Demagnetization and How it Works