Initial implementation of nditer.
Added unit tests.