# Homework¶

**Turning things in:**

Before 5:00 pm on the date indicated, you must upload a single ”.tgz” or ”.zip” file to Canvas, containing all Matlab functions and scripts as separate ”.m” files, and all input files as ”.txt” files. We will run your code, so if your codes have names that do not match the assignment or have capitalization/spelling errors, these will not run and points will be deducted.

**Late homework:**

Any homework turned in late will lose points based on the following schedule:

- 1 minute to 24 hours – 20%
- 24 hours to 48 hours – 50%
- over 48 hours – no credit

**Honor Code:**

Students may work together to discuss code

structure. However,all work turned in for credit must represent your own individual effort, and must be in keeping with the SMU Honor Code.Examples of allowed/disallowed collaboration:

- You can discuss things like the types of functions that are needed, which algorithms to use, and how functions should interact with one another (e.g. input/output arguments). However, you must write
and debugall codes yourself, using your own personal variable names, comments, and implementation details.

## Assignments¶

Homework 1:

`MATLAB Scripts`

(due 2/2)Solutions:

`homework1.m`

,`homework1_output.txt`

Solutions (Windows):

`homework1.m`

,`homework1_output.txt`

Homework 2:

`Loops`

(due 2/9)Solution:

`homework2.m`

Solution (Windows):

`homework2.m`

Homework 3:

`Summation and Product Notation`

(due 2/16)Solution:

`homework3.m`

Solution (Windows):

`homework3.m`

Homework 4:

`MATLAB functions`

(due 2/23)Solutions:

`homework4.m`

,`forward_difference.m`

Solutions (Windows):

`homework4.m`

,`forward_difference.m`

Homework 5:

`Translating Pseudocode`

(due 3/2)Solutions:

`homework5.m`

,`mypolynomial.m`

Solutions (Windows):

`homework5.m`

,`mypolynomial.m`

Homework 6:

`Functional Programming`

(due 3/9)`homework6.m`

,`homework6.m (Windows)`

Solutions:

`homework6_solution.m`

,`normalize.m`

,`dotprod.m`

,`project.m`

Solutions (Windows):

`homework6_solution.m`

,`normalize.m`

,`dotprod.m`

,`project.m`

Homework 7:

`Algorithmic Complexity and the MATLAB Timer`

(due 3/23)`linearsolve.m`

,`linearsolve.m (Windows)`

Solutions:

`homework7.m`

Solutions (Windows):

`homework7.m`