<img src="https://d5nxst8fruw4z.cloudfront.net/atrk.gif?account=iA1Pi1a8Dy00ym" style="display:none" height="1" width="1" alt="" />
You are reading an older version of this FlexBook® textbook: Engineering: An Introduction to Solving Engineering Problems with Matlab Go to the latest version.

8.4: Solutions to Exercises

Difficulty Level: At Grade Created by: CK-12

Solution to Exercise 1

10 times.

Solution to Exercise 2

This loop will continue to print 'Hello World' until the user stops the program. You can stop a program by holding down the 'Ctrl' key and simultaneously pressing the '$c$' key.

Solution to Exercise 3

a =

1

a =

2

a =

4

a =

8

a =

16

a =

32

a =

64

a =

128


Solution to Exercise 4

a =

1

a =

2

a =

6

a =

24

a =

120


Solution to Exercise 5

APR = 14.9;

r = (1 + APR/100)^(1/12)-1;


Solution to Exercise 6

bn = 2203;

pn = max((r + 0.01)*bn, 10);


Solution to Exercise 7

fn = r * bn;

bn = bn + fn - pn;


Date Created:

Feb 23, 2012

Sep 15, 2014
Files can only be attached to the latest version of section