Advertisement
Zalosin

Untitled

Nov 19th, 2018
86
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.32 KB | None | 0 0
  1. syms x;
  2. g = @(x) (3 + x - 2*x.^2).^(1/4);
  3.  
  4. A = -1;
  5. B = 3/2;
  6. figure(1);
  7. X = linspace(A,B,100);
  8. % x = -1 : 0.1 : 3/2;
  9. y = g(X);
  10. plot(X,y,'--*');
  11. hold on
  12. xlim([-1.5 2]);
  13. ylim([-1.5 2]);
  14. line([-1,-1,3/2,3/2,-1], [-1,3/2,3/2,-1,-1]);
  15.  
  16. hold off
  17.  
  18. gd = matlabFunction(diff(g(X),X));
  19.  
  20. figure(2);
  21. line ([-5,5],[1,1]);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement