0% found this document useful (0 votes)
3 views

HW3_Matlab

The document outlines Homework #3 for Engr 10300, assigned to Cesar A. Pascal, which includes reading Chapters 4 and 5 and solving problems 5.1 and 5.11. Problem 5.1 involves graphing functions such as e^x, sin(x), a quadratic equation, and the square root of x using MATLAB scripts. Problem 5.11 focuses on tensile testing, calculating stress and strain from given lengths and forces, and plotting the results.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
3 views

HW3_Matlab

The document outlines Homework #3 for Engr 10300, assigned to Cesar A. Pascal, which includes reading Chapters 4 and 5 and solving problems 5.1 and 5.11. Problem 5.1 involves graphing functions such as e^x, sin(x), a quadratic equation, and the square root of x using MATLAB scripts. Problem 5.11 focuses on tensile testing, calculating stress and strain from given lengths and forces, and plotting the results.
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7

Homework #3, Engr 10300

DATE: 09/24/2024,
NAME: Cesar A. Pascal

Homework # 3,
Read Chapters #4 and #5,
Problems:
5.1 (p. 197), 5.11 (p. 199)

Problem #5.1 (p. 197):

Script:

>>

figure(1)

x = [0:0.1:10];

y = exp(x);

plot(x,y)

grid on

title('e^x')

xlabel('x-axis')

ylabel('y-axis')

%b

figure(2)

x = [0:0.1:10];
y = sin(x);

plot(x,y)

grid on

title('sin(x)')

xlabel('x-axis')

ylabel('y-axis')

%c

figure(3)

a = 5;

b = 2;

c = 4;

x = [0:0.1:10];

y = (a*x.^2)+(b*x)+c;

plot(x,y)

grid on

title('ax^2+bx+c')

xlabel('x-axis')

ylabel('y-axis')

%d

figure(4)

x = [0:0.1:10];

y = sqrt(x);

plot(x,y)

grid on
title('Square Root of x')

xlabel('x-axis')

ylabel('y-axis')

Answer:
Discussion: For this problem I first compute then plugging the number on it to graph it. Later

put the title for the axis and the title.

Problem 5.11 (p. 199):


Script:

>> length =
[2.0000, 2.0024,
2.0047, 2.0070,
2.0094, 2.0128,
2.0183, 2.0308,
2.0500, 2.075];

Force = [0, 2000, 4000, 6000,7500, 8000, 8500, 9000, 9500, 10000];

diameter = 0.505;

Area = pi*((diameter/2)^2);

stress = Force./Area;

strain = (length - length(1))/length(1);

Stress_Strain = [stress', strain']

plot(strain,stress, '-o K')

grid on

title('Tensile Testing')

xlabel('Strain')

ylabel('Stress')

Discussion:

On this problem I compute the equation for each of the different values then compute the graph.

Answer:

stress'

strain'

Stress:
1.0e+04 *

0.9985

1.9970

2.9956

3.7445

3.9941

4.2437

4.4933

4.7430

4.9926

Strain:

0.0012

0.0024

0.0035

0.0047

0.0064

0.0091

0.0154

0.0250

0.0375

You might also like