Term rewriting system Prototype