Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

CS122 Exam 1 2017 spring 20170222094218.pdf where m is the associated friction,

ID: 3585378 • Letter: C

Question

CS122 Exam 1 2017 spring 20170222094218.pdf where m is the associated friction, el is elasticity of the mass, vol is volume of the mass, mg is the moon's orce (mass moon's gravityl, eg is the earth's gravitational force (mass earth's gravity). 2 the following formula: r = 3m/ + e2701-mete, where tance ofan object is calculated with the following formula: rmf + 27s in pseudo code, remembering that you gravi how you would write only the calculation part of this program e should always break a using comments. complicated expression down into components. Also note that this would be writtes

Explanation / Answer

Pseudocode to calculate retractance

Now matlab code for calculation of this formula

rectraction =0
moon_gravity =1.622
earth_gravity =9.807

prompt="Enter the value of mass";
mass=input(prompt) % takes the input from user and store it to the variable. It shows the message written in the prompt at the time of asking for an input

prompt = "Enter the value of friction";
friction = input(prompt)

prompt = "Enter the value of elasticity";
elasticity = input(prompt)

prompt = "Enter the value of volume";
volume = input(prompt)

mass_friction = mass * friction
mass_friction = mass_friction / 3

elast_volume = elasticity * volume
elast_volume = elast_volume / 2.75

mmg = mass * moon_gravity
meg = mass * earth_gravity
mass_gravity = mmg + meg
mass_gravity = mass_gravity /2

rectractance = mass_friction + elast_volume - mass_gravity