Company Events Academic NI Developer Zone Support Solutions Products & Services Contact NI MyNI

Resample Waveforms (single shot) (Not in Base Package)

LabVIEW 8.2 Help
August 2006

NI Part Number:
371361B-01

»View Product Info

Resamples input waveforms or data according to the user-defined t0 and dt values. The data type you wire to the waveform or data input determines the polymorphic instance to use. Example

Use the pull-down menu to select an instance of this VI.

Resample Waveform (single shot)

open interval? defines the interval over which the VI resamples the input waveform. The default is FALSE, which selects a closed interval. For example, assume an input waveform contains 3 data elements at t = {0, dt, 2dt}. An open interval yields resampled data over the time interval 0 t < 2dt, and a closed interval yields resampled data over the time interval 0 t < 3dt.
waveform in is a waveform to align.
dt is the user-defined sampling interval for resampled waveform out.
t0 is the user-defined time stamp value for resampled waveform out.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
FIR filter specifications specifies the minimum values this VI needs to specify the FIR filter.
alias rejection (dB) specifies the minimum attenuation level of signal components aliased after any resampling operation. The default is 120.
normalized bandwidth specifies the fraction of the new sampling rate that is not attenuated. The default is 0.4536.
resampled waveform out contains the resampled waveform.
used t0 returns the actual time stamp of resampled waveform out.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warning returns TRUE if used t0 does not equal t0.

Resample N Waveforms (single shot)

Resamples waveforms in according to the user-defined t0 and dt values.

open interval? defines the interval over which the VI resamples the input waveform. The default is FALSE, which selects a closed interval. For example, assume an input waveform contains 3 data elements at t = {0, dt, 2dt}. An open interval yields resampled data over the time interval 0 t < 2dt, and a closed interval yields resampled data over the time interval 0 t < 3dt.
waveforms in is an array of waveforms to align.
dt is the user-defined sampling interval for resampled waveforms out.
t0 is the user-defined time stamp value for resampled waveforms out.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
FIR filter specifications specifies the minimum values this VI needs to specify the FIR filter.
alias rejection (dB) specifies the minimum attenuation level of signal components aliased after any resampling operation. The default is 120.
normalized bandwidth specifies the fraction of the new sampling rate that is not attenuated. The default is 0.4536.
resampled waveforms out returns an array containing the resampled waveforms.
used t0's returns the array of actual time stamps for resampled waveforms out.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warnings returns TRUE in each element of the array where the corresponding used t0's element does not equal t0.

Resample Array of Pairs (single shot)

Resamples the input waveform represented by XY-data in according to the user-defined t0 and dt values. This VI does not assume any signal history. Use this VI to resample a finite-length, unevenly-sampled signal that is considered complete.

XY-data in is the array of XY pairs representing the signal to resample.
x is the X component of the XY pair.
y is the Y component of the XY pair.
dt is the user-defined sampling interval for resampled waveform out.
t0 is the user-defined time stamp value for resampled waveform out. If t0 is less than the first X value of XY-data in, the value is adjusted.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
resampled waveform out contains the resampled waveform.
XY-data out is the array of XY pairs containing the resampled signal.
x is the X component of the XY pair.
y is the Y component of the XY pair.
used t0 returns the actual time stamp of resampled waveform out and also is the first X value of XY-data out. If t0 is less than the first X value of XY-data in, used t0 is the lowest value greater than t0 that fulfills the following equation.

used t0 = t0 + n*dt

where n is an integer.

error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warning returns TRUE if used t0 does not equal t0.

Resample Pair of Arrays (single shot)

Resamples the input waveform represented by XY-data in according to the user-defined t0 and dt values. This VI does not assume any signal history. Use this VI to resample a finite-length, non-evenly sampled signal that is considered complete.

XY-data in is a pair of X and Y arrays that represents the signal to resample.
X-array is the array of x values.
Y-array is the array of y values.
dt is the user-defined sampling interval for resampled waveform out.
t0 is the user-defined time stamp value for resampled waveform out. If t0 is less than the first X value of XY-data in, the value is adjusted.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
resampled waveform out contains the resampled waveform.
XY-data out is the pair of X and Y arrays containing the resampled signal.
X-array is the array of x values.
Y-array is the array of y values.
used t0 returns the actual time stamp of resampled waveform out and also is the first X value of XY-data out. If t0 is less than the first X value of XY-data in, used t0 is the lowest value greater than t0 that fulfills the following equation.

used t0 = t0 + n*dt

where n is an integer.

