Completed hw7 from uva haskell lectures. Yikes! Vector math is ugly in
haskell