refactor PTFOp and function classes to use new data structs.
Remove old data struct classes.