IsDefinite - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


LinearAlgebra

  

IsDefinite

  

test for positive or negative definite or indefinite Matrices

 

Calling Sequence

Parameters

Description

Examples

Calling Sequence

IsDefinite(A, q)

Parameters

A

-

square Matrix

q

-

equation of the form query = attribute where attribute is one of 'positive_definite', 'positive_semidefinite', 'negative_definite', 'negative_semidefinite', or 'indefinite'

Description

• 

The IsDefinite(A, query = 'positive_definite') returns true if A is a real symmetric or a complex Hermitian Matrix and all the eigenvalues are determined to be positive.  Because the default query is query = 'positive_definite', this command is equivalent to IsDefinite(A).

  

Similarly, for real symmetric or complex Hermitian Matrices, the following calling sequences return the indicated result:

  

IsDefinite(A, query = 'positive_semidefinite') returns true if all the eigenvalues are determined to be nonnegative.

  

IsDefinite(A, query = 'negative_definite') returns true if all the eigenvalues are determined to be negative.

  

IsDefinite(A, query = 'negative_semidefinite') returns true if all the eigenvalues are determined to be non-positive.

  

IsDefinite(A, query = 'indefinite') returns true if at least one eigenvalue is determined to be positive and at least one eigenvalue is determined to be negative.

  

If the eigenvalues are determined to be other than described in the cases above, a value of false is returned.

  

If the requested query cannot be resolved, this routine returns a boolean expression representing the condition which must be satisfied for that resolution to be true.

• 

The definition of positive definite is that, for all column Vectors x, 0<HermitianTransposex·A·x.

  

The definitions for positive semidefinite, negative definite, and negative semidefinite involve reversal of the inequality sign, or relaxation from a strict inequality.

  

The definition of indefinite is that it is equivalent to not positive semidefinite and not negative semidefinite.

• 

A complex, non-Hermitian Matrix A has the same definiteness as its Hermitian part, that is, A2+HermitianTransposeA2.

  

A real, non-symmetric Matrix A has the same definiteness as its symmetric part, that is, A2+TransposeA2.

• 

This function is part of the LinearAlgebra package, and so it can be used in the form IsDefinite(..) only after executing the command with(LinearAlgebra). However, it can always be accessed through the long form of the command by using LinearAlgebra[IsDefinite](..).

Examples

withLinearAlgebra&colon;

ADiagonalMatrix5&comma;0&comma;1

A−50000000−1

(1)

IsDefiniteA

false

(2)

IsDefiniteA&comma;query=positive_semidefinite

false

(3)

IsDefiniteA&comma;query=negative_semidefinite

true

(4)

B1&comma;8&comma;3|4&comma;5&comma;2|6&comma;1&comma;0

B1−46851320

(5)

IsDefiniteB

false

(6)

C1&comma;2+I|2I&comma;5

C12I2+I5

(7)

IsDefiniteC

false

(8)

IsDefiniteC&comma;query=positive_semidefinite

true

(9)

IsDefiniteC&comma;query=negative_semidefinite

false

(10)

In the next example, the result of the query depends on the values assigned to x and y.

assumex&comma;real&comma;y&comma;real

IsDefinitex&comma;0|0&comma;y

0<x~and0<x~y~

(11)

See Also

attributes

LinearAlgebra[Eigenvalues]

LinearAlgebra[Eigenvectors]

LinearAlgebra[HermitianTranspose]

Matrix

type