Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
Vašek edited this page Jan 13, 2019 · 8 revisions

tan

Returns the tangent of value in radians

Syntax:

tan(x)
Argument Description
double x The angle in radians to tangent

Returns: double

Description:

In a right angled triangle tan(x) = Opposite / Adjacent. If you want to use degrees instead of radians use function dtan().

This function will accept any number except pi/2 plus-minus multiples of pi. In that case the function return error due to returning infinity.

Example:

double value;
value = tan(5);

This code will set value to -3,380515.

Back to number_functions

Clone this wiki locally

AltStyle によって変換されたページ (->オリジナル) /