A definite integral



Please try
integrate((tan(x)^2+1)/tan(x),x,%pi/6,%pi/3);
which on my computer ends up with something different from what I expect
to be the result, namely log(3).
Im I wrong?

Try also
integrate((tan(x)^2+1)/tan(x),x);
followed by
logcontract(%);

Yours,
Poul Riis