  Development of quantum engineering put forward new theoretical problems.
Behavior of a single mesoscopic cell (device) we may usually describe by
equations of quantum mechanics. However if experimentators gather hundreds of
thousands of similar cells there arises some artificial medium that one already
needs to describe by means of new electromagnetic equations. The same problem
arises when we try to describe e.g. a sublattice structure of such complex
substances like perovskites. It is demonstrated that the inherent primacy of
vector potential in quantum systems leads to a generalization of the equations
of electromagnetism by introducing in them toroid polarizations. To derive the
equations of motion the Lagrangian and the Hamiltonian formalisms are used.
Some examples where electromagnetic properties of molecules are described by
the toroid moment are pointed out.
