Function reference · Math
tri
Computes a triangular pulse centered at zero.
tri(x) returns 1-|x| when |x|<1 and 0 when |x|>=1. Unresolved symbolic inputs remain as tri(x).
Examples
These examples use Nerdamer Notation.
Evaluate the peak of the triangular pulse.
tri(0)
// → 1Evaluate an interior point exactly.
tri(1/4)
// → 3/4Return zero at the boundary.
tri(1)
// → 0Keep an unresolved symbolic input unevaluated.
tri(x)
// → tri(x)Interfaces
The same operation is available through the interfaces below.
Nerdamer Notation
Use this form inside input passed to nerdamer(...).
tri(arg1)
nerdamer.tri
Call the operation through the default nerdamer import.
nerdamer.tri(x: ExpressionInput): Expression
Parameters
| Name | Type | Description |
|---|---|---|
x | ExpressionInput | — |
