lapack_inject/
lib.rs

1//! # lapack-inject
2//!
3//! LAPACK compatible interface backed by Fortran LAPACK function pointers.
4//!
5//! This crate allows you to use LAPACK functions while the actual computation
6//! is performed by Fortran LAPACK functions provided at runtime.
7//! This is useful for integrating with Python (scipy) or Julia (libblastrampoline)
8//! where Fortran LAPACK pointers are available.
9//!
10//! ## Usage
11//!
12//! ```ignore
13//! use lapack_inject::register_dgesv;
14//!
15//! // Register Fortran dgesv pointer (e.g., from scipy or Julia)
16//! unsafe {
17//!     register_dgesv(dgesv_ptr);
18//! }
19//!
20//! // Now lapack_inject exports dgesv_ symbol that can be used by other crates
21//! ```
22//!
23//! ## lapack-src/lapack-sys Compatibility
24//!
25//! This crate exports all Fortran-style LAPACK symbols defined in lapack-sys
26//! (e.g., `dgesv_`, `dgetrf_`, etc.). These symbols are compatible with the
27//! lapack-src crate. Register function pointers at runtime, and this crate
28//! will provide the symbols that other crates expect from lapack-src.
29//!
30//! ## Supported Functions
31//!
32//! All 1315 LAPACK functions from lapack-sys are supported, including:
33//! - Linear solvers (GESV, GBSV, POSV, SYSV, etc.)
34//! - Factorizations (GETRF, POTRF, GEQRF, etc.)
35//! - SVD (GESVD, GESDD, etc.)
36//! - Eigenvalue problems (GEEV, SYEV, HEEV, GEES, etc.)
37//! - And many more...
38
39mod backend;
40pub mod fortran;
41mod types;
42
43pub use backend::*;
44pub use fortran::*;
45pub use types::*;