Solutions for Engineering Computation 2nd Us Edition by Musto

Page 1


Problem 1.1

Describethedifferencesbetweenanalyticandalgorithmicsolutions.

Answer:

An analytic solution is an exact solution, based on the application of the mathematical principles of algebra, calculus, etc.

An algorithmic solution is an approximate solution, based on the application of a computational procedure. The algorithm will generally rely on principles of arithmetic only to solve the problem; therefore, while the solution is approximate, it also eliminates the need to apply more complicated mathematics to the problem

Developthepseudocodeforanalgorithmicsolutionforfindingthetwopointswherethe function crossesthe -axis.

Answer:

1. Defineaninitialvaluefor ;e.g. .

2 Calculatethevalueof at ,

3. Addasmallincrementto toget ;e.g.

4. Calculatethevalueof at ,

5 If and havethesamesign,thenmake GotoStep2andrepeat. If and havedifferentsigns,thencalculatethefirstaxiscrossingtobeat andcontinue.

6. Define .

7 Calculatethevalueof at ,

8. Addasmallincrementto toget ;e.g.

9. Calculatethevalueof at ,

10.If and havethesamesign,thenmake . GotoStep7andrepeat. If and havedifferentsigns,thencalculatethesecondaxiscrossingtobeat

11.Endthealgorithm,andreporttheresults and .

Problem 1.3

ConsiderthecannonmodeldevelopedinSection111

a) Usingtheequationsdevelopedandalaunchspeedof10.0m/s,developthe pseudocodeforanalgorithmicsolutiontodeterminethelaunchanglerequiredto reachapeakheightofatleast25meters.

b) Usingdiscretevaluesspaced5° apart,carryoutthealgorithmicsolutionbyhand. Reporteachstepinthealgorithminatable.

c) Performananalyticsolutionforthisproblem,andcomparetheresultwithyour algorithmicsolution.

Solution:

a) Inthisalgorithm,intervalsof and and willbeused.

1. Definethevariable .

2. Definethevariable

3. Definethevariable .

4. Calculate

5. Definethevariable

6. Calculate

7. If ,thenmake .

8. If ,set , , andreturntoStep4.

9. If ,thenmake ,andreturntoStep3.

10 Reportthevaluefor ,andendthealgorithm

b) Carryingoutthealgorithmyields:

Answer: Alaunchangleof50°willyieldapeakheightgreaterthan25m.

c) Theanalyticsolutionisasfollows:

FromEq.1.4,theheightwillbemaximumat:

SubstitutingthisintoEq.1.1,withtheheightsetat2.5m,yields:

With and ,thiscanbesolvedfor analytically: =.4905

or:

Answer: Alaunchangleof yieldsapeakheightof2.5m.

Discussion: Whileboththealgorithmicandtheanalyticsolutionproducedanswersthat yieldedapeakheightof at least 25m,thediscretenatureofthealgorithmicsolution missedthesmallestlaunchanglethatwouldachievethisgoal. Usingthe50°launchangle givenbythealgorithmicsolution,thepeakheightwouldactuallybe3.0m.

Copyright 2021 © McGraw-Hill Education. All rights reserved. No reproduction or distribution without the prior written consent of McGraw-Hill Education.

ConsiderthecannonballproblemdescribedinSection1.1.1. Youhavebeenaskedto determineacombinationoflaunchspeedandanglerequiredtocleara5-meterwall erected8metersfromthelaunchpoint. Developthepseudocodeforanalgorithmic solutiontothisproblem.

Answer: Thisalgorithmassumesthatsomemaximumspeedofthecannon, ,is known,andthatthereisasolutiontotheproblem Also,averysmalltimestepwouldbe recommended.

1. Definethevariables and (somepracticalarbitrarystarting values).

2. Definethevariable .

3. Calculate

4 If ,thenincrease andrepeatStep3

5 Calculate

6. If and ,thenincrease andreturntoStep2.

7 If and ,thenset , increase , andreturnto Step2.

8. Reportthevaluesfor and ,andendthealgorithm.

Problem 1.6 5

Developandwritethepseudocodeforanalgorithmthatcantakealistof10integersand determinehowmanyareevennumbers.

Answer:

1) Definetwo“counters”tobesetatzero;e.g. and .

2) Readthefirstnumberinthelist;callit .

3) Dividethenumberbytwo;eg

4) Roundoffthenumbery;calltheroundednumber .

5) If ,thenthenumberiseven,andthecounters and areincreasedby1. If ,thenthenumberisodd,andonlythecounter isincreasedby1.

6) If ,readtheelementisposition fromthelist,callit ,andgotoStep3

7) Endthealgorithm,andreportthecountervalue asthenumberofevenelementsin thelist.

Problem 1.6

Anengineermeasuresthediametersandlengthsofanumberofsteelrods. Calculatethe cross-sectionalareaandtotalvolumeofeachoftherods,andreporttheanswerusingthe correctnumberofsignificantdigits.

A 0.125 in 12.80 in

B 0.13 in 1.1 ft

C 0.1250 in 1.1 ft

D .01250 in 1.067 ft

E 0.38 in 8.11 in

F 0.3750 in 8.110 in

G 0.3750 in 8.1 in

H 1.2 in 5.29 in

I 1.20 in 5.290 in

J 1.200 in 5.3 in

Solution:

Rod A: Thediameterhas3significantdigits,thelengthhas4.

CrossSectionalArea:

Volume:

Rod B: Thediameterhas2significantdigits,thelengthhas2.

CrossSectionalArea:

Volume:

Rod C: Thediameterhas4significantdigits,thelengthhas2.

Volume:

Rod D: Thediameterhas4significantdigits,thelengthhas4.

CrossSectionalArea:

Volume:

Rod E: Thediameterhas2significantdigits,thelengthhas3.

CrossSectionalArea:

Volume:

Rod F: Thediameterhas4significantdigits,thelengthhas4

CrossSectionalArea:

Volume:

Rod G: Thediameterhas4significantdigits,thelengthhas2.

Copyright 2021 © McGraw-Hill Education. All rights reserved. No reproduction or distribution without the prior written consent of McGraw-Hill Education.

CrossSectionalArea:

Volume:

Rod H: Thediameterhas2significantdigits,thelengthhas3.

CrossSectionalArea:

Volume:

Rod I: Thediameterhas3significantdigits,thelengthhas4.

CrossSectionalArea:

Volume:

Rod J: Thediameterhas4significantdigits,thelengthhas2.

CrossSectionalArea:

Volume:

B 0.13 in 1.1 ft

C 0.1250 in 1.1 ft 0.012 0.16 D .01250 in 1.067 ft 0.01227 0.1571 E 0.38 in 8.11 in 0.11

F 0.3750 in 8.110 in .1105 0.8962 G 0.3750 in 8.1 in .1105 0.90 H 1.2 in 5.29 in 1.1 5.8 I 1.20 in 5.290 in 1.13 5.98 J 1.200 in 5.3 in 1.131 6.0

Copyright 2021 © McGraw-Hill Education. All rights reserved. No reproduction or distribution without the prior written consent of McGraw-Hill Education.

Problem 1.7

Usingyourcomputer,researchanddocumentavalueforthedensityofsteel. Usethevalue todeterminetheweightofeachroddescribedinProblem1.6,reportingeachanswerusing thecorrectnumberofsignificantdigits.

Answer: Usingatypicalvalueof0.283lb/in3fortheweightdensityofsteel:

Turn static files into dynamic content formats.

Create a flipbook
Issuu converts static files into: digital portfolios, online yearbooks, online catalogs, digital photo albums and more. Sign up and create your flipbook.