Function Repository Resource:

ArcTanDegree

Source Notebook

Compute the inverse tangent of a number and get a result in degrees

Contributed by: Paco Jain (Wolfram Research)

ResourceFunction["ArcTanDegree"][x]

computes the inverse tangent of x in degrees.

ResourceFunction["ArcTanDegree"][x,y]

computes the inverse tangent of in degrees, taking into account which quadrant the point (x,y) is in.

Details

Mathematical function, suitable for both symbolic and numerical manipulation.
ResourceFunction["ArcTanDegree"][x] always returns a value between -90 and 90 for real x.
For certain special arguments, ResourceFunction["ArcTanDegree"] automatically evaluates to exact values.
ResourceFunction["ArcTanDegree"] can be evaluated to arbitrary numerical precision.
ResourceFunction["ArcTanDegree"] automatically threads over lists.

Examples

Basic Examples (2) 

Compute the inverse tangent of a number:

In[1]:=
ResourceFunction["ArcTanDegree"][1]
Out[1]=

Plot over a given range of values:

In[2]:=
Plot[ResourceFunction["ArcTanDegree"][x], {x, -5, 5}]
Out[2]=

ArcTanDegree[x,y] gives the angle of the point {x,y}:

In[3]:=
ResourceFunction["ArcTanDegree"][1, 1]
Out[3]=
In[4]:=
ResourceFunction["ArcTanDegree"][-1, -1]
Out[4]=

Scope (2) 

Evaluate numerically:

In[5]:=
ResourceFunction["ArcTanDegree"][43.1]
Out[5]=
In[6]:=
ResourceFunction["ArcTanDegree"][3., 4.]
Out[6]=

Evaluate to high precision:

In[7]:=
N[ResourceFunction["ArcTanDegree"][26], 50]
Out[7]=
In[8]:=
N[ResourceFunction["ArcTanDegree"][9, 14], 50]
Out[8]=

Applications (2) 

Find angles of the right triangle with sides 3, 4 and hypotenuse 5:

In[9]:=
N[{ResourceFunction["ArcTanDegree"][4, 3], ResourceFunction["ArcTanDegree"][3, 4]}]
Out[9]=

They total to 90°:

In[10]:=
Total[%]
Out[10]=

Requirements

Wolfram Language 11.3 (March 2018) or above

Version History

  • 1.1.0 – 13 September 2021
  • 1.0.0 – 27 November 2018

Related Resources

License Information