Math 156

Induction Review

  • Cases & Operators

  • Co-Operators

  • Spotting Applications

Week 1 : Cases & Their Algebra

Cases & Operators

 

Week 1 : Cases & Their Algebra

trait File
case TextFile(txt:String)() extends File
case Join(first:File, second:File) extends File
case Folder(files:List[Files,n]) extends File
\begin{aligned} \text{TextFile}(txt) & : \mathbb{F}^0\to \mathbb{F}\\ \text{Link} & : \mathbb{F}^2\to \mathbb{F}\\ \text{Folder} & : \bigsqcup_{n=0}^{\infty}\mathbb{F}^n\to \mathbb{F}\\ \end{aligned}
  1. introduction rules are operators
  2. if an introduction depends on other data of the same type, e.g. File, then it is "inductive case", otherwise "base case".
  3. Unified algebra:
allOps:\mathbb{F}^0\sqcup \mathbb{F}^2\sqcup\bigsqcup_{n=0}^{\infty} \mathbb{F}^n\to \mathbb{F}

Co-Operators

 

Week 1 : Cases & Their Algebra

x match 
case TextFile(txt:String)() -> // use txt (a base case)
case Join(first:File, second:File) -> // use first, second, recursively
case Folder(files:List[Files,n]) -> // use files, recursively
allOps:\mathbb{F}^0\sqcup \mathbb{F}^2\sqcup\bigsqcup_{n=0}^{\infty} \mathbb{F}^n\to \mathbb{F}
match:\mathbb{F}\to \mathbb{F}^0\sqcup \mathbb{F}^2\sqcup\bigsqcup_{n=0}^{\infty} \mathbb{F}^n

Operators

 

trait File
case TextFile(txt:String)() extends File
case Join(first:File, second:File) extends File
case Folder(files:List[Files,n]) extends File

Week 1 : Cases & Their Algebra

Inductive types have

  1. Possibly multiple introduction/ constructors given as "cases"
    1. Base case does not depend on others of the type
    2. Inductive types do depend on others of that type
  2. Single elimination called "Induction Hypothesis"
  3. Computation rule called "Recursion"

 

used to express data that can be taken apart

Co-Inductive types have possibly multiple introduction/constructors given as "cases"

  1. One introduction / constructor often called `match` or `explode` or `parse`
  2. Multiple elimination rules
  3. Computation rule is called "Co-recursion"

 

Used to express data that can be built up, it can be infinite. 

  • Prop is what qualifies as propositions

    • Theoretical just True/False

    • Computational (true by evidence)

    • Practical ( true, false, possibly others (missing, inconsistent, etc))

  • Relation is a function from data to Prop. \(R(\cdots):A_1\times \cdots \times A_n\to Prop\)

Week 2 : Relations

Useful qualities

  • Binary relations \(R:A\times A\to Prop\) Often a symbol \(=, \cong,\leq, \sim\) and infix \(x\leq y\) instead of \(R(x,x)\).
  • If binary then look for
    • Transitive: \(\begin{array}{c} R(x,y)\\ R(y,z)\\ \hline R(x,z)\end{array}\)
      • \(x=y\) and \(y=z\) then \(x=z\)
    • Reflexive: \(R(x,x)\) is valid \(\vdash R(x,x)\)
    • Symmetric: \(\frac{R(x,y)}{R(y,x)}\), e.g. \(x\cong y\rightarrow y\cong x\)
    • Anti-symmetric \(\begin{array}{c} R(x,y)\\ R(y,x) \\ \hline x=y\end{array}\)
    • Equivalence : reflexive transitive symmetric
    • Order : Transitive; Partial order: transive, reflexive, anti-symmetric.

Week 2 : Relations

  • Plot subset in graph \(A\times A\)
  • Plot as graph of nodes and arcs.
    • Be able to make transitive closure,
    • reflexive closure
  • Plot Hierarchy/ Hasse diagram.

Week 2 : Relations

  • Monotonic logic: \(A\vdash B\) leads to \(A,X\vdash B\) for any \(X\)
  • Non-monotonic: does NOT.  
    • Allows defeat of claims \(A\vdash B\) can be true, but with new evidence X \(A,X\not\vdash B\) "Defeasible Logic"
  • Default Logic Priority
    • A partial order (week 2)
  • Adaptive Logic: a Lower logic that can simulate an upper logic as a virtual machine but when a rule fails in the upper logic the lower logic takes over.

Week 3 : Defaults

Default

  • Has clear source of priorities
  • Have time to sort out the options
  • Not too complicated to use

Week 3 : Defaults

Adapt

  • Unclear causes
  • Clear restart options
  • Clear separation of ideal vs. actual rules
  • Abductive
  • Proportion
  • Distribution 
    • Gaussian
    • Uniform
  • Independent
  • Probabilistic algorithm (Monte Carlo)
  • Probabilistic Data type (Bloom)

Week 4 : Probability

Next...

Two aspects of logic:

  • Semantics (meaning, value, truth)

  • Entailment, validity

Model theory ()

  • Syntax (grammatical structure, form)

  • Provability, rules of inference

Proof theory ()

Induction-Revie

By James Wilson

Induction-Revie

  • 62