-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
expr: add support for trig functions - sin, cos, tan & their inverses
- Loading branch information
1 parent
670843c
commit a484816
Showing
18 changed files
with
713 additions
and
120 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,6 +3,9 @@ AES | |
APIs | ||
ARNs | ||
aren | ||
arcsin | ||
arccos | ||
arctan | ||
AST | ||
AdministratorAccess | ||
AllowKinesisAccess | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
--- | ||
title: Arccos | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Arccos | ||
|
||
Function in `num` namespace to get the value of the inverse trigonometric | ||
cosine function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the arccos of the input data (in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
:::info | ||
Invoking `arccos` outside the range [-1, 1] will return `NaN`. | ||
::: | ||
|
||
<pre snippet="api-reference/expressions/num#arccos" | ||
status="success" message="Getting arccos of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
--- | ||
title: Arcsin | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Arcsin | ||
|
||
Function in `num` namespace to get the value of the inverse trigonometric | ||
sine function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the arcsin of the input data (in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
|
||
:::info | ||
Invoking `arcsin` outside the range [-1, 1] will return `NaN`. | ||
::: | ||
|
||
|
||
<pre snippet="api-reference/expressions/num#arcsin" | ||
status="success" message="Getting arcsin of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Arctan | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Arctan | ||
|
||
Function in `num` namespace to get the value of the inverse trigonometric | ||
tangent function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the arctan of the input data (in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
|
||
<pre snippet="api-reference/expressions/num#arctan" | ||
status="success" message="Getting arctan of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Cos | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Cos | ||
|
||
Function in `num` namespace to get the value of the cosine function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the cos of the input data (expected | ||
to be in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
|
||
<pre snippet="api-reference/expressions/num#cos" | ||
status="success" message="Getting cos of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Sin | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Sin | ||
|
||
Function in `num` namespace to get the value of the sinusoidal function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the sin of the input data (expected | ||
to be in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
|
||
<pre snippet="api-reference/expressions/num#sin" | ||
status="success" message="Getting sin of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
--- | ||
title: Tan | ||
order: 0 | ||
status: published | ||
--- | ||
|
||
### Tan | ||
|
||
Function in `num` namespace to get the value of the trigonometric tangent function. | ||
|
||
#### Returns | ||
<Expandable type="Expr"> | ||
Returns an expression object denoting the tan of the input data (expected | ||
to be in radians). | ||
|
||
The data type of the resulting expression is `float` if the input is `int` or | ||
`float` and `Optional[float]` if the input is `Optional[int]` or `Optional[float]`. | ||
</Expandable> | ||
|
||
|
||
<pre snippet="api-reference/expressions/num#tan" | ||
status="success" message="Getting tan of a number"> | ||
</pre> | ||
|
||
#### Errors | ||
<Expandable title="Invoking on a non-numeric type"> | ||
Error during `typeof` or `eval` if the input expression is not of type int, | ||
float, optional int or optional float. | ||
</Expandable> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.