if getfield(r, 'width') > getfield(p, 'width') then -- change the width of p
r, p, post_intrusion = enlarge_parent(r, p, ppre, pmid, ppost, mapre, mapost, intmode)
elseif getfield(r, 'width') < getfield(p, 'width') then -- change the width of r
if getfield(r, 'width') > getfield(p, 'width') then -- change the width of p
r, p, post_intrusion = enlarge_parent(r, p, ppre, pmid, ppost, mapre, mapost, intmode)
elseif getfield(r, 'width') < getfield(p, 'width') then -- change the width of r