clear all; clc; % plate_sxx = load('plate_sxx.txt'); %ANSYS result plate_sxx = dlmread('plate_sxx.txt', '', 1, 1); %ANSYS result % Exact for infinite plate a = 2.5; sigma_o = 1; r = linspace(2.5,10,51); s_xx_theory = 1 + (a./r).^2; s_xx_theory = s_xx_theory + (1 + 3*(a./r).^4); s_xx_theory = s_xx_theory*0.5*sigma_o; %Figure figure(1); clf; h=plot(plate_sxx(:,1)/10+2.5,plate_sxx(:,2),'-k'); hold on; set(gca,'Box','on','LineWidth',2,'FontName','Helvetica',... 'FontSize',14); set(h,'LineWidth',2); h=plot(r,s_xx_theory,'--r'); set(h,'LineWidth',2); legend('ANSYS','Theory'); xlabel('y (cm)'); ylabel('\sigma_{xx} (MPa)'); title('\sigma_{xx} variation along y axis'); axis square;