# SageMath

SageMath (previously Sage or SAGE, "System for Algebra and Geometry Experimentation") is a computer algebra system (CAS) with features covering many aspects of mathematics, including algebra, combinatorics, graph theory, group theory, differentiable manifolds, numerical analysis, number theory, calculus and statistics.
The first version of SageMath was released on 24 February 2005 as free and open-source software under the terms of the GNU General Public License version 2, with the initial goals of creating an "open source alternative to Magma, Maple, Mathematica, and MATLAB". The originator and leader of the SageMath project, William Stein, was a mathematician at the University of Washington.
SageMath uses a syntax resembling Python's, supporting procedural, functional and object-oriented constructs.

## Development

Stein realized when designing Sage that there were many open-source mathematics software packages already written in different languages, namely C, C++, Common Lisp, Fortran and Python.
Rather than reinventing the wheel, Sage (which is written mostly in Python and Cython) integrates many specialized CAS software packages into a common interface, for which a user needs to know only Python. However, Sage contains hundreds of thousands of unique lines of code adding new functions and creating the interfaces among its components.
SageMath uses both students and professionals for development. The development of SageMath is supported by both volunteer work and grants. However, it was not until 2016 that the first full-time Sage developer was hired (funded by an EU grant). The same year, Stein described his disappointment with a lack of academic funding and credentials for software development, citing it as the reason for his decision to leave his tenured academic position to work full-time on the project in a newly founded company, SageMath, Inc.

## Achievements

* 2007: first prize in the scientific software division of Les Trophées du Libre, an international competition for free software.
* 2012: one of the projects selected for the Google Summer of Code.
* 2013: ACM/SIGSAM Jenks Prize.

## Performance

Both binaries and source code are available for SageMath from the download page. If SageMath is built from source code, many of the included libraries such as OpenBLAS, FLINT, GAP (computer algebra system), and NTL will be tuned and optimized for that computer, taking into account the number of processors, the size of their caches, whether there is hardware support for SSE instructions, etc.
Cython can increase the speed of SageMath programs, as the Python code is converted into C.

## Licensing and availability

SageMath is free software, distributed under the terms of the GNU General Public License version 3.
Windows: SageMath 10.0 (May 2023) requires Windows Subsystem for Linux in version 2, which in turn requires Windows to run as a Hyper-V client. SageMath 8.0 (July 2017), with development funded by the OpenDreamKit project, successfully built on Cygwin, and a binary installer for 64-bit versions of Windows was available. Although Microsoft was sponsoring a Windows version of SageMath, prior to 2016 users of Windows had to use virtualization technology such as VirtualBox to run SageMath.
Linux: Linux distributions in which SageMath is available as a package are Fedora, Arch Linux, Debian, Ubuntu and NixOS. In Gentoo, it is available via layman in the "sage-on-gentoo" overlay. The package used by NixOS is available for use on other distributions, due to the distribution-agnostic nature of its package manager, Nix.
Other operating systems: Gentoo prefix also provides Sage on other operating systems.

## Software packages contained in SageMath

The philosophy of SageMath is to use existing open-source libraries wherever they exist. Therefore, it uses many libraries from other projects.
| Mathematics packages contained in SageMath | Algebra | GAP, Singular, FLINT |
| Mathematics packages contained in SageMath | Algebraic geometry | Singular |
| Mathematics packages contained in SageMath | Arbitrary-precision arithmetic | GMP, MPFR, MPFI, NTL, mpmath, Arb |
| Mathematics packages contained in SageMath | Arithmetic geometry | PARI/GP, NTL, mwrank, ECM |
| Mathematics packages contained in SageMath | Calculus | Maxima, SymPy, GiNaC, Giac, FriCAS |
| Mathematics packages contained in SageMath | Combinatorics | Symmetrica, Sage-Combinat |
| Mathematics packages contained in SageMath | Linear algebra | ATLAS, BLAS, LAPACK, NumPy, LinBox, IML, GSL |
| Mathematics packages contained in SageMath | Graph theory | NetworkX |
| Mathematics packages contained in SageMath | Group theory | GAP |
| Mathematics packages contained in SageMath | Numerical computation | GSL, SciPy, NumPy, ATLAS |
| Mathematics packages contained in SageMath | Number theory | PARI/GP, FLINT, NTL |
| Mathematics packages contained in SageMath | Statistical computing | R, SciPy |
| Other packages contained in SageMath | Command-line shell | IPython |
| Other packages contained in SageMath | Database | ZODB, SQLite |
| Other packages contained in SageMath | Graphical interface | SageMath Notebook, MathJax (formerly jsMath) |
| Other packages contained in SageMath | Graphics | matplotlib, Tachyon, GD, Jmol |
| Other packages contained in SageMath | Interactive programming language | Python |
| Other packages contained in SageMath | Networking | Twisted |
| Other Mathematics package available for SageMath | Differential geometry and tensor calculus | Sage Manifolds |