ddemidov / amgcl

C++ library for solving large sparse linear systems with algebraic multigrid method
http://amgcl.readthedocs.org/
MIT License
724 stars 110 forks source link

Julia and C Wrapper #273

Open j-fu opened 7 months ago

j-fu commented 7 months ago

Hi, thank you for the great package!

I just created a Julia wrapper package: https://github.com/j-fu/AMGCLWrap.jl

It uses another C Wrapper

https://github.com/j-fu/amgcl_c

which instantiates AMG and relaxation solvers for double numbers and OpenMP backend with blocksizes 1...8 . Passing of parameters goes via json strings which are easily generated from Julia dicts, structs or tuples via JSON3.jl, so they are not exposed to the user.

Compiled binaries of the C Wrapper are automatically precompiled for all architecturs supported by Julia: https://github.com/JuliaBinaryWrappers/AMGCL_C_jll.jl .

With time I plan to extend this ( complex, saddlepoint...)

Best regards

Jürgen

ddemidov commented 7 months ago

Thanks! Feel free to create a PR to AMGCL with a link to your repo in README )

j-fu commented 7 months ago

I'll check a bit how it performs in a couple of projects, when it appears to be stable I will do the PR.