-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathexample.tex
More file actions
109 lines (72 loc) · 1.94 KB
/
example.tex
File metadata and controls
109 lines (72 loc) · 1.94 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
\documentclass{article}
\usepackage{genabacus}
\title{Genabacus Package Examples}
\author{}
\date{}
\begin{document}
\maketitle
\section{Basic Usage}
The \verb|\abacus| command takes the number of columns and a list of bead positions.
\subsection{Simple Abacus}
A 5-column abacus with beads at positions 0, 2, 4, 6, 8:
\begin{center}
\abacus{5}{0,2,4,6,8}
\end{center}
\subsection{Different Configurations}
3 columns, beads at positions 1, 3, 5:
\begin{center}
\abacus{3}{1,3,5}
\end{center}
\section{Using fabacus (Friendly Syntax)}
The \verb|\fabacus| command uses \texttt{b} to mark bead positions:
\begin{center}
\fabacus{bnn,nbn,nnb}
\end{center}
This creates a diagonal pattern (b = bead, n = no bead).
\section{Styling Options}
\subsection{Colored Beads}
\begin{center}
\abacus[bead_body_colour=blue]{4}{0,1,2,3}
\end{center}
\subsection{With Position Markers}
Show empty positions where beads could go:
\begin{center}
\abacus[positions=true, max_position=12]{4}{1,5,9}
\end{center}
\subsection{Scaled}
Larger scale:
\begin{center}
\abacus[scale=1.5]{3}{0,1,2}
\end{center}
\subsection{With Runner Labels}
\begin{center}
\abacus[runner_label_switch=true]{5}{0,6,12,18,24}
\end{center}
\subsection{Different Bead Colors}
Red beads with white labels:
\begin{center}
\abacus[bead_body_colour=red, bead_label_colour=white]{4}{0,5,10,15}
\end{center}
\subsection{No Shading (Flat Style)}
\begin{center}
\abacus[shade=false, bead_body_colour=orange]{3}{0,1,2}
\end{center}
\subsection{With Border}
\begin{center}
\abacus[bead_border_switch=true, bead_border_colour=darkgray]{4}{0,1,2,3}
\end{center}
\section{Inline Usage}
Abacuses can be used inline: \abacus[scale=0.5]{3}{0,1,2} like this.
\section{Combined Options}
\begin{center}
\abacus[
scale=1.2,
bead_body_colour=purple,
bead_label_switch=true,
bead_label_colour=white,
runner_label_switch=true,
positions=true,
max_position=20
]{5}{0,6,7,13,19}
\end{center}
\end{document}