Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BUG: special: elliptic integral incorrectly gives nan #20525

Open
unalmis opened this issue Apr 19, 2024 · 1 comment
Open

BUG: special: elliptic integral incorrectly gives nan #20525

unalmis opened this issue Apr 19, 2024 · 1 comment
Labels
defect A clear bug or issue that prevents SciPy from being installed or used as expected scipy.special

Comments

@unalmis
Copy link

unalmis commented Apr 19, 2024

Describe your issue.

ellipeinc and ellipkinc are broken.

Reproducing Code Example

# Pick some k between 0 and 1.
ellipkinc(np.arcsin(k), 1 / k**2)
ellipeinc(np.arcsin(k), 1 / k**2)

Error message

nan output is incorrect.

SciPy/NumPy/Python version and system information

1.12.0 1.26.4 sys.version_info(major=3, minor=12, micro=2, releaselevel='final', serial=0)
Build Dependencies:
  blas:
    detection method: pkgconfig
    found: true
    include directory: /usr/local/include
    lib directory: /usr/local/lib
    name: openblas
    openblas configuration: USE_64BITINT= DYNAMIC_ARCH=1 DYNAMIC_OLDER= NO_CBLAS=
      NO_LAPACK= NO_LAPACKE= NO_AFFINITY=1 USE_OPENMP= HASWELL MAX_THREADS=2
    pc file directory: /usr/local/lib/pkgconfig
    version: 0.3.21.dev
  lapack:
    detection method: pkgconfig
    found: true
    include directory: /usr/local/include
    lib directory: /usr/local/lib
    name: openblas
    openblas configuration: USE_64BITINT= DYNAMIC_ARCH=1 DYNAMIC_OLDER= NO_CBLAS=
      NO_LAPACK= NO_LAPACKE= NO_AFFINITY=1 USE_OPENMP= HASWELL MAX_THREADS=2
    pc file directory: /usr/local/lib/pkgconfig
    version: 0.3.21.dev
  pybind11:
    detection method: config-tool
    include directory: unknown
    name: pybind11
    version: 2.11.1
Compilers:
  c:
    commands: cc
    linker: ld.bfd
    name: gcc
    version: 10.2.1
  c++:
    commands: c++
    linker: ld.bfd
    name: gcc
    version: 10.2.1
  cython:
    commands: cython
    linker: cython
    name: cython
    version: 3.0.8
  fortran:
    commands: gfortran
    linker: ld.bfd
    name: gcc
    version: 10.2.1
  pythran:
    include directory: ../../tmp/pip-build-env-tfqmvy7q/overlay/lib/python3.12/site-packages/pythran
    version: 0.15.0
Machine Information:
  build:
    cpu: x86_64
    endian: little
    family: x86_64
    system: linux
  cross-compiled: false
  host:
    cpu: x86_64
    endian: little
    family: x86_64
    system: linux
Python Information:
  path: /opt/python/cp312-cp312/bin/python
  version: '3.12
@unalmis unalmis added the defect A clear bug or issue that prevents SciPy from being installed or used as expected label Apr 19, 2024
@unalmis unalmis changed the title BUG: <Please write a comprehensive title after the 'BUG: ' prefix> BUG: <eliptic integral gives nan ' prefix> Apr 19, 2024
@lucascolley lucascolley changed the title BUG: <eliptic integral gives nan ' prefix> BUG: special: eliptic integral incorrectly gives nan Apr 19, 2024
@izaid
Copy link
Contributor

izaid commented Apr 19, 2024

Thanks for reporting this. Actually, like #20506, we haven't touched the elliptic integrals at all (yet). But they are going to be updated via #20390. Once that is merged, I think we can look into this easily.

@lucascolley lucascolley changed the title BUG: special: eliptic integral incorrectly gives nan BUG: special: elliptic integral incorrectly gives nan Apr 19, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
defect A clear bug or issue that prevents SciPy from being installed or used as expected scipy.special
Projects
None yet
Development

No branches or pull requests

4 participants
@izaid @j-bowhay @unalmis and others