Cuexpm
Matrix Exponential Approximation using CUDA
Install / Use
/learn @maximilianbehr/CuexpmREADME
cuexpm - Matrix Exponential Approximation using CUDA
Version: 2.0.0
Copyright: Maximilian Behr
License: The software is licensed under under MIT. See LICENSE for details.
cuexpm is a CUDA library for the numerical approximation of the matrix exponential $e^A$.
cuexpm supports single and double precision as well as real and complex matrices.
| Functions | Data |
| ---------------------------------|----------------------------------|
| cuexpms_bufferSize, cuexpms | real, single precision matrix |
| cuexpmd_bufferSize, cuexpmd | real, double precision matrix |
| cuexpmc_bufferSize, cuexpmc | complex, single precision matrix |
| cuexpmz_bufferSize, cuexpmz | complex, double precision matrix |
Available functions:
int cuexpms_bufferSize(const int n, size_t *d_bufferSize, size_t *h_bufferSize);
int cuexpms(const int n, const float *d_A, const int ldA, void *d_buffer, void *h_buffer, float *d_expmA, const int ldexpmA);
int cuexpmd_bufferSize(const int n, size_t *d_bufferSize, size_t *h_bufferSize);
int cuexpmd(const int n, const double *d_A, const int ldA, void *d_buffer, void *h_buffer, double *d_expmA, const int ldexpmA);
int cuexpmc_bufferSize(const int n, size_t *d_bufferSize, size_t *h_bufferSize);
int cuexpmc(const int n, const cuComplex *d_A, const int ldA, void *d_buffer, void *h_buffer, cuComplex *d_expmA, const int ldexpmA);
int cuexpmz_bufferSize(const int n, size_t *d_bufferSize, size_t *h_bufferSize);
int cuexpmz(const int n, const cuDoubleComplex *d_A, const int ldA, void *d_buffer, void *h_buffer, cuDoubleComplex *d_expmA, const int ldexpmA);
Algorithm
cuexpm implements the scaling and squaring method for the matrix exponential approximation.
The Scaling and Squaring Method for the Matrix Exponential Revisited Nicholas J. Higham SIAM Journal on Matrix Analysis and Applications 2005 26:4, 1179-1193
Installation
Prerequisites:
CMake >= 3.23CUDA >= 11.4.2
mkdir build && cd build
cmake ..
make
make install
Usage and Examples
We provide examples for all supported matrix formats:
| File | Data |
| -------------------------------------------|----------------------------------|
| example_cuexpms.cu | real, single precision matrix |
| example_cuexpmd.cu | real, double precision matrix |
| example_cuexpmc.cu | complex, single precision matrix |
| example_cuexpmz.cu | complex, double precision matrix |
Related Skills
node-connect
341.2kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
frontend-design
84.5kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
openai-whisper-api
341.2kTranscribe audio via OpenAI Audio Transcriptions API (Whisper).
commit-push-pr
84.5kCommit, push, and open a PR
