Unit Functions

<< Click to Display Table of Contents >>

Navigation:  Problem Descriptor Reference > The Elements of a Descriptor > Built-in Functions >

Unit Functions

Previous pageReturn to chapter overviewNext page

The following unit-valued functions are supported in FlexPDE:

 

USTEP(arg)        

The unit step function requires one argument. USTEP is 1 where the argument is positive and 0 where the argument is negative.  For example, USTEP(x-x0) is a step function at x=x0.

 

UPULSE(arg1,arg2)

The unit pulse function requires two arguments. UPULSE is 1 where arg1 is positive and arg2 is negative and 0 everywhere else. UPULSE(t-t0, t-t1) is a pulse from t0 to t1 if t1>t0.  [Note: because instantaneous switches cause serious trouble in time dependent problems, the UPULSE function automatically ramps the rise and fall over 1% of the total pulse width.]

 

URAMP(arg1,arg2)        

The unit ramp function requires two arguments. URAMP is like UPULSE, except it builds a ramp instead of a rectangle. URAMP is 1 where arg1 and arg2 are both positive,  linearly interpolated between 0 and 1 when arg1 is positive and arg2 is negative, and 0 everywhere else.

 

 

Examples:

Samples | Usage | Unit_Functions.pde