Expansion Tanks

How does Boyle’s law relate to sizing expansion tanks in domestic hot water systems?
what size expansion tank is required?