Question: function y =g( u ) if (0

function y=g(u) if (0<=u<1) y=sqrt(u); elseif(1<=u<2) y= (1/2+ (1/2)*u); else y= (-2*(u^2)+(17/2)*u-15/2); end endfunction N=100; x= linspace(0,3,100); y= zeros(x); for i=1:N y(i)= g(x(i)); end plot(x,y,'linewidth',3) 

can anyone tell me what is wrong whit my code it says i have in error on line 17 this is the error " Undefined operation for the given operands. check or define function %b_1_s for overloading." this is on Scilab

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!