fiveten
06-16-2012, 06:31 PM
I am new to Simba, SRL, Free Pascal, and this forum, so I hope this is the correct section for my post.
I was searching google and found a unit for Free Pascal called ucomplex which should work for what I need, but I am not sure how to include it into my script. I know I could just write my own class which holds both real and imaginary parts of the number and overload the operators. In fact, this site (http://www.freepascal.org/docs-html/ref/refse84.html)explains it very well, but my question concerns including these units into my script.
http://wiki.freepascal.org/Unit_categorization
I have tried this script but it fails to compile on the "uses UCOMPLEX" line:
program CmplxDemo;
uses UCOMPLEX;
var
z: Complex;
begin
z := Cmplx (13, 37) { z := x + iy }
end.
I was searching google and found a unit for Free Pascal called ucomplex which should work for what I need, but I am not sure how to include it into my script. I know I could just write my own class which holds both real and imaginary parts of the number and overload the operators. In fact, this site (http://www.freepascal.org/docs-html/ref/refse84.html)explains it very well, but my question concerns including these units into my script.
http://wiki.freepascal.org/Unit_categorization
I have tried this script but it fails to compile on the "uses UCOMPLEX" line:
program CmplxDemo;
uses UCOMPLEX;
var
z: Complex;
begin
z := Cmplx (13, 37) { z := x + iy }
end.