wolffd@0: function pot = cg_mom_to_can(pot) wolffd@0: % CG_MOM_TO_CAN Convert a CG potential from moment to canonical form, if necessary. wolffd@0: % pot = cg_mom_to_can(pot) wolffd@0: wolffd@0: if pot.subtype ~= 'c' wolffd@0: for i=1:pot.dsize wolffd@0: pot.can{i} = mpot_to_cpot(pot.mom{i}); wolffd@0: end wolffd@0: pot.subtype = 'c'; wolffd@0: end