errors using cdf function
errors using cdf function
I have downloaded the cdf function in cdf.h (as well as the files it needs to compile poly_eval.h and errorfn.h) - when I try to run I get the following errors:
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccX1AqC8.o:main.cpp:(.text+0x100): multiple definition of `Maths::Algebra::Polynomial::polyEval(double, double const*, int)'
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccJGh0lW.o:option.cpp:(.text+0x100): first defined here
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccX1AqC8.o:main.cpp:(.text+0x148): multiple definition of `Maths::Algebra::Polynomial::polyEval1(double, double const*, int)'
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccJGh0lW.o:option.cpp:(.text+0x148): first defined here
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccX1AqC8.o:main.cpp:(.text+0x192): multiple definition of `Maths::Special::errorFn(double)'
/cygdrive/c/DOCUME~1/MICHEL~1/LOCALS~1/Temp/ccJGh0lW.o:option.cpp:(.text+0x192): first defined here
can anyone explain why I am getting these problems?
18 Oct 08, 5:48PM
This error occurs when you include a file twice!
I assume you're using the Normal CDF function.
What does your main.cpp file look like. Make sure you don't include poly_eval.h and errorfn.h explicitly. You should only have:
#include <codecogs/stats/dists/continuous/normal/cdf.h>
Can you post your code here (or perhaps a cut down version that still exhibits this error)
Login