back up for master branch
Merge pull request #1 from emstoudenmire/master

Adding valid() and index(n) methods to NDIterator.
Merge github.com:naokin/BTAS-TWG into devel
Updated Tensor and TArray classes, cleaned up file structure
Renew NDIterator class to be more readable and user-friendly, I hope
Merge 'naoki/master'
Removed out-of-date code introduced in patch to old version of NDIterator.
Merge branch 'master' into branch 'slice'
Minor cleanup of external begin and end NDIterator friend functions.
Added friend declaration and changed template argument to allow conversion between NDIterators with convertible iterator types.
Removed has_container from is_tensor trait in order to enable TensorRef class to work (for example, for it to convert to Tensor).
Updated TensorRef to use new NDIterator implementation. Added a member end() function to NDIterator as a workaround.
Got slicing methods working with new NDIterator implementation except for methods taking TensorRef argument (composition of slicing).