Matlab sourcecodes for week #3 assignment