Do you mean diagonalize matrix A or a matrix made up of the diagonal entries of A.

The command

with(LinearAlgebra):

D := Diagonal(A);

Will choose just the diagonal entries from matrix A.

For diagonalizing one... I'm not entirely sure but

with(LinearAlgebra):

D := JordanForm(A);

Seems to be on the right track.