Functions and operators\cos

\cosCommand

Used for cosine in trigonometric formulas, identities, and Fourier-style calculations

\cos
Available in
base, physics
Kind
prefix
Allowed mode
math
Frequency
2.01% of corpus formulasrank 28 of 263
Commonality
high
Renderer support
PackageMathJaxKaTeXXeTeX
baseMathJax: FullKaTeX: FullXeTeX: Full
physicsMathJax: FullKaTeX: FullXeTeX: Full
About the test scope

Syntax#

\cos

Takes no arguments. In base. Reading argspecs

\coso[a]optional math contentd()(b)optional math content

Argspec o d() — two optional arguments. In physics. Reading argspecs

Common tasks#

How to write cosine of an angle#

\cos\theta

How to write cosine with a power#

Write the power on the operator: \cos^2 x, not \cos x^2 unless you mean cos(x^2).

\cos^2 x + \sin^2 x = 1

How to write an inverse cosine#

\arccos x

Examples#

physics

\cos x

physics

\cos[2](x)

Package variants#

PackageSignatureAllowed modeNotes
basemathUsed for cosine in trigonometric formulas, identities, and Fourier-style calculations
physicso d()mathUsed for cosine notation, including bracketed powers such as \cos[2](x).

In TeXForm#

TeXForm parses this entry as prefix syntax; the package determines its argument specification.

physics/named-fn-paren-expandfrom Faithfulreading

Expand physics power and auto-sized parenthesis arguments of standard named functions.

\sin(#1) \sin\left(#1\right)

See also#

Test cases#

base
InputCaseMathJaxKaTeXXeTeX
\cosPositive · baselinePassPassPass
physics
InputCaseMathJaxKaTeXXeTeX
\cosPositive · baselinePassPassPass
\cos[a]Positive · vary:o[0]PassPassPass
\cos (a)Positive · vary:d[1]PassPassPass
\cos[a](b)Positive · maximalPassPassPass
All 74 in Functions and operators