wolffd@0: function D = PsdToEdm(G) wolffd@0: wolffd@0: d = diag(G); wolffd@0: D = bsxfun(@plus, d, d') - 2 * G;