
- Bob Seger
public class final float from<Base>
float
float Methods
Compiler |
Global |
Instance |
Description |
- |
- |
Constructor for the 'float' class to initialize with a float value | |
- |
- |
Constructor for the 'float' class to initialize with an int value | |
| - | - | float() | Constructor for the 'float' class to initialize with a string value |
| Returns a string representation of the float value with formatting options | |||
| Returns an integer representation of the floating point number value | |||
| CompilerFloatValidInt() | FloatValidInt() | ValidInt() | Returns true if the float value fits within valid int range |
| CompilerInc() | Inc() | Inc() | Increments the float value and returns the result |
| CompilerDec() | Dec() | Dec() | Decrements the float value and returns the result |
| CompilerAdd() | Add() | Add() | Adds a value to the float value and returns the result |
| CompilerSub() | Sub() | Sub() | Subtracts a value from the float value and returns the result |
| CompilerMult() | Mult() | Mult() | Multiplies the float value by a specified value and returns the result |
| CompilerDiv() | Div() | Div() | Divides the float value by a specified value and returns the result |
| CompilerMod() | Mod() | Mod() | Divides the float value by a specified value and returns the remainder |
| Raises the float value to a specified power and returns the result | |||
| CompilerAbs() | Abs() | Abs() | Takes the absolute vaue of the float value and returns the result |
| CompilerFrac() | Frac() | Frac() | Returns the fractional part of the float value |
| CompilerRound() | Round() | Round() | Returns the float value rounded to the nearest whole number |
| CompilerFloor() | Floor() | Floor() | Returns largest whole number not greater than the float value |
| CompilerCeiling() | Ceiling() | Ceiling() | Returns the smallest whole number not less than the float value |
| CompilerLn() | Ln() | Ln() | Returns the natural log of the float value |
| CompilerLog() | Log() | Log() | Returns the base 10 log of the float value |
| CompilerExp() | Exp() | Exp() | Returns the result of 'e' raised to the power specified by the float value |
| CompilerSqrt() | Sqrt() | Sqrt() | Returns the square root of the float value |
| CompilerSquare() | Square() | Square() | Returns the float value squared |
| CompilerSin() | Sin() | Sin() | Returns the sine of the float value (radians or degrees) |
| CompilerCos() | Cos() | Cos() | Returns the cosine of the float value (radians or degrees) |
| CompilerTan() | Tan() | Tan() | Returns the tangent of the float value (radians or degrees) |
| CompilerArcSin() | ArcSin() | ArcSin() | Returns the angle whose sine is the float value (radians or degrees) |
| CompilerArcCos() | ArcCos() | ArcCos() | Returns the angle whose cosine is the float value (radians or degrees) |
| CompilerArcTan() | ArcTan() | ArcTan() | Returns the angle whose tangent is the float value (radians or degrees) |
| CompilerDegRad() | DegRad() | DegRad() | Converts the float value from degrees to radians and returns the result |
| CompilerRadDeg() | RadDeg() | RadDeg() | Converts the float value from radians to degrees and returns the result |
| CompilerValidFloat32() | ValidFloat32() | ValidFloat32() | Returns true if float value is in range of a valid four byte floating point value |
float Constants
| Constant Data Item | Data Type | Value |
| float.MaxValue | float | +1.79769E+308 |
| float.MaxValue32 | float | +3.40282E+38 |
| float.MaxValue64 | float | +1.79769E+308 |
| float.MinValue | float | -1.79769E+308 |
| float.MinValue32 | float | -3.40282E+38 |
| float.MinValue64 | float | -1.79769E+308 |
| float.E | float | 2.718281828459045 |
| float.Pi | float | 3.141592653589793 |
| float.Size | int | 8 |
| float.Size32 | int | 4 |
| float.Size64 | int | 8 |
Derived Classes
NONE
See Also
Class Hierarchy, Primitive Framework, int, string, bool, Enumerations, MathException
public method float(float InitValue = 0.0)
Parameters
InitValue
Initial value for the float object, with a default of zero.
Return Value
None
Description
This is one of the constructors for the 'float' class, invoked automatically by the VM during dynamic allocation of a floating point object, if the constructor arguments match this method. It is only available for dynamic allocation and not for initialization of floating point variables.
This particular constructor takes a floating point number as a parameter to initialize the object. A default of zero is used if the parameter is not provided.
float Class
public method float(int InitValue)
Parameters
InitValue
Initial value for the float object as an integer
Return Value
None
Description
This is one of the constructors for the 'float' class, invoked automatically by the VM during dynamic allocation of a floating point object, if the constructor arguments match this method. It is only available for dynamic allocation and not for initialization of floating point variables.
This particular constructor takes an int as a parameter to initialize the object. The integer is converted to a float and the object is initialized with that value.
float Class
public method float(string InitValue)
Parameters
InitValue
Initial value for the float object as a string
Return Value
None
Description
This is one of the constructors for the 'float' class, invoked automatically by the VM during dynamic allocation of a floating point object, if the constructor arguments match this method. It is only available for dynamic allocation and not for initialization of floating point variables.
This particular constructor takes a string as a parameter to initialize the object. The string is converted to a float (zero if error) and the object is initialized with that value.
float Class
public method<string> Str(string Format = "F.2")
Parameters
Format
Format string to control size and value of the resulting string with a default of "F.2"
Return Value
Returns the string representation of the float
Description
This instance method converts the internal floating point value into a string based on the specified format string. The format string is a combination of a single letter and an optional "number1.number2" (e.g. "F", "F10.2", "F.3", "F6").
The letter is used to indicate how the float is represented, and can be entered as lowercase or uppercase.
- 'F' for normal floating point (1000.0)
- 'E' for exponential (1.0E03)
The first number specifies the length of the string and the second number specified the number of places after the decimal point. If no length is specified, the "natural length" is used based on the size of the float value and the number of places after the decimal point (e.g. an float value of "100.00" and two decimal places has a natural length of 6). If the length is specified and it exceeds the natural length, the return string will be padded with spaces at the end.
float Class
public method<string> FloatStr(float Value,string Format = "F.2")
Parameters
Value
Float value to be converted to a string
Format
Format string to control size and value of the resulting string with a default of "F.2"
Return Value
Returns the string representation of the float
Description
This global method converts the specified floating point value into a string based on the specified format string. Refer to the description of the 'float.Str()' method for a description of the the syntax rules for the format string.
Global Method
public method<string> compiler CompilerFloatStr(float Value,string Format = "F.2")
Parameters
Value
Float value to be converted to a string
Format
Format string to control size and value of the resulting string with a default of "F.2"
Return Value
Returns the string representation of the float
Description
This compiler method converts the specified floating point value into a string based on the specified format string. Refer to the description of the 'float.Str()' method for a description of the the syntax rules for the format string.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<int> Int()
Parameters
None
Return Value
Returns the integer representation of the float
Description
This instance method converts the internal floating point value into an integer value and returns it. Any decimal portion is truncated.
If the floating point value is greater than the max int value, then it returns the max int value. If the float is less than the min int value, it returns the min int value.
float Class
public method<int> FloatInt(float Value)
Parameters
Value
Float value to be converted to an int
Return Value
Returns the integer representation of the float
Description
This global method converts the specified floating point value into an integer value and returns it. Any decimal portion is truncated.
If the floating point value is greater than the max int value, then it returns the max int value. If the float is less than the min int value, it returns the min int value.
Global Method
public method<int> compiler CompilerFloatInt(float Value)
Parameters
Value
Float value to be converted to an int
Return Value
Returns the integer representation of the float
Description
This compiler method converts the specified floating point value into an integer value and returns it. Any decimal portion is truncated.
If the floating point value is greater than the max int value, then it returns the max int value. If the float is less than the min int value, it returns the min int value.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<bool> ValidInt()
Parameters
None
Return Value
Returns true if the float is a valid int
Description
This instance method attempts to convert the internal floating point value into an integer value. If the float value is within the valid range of an int, it returns true. If not, it returns false.
float Class
public method<bool> FloatValidInt(float Value)
Parameters
Value
Float value to be tested as an int
Return Value
Returns true if the float is a valid int
Description
This global method attempts to convert the specifiedl floating point value into an integer value. If the float value is within the valid range of an int, it returns true. If not, it returns false.
Global Method
public method<bool> compiler CompilerFloatValidInt(float Value)
Parameters
Value
Float value to be tested as an int
Return Value
Returns true if the float is a valid int
Description
This compiler method attempts to convert the specifiedl floating point value into an integer value. If the float value is within the valid range of an int, it returns true. If not, it returns false.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Inc()
Parameters
None
Return Value
Returns the result of the increment operation
Description
This instance method increments the internal floating point object and returns the result. This operation modifies the internal float object. If the operation would cause an overflow, an OverflowException event is fired.
float Class
public method<float> Inc(float Value)
Parameters
Value
Float value to be incremented
Return Value
Returns the result of the increment operation
Description
This global method increments the specified floating point value and returns the result. This operation does not modify the source float object. If the operation would cause an overflow, an OverflowException event is fired.
Global Method
public method<float> compiler CompilerInc(float ref Value)
Parameters
Value
Reference to float object to receive the incremented value
Return Value
Returns the result of the increment operation
Description
This compiler method increments the float value specified by the float reference and returns the result. This operation modifies the source float object. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Dec()
Parameters
None
Return Value
Returns the result of the decrement operation
Description
This instance method decrements the internal floating point object and returns the result. This operation modifies the internal float object. If the operation would cause a negative overflow, an OverflowException event is fired.
float Class
public method<float> Dec(float Value)
Parameters
Value
Float value to be decremented
Return Value
Returns the result of the decrement operation
Description
This global method decrements the specified floating point value and returns the result. This operation does not modify the source float object. If the operation would cause a negative overflow, an OverflowException event is fired.
Global Method
public method<float> compiler CompilerDec(float ref Value)
Parameters
Value
Reference to float object to receive the decremented value
Return Value
Returns the result of the decrement operation
Description
This compiler method decrements the float value specified by the float reference and returns the result. This operation modifies the source float object. If the operation would cause a negative overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Add(float Value)
Parameters
Value
Float value to be added to the internal float object
Return Value
Returns the result of the addition operation
Description
This instance method adds the specified value to the internal floating point value and returns the result. This operation modifies the internal float object. If the operation would cause an overflow, an OverflowException event is fired.
float Class
public method<float> Add(float Value1,float Value2)
Parameters
Value1
Float value to be used in the addition
Value2
Float value to be used in the addition
Return Value
Returns the result of the addition operation
Description
This global method adds the two incoming floating point values and returns the result. This operation does not modify the source float objects. If the operation would cause an overflow, an OverflowException event is fired.
This method emulates the '+' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerAdd(float ref Value1,float Value2)
Parameters
Value1
Reference to float object to be used in addition
Value2
Float value to be used in the addition
Return Value
Returns the result of the addition operation
Description
This compiler method adds the two incoming floating point values and returns the result. This operation also modifies the floating point object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Sub(float Value)
Parameters
Value
Float value to be subtracted from the internal float object
Return Value
Returns the result of the subtraction operation
Description
This instance method subtracts the specified value from the internal float value and returns the result. This operation modifies the internal floating point object. If the operation would cause an overflow, an OverflowException event is fired.
float Class
public method<float> Sub(float Value1,float Value2)
Parameters
Value1
Float value to be used in the subtraction
Value2
Float value to be used in the subtraction
Return Value
Returns the result of the subtraction operation
Description
This global method subtracts Value2 from Value1 and returns the result. This operation does not modify the source float objects. If the operation would cause an overflow, an OverflowException event is fired.
This method emulates the '-' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerSub(float ref Value1,float Value2)
Parameters
Value1
Reference to float object to be used in the subtraction
Value2
Float value to be used in the subtraction
Return Value
Returns the result of the subtraction operation
Description
This compiler method subtracts Value2 from the object referenced by Value1 and returns the result. This operation also modifies the floating point object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Mult(float Value)
Parameters
Value
Float value to multiply the internal float object by
Return Value
Returns the result of the multiplication operation
Description
This instance method multiplies the internal float value by the specified value and returns the result. This operation modifies the internal float object. If the operation would cause an overflow, an OverflowException event is fired.
float Class
public method<float> Mult(float Value1, float Value2)
Parameters
Value1
Float value to be used in the multiplication
Value2
Float value to be used in the multiplication
Return Value
Returns the result of the multiplication operation
Description
This global method multiplies the two incoming float values and returns the result. This operation does not modify the source float objects. If the operation would cause an overflow, an OverflowException event is fired.
This method emulates the '*' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerMult(float ref Value1, float Value2)
Parameters
Value1
Reference to float object to be used in the multiplication
Value2
Float value to be used in the multiplication
Return Value
Returns the result of the multiplication operation
Description
This compiler method multiplies the two incoming float values and returns the result. This operation also modifies the float object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Div(float Value)
Parameters
Value
Float value to divide the internal integer object by
Return Value
Returns the result of the division operation
Description
This instance method divides the internal float value by the specified value and returns the result. This operation modifies the internal float object. If the operation would cause a divide by zero, a DivByZeroException event is fired.
float Class
public method<float> Div(float Value1, float Value2)
Parameters
Value1
Float value to be used in the division
Value2
Float value to be used in the division
Return Value
Returns the result of the division operation
Description
This global method divides the first float value by the second float value and returns the result. This operation does not modify the source float objects. If the operation would cause a divide by zero, a DivByZeroException event is fired.
This method emulates the '/' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerDiv(float ref Value1, float Value2)
Parameters
Value1
Reference tothe float object to be used in the division
Value2
Float value to be used in the division
Return Value
Returns the result of the division operation
Description
This compiler method divides the first float value by the second float value and returns the result. This operation also modifies the float object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Mod(float Value)
Parameters
Value
Float value to divide the internal float object by
Return Value
Returns the modulus (remainder) of the division operation
Description
This instance method divides the internal float value by the specified value and returns the remainder as the result. This operation modifies the internal float object. If the operation would cause a divide by zero, a DivByZeroException event is fired.
float Class
public method<float> Mod(float Value1, float Value2)
Parameters
Value1
Float value to be used in the division
Value2
Float value to be used in the division
Return Value
Returns the modulus (remainder) of the division operation
Description
This global method divides the first float value by the second float value and returns the remainder of the result. This operation does not modify the source float objects. If the operation would cause a divide by zero, a DivByZeroException event is fired.
This method emulates the '%' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerMod(float ref Value1, float Value2)
Parameters
Value1
Reference to float object to be used in the division
Value2
Float value to be used in the division
Return Value
Returns the modulus (remainder) of the division operation
Description
This compiler method divides the first float value by the second float value and returns the remainder of the result. This operation also modifies the float object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Pow(float Value)
Parameters
Value
Float value to use as exponent in power operation
Return Value
Returns the result of the exponentation operation
Description
This instance method raises the internal float value to the power specified by Value and returns the result. This operation modifies the internal float object. If the operation would cause an overflow, an OverflowException event is fired.
float Class
public method<float> Pow(float Value1, float Value2)
Parameters
Value1
Float value to use as base in power operation
Value2
Float value to use as exponent in power operation
Return Value
Returns the result of the exponentation operation
Description
This global method raises the first float value to the power of the second float. This operation does not modify the source float objects. If the operation would cause an overflow, an OverflowException event is fired.
This method emulates the '**' operator, and is included mainly for consistency and completeness.
Global Method
public method<float> compiler CompilerPow(float ref Value1, float Value2)
Parameters
Value1
Reference to float object to use as base in power operation
Value2
Float value to use as exponent in power operation
Return Value
Returns the result of the exponentation operation
Description
This compiler method raises the first float value to the power of the second float. This operation also modifies the float object referenced by Value1 with the new value. If the operation would cause an overflow, the operation is not performed.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Abs()
Parameters
None
Return Value
Returns the absolute value of the float object
Description
This instance method takes the absolute value of the internal float value and returns the result. This operation modifies the internal float object.
float Class
public method<float> Abs(float Value)
Parameters
Value
Source float for absolute value operation
Return Value
Returns the absolute value of the float object
Description
This global method takes the absolute value of the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerAbs(float Value)
Parameters
Value
Source float for absolute value operation
Return Value
Returns the absolute value of the float object
Description
This compiler method takes the absolute value of the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Frac()
Parameters
None
Return Value
Returns the fractional portion of the float object
Description
This instance method takes the fractional portion of the internal float value and returns the result. This operation modifies the internal float object.
float Class
public method<float> Frac(float Value)
Parameters
Value
Source float to extract fraction from
Return Value
Returns the fractional portion of the float object
Description
This global method takes the fractional portion of the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerFrac(float Value)
Parameters
Value
Source float to extract fraction from
Return Value
Returns the fractional portion of the float object
Description
This compiler method takes the fractional portion of the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Round()
Parameters
None
Return Value
Returns the rounded result
Description
This instance method rounds the internal float value to the nearest whole number and returns the result. This operation modifies the internal float object.
float Class
public method<float> Round(float Value)
Parameters
Value
Source float to round
Return Value
Returns the rounded result
Description
This global method rounds the specified float value to the nearest whole number and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerRound(float Value)
Parameters
Value
Source float to round
Return Value
Returns the rounded result
Description
This compiler method rounds the specified float value to the nearest whole number and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Floor()
Parameters
None
Return Value
Returns the result of the Floor operation
Description
This instance method determines the largest whole number which is less than or equal to the internal float value and returns the result. This operation modifies the internal float object.
float Class
public method<float> Floor(float Value)
Parameters
Value
Source float to get floor from
Return Value
Returns the result of the Floor operation
Description
This global method determines the largest whole number which is less than or equal to the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerFloor(float Value)
Parameters
Value
Source float to get floor from
Return Value
Returns the result of the Floor operation
Description
This compiler method determines the largest whole number which is less than or equal to the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Ceiling()
Parameters
None
Return Value
Returns the result of the Ceiling operation
Description
This instance method determines the smallest whole number which is greater than or equal to the internal float value and returns the result. This operation modifies the internal float object.
float Class
public method<float> Ceiling(float Value)
Parameters
Value
Source float to get ceiling from
Return Value
Returns the result of the Ceiling operation
Description
This global method determines the smallest whole number which is greater than or equal to the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerCeiling(float Value)
Parameters
Value
Source float to get ceiling from
Return Value
Returns the result of the Ceiling operation
Description
This compiler method determines the smallest whole number which is greater than or equal to the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Ln()
Parameters
None
Return Value
Returns the natural log of the float object
Description
This instance method takes the natural log (base 'e') of the internal float value and returns the result. This operation does not modify the internal float object.
The float value must be greater than zero. If zero, a DivByZeroException is fired, and if less than zero, a DomainException is fired.
float Class
public method<float> Ln(float Value)
Parameters
Value
Source float to take natural log of
Return Value
Returns the natural log of the float object
Description
This global method takes the natural log (base 'e') of the specified float value and returns the result. This operation does not modify the source float object.
The float value must be greater than zero. If zero, a DivByZeroException is fired, and if less than zero, a DomainException is fired.
Global Method
public method<float> compiler CompilerLn(float Value)
Parameters
Value
Source float to take natural log of
Return Value
Returns the natural log of the float object
Description
This compiler method takes the natural log (base 'e') of the specified float value and returns the result. This operation does not modify the source float object.
The float value must be greater than zero. If less than or equal to zero, the operation is not performed and a value of zero is returned.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Log()
Parameters
None
Return Value
Returns the base 10 log of the float object
Description
This instance method takes the logarithm (base 10) of the internal float value and returns the result. This operation does not modify the internal float object.
The float value must be greater than zero. If zero, a DivByZeroException is fired, and if less than zero, a DomainException is fired.
float Class
public method<float> Log(float Value)
Parameters
Value
Source float to take log of
Return Value
Returns the base 10 log of the float object
Description
This global method takes the logarithm (base 10) of the specified float value and returns the result. This operation does not modify the source float object.
The float value must be greater than zero. If zero, a DivByZeroException is fired, and if less than zero, a DomainException is fired.
Global Method
public method<float> compiler CompilerLog(float Value)
Parameters
Value
Source float to take log of
Return Value
Returns the base 10 log of the float object
Description
This compiler method takes the logarithm (base 10) of the specified float value and returns the result. This operation does not modify the source float object.
The float value must be greater than zero. If less than or equal to zero, the operation is not performed and a value of zero is returned.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Exp()
Parameters
None
Return Value
Returns the result of "e" raised to power of the float value
Description
This instance method raises the value of "e" (2.71828...) to the power specified by the internal float value and returns the result. This operation does not modify the internal float object.
This method will fire an OverflowException if the result exceeds the max valid float value.
float Class
public method<float> Exp(float Value)
Parameters
Value
Source float to represent exponent
Return Value
Returns the result of "e" raised to power of the float value
Description
This global method raises the value of "e" (2.71828...) to the power specified by the source float value and returns the result. This operation does not modify the source float object.
This method will fire an OverflowException if the result exceeds the max valid float value.
Global Method
public method<float> compiler CompilerExp(float Value)
Parameters
Value
Source float to represent exponent
Return Value
Returns the result of "e" raised to power of the float value
Description
This compiler method raises the value of "e" (2.71828...) to the power specified by the source float value and returns the result. This operation does not modify the source float object.
If the result would cause an overflow, a value of zero is returned.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Sqrt()
Parameters
None
Return Value
Returns the square root of the float object
Description
This instance method takes the square root of the internal float value and returns the result. This operation does not modify the internal float object.
float Class
public method<float> Sqrt(float Value)
Parameters
Value
Source float to take square root of
Return Value
Returns the square root of the float object
Description
This global method takes the square root of the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerSqrt(float Value)
Parameters
Value
Source float to take square root of
Return Value
Returns the square root of the float object
Description
This compiler method takes the square root of the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Square()
Parameters
None
Return Value
Returns the square of the float object
Description
This instance method performs a square operation (Value**2) with the internal float value and returns the result. This operation does not modify the internal float object.
float Class
public method<float> Square(float Value)
Parameters
Value
Source float to take square root of
Return Value
Returns the square root of the float object
Description
This global method performs a square operation (Value**2) with the specified float value and returns the result. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerSquare(float Value)
Parameters
Value
Source float to take square root of
Return Value
Returns the square root of the float object
Description
This compiler method performs a square operation (Value**2) with the specified float value and returns the result. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Sin(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the sine of the angle specified by the float object
Description
This instance method takes the sine of the angle specified by the internal float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the internal float object.
float Class
public method<float> Sin(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take sine of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the sine of the angle specified by the float object
Description
This global method takes the sine of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerSin(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take sine of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the sine of the angle specified by the float object
Description
This compiler method takes the sine of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Cos(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the cosine of the angle specified by the float object
Description
This instance method takes the cosine of the angle specified by the internal float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the internal float object.
float Class
public method<float> Cos(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take cosine of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the cosine of the angle specified by the float object
Description
This global method takes the cosine of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerCos(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take cosine of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the cosine of the angle specified by the float object
Description
This compiler method takes the cosine of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> Tan(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the tangent of the angle specified by the float object
Description
This instance method takes the tangent of the angle specified by the internal float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the internal float object.
float Class
public method<float> Tan(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take tangent of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the tangent of the angle specified by the float object
Description
This global method takes the tangent of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerTan(float Value, bool IsDegrees = false)
Parameters
Value
Source angle to take tangent of
IsDegrees
Flag to specify how to interpret the angle (degrees/radians)
Return Value
Returns the tangent of the angle specified by the float object
Description
This compiler method takes the tangent of the angle specified by the source float value and returns the result. If the 'IsDegrees' flag is false (default), the angle is specified in radians. If 'IsDegrees' is true, the angle is specified in degrees. This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> ArcSin(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose sine value is specified by the float object
Description
This instance method analyzes the current value of the floating point object and returns the angle whose sine value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid sine value (0 to 1), this method will fire a math domain exception.
float Class
public method<float> ArcSin(float Value, bool IsDegrees = false)
Parameters
Value
Incoming sine value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose sine value is specified by the float object
Description
This global method analyzes the current value of the floating point object and returns the angle whose sine value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid sine value (0 to 1), this method will fire a math domain exception.
Global Method
public method<float> compiler CompilerArcSin(float Value, bool IsDegrees = false)
Parameters
Value
Incoming sine value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose sine value is specified by the float object
Description
This compiler method analyzes the current value of the floating point object and returns the angle whose sine value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid sine value (0 to 1), this method will return a value of zero.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> ArcCos(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose cosine value is specified by the float object
Description
This instance method analyzes the current value of the floating point object and returns the angle whose cosine value matches the floating point value. The angle will always be between 0 and Pi radians or 0 and 180 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid cosine value (0 to 1), this method will fire a math domain exception.
float Class
public method<float> ArcCos(float Value, bool IsDegrees = false)
Parameters
Value
Incoming cosine value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose cosine value is specified by the float object
Description
This global method analyzes the current value of the floating point object and returns the angle whose cosine value matches the floating point value. The angle will always be between 0 and Pi radians or 0 and 180 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid cosine value (0 to 1), this method will fire a math domain exception.
Global Method
public method<float> compiler CompilerArcCos(float Value, bool IsDegrees = false)
Parameters
Value
Incoming cosine value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose cosine value is specified by the float object
Description
This compiler method analyzes the current value of the floating point object and returns the angle whose cosine value matches the floating point value. The angle will always be between 0 and Pi radians or 0 and 180 degrees, depending on the value of the "IsDegrees" flag. If the floating point value does not contain a valid cosine value (0 to 1), this method will return a value of zero.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> ArcTan(bool IsDegrees = false)
Parameters
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose tangent value is specified by the float object
Description
This instance method analyzes the current value of the floating point object and returns the angle whose tangent value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag.
float Class
public method<float> ArcTan(float Value, bool IsDegrees = false)
Parameters
Value
Incoming tangent value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose tangent value is specified by the float object
Description
This global method analyzes the current value of the floating point object and returns the angle whose tangent value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag.
Global Method
public method<float> compiler CompilerArcTan(float Value, bool IsDegrees = false)
Parameters
Value
Incoming tangent value
IsDegrees
Flag to specify what type of angle is returned (degrees/radians)
Return Value
Returns the angle whose tangent value is specified by the float object
Description
This compiler method analyzes the current value of the floating point object and returns the angle whose tangent value matches the floating point value. The angle will always be between (-Pi/2) and Pi/2 radians or -90 and 90 degrees, depending on the value of the "IsDegrees" flag.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> DegRad()
Parameters
None
Return Value
Returns the angle converted to radians
Description
This instance method converts the internal float value from degrees to radians and returns the result. The following conversion is performed:
radians = (degrees * Pi) / 180.0
This operation does not modify the internal float object.
float Class
public method<float> DegRad(float Angle)
Parameters
Angle
Source angle to convert to radians
Return Value
Returns the angle converted to radians
Description
This global method converts the specified float value from degrees to radians and returns the result. The following conversion is performed:
radians = (degrees * Pi) / 180.0
This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerDegRad(float Angle)
Parameters
Angle
Source angle to convert to radians
Return Value
Returns the angle converted to radians
Description
This compiler method converts the specified float value from degrees to radians and returns the result. The following conversion is performed:
radians = (degrees * Pi) / 180.0
This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<float> RadDeg()
Parameters
None
Return Value
Returns the angle converted to degrees
Description
This instance method converts the internal float value from radians to degrees and returns the result. The following conversion is performed:
degrees = (radians * 180.0) / Pi
This operation does not modify the internal float object.
float Class
public method<float> RadDeg(float Angle)
Parameters
Angle
Source angle to convert to degrees
Return Value
Returns the angle converted to degrees
Description
This global method converts the specified float value from radians to degrees and returns the result. The following conversion is performed:
degrees = (radians * 180.0) / Pi
This operation does not modify the source float object.
Global Method
public method<float> compiler CompilerRadDeg(float Angle)
Parameters
Angle
Source angle to convert to degrees
Return Value
Returns the angle converted to degrees
Description
This compiler method converts the specified float value from radians to degrees and returns the result. The following conversion is performed:
degrees = (radians * 180.0) / Pi
This operation does not modify the source float object.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method
public method<bool> ValidFloat32()
Parameters
None
Return Value
Returns true if the 64 bit floating point value is in range of a valid 32 bit floating point number
Description
This instance method compares the value of the 64 floating point to determine if it fits within the valid range of a 32 bit floating point number. The valid range for a 32 bit floating point number is approximately -3.40E+38 to +3.40E+38.
floatt Class
public method<bool> ValidFloat32(float Value)
Parameters
Value
Floating point value to use in the operation
Return Value
Returns true if the 64 bit floating point value is in range of a valid 32 bit floating point number
Description
This global method compares the value of the 64 floating point to determine if it fits within the valid range of a 32 bit floating point number. The valid range for a 32 bit floating point number is approximately -3.40E+38 to +3.40E+38.
Global Method
public method<bool> compiler CompilerValidFloat32(float Value)
Parameters
Value
Floating point value to use in the operation
Return Value
Returns true if the 64 bit floating point value is in range of a valid 32 bit floating point number
Description
This compiler method compares the value of the 64 floating point to determine if it fits within the valid range of a 32 bit floating point number. The valid range for a 32 bit floating point number is approximately -3.40E+38 to +3.40E+38.
Compiler methods can be used dynamically during the compile process at the module level, class level and inside compiler methods. Compiler methods cannot be called from normal (non-compiler) methods.
Compiler Method