/** * Inference between two compound terms * * @param taskTerm The compound from the task * @param beliefTerm The compound from the belief * @param memory Reference to the memory */ private static void compoundAndCompound( CompoundTerm taskTerm, CompoundTerm beliefTerm, Memory memory) { if (taskTerm.getClass() == beliefTerm.getClass()) { if (taskTerm.size() > beliefTerm.size()) { compoundAndSelf(taskTerm, beliefTerm, true, memory); } else if (taskTerm.size() < beliefTerm.size()) { compoundAndSelf(beliefTerm, taskTerm, false, memory); } } }