  We introduce a method to compute Casimir forces in arbitrary geometries and
for arbitrary materials based on the finite-difference time-domain (FDTD)
scheme. The method involves the time-evolution of electric and magnetic fields
in response to a set of current sources, in a modified medium with
frequency-independent conductivity. The advantage of this approach is that it
allows one to exploit existing FDTD software, without modification, to compute
Casimir forces. In this manuscript, part I, we focus on the derivation,
implementation choices, and essential properties of the time-domain algorithm,
considered both analytically and illustrated in the simplest parallel-plate
geometry. Part II presents results for more complex two- and three-dimensional
geometries.
