Kirk Rader  1.0-SNAPSHOT
TT

Generate Markfown output for a formula of the monadic predicate calculus.

Overview

The us.rader.tt.app package defines a console application that invokes functionality provided by the class library described by the Parsing Symbolic Logic Formulas page.

Usage

java -jar TT-1.0-SNAPSHOT.jar -e '(P -> Q)'
java -jar TT-1.0-SNAPSHOT.jar -f formula.txt

Output

# (P->Q)

## Graphviz

```viz
digraph {
   node3 [ label="->" ]
   node1 [ label="P" ]
   node2 [ label="Q" ]
   node3 -> { node1 node2 }
}

```

## LaTex

### Preamble

The LaTeX generated by this program assumes the following preamble:

    \usepackage{amsmath}
    \usepackage{amssymb}
    \usepackage{graphicx}
    \usepackage{natded}
    \newcommand{\lognot}{\mathord{\sim}}
    \newcommand{\uq}{\mathord{\bigwedge}}
    \newcommand{\eq}{\mathord{\bigvee}}
    \newcommand{\riota}{\mathrm{\rotatebox[origin=c]{180}{$\iota$}}}

### Formula

```math
\left( P \rightarrow Q \right)
```

## Truth Table

```math
\begin{array}{cc|c}
P & Q & \left( P \rightarrow Q \right) \\
\hline \\
T & T & T \\
T & F & F \\
F & T & T \\
F & F & T
\end{array}
```