add missing equals and hashcode functions
add comment, update tostring
add gamma test
remove uneeded code