Extend interpolation to last column.

Previously, the interpolation skips last column, for example,

a = [1, 1]
x = [0, 0.5, 1, 1.5]
map_coordinate(a, (x, ), mode='constant')

gives 1 1 1 0.

After this fix, it gives 1 1 1 1. (see test case), which in my opion
makes more sense; this will also potentially allow us to get rid
of a few shape hacks in zoom and shift.

This also fix 'wrap', making its output N periodic,
compatible with numpy's definition of 'wrap'. Previously it was
broken (N - 1) periodic, with the first element handled inconsistently.

The boundary handling is enforced after the
spline interpolation is applied, even though in the code
appears before calling the splev.

Note that the spline filter assumes a 'reflect' boundary.
see, the definition of boundary in
http://citeseerx.ist.psu.edu/viewdoc/download?doi=10.1.1.68.6734&rep=rep1&type=pdf
(last two pages)

The only boundary that is consistent with the spline is 'reflect'.

All other boundaries shall be used with caution.
Merge branch 'newmaster' of github.com:rainwoodman/scipy into newmaster
allow cKDTree.query taking a list input in k.

the list input k will return only the neighbours ranks as
given in the list.