Skip to main content

Casio fx-CG50 lesson 12: Matrices, Markov chains and complex numbers

The last lesson of the series covers the HL tools in RUN-MATRIX: matrices (AI HL: systems, Markov chains) and complex numbers (AA HL and AI HL). The skill is the same in both: store the object once, then work with its name.

Objective

Store matrices and use them for determinants, inverses, systems of equations and Markov chains; switch to complex mode and find the modulus, argument, conjugate and polar form of a complex number.

By the end, students can:

Which courses this lesson suits

Matrices are in IB AI HL. Complex numbers are in AA HL and AI HL. Neither is in A Level Maths. Vectors: Casio lists vector calculations among the functions Examination Mode (for IB) turns off, so step 7 is only for checking practice work.

Before you start

Matrices persist in the calculator's memory: ask students to look at the MAT/VCT list before the lesson and delete anything left over that could confuse them. Examination Mode (for IB) does not stop matrices or complex numbers.

The key presses, step by step

Every key is shown as it is printed on the calculator, like SHIFT or F1. The F-keys do whatever the bottom row of the screen says, so the picture next to each step shows that row.

  1. MENU 1 (RUN-MATRIX), then F3 (MAT/VCT). Highlight Mat A and press EXE. Set m = 2 EXE and n = 2 EXE, then type 3, 5, 1, 2 row by row with EXE after each. EXIT twice to get back.

    m is the number of rows and n the number of columns. A wrong size is the usual reason for a Dimension ERROR later.

    Casio fx-CG50 lesson 12 screen: Matrix A, showing the matrix editor showing Mat A with rows 3, 5 and 1, 2
    The matrix editor with Mat A entered (our drawing of the fx-CG50 screen, not a photo).
  2. Determinant: OPTN F2 (MAT/VCT) F3 (Det), then F1 (Mat) ALPHA X,θ,T (A) EXE: det A = 1.

    F1 (Mat) types the word Mat, and ALPHA X,θ,T types A. The same two keys recall Mat A anywhere.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing Det Mat A = 1; F-keys Mat, M→L, Det, Trn, Augment, ▷
    Det Mat A, with the OPTN MAT/VCT F-keys (our drawing of the fx-CG50 screen, not a photo).
  3. Inverse: F1 (Mat) ALPHA X,θ,T (A), then x⁻¹ (SHIFT )), EXE. A⁻¹ has rows 2, −5 and −1, 3.

    To solve AX = B, put B = (7, 3) as a 2 × 1 matrix in Mat B, then type Mat A⁻¹ × Mat B EXE: x = −1, y = 2.

    A matrix with determinant 0 has no inverse (Math ERROR): then the system has no unique solution.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing the inverse of Mat A and the solution of AX = B
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).
  4. Markov chains (AI HL): put the transition matrix in Mat A and the starting state in Mat B (a column). The state after n steps is Mat A ^ n × Mat B: type ^ with the ^ key. In Math input ^ opens an exponent box: type n, then press ▶ to leave it before ×.

    For the long term, use a large power such as 50 and check that the answer stops changing.

    This is the column convention the IB uses: each column of the transition matrix adds up to 1.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing the commands Mat A^3×Mat B and Mat A^50×Mat B
    The two commands for a Markov chain (results in the worked example) (our drawing of the fx-CG50 screen, not a photo).
  5. Complex numbers: SHIFT MENU (SET UP), Complex Mode → a+bi, Angle → Rad, EXIT. In RUN-MATRIX, i is SHIFT 0.

    Type (2 + i)² EXE: 3+4i. Store it so you can reuse it: → ALPHA X,θ,T (A) EXE puts Ans into A.

    In Real mode √(−4) and similar real inputs give Non-Real ERROR. Once you type i, the calculator works with complex numbers, but set a+bi so every answer shows in that form.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing (2+i)² = 3+4i in complex mode
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).
  6. OPTN F3 (COMPLEX): F2 (Abs) A EXE gives |z| = 5; F3 (Arg) A EXE gives arg z = 0.927295218 (radians); F4 (Conjg) A EXE gives z* = 3−4i.

    Polar form: type A, then F6 (▷) and ▶r∠θ, EXE: 5∠0.927295218. ▶a+bi converts back.

    Arg uses the angle mode: keep it in Rad unless the question gives degrees. Ans changes after each EXE, which is why z was stored in A.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing Abs A and Arg A: 5 and 0.927295218; F-keys i, Abs, Arg, Conjg, ReP, ▷
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).
  7. Vectors, for checking only. F3 (MAT/VCT), then F6 (M⇔V) switches to the vector list. The vector commands (DotP, CrossP, Norm, Angle) are under OPTN F2 (MAT/VCT) and F6 (▷).

    Casio lists vector calculations among the functions Examination Mode (for IB) turns off, so they will not be there in the exam. Do vector questions by hand, then use this to check practice answers.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing a note that vector commands are turned off in Examination Mode (for IB)
    A reminder: vectors are for checking practice work (our drawing of the fx-CG50 screen, not a photo).

