# Hamiltonian formalism in quantum electrodynamics

I need to compute $\frac{d}{dt}\hat{\mathbf P} = \frac{d}{dt}(\hat{\mathbf p} - q\hat{\mathbf A})$ for the solutions of $$(i\gamma^{\mu}\partial_{\mu} + q\gamma^{\mu}A_{\mu} - m)\Psi = 0.$$ May I use Hamiltonian formalism for that. I mean that I may rewrite the equation above in a form $$i\partial_{t} \Psi = \hat{H}\Psi$$ (or I need also introduce $\hat{P}_{0} = \hat {p}_{0} - q\hat {A}_{0}$ and rewrite the equation in form $\hat {P}_{0}\Psi = \hat {H}\Psi$?) and get time derivation operation of average value of my operator of generalized momentum as average value of commutator $i[\hat{H}, \hat{\mathbf P}]$? Maybe also I need to include partial derivative of my operator, because $\hat{\mathbf A}$ depends on $t$. But I am not sure in all of these statements. Can you make it more clear for me?

-