SciPy 0.6.0 API Documentation Generated by Endo, 2007-10-17
cast = numpy.cast
eps = numpy.finfo(float).eps
feps = numpy.finfo(single).eps
r_ = numpy.r_
Compute Cholesky decomposition of matrix and return an object to be used for solving a linear system using cho_solve.
Solve a previously factored symmetric system of equations. First input is a tuple (LorU, lower) which is the output to cho_factor. Second input is the right-hand side.
Compute Cholesky decomposition of matrix.
Description:
For a hermitian positive-definite matrix a return the upper-triangular (or lower-triangular if lower==1) matrix, u such that u^H * u = a (or l * l^H = a).
Return sigma from singular values and original size M,N.
Solve ordinary and generalized eigenvalue problem
of a square matrix.
Inputs:
a -- An N x N matrix.
b -- An N x N matrix [default is identity(N)].
left -- Return left eigenvectors [disabled].
right -- Return right eigenvectors [enabled].
overwrite_a, overwrite_b -- save space by overwriting the a and/or
b matrices (both False by default)
Outputs:
w -- eigenvalues [left==right==False].
w,vr -- w and right eigenvectors [left==False,right=True].
w,vl -- w and left eigenvectors [left==True,right==False].
w,vl,vr -- [left==right==True].
Definitions:
a * vr[:,i] = w[i] * b * vr[:,i]
a^H * vl[:,i] = conjugate(w[i]) * b^H * vl[:,i]
where a^H denotes transpose(conjugate(a)).
Solve real symmetric or complex hermetian band matrix problem.
Inputs:
a_band -- A hermitian N x M matrix in 'packed storage'.
Packed storage looks like this: ('upper form')
[ ... (more off-diagonals) ...,
[ * * a13 a24 a35 a46 ... a(n-2)(n)],
[ * a12 a23 a34 a45 a56 ... a(n-1)(n)],
[ a11 a22 a33 a44 a55 a66 ... a(n)(n) ]]
The cells denoted with * may contain anything.
lower -- a is in lower packed storage
(default: upper packed form)
eigvals_only -- if True, don't compute eigenvectors.
overwrite_a_band -- content of a may be destroyed
select -- 'a', 'all', 0 : return all eigenvalues/vectors
'v', 'value', 1 : eigenvalues in the interval (min, max]
will be found
'i', 'index', 2 : eigenvalues with index [min...max]
will be found
select_range -- select == 'v': eigenvalue limits as tuple (min, max)
select == 'i': index limits as tuple (min, max)
select == 'a': meaningless
max_ev -- select == 'v': set to max. number of eigenvalues that is
expected. In doubt, leave untouched.
select == 'i', 'a': meaningless
Outputs:
w,v -- w: eigenvalues, v: eigenvectors [for eigvals_only == False]
w -- eigenvalues [for eigvals_only == True].
Definitions:
a_full * v[:,i] = w[i] * v[:,i] (with full matrix corresponding to a)
v.H * v = identity
Solve real symmetric or complex hermitian eigenvalue problem.
Inputs:
a -- A hermitian N x N matrix.
lower -- values in a are read from lower triangle
[True: UPLO='L' (default) / False: UPLO='U']
eigvals_only -- don't compute eigenvectors.
overwrite_a -- content of a may be destroyed
Outputs:
For eigvals_only == False (the default),
w,v -- w: eigenvalues, v: eigenvectors
For eigvals_only == True,
w -- eigenvalues
Definitions:
a * v[:,i] = w[i] * vr[:,i]
v.H * v = identity
Return eigenvalues of square matrix.
Return eigenvalues of hermitean or real symmetric matrix.
Return eigenvalues of hermitean or real symmetric matrix.
Compute Hessenberg form of a matrix.
Inputs:
a -- the matrix
calc_q -- if non-zero then calculate unitary similarity
transformation matrix q.
overwrite_a=0 -- if non-zero then discard the contents of a,
i.e. a is used as a work array if possible.
Outputs:
h -- Hessenberg form of a [calc_q=0]
h, q -- matrices such that a = q * h * q^T [calc_q=1]
Return LU decompostion of a matrix.
Inputs:
a -- An M x N matrix.
permute_l -- Perform matrix multiplication p * l [disabled].
Outputs:
p,l,u -- LU decomposition matrices of a [permute_l=0]
pl,u -- LU decomposition matrices of a [permute_l=1]
Definitions:
a = p * l * u [permute_l=0]
a = pl * u [permute_l=1]
p - An M x M permutation matrix
l - An M x K lower triangular or trapezoidal matrix
with unit-diagonal
u - An K x N upper triangular or trapezoidal matrix
K = min(M,N)
Return raw LU decomposition of a matrix and pivots, for use in solving a system of linear equations.
Inputs:
a --- an NxN matrix
Outputs:
lu --- the lu factorization matrix piv --- an array of pivots
Solve a previously factored system. First input is a tuple (lu, pivots) which is the output to lu_factor. Second input is the right hand side.
Return an orthonormal basis for the range of A using svd
QR decomposition of an M x N matrix a.
Description:
Find a unitary (orthogonal) matrix, q, and an upper-triangular
matrix r such that q * r = a
Inputs:
a -- the matrix
overwrite_a=0 -- if non-zero then discard the contents of a,
i.e. a is used as a work array if possible.
lwork=None -- >= shape(a)[1]. If None (or -1) compute optimal
work array size.
econ=False -- computes the skinny or economy-size QR decomposition
only useful when M>N
mode='qr' -- if 'qr' then return both q and r; if 'r' then just return r
Outputs:
q,r - if mode=='qr'
r - if mode=='r'
QR decomposition of an M x N matrix a.
Description:
Find a unitary (orthogonal) matrix, q, and an upper-triangular
matrix r such that q * r = a
Inputs:
a -- the matrix
overwrite_a=0 -- if non-zero then discard the contents of a,
i.e. a is used as a work array if possible.
lwork=None -- >= shape(a)[1]. If None (or -1) compute optimal
work array size.
Outputs:
q, r -- matrices such that q * r = a
RQ decomposition of an M x N matrix a.
Description:
Find an upper-triangular matrix r and a unitary (orthogonal)
matrix q such that r * q = a
Inputs:
a -- the matrix
overwrite_a=0 -- if non-zero then discard the contents of a,
i.e. a is used as a work array if possible.
lwork=None -- >= shape(a)[1]. If None (or -1) compute optimal
work array size.
Outputs:
r, q -- matrices such that r * q = a
Convert real schur form to complex schur form.
Description:
If A is a real-valued matrix, then the real schur form is quasi-upper triangular. 2x2 blocks extrude from the main-diagonal corresponding to any complex-valued eigenvalues.
This function converts this real schur form to a complex schur form which is upper triangular.
Compute Schur decomposition of matrix a.
Description:
Return T, Z such that a = Z * T * (Z**H) where Z is a unitary matrix and T is either upper-triangular or quasi-upper triangular for output='real'
Compute singular value decomposition (SVD) of matrix a.
Description:
Singular value decomposition of a matrix a is
a = u * sigma * v^H,
where v^H denotes conjugate(transpose(v)), u,v are unitary
matrices, sigma is zero matrix with a main diagonal containing
real non-negative singular values of the matrix a.
Inputs:
a -- An M x N matrix.
compute_uv -- If zero, then only the vector of singular values
is returned.
Outputs:
u -- An M x M unitary matrix [compute_uv=1].
s -- An min(M,N) vector of singular values in descending order,
sigma = diagsvd(s).
vh -- An N x N unitary matrix [compute_uv=1], vh = v^H.
Return singular values of a matrix.
| Local name | Refers to |
|---|---|
| array | numpy.array |
| asarray | numpy.asarray |
| asarray_chkfinite | numpy.asarray_chkfinite |
| basic | SciPy.linalg.basic |
| calc_lwork | scipy.linalg.calc_lwork |
| complexfloating | numpy.complexfloating |
| diag | numpy.diag |
| find_best_lapack_type | SciPy.linalg.lapack.find_best_lapack_type |
| get_blas_funcs | SciPy.linalg.blas.get_blas_funcs |
| get_flinalg_funcs | SciPy.linalg.flinalg.get_flinalg_funcs |
| get_lapack_funcs | SciPy.linalg.lapack.get_lapack_funcs |
| inexact | numpy.inexact |
| isfinite | numpy.isfinite |
| LinAlgError | numpy.linalg.LinAlgError |
| numpy | numpy |
| ones | numpy.ones |
| single | numpy.single |
| warn | warnings.warn |
| zeros | numpy.zeros |