If the states of matter have changed such as from solid to liquid, you have to remove or add energy.
Because when anything is exposed to air, it come in contact with bacteria which begin to break down the proteins in the beans. But when it’s in a can, it can’t get exposed to bacteria which means it won’t break down.
Hope this sheds some light ♥︎
the glass of water that has been sitting in the sun cause it gathers the heat energy
the more the temperature the more energy
hope you understand and good luck