OjAlgo

OjAlgo
Original authorAnders Peterson
Stable release
v56.1.1 / November 9, 2025 (2025-11-09)
Written inJava
Operating systemCross-platform
PlatformJava
TypeLibrary
LicenseMIT License
Websitewww.ojalgo.org
Repositorygithub.com/optimatika/ojAlgo

oj! Algorithms or ojAlgo, is an open source Java library for mathematics, linear algebra and optimisation. It was first released in 2003 and is 100% pure Java source code and free from external dependencies. Its feature set make it particularly suitable for use within the financial domain.

Capabilities

It requires Java 8 since version v38. As of version 44.0, the finance specific code has been moved to its own project/module named ojAlgo-finance.

Usage example

Example of singular value decomposition:

SingularValue<Double> svd = SingularValueDecomposition.make(matA);
svd.compute(matA);

MatrixStore<Double> U = svd.getQ1();
MatrixStore<Double> S = svd.getD();
MatrixStore<Double> V = svd.getQ2();

Example of matrix multiplication:

PrimitiveDenseStore result = FACTORY.makeZero(matA.getRowDim(), matB.getColDim());
result.fillByMultiplying(matA, matB);

See also