Solve for w p=2l+2w