# Integrate white noise

17/07/2011

It is suppose the matlab function “randn” can give a zeros mean Gaussian distributed random number. If we add many this kind of number together, what we will get? will the sum approach to zero? The following is a simple example. The answer is no.

clc;clear;close all num=100000; sum=zeros(1,num); for i=2:num sum(i)=sum(i-1)+randn; end plot([1:num],sum)

Advertisements

No comments yet