fmod is not mathematically valid. Replace it by a correct one.
This commit is contained in:
@@ -22,7 +22,7 @@ public:
|
||||
|
||||
double value = floor(sqrt(squared));
|
||||
|
||||
return (fmod(value, 2) == 0)?this->a:this->b;
|
||||
return (modulo(value, 2) == 0)?this->a:this->b;
|
||||
}
|
||||
|
||||
void dumpMe(FILE *fp) {
|
||||
|
||||
Reference in New Issue
Block a user