piecewise function with integrals



"Okay, now I get it.  iif() is a function that only works for simplifying 
functions.  If you want to actually plug in a value for x inside an "if" 
like this one.  You will crash Maxima.

(1/(x-1) *  if equal(x,1) then 1 else (x-1));
%,x=1;
results in an error

You could do

(1/(x-1) *  if equal(x,1) then 1 else (x-1))$
somesimplifyercall(%);
-> if equal(x,1) then error("divide by zero") else 1"

Another thought.  Doing it this way puts time bombs in the expression.