Your turn: check your understanding

Try these straight after the key presses, on your own calculator, before looking at the answers.

  1. Put A = (2 1; 5 3) in Mat A. Find det A and A⁻¹.
  2. In a+bi mode work out (1 + 2i)(3 − i), then |3 + 4i|.
  3. Find arg(1 + i) in Rad mode. Which fraction of π is it?
Show the answers
  1. det A = 1; A⁻¹ has rows 3, −1 and −5, 2.
  2. 5+5i, and |3 + 4i| = 5
  3. 0.785, which is π ÷ 4.

Exam efficiency

Worked exam-style example

Question. (AI HL) Each week, 70% of customers of shop A stay with A and 30% move to B; 80% of customers of B stay with B and 20% move to A. At the start A has 100 customers and B has 200. (a) Write down the transition matrix T. (b) Find the number of customers of each shop after 3 weeks. (c) Find the long-term number of customers of each shop.

  1. (a) T has columns "from A" and "from B": first row 0.7, 0.2 and second row 0.3, 0.8. Enter it as Mat A (2 × 2) and the starting state (100, 200) as Mat B (2 × 1).

    Casio fx-CG50 lesson 12 screen: Matrix A, showing the transition matrix entered as Mat A
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).
  2. (b) Mat A ^ 3 × Mat B EXE (in Math input, press ▶ to leave the exponent box after the 3, before ×): A has 117.5 and B has 182.5.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing after 3 weeks: 117.5 and 182.5
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).
  3. (c) Mat A ^ 50 × Mat B EXE, then Mat A ^ 60 × Mat B: both give 120 and 180, so the state has settled.

    Casio fx-CG50 lesson 12 screen: RUN-MATRIX, showing the long-term state 120 and 180
    What the screen shows after this step (our drawing of the fx-CG50 screen, not a photo).

What to write down

(a) T = (0.7 0.2; 0.3 0.8), columns from A and from B.

(b) s₃ = T³s₀ = (117.5, 182.5): about 117.5 customers for A and 182.5 for B (expected numbers, so they need not be whole).

(c) Tⁿs₀ tends to (120, 180): 120 customers for A and 180 for B. You can confirm it by solving Ts = s with the total 300.

Practice

Do these on your own calculator. Write the answers to 3 significant figures unless the task says otherwise.

  1. A = (4 1; 2 3). Find det A and A⁻¹.
  2. Solve x + 2y − z = 4, 2x − y + 3z = 9, 3x + y + z = 8 using matrices (A⁻¹B).
  3. (AI HL) T = (0.9 0.4; 0.1 0.6) and s₀ = (500, 500). Find s₅ and the long-term state.
  4. Work out (2 + 3i)(4 − i) and (2 + 3i) ÷ (4 − i).
  5. z = −1 + √3 i. Find |z| and arg z in radians, and write z in polar form.
  6. Work out by hand the scalar product of a = (1, 2, −2) and b = (3, 0, 4), and the angle between them. Then check with the vector commands (practice only: not available in Examination Mode (for IB)). The calculator is still in Rad from step 5: switch Angle to Deg, or convert the answer.
Show the practice answers
  1. det A = 10; A⁻¹ = (0.3 −0.1; −0.2 0.4). The calculator may show the entries as fractions in Math mode: S⇔D switches.
  2. x = −0.6, y = 4.8, z = 5
  3. s₅ = (791, 209); long term (800, 200)
  4. 11+10i and 0.294+0.824i (3 s.f.)
  5. |z| = 2, arg z = 2π/3 = 2.09, z = 2∠2π/3 (the calculator may show the exact 2π/3 in Math mode)
  6. a · b = −5, angle = 109°

Common mistakes

1-minute quick check

Answer these without looking back. Most need no calculation: they check that the key presses have stuck.

  1. Which key opens the matrix list from RUN-MATRIX?
  2. Which keys give x⁻¹?
  3. How do you find the long-term state of a Markov chain?
  4. Which keys give i?
  5. Are the vector commands available in Examination Mode (for IB)?
Show the quick-check answers
  1. F3 (MAT/VCT)
  2. SHIFT )
  3. Mat A ^ a large power (such as 50) × Mat B, and check it has stopped changing.
  4. SHIFT 0 (with Complex Mode a+bi)
  5. No: Casio lists vector calculations among the functions it turns off.

Teaching this lesson (about 55 minutes)

0–5 minStarter: solve a 2 × 2 system by hand; then show the same on the calculator in 20 seconds.
5–20 minSteps 1–3: the matrix editor, Det, inverse, AX = B.
20–30 minStep 4 and the worked example: Markov chains (AI HL).
30–40 minSteps 5–6: complex mode, i, Abs, Arg, Conjg, polar form (AA HL and AI HL).
40–50 minPractice tasks 1–6 (students pick the ones for their course); step 7 for checking task 6.
50–55 min1-minute quick check.

Students need their own fx-CG50. With a projector, the calculator-skills guides below have a Show on the board view and an animated walkthrough of the key presses.

Matching calculator guides

More fx-CG50 lessons