void SinCos(TOpenCLValue SinX, TOpenCLValue CosX)
Sine and cosine.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | SinX | TOpenCLValue | source TOpenCLValue |
| 2 | CosX | TOpenCLValue | source TOpenCLValue |
Result: stored in self (calling object)
Remarks:
Calculates the sine and cosine of the value stored in the calling object. FloatPrecision and Dew.Math.TOpenCLBase.Complex property of SinX and CosX are adjusted automatically.
Note
Use this method if you require both sine and cosine.
Examples
using Dew.Math;
using Dew.Math.Units;
namespace Dew.Examples
{
void Example()
{
TOpenCLValue a,s,v;
MtxVec.CreateIt(out a, out s, out c);
try
{
a.Copy(0);
a.SinCos(s,c); // s=[0], c =[1]
}
finally
{
MtxVec.FreeIt(ref a, ref s, ref c);
}
}
}
See Also: TOpenCLValue.Sin, TOpenCLValue.Cos