Trying to plot multiple values

Hello, I'm trying to plot multiple values on one graph. For the attached code, I can get the plots for Ex to show up, but not for Gxy. Any help would be appreciated.

Answers (1)

That's because your code is breaking due to error at the following line of code on the first iteration of the second for-loop. You should have seen red warning text in your command window pointing to this line of code.
G_Inverse = 2*(2/E11+2/E22+4*v12/E11-1/G12)*(sind(theta)^2)*(cosd(theta)^2)+1/G12((cosd(theta)^4)+(sind(theta)^4));
% P R O B L E M I S H E R E ----------------------------------------------^
Instead, if you're intention is to multiply,
G_Inverse = 2*(2/E11+2/E22+4*v12/E11-1/G12)*(sind(theta)^2)*(cosd(theta)^2)+1/G12 * ((cosd(theta)^4)+(sind(theta)^4));
% S O L U T I O N I S H E R E -------------------------------------------- ^

Categories

Tags

Asked:

on 8 Apr 2019

Commented:

on 9 Apr 2019

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!