Frechet derivative of the matrix exponential of A in the direction E.
New in version 0.13.0.
Parameters: | A : (N, N) array_like
E : (N, N) array_like
method : str, optional
compute_expm : bool, optional
check_finite : boolean, optional
|
---|---|
Returns: | expm_A : ndarray
expm_frechet_AE : ndarray
For compute_expm = False, only expm_frechet_AE is returned. |
See also
Notes
This section describes the available implementations that can be selected by the method parameter. The default method is SPS.
Method blockEnlarge is a naive algorithm.
Method SPS is Scaling-Pade-Squaring [R68]. It is a sophisticated implementation which should take only about 3/8 as much time as the naive implementation. The asymptotics are the same.
References
[R68] | (1, 2) Awad H. Al-Mohy and Nicholas J. Higham (2009) Computing the Frechet Derivative of the Matrix Exponential, with an application to Condition Number Estimation. SIAM Journal On Matrix Analysis and Applications., 30 (4). pp. 1639-1657. ISSN 1095-7162 |
Examples
>>> import scipy.linalg
>>> A = np.random.randn(3, 3)
>>> E = np.random.randn(3, 3)
>>> expm_A, expm_frechet_AE = scipy.linalg.expm_frechet(A, E)
>>> expm_A.shape, expm_frechet_AE.shape
((3, 3), (3, 3))
>>> import scipy.linalg
>>> A = np.random.randn(3, 3)
>>> E = np.random.randn(3, 3)
>>> expm_A, expm_frechet_AE = scipy.linalg.expm_frechet(A, E)
>>> M = np.zeros((6, 6))
>>> M[:3, :3] = A; M[:3, 3:] = E; M[3:, 3:] = A
>>> expm_M = scipy.linalg.expm(M)
>>> np.allclose(expm_A, expm_M[:3, :3])
True
>>> np.allclose(expm_frechet_AE, expm_M[:3, 3:])
True