Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 1 d Solution Created 2026-10-03 Updated 2026-10-05
There are two defects. The mixed fit supplies a restricted maximum likelihood, whereas the ordinary fit supplies an ordinary log-likelihood, so their difference is not a likelihood-ratio test statistic. Also, lies on the boundary of ; the usual Wilks theorem does not give a null law.
A valid approach first refits the mixed model by ordinary maximum likelihood estimation, setting REML to false, and fits the same fixed effects under . For , maximizeover , and separately over with . Set .
For finite-sample calibration, use the location-scale invariant simulation test for a Gaussian variance component. With the actual fixed, simulate independent vectors , refit both models by ordinary maximum likelihood estimation to each, and calculate in exactly the same way. Under , . Translating by a vector in the column space of and multiplying by a positive scalar preserves the statistic: both maximized log-likelihoods acquire the same scale constant. Thus this simulation has the correct null law without knowing or . A conservative Monte Carlo p-value isIn the usual regular limit with increasing independent groups, a variance-component likelihood-ratio test at a boundary instead uses : for , its approximate tail probability is , and at the nonrandomized p-value is one. This approximation is not an exact guarantee for sixteen rats. Alternatively one can compare consistently defined restricted likelihoods with the same and simulate their restricted-ratio null distribution, as in the RLRsim documentation.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 3 d Solution Created 2026-10-03 Updated 2026-10-05
For one observation, let and define . Differentiating the softmax function and its log-likelihood gives . The sigmoid-softmax network gradients areThese equations are backpropagation: use the chain rule through the output affine map, then through the hidden units, then the input affine map.
For a learning rate , select one observation and update every parameter by , computing all entries of the gradient from the old parameters before applying the update. A uniformly selected observation gives an unbiased gradient of the average log-likelihood; multiplying by 3000 would instead estimate the gradient of the sum. Equivalently perform stochastic gradient descent on the negative log-likelihood. Batch size one makes one update per observation, and five epochs make five passes through the data, typically with a fresh random ordering on each pass.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 4 a Solution Created 2026-10-03 Updated 2026-10-05
Let denote Progabide and placebo; write for age and for baseline count. The fitted Poisson regression specifies independentIts log-likelihood isThe coefficient table in the original PDF, whose TeX transcription is truncated, gives the maximum-likelihood estimatesFor the treatment interaction contrast in a Poisson regression, the baseline slope of the log mean is on placebo and on Progabide. At fixed age and baseline , the fitted drug-to-placebo mean ratio is . Increasing baseline by one multiplies that ratio by . Thus the interaction term describes how the treatment ratio changes with baseline, rather than a uniform additive change in seizure counts. The displayed call makes clear that the source's
summary(model1) line is an object-name typo for the epilepsy fit. Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 4 b Solution Created 2026-10-03 Updated 2026-10-05
The null model has only an intercept:For , maximizing its log-likelihood gives and . The saturated Poisson regression gives each observation its own fitted mean , allowing zero as a limiting fitted mean. By the definition of Poisson deviance,Since ,Use the continuous convention . If all counts are zero, both the saturated and null likelihood maxima are attained as limits at zero mean and the deviance is zero.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 218 5 d Solution Created 2026-10-03 Updated 2026-10-05
Apply EM for a missing observation in a Gaussian AR1 process, starting from in the stationary parameter space. The Gaussian AR1 bridge gives the E-step quantitiesThus , , and , .
Let and otherwise. Keeping fixed throughout the M-step, defineThe last term comes from the missing observation's conditional variance in the two adjacent innovation squares. The expected complete-data log-likelihood isFor fixed , differentiating the quadratic in givesAlso the maximizing variance is . The M-step is therefore a one-dimensional profile likelihood maximization:Repeat the E- and M-steps until the observed-data likelihood and parameters stabilize. Exact M-steps make that likelihood nondecreasing; different initializations help detect different local optima, and convergence alone is not a guarantee of a global maximum. At an interior local maximum, impute the missing temperature by its conditional mean evaluated at the fitted parameters, retaining as its conditional uncertainty. Replacing by and discarding would not implement the expectation-maximization algorithm.
Past exam of the mathematics course of the University of Cambridge 2018 iii Paper 219 1 v Solution Created 2026-10-03 Updated 2026-10-05
A valid covariance matrix must be real symmetric and a positive semidefinite matrix, with . Conversely, every such matrix is the covariance of a possibly degenerate multivariate normal distribution. The diagonal correlations are ; the printed strict inequality can only concern distinct indices. Pairwise bounds do not suffice: the by correlation matrix with diagonal and every off-diagonal entry has eigenvalue along and is invalid. Even strict pairwise inequalities allow singularity: off-diagonal entries give an eigenvalue zero.
For the inverse requested in the question, assume in addition that is a positive-definite matrix. Write , and . Up to a constant, the log-likelihood is . Its score function and second derivative areThe correlated Gaussian common-mean estimator is thereforeIts expectation is , and direct covariance propagation givesThe Fisher information is , so this variance attains the Cramer-Rao bound and the estimator is an efficient estimator.
If is singular, an ordinary Lebesgue density and are unavailable. When lies in the range of , the same formulas hold on that range with its Moore-Penrose inverse. Otherwise there is with , and determines exactly with zero variance. The usual nonsingular Cramér–Rao calculation then does not apply.
Past exam of the mathematics course of the University of Cambridge 2019 ib Paper 1 7H a Solution Created 2026-09-24 Updated 2026-09-29
For observations , the log-likelihood of the normal distribution model isDifferentiating first with respect to gives . Substituting this value and differentiating with respect to gives the normal mean and variance maximum-likelihood estimators
Past exam of the mathematics course of the University of Cambridge 2019 ib Paper 4 19H a Solution Created 2026-09-24 Updated 2026-09-29
Apart from terms independent of , the Gaussian log-likelihood isDifferentiating with respect to givesThe unique zero, and hence the maximum-likelihood estimate, isThe same value minimizes the residual sum of squares , since maximizing the Gaussian likelihood for fixed is equivalent to minimizing this sum. It is therefore also the least-squares estimator.
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 2 28J a Solution Created 2026-09-24 Updated 2026-10-03
For , its probability generating function isThus andThe log-likelihood is, up to an additive constant,so the maximum-likelihood estimator is . The central limit theorem gives
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 3 28J a Solution Created 2026-09-24 Updated 2026-10-03
Let . The log-likelihood iswith score function and second derivative . The unique maximum-likelihood estimator is thereforeFor an exponential distribution of rate ,The central limit theorem givesApplying the delta method to , for which , yields the exponential-rate maximum-likelihood estimator limit
Past exam of the mathematics course of the University of Cambridge 2019 ii Paper 3 5J a Solution Created 2026-09-24 Updated 2026-10-03
Writing the log-likelihood as , the Fisher information matrix is the expected negative Hessian matrixUnder the usual regularity conditions it is equivalently the expected outer product of the score function.
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 2 28J Solution Created 2026-09-24 Updated 2026-09-29
PutThe log-likelihood, apart from an additive constant, isOver the full parameter space its maximum-likelihood estimates are . Under , maximizing over the nuisance parameter gives . Thus the generalized likelihood-ratio test statistic, in the convention , is
Under , the normal-sample decomposition givesWriting , the central limit theorem for a sum of squared independent standard normal variables yields . Hence Slutsky theorem givesand in particular .
For , Taylor theorem at givesConsequentlyby the continuous mapping theorem and Slutsky's theorem. Since the square of a standard normal variable has the chi-squared distribution with one degree of freedom,
Past exam of the mathematics course of the University of Cambridge 2020 ii Paper 3 5J a Solution Created 2026-09-24 Updated 2026-10-03
Conditional independence makes the log-likelihoodA maximum-likelihood estimator is any . If the model has fitted real parameters, its Akaike information criterion is
Past exam of the mathematics course of the University of Cambridge 2021 ib Paper 4 17H a Solution Created 2026-09-24 Updated 2026-09-25
Here has the binomial distribution , so, up to a factor independent of , the likelihood function isFor , differentiating the log-likelihood givesand the boundary cases give the same formula. Thus the binomial proportion maximum-likelihood estimator is
Past exam of the mathematics course of the University of Cambridge 2021 ii Paper 1 29J a Solution Created 2026-09-24 Updated 2026-09-25
Letbe the log-likelihood. The score function and scalar Fisher information areUnder the usual regularity conditions the score has mean zero, so this is also its variance.
The information tensorizes when it is additive over observations. For identically distributed observations,For an independent sample the joint score is the sum of the individual scores, and the mean-zero score identity makes all cross covariances vanish. This is the Tensorization of Fisher information.
Past exam of the mathematics course of the University of Cambridge 2021 ii Paper 3 28J a Solution Created 2026-09-24 Updated 2026-10-03
The log-likelihood is, up to constants, , so the maximum-likelihood estimator is . By the central limit theorem,Applying the delta method to gives
Past exam of the mathematics course of the University of Cambridge 2022 iii Paper 218 1 b Solution Created 2026-09-28 Updated 2026-10-03
Let be row of the design matrix, , and . The full log-likelihood isDifferentiation gives the score functionandThe Hessian does not depend on , so the Fisher information matrix is
Past exam of the mathematics course of the University of Cambridge 2022 iii Paper 218 3 c Solution 2026-09-28
Writing , the log-likelihood isWith 500 observations and 5000 word predictors, the augmented design matrix cannot have full column rank. There are nonzero coefficient directions that leave every unchanged, so any maximizer belongs to an affine family and is not unique. In addition, the high-dimensional features may completely separate the classes, in which case no finite maximizer exists at all.
Past exam of the mathematics course of the University of Cambridge 2022 iii Paper 219 1 c Solution Created 2026-09-28 Updated 2026-10-03
Letand setThe within-galaxy contrasts contain no , so the parameter-dependent log-likelihood reduces toThe score equations give the maximum-likelihood estimatorsThe calibrator and Hubble-flow samples are independent, so both estimators are unbiased andThe Fisher information matrix for isHence : attains the multiparameter Cramer-Rao bound.
Past exam of the mathematics course of the University of Cambridge 2022 ii Paper 1 29K b Solution Created 2026-09-24 Updated 2026-09-25
For observations , the log-likelihood is, up to an additive constant,Its unique maximum isNow and, using , . The central limit theorem followed by the delta method for gives