In PR 1609 (
https://github.com/sympy/sympy/pull/1616 ) I'm dealing with determinism in cse, trigsimp and risch. I've reorganized the logic and compatibilty modules a bit, getting similar functions in one place. That PR also has commits fixing some failures related to power rules. PR 1616 has it all; PR 1607 (
https://github.com/sympy/sympy/pull/1607 ) just has the part dealing mostly with cse. If I could get some review help there that would be appreciated.
One more thing: there is also an ordered set (oset) added to compatibility which remembers the order that things are added to it while mainting only one copy of anything. It can pop from either end (o.pop() from the tail or o.pop(0) from the head). I opted for the oset name rather than OrderedSet since the latter looks like a SymPy object and oset is more like a set -- SymPy agnostic.
P.S. I learned a new way to document a calculation via wolfram alpha : copy the url that generated the page and feed it to
tinyurl.com to get a short link which you can easily share with someone or write it as a reference in a commit message. I used it to verify that two expressions were equivalent as i made the change from one to another.