The Feynman algorithm needs no modification to deal with forces that depend on time as well as position. Consider the example of a mass that is attached to a spring and is subjected to a driving force that varies sinusoidally at the natural frequency of oscillation of the mass-spring system. The analytic solution of this problem is beyond the level of introductory physics texts, but the numerical solution requires only direct application of the Feynman algorithm. The parameters of the problem are given in the program listings, and the output is a plot of the driving force and the response of the mass. (The mass is at rest at its equilibrium position when the force is turned on.)
When the oscillator is driven at its natural frequency, the response appears to increase linearly with time, and to lag the force by 90 degrees. (This information enables us to guess a particular integral and proceed with a standard analytic solution if we wish.) When the driving frequency is 90% of the natural frequency, the oscillation builds up until it is in phase with the driving force, then decreases. At 110% of the natural frequency, the maximum response occurs when it is 180 degrees out of phase with the driving force.