TOpenCLValue.Frac Method

TOpenCLValue Frac(TOpenCLValue X)

Fractional part of values.

#NameTypeDescription
1XTOpenCLValuesource TOpenCLValue

Returns: TOpenCLValue

Remarks:

Calculates the fractional part of X.

Examples
using Dew.Math;
using Dew.Math.Units;

namespace Dew.Examples
{
    void Example()
    {
        TOpenCLValue a,b;
        clMtxVec.CreateIt(out a, out b);
        try
        {
            b.Copy(2.3);
            a.Frac(b);  // a = 0.3
        }
        finally
        {
            clMtxVec.FreeIt(ref a, ref b);
        }
    }
}
See Also: TOpenCLValue.Trunc, TOpenCLValue.Round