2

How can I do this bar with the size adjusted?

enter image description here

Thanks in advance!

George
  • 221

4 Answers4

6
  • I use the \left and \right approach.
  • With \left. you create an "empty" \left. See Equation 2 where I used \left| instead.
  • With \right| you create the bar that you want.
  • Equation 3 is just a typographical addition and un-related to the question (\text{d} instead of d). Some people prefer it that way.

\documentclass{article}

% amsmath + improvements (here used for \text in math mode)
\usepackage{mathtools}

\begin{document}

\begin{equation}
\left.\frac{d}{ds}\right|_{s=0} \nu(s)
\end{equation}

Equation 2 ist just to show the effect of \texttt{\textbackslash left.} compared to \texttt{\textbackslash left|}.
\begin{equation}
\left|\frac{d}{ds}\right|_{s=0} \nu(s)
\end{equation}

\begin{equation}
\left.\frac{\text{d}}{\text{d}s}\right|_{s=0} \nu(s)
\end{equation}

\end{document}

enter image description here


Further reading

5

Like this? (with amendments suggested by Manuel Kühner and egreg)

enter image description here

\documentclass{article}
\begin{document}
$\displaystyle 
 \frac{d}{ds}\bigg\vert_{s=0} \nu(s) \quad\mbox{or}\quad
 \frac{d\nu(s)}{ds}\bigg|_{s=0}      \quad\mbox{or}\quad
 \nu\mkern1mu'(0)$
\end{document}
Mico
  • 506,678
5

It is very simple with the diffcoeff package:

\documentclass{article}
\usepackage{diffcoeff}

\begin{document}

\[ \diff{ν(s)}{s}[s=0]\]%

\end{document} 

enter image description here

Bernard
  • 271,350
4

I add my answer using derivative package:

\documentclass[a4paper,12pt]{article}
\usepackage{amssymb}
\usepackage{derivative}
\begin{document}
\[\odv{\nu(s)}{s}_{s=0}\quad \text{ or } \odv*{\phantom{d}}{s}_{s=0}\nu(s)\]
\end{document}

This is the screenshot:

enter image description here

Using another package that it is not very used (for reason also of spacing), called physics, you can obtained this:

\documentclass[a4paper,12pt]{article}
\usepackage{amssymb}
\usepackage{physics}
\begin{document}
\[\eval{\dv{s}}_{s=0}\nu(s), \quad \eval{\dv{\nu(s)}{s}}_{s=0}\]
\end{document}

....and this is the output:

a

Sebastiano
  • 54,118