Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/takagiy/satysfi-karnaugh
Drawing Karnaugh maps in SATySFi / SATySFiでカルノー図を描くためのパッケージ
https://github.com/takagiy/satysfi-karnaugh
Last synced: 2 months ago
JSON representation
Drawing Karnaugh maps in SATySFi / SATySFiでカルノー図を描くためのパッケージ
- Host: GitHub
- URL: https://github.com/takagiy/satysfi-karnaugh
- Owner: takagiy
- License: mit
- Created: 2019-08-09T13:26:34.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-01-18T13:51:29.000Z (almost 5 years ago)
- Last Synced: 2024-08-03T17:13:55.542Z (6 months ago)
- Language: Makefile
- Homepage:
- Size: 70.3 KB
- Stars: 7
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
- awesome-satysfi - satysfi-karnaugh - Drawing Karnaugh maps in SATySFi / SATySFi でカルノー図を描くためのパッケージ (Uncategorized / Uncategorized)
README
# satysfi-karnaugh - Drawing Karnaugh maps in SATySFi
## example```satysfi
let-math \dc = ${\dontcare} in
{
\karnaugh-map(${xy})(${zw}) [
${| 1 | 0 | 0 | 1 |};
${| 1 | 1 | 0 | 1 |};
${| \dc | \dc | \dc | \dc |};
${| 1 | 0 | \dc | \dc |};
] [
Karnaugh.box (0, 1);
Karnaugh.tall (3, 0);
];
}{
\karnaugh-map(${AB})(${C}) [
${| 1 | 1 | 0 | 1 |};
${| 1 | 0 | 0 | 0 |};
] [
Karnaugh.slim (0, 0);
Karnaugh.flat (0, 0);
Karnaugh.flat (3, 0);
];
}
```The adbove will look like the following.
![output](/docs/example.png)
## reference
* `\dontcare` : `[] math-cmd`* “∅” in formula
* `\karnaugh-map` : `[math; math; (math list) list; (length list -> length list -> graphics list) list] inline-cmd`
`\karnaugh-map` : ` `
* Draw a Karnaugh map* `Karnaugh.box` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.box` : `(, ) -> `
* Group 2x2 cells* `Karnaugh.tall` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.tall` : `(, ) -> `
* Group 2x4 cells* `Karnaugh.wide` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.wide` : `(, ) -> `
* Group 4x2 cells* `Karnaugh.slim` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.slim` : `(, ) -> `
* Group 1x2 cells* `Karnaugh.flat` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.flat` : `(, ) -> `
* Group 2x1 cells* `Karnaugh.minimum` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.minimum` : `(, ) -> `
* Group 1x1 cells* `Karnaugh.large` : `int * int -> lenght list -> length list -> graphics list`
`Karnaugh.large` : `(, ) -> `
* Group 4x4 cells* `Karnaugh.group` : `int -> int -> int * int -> lenght list -> length list -> graphics list`
`Karnaugh.group` : ` (, ) -> `
* Group `width`x`height` cells* `Karnaugh.group-` : `int * int -> int * int -> lenght list -> length list -> graphics list`
`Karnaugh.group-` : `(, ) (, ) -> `
* Group the cells in the specific range