- write tests
- fix c/fortran api issue somehow
