Working version!
Cleanup.
Hard constraint and some cleanup.
More sanity checks.