Atn Function

Hàm lượng giác mà trả về arctang của một biểu thức thuộc số. Giá trị trả về nằm trong phạm vi -π/2 đến +π/2.

The arctangent is the inverse of the tangent function. The Atn Function returns the angle "Alpha", expressed in radians, using the tangent of this angle. The function can also return the angle "Alpha" by comparing the ratio of the length of the side that is opposite of the angle to the length of the side that is adjacent to the angle in a right-angled triangle.

Atn(side opposite the angle/side adjacent to angle)= Alpha

Syntax:


        Atn (Number As Double) As Double
    

Return value:

Double

Parameters:

Number: Any numerical expression that represents the ratio of two sides of a right triangle. The Atn function returns the corresponding angle in radians (arctangent).

Để chuyển đổi một số radian sang độ, hãy nhân số radian với 180/π.

độ=(radian*180)/π

radian=(độ*π)/180

Pi is here the fixed circle constant with the rounded value 3.14159. Pi is a Basic mathematical constant.

Error codes:

5 Sai gọi thủ tục

Example:


        REM Mẫu ví dụ sau tính cho một tam giác vuông góc
        REM góc Alpha từ tang của góc Alpha:
        Sub ExampleAtn
        REM π = 3.14159 được làm tròn là một hằng số đã xác định sẵn
        Dim d1 As Double
        Dim d2 As Double
            d1 = InputBox("Nhập chiều dài của cạnh kề với góc: ","Kề")
            d2 = InputBox("Nhập chiều dài của cạnh đối với góc: ","Đối")
            Print "Góc Alpha là"; (atn (d2/d1) * 180 / Pi); " độ"
        End Sub
    

Please support us!