Expected number of friends I have a random thought experiment that I am having trouble working through.Suppose there are $N_s$ sophomores and $N_j$ juniors. It is observed that juniors have on average a total of $j$ friends, and that sophomores have on average a total of $s$ friends. Assuming that a junior and a sophomore are equally likely to be friends with each other as a junior and a junior (or a soph and a soph), what is the expected number of:


*

*junior-junior friends

*soph-soph friends

*junior-senior friends


(and then repeat the question with a bias towards within-group friends, but I think I can work that out once I figure this one).
What I've tried:
I think that if juniors/sophs only befriend each other, then you would have a total of
$$ \frac{jN_j}{2} \ \text{and}\  \frac{sN_s}{2}$$
friends, respectively. 
Now going back to the general case, looking at junior-junior friends. Then the maximum possible number of junior-junior friends is $\frac{jN_j}{2}$, but this is where I get stuck. Any tips? Thanks :)
EDIT. Would the expected number of junior-junior friends be
$$ \sum_{i=1}^{jN_j/2} \frac{jN_j}{jN_j + sN_s} = \frac{(jN_j)^2}{2(jN_j+sN_s)}$$
EDIT2. A few posters have found that $s=j$, but this can't be true...all I meant was that there is no preferential attachment among each group.
 A: I presume that being a friend is a symmetric and irreflexive relation: if $x$ is a friend of $y$, then $y$ is a friend of $x$, and nobody is their own friend. Moreover, all friends are either sophomores or juniors.
Let $x_{ss}$ be the number of ordered pairs $(a,b)$ where $a$ and $b$ are friends and both are sophomores.  Similarly for $x_{sj}$, $x_{js}$, $x_{ss}$.  By symmetry, $x_{sj} = x_{js}$.  If the average number of friends per sophomore is $s$, that says $x_{ss} + x_{sj} = s N_s$, and if the average number of friends per junior is $j$, $x_{js} + x_{jj} = j N_j$.  Now there are $N_j (N_j-1)$ possible ordered pairs of distinct juniors,
so the probability of two distinct juniors being friends is $x_{jj}/(N_j (N_j-1))$.
Similarly, the probability of two distinct seniors being friends is $x_{ss}/(N_s (N_s-1))$, and the probability of a junior and a senior being friends is $x_{sj}/(N_s N_j)$.  You seem to be asserting that these are equal: if so we have the system of four equations
$$ \eqalign{x_{ss} + x_{sj} &= s N_s\cr
            x_{sj} + x_{jj} &= j N_j\cr
            N_s (N_s-1) x_{jj} &= N_j (N_j-1) x_{ss}\cr
            N_s N_j x_{jj} = N_j (N_j-1) x_{sj}\cr}$$
I'll assume $N_j > 0$, and $N_s > 0$, so we can divide the last equation by $N_j$.  We should be able to solve for four variables, let's say $x_{ss}, x_{js}, x_{jj}, j$:
$$\eqalign{x_{ss} &= \frac{s N_s (N_s - 1)}{N_s + N_j-1}\cr
           x_{sj} &= \frac{s N_j N_s}{N_s + N_j - 1}\cr
           x_{jj} &= \frac{s N_j (N_j - 1)}{N_s + N_j - 1}\cr
                j &= s\cr} $$
So your assumptions imply that the average numbers of friends per sophomore and per junior are equal.
A: Let $p$ be the probability that two people picked at random are friends.  The question indicates that $p$ doesn't depend on whether or not the two people are in the same class.  We have $$j=p(N_j-1+N_s)\\
s=p(N_s-1+N_j)$$ so that $j=s,$ but that's incidental.  What's important is that $$p=\frac j{N_j+N_s-1}$$  Now you should be able to answer all the questions, using linearity of expectation.  
