Overload List
| # | Signature | Description |
|---|---|---|
| 1 | void CartToPolar(TOpenCLMtxVec AmpltVec, TOpenCLMtxVec PhaseVec) | Converts elements from cartesian to polar coordinate form. |
| 2 | void CartToPolar(TOpenCLMtxVec AmpltVec, TOpenCLMtxVec PhaseVec, Int32 AmpltIndex, Int32 PhaseIndex, Int32 Index, Int32 Len) | Convert calling object elements [Index] to [Index+Len-1] from cartesian to polar form. |
Overload 1: void CartToPolar(TOpenCLMtxVec AmpltVec, TOpenCLMtxVec PhaseVec)
Converts elements from cartesian to polar coordinate form.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | AmpltVec | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | PhaseVec | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
Result: stored in self (calling object)
Converts all calling object elements from cartesian to polar coordinate form, storing the magnitude (radius) component of corresponding elements in the AmpltVec and the phase (angle) component of corresponding elements in the PhaseVec. If you want to use this method then the calling matrix Dew.Math.TOpenCLBase.Complex property must be true. If this is not the case, an exception is raised. Size and Dew.Math.TOpenCLBase.Complex properties of AmpltVec and PhaseVec are set automatically.
clVector A;
clVector Amplt;
clVector Phase;
A.CopyCplxFromArray(TSingleArray.Create(1,0, 2,0, 2,0 4,1)); // 4, complex matrix
A.CartToPolar(Amplt,Phase);
Overload 2: void CartToPolar(TOpenCLMtxVec AmpltVec, TOpenCLMtxVec PhaseVec, Int32 AmpltIndex, Int32 PhaseIndex, Int32 Index, Int32 Len)
Convert calling object elements [Index] to [Index+Len-1] from cartesian to polar form.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | AmpltVec | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 2 | PhaseVec | TOpenCLMtxVec | source TOpenCLVector or TOpenCLMatrix |
| 3 | AmpltIndex | Int32 | |
| 4 | PhaseIndex | Int32 | |
| 5 | Index | Int32 | start index |
| 6 | Len | Int32 | element count |
Result: stored in self (calling object)
Store the results in AmpltVec (radius values) and PhaseVec(phase values). Size and Dew.Math.TOpenCLBase.Complex properties of the calling vector must be set explicitly. An exception is raised if array borders are overrun or underrun.