powerinjection problem: make it work for 2D and 3D grids

and some minor variable renames in the base gradient calculator so
that a delta won't be mistaken for a derivative...
resetTerminal(): only use documented ANSI escape codes

the ones which where send to the TTY before this commit were taken
from the 'tset' utility and I could not find documentation for some of
them. Some of these caused trouble with 'screen' under some
circumstances, probably because they were invalid or unsupported..
set CMake policies CMP0026 and CMP0048 to OLD

this is required for CMake 3.0 to stop it complaining that we access
the LOCATION target property and set the *_VERSION_* variables ourselves.