Implement Primal and Dual datastructures for numpy