```Date: Mar 20, 2013 3:55 PM
Author: RGVickson@shaw.ca
Subject: Re: simple statistics question

On Wednesday, March 20, 2013 3:45:21 AM UTC-7, Thomas Plehn wrote:> while(1) %Matlab code> > > > rr = rand(1,50); %sequence of 50 U(0,1) Values> > > > des = rand(1,50); %sequence of 50 U(0,1) Values> > > > diff = rr - des;> > > > %This are both decide statistics, a, b> > a = mean(rr); > > b = min(diff);> >  > > disp(a-b); %their difference is nearly constant> > %but how is it distributed (mu,sigma)> > > > %and how does that depend on sequence length (n=50)> > > > %i think we can chose U(0,1) insted of U(a,b) without los of generality> > %(linear transformation of coordinates)> > > > endIn plain English, is the following a description of your problem? (Below, I have changed the notation, and assigned different symbols from yours. However, if I understand correctly what you want, the concepts are the same.) We take two independent samples X = (X_1,X_2,...,X_n) and Y = (Y_1,Y_2,...,Y_n) from the distribution U(0,1). [n = 50 in your case.] You take the difference sequence Z = (X_1-Y_1, X_2-Y_2,...,X_n-Y_n) and compute a = mean(X), b = min(Z) = smallest of the differences X_i - Y_i. Finally, you look at D = a - b. You want the mean and variance of D, and maybe also the actual distribution.You claim that D is "almost constant", by which I assume you do the above computations many times, using many different samples, and come up with results that differ by little.Is all that a fair summary of what you are trying to say?
```