clear all figure(1) figure(gcf) syms x y1=-3*x+18; y2=(-3*x+27)/4; figure(gcf) hold on X=solve(y1==y2); f1=inline(y1); f2=inline(y2); plot(X,f1(X),'*b') fplot(char(y1),[double(X)-5 double(X)+5],'r') fplot(char(y2),[double(X)-5 double(X)+5],'g') hold off clear all figure(2) figure(gcf) syms x y e1=3*x+y-18; e2=3*x+4*y-27; figure(gcf) hold on [X,Y]=solve(e1,e2,'x','y'); plot(X,Y,'*b') h1=ezplot(e1,[double(X)-5 double(X)+5]); set(h1, 'Color', 'r'); h2=ezplot(e2,[double(X)-5 double(X)+5]); set(h2, 'Color', 'g'); grid on hold off |
José Jeremías Caballero
Servicios de Programación en MatLab
https://programacioncaballero.blogspot.com/Lima - Perú
Para mayor informacion, contactarse a jjcc94@hotmail.com
No hay comentarios:
Publicar un comentario