CINXE.COM

SciPy

<!DOCTYPE html> <html lang="en" data-colorscheme="auto" > <head> <meta name="generator" content="Hugo 0.141.0"> <!-- Generated 2025-04-05 01:28:30 UTC --> <meta name="description" content="Why SciPy? Fundamental algorithms. Broadly applicable. Foundational. Interoperable. Performant. Open source." /> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no"> <meta http-equiv="x-ua-compatible" content="ie=edge"> <title>SciPy</title> <link rel="icon" href="/images/favicon.ico" /> <link rel="stylesheet" type="text/css" href="/theme-css/sphinx-design/index.scss.min.acf226aa2ff428a500491b1393bef415c3883113dac542174f5814fba5532592.css" integrity="sha256-rPImqi/0KKUASRsTk770FcOIMRPaxUIXT1gU&#43;6VTJZI="> <link rel="stylesheet" type="text/css" href="/theme-css/pst/bootstrap.scss.min.e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855.css" integrity="sha256-47DEQpj8HBSa&#43;/TImW&#43;5JCeuQeRkm5NMpJWZG3hSuFU="> <link rel="stylesheet" type="text/css" href="/theme-css/pst/pydata-sphinx-theme.scss.min.1032a66ba1e0ab03bfcbfd265dce1d831879c5ea9d57e8575a68eeeb887b617e.css" integrity="sha256-EDKma6HgqwO/y/0mXc4dgxh5xeqdV&#43;hXWmju64h7YX4="> <link rel="stylesheet" type="text/css" href="/theme-css/spht/index.scss.min.ad03de1683bb39a0d1b31395797b97188e59cda6d778c0671a99db0b4fb799a9.css" integrity="sha256-rQPeFoO7OaDRsxOVeXuXGI5ZzabXeMBnGpnbC0&#43;3mak="> <link rel="stylesheet" href="/theme-css/backtotop.min.af4a1eb2a3e4e5ca38353a8320dafc9b1e1fd2edd480caa5fff0ae4e751d991c.css" integrity="sha256-r0oesqPk5co4NTqDINr8mx4f0u3UgMql//CuTnUdmRw="> <link rel="stylesheet" href="/theme-css/bulma.min.f488b160722c9b7a2a760c03808dc8df5173e6c9dd25cb7481451ddb3c4f35dc.css" integrity="sha256-9IixYHIsm3oqdgwDgI3I31Fz5sndJct0gUUd2zxPNdw="> <link rel="stylesheet" href="/theme-css/code-highlight.min.d0bd96ff1dbeb4b62536da5935b92af5cd7edb6d6f52b316d721e62078d9f089.css" integrity="sha256-0L2W/x2&#43;tLYlNtpZNbkq9c1&#43;221vUrMW1yHmIHjZ8Ik="> <link rel="stylesheet" href="/theme-css/content.min.1de9b096ffc099fee4b538589fea6b622be33d69de64c451e11f2c91476029c5.css" integrity="sha256-Hemwlv/Amf7ktThYn&#43;prYivjPWneZMRR4R8skUdgKcU="> <link rel="stylesheet" href="/theme-css/dark-mode.min.5acf8f4101cd9f24228036af1488ce5c137f9c7e45fbc9c24c20200ea5140ac0.css" integrity="sha256-Ws&#43;PQQHNnyQigDavFIjOXBN/nH5F&#43;8nCTCAgDqUUCsA="> <link rel="stylesheet" href="/theme-css/footer.min.4be63c4d5628cb485efcfa5c9475fa1daa18933eb83741a2ca2bcd444ec270a2.css" integrity="sha256-S&#43;Y8TVYoy0he/PpclHX6HaoYkz64N0GiyivNRE7CcKI="> <link rel="stylesheet" href="/theme-css/hero.min.aa8286fd7d31d78e297e71594436c47b17d4f28660fd16f2b252e3f55fa500be.css" integrity="sha256-qoKG/X0x144pfnFZRDbEexfU8oZg/RbyslLj9V&#43;lAL4="> <link rel="stylesheet" href="/theme-css/lists.min.83821789384ebadc1a1ff75ef9f4b29ba53fe45eb30a46a228aa55772a393396.css" integrity="sha256-g4IXiThOutwaH/de&#43;fSym6U/5F6zCkaiKKpVdyo5M5Y="> <link rel="stylesheet" href="/theme-css/navbar.min.c15f7eadb5a7e1532309c04d94e1b0099d4fa75aaded30829bbfd21ebdb51ad5.css" integrity="sha256-wV9&#43;rbWn4VMjCcBNlOGwCZ1Pp1qt7TCCm7/SHr21GtU="> <link rel="stylesheet" href="/theme-css/news.min.8875ffae62ae22741a27025581fcb3341c18442be06bf132e45f8d6027692876.css" integrity="sha256-iHX/rmKuInQaJwJVgfyzNBwYRCvga/Ey5F&#43;NYCdpKHY="> <link rel="stylesheet" href="/theme-css/posts.min.9505f87d5973f3f08c99c613c0781b3a42411f4795657e8da7ef29c7ad37c23d.css" integrity="sha256-lQX4fVlz8/CMmcYTwHgbOkJBH0eVZX6Np&#43;8px603wj0="> <link rel="stylesheet" href="/theme-css/search.min.ee3423de82ad5535fd375aa47bc4fe618ecaa5d10eb0b68fe6dfc85a78790676.css" integrity="sha256-7jQj3oKtVTX9N1qke8T&#43;YY7KpdEOsLaP5t/IWnh5BnY="> <link rel="stylesheet" href="/theme-css/shortcuts.min.f90addf0a2a3c4e075eb5c3c78e4cc27d9b4fba18a02a17808695212762224c1.css" integrity="sha256-&#43;Qrd8KKjxOB161w8eOTMJ9m0&#43;6GKAqF4CGlSEnYiJME="> <link rel="stylesheet" href="/theme-css/styles.min.00c75e5e25cb21123ca151cb4f4a130891157870829d91cefa425316ecf23de2.css" integrity="sha256-AMdeXiXLIRI8oVHLT0oTCJEVeHCCnZHO&#43;kJTFuzyPeI="> <link rel="stylesheet" href="/theme-css/tables.min.7a44b6bd698323dd3d379b714bd534132e76bf4ba0d3dec61997a8d9ba9db5fb.css" integrity="sha256-ekS2vWmDI909N5txS9U0Ey52v0ug097GGZeo2bqdtfs="> <link rel="stylesheet" href="/theme-css/tabs.min.8884c317231b5f2331b2fd9f65e4f7900fe9124aafae93b78cef175960289683.css" integrity="sha256-iITDFyMbXyMxsv2fZeT3kA/pEkqvrpO3jO8XWWAoloM="> <link rel="stylesheet" href="/theme-css/vars.min.3d537d14ea6e6fb59012fa9d357adf4b209dab8c2535fb94ab37afb6a37020fd.css" integrity="sha256-PVN9FOpub7WQEvqdNXrfSyCdq4wlNfuUqzevtqNwIP0="> <link rel="stylesheet" href="/css/custom.min.cf0f0187caa046832f55197d09d0ad54a98eebc7758bbb354fb1c8fb8541b5bb.css" integrity="sha256-zw8Bh8qgRoMvVRl9CdCtVKmO68d1i7s1T7HI&#43;4VBtbs="> <meta name="twitter:card" content="summary_large_image"> <meta name="twitter:image" content="https://scipy.scientific-python.org/images/logo.svg"> <meta name="twitter:title" content="SciPy"> <meta name="twitter:description" content="Fundamental algorithms SciPy provides algorithms for optimization, integration, interpolation, eigenvalue problems, algebraic equations, differential equations, statistics and many other classes of problems. Broadly applicable The algorithms and data structures provided by SciPy are broadly applicable across domains. Foundational Extends NumPy providing additional tools for array computing and provides specialized data structures, such as sparse matrices and k-dimensional trees. Performant SciPy wraps highly-optimized implementations written in low-level languages like Fortran, C, and C&#43;&#43;. Enjoy the flexibility of Python with the speed of compiled code. Easy to use SciPy鈥檚 high level syntax makes it accessible and productive for programmers from any background or experience level. Open source Distributed under a liberal BSD license, SciPy is developed and maintained publicly on GitHub by a vibrant, responsive, and diverse community."> </head> <body> <nav id="nav" class="navbar" role="navigation" aria-label="main navigation"> <div class="container"> <div class="navbar-brand"> <a role="button" class="navbar-burger" aria-label="menu" aria-expanded="false" data-target="navbar-menu"> <span aria-hidden="true"></span> <span aria-hidden="true"></span> <span aria-hidden="true"></span> </a> </div> <div id="navbar-menu" class="navbar-menu"> <div class="navbar-end"> <a href="/install" class="navbar-item"> Install </a> <a href="https://docs.scipy.org/doc/scipy/" class="navbar-item"> Documentation </a> <a href="/community" class="navbar-item"> Community </a> <a href="/about" class="navbar-item"> About Us </a> <a href="/contribute" class="navbar-item"> Contribute </a> </div> </div> </div> </nav> <section class="hero"> <div class="hero-container"> <div class="hero-content"> <div class="hero-title-content"> <div class="hero-title"> SciPy <img class="hero-logo" src="/images/logo.svg" alt="SciPy logo. A blue circle with a snake in the shape of the letter &#39;S&#39;."> </div> <div class="flex-column"> <div class="hero-subtitle"> Fundamental algorithms for scientific computing in Python </div> <div class="hero-cta"> <a href="/install"><button class="cta-button">Get started</button></a> </div> </div> </div> </div> </div> </section> <div class="news-container"> <div class="news-title"><a href="/news"> SciPy 1.15.2 released!</a></div> <div class="news-date"><a href="/news">2025-02-16</a></div> </div> <section class="content-padding"> <div class="content-container"> <div class="sd-container-fluid sd-mb-4 false"> <div class="sd-row sd-row-cols-1 sd-row-cols-xs-1 sd-row-cols-sm-2 sd-row-cols-md-2 sd-row-cols-lg-3 sd-g-2 sd-g-xs-1 sd-g-sm-2 sd-g-md-2 sd-g-lg-3"> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Fundamental algorithms </div> SciPy provides algorithms for optimization, integration, interpolation, eigenvalue problems, algebraic equations, differential equations, statistics and many other classes of problems. </div> </div> </div> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Broadly applicable </div> The algorithms and data structures provided by SciPy are broadly applicable across domains. </div> </div> </div> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Foundational </div> Extends NumPy providing additional tools for array computing and provides specialized data structures, such as sparse matrices and k-dimensional trees. </div> </div> </div> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Performant </div> SciPy wraps highly-optimized implementations written in low-level languages like Fortran, C, and C++. Enjoy the flexibility of Python with the speed of compiled code. </div> </div> </div> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Easy to use </div> SciPy&rsquo;s high level syntax makes it accessible and productive for programmers from any background or experience level. </div> </div> </div> <div class="sd-col sd-d-flex-row"> <div class="sd-card sd-w-100 sd-shadow-sm "> <div class="sd-card-body"> <div class="sd-card-title sd-font-weight-bold"> Open source </div> Distributed under a liberal <a href="https://github.com/scipy/scipy/blob/main/LICENSE.txt">BSD license</a>, SciPy is developed and maintained <a href="https://github.com/scipy/scipy">publicly on GitHub</a> by a vibrant, responsive, and diverse <a href="/community/">community</a>. </div> </div> </div> </div> </div> </div> </section> <div id="backtotop"><a href="#" id="backtotop-color"><i class="fa-solid fa-arrow-up"></i></a></div> <footer id="footer"> <div class="container"> <div id="footer-columns"> <div id="footer-logo-column"> <img id="footer-logo" src="/images/logo.svg" alt="SciPy logo. A blue circle with a snake in the shape of the letter &#39;S&#39;."> </div> <div class="footer-column"> <div class="footer-item"> <a href="/install"> Install </a> </div> <div class="footer-item"> <a href="https://docs.scipy.org/doc/scipy/"> Documentation </a> </div> <div class="footer-item"> <a href="/citing-scipy"> Citing SciPy </a> </div> <div class="footer-item"> <a href="https://scipy.github.io/devdocs/dev/roadmap.html"> Roadmap </a> </div> </div> <div class="footer-column"> <div class="footer-item"> <a href="/about"> About Us </a> </div> <div class="footer-item"> <a href="/community"> Community </a> </div> <div class="footer-item"> <a href="https://conference.scipy.org/"> SciPy Conference </a> </div> <div class="footer-item"> <a href="/contribute"> Contribute </a> </div> <div class="footer-item"> <a href="https://docs.scipy.org/doc/scipy/dev/conduct/code_of_conduct.html"> Code of Conduct </a> </div> </div> <div class="footer-column"> <div class="footer-item"> <a href="/faq"> FAQ </a> </div> <div class="footer-item"> <a href="/terms"> Terms of Use </a> </div> <div class="footer-item"> <a href="/privacy"> Privacy </a> </div> <div class="footer-item"> <a href="/press-kit"> Press Kit </a> </div> <div class="footer-item"> <a href="/about/#social-media"> Social Media </a> </div> </div> <div class="footer-actions"> <div class="community-icons"> <a href="https://github.com/scipy/scipy" aria-label="https://github.com/scipy/scipy"> <svg class="icon github-icon" viewBox="0 0 24 24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg> </a> <a href="https://discuss.scientific-python.org/c/contributor/scipy/" aria-label="https://discuss.scientific-python.org/c/contributor/scipy/"> <svg class="icon scientific-python-icon" viewBox="0 0 24 24" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 7.1c-.19-.11-.46-.4-.39-.76.076-.36.063-.59-.26-.97a.683.683 0 0 1-.14-.63.92.92 0 0 0 .063-.16v-.002c.046-.13.072-.28.072-.42 0-.76-.59-1.3-1.3-1.3l-.063.003c-.017 0-.034 0-.05.002h-.006a1.831 1.831 0 0 0-.093.013c-.46.05-.97-.01-1.1-.31-.17-.32-.46-.46-.84-.63-.38-.17-.08-.46-.72-.89-.63-.42-1.4-.19-2.1-.31-.4-.068-.72-.19-.93-.29-.063-.038-.13-.072-.2-.11l-.022-.014h-.004a2.638 2.638 0 0 0-3.1.64l-.013.01c-.46.42-.67.28-1.3.63-.67.35-.55.72-.93 1-.39.29-1.1.098-1.8.42-.63.32-.51.76-.67 1-.19.26-.8.63-1.2.8s-.76.51-.63 1.1c.13.63.29.8.55.93.24.13.46.38.67.67.21.29.27.59.8.89s.55.93.55.93a1.35 1.35 0 0 0-.012.18c0 .76.59 1.3 1.3 1.3.18 0 .35-.036.51-.1h.002c.72-.17.42.46 1 .46s.89-.51 1.3-.46c.42.063.51.24 1.3.63.8.39 1.3-.076 1.3-.076l.29-.63s.46.34.8.39c.34.05.97-.38 1.5-.59s1.1.55 1.9.4c.76-.16 1.1-.67 1.6-.93.51-.25 1.2-.051 1.8-.27.55-.22.29-.76.42-1.1.13-.3.46-.063.59-.67.13-.63-.23-.76-.42-.89zM1 16.4c3-1 6.2-1.6 9.4-1.7-3.3.063-6.5.51-9.6 1.3.036.13.076.27.11.4zm21 0c.041-.13.08-.27.11-.4-3.1-.76-6.3-1.2-9.6-1.3 3.3.084 6.5.67 9.4 1.7zM20.1 19c-.42-3.7-14-2.2-14-3.1-.059-.59 1.8-1 3.1-1.2l-.31.024c-1.6.18-3.9.51-3.8 1.3.2 1.9 9.9.13 10 3 .19 1.5-5.4 2.3-10 2.7 1.8 1.4 4.1 2.2 6.6 2.2 3.1 0 5.8-1.3 7.8-3.3.46-.51.67-1.1.63-1.6zM18.5 6l-.076-.33s-1.6.39-3.5 1.2c-.22.097-.42.19-.63.28.021-.19.055-.51.093-.89.1-.33.3-.46.67-.63.46-.23 1.4-.84 1.4-.84l-.21-.26c-.63.46-1.5.8-1.8.89.059-.93.033-2.4.033-2.4l-.35.32s.021 1.2-.13 2.2c-.13.84-.24 1.5-.59 2-.55.28-.93.51-1.1.63l-.3-3.3c.51-1.2 1.6-2.7 1.6-2.7l-.34-.039s-.8 1.3-1.3 1.8l-.27-3-.3-.11-.17 4c-.72-.55-1.7-2.1-1.7-2.1l-.21.23s.93 1.4 1.4 2.2c.19.27.32.55.41.8l-.11 2.5-.002-.003s-1.2-.97-2.1-1.8c-.14-.14-.3-.32-.46-.51l.003-.097c.035-1.1-.33-3.4-.33-3.4l-.28-.008s.23 1.8.15 3c-.72-.84-1.4-1.8-1.4-1.8l-.21.18c.007.022 1 1.3 1.5 2 .35.46.72.97.97 1.3-.36-.072-1.3-.17-2.2-.41l-.014-.032c-.35-.8-1.1-1.8-1.1-1.8l-.31-.11s.59.97.89 1.8c-.72-.22-1.5-.51-2-.93v.3c1.3 1.2 4 1.6 4.6 1.7.024.006.046.014.072.022-1.2-.041-2.7.3-2.7.3l-.17.42s2.4-.55 3.6-.15c.39.41.72.89.89 1.1.093.14.16.25.22.41h-.004c.009.023.018.043.026.069.076.25.11.59.11 1.3 0 1.2-.08 1.9-.088 2-.027.12-.068.22-.12.26a.85.85 0 0 0-.25.32.44.44 0 0 1-.2.22c-.11.063-.22.23-.32.3-.1.068-.29.1-.29.1l-.76.33h.008c.67-.06 1.3-.097 2-.11.28-.005.55-.01.84-.01s.55.005.84.01c.72.018 1.4.059 2.1.12-.24-.08-.76-.26-.89-.3-.13-.051-.3-.19-.37-.24a1.433 1.433 0 0 0-.25-.16c-.1-.046-.15-.11-.23-.28-.084-.16-.27-.33-.33-.46-.051-.11-.08-1.2-.093-1.7v-2c.16-.28.39-.63.76-1a.795.795 0 0 1 .31.022c.46.12 1.2.38 2.1.8l.08-.2s-1.3-.72-2.1-.97c.2-.17.42-.35.67-.51.27-.18.55-.35.84-.51 1.1.19 3.2.16 3.2.16l.059-.29s-1.5-.027-2.6-.22c1.3-.63 2.7-1 2.7-1z"/></svg> </a> </div> <div class="copyright">&copy; 2025 . All rights reserved.</div> </div> </div> </div> </footer> </body> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.6.0/css/all.min.css" integrity="sha512-Kc323vGBEqzTmouAECnVceyQqyqdsSiqLQISBL29aUW4U/M7pSPA/gEUZQqv1cwx4OnYxTxve5UMg5GT6L4JJg==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.6.0/css/all.min.css" integrity="sha512-Kc323vGBEqzTmouAECnVceyQqyqdsSiqLQISBL29aUW4U/M7pSPA/gEUZQqv1cwx4OnYxTxve5UMg5GT6L4JJg==" crossorigin="anonymous" referrerpolicy="no-referrer" /> <script type="text/javascript" src=/js/bundle.min.js></script><script type="text/javascript">setupShortcuts(maxLevel= 2 );</script> <script defer data-domain="scipy.org" src="https://views.scientific-python.org/js/script.js"></script> </html>

Pages: 1 2 3 4 5 6 7 8 9 10