Created
March 23, 2014 01:16
-
-
Save keskarnitish/9717036 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
try | |
A=[-1 -2; -4 -3; 1 0 ; 0 1]; | |
b = [ -40; -120; 0; 0]; | |
plotregion(A,b); | |
hold on; | |
x=1:30; | |
y = (100 - 4*x)/5; | |
plot(x,y,'k--','LineWidth',2) | |
y = (136 - 4*x)/5; | |
plot(x,y,'k','LineWidth',2) | |
catch ME | |
if(strcmp(ME.identifier, 'MATLAB:UndefinedFunction')) | |
rethrow(ME); | |
display('Please download PlotRegion from MATLAB File Exchange') | |
display('Link: http://www.mathworks.com/matlabcentral/fileexchange/9261-plot-2d3d-region') | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment