The quadratic product "%&%" is a convenience function for pre- and post-multiplying a matrix B by another matrix A and its transpose A', ie.. ABA'
A %&% B is equivalent to A %% B %% t(A)