%MATLAB-funksjonen mfd.m function xdot=mfd(t,x) global m D Kf u=4; xdot(1)=x(2); xdot(2)=-(Kf/m)*x(1)-(D/m)*x(2)+(1/m)*u; xdot=[xdot(1);xdot(2)];