Code for simulating electrodynamics phenomena