# Help: Difference Equation

The "Difference equation" algorithm interprets an equation of the form
Y' = <function>

as defining the value of Y at the next step. The function on the right side
of the equation may depend on any variables (using their values at the
current step). The independent variable indexes the steps (but note that
its values are not necessarily integers, depending on the settings in the
Main window).
Suppose, for example, that the Main window shows
Independent variable N
Initial N = 1.0000
Final N = 2.0000
Number of steps 10

and in the Equations window we define
Y' = N + Y

with initial value Y = 0 at N = 1. Then we will obtain
Y = 1 at N = 1.1
Y = 2.1 at N = 1.2
Y = 3.3 at N = 1.3, etc.