stdlib
stdlib copied to clipboard
[feature] Add more base routines for `stdlib_linalg`
Description
Fortran has its unique grammatical characteristics. I think it is impossible to learn from some routines of Matlab and Python completely. We should be based on the characteristics of Fortran.
Seeing the implementation of linspace/logspace in stdlib_math, I want to implement some routines in stdlib, mainly for stdlib_linalg.
Tasks
- [x]
zeros(see #478) - [x]
ones(see #478) - [x]
seq/arange(see #480) - [x]
eye, for matrix is not square. (see #481) - [ ]
det(need BLAS #450 ) - [x]
diff(see #605 )
- [x]
is_square - [x]
is_symmetric
Prior Art
Some routines has been implemented in keurfonluu/Forlab (MIT license).
I will rethink how to adapt to Fortran to write code.
I was thinking about proposing and implementing some matrix property checks like
is_square(not sure if it's the same isis_squared?)is_symmetricis_triangular(upper, lower, and diagonal can fit in here somewhere)is_hermitianis_hessenberg(upper, lower, etc.) etc.
I think there is at least a little bit about API to discuss here, since for example I have found it very useful for is_square to also set the dimension n. Also, there should be a very clean way to set the API for checks that can result in upper/lower/diagonal/none, but we could discuss what is best for everyone.
I can open an issue to discuss this if that works for you.