Some cleanup in state.py.
Fix merge errors -- finish renaming local vectors.
Merge pull request #474 from ketch/fix-docstrings

Some cleanup in state.py.