CEG220: Introduction to C Programming for Engineers – I

Section 2

 

Project 4: Matrix Math

 

Program Background:

As an engineer, you will frequently have to work with matrices. Most engineering languages, such as Matlab and IDL already have matrix math implemented.

 

Program Description:

Your task is to implement matrix addition, subtraction, and multiplication. Make sure to check that dimensions match up.

 

Program Requirements:

1)      Your program must comply with the class programming standard

2)      You must submit a hand-written program specification detailing (1) your approach to solving the problem, (2) the algorithm(s) you used, and (3) justifying the data types and loops you have used

 

Grading Standard:

This project is worth 100 points. Please note that programs that do not compile or do not link will lose all points related to run-time requirements (examples of run-time requirements includes but is not limited to correct run output, handling certain cases adequately, etc.). Grading standard will be followed strictly:

 

25 points:         Preparatory Requirements

·        Compliance with class coding standard (3 points each)

·        adequate comments – clear, concise, useful; not excessive

·        well-named identifiers

·        follows program specification

·        hand-written document / program specification (16 points)

·        all algorithms designed properly and included in the spec

·        Uses pseudo-code to express the problem and how to solve it

 

75 points:         Run-time Requirements

·        Addition (20 points)

·        Subtraction (10 points)

·        Multiplication (20 points)

·        Handles bad cases, such as mismatched dimensions (15 points)

·        Code is modularized (10 points)

 

Due Date:

This project is due on 10/27 at the beginning of class. If your assignment is late – by 5 minutes or (the maximum) 2 days, the penalty is 30% (see syllabus).