Please enable JavaScript to view this site.

Knowledge Base

Calculates the inverse trigonometric tangent function (arctangent). Angle units are in radians. The function is defined for complex values. Phase of a complex number is evaluated between -π and π. If x is complex, or abs(x) > 1, the following equation is used:

 

Supported Product: FDTD, MODE, DEVICE, INTERCONNECT

 

Syntax

Description

out = atan(x);

Returns the complex arctangent of x. The range of atan is -π/2 to π/2.

 

Example

Plot atan(y/x) for -π ≤ theta≤ π.

ref_fdtd_scripts_atan_xy_zoom54 ref_fdtd_scripts_atan_theta_zoom54

theta=linspace(-pi,pi,1000);

x=cos(theta);

y=sin(theta);

plot(theta*180/pi,atan(y/x)*180/pi,"theta (deg)","atan(y/x) (deg)","atan(y/x)");

plot(y/x,atan(y/x)*180/pi,"y/x","atan(y/x) (deg)","atan(y/x)");

 

Calculate atan(π/4 + i).

x=pi/4+1i;

?atan(x);

result: 

0.972497+0.50321i 

 

See Also

Functions, atan2, tan

Copyright Lumerical Inc. | Privacy | Site Map