Overload List
| # | Signature | Description |
|---|---|---|
| 1 | TOpenCLValue ThresholdGT(TOpenCLValue Vec, Double GTLevel, TCplx GTValue) | Perform "greater than" threshold operation for complex value in Vec. |
| 2 | TOpenCLValue ThresholdGT(TOpenCLValue Vec, Double GTLevel, Double GTValue) | Threshold greater than operation. |
Overload 1: TOpenCLValue ThresholdGT(TOpenCLValue Vec, Double GTLevel, TCplx GTValue)
Perform "greater than" threshold operation for complex value in Vec.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Vec | TOpenCLValue | source TOpenCLValue |
| 2 | GTLevel | Double | scalar |
| 3 | GTValue | TCplx | scalar |
Returns: TOpenCLValue
Remarks:
Store the result in the calling object. FloatPrecision and Dew.Math.TOpenCLBase.Complex properties of the calling object are adjusted automatically. If Vec value is not complex, an exception will be raised.
Overload 2: TOpenCLValue ThresholdGT(TOpenCLValue Vec, Double GTLevel, Double GTValue)
Threshold greater than operation.
| # | Name | Type | Description |
|---|---|---|---|
| 1 | Vec | TOpenCLValue | source TOpenCLValue |
| 2 | GTLevel | Double | scalar |
| 3 | GTValue | Double | scalar |
Returns: TOpenCLValue
Remarks:
Perform operation on Vec value. The GTValue parameter is an upper bound for threshold operation. Vec value bigger than LTLevel will be replaced with GTValue. For a complex number the comparison will be applied with the norm of the complex value.
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);
a.ThresholdGT(b, 1.3,1.5); // a = [1.5]
}
finally
{
clMtxVec.FreeIt(ref a, ref b);
}
}
}