theta=2;
randn('state',1127);
sigma=0.1; %desvio standard
nu=sigma*randn(1000,1);
nu=nu-mean(nu);
y=theta+nu;
n=[1:1:length(nu)]';
plot(n,y,'r',n,theta*ones(length(nu),1),'b')
rmse=sqrt(norm(nu)^2/length(nu));