Add missing tests.
Improve docs.
Fix spelling.
Remove pointless square root.
Add missing test.