Solve Modular Arithmetic

Solve modular arithmetic problems including congruences, systems via the Chinese Remainder Theorem, modular inverses, and Euler's theorem applications. Covers both manual and computational approaches. Use when solving linear congruences, computing modular inverses, evaluating large modular exponentiations, working with simultaneous congruences (CRT), or operating in cyclic groups and discrete logarithm contexts.

45 stars 4 forksOther

Install

skills CLI (Claude Code, Cursor, Codex and more)
npx skills add pjt222/agent-almanac --skill solve-modular-arithmetic
Manual install
git clone --depth 1 https://github.com/pjt222/agent-almanac.git /tmp/agent-almanac
mkdir -p ~/.claude/skills
cp -r /tmp/agent-almanac/i18n/caveman-lite/skills/solve-modular-arithmetic ~/.claude/skills/solve-modular-arithmetic

Personal skills live in ~/.claude/skills. Use .claude/skills in a project folder to share a skill with your team.

From the SKILL.md

# Solve Modular Arithmetic

Solve modular arithmetic problems by parsing congruence systems, applying the extended Euclidean algorithm for inverses, using the Chinese Remainder Theorem for simultaneous congruences, and leveraging Euler's theorem for modular exponentiation. Verify every solution by substitution.

## When to Use

- Solving a single linear congruence ax = b (mod m)
- Solving a system of simultaneous congruences (Chinese Remainder Theorem)
- Computing a modular inverse a^{-1} (mod m)
- Evaluating large modular exponentiations a^k (mod m)
- Determining the order of an element in Z/mZ
- Working with cyclic groups, primitive roots, or discrete logarithm contexts

## Inputs

- **Required**: The congruence(s) or modular equation to solve
- **Optional**: Whether to show the extended Euclidean algorithm steps explicitly
- **Optional**: Whether Euler's theorem or Fermat's little theorem should be applied
- **Optional**: Whether to find primitive roots or element orders
- **Optional**: Output format (step-by-step, compact, or proof-style)

## Procedure

### Step 1: Parse the Congruence System or Modular Equation

Extract the mathematical structure from the problem statement.

1. **Identify the type**:
   - Single linear congruence: ax = b (mod m)
   - System of congruences: x = a1 (mod m1), x = a2 (mod m2), ...
   - Modular exponentiation: a^k (mod m)
   - Modular inverse: find a^{-1} (mod m)
Read the full skill on GitHub

Details

Skill name
solve-modular-arithmetic
Path
i18n/caveman-lite/skills/solve-modular-arithmetic/SKILL.md
License
MIT
Repo updated
18 November 2026

FAQ

What does the Solve Modular Arithmetic skill do?

Solve modular arithmetic problems including congruences, systems via the Chinese Remainder Theorem, modular inverses, and Euler's theorem applications. Covers both manual and computational approaches. Use when solving linear congruences, computing modular inverses, evaluating large modular exponentiations, working with simultaneous congruences (CRT), or operating in cyclic groups and discrete logarithm contexts.

How do I install the Solve Modular Arithmetic skill?

skills CLI (Claude Code, Cursor, Codex and more): npx skills add pjt222/agent-almanac --skill solve-modular-arithmetic. Skills go in ~/.claude/skills (personal) or .claude/skills (project), and Claude loads them automatically when a task matches the description.

Is Solve Modular Arithmetic popular?

It lives in pjt222/agent-almanac, which has 45 GitHub stars and 4 forks, and is included in 1 curated skill list.

Related skills

Adapt Architecture

45

pjt222/agent-almanac

Execute structural metamorphosis using strangler fig migration, chrysalis phases, and interface preservation. Covers transformation planning, parallel running, progressive cutover, rollback design, and post-metamorphosis stabilization for system architecture evolution. Use when assess-form has classified the system as READY for transformation, when migrating from monolith to microservices, when replacing a core subsystem while dependents continue operating, or when any architectural change must be gradual rather than big-bang.

Software DevelopmentIn 1 list

Adaptic

45

pjt222/agent-almanac

Master skill composing the 5-step synoptic cycle for panoramic synthesis across multiple domains. Orchestrates meditate, expand-awareness, observe, awareness, integrate-gestalt, and express-insight into a coherent process that produces unified understanding rather than sequential compromise. Use when a problem genuinely spans 3+ domains and the interactions between domains matter more than depth in any one, when sequential analysis feels like compromise rather than integration, or before major architectural decisions affecting multiple stakeholders.

OtherIn 1 list

Add Puzzle Type

45

pjt222/agent-almanac

Scaffold a new puzzle type across all 10+ pipeline integration points in jigsawR. Creates the core puzzle module, wires it into the unified pipeline (generation, positioning, rendering, adjacency), adds ggpuzzle geom/stat layers, updates DESCRIPTION and config.yml, extends the Shiny app, and creates a comprehensive test suite. Use when adding a completely new puzzle type to the package or following the 10-point integration checklist to ensure nothing is missed end-to-end.

Testing & QAIn 1 list

Statute of Limitations Check

43

AlsKozlov/ru-legal

Quick check срока давности по ст.4.5 КоАП. Истечение срока = mandatory прекращение дела (ст.24.5 ч.1 п.6). Может быть game-changer для defense.

Other

Solve Electromagnetic Induction

45

pjt222/agent-almanac

Solve problems involving changing magnetic flux using Faraday's law, Lenz's law, motional EMF, mutual and self-inductance, and RL circuit transients. Use when computing induced EMF from time-varying B-fields or moving conductors, determining current direction via Lenz's law, analyzing inductance and energy storage in magnetic fields, or solving RL circuit differential equations for switching transients.

OtherIn 1 list

Submit to Cran

45

pjt222/agent-almanac

Complete procedure for submitting an R package to CRAN, including pre-submission checks (local, win-builder, R-hub), cran-comments.md preparation, URL and spell checking, and the submission itself. Covers first submissions and updates. Use when a package is ready for initial CRAN release, when submitting an updated version of an existing CRAN package, or when re-submitting after receiving CRAN reviewer feedback.

OtherIn 1 list

Browse the most popular Claude skills, all other skills, or write your own with the skills generator.