GiacSlate.jl

Computer algebra, live in the notebook

Giac — the engine behind Xcas — driven from Julia, with editable MathLive math fields, typeset results, and exercises that grade themselves.

GiacSlate.jl GiacSlate.jl

Exact algebra

Factor, integrate, solve, transform — with no floating-point roundoff anywhere. All ~1800 GIAC commands, reachable from Julia.

⌨️

Live math fields

A giac"…" literal renders as an editable MathLive field. The reader types fractions and exponents; the cell recomputes.

Self-grading exercises

A symbolic grader that accepts any algebraically equivalent form, with score cards, hints, and a progress report.

🧩

A native Slate extension

Built on SlateExtensionsBase — no boot cell, no assets to declare. `using GiacSlate` is the whole setup; the front-end loads on demand.

📐

Typeset in prose

gmath and gdisplay drop a Giac expression into the middle of a Markdown paragraph, and it re-typesets when the variable changes.

🔁

Reproducible in CI

Every notebook is executed and published as a Documenter page by DocumenterSlate — with verifiable archives, provenance, and a deploy job that executes nothing.

What it is

GiacSlate.jl connects Giac.jl — the Julia wrapper around Giac, the computer algebra engine behind Xcas — to reactive Kaimon Slate notebooks.

It supplies three things neither Giac.jl nor Slate provides on its own:

  1. a typed @bind control (Mathfield) whose value is an expression entered on a math keyboard, not a string;
  2. a MathJSON ↔ GIAC source ↔ LaTeX bridge, which is what makes a giac"…" render as typeset mathematics and become editable on click;
  3. a symbolic autograder, which compares a student's answer to a reference solution by algebraic equivalence rather than by string equality.

The four notebooks in notebooks/ are not mockups: the pages under The notebooks are the real output of those .jl files, executed headlessly by DocumenterSlate.jl.

Installation

GiacSlate isn't registered yet. From the Pkg REPL (press ]):

pkg> add https://github.com/JuliaGiac/GiacSlate.jl

Then, to open a notebook:

git clone https://github.com/JuliaGiac/GiacSlate.jl.git
cd GiacSlate.jl
slate notebooks/giac_intro.jl

Getting started covers the slate CLI and the notebook environment in more detail.

A taste

using Giac, GiacSlate
using Giac.Commands: factor, integrate, laplace

@giac_var x
@giac_var t
@giac_var s

factor(x^4 - 1)              # (x-1)*(x+1)*(x^2+1)
integrate(x * exp(x), x)     # (x-1)*exp(x)
laplace(exp(-2t), t, s)      # 1/(s+2)

…and, inside a notebook cell, the same thing editable with the mouse:

factor(giac"x^6 - 1")        # the literal is a live MathLive field

Where to go next