implemented matcher and solver for linrat, with some tests (needs improvement). working on substitutor