ArcTan

concerns

The ArcTan function returns a value that specifies the arc tangent of the passed value.

 

Syntax

ArcTan(Value)

Return value

Type

Description

Double

Arc tangent of Value

Parameter

Use

Name

Type

Passing

Description

Required

Value

Double

ByVal

Value to retrieve the arc tangent.

Notes

The ArcTanfunction calculates the ratio of two sides of a right-angled triangle (Value) and returns the corresponding anglein radians. The ratio is the length of the side opposite the angle divided by the length of the side attached to the angle.

The result for the radians is in the range of - π/2 to π/2.

In order to convert degrees to radians, the degree must be multiplied by π/180.

ArcTan is the inverse function of the trigonometric function  Tan, which receives an angle as an argument and returns the ratio of the two sides of a right-angled triangle. Do not confuse ArcTan  with the cotangent that corresponds to the inverse of the tangent (1/tangent).

Example

Dim pi2 As Double

pi2 := 4 * ArcTan(1)

In this example, the ArcTan function is used to calculate the value of π.