Summary
Defines if object values are complex.
Class
TMtxVec
Declaration
Property Complex: boolean read FComplex write setComplex stored false;
Description
If true, TMtxVec will treat it's elements as complex numbers. Two successive number in the values array be treated as real and imaginary part of the complex number. When property is false, object will treat it's elements as real numbers. You should always set the value of the Complex property before setting object size (
TVec.Length for vector or
TMtx.Rows,
TMtx.Cols for matrix). Setting Complex from true to false does not cause memory reallocation. It simply doubles the value of the Length property. Setting Complex from false to true halves the vector length or number of matrix columns, but retains all data. Complex property is initially false.
Example 1
var a,b,c,d: TVec;
begin
CreateIt(a,b,c);
try
a.SetIt(True,[1,2,3,4]);
b.SetIt(False,[8,9,6,7]);
b.Complex := True;
c.Mul(a,b); // = [(1+2i)*(8*9i), (3+4i)*(6+7i)]
finally
FreeIt(a,b,c);
end;
end;
| Copyright 2008 Dew Research |
http://www.dewresearch.com