Skip to content

Releases: QuantumKitHub/MatrixAlgebraKit.jl

v0.6.1

28 Dec 14:25
b6eaf3d

Choose a tag to compare

MatrixAlgebraKit v0.6.1

Diff since v0.6.0

Compare: v0.6.0...v0.6.1
Date: 2025-12-28

Added

  • Support for null-space computation via Householder QR in the GenericLinearAlgebra extension (#132).
  • New truncated-eigensolver variants: eig_trunc_no_error and eigh_trunc_no_error (#117).
  • New truncated-singular value variant: svd_trunc_no_error to improve GPU synchronization and AD support (#116).
  • AD: ChainRules support for svd_vals, eig_vals, eigh_vals, and diagonal (#107).

Changed

  • Improved GPU compatibility for some wrapper arrays (#100).
  • Test infrastructure migrated to a common TestSuite to reduce duplication (#119, #130, #131, #127, #125, #123, #124).

Fixed

  • ishermitian now correctly handles all-zero matrices (#121).

Merged pull requests:

Closed issues:

  • [Autodiff] svd_vals is not differentiable (#88)
  • Memory optimizations for large-scale SVD on GPU (#111)
  • Further questions about truncation error reporting for svd_trunc! (#114)
  • check_hermitian fails for zero-matrix (#120)

v0.6.0

14 Nov 22:44
eceef30

Choose a tag to compare

MatrixAlgebraKit v0.6.0

Diff since v0.5.0

We are pleased to announce the release of MatrixAlgebraKit.jl v0.6.0! This release brings significant new features, enhanced GPU support, and improved automatic differentiation capabilities.

🎉 Highlights

  • Expanded GPU Support: GPU acceleration for polar decomposition, projections, and orthogonal space computations
  • Mooncake AD Integration: New reverse-mode automatic differentiation rules using Mooncake.jl
  • BigFloat Support: Arbitrary precision computing via GenericLinearAlgebra extension
  • New Projection Operations: Introduction of project_isometric for manifold projections
  • Enhanced Matrix Properties: New functions for Hermitian and anti-Hermitian decomposition

✨ New Features

Matrix Projections

  • project_isometric - Project matrices onto the isometric manifold (#67)
  • PolarNewton - New Newton-iteration-based algorithm for polar decomposition (#67)

Matrix Property Functions

New functions for analyzing and manipulating matrix properties (#64):

  • ishermitian - Check if a matrix is Hermitian
  • isantihermitian - Check if a matrix is anti-Hermitian
  • hermitianpart! / hermitianpart - Extract Hermitian component (in-place and allocating)
  • antihermitianpart! / antihermitianpart - Extract anti-Hermitian component (in-place and allocating)

Extended Type Support

  • BigFloat precision through new GenericLinearAlgebra extension (#87)
  • GPU wrapper types now have default algorithm implementations (#49)

Automatic Differentiation

  • Mooncake.jl reverse-mode AD rules added (#85)

GPU Acceleration

Extended GPU support across multiple operations:

  • Image and null space computations (#82)
  • Polar decomposition (#83)
  • Projection operations (#81)
  • Improved SVD operations (#80)

Truncation Features

  • Truncation error output for truncated decompositions (#75)
  • Enhanced documentation for truncated decomposition keyword arguments (#71)

🔄 Breaking Changes

Renamed Functions

  • isisometryisisometric for consistency with project_isometric (#73)

Interface Changes

  • Refactored interface for left_orth, right_orth, left_null, and right_null (#79)

🔧 Improvements

Behavior Changes

  • Optional gauge fixing - gaugefix! is now optional (#95)
  • Relaxed Hermitian checks - Loosened strictness on hermiticity checks (#78)
  • Updated pullback tolerances for improved numerical stability when the input norms are large or small (#92)

📦 Dependencies

New Extensions

  • MatrixAlgebraKitGenericLinearAlgebraExt - BigFloat support
  • MatrixAlgebraKitGenericSchurExt - BigFloat support
  • MatrixAlgebraKitMooncakeExt - Mooncake AD integration

Compatibility

  • Julia: 1.10+
  • AMDGPU: 2
  • CUDA: 5
  • ChainRulesCore: 1
  • GenericLinearAlgebra: 0.3.19+
  • GenericSchur: 0.5.6+
  • Mooncake: 0.4.174+

🙏 Acknowledgments

Thank you to all contributors who made this release possible! Special thanks to those who submitted pull requests, reported issues, and participated in discussions.

📚 Documentation

For detailed documentation, please visit:

🔗 Links


For any issues or questions, please file an issue on our GitHub repository.

Merged pull requests:

  • Updates for TensorKit compatibility (#49) (@kshyatt)
  • [Feature] Add ishermitian, isantihermitian, hermitianpart(!) and antihermitianpart(!) (#64) (@lkdvos)
  • [Features] project_isometric and PolarNewton (#67) (@Jutho)
  • remove additional unnecessary ::AbstractMatrix annotation (#70) (@lkdvos)
  • Add documentation for truncated decomposition keyword arguments (#71) (@Copilot)
  • Rename isisometry to isisometric for consistency with project_isometric (#73) (@Copilot)
  • Output truncation error for truncated decompositions (#75) (@Jutho)
  • Loosen strictness on hermitian checks (#78) (@lkdvos)
  • Refactor orthogonalization and nullspace interface (#79) (@lkdvos)
  • GPU improvements for SVD (#80) (@kshyatt)
  • Support new projections on GPU (#81) (@kshyatt)
  • Add tests for image and null space for GPU (#82) (@kshyatt)
  • Add tests for polar decomposition for GPU (#83) (@kshyatt)
  • Mooncake reverse rules (#85) (@kshyatt)
  • add support for BigFloats via a new extension (#87) (@sanderdemeyer)
  • update pullback tolerances (#92) (@lkdvos)
  • Make gaugefix! optional (#95) (@lkdvos)
  • Release v0.6 + small fixes (#97) (@lkdvos)

Closed issues:

  • safe_inv should have a different tol from pullback_gaugetol (#7)
  • [Feature request] Add support for BigFloats (#8)
  • Support passing Hermitian matrix to eigh_x (#35)
  • left_orth and right_orth interface improvements (#66)
  • Document how to pass a truncation strategy to a truncated factorization (and other kwarg mysteries) (#68)
  • Rename isisometry to isisometric (#69)
  • Reinstate outputting the truncation error for truncated decompositions (#72)
  • Necessity of the hard symmetry/hermiticity checks in eigh(!) decompositions (#76)
  • [Bug] SVD pullback does not properly take into account the norm of the initial matrix (#89)

v0.5.0

01 Oct 20:49
4ab245c

Choose a tag to compare

MatrixAlgebraKit v0.5.0

Diff since v0.4.1

This release introduces pullback functions for nullspace decompositions, refactors the truncation interface to return indices, and includes several code quality improvements and internal consistency enhancements.


🚀 New Features & Enhancements

  • Nullspace Pullback Functions: Added dedicated pullback functions qr_null_pullback! and lq_null_pullback! for computing gradients through nullspace decompositions. These functions provide a cleaner and more efficient interface for automatic differentiation through qr_null and lq_null operations.

  • Renamed Pullback Functions: The pullback functions have been renamed for consistency:

    • qr_compact_pullback!qr_pullback!
    • lq_compact_pullback!lq_pullback!

    The new names are marked as public and are now part of the package's public API.

  • Changed Truncation Interface: The internal truncate function replaces the old truncate! and returns both the truncated result and the indices that were kept, enabling more efficient implementations in ChainRules extensions and other downstream code.

  • Enhanced ChainRules Integration:

    • Streamlined pullback implementations for qr_null! and lq_null! to use the new dedicated pullback functions
    • Improved type stability in truncation-related rules
    • Added @non_differentiable declarations for utility functions (select_algorithm, initialize_output, check_input, isisometry, isunitary)
    • More generic type signatures (removed AbstractMatrix constraints) for better compatibility with custom array types

📋 Public API Changes and breaking changes

New Public Functions

  • qr_null_pullback! - Compute pullback for QR nullspace decomposition
  • lq_null_pullback! - Compute pullback for LQ nullspace decomposition
  • truncate - Now marked as public (previously unexported truncate!)

Renamed Functions

  • qr_compact_pullback!qr_pullback! (old name removed)
  • lq_compact_pullback!lq_pullback! (old name removed)

Note: The previous pullback function names are no longer available. If you were using these internal functions (they were not exported but marked as public in v0.4.1), you will need to update your code to use the new names.


🔧 Migration Guide

If you were using the pullback functions directly:

# Old code (v0.4.1)
qr_compact_pullback!(ΔA, A, QR, ΔQR)
lq_compact_pullback!(ΔA, A, LQ, ΔLQ)

# New code (v0.5.0)
qr_pullback!(ΔA, A, QR, ΔQR)
lq_pullback!(ΔA, A, LQ, ΔLQ)

For nullspace pullbacks, use the new dedicated functions:

# v0.5.0
qr_null_pullback!(ΔA, A, N, ΔN)
lq_null_pullback!(ΔA, A, Nᴴ, ΔNᴴ)

Replace truncate!(args...) calls with truncate, ensure they don't mutate the input arguments and also return the truncated inds.


For further details, see the updated docs and the diff for this release: v0.4.1...v0.5.0

Merged pull requests:

  • Replace truncate! with truncate (#60) (@lkdvos)
  • More consistent API for when to have _full, _compact, ... (#61) (@lkdvos)
  • Add qr_null_pullback! and lq_null_pullback! (#62) (@lkdvos)
  • Loosen AbstractArray restrictions where these are not necessary (#63) (@lkdvos)

v0.4.1

29 Sep 15:29

Choose a tag to compare

MatrixAlgebraKit v0.4.1

Diff since v0.4.0

🚀 New Features & Enhancements

  • Truncated factorization pullbacks:: The chainrules have now been extended to truncated decompositions. This required a slight modification to the previous pullback function API, which is deemed non-breaking as these methods were not exported, nor marked as public. Henceforth however, the pullback methods are marked as public.

For further details, see the updated docs and the diff for this release: v0.4.0...v0.4.1

Merged pull requests:

v0.4.0

26 Sep 15:17
6c0b297

Choose a tag to compare

MatrixAlgebraKit v0.4.0

Diff since v0.3.2

This release introduces an overhaul of the truncation interface, significant improvements to consistency and code clarity, and generalizes the truncation API for matrix decompositions. It also includes some bug fixes, code cleanup, and improved documentation.
Note: This release contains breaking changes, especially in the truncation API and related function signatures.


🚀 New Features & Enhancements

  • Overhauled Truncation API

    • Introduced new types with consistent names: TruncationByOrder, TruncationByValue, TruncationByFilter, TruncationByError, and TruncationIntersection.
    • New user-facing convenience constructors: truncrank, trunctol, truncerror, truncfilter, and notrunc.
    • Renamed findtruncated_sorted to findtruncated_svd as the standard for SVD truncation (values assumed sorted).
    • Documentation for the new truncation interface.
  • Export and API Changes

    • New exports: notrunc, truncrank, trunctol, truncerror, truncfilter.
    • New public structs: TruncationByOrder, TruncationByValue, TruncationByFilter, TruncationByError and TruncationIntersection
    • Improved and clarified exported algorithm types.
  • Documentation Improvements

    • Improved and clarified docstrings for truncation strategies.
  • Developer Improvements

    • Separated the truncation interface and implementation to src/interface/truncation.jl and src/implementation/truncation.jl
    • Switched to the Runic.jl code formatter

💥 Breaking Changes

  • Truncation API has changed:

    • The old TruncationKeepAbove, TruncationKeepBelow, and TruncationKeepSorted are replaced by new types and constructors.
    • All places accepting a truncation strategy now expect the new types or the new keyword-based syntax (see docs).
    • The function findtruncated_sorted is replaced by findtruncated_svd.
    • The default truncation strategy is now notrunc() instead of NoTruncation().
    • Function signatures for all decomposition and truncation routines have changed to use the new API.
  • Keyword Arguments:

    • Truncation-related keyword arguments have changed (maxrank instead of howmany, trunctol(; atol, rtol, ...), etc.).
    • keep_below keyword controls whether the truncation keeps values below or above the threshold.
  • Test and Extension Code:

    • All code using the old truncation types or calling decomposition/truncation routines will need to be updated for compatibility.

🛠️ Internal & Code Quality

  • Code formatting through Runic
  • Bg fixes and clarifications in test code and docstrings.

For further details, see the updated docs and the diff for this release: v0.3.2...v0.4.0

Disclaimer: these notes have been generated with the help of Copilot -- check for correctness.

Merged pull requests:

  • Fix Jacobi error message (#54) (@kshyatt)
  • Refactor truncation module + add truncerror (#55) (@lkdvos)
  • TruncationStrategy types and constructors: consistency in names and implementations (#56) (@lkdvos)
  • Small fixes and improvements (#57) (@lkdvos)
  • Switch to Runic formatter (#58) (@lkdvos)

v0.3.2

10 Sep 12:39
61f9869

Choose a tag to compare

MatrixAlgebraKit v0.3.2

Diff since v0.3.1

Merged pull requests:

v0.3.1

05 Sep 15:31
7531d17

Choose a tag to compare

MatrixAlgebraKit v0.3.1

Diff since v0.3.0

Merged pull requests:

v0.3.0

18 Aug 17:57
cbecd7b

Choose a tag to compare

MatrixAlgebraKit v0.3.0

Diff since v0.2.5

Changelog:

  • Added support for CUDA and ROCm through extensions -- currently QR, LQ, and SVD are supported on GPU
  • Added support for svd_trunc! on GPU including randomized SVD from CUDA
  • Added support for generalized eigensolving (CPU only)
  • Modified check_input to allow algorithm-specific checks
  • Added gaugefix function for eigensolving and SVD

Merged pull requests:

v0.2.5

15 Jun 16:50
b38df0e

Choose a tag to compare

MatrixAlgebraKit v0.2.5

Diff since v0.2.4

This release features the new isisometry(A; kind=:left), isisometry(A; kind=:right) and isunitary functions to conveniently verify whether or not A' * A = I and/or A * A' = I.

Merged pull requests:

  • Add isisometry function and integrate into tests (#38) (@lkdvos)

v0.2.4

12 Jun 16:00
dfa334d

Choose a tag to compare

MatrixAlgebraKit v0.2.4

Diff since v0.2.3

Merged pull requests:

  • Handle empty matrices in svd_full and add tests (#37) (@lkdvos)

Closed issues:

  • svd_full with empty matrices: (#12)