EML3035: Programming Concepts for Mechanical Engineers


Lectures & Assignments      Syllabus


EML 3035

Programming Concepts for Mechanical Engineers

Department of Mechanical Engineering

University of South Florida

 

LECTURES, HANDOUTS AND ASSIGNMENTS  Spring 2008

EML 3035 Home Page

Fall 2007 archived lectures

Week

Lecture Notes

Assignment

Week 1 January 8, 10

Handouts of First Day of Class

      Syllabus

      Words of wisdom from your peers

      About you form

      Affidavit Sheet

      Sample Attendance Memo

 

Sample HW of Brinell Hardness

      Homework Assignment Sheet

      Mfile

      Print out of the output

 

Excellent Introductory Tutorial from MATLAB

Another good tutorial from Duke University

The Sprintf command

 

Class Notes - Week 1

Reading Assignment: Pages 1-83.  Skip Section 2.4 pages 35-37.

 

Assigned HW: Monthly Payment on a Car.  Problem#1

 

Other HW problems: All problems given on pages 1-83. Skip #2.1,2.3,2.4 on pg 77


Week 2 January 15, 17

Class Notes - Week 2

Reading Assignment: Same as last week

 

Assigned HW: None.  Cut the potato! 

  

Other HW problems: Same as last week


Week 3 January 22, 24

Gutter Problem (Handout   Mfile)

Water Freezing  (Handout   Mfile)

Clicker Quiz (PDF)

Reading Assignment: Same as last week

 

Assigned HW: Problem#2

 

Other HW problems: Same as last week.  Also try these problems.

 

Week4 January 29, 31

Competency test#1

 

 

 

 

 

 

 

 

Week5 Feb 5, 7

Handout of flowcharts

BMI Problem  DOC  MFile

Reading Assignment: Pages 85-117;139-143.  Skip && and || operators and corresponding explanation and problems.

 

Assigned HW: Problem#3

 

Other HW problems: All problems given on pages 85-117;139-146. Skip problems with && and ||, and #3.12 to 3.17.

 

Week6 Feb 12, 14

BMI calculator function

Testing the BMI calculator function (need to have the above mfile also to run this)

fprintf a string variable with explanation. See this mfile

Is a number an integer or not?

An example of the switch construct

Sample HW problem

Reading Assignment: Same as previous week + pg 199-206

 

Assigned HW: Problem#4.  Follow guidelines given in the specifications and the sample HW problem.

 

Other HW problems: Same as last week

 

Week 7 Feb 19, 21

Simple Examples of Loop     

       Loop Examples

Average & Standard Deviation

      Problem Statement

      Mfile

Example of Break and Continue Statement

      Mfile of Break Statement

      Mfile of Continue Statement

Reading Assignment: Pg 147-170.  Read pg 199-206 again.

 

Assigned HW: Problem#5.

 

Other HW problems: 4.1, 2-8, 18,19

 

Week 8  Feb 26,28

While statement examples

      Mfile of Equivalent Break Statement

Square Root of a Number

      Problem Statement

      Mfile 

Class Exercises

       Loops

       Maclaurin Series

Read pg 199-206 again.

Skip Art 4.2.2 pg 163-167

Skip Art 4.3 pg 170-175

Skip Example 4.8, pg 182-190

Skip Problem#4.9, 10, 11, 12, 13, 14, 15, 17.  Try other problems.

Assigned HW: NONE but keep cutting the potato

 

Week 9  Mar 4, 6

   How many grains on given squares

        Problem Statement

        Mfile

   How many squares filled by given grains

        Problem Statement

        Mfile

    Clicker Quiz

        Loops Quiz 1

Same as last week

Assigned HW: Problem#6

 

 

Week 10  Mar 11, 13

Spring Break

 

 

 

 

 

 

 

Week 11  Mar 18, 20

Competency test#2

 

 

 

 

 

 

 

 

Week 12  Mar 25, 27 

    Trapezoidal Rule

        Problem Statement 

        Mfile  Function Test

    Error Function

        Problem Statement

        Mfile  Function Test

   Picking up lotto numbers

             Problem Statement

             Mfile

 

Assigned HW: Problem#7

 

Study and Remember Matrix Algebra Handout

 

Week 13  April 1, 3 

Trace of a matrix

            Problem Statement

            Mfile

Program for Dot Product

       Mfile

Assigned HW: Problem#8

Study the Matrix Algebra Handout

write programs to find whether a given matrix is a certain type of special matrix or not

 

Week 14  Apr 8, 10 

Reading from a file line by line

       Mfile   Input File

Reading Using a Loop

       Mfile   Input File

Reading using the While loop

       Mfile   Input File

Maximum of an array

        Mfile

Minimum of an array

        Mfile

Regression Model

       Mfile   Input File   

Assigned HW: None

 

Do these problems for practice for Test#3

Symmetric Matrix

        Problem Statement

Strictly Diagonally Dominant

        Problem Statement

Diagonally Dominant

        Problem Statement

 

 

 

Week 15  Apr 15, 17 

Strictly Diagonally Dominant

        Problem Statement    Rough Mfile

Diagonally Dominant

        Problem Statement     Rough Mfile

 

Try at least one more way of doing the above problems.

Assigned HW: None; No Quiz this week; No HW to be submitted

 

Do these problems to get ready for the test and do not look at the solution till you do them.

1. Is a matrix an identity matrix or not? 

Rough Mfile

      Method 1

      Method 2

Test them out.  Understand both methods.

2. Is a matrix tridiagonal or not?

3. Is  a matrix symmetric or not?

4. Secant Method:

            Problem Statement

            Rough Solution Mfile

 

 

Week 16  Apr 22,24 

Competency test#3

 

 

 

Assigned HW: None