Extending the core
From Omath
This tutorial assumes you have a working copy of Eclipse, and you've checked out the omath kernel project. If you haven't done that yet, you might like to read omath using Eclipse.
There are several steps to extending the core, and several different approaches, depending on how you plan to implement your extension.
- Identify the pattern(s) you want to define a rule for.
- Write a brief description of the behaviour you're about to implement, in the Core Manual.
- Create some test cases.
- Your test cases serve several purposes. Firstly, you'll be able to tell if your implementation works as intended. Secondly, they'll eventually become part of the formal specification of the omath core. Finally, if anyone makes major modifications to the kernel, or other parts of the core that you depend on, they'll be able to easily check they haven't broken everything else, simply by running all the accumulated test cases.
- Decide whether you'll be implementing your rule as an omath expression (easiest), in java code (somewhat more complicated), or in another language, such as python (at present nearly, but not quite, impossible!).
- Write the code!
