"INVAR (" <+ encodeGoalState (indexList boxes) targetPos <+
") <-> movement = finished;",
"INVAR " <+ encodeAgentNotOnBox (indexList boxes) <+ ";",
+ "INVAR " <+ encodeBoxesNotOnBox (indexList boxes),
"TRANS next(agent.x) = agent.x + dx;",
"TRANS next(agent.y) = agent.y + dy;",
encodeBlockMovement (indexList boxes),
"\t\tTRUE: b" <+ i <+ ".y + dy;\n" <+
"\tesac;"
+//TODO
+encodeBoxesNotOnBox :: [Int] -> String
+encodeBoxesNotOnBox _ = "TRUE;"
+
encodeAgentNotOnBox :: [Int] -> String
encodeAgentNotOnBox bs = join " &\n\t" [
"(b" <+ i <+ ".x != agent.x & b" <+ i <+ ".y != agent.y)"\\i<-bs]