fixed some bugs in Agent.solve, working for very limited tests
updated notes