How to filter a white noise or random noise in Matlab Simulink? I am working on a sun-synchronous satellite Simulink model wich determines its attitude from a Sun sensor and a star sensor whom measure the sun and star direction in the satellite body reference frame. I have to introduce measure errors on both sensors using a "white noise" Simulink block, but I prefer to generate the noise through a Matlab function block using the function "rand" (or shoul'd I use the "randn" function?).

My issue is that I have to filter the noises on the measurements before sending them to a block who compute the attitude quaternion error to feed it to a PID controller blockset which commands a Reaction Wheels Assembly. Without noise the satellite flies smoothly.

I have tried some solution such as lowpass filter, Butterworth filter, mean on peaks and downs, but nothing seems to work properly.

I cannot figure out, for example, which should be the cut off frequency to set up on a lowpass filter ( I cannot figure out if the lowpass filter is the correct choice for such a problem, too).
It may be useful to have a deeper understanding of you satellite's dynamics. 
What I mean is that by observing your attitude quaternion error variation DSP ( or using the motion mathematical model), you may be able to choose a convenient filtering type/tuning to get rid of most possible white noise.