error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warning returns TRUE if used t0 does not equal t0.

Resample N Arrays of Pairs (single shot)

Resamples the input waveforms represented by Multiple XY-data in according to the user-defined t0 and dt values. This VI does not assume any signal history. Use this VI to resample finite-length, unevenly-sampled signals that are considered complete.

Multiple XY-data in is an array of clusters containing arrays of XY pairs representing the signals to resample.
XY-data in is the array of XY pairs representing the signal to resample.
x is the X component of the XY pair.
y is the Y component of the XY pair.
dt is the user-defined sampling interval for resampled waveforms out.
t0 is the user-defined time stamp value for resampled waveforms out. If t0 is less than the first X value of Multiple XY-data in, the value is adjusted.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
resampled waveforms out returns an array containing the resampled waveforms.
Multiple XY-data out is the array of arrays of XY pairs containing the resampled signals.
XY-data out is the array of XY pairs containing the resampled signal.
x is the X component of the XY pair.
y is the Y component of the XY pair.
used t0's returns the array of actual time stamps for resampled waveforms out. The time stamps are also the first X values in Multiple XY-data out. For each element of Multiple XY-data in, if t0 is less than the first X value (x0) of that element, the corresponding element value of used t0's is the lowest value greater than x0 that also fulfills the following equation.

used t0 = t0 + n*dt

where n is an integer.

error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warnings returns TRUE in each element of the array where the corresponding used t0's element does not equal t0.

Resample N Pairs of Arrays (single shot)

Resamples the input waveforms represented by Multiple XY-data in according to the user-defined t0 and dt values. This VI does not assume any signal history. Use this VI to resample finite-length, non-evenly sampled signals that are considered complete.

Multiple XY-data in is the array of pairs of X and Y arrays representing the waveforms to resample.
X-array is the array of x values.
Y-array is the array of y values.
dt is the user-defined sampling interval for resampled waveforms out.
t0 is the user-defined time stamp value for resampled waveforms out. If t0 is less than the first X value of Multiple XY-data in, the value is adjusted.
interpolation mode specifies the resampling algorithm used for the resampling.

0Coerce—Specifies that each output sample is set equal to the input sample value that is closest to it in time.
1Linear—(Default) Specifies that each output sample value is a linear interpolation between the two input samples that are closest to it in time.
2Spline—Specifies that this VI uses the spline interpolation algorithm to compute the resampled values.
3FIR filter—Specifies that this VI uses a finite impulse response (FIR) filtering algorithm to compute the resampled values.
error in describes error conditions that occur before this VI or function runs. The default is no error. If an error occurred before this VI or function runs, the VI or function passes the error in value to error out. This VI or function runs normally only if no error occurred before this VI or function runs. If an error occurs while this VI or function runs, it runs normally and sets its own error status in error out. Use the Simple Error Handler or General Error Handler VIs to display the description of the error code. Use error in and error out to check errors and to specify execution order by wiring error out from one node to error in of the next node.
status is TRUE (X) if an error occurred before this VI or function ran or FALSE (checkmark) to indicate a warning or that no error occurred before this VI or function ran. The default is FALSE.
code is the error or warning code. The default is 0. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source specifies the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning. The default is an empty string.
resampled waveforms out returns an array containing the resampled waveforms.
Multiple XY-data out is the array of pairs of X and Y arrays containing the resampled waveforms.
X-array is the array of x values.
Y-array is the array of y values.
used t0's returns the array of actual time stamps for resampled waveforms out.
error out contains error information. If error in indicates that an error occurred before this VI or function ran, error out contains the same error information. Otherwise, it describes the error status that this VI or function produces. Right-click the error out front panel indicator and select Explain Error from the shortcut menu for more information about the error.
status is TRUE (X) if an error occurred or FALSE (checkmark) to indicate a warning or that no error occurred.
code is the error or warning code. If status is TRUE, code is a nonzero error code. If status is FALSE, code is 0 or a warning code.
source describes the origin of the error or warning and is, in most cases, the name of the VI or function that produced the error or warning.
t0 adjusted warnings returns TRUE in each element of the array where the corresponding used t0's element does not equal t0.

Example

Refer to the Resampling a Waveform (single-shot) VI in the labview\examples\measure\resample_align_xmpl.llb for an example of using the Resample Waveforms (single shot) VI.

 


Resources


 

Your Feedback! poor Poor  |  Excellent excellent   Yes No
 Document Quality? 
 Answered Your Question? 
Add Comments 1 2 3 4 5 submit