P = [0 0] ;
L = 1000 ; % length of beam
B = 0.5 ; % breadth of beam
B = [P ; L P(2) ; L B ; P(1) B] ;
patch(B(:,1),B(:,2),'b')
ylim([-5 5])
box on
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!