# FullSimplify providing an answer not valid for certain parameters

I have an expression:

expression=(a - 2 b + Sqrt[a^2 + 4 (b^2 + c^2) + 4 a (-b + c + 2 c d)])/(a -
2 b + 2 c + Sqrt[a^2 + 4 (b^2 + c^2) + 4 a (-b + c + 2 c d)])


that yields the following when fully simplified

FullSimplify[expression]

(*(a + 2 b + 2 c + 4 a d - Sqrt[a^2 + 4 (b^2 + c^2) + 4 a (-b + c + 2 c d)])/(4 (b + a d))*)


However, the fully simplified expression is not valid for b,d=0 whereas the original expression is.

For example, a=1,b=0,c=3,d=0 yields 4/7 from the original expression but is indeterminate from the mathematica fully simplified expression.

No assumptions have been made when using FullSimplify so I thought it should be true for all parameter choices. What's going wrong?

The simplified version has different removable singularities.

f = FullSimplify[expression] /. {a -> 1, b -> 0, c -> 3};
Plot[f, {d, -0.5, 0.5},
Epilog -> {PointSize[Medium], Red, Point[{0, 4/7}]}]


Note that

Limit[f, d -> 0]


$\frac{4}{7}$

• sorry, my math not as strong as I'd like. Are you saying that the simplified version is correct in the limit as b,d approach zero although not strictly determinate at the limit? And therefore is an acceptable simplification? – physioConfusio Aug 14 '16 at 8:28
• i'd actually much prefer a simplification that is valid for b,d zero. Is there any general way to specify such a requirement in a simplification request? – physioConfusio Aug 14 '16 at 8:36
• @physioConfusio Yes,it has a limit as $d\rightarrow 0$ which has the same value is the original function has for $d=0$. – Feyre Aug 14 '16 at 8:37
• @physioConfusio see this question: mathematica.stackexchange.com/questions/89990/… – Feyre Aug 14 '16 at 8:40
• yep, that looks relevant, thanks – physioConfusio Aug 14 '16 at 8:42