Move examples to another folder
This commit is contained in:
parent
45e413eb0b
commit
6c8a80212f
|
@ -1,14 +0,0 @@
|
|||
|
||||
\begin{truthtable}
|
||||
{c|c|c|c|c|e|c}
|
||||
{$p$ & $q$ & $s$ & $p \wedge q$ & $p \Rightarrow q$ & $ p \Leftrightarrow q$ & $p \Leftrightarrow (q \wedge s)$}
|
||||
\T & \T & \T & \T & \T & \T & \T
|
||||
\T & \T & \F & \T & \T & \T & \F
|
||||
\T & \F & \T & \F & \F & \F & \F
|
||||
\T & \F & \F & \F & \F & \F & \F
|
||||
\F & \T & \T & \F & \T & \F & \F
|
||||
\F & \T & \F & \F & \T & \F & \T
|
||||
\F & \F & \T & \F & \T & \T & \T
|
||||
\F & \F & \F & \F & \T & \T & \T
|
||||
\end{truthtable}
|
||||
|
|
@ -0,0 +1,11 @@
|
|||
\newcommand{\arrow}[2]{\path [-{Latex[scale=1]}] (#1) edge (#2);}
|
||||
|
||||
\begin{tikzpicture}
|
||||
|
||||
\begin{scope}[every node/.style={shape=circle, fill=white, draw, inner sep=2pt}]
|
||||
%NODES
|
||||
\end{scope}
|
||||
|
||||
%EDGES
|
||||
|
||||
\end{tikzpicture}
|
|
@ -0,0 +1,15 @@
|
|||
.DEFAULT_GOAL := default
|
||||
.PHONY: default python
|
||||
|
||||
default: python
|
||||
pdflatex main.tex
|
||||
|
||||
SRC_DIR := $(shell find graphics/src -type f -printf "%f\n" -name *.txt | cut -d '.' -f1)
|
||||
|
||||
python:
|
||||
@for f in $(SRC_DIR); \
|
||||
do \
|
||||
echo -e "\033[33mCOMPILING $$f.tex\033[0m"; \
|
||||
python ../exam_template/python/run.py graphics/src/$$f.txt graphics/$$f.tex; \
|
||||
echo ""; \
|
||||
done
|
|
@ -0,0 +1,30 @@
|
|||
\newcommand{\arrow}[2]{\path [-{Latex[scale=1]}] (#1) edge (#2);}
|
||||
|
||||
\begin{tikzpicture}
|
||||
|
||||
\begin{scope}[every node/.style={shape=circle, fill=white, draw, inner sep=2pt}]
|
||||
\node (A) at (0,3.0) {$A$};
|
||||
\node (B) at (-2.59808,1.5) {$B$};
|
||||
\node (C) at (-2.59808,-1.5) {$C$};
|
||||
\node (D) at (-0.0,-3.0) {$D$};
|
||||
\node (E) at (2.59808,-1.5) {$E$};
|
||||
\node (F) at (2.59808,1.5) {$F$};
|
||||
\end{scope}
|
||||
|
||||
\draw (A) -- (B);
|
||||
\draw (A) -- (C);
|
||||
\draw (A) -- (D);
|
||||
\draw (A) -- (E);
|
||||
\draw (A) -- (F);
|
||||
\draw (B) -- (C);
|
||||
\draw (B) -- (D);
|
||||
\draw (B) -- (E);
|
||||
\draw (B) -- (F);
|
||||
\draw (C) -- (D);
|
||||
\draw (C) -- (E);
|
||||
\draw (C) -- (F);
|
||||
\draw (D) -- (E);
|
||||
\draw (D) -- (F);
|
||||
\draw (E) -- (F);
|
||||
|
||||
\end{tikzpicture}
|
|
@ -2,14 +2,14 @@
|
|||
\tikzset{every node/.style={shape=circle,draw,inner sep=2pt}}
|
||||
|
||||
\node (a) at (-0.5, 0) {$a$};
|
||||
\node (e) at (-1.0, 1) {$e$};
|
||||
\node (b) at (0.0, 1) {$b$};
|
||||
\node (d) at (-1.0, 2) {$d$};
|
||||
\node (c) at (0.0, 2) {$c$};
|
||||
\node (b) at (-1.0, 1) {$b$};
|
||||
\node (e) at (0.0, 1) {$e$};
|
||||
\node (c) at (-1.0, 2) {$c$};
|
||||
\node (d) at (0.0, 2) {$d$};
|
||||
|
||||
\draw (e) -- (d);
|
||||
\draw (a) -- (e);
|
||||
\draw (b) -- (c);
|
||||
\draw (e) -- (d);
|
||||
\draw (a) -- (b);
|
||||
\draw (e) -- (c);
|
||||
|
|
@ -1,3 +1,4 @@
|
|||
# FSA
|
||||
0 s
|
||||
1 r0
|
||||
2 fr1
|
|
@ -0,0 +1,4 @@
|
|||
# Graph
|
||||
complete
|
||||
|
||||
6
|
|
@ -1 +1,2 @@
|
|||
# Hasse
|
||||
ab ac ad ae bc ed ec
|
|
@ -1 +1,2 @@
|
|||
# Truthtable
|
||||
p, q, s, p and q, p implies q, E p iff q, p iff (q and s)
|
|
@ -0,0 +1,9 @@
|
|||
# Graph
|
||||
undirected
|
||||
|
||||
A B C D E F G H
|
||||
|
||||
AB
|
||||
AC
|
||||
CD
|
||||
DE
|
|
@ -0,0 +1,14 @@
|
|||
|
||||
\begin{truthtable}
|
||||
{c|c|c|c|c|e|c}
|
||||
{$p$ & $q$ & $s$ & $p \wedge q$ & $p \Rightarrow q$ & $ p \Leftrightarrow q$ & $p \Leftrightarrow (q \wedge s)$}
|
||||
\T & \T & \T & \T & \T & \T & \T \\
|
||||
\T & \T & \F & \T & \T & \T & \F \\
|
||||
\T & \F & \T & \F & \F & \F & \F \\
|
||||
\T & \F & \F & \F & \F & \F & \F \\
|
||||
\F & \T & \T & \F & \T & \F & \F \\
|
||||
\F & \T & \F & \F & \T & \F & \T \\
|
||||
\F & \F & \T & \F & \T & \T & \T \\
|
||||
\F & \F & \F & \F & \T & \T & \T \\
|
||||
\end{truthtable}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
\newcommand{\arrow}[2]{\path [-{Latex[scale=1]}] (#1) edge (#2);}
|
||||
|
||||
\begin{tikzpicture}
|
||||
|
||||
\begin{scope}[every node/.style={shape=circle, fill=white, draw, inner sep=2pt}]
|
||||
\node (A) at (0,4.0) {$A$};
|
||||
\node (B) at (-2.82843,2.82843) {$B$};
|
||||
\node (C) at (-4.0,0.0) {$C$};
|
||||
\node (D) at (-2.82843,-2.82843) {$D$};
|
||||
\node (E) at (-0.0,-4.0) {$E$};
|
||||
\node (F) at (2.82843,-2.82843) {$F$};
|
||||
\node (G) at (4.0,-0.0) {$G$};
|
||||
\node (H) at (2.82843,2.82843) {$H$};
|
||||
\end{scope}
|
||||
|
||||
\draw (A) -- (B);
|
||||
\draw (A) -- (C);
|
||||
\draw (C) -- (D);
|
||||
\draw (D) -- (E);
|
||||
|
||||
\end{tikzpicture}
|
|
@ -0,0 +1,43 @@
|
|||
\documentclass[12pt]{article}
|
||||
\usepackage{ntnu}
|
||||
\usepackage{ntnu-math}
|
||||
|
||||
\author{TODO: STUDENTNUMMER}
|
||||
\title{Exam v2021}
|
||||
|
||||
\usetikzlibrary{automata, positioning, arrows.meta}
|
||||
|
||||
\newcommand{\I}{Option 1 is correct}
|
||||
\newcommand{\II}{Option 2 is correct}
|
||||
\newcommand{\III}{Option 3 is correct}
|
||||
|
||||
\renewcommand{\theenumi}{\arabic{enumi}}
|
||||
\renewcommand{\theenumii}{(\arabic{enumii})}
|
||||
\renewcommand{\theenumiii}{\alph{enumiii})}
|
||||
|
||||
\begin{document}
|
||||
|
||||
\ntnuTitle{}
|
||||
\break{}
|
||||
|
||||
\tableofcontents
|
||||
|
||||
\begin{excs}
|
||||
\exc{}
|
||||
\includeDiagram{graphics/hasse.tex}
|
||||
|
||||
\exc{}
|
||||
\includeDiagram{graphics/automata.tex}
|
||||
|
||||
\exc{}
|
||||
\input{graphics/truthtable.tex}
|
||||
|
||||
\exc{}
|
||||
\includeDiagram{graphics/undirectedGraph.tex}
|
||||
|
||||
\exc{}
|
||||
\includeDiagram{graphics/complete6.tex}
|
||||
|
||||
\end{excs}
|
||||
|
||||
\end{document}
|
Loading…
Reference in New Issue