Spring 2021 | Exercises and python framework for discrete mathematics course
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 
h7x4 b06a6e58f9 Add exam 1 year ago
.gitlab/graphics/chrome-extension Add images 1 year ago
exam Add exam 1 year ago
exam_template Remove hasse (moved to relations) 1 year ago
exam_template_graphics Add kruskals algorithm 1 year ago
exercise1 Init commit 2 years ago
exercise2 Init commit 2 years ago
exercise3 Remove temporary file 2 years ago
exercise4 Init commit 2 years ago
exercise5 Init commit 2 years ago
exercise6 Init commit 2 years ago
exercise7 Init commit 2 years ago
exercise8 Add exercise 8 2 years ago
exercise9 Add the rest of the exercises 1 year ago
exercise10 Add the rest of the exercises 1 year ago
exercise11 Add the rest of the exercises 1 year ago
exercise12 Add the rest of the exercises 1 year ago
tools Update AND detection for chrome extension 1 year ago
.gitignore Add exam template 1 year ago
.gitlab-ci.yml Add gitlab ci for compiling documents 2 years ago
README.md Add kruskals algorithm 1 year ago
generate_pdfs.sh Change generate_pdfs to bash 1 year ago

README.md

MA0301 - Spring 2021 - Diskret Matematikk

Using styling files from oysteikt/texmf

Exercises

Num Exercise PDF Answer PDF Solutions PDF
1 wiki.math.ntnu.no ex1.pdf wiki.math.ntnu.no
2 wiki.math.ntnu.no ex2.pdf wiki.math.ntnu.no
3 wiki.math.ntnu.no ex3.pdf wiki.math.ntnu.no
4 wiki.math.ntnu.no ex4.pdf wiki.math.ntnu.no
5 wiki.math.ntnu.no ex5.pdf wiki.math.ntnu.no
6 wiki.math.ntnu.no ex6.pdf wiki.math.ntnu.no
7 wiki.math.ntnu.no ex7.pdf wiki.math.ntnu.no
8 wiki.math.ntnu.no ex8.pdf wiki.math.ntnu.no
9 wiki.math.ntnu.no ex9.pdf wiki.math.ntnu.no
10 wiki.math.ntnu.no ex10.pdf wiki.math.ntnu.no
11 wiki.math.ntnu.no ex11.pdf wiki.math.ntnu.no
12 wiki.math.ntnu.no ex12.pdf wiki.math.ntnu.no

Automation


VSCode snippets

See snippets for LaTeX

See snippets for Makefile


Chrome plugin

Chapter 1. 2. 3. Boolean calculator

Boolean Calculator

Automates calculating boolean expression step by step by running the input through https://boolean-algebra.com/

Outputs the resulting set of expressions to either propositional logic, boolean algebra or set operations.

Converts output to LaTeX

  • Finished

NOTE: there are some bugs when converting boolean algebra AND operations to PL/S

Chapter 4. Induction

Automates proof by induction by running the input through https://wolframalpha.com/

Converts output to LaTeX

  • Finished

Chapter 6. Combinatorics

Permutation/Combination Calculator

Permutations / Combinations Calculator

Computes permutations and combinations

Outputs to LaTeX

  • Finished

Python framework

See examples of what the engine for the exam template can do here: exam_template_graphics.pdf

Chapter 1. Truthtables (propositional logic)

Capabilities:

  • Calculate and render truthtable for propositional logic expressions

Chapter 3. Sets

Capabilities:

  • Calculate and output powersets

Chapter 5. Relations

Capabilities:

Proofs:

  • Check whether relation is reflexive
  • Check whether relation is symmetric
  • Check whether relation is antisymmetric
  • Check whether relation is transitive
  • Check whether relation is an equivalence relation
  • Check whether relation is a partial order

Graphs:

  • Draw a hasse diagram from a partial order
  • Draw an graph from any relation

Note: Checking whether a relation has a property in this context means that it goes over every pair of related elements and looks for contradictions. This program can not prove relation properties algebraically

Chapter 6. Combinatorics

Capabilities:

  • Make an inclusion exclusion expression from list of conditions

Chapter 7. Graph theory

Capabilities:

Inputs:

  • Input a graph from a matrix
  • Input a graph from a node/edge list
  • Input a complete graph from a node number

Outputs:

  • Output a graph to a matrix
  • Draw an undirected graph
  • Draw a directed graph
  • Find a minimal spanning tree with Kruskals algorithm

Chapter 8. Finite state automata

Capabilities:

  • Draw a finite state machine
  • Output a finite state machine table
  • Calculate input based on a finite state machine

Python

Capabilities:

  • Include a raw python program, and capture its output into a listing