සංගතිකSangathika

SAM · Spined Advanced Mathematics · a tree of leaves for computing students

සංගතික Sangathika

Mathematics is one subject seen through many windows. Each leaf is a window. The same few objects appear in every one of them, so what you learned at one window is waiting for you at the next.

QR code for www.sangathika.comසංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0.
Scan to open www.sangathika.com on your phone.
The Sangathika tree A tree with thirteen labelled leaves. Three root leaves (Functions, Trigonometry, Exponentials and logarithms) grow below the soil line. Four leaves grow on the trunk (Logic and sets, Counting, Modular arithmetic, Graphs). The crown holds Probability and Statistics on the left bough, Sequences, Differentiation and Integration on the right bough, and Linear Algebra at the top. සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. ROOTS DISCRETE TRUNK CHANCE AND DATA CHANGE AND ACCUMULATION THE MACHINE Functions Trigonometry Exponentials and logarithms Logic and sets Counting Modular arithmetic Graphs Probability Statistics and data Sequences and limits Differentiation Integration Linear Algebra
The tree. Click a leaf to go to its card; on a phone, scroll the picture sideways. Roots grow below the soil line: they are not optional. Pale leaves are planned and not yet built.

The name

The name is a Sinhala word. Its root is saṅgata: coherent, gone together. Things that are saṅgata fit each other. They agree. Nothing in them is out of place.

An ola-leaf manuscript with a commentator's note in the margin, tied by a thread to the line above සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0.
Purpose: saṅgati as a visible thread from the new note back to the old line.

The word also had a precise job in the old commentaries. A scholar could not open a new section without first stating its saṅgati: the thread that tied it to the section before, and the reason it had the right to come next. A section with no thread had no place in the text.

That rule is the whole of this project. Every page states its thread to the page before. Every page makes a promise to the page after.

A formal system you have already heard of

Sanskrit is a language. It is also a formal system, and the oldest one we have in full.

About twenty-four centuries ago, Pāṇini wrote a grammar of Sanskrit in close to four thousand short rules called sūtras. A sūtra is a few words long. Rules refer to other rules. A later rule uses what an earlier rule defined. Some rules are rules about rules: they say which rule wins when two apply. From a few hundred roots and these rules, every correct word of the language can be built, and a wrong one can be shown to be wrong, step by step.

A dovetail joint: two timber pieces drawn apart, then joined, with the cuts dimensioned සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. 1 : 6 pitch joined
Purpose: a complex, strong thing is two parts and one explicit rule for joining them.

Computer scientists met this grammar again in the twentieth century. The notation they use to define programming languages has the same shape, and some of them named it after both its inventors: the Pāṇini-Backus form.

Here is what Sanskrit shows. A complex idea is not a large thing. It is a small set of parts and an explicit rule for joining them. What makes an idea hard is not its size. It is a missing rule.

What Sangathika formalises

Most courses treat advanced mathematics as a summit. You climb through the foundations, and the advanced ideas wait at the top for the few who arrive.

Sangathika treats mathematics as a spine. There is no summit. Each idea is a bone shaped to hold the next. What you can carry at the top is only what is aligned below.

A human spine in side view, vertebra by vertebra, with three vertebrae labelled Vectors, Determinant and Eigenvectors සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. Vectors Determinant Eigenvectors no bone is the advanced one
Purpose: strength at the top is alignment below; no bone is the advanced one.

Most lessons mix several ideas in one chapter.

Here every page is a sūtra: one idea, stated in one sentence of fewer than twenty words. The rest of the page is the commentary that builds it, in six layers, in a fixed order.

Most teaching asks you to read, then do.

Here you act first. You drag the arrow, set the dial, move the towns. Then you predict what will happen. Only then do you read why.

Most definitions are words to memorise.

Here a definition is code. The page that introduces the dot product adds a function called dot to the leaf's library. The next page calls it, and you can read the call. By the end of a leaf you hold a small grammar you built one rule at a time, and every rule in it runs.

A workshop wall of hand tools on hooks, each labelled with a library function name, with one empty hook for the next page සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. vecadddotdet apply page 01page 01page 05page 09page 06, next
Purpose: the library is a set of tools the learner made and will use again; the empty hook is the next page.

Most courses change their examples with every chapter.

Here the same few objects return: a 3-4-5 triangle, two towns and the road between them, one dial, fifteen students and their marks. They are the roots of the grammar. Each time you meet one, it means more than last time.

Most textbooks keep pure and applied mathematics in separate rooms.

Here an application hangs from the exact bone it needs. A cipher hangs from the inverse. A search engine's ranking hangs from an eigenvector. You reach the application the moment its spine is strong enough.

Most difficulty is hidden until you fail.

Here every challenge declares its level before you open it: Seed, Branch or Canopy. You choose your climb.

Advanced mathematics is not far away. It is what a strong spine can carry.

How to read a page

Act: drag, set or step the object on the first plate before you read anything. Predict: commit to an answer before the plate shows it. Read: the six layers, in order, each adding one clause to the page's one sentence. Check: six quick questions, then the challenges, each with its level declared.

The cast

Four objects that return across the leaves. Each leaf uses at least one. No object is ever redefined; each return adds one new reading.

Three rope-stretchers holding a knotted rope in a 3-4-5 triangle සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. 4 3 5
The 3-4-5 triangle. A rope with twelve knots makes a right angle. Born in Linear Algebra page 1 as the arrow (3, 4).
Two towns on a ridge with one road between them and carts moving both ways සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. A B
The two towns. Each year some people move each way. Born in Linear Algebra page 17; the gap between them shrinks by 0.7 every year.
A brass dial with a single pointer සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. 0
The dial. One circle marked round its rim. Unit circle, clock face and spinner are all this one object.
A classroom of fifteen desks seen from above සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0. board
The fifteen. Fifteen students, their study hours and their marks. An invented class; no real person is in it.

Three levels of challenge

A seedling with two leaves rising from a mound of soil සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0.
Seed. One idea from this page, a few minutes, by a route the page did not walk.
A branch with side shoots and buds සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0.
Branch. Two ideas within the leaf, or a reframe the page did not state. Ten to thirty minutes.
A tree canopy seen from below, branches radiating from the trunk සංගතික · Sangathika · SAM. © 2026 Niranga Dharmaratna. CC BY-SA 4.0.
Canopy. Crosses leaves, needs invention, may stay open for days. Every meeting point between two leaves is one.

For the teacher

Sequencing, principles and how to contribute

Every lesson page carries a teacher note: why the page sits where it does, the misconceptions it targets, and why each challenge is hard. Every leaf page states the sequencing of its whole leaf. The seven principles behind every page are: need before name, act before read, predict before reveal, one idea per page, misconception first, same objects with new eyes, and spaced retrieval.

To propose a page or report an error, see how to contribute.

Privacy

No learner accounts, no analytics scripts, no cookies set by this site. Your quiz and challenge progress stays in your own browser. GitHub serves these pages and keeps its own traffic counts under its terms.