Macaulay2 » Documentation
Packages » GraphicalModelsMLE :: checkPD(...,ZeroTolerance=>...)
next | previous | forward | backward | up | index | toc

# checkPD(...,ZeroTolerance=>...) -- optional input to set the largest absolute value that should be treated as zero

- Usage:
    `checkPD(L,ZeroTolerance=>n)`
- Inputs:
  - n, a real number, default is 1e-10

## Description

A matrix is assumed to be positive definite if for all eigenvalues e:

- realPart e > ZeroTolerance

- abs imaginaryPart e <= ZeroTolerance

If a matrix contains an imaginary part below the tolerance level, then only the real part is reported in the output.

    i1 : L={matrix{{10^(-9)+10^(-10)*sqrt(-1),0},{0,10^(-9)+10^(-10)*sqrt (-1)}},
             matrix{{10^(-10)+10^(-10)*sqrt(-1),0},{0,10^(-10)+10^(-10)*sqrt (-1)}},
             matrix{{1+10^(-10)*sqrt(-1),0},{0,1+10^(-10)*sqrt (-1)}},
             matrix{{1-10^(-9)*sqrt(-1),0},{0,1+10^(-9)*sqrt (-1)}}
             }

    o1 = {| 1e-9+1e-10ii 0            |, | 1e-10+1e-10ii 0             |, |
          | 0            1e-9+1e-10ii |  | 0             1e-10+1e-10ii |  |
         ------------------------------------------------------------------------
         1+1e-10ii 0         |, | 1-1e-9ii 0        |}
         0         1+1e-10ii |  | 0        1+1e-9ii |

    o1 : List

    i2 : checkPD L

    o2 = {| 1e-9 0    |, | 1 0 |}
          | 0    1e-9 |  | 0 1 |

    o2 : List

## See also

- checkPSD(...,ZeroTolerance=>...) -- optional input to set the largest absolute value that should be treated as zero
- solverMLE -- Maximum likelihood estimate of a loopless mixed graph

## Functions with optional argument named ZeroTolerance:

- checkPD(...,ZeroTolerance=>...) -- optional input to set the largest absolute value that should be treated as zero
- checkPSD(...,ZeroTolerance=>...) -- optional input to set the largest absolute value that should be treated as zero
- solverMLE(...,ZeroTolerance=>...) -- optional input to set the largest absolute value that should be treated as zero

## Further information

- Default value: 1e-10
- Function: checkPD -- returns positive definite matrices from a list of symmetric matrices
- Option key: ZeroTolerance -- optional input to set the largest absolute value that should be treated as zero

The source of this document is in /build/macaulay2-88fgJW/macaulay2-1.25.11+ds/M2/Macaulay2/packages/GraphicalModelsMLE.m2:1725:0.