Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
This module contains the maths-specific part of Text.LaTeX.Base.Commands, i.e. of the commands that are available in LaTeX out of the box without any imports.
Note however that most maths-related documents use the amsmath package, which not only adds some more environments but also improves on rendering details such as symbol spacing. So even if you only need the vanilla-LaTeX commands that this module provides, consider importing Text.LaTeX.Packages.AMSMath instead; it re-exports the entire Text.LaTeX.Base.Math module.
Synopsis
- math :: LaTeXC l => l -> l
- mathDisplay :: LaTeXC l => l -> l
- equation :: LaTeXC l => l -> l
- equation_ :: LaTeXC l => l -> l
- nonumber :: LaTeXC l => l
- autoParens :: LaTeXC l => l -> l
- autoSquareBrackets :: LaTeXC l => l -> l
- autoBraces :: LaTeXC l => l -> l
- autoAngleBrackets :: LaTeXC l => l -> l
- autoBrackets :: LaTeXC l => LaTeX -> LaTeX -> l -> l
- langle :: LaTeXC l => l
- rangle :: LaTeXC l => l
- lfloor :: LaTeXC l => l
- rfloor :: LaTeXC l => l
- lceil :: LaTeXC l => l
- rceil :: LaTeXC l => l
- dblPipe :: LaTeXC l => l
- (^:) :: LaTeXC l => l -> l -> l
- (!:) :: LaTeXC l => l -> l -> l
- (!^) :: LaTeXC l => l -> (l, l) -> l
- tsin :: LaTeXC l => l
- arcsin :: LaTeXC l => l
- tcos :: LaTeXC l => l
- arccos :: LaTeXC l => l
- ttan :: LaTeXC l => l
- arctan :: LaTeXC l => l
- cot :: LaTeXC l => l
- arccot :: LaTeXC l => l
- tsinh :: LaTeXC l => l
- tcosh :: LaTeXC l => l
- ttanh :: LaTeXC l => l
- coth :: LaTeXC l => l
- sec :: LaTeXC l => l
- csc :: LaTeXC l => l
- texp :: LaTeXC l => l
- tlog :: LaTeXC l => l
- ln :: LaTeXC l => l
- tsqrt :: LaTeXC l => Maybe l -> l -> l
- operatorname :: LaTeXC l => l -> l
- tsum :: LaTeXC l => l
- sumFromTo :: LaTeXC l => l -> l -> l
- prod :: LaTeXC l => l
- prodFromTo :: LaTeXC l => l -> l -> l
- coprod :: LaTeXC l => l
- coprodFromTo :: LaTeXC l => l -> l -> l
- integral :: LaTeXC l => l
- integralFromTo :: LaTeXC l => l -> l -> l
- partial :: LaTeXC l => l
- totald :: LaTeXC l => l
- partialOf :: LaTeXC l => l -> l
- totaldOf :: LaTeXC l => l -> l
- bigcup :: LaTeXC l => l
- bigcupFromTo :: LaTeXC l => l -> l -> l
- bigcap :: LaTeXC l => l
- bigcapFromTo :: LaTeXC l => l -> l -> l
- (+-) :: LaTeXC l => l -> l -> l
- (-+) :: LaTeXC l => l -> l -> l
- cdot :: LaTeXC l => l -> l -> l
- times :: LaTeXC l => l -> l -> l
- div_ :: LaTeXC l => l -> l -> l
- frac :: LaTeXC l => l -> l -> l
- (*:) :: LaTeXC l => l -> l -> l
- star :: LaTeXC l => l -> l -> l
- circ :: LaTeXC l => l -> l -> l
- bullet :: LaTeXC l => l -> l -> l
- (=:) :: LaTeXC l => l -> l -> l
- (/=:) :: LaTeXC l => l -> l -> l
- (<:) :: LaTeXC l => l -> l -> l
- (<=:) :: LaTeXC l => l -> l -> l
- (>:) :: LaTeXC l => l -> l -> l
- (>=:) :: LaTeXC l => l -> l -> l
- ll :: LaTeXC l => l -> l -> l
- gg :: LaTeXC l => l -> l -> l
- equiv :: LaTeXC l => l -> l -> l
- propto :: LaTeXC l => l -> l -> l
- parallel :: LaTeXC l => l -> l -> l
- perp :: LaTeXC l => l -> l -> l
- approx :: LaTeXC l => l -> l -> l
- sim :: LaTeXC l => l -> l -> l
- simeq :: LaTeXC l => l -> l -> l
- cong :: LaTeXC l => l -> l -> l
- in_ :: LaTeXC l => l -> l -> l
- ni :: LaTeXC l => l -> l -> l
- notin :: LaTeXC l => l -> l -> l
- subset :: LaTeXC l => l -> l -> l
- supset :: LaTeXC l => l -> l -> l
- subseteq :: LaTeXC l => l -> l -> l
- supseteq :: LaTeXC l => l -> l -> l
- cap :: LaTeXC l => l -> l -> l
- cup :: LaTeXC l => l -> l -> l
- setminus :: LaTeXC l => l -> l -> l
- vee :: LaTeXC l => l -> l -> l
- wedge :: LaTeXC l => l -> l -> l
- oplus :: LaTeXC l => l -> l -> l
- ominus :: LaTeXC l => l -> l -> l
- otimes :: LaTeXC l => l -> l -> l
- oslash :: LaTeXC l => l -> l -> l
- odot :: LaTeXC l => l -> l -> l
- uplus :: LaTeXC l => l -> l -> l
- hat :: LaTeXC l => l -> l
- tilde :: LaTeXC l => l -> l
- bar :: LaTeXC l => l -> l
- vec :: LaTeXC l => l -> l
- widehat :: LaTeXC l => l -> l
- widetilde :: LaTeXC l => l -> l
- dot :: LaTeXC l => l -> l
- overline :: LaTeXC l => l -> l
- alpha :: LaTeXC l => l
- beta :: LaTeXC l => l
- gamma :: LaTeXC l => l
- gammau :: LaTeXC l => l
- delta :: LaTeXC l => l
- deltau :: LaTeXC l => l
- epsilon :: LaTeXC l => l
- varepsilon :: LaTeXC l => l
- zeta :: LaTeXC l => l
- eta :: LaTeXC l => l
- theta :: LaTeXC l => l
- vartheta :: LaTeXC l => l
- thetau :: LaTeXC l => l
- iota :: LaTeXC l => l
- kappa :: LaTeXC l => l
- lambda :: LaTeXC l => l
- lambdau :: LaTeXC l => l
- mu :: LaTeXC l => l
- nu :: LaTeXC l => l
- xi :: LaTeXC l => l
- xiu :: LaTeXC l => l
- pi_ :: LaTeXC l => l
- varpi :: LaTeXC l => l
- piu :: LaTeXC l => l
- rho :: LaTeXC l => l
- varrho :: LaTeXC l => l
- sigma :: LaTeXC l => l
- varsigma :: LaTeXC l => l
- sigmau :: LaTeXC l => l
- tau :: LaTeXC l => l
- upsilon :: LaTeXC l => l
- upsilonu :: LaTeXC l => l
- phi :: LaTeXC l => l
- varphi :: LaTeXC l => l
- phiu :: LaTeXC l => l
- chi :: LaTeXC l => l
- psi :: LaTeXC l => l
- psiu :: LaTeXC l => l
- omega :: LaTeXC l => l
- omegau :: LaTeXC l => l
- uparrow :: LaTeXC l => l
- downarrow :: LaTeXC l => l
- uparrow2 :: LaTeXC l => l
- downarrow2 :: LaTeXC l => l
- updownarrow :: LaTeXC l => l
- updownarrow2 :: LaTeXC l => l
- leftarrow :: LaTeXC l => l
- rightarrow :: LaTeXC l => l
- leftrightarrow :: LaTeXC l => l
- leftrightarrow2 :: LaTeXC l => l
- leftarrow2 :: LaTeXC l => l
- rightarrow2 :: LaTeXC l => l
- longleftarrow :: LaTeXC l => l
- longrightarrow :: LaTeXC l => l
- longleftarrow2 :: LaTeXC l => l
- longrightarrow2 :: LaTeXC l => l
- longleftrightarrow :: LaTeXC l => l
- longleftrightarrow2 :: LaTeXC l => l
- nwarrow :: LaTeXC l => l
- nearrow :: LaTeXC l => l
- swarrow :: LaTeXC l => l
- searrow :: LaTeXC l => l
- to :: LaTeXC l => l
- mapsto :: LaTeXC l => l
- longmapsto :: LaTeXC l => l
- hookleftarrow :: LaTeXC l => l
- hookrightarrow :: LaTeXC l => l
- leftharpoonup :: LaTeXC l => l
- rightharpoonup :: LaTeXC l => l
- leftharpoondown :: LaTeXC l => l
- rightharpoondown :: LaTeXC l => l
- pm :: LaTeXC l => l
- mp :: LaTeXC l => l
- implies :: LaTeXC l => l
- forall :: LaTeXC l => l
- exists :: LaTeXC l => l
- dagger :: LaTeXC l => l
- ddagger :: LaTeXC l => l
- infty :: LaTeXC l => l
- imath :: LaTeXC l => l
- jmath :: LaTeXC l => l
- bot :: LaTeXC l => l
- mathdefault :: LaTeXC l => l -> l
- mathbf :: LaTeXC l => l -> l
- mathrm :: LaTeXC l => l -> l
- mathcal :: LaTeXC l => l -> l
- mathsf :: LaTeXC l => l -> l
- mathtt :: LaTeXC l => l -> l
- mathit :: LaTeXC l => l -> l
Math Environments
mathDisplay :: LaTeXC l => l -> l Source #
Displayed mathematical expressions, i.e. in a seperate line / block.
equation :: LaTeXC l => l -> l Source #
A numbered mathematical equation (or otherwise math expression).
Referencing
nonumber :: LaTeXC l => l Source #
Prevent an equation from being numbered, where the environment would by default do that.
Symbols and utilities
Brackets / delimiters
autoParens :: LaTeXC l => l -> l Source #
Surround a LaTeX math expression by parentheses whose height
automatically matches the expression's. Translates to \left(...\right)
.
autoSquareBrackets :: LaTeXC l => l -> l Source #
Like autoParens
, but with square brackets. Equivalent to
.autoBrackets
"[""]"
autoBraces :: LaTeXC l => l -> l Source #
Like autoParens
, but with curly brackets.
autoAngleBrackets :: LaTeXC l => l -> l Source #
Like autoParens
, but with angle brackets \(\langle\) ... \(\rangle\). Equivalent to
.autoBrackets
langle
rangle
dblPipe :: LaTeXC l => l Source #
Double vertical line, used as delimiter for norms \(\| \ldots \|\).
Superscript and subscript
Function symbols
Some symbols are preceded with t to be distinguished from
predefined Haskell entities (like sin
and cos
).
tsqrt :: LaTeXC l => Maybe l -> l -> l Source #
Root notation. Use tsqrt (Just n) x
for the n
th root of x
.
When Nothing
is supplied, the function will output a square root.
Custom function symbols
operatorname :: LaTeXC l => l -> l Source #
Defines a new function symbol. Note that function symbols defined in this way will not be automatically translated by babel.
Summation / integration / differentiation / relations
tsum :: LaTeXC l => l Source #
Sigma sumation symbol \(\sum\). Use sumFromTo
instead if you want to
specify the limits of the sum.
:: LaTeXC l | |
=> l | Expression below the sigma. |
-> l | Expression above the sigma. |
-> l |
Sigma sumation symbol with limits, like \[\sum_0^n\].
prod :: LaTeXC l => l Source #
Pi product symbol \(\prod\). Use prodFromTo
if you want to specify the
limits of the product.
:: LaTeXC l | |
=> l | Expression below the pi. |
-> l | Expression above the pi. |
-> l |
Pi product symbol with limits, like \[\prod_0^n\].
coprod :: LaTeXC l => l Source #
Coproduct symbol \(\coprod\). Use coprodFromTo
if you want to specify the
limits of the coproduct.
:: LaTeXC l | |
=> l | Expression below. |
-> l | Expression above. |
-> l |
Coproduct symbol with limits, like \[\coprod_0^n\].
integral :: LaTeXC l => l Source #
Integral symbol. Use integralFromTo
if you want to specify
the limits of the integral.
:: LaTeXC l | |
=> l | Lower limit of integration. |
-> l | Upper limit of integration. |
-> l |
Integral symbol with limits of integration. \(\int\limits_{-1}^1\)
totald :: LaTeXC l => l Source #
Total-differentiation (or integration-variable) symbol d (non-italic!)
To be used as frac (totald) (totald<>"x")
→ \(\frac{\mathrm{d}}{\mathrm{d}x}\).
partialOf :: LaTeXC l => l -> l Source #
Partial-differentiation of variable, e.g.
frac (partialOf h) (partialOf t)
→ \(\frac{\partial h}{\partial t}\).
totaldOf :: LaTeXC l => l -> l Source #
Total-differentiation of variable, or integration over variable. To be used as
integralFromTo 0 infty $ totaldOf "x" <> "f(x)"
\[\int\limits_0^\infty\mathrm{d}x f(x),\] or
frac (totaldOf"f") (totaldOf"x")
→ \(\frac{\mathrm{d}f}{\mathrm{d}x}\).
bigcup :: LaTeXC l => l Source #
Big union symbol \(\bigcup\). Use bigcupFromTo
if you want to specify the
limits of the union.
:: LaTeXC l | |
=> l | Expression below. |
-> l | Expression above. |
-> l |
Big union symbol with limits, like \[\bigcup_0^n\].
bigcap :: LaTeXC l => l Source #
Big intersection symbol \(\bigcap\). Use bigcapFromTo
if you want to specify the
limits of the intersection.
:: LaTeXC l | |
=> l | Expression below. |
-> l | Expression above. |
-> l |
Big intersection symbol with limits, like \[\bigcap_0^n\].
Operator symbols
Arithmetic
(+-) :: LaTeXC l => l -> l -> l infixl 6 Source #
Plus-or-minus operator \(\pm\). Also available as symbol pm
.
(-+) :: LaTeXC l => l -> l -> l infixl 6 Source #
Minus-or-plus operator \(\mp\). Also available as symbol mp
.
Comparison
simeq :: LaTeXC l => l -> l -> l Source #
Equivalence relation \(\simeq\). Sometimes used for approximate equality or isomorphism.
Sets
Misc operators
Accents
widetilde :: LaTeXC l => l -> l Source #
Add a wide tilde accent above a symbol, like \(\widetilde{u}\).
dot :: LaTeXC l => l -> l Source #
Add a dot accent above a symbol, as used to denote a derivative, like \(\dot{x}\).
overline :: LaTeXC l => l -> l Source #
Add a wide line accent above a symbol, like \(\overline{abc}\).
Greek alphabet
Functions of greek alphabet symbols.
Uppercase versions are suffixed with u
.
Variants are prefixed with var
.
The function pi_
is ended by an underscore symbol to
distinguish it from the pi
Prelude function.
varepsilon :: LaTeXC l => l Source #
\(\varepsilon\) symbol.
Arrows
downarrow2 :: LaTeXC l => l Source #
\(\Downarrow\) symbol
updownarrow :: LaTeXC l => l Source #
\(\updownarrow\) symbol
updownarrow2 :: LaTeXC l => l Source #
\(\Updownarrow\) symbol
rightarrow :: LaTeXC l => l Source #
\(\rightarrow\) symbol
leftrightarrow :: LaTeXC l => l Source #
\(\leftrightarrow\) symbol
leftrightarrow2 :: LaTeXC l => l Source #
\(\Leftrightarrow\) symbol
leftarrow2 :: LaTeXC l => l Source #
\(\Leftarrow\) symbol
rightarrow2 :: LaTeXC l => l Source #
\(\Rightarrow\) symbol
longleftarrow :: LaTeXC l => l Source #
\(\longleftarrow\) symbol
longrightarrow :: LaTeXC l => l Source #
\(\longrightarrow\) symbol
longleftarrow2 :: LaTeXC l => l Source #
\(\Longleftarrow\) symbol
longrightarrow2 :: LaTeXC l => l Source #
\(\Longrightarrow\) symbol
longleftrightarrow :: LaTeXC l => l Source #
\(\longleftrightarrow\) symbol
longleftrightarrow2 :: LaTeXC l => l Source #
\(\Longleftrightarrow\) symbol
longmapsto :: LaTeXC l => l Source #
\(\longmapsto\) symbol
hookleftarrow :: LaTeXC l => l Source #
\(\hookleftarrow\) symbol
hookrightarrow :: LaTeXC l => l Source #
\(\hookrightarrow\) symbol
leftharpoonup :: LaTeXC l => l Source #
\(\leftharpoonup\) symbol
rightharpoonup :: LaTeXC l => l Source #
\(\rightharpoonup\) symbol
leftharpoondown :: LaTeXC l => l Source #
\(\leftharpoondown\) symbol
rightharpoondown :: LaTeXC l => l Source #
\(\rightharpoondown\) symbol
Other symbols
Fonts
mathdefault :: LaTeXC l => l -> l Source #
Default math symbol font.
mathcal :: LaTeXC l => l -> l Source #
Calligraphic math symbols. Only works (reliably) with uppercase letters, like \(\mathcal{LMN}\).
mathit :: LaTeXC l => l -> l Source #
Italic math. Uses the same glyphs as mathdefault
, but with spacings
intended for multi-character symbols rather than juxtaposition of single-character symbols.
Orphan instances
Floating LaTeX Source # | The |
Num LaTeX Source # | The |
Fractional LaTeX Source # | Division uses the LaTeX |
(Monad m, a ~ ()) => Floating (LaTeXT m a) Source # | Undefined methods: |
exp :: LaTeXT m a -> LaTeXT m a # log :: LaTeXT m a -> LaTeXT m a # sqrt :: LaTeXT m a -> LaTeXT m a # (**) :: LaTeXT m a -> LaTeXT m a -> LaTeXT m a # logBase :: LaTeXT m a -> LaTeXT m a -> LaTeXT m a # sin :: LaTeXT m a -> LaTeXT m a # cos :: LaTeXT m a -> LaTeXT m a # tan :: LaTeXT m a -> LaTeXT m a # asin :: LaTeXT m a -> LaTeXT m a # acos :: LaTeXT m a -> LaTeXT m a # atan :: LaTeXT m a -> LaTeXT m a # sinh :: LaTeXT m a -> LaTeXT m a # cosh :: LaTeXT m a -> LaTeXT m a # tanh :: LaTeXT m a -> LaTeXT m a # asinh :: LaTeXT m a -> LaTeXT m a # acosh :: LaTeXT m a -> LaTeXT m a # atanh :: LaTeXT m a -> LaTeXT m a # log1p :: LaTeXT m a -> LaTeXT m a # expm1 :: LaTeXT m a -> LaTeXT m a # | |
(Monad m, a ~ ()) => Num (LaTeXT m a) Source # | Careful! Method |
(Monad m, a ~ ()) => Fractional (LaTeXT m a) Source # | Division uses the LaTeX |