Professional Documents
Culture Documents
Vasquez 03LabExercise
Vasquez 03LabExercise
3
SIMPLE SOLID MENSURATION MATLAB PROGRAM
1. Objective:
The activity aims to create matlab program that will ask the user to choose between the two types of
figures in solid mensuration and output the area, perimeter/circumference, volume or surface area of a
certain figure.
3. Discussion :
Solid Mensuration is a branch of mathematics that deals with the area and perimeter/circumference of
plane figures and volume and surface area of solid figures.
4. Resources:
Matlab
5. Procedure:
1. Using the matlab editor , choose File/New/ Blank m-file , type the following:
clc;
disp('Area of the Rectangle');
% Input here…
length=input('Enter the length of the rectangle: ');
width=input('Enter the width of the rectangle :');
% Process here…
area=length*width;
% Output here …
fprintf('The area of the rectangle is %0.2f. ',area );
2. Save the file as areaRectangle. Run the program and record the results.
3. Create m-file for the area of the square, right triangle, oblique triangle, circle and ellipse.
4. Create m-file for the perimeter of square, rectangle, right triangle, oblique triangle, circle and ellipse.
For circle, use circumference instead of perimeter.
5. Create m-file for the volume of cone, sphere, rectangular parallelepiped, right circular cylinder and
cube.
6. Create m-file for the surface area of cone, sphere, rectangular parallelepiped, right circular cylinder
and cube.
7. Using the matlab editor, choose File/New/Blank m-file, type the following:
clc;
disp('Area and Perimeter of the Rectangle');
choose=input('\n 1. Area of the Rectangle \n 2. Perimeter of the Rectangle \n Choose 1 or 2: ');
switch(choose)
case 1;
length=input('Enter the length of the rectangle: ');
width=input('Enter the width of the rectangle :');
area=length*width;
fprintf('The area of the rectangle is %0.2f. ',area );
break;
case 2;
length=input('Enter the length of the rectangle: ');
width=input('Enter the width of the rectangle :');
perimeter= 2*length + 2*width;
fprintf('The perimeter of the rectangle is %0.2f. ',perimeter );
break;
end
Save the file as areaPeriRect.m and run.
8. Create a matlab program that will ask the user to choose between plane figures and solid figures.
If the user will choose plane figures, he will then be ask to choose among the five (5) plane figures
as mentioned in Procedure No. 4. After choosing any of the five (5) plane figures, he will then be ask
to choose between area and perimeter. If the user will choose solid figures, he will then be ask to
choose among the five (5) solid figures as mentioned in Procedure No. 5. After choosing any of the
five (5) solid figures, he will then be ask to choose between volume and surface area. Necessary
inputs are needed and the output will be any of the area or perimeter of any of the five (5) plane
figures and any of the volume and surface area of any of the five (5) solid figures.
Course: CHE 508 Laboratory Exercise No.: 3
Group No.: Section: CH51FC1
Group Members: Vasquez,Ryan Joshua R. Date Performed: July 15, 2018
Date Submitted: July 15, 2018
Instructor: Engr. Crispulo Maranan
Procedure Results
2
3
4 <periSquare.m>
wawd
<periRightTriangle.m>
<periObliqueTriangle.m>
<circumCircle.m>
<circumEllipse.m>
5 <volCone.m>
Awwww
<volSphere.m>
<volRecPar.m>
<volRightCirCyl.m>
<volCube.m>
6 <surfAreaCone.m>
<surfAreaCone.m>
<surfAreaSphere.m>
<surfAreaRecPar.m>
<surAreaRightCirCyl.m>
<surAreaCube.m>
7
8
7. Conclusion:
I therefore conclude that In this lab Exercise, I figured out how to make a Matlab Program between two kinds
of figures in strong mensuration. I figured out how to apply matlab for the calculation of volume, surface
territory, paramater and periphery of various figures utilized in strong mensuration.
1 2 3
I. Laboratory Skills
Manipulative
Members do not demonstrate Members occasionally Members always demonstrate
needed skills. demonstrate needed skills. needed skills.
Skills
Members occasionally
Member do not demonstrate Members always demonstrate
Process Skills demonstrate targeted process
targeted process skills. targeted process skills.
skills.
Members do not follow safety Members follow safety Members follow safety
Safety Precautions
precautions. precautions most of the time. precautions at all times.
Members do not know their Members have defined Members are on tasks and
tasks and have no defined responsibilities most of the have defined responsibilities at
Cooperative and
responsibilities. Group time. Group conflicts are all times. Group conflicts are
Teamwork
conflicts have to be settled by cooperatively managed most of cooperatively managed at all
the teacher. the time. times.
Ability to do Members require supervision Members require occasional Members do not need to be
independent work by the teacher. supervision by the teacher. supervised by the teacher.
TOTAL SCORE
Other Comments / Observations:
RATING = ( ) x 100%
Evaluated by:
_______________________________________