Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new method for matrix exponential #33

Merged
merged 1 commit into from Dec 2, 2019

Conversation

yoshoku
Copy link
Contributor

@yoshoku yoshoku commented Nov 30, 2019

I have implemented the matrix exponential method for issue #32 . In scipy, it is implemented using the newer algorithm, but I implemented it using the basic pade approximation method[1].

Example of execution results like scipy.linalg.expm

> Numo::Linalg.expm(Numo::DFloat.zeros([2,2]))
=> Numo::DFloat#shape=[2,2]
[[1, 0],
 [0, 1]]
> Numo::Linalg.expm(Numo::DFloat[[1, 2], [-1, 3]] * Complex::I)
=> Numo::DComplex#shape=[2,2]
[[0.426459+1.89218i, -2.13721-0.978113i],
 [1.06861+0.489056i, -1.71076+0.914063i]]

[1] Gene H. Golub and Charles F. Van Loan, "Matrix Computations 4th Edition: Algorithm 9.3.1," JHU Press, 2013.

@masa16 masa16 merged commit c0d7f39 into ruby-numo:master Dec 2, 2019
@yoshoku
Copy link
Contributor Author

yoshoku commented Dec 2, 2019

Thank you.

@yoshoku yoshoku deleted the add_expm_method branch December 2, 2019 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants