best_practices
Differences
This shows you the differences between two versions of the page.
| Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
| best_practices [2011/07/20 13:00] – [Sets and Functions] 131.246.161.187 | best_practices [2012/04/13 15:36] (current) – [Parentheses] paddy | ||
|---|---|---|---|
| Line 7: | Line 7: | ||
| * Conditions: '' | * Conditions: '' | ||
| - | * Case distinctions: | + | * Case distinctions: |
| * Constructors (in patterns): '' | * Constructors (in patterns): '' | ||
| In all of these cases it is generally inadvisable to leave out the outermost parentheses. | In all of these cases it is generally inadvisable to leave out the outermost parentheses. | ||
| - | You might also often have to overwrite how Isabelle puts parentheses | + | You might also run into problems by implicitly |
| + | |||
| + | As an example, consider | ||
| + | |||
| + | If in doubt, check [Isabelle → Settings → Display → Show Brackets] and find out what exactly happens. | ||
| ===== Modelling ===== | ===== Modelling ===== | ||
| ==== Sets and Functions ==== | ==== Sets and Functions ==== | ||
| - | Sets and (boolean) functions are equivalent. However, using both worlds in parallel, e.g. using sometimes $P x$ and sometimes $x \in P$ or even $\{x. P x\}$, you might run into issues during proofs as Isabelle has to perform certain steps in order to switch from one point of view to the other. Therefore you better choose wether to express your statements in predicate or in set notation and stick with it. | + | Sets and (boolean) functions are equivalent. However, using both worlds in parallel, e.g. using sometimes $P\; x$ and sometimes $x \in P$ or even $\{x. P\; x\}$, you might run into issues during proofs as Isabelle has to perform certain steps in order to switch from one point of view to the other. Therefore you better choose wether to express your statements in predicate or in set notation and stick with it. |
best_practices.1311159604.txt.gz · Last modified: by 131.246.161.187
