Skip to content

HeavisidePi ​

The Heaviside-family rectangular pulse: 1 for |x| < 1/2, unevaluated at x = ±1/2, 0 for |x| > 1/2.

✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram LanguageHeavisidePi!
HeavisidePi(x)1 inside (-1/2, 1/2), 0 outside [-1/2, 1/2], and unevaluated (stays symbolic) exactly at x = ±1/2.
Typed signatures
TypePackageApplies
(real) -> numberanalyticalways

Domain: Elementary functions

Details
  • The same rectangular pulse as UnitBox, but the boundary is left open rather than closed -- UnitBox(±1/2) = 1, HeavisidePi(±1/2) unevaluated. The two heads exist for the two conventions.

Examples

Basic #
live ↗
InHeavisidePi(0)\mathrm{HeavisidePi}(0)Out11

Unevaluated at the boundary -- unlike UnitBox

live ↗
InHeavisidePi(12)\mathrm{HeavisidePi}(\frac{1}{2})OutHeavisidePi(12)\mathrm{HeavisidePi}(\frac{1}{2})
live ↗
InHeavisidePi(−12)\mathrm{HeavisidePi}(-\frac{1}{2})OutHeavisidePi(−12)\mathrm{HeavisidePi}(-\frac{1}{2})
Scope #
live ↗
InHeavisidePi(1)\mathrm{HeavisidePi}(1)Out00

Zero outside the support ∣x∣<12|x|<\frac12

live ↗
InHeavisidePi(−1)\mathrm{HeavisidePi}(-1)Out00

Equals 1 inside the support

live ↗
InHeavisidePi(14)\mathrm{HeavisidePi}(\frac{1}{4})Out11

The matrix function takes the value at each eigenvalue, here both 0

live ↗
InMatrixFunction(HeavisidePi,[[−1,0],[0,1]])\mathrm{MatrixFunction}(\mathrm{HeavisidePi}, \bigl\lbrack\bigl\lbrack-1, 0\bigr\rbrack, \bigl\lbrack0, 1\bigr\rbrack\bigr\rbrack)Out[[0,0],[0,0]]\bigl\lbrack\bigl\lbrack0, 0\bigr\rbrack, \bigl\lbrack0, 0\bigr\rbrack\bigr\rbrack
About
Examples7
Checked againstWolfram Language 6 agree1 differ
CrosswalkWolfram Language