Structs

More standard data structures and algorithms

closes #512