Post Reply 
anti-Identity matrix for Casio calculators
05-18-2018, 07:54 AM (This post was last modified: 05-18-2018 07:58 AM by klesl.)
Post: #1
anti-Identity matrix for Casio calculators
This small code creates m×n anti-Identity matrix. It is for fx-9860 and similar calcs with matrix. For using with ClassPad the code has to be adapted which is very easy.
An enter is pressed at the end of row.
ClrText
"Dim"?->M:M->I:{M,M}->Dim Mat A/put here an output triangle - opt./
Fill(1,Mat A):Mat A/put here an output triangle- opt./
Do
0->Mat A [I, I]
I-1->I
LpWhile I>0
Mat A/put here an output triangle/

Description:
The Idea is simple- create square M×M zero matrix and replace values in the diagonal cells

1. Command "Dim" creates square M×M zero matrix
2. Command "Fill" replaces zero elements with 1
3. Command "Do" repeats the loop till the condition I>0
4. 0->Mat A [I, I] assigns 0 to all diagonal cells
5. Command "lpWhile" ends the loop when the condioit is achieved
---------------------------------------------
Variables:
M - dimension of Matrix
I - index of cell position (30, 29, 28)
[I.I] - index of diagonal cells
Mat A - created matrix A
---------------------------------------------
Notes: You can delete the first two triangles marked as opt., because I use them for visual checking of created matrix
Also You can add the "Det" command (Det Mat A) at the end of the program to calculate the determinant automatically
Find all posts by this user
Quote this message in a reply
05-18-2018, 11:55 PM
Post: #2
RE: anti-Identity matrix for Casio calculators
Thanks for that. I knew it must have been something simple, but I wasn't sure how to do it at the time that I asked. I did try making a 30x30 matrix on the older calculator (the 9750g+), but though I could create the matrix, I couldn't then work with it (then duplicating its contents into Mat Ans) because there simply wasn't enough room left on the calculator when I had other programs installed as well.

(Post 225)

Regards, BrickViking
HP-50g |Casio fx-9750G+ |Casio fx-9750GII (SH4a)
Visit this user's website Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)