Added wrapAround parameter to SP 

Added wrapAround parameter to SP so the behavior of _mapPotential can be chosen by user.

Also made a relatively small change in the way _mapPotential maps inputs to columns when potentialRadius is smaller than the largest input dimension.  See images below. 

Fixes #1211
Fixes #1216

@chetan51 please review
The formula change is only 3 lines of code so it would not be that hard to split them.