tempusSystem Class TimeHistoryVF
TimeHistoryVF is part of the WaveTrain system class library

TimeHistoryVF outputs a time-dependent Vector< float > given an input signal array sa having dimension (nx,nt) and corresponding time vector tv with dimension (nt). The output vector is chosen based on the current time; if the current time falls between two times in the time vector, the output vector is chosen by interpolating the input signal array (if sampleFlag = 0), or by sample-and-hold (if sampleFlag != 0). The parameter t0 defines the start time in the time vector, so that at simulation time t = 0.0 s, the output vector will be that for tv = t0. Also, the input time vector may be defined such that the time history does not begin until t > 0.0 s, and in prior times the initial vector s0 is used. If the time vector ends before the end of the simulation, the last vector is held throughout the remainder of the simulation.

Tempus Block Diagram Editor Snapshot
Parameters
tv  Vector<double>   Time vector, length nt (s)   Vector()
sa  Array<float>   Signal array, dimensioned nx * nt   Array()
t0  double   The time within the tv vector that is to correspond to simulation time t=0.0 (s)   0.0
s0  Vector<float>   Default signal vector before initial time   Vector()
sampleFlag  int   Sample flag (0 = interpolate; 1 = sample and hold)   0
Inputs
None
Outputs
s  Vector<float>   Output signal vector, length nx Vector()  
Subsystems


Last Saved: Wed Feb 13 12:18:59 MST 2008 by TVE version 2007B