Sponsored links: Algebra eBooks
 

Help Index

A

B

C

D

E

F

G

H

I

J

K

L

M

N

O

P

Q

R

S

T

U

V

W

X

Y

Z

The Maxima on-line user's manual

Algebra Calculator

Search:

Diagmatrix

Function: diagmatrix (<n>, <x>) Returns a diagonal matrix of size <n> by <n> with the diagonal elements all equal to <x>. diagmatrix (<n>, 1) returns an identity matrix (same as ident (<n>)).

A: diagmatrix(10,2);

<n> must evaluate to an integer, otherwise diagmatrix complains with an error message.

<x> can be any kind of expression, including another matrix. If <x> is a matrix, it is not copied; all diagonal elements refer to the same instance, <x>.

There are also some inexact matches for diagmatrix. Try ?? diagmatrix to see them.

(%o1)                                true
(%i2) 

Related Examples

diagmatrix-matrix

x: matrix ([a, a,0,0]...

i: diagmatrix (4, 1);

j: matrix ( [1,1,1,1]...

Calculate

diagmatrix-matrix

x: matrix ([a, a,0,0]...

i: diagmatrix (4, 1);

j: matrix ( [1,1,1,1]...

Calculate

diagmatrix-matrix

x: matrix ([a, a,0,0]...

i: diagmatrix (4, 1);

j: matrix ( [1,1,1,1]...

Calculate

diagmatrix-matrix-mod

M: matrix ([7, 3, 4, ...

K : mod(M,11);

D:diagmatrix(4,1)*k;

Calculate

diagmatrix-matrix-mod

M: matrix ([7, 3, 4, ...

K : mod(M,11);

D:diagmatrix(4,1)*k;

Calculate

diagmatrix-expand-jacobian-matrix-phi-sin

A:matrix([0,-1/L1,0],...

B:matrix([1/L1, 0], [...

x:matrix([i_inv],[u_c...

Calculate

diagmatrix-matrix

x: matrix ([a, a,0,0]...

i: diagmatrix (4, 1);

j: matrix ( [1,1,1,1]...

Calculate

diagmatrix-matrix-mod

M: matrix ([7, 3, 4, ...

K : mod(M,11);

D:diagmatrix(4,1)*k;

Calculate

diagmatrix-jacobian-matrix-phi-sin

A:matrix([0,-1/L1,0],...

B:matrix([1/L1, 0], [...

x:matrix([i_inv],[u_c...

Calculate