Click or drag to resize

DoubleComplexMatrixParse(String, NumberStyles) Method

Constructs a DoubleComplexMatrix instance from a formatted string and a NumberStyles object.

Namespace: CenterSpace.NMath.Core
Assembly: NMath (in NMath.dll) Version: 7.4
Syntax
public static DoubleComplexMatrix Parse(
	string s,
	NumberStyles styles
)

Parameters

s  String
A formatted string representation of a matrix.
styles  NumberStyles
One or more number styles.

Return Value

DoubleComplexMatrix
Remarks
The string must contain the number of rows, followed by an optional separator character, such as x, followed by the number of columns. The matrix values, separated by white space, are then read in row by row. If the sequence of numbers begins with a left bracket '[', then the numbers are read until a matching right bracket ']' is encountered. If no brackets are used, numbers are read until the end of the string.
Example
Example strings with a style that allows for exponential format ( NumberStyles.Number | NumberStyles.AllowExponent):
C#
string s = "1 x 3 [ (1.5e+002,1.444e-001) (4.429923e+005,9.93338e-010) (1.4e+000,9.0e-002) ]";
DoubleComplexMatrix M = DoubleComplexMatrix.Parse( s, NumberStyles.Number | NumberStyles.AllowExponent );
See Also