7

I am studying theory at university, and the lecturer uses this symbol for elementary probability: elementary probability

I want to use it in math mode, but the best suggestions I got from http://detexify.kirelabs.org/classify.html was:

\usepackage[T1]{fontenc}
\TH
textmode

and

\usepackage{ tipa }
\textthorn
textmode

What i need is this symbol, sans serif, italic, in math mode.

How can i reach it?

4

The Comprehensive list shows a bundle of different \thorn symbols, depending on various packages.

The table below gives an example of some of the commands.

There might be some warnings, especially for the \itshape fontshape, since this shape is not available for all fonts/symbols

\documentclass{article}


\usepackage{mathtools}
\usepackage[T1]{fontenc}
\usepackage{tipa}
\usepackage{tipx}
\usepackage{wasysym}

\newcommand{\mythorntable}[1]{%
\begin{tabular}{ll}
\multicolumn{2}{c}{#1} \tabularnewline
fontenc & \TH~\th \tabularnewline
tipa & \textthorn \tabularnewline
tipx & \textthornvari~\textthornvarii~\textthornvariii~\textthornvariv \tabularnewline
wasysym & \thorn~\Thorn \tabularnewline
\end{tabular}
}

\begin{document}

\huge
\begin{tabular}{ll}
\mythorntable{Normal font}
 &
\slshape
\mythorntable{Slanted}
\tabularnewline
& \tabularnewline
\sffamily
\mythorntable{Sans serif}
 &
 \itshape
 \mythorntable{Italic}
 \tabularnewline
 & \tabularnewline
 \begin{tabular}{ll}
   \multicolumn{2}{c}{Math} \tabularnewline
   fontenc & $\text{\sffamily\itshape\TH~\th}$ \tabularnewline
   tipa & $\text{\sffamily\itshape\textthorn}$ \tabularnewline
   \tabularnewline
 \end{tabular} &

\end{tabular} 


\end{document}

enter image description here

  • As you can see, tipx does not provide italic \textthornvari etc. variants – user31729 Mar 11 '15 at 21:01
2

Use sans serif italic! ;-)

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage{amsmath}

\newcommand{\pTH}{\text{\normalfont\sffamily\itshape\TH\/}}
\newcommand{\pth}{\text{\normalfont\sffamily\itshape\th\/}}

\begin{document}
$a\pTH b\ne a\pth b$
\end{document}

enter image description here

0

Old questions but I just wanted to add that the commands \TH and \th for Fontenc only works in text and not in math mode. The way I did was:

$ \text{\TH}_n $

This allowed me to use the Thorn symbol with a subscript.

Thorn symbol with subscript

0

For use in pdflatex.

\documentclass{article}
\usepackage{tabstackengine}
\newsavebox\foobox
\newcommand{\slantbox}[2][.5]{\mbox{%
        \sbox{\foobox}{#2}%
        \hskip\wd\foobox
        \pdfsave
        \pdfsetmatrix{1 0 #1 1}%
        \llap{\usebox{\foobox}}%
        \pdfrestore
}}
\setstacktabbedgap{.5ex}
\setstackgap{L}{8pt}
\newcommand\prob{\mkern-1mu%
  \slantbox[.3]{\stackengine{0pt}{$\mathsf{p}$}{$\mathsf{l}$}{O}{l}{F}{F}{L}}%
  \mkern1mu}
\begin{document}
$(\prob(x) = .3)$
\end{document}

enter image description here

If one needs it in the smaller math styles:

\documentclass{article}
\usepackage{tabstackengine,scalerel}
\newsavebox\foobox
\newcommand{\slantbox}[2][.5]{\mbox{%
        \sbox{\foobox}{#2}%
        \hskip\wd\foobox
        \pdfsave
        \pdfsetmatrix{1 0 #1 1}%
        \llap{\usebox{\foobox}}%
        \pdfrestore
}}
\setstacktabbedgap{.5ex}
\setstackgap{L}{8pt}
\newcommand\prob{\ThisStyle{\mkern-1mu%
  \slantbox[.3]{\stackengine{0pt}{$\SavedStyle\mathsf{p}$}{$\SavedStyle\mathsf{l}$}{O}{l}{F}{F}{L}}%
  \mkern1mu}}
\begin{document}
$(\prob(x) = .3)$

$\scriptstyle(\prob(x) = .3)$

$\scriptscriptstyle(\prob(x) = .3)$
\end{document}

enter image description here

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.