
gapt.proofs.lk.rules.BinaryLKProof.scala Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of gapt_3 Show documentation
Show all versions of gapt_3 Show documentation
General Architecture for Proof Theory
The newest version!
package gapt.proofs.lk.rules
import gapt.proofs.HOLSequent
import gapt.proofs.SequentConnector
import gapt.proofs.lk.LKProof
/**
* An LKProof deriving a sequent from two other sequents:
*
* (π1) (π2)
* Γ :- Δ Γ' :- Δ'
* ------------------
* Π :- Λ
*
*/
abstract class BinaryLKProof extends LKProof {
/**
* The immediate left subproof of the rule.
*
* @return
*/
def leftSubProof: LKProof
/**
* The immediate right subproof of the rule.
*
* @return
*/
def rightSubProof: LKProof
/**
* The object connecting the lower and left upper sequents.
*
* @return
*/
def getLeftSequentConnector: SequentConnector = occConnectors.head
/**
* The object connecting the lower and right upper sequents.
*
* @return
*/
def getRightSequentConnector: SequentConnector = occConnectors.tail.head
/**
* The left upper sequent of the rule.
*
* @return
*/
def leftPremise: HOLSequent = leftSubProof.endSequent
/**
* The right upper sequent of the rule.
*
* @return
*/
def rightPremise: HOLSequent = rightSubProof.endSequent
override def immediateSubProofs: Seq[LKProof] = Seq(leftSubProof, rightSubProof)
}
object BinaryLKProof {
def unapply(p: BinaryLKProof): Some[(HOLSequent, LKProof, LKProof)] =
Some(p.endSequent, p.leftSubProof, p.rightSubProof)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy