WLJS LogoWLJS Notebook

UnitTriangle

UnitTriangle[x] represents the unit triangle function on the interval |x| ≤ 1.

UnitTriangle[x1,x2,…] represents the multidimensional unit triangle function on the interval |xi| ≤ 1.

Examples

Evaluate the unit triangle function:

UnitTriangle[0.5]
(* 0.5 *)

Plot the unit triangle:

Plot[UnitTriangle[x], {x, -2, 2}]

Please visit the official Wolfram Language Reference for more details.

On this page