In micromagneticmodel
package, a base class micromagneticmodel.Driver
is defined. Its purpose is to build individual drivers in a particular micromagnetic calculator. In this tutorial, we will demonstrate some of its basic properties.
import micromagneticmodel as mm
driver = mm.Driver()
Driver
class does not require any parameters to be passed at initialisation. However, any keyword argument can be passed.
driver = mm.Driver(t=1e-9, n=30)
The attributes are
driver.t
1e-09
driver.n
30
The main driver method which must be implemented by a derived class is drive
.
try:
driver.drive()
except NotImplementedError:
print('Exception raised.')
Exception raised.
Full description of all existing descriptors can be found in the API Reference.