MATLAB: Why i get error

matlab function

i=i
MO=1;
fi=-pi:pi/100:pi;
y=(MO*(exp(fi*i))*(2*exp(fi*i)+1))/(EI*(8*exp(fi*i)+2*exp(2*fi*i)+2))
i got:
??? Error using ==> mtimes Inner matrix dimensions must agree.
Error in ==> rrrr at 10 y=(MO*(exp(fi*i))*(2*exp(fi*i)+1))/(EI*(8*exp(fi*i)+2*exp(2*fi*i)+2))

Best Answer

It would help if you told us what EI is. I just made it equal to 1 here. Is this what you are looking for?
And why do i=i????
MO=1;
fi=-pi:pi/100:pi;
EI = 1;
y=(MO*(exp(fi*1i)).*(2*exp(fi*1i)+1))./(EI*(8*exp(fi*1i)+2*exp(2*fi*1i)+2));