Question: Use Python, NumPy, and Matplotlib to complete the following tasks: (a) Write function translate(tx, ty) that returns the matrix translating by (tx, ty). Plot
Use Python, NumPy, and Matplotlib to complete the following tasks: (a) Write function translate(tx, ty) that returns the matrix translating by (tx, ty). Plot the point (2, 1) and its translation by (-1,-2). (b) Write function rotate (theta) that returns the matrix rotating by angle 0. Plot the point (2, 1) and its rotation by 45. (c) Write function scale(sx, sy) that returns the matrix scaling by (s,sy). Plot the point (2, 1) and its scaling by (1/2,2).
Step by Step Solution
There are 3 Steps involved in it
Heres how you can achieve this using Python NumPy and Matplotlib import numpy as np import matplotli... View full answer
Get step-by-step solutions from verified subject matter experts
