DoubleNegationEliminationDeclaration (python class)
See also
This section presents the DoubleNegationEliminationDeclaration python class.
This class models the declaration of the double-negation-elimination inference-rule in the target universe-of-discourse.
Punctilious users do not need to instanciate objects from this class. In effect, the UniverseOfDiscourse class exposes the double_negation_elimination property, and instanciation is automatic when the property is accessed for the first time.
- class punctilious.DoubleNegationEliminationDeclaration(u, echo=None)
The well-known double negation elimination #1 inference rule: ¬(¬(P)) ⊢ P.
Acronym: cer.
- Parameters
p_land_q – A formula-statement of the form: (P ⋀ Q).
t – The current theory-derivation.
- Returns
The (proven) formula: Q.
- class Premises(not_not_p)
- not_not_p: Union[punctilious.core.Formula, punctilious.core.FormulaStatement, punctilious.core.CompoundFormula, tuple, list]
Alias for field number 0
- construct_formula(not_not_p)
This python method verify the syntactic correctness of the premises, but does not verify the validity of the premises, it then applies the inference-rule algorithm, and returns a formula.
Note
Note the critical distinction between the
construct_formulaand theinfer_formula_statementmethods. The former only verifies the syntactic correctness but does not verify the validity of the premises, it then applies the inference-rule algorithm, and produces a formula that may be invalid . The later verifies the validity of the premises, applies the inference-rule algorithm, and produces a formula-statement that is valid by definition.Taking the modus-ponens inference-rule as an example, the
construct_formulamethod requires two premise arguments:p_implies_qandp. One may pass a formula as thep_implies_qargument that is not valid in the theory-derivation under consideration, but that is syntactically correct. On the other hand, theinfer_formula_statementmethod requires that both premise arguments be valid.This distinction makes it possible to use the algorithms of inference-rules in “what if” scenarii, i.e. building invalid formulae. And at the same time, it assures that all formula_statements are valid.
- Return type
CompoundFormula