跳到主要内容
知仓学习社ZHICANG

prime-numbers

Problem-solving strategies for prime numbers in graph number theory

不碰外部(只输出文字)无严重或高危命中parcadei/Continuous-Claude-v3

它会碰到什么

扫了多少1 个文本文件,2 KB
它会碰到什么不碰外部(只输出文字)
命中总数0 处
命中统计严重 0 · 高 0 · 中 0 · 低 0

这一栏是扫描器报的事实,不是结论。命中多不等于有毒(安全工具、规则库、示例脚本本来就会包含危险写法),命中少也不等于干净。它和你手上的凭据、文件、网络有什么关系,需要你自己看。

技能内容

Prime Numbers

When to Use

Use this skill when working on prime-numbers problems in graph number theory.

Decision Tree

  1. Primality testing hierarchy
  • Trial division: O(sqrt(n)), exact
  • Miller-Rabin: O(k log^3 n), probabilistic
  • AKS: O(log^6 n), deterministic polynomial
  1. Factorization
  • Trial division for small factors
  • Pollard's rho: probabilistic, medium numbers
  • Quadratic sieve: large numbers
  • sympy_compute.py factor "n"
  1. Prime distribution
  • Prime Number Theorem: pi(x) ~ x/ln(x)
  • Prime gaps: p_{n+1} - p_n
  • sympy_compute.py limit "pi(x) * ln(x) / x"
  1. Fermat's Little Theorem
  • a^{p-1} = 1 (mod p) for a not divisible by p
  • Use for modular exponentiation
  • z3_solve.py prove "fermat_little"
  1. Wilson's Theorem
  • (p-1)! = -1 (mod p) iff p is prime

Tool Commands

Sympy_Factor

uv run python -m runtime.harness scripts/sympy_compute.py factor "n"

Z3_Primality

uv run python -m runtime.harness scripts/z3_solve.py prove "no_divisor_between_1_and_sqrt_n"

Sympy_Prime_Count

uv run python -m runtime.harness scripts/sympy_compute.py simplify "pi(x) ~ x/ln(x)"

Z3_Fermat_Little

uv run python -m runtime.harness scripts/z3_solve.py prove "a**(p-1) == 1 mod p"

Key Techniques

From indexed textbooks:

Cognitive Tools Reference

See .claude/skills/math-mode/SKILL.md for full tool documentation.

想直接用这个技能?

本站把开放许可(MIT / Apache 等)的技能按仓库打包整理到网盘,点一下转存到你自己的网盘,不用一个个从 GitHub 拉。许可未声明的技能只给原始仓库链接,不打包。

它属于哪个仓库

星标★ 3,941
本站分层T1
该仓技能数158
原文件路径.claude/skills/math/graph-number-theory/prime-numbers/SKILL.md

同一个仓库里的其他技能

看这个仓库的全部 158 个技能