Question: Task 1 ( of 2 ) Under certain condition, the velocity distribution u ( r ) of a liquid through the annular pipe are given

Task 1(of 2)
Under certain condition, the velocity distribution u(r) of a liquid through the annular pipe are given by:
u(r)=G4(R12-r2)+G4(R22-R12)ln(rR1)ln(R2R1),Eq.1
where is the dynamic viscosity and equal to 8.90**10-4Pa**s for water, RI is the inner cylinder radius,
R2 is the outer cylinder radius, and r is a radial distance from the centerline axis of the pipe. For this
problem, all radii are in units of meters (m).G(Pam) is the normalized gradient pressure per unit length
and is given as:
G(r)=r2R22-R12tan(r-R1R2-R1)
Write a MATLAB script named HW4p2_Taskl_UCusername.m that will prompt the user to enter the
values of R1,R2 and r as constants. Your script should then make sure the inputted r value is valid: r>RI
and rurtanlnGrr=0.35mu=4.096msr.If the value ofris valid, your script will then compute and print the values ofu with 3
decimals and the corresponding units. If the value ofris invalid, your script will print an error message.
You will need to use the MATLAB built-in functions for tan and lnis the Natural Log, you can type in
help logor help tanto see how to use these functions. The tangent function in the G equation isin
radians.
Sample Test Case:
Enter R1in meters: 0.2
Enter R2in meters: 0.5
Enter the radial distance, rin meters: 0.35
the velocity atr=0.35m,isu=4.096ms
 Task 1(of 2) Under certain condition, the velocity distribution u(r) of

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!