Skip to content
This repository has been archived by the owner on Jan 30, 2023. It is now read-only.

Commit

Permalink
21906: fix bessel_Y/K(0,0); add tests
Browse files Browse the repository at this point in the history
  • Loading branch information
rwst committed Dec 4, 2016
1 parent 163489e commit bd4d2cf
Showing 1 changed file with 11 additions and 1 deletion.
12 changes: 11 additions & 1 deletion src/sage/functions/bessel.py
Original file line number Diff line number Diff line change
Expand Up @@ -575,6 +575,11 @@ def _eval_(self, n, x):
-sqrt(2)*sqrt(1/(pi*x))*cos(x)
sage: bessel_Y(-1/2, x)
sqrt(2)*sqrt(1/(pi*x))*sin(x)
TESTS::
sage: bessel_Y(0, 0)
-Infinity
"""
from sage.rings.infinity import infinity, unsigned_infinity
if not isinstance(x, Expression) and x == 0:
Expand Down Expand Up @@ -974,8 +979,13 @@ def _eval_(self, n, x):
sqrt(1/2)*sqrt(pi)*e^(-x)/sqrt(x)
sage: bessel_K(n, 0)
bessel_K(n, 0)
TESTS::
sage: bessel_K(0, 0)
+Infinity
"""
from sage.rings.infinity import unsigned_infinity
from sage.rings.infinity import infinity, unsigned_infinity
if not isinstance(x, Expression) and x == 0:
if n == 0:
return infinity
Expand Down

0 comments on commit bd4d2cf

Please sign in to comment.