Implement methods to operate complex numbers.
- Lucas Leandro Costa Lacerda
- iostream
- string
- cmath
To use the Complex class with polar implementation instantiate with the format bellow.
Complex c(5, 45)
The first parameter is the real number (radius) and the second is the imaginary number (angle in degrees).
To use the Complex class with euclidean implementation instantiate with the format bellow.
Complex c(2, 15)
The first parameter is the real number (x axis) and the second is the imaginary number (y axis).
Inside the run.sh
file you can add repositories to use like the example bellow:
dependencies=("complex-number;https://github.com/LucasLacerdaCL/complex-number.git")
Execute the run.sh
file to generate the binary files inside dist
folder.
For OSX:
sh ./run.sh
For Windows:
./run.sh
Inside the bootstrap.sh
file you can inject the dependencies like the example bellow:
yourBinary="exemple.o"
yourMain="main.o"
imports=("complex-number;complex.euclidean.o")
cmdLine="./${yourBinary} ./${yourMain}"
Execute the bootstrap.sh
file to generate the main.exe
file.
For OSX:
sh ./bootstrap.sh
For Windows:
./bootstrap.sh
Released under the MIT license.