Advertisement
nigu

fun_quad

Dec 5th, 2014
178
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
MatLab 0.27 KB | None | 0 0
  1. % Definizione funzioni test per esercitazione 10
  2. %
  3. function y=fun_quad(x,no)
  4. switch no
  5.     case 1
  6.         y=sqrt(1-x.^2);
  7.     case 2
  8.         y=1./sqrt(x);
  9.     case 3
  10.         y=2*x.^3+5*x;
  11.     case 4
  12.         y=exp(-x.^2);
  13.     case 5
  14.         y=1./(1+x.^2);
  15. end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement