📄 mf_cholesky.hlp
字号:
{smcl}
{* 11mar2005}{...}
{cmd:help mata cholesky()}
{hline}
{* index LAPACK}{...}
{* index cholesky()}{...}
{* index _cholesky()}{...}
{* index Cholesky decomposition}{...}
{* index square root}{...}
{* index decomposition}{...}
{title:Title}
{p 4 4 2}
{bf:[M-5] cholesky() -- Cholesky square-root decomposition}
{title:Syntax}
{p 8 12 2}
{it:numeric matrix}
{cmd:cholesky(}{it:numeric matrix A}{cmd:)}
{p 8 12 2}
{it:void}{bind: }
{cmd:_cholesky(}{it:numeric matrix A}{cmd:)}
{title:Description}
{p 4 4 2}
{cmd:cholesky(}{it:A}{cmd:)} returns the Cholesky decomposition {it:G} of
symmetric (Hermitian), positive-definite matrix {it:A}.
{cmd:cholesky()} returns a lower-triangular matrix of missing values if
{it:A} is not positive definite.
{p 4 4 2}
{cmd:_cholesky(}{it:A}{cmd:)} does the same thing, except that it overwrites
{it:A} with the Cholesky result.
{title:Remarks}
{p 4 4 2}
The Cholesky decomposition {it:G} of a symmetric, positive-definite matrix
{it:A} is
{it:A} = {it:G}*{it:G}{bf:'}
{p 4 4 2}
where {it:G} is lower triangular.
When {it:A} is complex, {it:A} must be Hermitian, and {it:G}{bf:'}, of course,
is the conjugate transpose of {it:G}.
{p 4 4 2}
Decomposition is performed via {bf:{help m1_lapack:[M-1] LAPACK}}.
{title:Conformability}
{cmd:cholesky(}{it:A}{cmd:)}
{it:A}: {it:n x n}
{it:result}: {it:n x n}
{cmd:_cholesky(}{it:A}{cmd:)}
{it:input:}
{it:A}: {it:n x n}
{it:output:}
{it:A}: {it:n x n}
{title:Diagnostics}
{p 4 4 2}
{cmd:cholesky(}{cmd:)} returns a lower-triangular matrix of missing values
if {it:A} contains missing values or if {it:A} is not positive definite.
{p 4 4 2}
{cmd:_cholesky(}{it:A}{cmd:)} overwrites {it:A} with a lower-triangular
matrix of missing values if {it:A} contains missing values or if {it:A} is
not positive definite.
{p 4 4 2}
Both functions use the elements from the lower triangle of {it:A} without
checking whether {it:A} is symmetric or, in the complex case, Hermitian.
{title:Source code}
{p 4 4 2}
{view cholesky.mata, adopath asis:cholesky.mata};
{cmd:_cholesky()} is built-in.
{title:Also see}
{p 4 13 2}
Manual: {hi:[M-5] cholesky()}
{p 4 13 2}
Online: help for
{bf:{help mf_lud:[M-5] lud()}}
{bf:{help m4_matrix:[M-4] matrix}}
{p_end}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -