  In the ballistic regime we study both semiclassically and quantum
mechanically the electron's dynamics in two-dimensional electron gas (2DEG) in
the presence of an inhomogeneous magnetic field applied perpendicular to the
plane. The magnetic field is constant inside four separate circular regions
which are located at the four corners of a square of side length larger than
the diameter of the circles, while outside the circles the magnetic field is
zero. We carry out the stability analysis of the periodic orbits and for given
initial conditions numerically calculate the two-dimensional invariant torus
embedded in the four-dimensional phase space. Applying the Bohr--Sommerfeld and
the Einstein--Brillouin--Keller semiclassical quantization methods we obtain
the energy levels for different magnetic field strengths. We also perform exact
quantum calculations solving numerically the discretized version of the
Schr\"odinger equation. In our calculations, we consider only those bound
states that are localized to the neighborhood of the four magnetic disks. We
show that the semiclassical results are in good agreement with those found from
our quantum calculations. Moreover, the current distribution and the phase of
the different wave functions enable us to deduce the two quantum numbers $n_1$
and $n_2$ characterizing the energy levels in the semiclassical methods.
Finally, we present two examples in which the quantum state shows a similar
structure to the previous states, but these are special in the following sense.
One of them is a scar state localized to the neighborhood of the periodic orbit
while this orbit is already unstable. In the case of the other state, the
current density is circulating in two rings in opposite direction. Thus, it is
not consistent with the classical motion in the neighborhood of the periodic
orbit.
