Programming Reference for VirtualLab Fusion
2025.1
|
This struct defines a two-dimensional vector of long numbers. Operators \(a+b\), \(a-b\) and \(a|b\) (Scalar product) can be used. One operand on \(a*b\) and \(a/b\) can be an long too. More...
Public Member Functions | |
override string | ToString () |
Converts a VectorL into a string of format "(X; Y). | |
VectorL (long x, long y) | |
Creates a VectorL from two long values. | |
VectorL (Vector v) | |
Copy constructor for vector object. | |
VectorL (VectorL v) | |
Copy constructor. | |
Static Public Member Functions | |
static long | Max (Vector a) |
Returns the maximal component of a VectorL. | |
static | operator Vector (VectorL vector) |
Converts a VectorL object to a Vector object. | |
static implicit | operator VectorL (Vector vector) |
Implicitly converts a Vector object to a VectorL object. | |
static | operator VectorL (VectorD vector) |
Converts a VectorD object to a VectorL object. | |
static bool | operator!= (VectorL vector1, VectorL vector2) |
Compares two VectorL for inequality. The comparison will be done by comparing the values of the two x- and y-components respectively. | |
static VectorL | operator* (long factor, VectorL vector) |
Multiplies a VectorL object by a long value. | |
static VectorL | operator* (VectorL a, VectorL b) |
Multiplies two VectorL objects. | |
static VectorL | operator* (VectorL vector, long factor) |
Multiplies a VectorL object by a long value. | |
static VectorL | operator+ (VectorL a, VectorL b) |
Adds two VectorL objects. | |
static VectorL | operator- (VectorL a, VectorL b) |
Subtracts two VectorL objects. | |
static VectorL | operator/ (long number, VectorL vector) |
Performs a component-wise division of a long value and a VectorL object. The result is defined as new Vector(number / vector.X, number / vector.Y). | |
static VectorL | operator/ (VectorL a, VectorL b) |
Performs a component-wise division of two VectorL objects. | |
static VectorL | operator/ (VectorL vector, long divisor) |
Performs a component-wise division of a VectorL object and a long value. | |
static bool | operator== (VectorL vector1, VectorL vector2) |
Compares two VectorL for equality. The comparison will be done by comparing the values of the two x- and y-components respectively. | |
static long | operator| (VectorL a, VectorL b) |
Calculates the scalar product of two VectorL objects. | |
Properties | |
long | X [get, set] |
public property to set and get the X value of the Vector object. | |
long | Y [get, set] |
public property to set and get the Y value of the Vector object. | |
This struct defines a two-dimensional vector of long numbers. Operators \(a+b\), \(a-b\) and \(a|b\) (Scalar product) can be used. One operand on \(a*b\) and \(a/b\) can be an long too.
VectorL | ( | long | x, |
long | y | ||
) |
Creates a VectorL from two long values.
x | X value of new VectorL object. |
y | Y value of new VectorL object. |
|
static |
Returns the maximal component of a VectorL.
a | the VectorL to investigate |
Converts a VectorL object to a Vector object.
vector | VectorL object to be converted. |
Implicitly converts a Vector object to a VectorL object.
vector | Vector object to be converted. |
Converts a VectorD object to a VectorL object.
vector | VectorD object to be converted. |
Compares two VectorL for inequality. The comparison will be done by comparing the values of the two x- and y-components respectively.
vector1 | First VectorL object to compare. |
vector2 | Second VectorL object to compare. |
Multiplies a VectorL object by a long value.
///
factor | The long value to multiply. |
vector | The VectorL object to multiply. |
Multiplies two VectorL objects.
a | The first VectorL object to multiply. |
b | The second VectorL object to multiply. |
Multiplies a VectorL object by a long value.
vector | The VectorL object to multiply. |
factor | The long value to multiply. |
Adds two VectorL objects.
a | The first VectorL object to add. |
b | The second VectorL object to add. |
Subtracts two VectorL objects.
a | The first VectorL object to substract from. |
b | The second VectorL object to substract. |
Performs a component-wise division of a long value and a VectorL object. The result is defined as new Vector(number / vector.X, number / vector.Y).
number | The long value to divide by the components of the VectorL object. |
vector | The VectorL object used as divisor. |
Performs a component-wise division of two VectorL objects.
a | The first VectorL object to divide by parameter b. |
b | The second VectorL object used as divisor. |
Performs a component-wise division of a VectorL object and a long value.
vector | The VectorL object to divide by the long value. |
divisor | The long value used as divisor. |
Compares two VectorL for equality. The comparison will be done by comparing the values of the two x- and y-components respectively.
vector1 | First VectorL object to compare. |
vector2 | Second VectorL object to compare. |
Calculates the scalar product of two VectorL objects.
a | First VectorL object. |
b | Second VectorL object. |
override string ToString | ( | ) |
Converts a VectorL into a string of format "(X; Y).