# Oddly Worded uniform probability Question

1. Jul 4, 2004

### Goalie_Ca

X has a uniform distribution of [0,1]
Y = h(x) = max(X,1-X)

question: pdf is what?

i think it is (x-a)/(B-A) = x , so for
pdf = x for x>0.5 and 1-x for x<0.5,

then part b is median, and part c is expected value and variance.

This is not a homework, but this is on a review sheet.

2. Jul 5, 2004

### Wong

Note that max(M, N) <= y if and only if M<=y and N <=y. Thus

Pr(max(1-X, X)<=x)
=Pr(1-X<=x and X<=x)
=Pr(1-x<=X<=x)

note that when x<0.5, the RHS is larger than the LHS such that the probability equals zero. For 0.5<=X<=1, the probability is easily seen to be x-(1-x) = 2x-1. When x>1, the statement "1-x<=X<=x" is trivially true (as 0<=X<=1) so the probabiluity equals 1. Combining, (the F(y) be the distribution function of Y)

F(y) = 0 when y<0.5
= 2x-1 when 0.5<=y<=1
= 1 when y>1

From this one may obtain the density function and so on.

3. Jul 5, 2004

### mathman

It looks to me that Y is uniformly distributed between .5 and 1. There are 2 cases, depending on x<.5 or x>.5. In the first case 1-x (the max) is uniform between .5 and 1, while in the second case x (the max) is uniform between .5 and 1.

4. Jul 6, 2004

### Goalie_Ca

If I've followed right you're saying that the pdf is uniform and is limited to [0.5,1]

Wong, I followed your logic after the first line.
I think i get what mathman is saying as well.