Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Lernen Challenge: Combined Transformations of a Vector | Linear Algebra Foundations
Mathematics for Data Science

bookChallenge: Combined Transformations of a Vector

Apply a scaling transformation and a 90° rotation to a 2D vector using Python and matrix multiplication. Visualize the result with arrows and coordinate labels from the origin.

You're working with a vector:

v=[23]\vec{v} = \begin{bmatrix}2 \\ 3\end{bmatrix}

You will:

  1. Apply a scaling matrix:

    S=[2000.5]S = \begin{bmatrix}2 & 0 \\ 0 & 0.5\end{bmatrix}
  2. Apply a rotation matrix:

    R=[23]R = \begin{bmatrix}2 \\ 3\end{bmatrix}
  3. Combine them as:

R(Sv)R \cdot (S \cdot \vec{v})

This simulates what happens when a vector is first scaled and then rotated.

Aufgabe

Swipe to start coding

  1. Complete the Python code below to:

    • Define the original vector;

    • Apply the scaling and rotation matrices;

    • Plot all vectors with labeled tips and coordinate axes;

  2. Verify that the output vectors are correct.

Lösung

War alles klar?

Wie können wir es verbessern?

Danke für Ihr Feedback!

Abschnitt 4. Kapitel 7
single

single

Fragen Sie AI

expand

Fragen Sie AI

ChatGPT

Fragen Sie alles oder probieren Sie eine der vorgeschlagenen Fragen, um unser Gespräch zu beginnen

close

Awesome!

Completion rate improved to 1.89

bookChallenge: Combined Transformations of a Vector

Swipe um das Menü anzuzeigen

Apply a scaling transformation and a 90° rotation to a 2D vector using Python and matrix multiplication. Visualize the result with arrows and coordinate labels from the origin.

You're working with a vector:

v=[23]\vec{v} = \begin{bmatrix}2 \\ 3\end{bmatrix}

You will:

  1. Apply a scaling matrix:

    S=[2000.5]S = \begin{bmatrix}2 & 0 \\ 0 & 0.5\end{bmatrix}
  2. Apply a rotation matrix:

    R=[23]R = \begin{bmatrix}2 \\ 3\end{bmatrix}
  3. Combine them as:

R(Sv)R \cdot (S \cdot \vec{v})

This simulates what happens when a vector is first scaled and then rotated.

Aufgabe

Swipe to start coding

  1. Complete the Python code below to:

    • Define the original vector;

    • Apply the scaling and rotation matrices;

    • Plot all vectors with labeled tips and coordinate axes;

  2. Verify that the output vectors are correct.

Lösung

Switch to desktopWechseln Sie zum Desktop, um in der realen Welt zu übenFahren Sie dort fort, wo Sie sind, indem Sie eine der folgenden Optionen verwenden
War alles klar?

Wie können wir es verbessern?

Danke für Ihr Feedback!

close

Awesome!

Completion rate improved to 1.89
Abschnitt 4. Kapitel 7
single

single

some-alt