For the first observations, write
By Gaussian conjugacy for a normal linear model, the prefix posterior is
Compute a Cholesky decomposition of once. If is row of the design matrix, then
The Rank-one Cholesky update obtains a triangular factor from in operations. Two triangular solves give , and, for , another solve gives
The initial factorization costs and all updates and samples cost . This is within the requested bound.
Put . The Weighted graph Laplacian of the tree is defined by
Multiplication of the Gaussian likelihood by the prior shows that, conditionally on the precision parameter ,
Completing the square therefore gives
As a function of , the posterior density is
so, in shape-rate notation,
The precision matrix has the sparsity pattern of a tree. A sparse Cholesky decomposition and its triangular solves have cost and storage on this graph, while the gamma update also costs . Hence each systematic-scan Gibbs sampler iteration costs .
Rank-one Cholesky update 2026-09-28
Given a Cholesky decomposition , a rank-one Cholesky update computes a triangular factor of in operations without refactorizing the matrix from scratch.