This sentence shows that overflow
B1 r2=r1 * * (Exp (r1 * (xf - xe)) - Exp (r2 * (xf - xe)))/(r1 * Exp (r2 * (xf - xe)) - r2 * Exp (r1 * (xf - xe)))
O great god save me!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
CodePudding user response:
MsgBox 0/0CodePudding user response:
You omitted the As a Double of the variables are not Double, you are still a lot more than the whole statementAnd check (r1 * Exp (r2 * (xf - xe)) - r2 * Exp (r1 * (xf - xe))) this part whether the result is 0
CodePudding user response:
First of all, because you are lazy, only the last one is doubule all variables, other are notError check (r1 * Exp (r2 * (xf - xe)) - r2 * Exp (r1 * (xf - xe))), not necessarily is 0, it is also possible that this value is very small, in short, an error when the formula broken down step by step calculation, and overflow, and see which step to check the numerical or logic is correct,
CodePudding user response:
MD,What you value is not assigned, the division becomes 0/0, lead to overflow,
The inside of the other formulas xe is not defined
CodePudding user response:
To compound expressions manually disassembled for as far as possible simple expressions step by step, step through again,CodePudding user response:
Most of overflow is to divide 0 there is nothing to say, check itCodePudding user response:
overflow error (6), when the assignment was beyond the limit of the target, overflow occurs,This error has the following cause and solution:
Assignment, calculation, or data type conversion is too large, the results of that cannot be represented within the range allowed by the variable type,
Assigned to said enough value scope of variables of type,
Value assigned to the property exceeds the maximum limit properties can accept,
Ensure that the scope of the assignment for attribute
Attempt to use a number in the calculation, and the number is mandatory as an integer, but the result over the range of integers, for example:
Dim x As Long
X=2000 * 365 'error: overflow
To solve this problem, as follows, please enter the number:
Dim x As Long
X=CLng (2000) * 365