STACK: integer and float variables in algebraic input

Re: STACK: integer and float variables in algebraic input

by Leo Butler -
Number of replies: 0
I think there are likely two issues:

  1. in the input: ans section, you need to set forbid float to no;
  2. you need to set simp:false to preserve the form of your expression with a floating-point denominator.
Your question will look like:

simp:false;
N : 150.1;
ta : v/N;

-----

Another method would be to ask for the numerator and denominator separately. I would likely do that since there are fewer pitfalls.

Leo



Average of ratings: Useful (2)