Warning: this is an htmlized version!
The original is here, and
the conversion rules are here.
% (find-angg "LATEX/2016optativa-1.tex")
% (find-angg "LATEX/2016optativa-1.lua")
% (defun c () (interactive) (find-LATEXsh "lualatex -record 2016optativa-1.tex"))
% (defun d () (interactive) (find-xpdfpage "~/LATEX/2016optativa-1.pdf"))
% (defun e () (interactive) (find-LATEX "2016optativa-1.tex"))
% (defun l () (interactive) (find-LATEX "2016optativa-1.lua"))
% (defun u () (interactive) (find-latex-upload-links "2016optativa-1"))
% (defun z () (interactive) (find-zsh "flsfiles-tgz 2016optativa-1.fls 2016optativa-1.tgz")
% (find-xpdfpage "~/LATEX/2016optativa-1.pdf")
% (find-sh0 "cp -v  ~/LATEX/2016optativa-1.pdf /tmp/")
% (find-sh0 "cp -v  ~/LATEX/2016optativa-1.pdf /tmp/pen/")
%   file:///home/edrx/LATEX/2016optativa-1.pdf
%               file:///tmp/2016optativa-1.pdf
%           file:///tmp/pen/2016optativa-1.pdf
% http://angg.twu.net/LATEX/2016optativa-1.pdf
\documentclass[oneside]{book}
\usepackage[latin1]{inputenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{pict2e}
%\usepackage{tikz}
%
\usepackage{edrx15}               % (find-angg "LATEX/edrx15.sty")
\input edrxaccents.tex            % (find-angg "LATEX/edrxaccents.tex")
\input edrxchars.tex              % (find-angg "LATEX/edrxchars.tex")
\input edrxheadfoot.tex           % (find-dn4ex "edrxheadfoot.tex")
%
\begin{document}

\catcode`\^^J=10
\directlua{dednat6dir = "dednat6/"}
\directlua{dofile(dednat6dir.."dednat6.lua")}
\directlua{texfile(tex.jobname)}
\directlua{verbose()}
\directlua{loadluarepl()} % (find-angg "LUA/lua50init.lua" "loadluarepl")
\directlua{output(preamble1)}
\def\expr#1{\directlua{output(tostring(#1))}}
\def\eval#1{\directlua{#1}}
\def\pu{\directlua{pu()}}
\def\repl{\directlua{sync:run()}}

%\directlua{dofile "edrxtikz.lua"} % (find-LATEX "edrxtikz.lua")

%L V.__tostring = function (v) return format("(%.3f,%.3f)", v[1], v[2]) end

%\directlua{print "11111"}
%\repl
%\directlua{print "22222"}


%  _____           _        _             _           
% |_   _|_ _ _   _| |_ ___ | | ___   __ _(_) ___  ___ 
%   | |/ _` | | | | __/ _ \| |/ _ \ / _` | |/ _ \/ __|
%   | | (_| | |_| | || (_) | | (_) | (_| | |  __/\__ \
%   |_|\__,_|\__,_|\__\___/|_|\___/ \__, |_|\___||___/
%                                   |___/             

\def\und#1#2{\underbrace{#1}_{#2}}
\def\und#1#2{\underbrace{#1}_{\textstyle #2}}
\def\subf#1{\underbrace{#1}_{}}
\def\p{\phantom{(}}

We can calculate the result of $¬¬P→P$

when $P=0$ (left) and

when $P=1$ (right) with:

\msk

$\und {{\und {¬ {\und {¬ \und P 0} 1}} 0} → {\und P 0}} 1
 \qquad
 \und {{\und {¬ {\und {¬ \und P 1} 0}} 1} → {\und P 1}} 1
$

\bsk

The {\it subformulas} of $¬¬P→P$ are:

\msk

$\subf{\subf{¬ \subf{¬ \subf P}} → {\subf P}}$

\bsk

If we write the result of each subformula

under its central connective we get:

\msk

$\begin{array}{ccccc}
 ¬ & ¬ & P & → & P \\ \hline
   &   & 0 &    & 0 \\
   & 1 &   &    &   \\
 0 &   &   &    &   \\
   &   &   & 1  &   \\
 \end{array}
 \qquad
 \begin{array}{ccccc}
 ¬ & ¬ & P & → & P \\ \hline
   &   & 1 &    & 1 \\
   & 0 &   &    &   \\
 1 &   &   &    &   \\
   &   &   & 1  &   \\
 \end{array}
$

\msk

We can write all results in the same line...

We get something more compact but harder to read,

\msk

$\begin{array}{ccccc}
 ¬ & ¬ & P & → & P \\ \hline
 0 & 1 & 0 &  1 & 0 \\
 \end{array}
 \qquad
 \begin{array}{ccccc}
 ¬ & ¬ & P & → & P \\ \hline
 1 & 0 & 1 & 1  & 1 \\
 \end{array}
$


\bsk

We can put each case in a single line.

Here we also add a column at the left with the values of $P$.

\msk


$\begin{array}{ccccccc}
 P & & ¬ & ¬ & P & → & P \\ \hline
 % (¬\p & (¬\p & \p\p P)) & → & P \\ \hline
 0 & & 0 & 1 & 0 & 1  & 0 \\
 0 & & 1 & 0 & 1 & 1  & 1 \\
 \end{array}
$


\msk

\newpage

%   ____                               _                    _             
%  / ___|___  _ __ ___  _ __  _ __ ___| |__   ___ _ __  ___(_) ___  _ __  
% | |   / _ \| '_ ` _ \| '_ \| '__/ _ \ '_ \ / _ \ '_ \/ __| |/ _ \| '_ \ 
% | |__| (_) | | | | | | |_) | | |  __/ | | |  __/ | | \__ \ | (_) | | | |
%  \____\___/|_| |_| |_| .__/|_|  \___|_| |_|\___|_| |_|___/_|\___/|_| |_|
%                      |_|                                                

Let

$A = \{x:\{-1,...,4\}; x^2\}$ and

$B = \{x:\{-1,...,4\}; x^2≤5; x\}$.

Then $A$ and $B$ can be calculated by:

\msk

$\begin{array}{cc}
 x & x^2 \\ \hline
 -1 & 1 \\
  0 & 0 \\
  1 & 1 \\
  2 & 4 \\
  3 & 9 \\
  4 & 16 \\
 \end{array}
 \qquad
 \begin{array}{cccc}
 x & x^2 & x^2≤5 & x \\ \hline
 -1 &  1 & 1 & -1 \\
  0 &  0 & 1 & 0 \\
  1 &  1 & 1 & 1 \\
  2 &  4 & 1 & 2 \\
  3 &  9 & 0 & \\
  4 & 16 & 0 & \\
  \end{array}
$

\msk

We get:

$A = \{1,0,1,4,9,16\}$,

$B = \{-1,0,1,2\}$.


\bsk

Let

$A = \{x:\{1,...,5\}, y:\{1,...,x\}, x+y≤6; (x,y)\}$ and

$B = \{y:\{1,...,5\}, x:\{y,...,5\}, x+y≤6; (x,y)\}$.

Then $A$ and $B$ can be calculated by:

\msk

$\begin{array}{ccccc}
 x & y & x+y & x+y≤6 & (x,y) \\ \hline
 1 & 1 &  2  &   1   & (1,1) \\
 2 & 1 &  3  &   1   & (2,1) \\
   & 2 &  4  &   1   & (2,2) \\
 3 & 1 &  4  &   1   & (3,1) \\
   & 2 &  5  &   1   & (3,2) \\
   & 3 &  6  &   1   & (3,3) \\
 4 & 1 &  5  &   1   & (4,1) \\
   & 2 &  6  &   1   & (4,2) \\
   & 3 &  7  &   0   &       \\
   & 4 &  8  &   0   &       \\
 5 & 1 &  6  &   1   & (5,1) \\
   & 2 &  7  &   1   &       \\
   & 3 &  8  &   0   &       \\
   & 4 &  9  &   0   &       \\
   & 5 & 10  &   0   &       \\
 \end{array}
 \qquad
 \begin{array}{ccccc}
 y & x & x+y & x+y≤6 & (x,y) \\ \hline
 1 & 1 &  2  &   1   & (1,1) \\
   & 2 &  3  &   1   & (2,1) \\
   & 3 &  4  &   1   & (3,1) \\
   & 4 &  5  &   1   & (4,1) \\
   & 5 &  6  &   1   & (5,1) \\
 2 & 2 &  4  &   1   & (2,2) \\
   & 3 &  5  &   1   & (3,2) \\
   & 4 &  6  &   1   & (4,2) \\
   & 5 &  7  &   0   &       \\
 3 & 3 &  6  &   1   & (3,3) \\
   & 4 &  7  &   0   &       \\
   & 5 &  8  &   0   &       \\
 4 & 4 &  8  &   0   &       \\
   & 5 &  9  &   0   &       \\
 5 & 5 & 10  &   0   &       \\
 \end{array}
$

\msk

We get:

$A = \{ (1,1), (2,1), (2,2), (3,1), (3,2), (3,3), (4,1), (4,2), (5,1)\}$ and

$B = \{ (1,1), (2,1), (3,1), (4,1), (5,1), (2,2), (3,2), (4,2), (3,3)\}$.





\newpage





\end{document}



* (eepitch-shell)
* (eepitch-kill)
* (eepitch-shell)
lualatex 2016optativa-1


% Local Variables:
% coding: utf-8-unix
% End: