Past exam of the mathematics course of the University of Cambridge 2017 iii Paper 216 2 Solution Created 2026-10-03 Updated 2026-10-06
Write for the directed edges from parent to child and for the state at site . The global Markov property for an undirected graph on this tree, together with the specified parent transitions, gives the complete-data likelihood functionOne can obtain the factorization by successively removing terminal subtrees: after conditioning on their parent, each subtree is independent of the rest. The root factor and transition products also show that different sites are independent. Only ancestral states are latent variables.
At the current Markov kernel , define expected transition countsThe E-step of the expectation-maximization algorithm isMaximize separately for each row under and . For , the Lagrange multiplier equation is , with zero-count entries set to zero at a boundary maximum. Thus the EM transition-count update on a tree isIf , that row does not occur in ; any row probability distribution, including its previous value, maximizes the objective.
The expected counts can be computed exactly by the Felsenstein pruning algorithm and an outward belief propagation pass. For one site, let be the conditional probability of observations in the subtree below , given state . For a leaf with observed state , . For an internal vertex,Define as the joint mass of state at and all observations outside its subtree. The root has . For a child of , putThe edge posterior probability required above isMultiply the inside and outside factors to obtain the joint mass of the observations and endpoint states; division by the site likelihood function proves this expression. Sum over edges and sites to form . The two passes take operations on a binary tree. Scaling messages or computing them logarithmically avoids underflow.
A strictly positive initial Markov kernel ensures for every observed leaf pattern, so every E-step is defined. At a later boundary iterate, require positive likelihood for the actual data and restrict the conditional distribution to its support. EM likelihood monotonicity proves that the update cannot decrease observed-data likelihood function. It is a maximum-likelihood iteration, not a guarantee of finding the global maximum-likelihood estimate; different initial kernels may lead to different stationary points.
Past exam of the mathematics course of the University of Cambridge 2017 ii Paper 2 26K c Solution Created 2026-09-24 Updated 2026-10-05
The support restricts to , and . Within its feasible interior, the likelihood function is proportional to and is strictly increasing in , diverging as . Under the printed infinite-endpoint-density, or extended-likelihood convention, the maximum-likelihood estimator isA density is defined only almost everywhere. If its value at the singular endpoint is reassigned a finite value, a finite maximum need not exist; the sample-minimum answer uses the stated endpoint/supremum convention.
Independence and on giveThe error is positive almost surely, so the estimator is not an unbiased estimator. More explicitly its bias is
Past exam of the mathematics course of the University of Cambridge 2017 ii Paper 4 12J b Solution Created 2026-09-24 Updated 2026-10-05
The two design matrices span the same six-dimensional space of arbitrary log means for the six periods. Fit.2 uses the first period as a baseline, whereas fit.3 uses cumulative indicator steps. If is the log mean for period , fit.3 has intercept and jump coefficients . Thus both fits give identical fitted means and identical maximized likelihood functions. ThereforeDifferent coefficient tests arise because they test different contrasts, not because one full fit explains the observations better.
Past exam of the mathematics course of the University of Cambridge 2018 ib Paper 1 7H Solution Created 2026-09-24 Updated 2026-10-03
The distribution function is on , so its median is . The likelihood function iswhich decreases over its admissible range. Hence . By the invariance property of maximum likelihood estimation,
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 216 3 a Solution Created 2026-10-03 Updated 2026-10-05
Write , , and . We keep the model's printed coefficient literally. Its latent log odds can be writtenThe independence of the is conditional on : they are not marginally independent when the random effects are correlated.
Holding the other predictors and the random-effect realization fixed, increasing predictor by one shifts the latent log odds by , so it multiplies the conditional odds of a late departure by . For a binary snow indicator, this compares the snow and no-snow days with other predictors held fixed. This is a conditional odds ratio, not generally the same as a marginal odds ratio after integrating the random effects.
Randomizing allows unmeasured daily conditions to change the success probability beyond the systematic linear predictor. In this logistic-normal regression with autoregressive random effects, let and . The law of total variance givesso the mixture allows overdispersion beyond a binomial distribution with fixed probability. The correlated part also allows related outcomes on nearby days.
The stationary autoregressive process of order one has and . HenceThe term is unstructured daily variability, whereas is the temporally correlated component under the printed parameterization. Larger gives greater persistence: the lag- correlation of the latent log odds is .
The PDF itself prints both the coefficient and the requested combination . They are inconsistent as a marginal variance. If the intended coefficient were , the variance and off-diagonal covariance would instead be and . The prior's argument list also repeats ; its displayed density indicates the intended second variance parameter is .
There is a further substantive issue with that improper prior. After integrating the latent variables, the observed-data likelihood function is positive and continuous at for fixed finite , positive , and . On a compact positive-volume set of those parameters it therefore has a positive lower bound for small . The prior density is , so integrating over gives . Thus the stated joint posterior distribution is improper, an instance of improper posterior from a log-uniform random-effect scale prior. The requested fixed-parameter conditional laws below are nevertheless proper; their existence does not remedy the joint impropriety.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 216 4 c Solution Created 2026-10-03 Updated 2026-10-05
Fix the observed , let , and let . The E-step formsFor finite expected log-likelihoods and , the Jensen inequality givesThe first inequality allows additional mass outside the old complete-data support; it is equality when the relevant supports coincide. Ratios are taken on the support of . If a candidate assigns zero density on positive -mass, its is minus infinity and it cannot be an improving finite M-step.
An M-step of the expectation-maximization algorithm chooses with , soThis EM likelihood monotonicity also holds for a generalized M-step that merely increases , rather than maximizing it exactly. It is a statement about the observed-data likelihood function.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 5 b Solution Created 2026-10-03 Updated 2026-10-05
The parameters are , and innovation variance . Stationarity gives , and the Markov property gives . Multiplying the initial density and the transition densities yields the stationary Gaussian AR1 likelihood, with :The initial-observation factor depends on all three parameters and must be retained for the full stationary likelihood function. Omitting it gives a conditional likelihood given , a different objective.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 5 c Solution Created 2026-10-03 Updated 2026-10-05
By the Markov property, all factors in the stationary likelihood function that involve are the transitions from to and from to . Hence conditioning on later observations adds no information once the two neighbors are known. Writing , and , its conditional density is proportional toThe quadratic coefficient of is and the linear coefficient is . Completing the square therefore gives the Gaussian AR1 bridgeHere is the innovation variance, not the marginal stationary variance.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 219 2 i Solution Created 2026-10-03 Updated 2026-10-05
Write , and . The latent absolute magnitude and measurement error are independent normal variables, so their convolution is normal. After integrating out the individual intrinsic magnitudes, each apparent magnitude has distributionConsequently the likelihood function for the independent sample isThis is the marginal observational likelihood of a hierarchical Bayesian model, not the likelihood conditional on each unknown intrinsic magnitude. The individual errors remain heteroscedastic through their known .
Past exam of the mathematics course of the University of Cambridge 2018 ii Paper 4 13J b Solution Created 2026-09-24 Updated 2026-10-03
Whenever players 1 and 2 occur, the linear predictor contains their parameters only throughFor any constants , replacingleaves every fitted probability and hence the likelihood function unchanged. The parameterization is therefore nonidentifiable: at most can be estimated uniquely. Hence there is no unique maximum-likelihood estimate of the three separate parameters.
Past exam of the mathematics course of the University of Cambridge 2019 ib Paper 2 8H a Solution Created 2026-09-24 Updated 2026-09-29
Let be the number of heads. The likelihood function for the Bernoulli distribution sample is proportional to . A uniform distribution prior on is the distribution, so Beta-binomial conjugacy gives the posterior distribution
Past exam of the mathematics course of the University of Cambridge 2019 iii Paper 219 1 a Solution 2026-10-03
LetSubtracting the measured distance modulus from the measured apparent magnitude givesFor the Hubble flow, defineThe Hubble law, with the Hubble constant parametrized by , gives . After integrating over each intrinsic absolute magnitude and each unobserved true distance modulus, independence therefore gives the likelihood function
Past exam of the mathematics course of the University of Cambridge 2019 iii Paper 350 1 a Solution Created 2026-10-03 Updated 2026-10-05
Let be the probability density function of the unknown and that of the noise, both relative to Lebesgue measure. By independence of random variables, the conditional distribution of the measurement given has density . Thus its likelihood function and the joint density areThe Bayesian model evidence is the marginal data densityBayes theorem gives the posterior density solving this Bayesian inverse problem:This formula applies when . Since by Tonelli theorem, these conditions hold almost everywhere under the marginal data law. Values of a conditional distribution at exceptional data are not determined by the joint law. The posterior mean or a maximum a posteriori estimate can then give a point estimate, while the full posterior density describes the remaining uncertainty.
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 1 13J b Solution Created 2026-09-24 Updated 2026-09-29
Write and . Under the model in part (a),and is independent of the price category . The Poisson-multinomial conditioning identity givesMore explicitly, the likelihood function for row factors asThe first factor is the likelihood of the row total and the second is the conditional multinomial likelihood. The free price effect makes the first factor maximal at , while maximizing the remaining factors givesConsequently both fits have the same maximum-likelihood fitted valueHere every row total is , the column totals are , and , so every fitted row isThis factorization is the Poisson trick.
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 4 28J a Solution Created 2026-09-24 Updated 2026-10-03
For observations , the likelihood function isA maximum-likelihood estimator is any measurable choiceFor one observation in a regular scalar model, the score function isand the Fisher information iswhere the second identity requires the usual differentiation-under-the-integral regularity. For independent observations, Tensorization of Fisher information gives .
Past exam of the mathematics course of the University of Cambridge 2020 ib Paper 1 19H a Solution Created 2026-09-24 Updated 2026-09-29
Let . The likelihood function isOn its feasible range , this is decreasing in . Therefore the maximum likelihood estimator is
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 3 28J ii Solution Created 2026-09-24 Updated 2026-09-29
Let be the likelihood function. Since the prior distribution is , the posterior density has the formwhere is the normalizing constant.
Choose and use the Gaussian autoregressive proposal reversible with respect to a standard normal distributionThuswhose covariance matrix is the required . Reversibility with respect to the standard normal distribution sayssoThe Metropolis–Hastings acceptance probability therefore reduces toThis is the Preconditioned Crank–Nicolson algorithm with proposal scale .
Past exam of the mathematics course of the University of Cambridge 2021 ib Paper 1 6H a Solution Created 2026-09-24 Updated 2026-09-25
A sufficient statistic is one for which the conditional distribution of the full sample given does not depend on . TakeFor a binary sample with , its likelihood function iswhich depends on the data only through . By the Fisher-Neyman factorization theorem, is sufficient. Equivalently, conditionally on , the sample is uniform over the binary vectors containing ones, independently of .