| CVec Class |
Namespace: Microsoft.Research.Liquid
[<SerializableAttribute>] type CVec = class end
The CVec type exposes the following members.
| Name | Description | |
|---|---|---|
| CVec(UInt64, Boolean) |
Creates a new vector filled with zeroes.
| |
| CVec(Double, FSharpOptionDouble, FSharpOptionBoolean) |
Creates a new vector from initial value vectors, real and imaginary.
Note that the length of the new vector must be no more than 2^20.
| |
| CVec(UInt64, FSharpOptionDouble, FSharpOptionDouble, FSharpOptionBoolean) |
Creates a new vector.
By default, the vector is all zero.
Optionally, the real and impaginary initial values may be provided;
in this case, the vector must be no more than 2^20 in length.
|
| Name | Description | |
|---|---|---|
| iSafe |
Gets the imaginary part of an element of this vector by index.
| |
| Length |
The length of this vector
| |
| rSafe |
Gets the real part of an element of this vector by index.
| |
| Safe |
Gets an element of this vector by index.
|
| Name | Description | |
|---|---|---|
| AddMCC |
Calculates the norm of this vector.
The norm is the square root of the sum of the complex magnitudes of the vector elements.
| |
| Copy |
Creates an exact copy of this vector.
| |
| Dump |
Dumps this vector using the provided function.
| |
| DumpMCC |
Dump vector MCC with provided function
| |
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
| GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
| GetType | Gets the Type of the current instance. (Inherited from Object.) | |
| GlobalPhase |
Estimates the global phase of a vector that represents a quantum state.
The estimate is computed as the complex phase of the vector element with
the greatest amplitude.
| |
| Kron |
Computes the Kronecker product of this vector and another.
| |
| NonZeros |
Gets non-zero indices upto a max count
| |
| Normalize |
Normalizes this vector to length 1.0.
| |
| Read |
Reads a new vector from a binary file.
Note that this routine is only intended to read vectors written with the
Write method.
| |
| Scale |
Scale all elements of the vector (unsafe)
| |
| ToString |
Converts this vector to a string.
At most the first 512 entries are displayed.
(Overrides ObjectToString.) | |
| Write |
Writes this vector to a binary file.
| |
| Zero |
Zeroes this vector.
Note that this also densely fills in the vector.
|
| Name | Description | |
|---|---|---|
| MultiplyBang |
Computes the Kronecker product of two vectors.
|