A 647 & 648
Yes, trip and grapple attempts can both be made in place of a melee attack, including Attacks of Opportunity.
A 649
No, because feeblemind isn't a form of ongoing control.
A 650?
I can't find anything in the rules that says immediate actions can backtrack events that have already happened, so I'd say that you'd have to do it when an enemy attacks you but before you find out if it hits if you want to avoid the risk of taking damage. Being under a displacement effect wouldn't change this, because you'd effectively have to choose whether to activate your getaway or trust in the displacement to protect you (similar to how you have to choose whether to activate Shadow Cloak's teleportation or concealment effects).