Department of Mathematics

Math 300: Mathematical Computing

Python ICE 1

Write Python commands to create the following matrix. \[ A = \begin{bmatrix} 4 & 0 & 0 & 0 & 0\\ 0 & 4 & 0 & 0 & 0\\ 0 & 0 & \cos\frac\pi6 & -\sin\frac\pi6 & 0\\ 0 & 0 & \sin\frac\pi6 & \cos\frac\pi6 & 0\\ 0 & 0 & 0 & 0 & -2\\ \end{bmatrix} \] Try to do it with only three (3) lines of code.


Assignment 7 is posted.




A solution to the test is available.







Department of Mathematics, PO Box 643113, Neill Hall 103, Washington State University, Pullman WA 99164-3113, 509-335-3926, Contact Us
Copyright © 1996-2015 Kevin Cooper