A non-linear dissipative model of magnetism