https://github.com/atelierarith/easyeigeninterface.jl
We don't say "Eigen is easy"
https://github.com/atelierarith/easyeigeninterface.jl
cxx eigen julia julialang
Last synced: 6 months ago
JSON representation
We don't say "Eigen is easy"
- Host: GitHub
- URL: https://github.com/atelierarith/easyeigeninterface.jl
- Owner: AtelierArith
- Created: 2024-06-14T19:34:46.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-08-23T14:26:44.000Z (over 1 year ago)
- Last Synced: 2025-07-08T22:02:46.281Z (6 months ago)
- Topics: cxx, eigen, julia, julialang
- Language: Julia
- Homepage:
- Size: 8.79 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# EasyEigenInterface.jl
This Julia package wraps some data types in `Eigen`, a C++ template library for linear algebra such as `MatrixXd`, `VectorXd`.
The design is strongly inspired by the work of `@barche` [JuliaCon 2020 workshop on CxxWrap.jl](https://github.com/barche/cxxwrap-juliacon2020/tree/master).
## Usage
```julia
using EasyEigenInterface
x = Float64[1 2 3; 4 5 6]
@assert MatrixXd(MatrixXd(x)) == MatrixXd(x) == x
m = MatrixXd(x)
@assert rows(m) == 2
@assert cols(m) == 3
jlm = Matrix{Float64}(undef, 2, 3)
jlm .= m
@assert jlm == m
resize!(m, 3, 2)
@assert rows(m) == 3
@assert cols(m) == 2
```
I believe this may be helpful for those interested in using C++ libraries from Julia.