ArcTangent
systemic:core-arctanMathfunction1 crInputs
| Name | Type | Description |
|---|---|---|
| Data | floatarray | The input data series for the arctangent calculation. |
Outputs
| Name | Type | Description |
|---|---|---|
| ArcTan | floatarray | The arctangent of each input value, expressed in **radians**. |
The Arctangent (arctan) module computes the inverse tangent of each value in a data series, returning the angle in radians whose tangent equals that value.
Mathematical Foundation
Domain and Range
| Property | Value |
|---|---|
| Domain | — all real numbers |
| Range | radians (-90° to 90°) |
Key Advantage: Unlike arcsine and arccosine, arctangent accepts any real number as input. This makes it ideal for processing unbounded data series without worrying about invalid inputs.
Properties
- (45°)
- (-45°)
- for all
- As ,
- As ,
Key Values
| Input | Output (radians) | Output (degrees) |
|---|---|---|
| 10 | 1.471 | 84.3° |
| 1 | 0.785 | 45° |
| 0.5 | 0.464 | 26.6° |
| 0 | 0 | 0° |
| -0.5 | -0.464 | -26.6° |
| -1 | -0.785 | -45° |
| -10 | -1.471 | -84.3° |
Behavior in Systemic
The Arctangent module applies the arctan function element-wise to every value in the input series.
Handling Any Input
Unlike arcsine and arccosine, arctangent is defined for all real numbers. Any numeric input produces a valid angle — even infinite values map cleanly to . This makes arctangent particularly robust for processing raw, unbounded data.
Missing Data
If a value is missing (null) at some position in the input series — a data gap or a closed-market day — the output is null at that same position. The module never substitutes a fabricated number for missing data; every non-missing input still produces its real angle.
Because arctangent has no invalid inputs, a null output always means the input was missing at that position — never a math error.
In live execution, the module returns exactly one datapoint: the newest value, which is null when the newest input is missing.
Creative Applications
Data Normalization (Squashing)
Arctangent is an excellent squashing function that compresses any unbounded range into a bounded interval :
- Large positive values → approach
- Large negative values → approach
- Values near zero → approximately linear response
This property is invaluable for:
- Outlier compression — reducing the impact of extreme values
- Signal normalization — converting unbounded indicators into bounded ranges
- Rate-of-change smoothing — compressing large price moves
Momentum Analysis
Apply arctangent to rate-of-change or momentum indicators to create a bounded momentum oscillator. Extreme momentum readings (both positive and negative) get compressed, making the signal easier to interpret and compare across different time periods or assets.
flowchart LR
Price[Price Data] --> ROC[Rate of Change]
ROC --> ARCTAN((Arctan))
ARCTAN --> Bounded["Bounded Momentum<br/>(-π/2 to +π/2)"]
Converting Radians to Degrees
The output is in radians. To convert to degrees, multiply by :
Use a Multiply module with a constant of approximately 57.2958 to convert.