Chapter 3 Analysis Library
© National Instruments Corporation 3-35 LabWindows/CVI Standard Libraries
Return Value
status integer Refer to error codes in
Table 3-2.
ToRect1D
int status = ToRect1D (double magnitude[], double phaseRadians[],
int numberofElements, double outputArrayReal[],
double outputArrayImaginary[]);
Purpose
Converts the set of polar coordinate points (magnitude, phaseRadians) to a set of rectangular
coordinate points (outputArrayReal, outputArrayImaginary). The function obtains the ith
element of the rectangular set by using the following formulas.
x mag phase
ii i
=∗cos( )
y mag phase
ii i
=∗sin( )
The function performs the operations in place; that is, outputArrayReal and magnitude, and
outputArrayImaginary and phaseRadians, can be the same arrays, respectively.
Parameters
Input magnitude double-precision
array Magnitude.
phaseRadians double-precision
array Phase (in radians).
numberofElements integer Number of elements.
Output outputArrayReal double-precision
array X coordinate.
outputArrayImaginary double-precision
array Y coordinate.
Return Value
status integer Refer to error codes in
Table 3-2.