Introduction#
What is sigmaepsilon.math?#
The `sigmaepsilon.math`_ library is the mathematical department of the SigmaEpsilon project, a collection of Python libraries for computational mechanics and related disciplines. It includes the tools that emerged during work on other parts of the SigmaEpsilon ecosystem.
Since most of these tools are general enough to be useful in other contexts, we decided to extract them into a separate library.
What can I use it for?#
The main areas of focus are linear algebra, optimization, approimation and graph theory. The most important features are highlighted below and each topic is covered in detail in the User Guide.
The library also provides some classes which are good base classes or are accessible inside Numba-jitted code, paving the way for further development in various topics.
Highlights#
-
A
ReferenceFrameclass for all kinds of frames, and dedicatedRectangularFrameandCartesianFrameclasses as special cases, all NumPy compliant.NumPy compliant classes like
TensorandVectorto handle various kinds of tensorial quantities efficiently with a built-in mechanism that guarantees to maintain the property of objectivity.A
JaggedArrayand a Numba-jittablecsr_matrixto handle sparse data.
-
Classes to define and solve linear and nonlinear optimization problems.
A
LinearProgrammingProblemclass to define and solve continuous, integer or mixed-integer linear optimization problems.A
BinaryGeneticAlgorithmclass to tackle more complicated optimization problems.
-
Several methods and classes to approximate functions and data, including a
MLSApproximatorfor multilinear regression using the moving least squares method.
-
Algorithms to calculate rooted level structures and pseudo peripheral nodes of a graph, and a
Graphclass that extendsnetworkx.Graph.
Is it fast?#
Yes, it is. The library is designed to be fast, as it relies on the vector math capabilities of `NumPy`_ and `SciPy`_, while other computationally sensitive calculations are JIT-compiled using `Numba`_. Thanks to `Numba`_, the implemented algorithms are able to bypass the limitations of Python’s GIL and are parallelized on multiple cores, utilizing the full potential of what the hardware has to offer.
How do I install sigmaepsilon.math?#
To install the library, follow the instructions in the Installation Guide.