Inspired by this ask.sagemath.org question. Consider :
(%i1) display2d:false;
(%o1) false
(%i2) define(f(x),diff(log(tan(%pi/2*tanh(x))),x));
(%o2) f(x):=(%pi*sech(x)^2*sec((%pi*tanh(x))/2)^2)/(2*tan((%pi*tanh(x))/2))
(%i3) limit(f(x), x, inf);
(%o3) und
(%i4) limit(trigreduce(trigsimp(trigreduce(f(x)))), x, inf);
(%o4) 2
As documented in the inspirating post's comments, he first answer is incorrect, the second one is correct.
HTH,
Yes, and other ways of simplifying also lead to the correct answer:
Fixed by commit [92e5f8].
Related
Commit: [92e5f8]