Ask Your Question

Unexpected result in calculating limits

asked 2020-04-15 13:43:24 +0200

gg gravatar image

Limit of sqrt(x-3) when x approaches 3 doesn't exist but the sage returns 0. Why is that?

sage: limit(sqrt(x-3), x=3)
edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2020-04-15 20:24:43 +0200

Sébastien gravatar image

Maybe because the square root function is defined for negative numbers and the square root of small negative numbers converges to zero as well (on the Complex plane):

sage: sqrt(-.00000001)
edit flag offensive delete link more


is there any way to alter this behavior?

gg gravatar imagegg ( 2020-04-17 13:35:34 +0200 )edit

I don't know. Sympy behaves the same:

sage: from sympy import limit, sqrt
sage: from import x
sage: limit(sqrt(x-3), x, 3)
sage: limit(sqrt(x-3), x, 3, dir="+")
sage: limit(sqrt(x-3), x, 3, dir="-")
Sébastien gravatar imageSébastien ( 2020-04-17 20:40:09 +0200 )edit

BTW, I don't quite understand the term "complex plane" and how the square root converges to 0. Where I can read more about it?

gg gravatar imagegg ( 2020-04-18 08:19:52 +0200 )edit

You may learn about the complex plane here and there is a section on the square root of negative number in the wikipedia page of the square root:

Sébastien gravatar imageSébastien ( 2020-04-18 11:36:45 +0200 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2020-04-15 13:43:24 +0200

Seen: 241 times

Last updated: Apr 15 '20