User Tools

Site Tools


gibson:teaching:spring-2016:math445:exam1sample

**This is an old revision of the document!** ----

A PCRE internal error occured. This might be caused by a faulty plugin

The exam will have around ten questions, some easy, some not so easy. For most questions, you will be asked to answer with Matlab code in correct syntax. E.g. **Problem 1:** (totally straightforward) Given a matrix $A$, write one line of Matlab code that would assign the 3rd row of $A$ into the variable $x$. **Problem 2:** (slightly tricky) Given a matrix $A$, write one line of Matlab code that convert the $j$th column of $A$ into a row vector and assign it to the variable $x$. **Problem 3:** (pretty straightforward) Given a vector $v$, write one or two lines of Matlab code that would return all the odd-numbered elements of $v$. **Problem 4:** (moderate) Write Matlab code that defines a function named ''mysin'' that computes $\sin(x)$ using the truncated power series \begin{equation*} \sin(x) \doteq \sum_{n=0}^{10} -1^{2n+1} \frac{x^{2n+1}}{(2n+1)!} \end{equation*}

gibson/teaching/spring-2016/math445/exam1sample.1456863386.txt.gz · Last modified: 2016/03/01 12:16 by gibson