Theory#
- class Theory(*args, load_prelude=True, **kwargs)[source]#
- Bases: - Object- The state of the logic developments so far. - A - Theoryconsists of a sequence of extensions (- Extension).- Multiple - Theoryobjects can coexist, but at any time only one of them is the current or top theory. By default, commands and other top-level functions operate over the top theory.- The top theory can be accessed using - Theory.topor- _thy(). It can be changed using- Theory.push()and restored using- Theory.pop().- Parameters:
- args – Extensions. 
- load_prelude – Whether to load the standard prelude. 
- kwargs – Annotations. 
 
- Returns:
 
Theory stack#
| The top theory. | |
| 
 | Pushes theory onto theory stack. | 
| Pops theory from theory stack. | 
Adding extensions#
| 
 | Adds extension. | 
| 
 | Adds new base type. | 
| 
 | Adds new type constructor. | 
| 
 | Adds new constant. | 
| 
 | Adds new axiom. | 
| 
 | Adds new definition. | 
| 
 | Adds new theorem. | 
| 
 | Adds new Python type alias. | 
Removing extensions#
| 
 | Removes all extensions since arg (inclusive). | 
Querying extensions#
| 
 | Enumerates extensions matching criteria. | 
| 
 | Searches for extension. | 
| 
 | Searches for type constructor. | 
| 
 | Searches for constant. | 
| 
 | Searches for axiom. | 
| 
 | Searches for definition. | 
| 
 | Searches for theorem. | 
| 
 | Searches for Python type alias. | 
Showing extensions#
| 
 | Prints extensions matching criteria. | 
Modules#
| 
 | Loads module into theory. | 
Prelude#
| Prelude module or  | |
| Gets prelude module. | |
| Start index of non-prelude extensions. | |
| Gets start index of non-prelude extensions. | |
| Theory arguments excluding prelude extensions. | |
| Gets theory arguments excluding prelude extensions. | 
Settings#
| Theory settings table. | |
| Gets theory settings table. | 
The theory settings table is an instance of TheorySettings.
| 
 | alias of  | 
| 
 | alias of  | 
| 
 | alias of  | 
| 
 | alias of  | 
| Prefix of generated ids. | |
| Whether to record proofs. | |
| Whether to override  | |
| Whether to enable debugging. |