Implement new C++ data structure to power algorithms

WIP

Starts #216.
Obsoletes https://github.com/numenta/nupic.core/pull/217.
You really need to use the proper macros here. Otherwise test successes and failures are not handled correctly.