RISC JKU

Library download page

<< Return to the main page

Usage example (formatted by java2html):
try {
	Reader in1 = new StringReader("x=f(x,y), y=f(x,y)");
	Reader in2 = new StringReader("y=f(x,y), x=f(x,y)");
	NodeFactory nf = new NodeFactory();
	// EXPERIMENTAL COMMUTATIVE RULES:
	// nf.setCommutative("f");
	// AntiUnifySystem.ENABLE_COMMUTATIVE_RULES = true;
	AntiUnifySystem.ENABLE_SPLIT_RULE = true;
	TermGraph tg1 = new InputParser(nf).parseTermGraph(in1, AntiUnifySystem.ENABLE_COMMUTATIVE_RULES);
	TermGraph tg2 = new InputParser(nf).parseTermGraph(in2, AntiUnifySystem.ENABLE_COMMUTATIVE_RULES);
	RigidityFncSubsequence r = new RigidityFncSubsequence();
	// Optional: Set minimum alignment length:
	// r.setMinLen(3);
	AntiUnify rau = new AntiUnify(r, r, tg1, tg2, nf);
	rau.antiUnify(true, true, DebugLevel.RESULT, System.out);
} catch (Exception e) {
	e.printStackTrace();
}


Author: Alexander Baumgartner FWF Der Wissenschaftsfond
Project: SToUT - Symbolic Computation Techniques for Unranked Terms