Inverse tangent function
For arctan in MATLAB^{®}, see atan
.
MuPAD® notebooks are not recommended. Use MATLAB® live scripts instead.
MATLAB live scripts support most MuPAD functionality, though there are some differences. For more information, see Convert MuPAD Notebooks to MATLAB Live Scripts.
arctan(x
) arctan(y
,x
)
arctan(x)
represents the inverse of the tangent
function.
arctan(y, x)
is an alias for arg
(x, y)
.
The angle returned by this function is measured in radians, not in degrees. For example, the result π represents an angle of 180^{o}.
arctan
is defined for complex arguments.
Floatingpoint values are returned for floatingpoint arguments. Floatingpoint intervals are returned for interval arguments. Unevaluated function calls are returned for most exact arguments.
If the argument is a rational multiple of I
,
the result is expressed in terms of hyperbolic functions. See Example 2.
The inverse tangent function is multivalued. The MuPAD^{®} arctan
function
returns the value on the main branch. The branch cuts are the intervals $$\left(i\infty ,i\right]$$ and $$\left[i,\text{\hspace{0.17em}}i\infty \right)$$ on
the imaginary axis. Thus, arctan
returns values,
such that y = arctan(x) satisfies $$\frac{\pi}{2}<\Re \left(y\right)<\frac{\pi}{2}$$ for
any finite complex x.
The tan
function returns explicit values
for arguments that are certain rational multiples of π.
For these values, arctan
returns an appropriate
rational multiple of π on
the main branch. See Example 3.
The values jump when the arguments cross a branch cut. See Example 4.
The float attributes are kernel functions. Thus, floatingpoint evaluation is fast.
If you call arctan
with two arguments, y
and x
, MuPAD calls
the arg
function
that computes the polar angle of a complex number x + I*y
.
See Example 7 and the arg
help page.
When called with a floatingpoint argument, arctan
is
sensitive to the environment variable DIGITS
which determines
the numerical working precision.
Call arctan
with the following exact and
symbolic input arguments:
arctan(5), arctan(1/sqrt(2)), arctan(5 + I), arctan(1/3), arctan(0), arctan(1)
arctan(x), arctan(x + 1), arctan(1/x)
Floatingpoint values are computed for floatingpoint arguments:
arctan(0.1234), arctan(5.6 + 7.8*I), arctan(1.0/10^20)
Floatingpoint intervals are computed for interval arguments:
arctan(2...2), arctan(0...10)
Arguments that are rational multiples of I
are
rewritten in terms of hyperbolic functions:
arcsin(5*I), arccos(5/4*I), arctan(3*I)
For other complex arguments unevaluated function calls without simplifications are returned:
arcsin(1/2^(1/2) + I), arccos(1 3*I)
Some special values are implemented:
arctan(1), arctan((5  2*5^(1/2))^(1/2)), arctan(3^(1/2)  2)
Such simplifications occur for arguments that are trigonometric images of rational multiples of π:
tan(9/10*PI), arctan(tan(9/10*PI))
The values jump when crossing a branch cut:
arctan(2.0*I + 10^(10)), arctan(2.0*I  10^(10))
On the branch cut, the values of arctan
coincide
with the limit "from the right" for imaginary arguments x
= c*i
where c > 1
:
limit(arctan(2.0*I  1/n), n = infinity); limit(arctan(2.0*I + 1/n), n = infinity); arctan(2.0*I)
The values coincide with the limit "from the left"
for imaginary arguments x = c*i
where c
< 1
:
limit(arctan(2.0*I  1/n), n = infinity); limit(arctan(2.0*I + 1/n), n = infinity); arctan(2.0*I)
The inverse tangent function can be rewritten in terms of the logarithm function with complex arguments:
rewrite(arctan(x), ln)
diff
, float
, limit
, taylor
, and other system
functions handle expressions involving the inverse trigonometric functions:
diff(arctan(x), x), float(arccos(3)*arctan(5 + I))
limit(arctan(sin(x)/tan(x)), x = 0)
taylor(arctan(x), x = 0)
When you call arctan
with two arguments, MuPAD calls
the arg
function
and computes the polar angle of a complex number:
arctan(y, x)
 

Arithmetical expressions representing real numbers 
Arithmetical expression or floatingpoint interval.
x