# Derive probability relation between Bayesian Network leaves

Suppose that we have a network like the one in figure

in which we know all the conditional probabilities $P(A_i | B_j)$.

Is it possible to compute the two conditional probability $P(B1 | B2)$ and $P(B2 | B1)$?

How?

-

From the definition of conditional probabilities: $$P(B_2|B_1) = \frac{P(B_2 \cap B_1)}{P(B_1)}$$ Given whether $A_1$ and $A_2$ are true, $B_1$ and $B_2$ become independant events, so that we can write $$= \frac{\sum_c P(B_2|c)P(B_1|c)}{\sum_c P(B_1|c)}$$ where the sum is over all possible combinations of $(A_1,A_2)$, $(A_1,!A_2)$...
As all $P(B_i|(!)A_1,(!)A_2)$ are known, this can be calculated.
Thank you for your help. Just a question; i can't understand what you mean with $c$ and $\sum_{c}$. What event $c$ is? –  Aslan986 Apr 10 '12 at 17:09
$c\in\{(A_1,A_2),(A_1,!A_2),(!A_1,A_2),(!A_1,!A_2)\}$. Did not want to write out all summands (even though there are only 3 as $!A_1,!A_2$ implies $!B_1$ and $!B_2$?). So eg the denominator expands to $(...)/(P(B_1|A_1,A_2)+P(B_1|A_1,!A_2)+P(B_1|!A_1,A_2)+P(B_1|!A_1,!A_2))$ –  example Apr 10 '12 at 17:12