I am trying to solve the following problem on an assignment.
Anna has two dice. Die $F$ is fair: it rolls $1,2,3,4,5$ or $6$ with equal probability $\frac{1}{6}$. Die $D$ is dodgy: Anna suspects that it may be rolling even and odd numbers with unequal probabilities. To investigate, Anna rolls die $D$ 40 times; 32 of these rolls result in odd numbers.
Let $q$ be the probability of rolling an odd number on die $D$.
The next day, Anna's friend Bob borrows Anna's dice and tries a different experiment. He rolls dice $D$ and $F$ together, multiplies the two resulting numbers, and notes whether the product is even or odd. After repeating this procedure 50 times, he finds that the product was odd on 16 occasions.
Find the maximum likelihood estimate of $q$ based on the two experiments combined.
The number of odd numbers that Anna records $X_A$ is clearly distributed as
$X_A \sim Bin(40,q)$
For Bob, the probability of recording an odd result is
$\mathbb P(\textrm{product is odd}) = \mathbb P(D\textrm{ is odd}) \mathbb P(F\textrm{ is odd}) = 0.5q$
since we know that die $F$ is fair. Therefore the number of odd numbers he records $X_B$ should be distributed
$X_B \sim Bin(50,0.5q)$
Finally, I understand that the MLE $\hat{q}$ should satisfy
$\frac{\textrm{d}}{\textrm{d}q} \mathbb L(q; X_A = 32)\mathbb L(0.5q; X_B = 16) = 0$
Is this correct? Taking the derivative of the function above and solving for $\hat{q}$ seems to be much too complicated. Thank you in advance for your feedback.