[Tinymux] Adding Penn's fmod function
Suzanne Baylor
sbaylor at dsl-only.net
Thu Nov 10 17:15:06 EST 2005
I'm copying some code over from Penn to TinyMUX 2.3.5.24 which uses the
fmod function from Penn which apparantly isn't supported in TinyMUX. Is
there an easy way to add this in or code around it? My last math class
was 20 years ago so I've no idea how to fake one up myself :) I tried
just pasting the hc into functions.cpp but it complains a ton on compile
about missing identifiers, etc (not surprising.)
---
fmod(<number>,<divisor>)
Identical to mod() but may take floating point arguments. The return
value is the (possibly floating point) smallest positive remainder
left after subtracting the largest number of multiples of <divisor>
from <number>.
Example:
> think fmod(6.1,2.5)
1.1
(above copyright Javelin and crew)
More information about the Tinymux
mailing list