steadily refactoring
more work on refactoring
Update readme