The following example may be useful. Imagine we have a chess computer, a cheap one that
always uses the same strategy. Now if playing against it we win a game, then we always can win 
by repeating our successful strategy. It is clear that this machine is deterministic and does
not have a free will. Now imagine that we have a more expensive chess computer, one that 
learns from its mistakes. After winning from it in a game, we cannot win again with our
previous strategy. The machine will remember that it is not good to repeat its moves.
We can state that this second machine has a rudimentary form of a 
free will: it reacts differently
under similar circumstances. But since the machine is programmed its behavior is deterministic.
So determinism and free will are compatible.

Still one may object. 
In some views on a human free will---e.g.\ the one propagated in
Christianity---there is an (eternal) soul that independently makes decisions.
In this sense the second chess computer does not have a free will, since its behavior is exactly
determined by the position on the board and by its past experience. But a really independent soul
that makes decisions that are not based on anything is in fact being haphazard, is a random
generator. This is not what is meant by free will---even in Christianity. According to this religion
one should base one's actions on the dictates of one's conscience (taking into account the
circumstances).  Doing this, however, our behavior is comparable with that of a chess computer of the
second kind, albeit that we are much more refined.


