clc; clear all ;
%%Q1a
clear;clc;
% Get the span of the beam along with positions of supports
l = input('Enter the span of the beam');%m
x =input('Enter the distance of pinned support from left end in m') ;
y = input('Enter the distance of roller support from left end in m') ;
% Check if the support locations specified are inside the span
while((x >l) || (y >l))
sprintf('The support location should be inside the span')
x = input('Reenter the value of x') ;
y = input(' Reenter the value of y') ;
end
disp('OK')
% Check if the supports are not given at the same location
while((x == y))
sprintf('The supports cannot be at the same location')
x = input('Reenter the value of x') ;
y = input(' Reenter the value of y') ;
end
disp('OK')
% Check if the beam is overhanging or simply supported
if((x<l)&&(y<l))
sprintf('The beam is overhanging')
else
sprintf('The beam is simply supported')
end