look-ahead: move jerk definitions into config.h templates.
dda: reduce code duplication and simplify.

There are three locations in the code that repeat a pattern of
"If z=0 then use 2d-approx(dx,dy), else if x==0 && y==0 then use dz,
else use 3d-approx".

Teach approx_distance_3 to detect these conditions for us and apply
the same logic.  Replace the three call locations with a simple call
to approx_distance_3.

Binary size for the LOOKAHEAD case drops by almost 400 bytes:

  old:  FLASH : 21242 bytes          149%       70%        34%       17%
  new:  FLASH : 20844 bytes          146%       68%        33%       17%

The size for non-LOOKAHEAD drops by 40 bytes:

  old:  FLASH : 16592 bytes          116%       55%        27%       13%
  new:  FLASH : 16552 bytes          116%       54%        27%       13%

We can actually do a little better if we consider the zero-ness of all
three axes, but this does make the code a little bit bigger. Another
change will consider that option. This change simply tries to mimic
the existing functionality.
dda: generalize the zero-distance case.

When approximating distances, if any axis delta is zero we can
choose to consider only the remaining one(s).

This does increase the code size a few bytes, but is arguably more
accurate in specific "lateral move" cases.
Add gnuplot script to explore approximate_distance.

Error is less than 5% for explored range [0,200000].
dda: move dda_find_crossing_speed() to dda.c.

This is a preparation towards going through the existing movement
queue backwards with dda_join_moves() to allow higher feedrates
for lots of short movements.
dda: use the already calculated distance for crossing speed calculation.