I am having this problem to define a function which raises a float y eg 3.5 which is not a whole number to the base x.
Heres the code which gives domain error as function pow takes only int values.
http://www.cplusplus.com/ref/cmath/pow.html
Pow, in the standard C library for mathematical operations, takes two double values by default. You could also look into the powerful powf function.
-Fredric
Daishi
Junior Poster in Training
80 posts since Aug 2005
Reputation Points: 10
Solved Threads: 2