Homework guidelines
Due dates/late policy
Homeworks will only be accepted electronically through the EEE dropbox. The dropbox will have a deadline of 11:59 pm on the given due date. No homeworks will be accepted after that time. If you are working down to the last minute, please make sure something is uploaded 10 minutes prior to the deadline to ensure you won't get zero credit.
Grading
Each assignment has both programming and written components. Your
code will be graded both on clarity and correctness.
It is generally more important that your code be clear and
correct than fast. Your writeup should
be richly illustrated with graphs and images, and your code
should be well commented and documented.
Homework Submission Instructions
Submit a pdf file with your writeup into the appropriate directory in the EEE Dropbox.
Also submit a zip or tar archive containing a folder with all your code. The name of the folder
should be YourName so that when I unzip it, everything is nicely self contained.
Include everything that your code needs to run. If I hand out code as part of the
assignment, please include that also.
Zip or tar the YourName
directory and submit either YourName.zip or
YourName.tar.gz or YourName.tgz.
You can create an archive
of the YourName directory in various ways
depending on the platform:
- Right-click on the folder and select "Create archive".
Select either "zip" or "tar.gz" to create the archive, or
- In a terminal, cd to the directory
containing YourName and type zip -r YourName
YourName to create YourName.zip, or
- In the terminal, type tar cfz YourName.tgz YourName
to create YourName.tgz.
You can list the contents of a zip archive with the command
unzip -l YourName and the contents of a tar archive with
the command tar tfz YourName.tgz.
Homework Writeup Guidelines
You must submit your writeups as as a single PDF file.
I will not accept writeups in any word processing format
such as MS Word or Open Office. You are welcome to create
the writeup in whichever word processor you like but in the
end you need to save it as a pdf file.
Some guidelines for your figures:
- Use a proper size and aspect ratio. If you are showing
an image, make sure that the pixels are displayed square. Use
the axis image command. If the image is not too large,
ensure that image and screen pixels coincide with the
truesize command.
- Always show the colorbar for 2D data. Whether your are
showing an image or data in the form of an image, always show the
colorbar. If you are showing an image, this will verify that the
color map spans the correct range (usually [0,1]). If
you are showing data, then this will show the meaning of the colors.
The only exception is when you show RGB images; in that case, the
colorbar is meaningless because the colormap is not used.
- Use a sensible color map. There are a couple standard color
maps available in MATLAB: gray, jet,
and hsv. In the few cases where your data is periodic
(such as with angles), then use colormap hsv. Otherwise,
use gray or jet. Which is appropriate
depends on what you are trying to show. Use the colormap that most
effectively communicates your point.
- Use a proper display range. If you are showing a
grayscale image, make sure that MATLAB does not remap the colors.
The imagesc command has an optional parameter for this
purpose, e.g. imagesc(im,[0,1]) will make sure the color
map spans the range [0,1]. If you are showing data, then
allowing imagesc to scale the color map to the range of
the data is usually appropriate. If your data is mostly symmetric
around zero, then consider using a display range that is symmetric
around zero,
e.g. imagesc(im,[-1,1]*max(abs(im(:))))
- Consider screen capture for figures. There are
three ways to create images of your figures in MATLAB:
- Use a screen capture utility.
- Select File > Save As... from the figure window, and export as
an image (PNG, TIFF, JPG, etc.).
- Use the print command.
- Use imwrite() for saving images. To directly export
an image from Matlab, use the imwrite command.