LAB 11:SEPARATE COMPILATION: CREATING A PROJECT
DUE TUESDAY NOV 12, 9:30 am
For this lab you need to create a project composed of several files.
The file that contains the main function must have the content of the file "Lab11Main.cpp" EXACTLY,
located in the class folder. Do NOT modify that file.
Write other necessary files, combine them into a project so that you can run the main program and it produces
a reasonable output.
Here are the other files you need to write:
- An interface (header) file called complex.h for the complex number class (which contains a definition of the
complex number class, but no implementations of the member functions or constructors)
- An implementation file, complex.cpp, which contains implementations of the members of the complex number class.
- An interface (header) file called Functions.h with prototypes of the following functions:
- factorial function // int fact(int);
- exponential function // double Exp(double)
- natural logarithmic function// double ln(double)
- trig functions sine and cosine // double Sin(double) and double Cos(double)
- An implementation file for the functions, Functions.cpp which contains definitions of the functions declared
in the interface file. Use the formulas given in the class to define these functions. Also pay attention to the
following: The factorial function is only defined for non-negative integers and the formula given for ln function
is only valid if the argument is positive but less than 2. If an argument different from these is given to these
2 functions, then an appropriate error message should be output.