Vector::Vector Constructor

Overload List

#SignatureDescription
1Vector(const int ALength, const TMtxFloatPrecision aFloatPrecision);Internally creates TVec object without using object cache.
2Vector(const int ALength);
3Vector(TVec *Src);Uses TVec object as internal storage.
4Vector(bool FromObjectCache);Constructor of the record.
5Vector(const int ALength, const bool aIsComplex, const bool aIsDouble);Constructor of the record.
6Vector(const int ALength, const bool aIsComplex);
7Vector();
8Vector(const Vector &aSrc);
9Vector(std::initializer_list<double> aValues);
10Vector(std::initializer_list<TCplx> aValues);
11Vector(const DewArray<float> &AValue);Explicitely convert array of single values to Vector.
12Vector(TVecInt *AValue);Explicitely convert TVecInt to Vector.
13Vector(const VectorInt &AValue);Explicitely convert VectorInt to Vector.
14Vector(const DewArray<double> &AValue);Implicit type conversion from an array of double to Vector.
15Vector(const DewArray<TCplx> &AValue);Implicit type conversion from an array of TCplx to Vector.

Overload 1: Vector(const int ALength, const TMtxFloatPrecision aFloatPrecision);

Internally creates TVec object without using object cache.

#NameTypeDescription
1ALengthconst int
2aFloatPrecisionconst TMtxFloatPrecision
Remarks:

Creates TVec object without using object cache. Suitable for declaring global variables.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 2: Vector(const int ALength);

#NameTypeDescription
1ALengthconst int
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 3: Vector(TVec *Src);

Uses TVec object as internal storage.

#NameTypeDescription
1SrcTVec *
Remarks:

The resulting Vector will own Src object of TVec type and will release it once Vector gets out of scope.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 4: Vector(bool FromObjectCache);

Constructor of the record.

#NameTypeDescription
1FromObjectCachebool
Remarks:

Returns a Vector with internal TVec object created from object cache (CreateIt), if FromObjectCache is True. Pass false to the constructor, if the variable is a global variable. Object cache has limited size and is to be used only for local variables.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 5: Vector(const int ALength, const bool aIsComplex, const bool aIsDouble);

Constructor of the record.

#NameTypeDescription
1ALengthconst int
2aIsComplexconst bool
3aIsDoubleconst bool
Remarks:

Returns a Vector with internal TVec object created explicitely with Length property set to aLength and Complex property set to IsComplex. Call this constructor, if the Vector type variable is a global variable with a long life span.

See Also: TVec::Equal, TMtxVec::IsEqual
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 6: Vector(const int ALength, const bool aIsComplex);

#NameTypeDescription
1ALengthconst int
2aIsComplexconst bool
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 7: Vector();

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 8: Vector(const Vector &aSrc);

#NameTypeDescription
1aSrcconst Vector &
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 9: Vector(std::initializer_list<double> aValues);

#NameTypeDescription
1aValuesstd::initializer_list<double>
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 10: Vector(std::initializer_list<TCplx> aValues);

#NameTypeDescription
1aValuesstd::initializer_list<TCplx>
Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 11: Vector(const DewArray<float> &AValue);

Explicitely convert array of single values to Vector.

#NameTypeDescription
1AValueconst DewArray<float> &
Remarks:

Copies all values from the AValue array to the result.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 12: Vector(TVecInt *AValue);

Explicitely convert TVecInt to Vector.

#NameTypeDescription
1AValueTVecInt *
Remarks:

Copies all values from AValue to the result.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 13: Vector(const VectorInt &AValue);

Explicitely convert VectorInt to Vector.

#NameTypeDescription
1AValueconst VectorInt &
Remarks:

Copies all values from AValue to the result.

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 14: Vector(const DewArray<double> &AValue);

Implicit type conversion from an array of double to Vector.

#NameTypeDescription
1AValueconst DewArray<double> &
Remarks:

Copies array and resizes resulting vector. Example of usage in Delphi XE7 and newer:

var a: Vector;
begin
a := [1,2,3,4,5];
a := [1,2.2,3,4] + [1,2]; //the + here is "column concatenation" a := [1,2.2,3,4] + a; //operator not applicable (it wont compile) end;

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler

Overload 15: Vector(const DewArray<TCplx> &AValue);

Implicit type conversion from an array of TCplx to Vector.

#NameTypeDescription
1AValueconst DewArray<TCplx> &
Remarks:

Copies array and resizes resulting vector. Example of usage in Delphi XE7 and newer:

var a: Vector;
begin
a := [Cplx(1,2),Cplx(3,4),Cplx(5)]; a := [Cplx(1,2.2),Cplx(3,4)] + [Cplx(1,2)]; //the + here is "column concatenation" a := [Cplx(1,2.2),Cplx(3,4)] + a; //operator not applicable (it wont compile) end;

Declared in Dew::Math::Vector · Dew.Math/MtxExpr.h · Cross-compiler