Every atom has its own field that kinda aligns with the surrounding atoms in magnets, so altogether they add up to the object’s magnetic field. As they heat up, they get more and more energy and start to wiggle around until those fields aren’t all aligned. When they lose that alignment, they start interfering with each other so the big magnetic field gets weaker and weaker until it’s all a mess, or until something comes and realigns them.
Latest Answers