Is there a proper way to do a math operation on 2 int declared intergers that is known should return a double or a floating point variable? I have an operation on 2 ints
int Adaptive_Gain_value
int Adj_Gain_value
double results
// to get or perscribe a percentage of the Adaptive_Gain_value... lets to the get the Percentage first.
results = Adj_Gain_value / Adaptive_Gain_value;
// this always returns a 0.000000000
// int the past, I thought this should work without having to change the declaration, or do I need to do some special cast?
Thanks!
ChipB
Message Edited by ASIC IIBU Tech on
05-07-2008 04:31 PM