Professional Documents
Culture Documents
clear all;
close all;
clc;
syms x
y=sin(x).*((cos(x)).^2)+2*x;
h=diff(y);
j=subs(h,x,pi/2);
subplot(2,1,1);ezplot(y);set(ezplot(y),'Color','r','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin');grid;...
subplot(2,1,2);ezplot(h);set(ezplot(h),'Color','g','LineStyle',':');hold on;
plot((pi/2),j,'r*');text((pi/2),j,'Punto (pi/2,2)');title('Primera Derivada');...
% FIN
clear all;
close all;
clc;
>> syms x;
>> y3 = diff(y,x,3)
>> y4 = diff(y,x,4)
>> y5 = diff(y,x,5)
>> y7 = diff(y,x,7)
>>subplot(2,4,1);ezplot(y);set(ezplot(y),'Color','r','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin');grid;...
subplot(2,4,2);ezplot(y1);set(ezplot(y1),'Color','b','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y1');grid;...
subplot(2,4,3);ezplot(y2);set(ezplot(y2),'Color','k','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y2');grid;...
subplot(2,4,4);ezplot(y3);set(ezplot(y3),'Color','m','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y3');grid;...
subplot(2,4,4);ezplot(y3);set(ezplot(y3),'Color','b','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y3');grid;...
subplot(2,4,5);ezplot(y4);set(ezplot(y4),'Color','m','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y4');grid;...
subplot(2,4,6);ezplot(y5);set(ezplot(y5),'Color','r','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y5');grid;...
subplot(2,4,7);ezplot(y6);set(ezplot(y6),'Color','b','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y6');grid;...
subplot(2,4,8);ezplot(y7);set(ezplot(y7),'Color','g','LineStyle','-.');title('Grafica de la
funcin');xlabel('Eje x');ylabel('Eje y');legend('Funcin y7');grid;...
%FIN