function y = myfun(x) % % Returns the function value y = (x^2 + 5)/(2*x). % The dots before the exponentiation and division operator below % enforce the operation to be carried out componentwise. % These dots are necessary when x is a vector. % y = (x.^2 + 5)./(2*x);