Skip to content
cccskills
FreePublished on GitHub

dimensional-analysis-checker

当有一条推导、模型方程、标度律或最终公式,想在相信它之前先过最便宜的一关时使用。逐项查量纲:先统一记号、建符号量纲表,再按加减两侧同量纲、等式两边一致、指数对数三角函数的宗量无量纲逐条核对,指出第一处不一致;每个通过的项还要说出它代表什么物理贡献,说不出的项就是没理解的项。结论里写明量纲通过不等于物理正确。

The English summary is being prepared. Showing the original description.

See how to install

Files included (1)

  • SKILL.md11.7 KB

SKILL.md (original)

Review the instructions the agent will receive before you install.

dimensional-analysis-checker

Purpose

Use this skill when a user has a physics equation, derivation step, scaling law, or model expression and wants to know whether the dimensions make sense before trusting the result.

This skill does not prove that a derivation is fully correct. It answers a narrower question first: do the units and dimensions constrain the expression the way physics says they should?

When to use

Use this skill when the user wants to:

  • check a derived formula term by term
  • catch missing factors, extra factors, or impossible sums
  • verify a scaling law or constitutive relation
  • compare two candidate formulas and rule out dimensionally impossible ones
  • inspect the equations of a modeling paper draft for inconsistent symbol usage or undeclared units (reviewing a whole modeling paper or its full chain of claims belongs to model-critique-coach)

When not to use

Do not use this skill as the only validation step when the user needs:

  • limiting-case checks
  • numerical plausibility checks
  • a full derivation from first principles
  • experimental uncertainty propagation
  • proof that the physics assumptions themselves are appropriate

If the algebra is dimensionally valid but still physically wrong, say so plainly and hand off to limiting-case-validator, physics-mechanism-decomposer, or derivation-step-checker.

Inputs

Ask for the smallest set that makes checking possible:

  1. the expression, equation, or derivation step to inspect
  2. a symbol table with meaning and units/dimensions for each symbol
  3. the unit system if it matters (SI, Gaussian/CGS, natural units, nondimensionalized variables, etc.)
  4. any declared constants or dimensionless coefficients
  5. if symbols were reused across sections, which definition is intended here

If the user does not provide a symbol table, build one explicitly from the prompt and mark guessed entries as assumed.

Outputs

Return a compact report with these sections:

  1. Scope — what was checked and under which unit system
  2. Dimension map — symbol → meaning → dimension/unit → status
  3. Checks — each equation or term marked pass, fail, or ambiguous
  4. Findings — the exact mismatch, leftover factor, or undefined symbol
  5. Physical meaning audit — what each surviving term represents physically
  6. Next move — smallest correction or follow-up check to run next

Core workflow

Step 1: Normalize notation first

Before checking dimensions:

  • rewrite the target expression in a consistent notation
  • expand overloaded symbols (R radius vs resistance, T period vs temperature)
  • note any hidden conventions such as radians treated as dimensionless
  • separate true constants from fitted coefficients

If notation is ambiguous, do not silently choose one meaning. Mark the result ambiguous until the symbol is disambiguated.

Step 2: Build a dimension map

For every symbol that appears, create a table with:

  • symbol
  • physical meaning in this context
  • dimension in base quantities when possible (for example [M L T^-2])
  • stated unit if supplied
  • evidence status: given, derived, or assumed

Prefer base-dimension form over only unit names because it exposes hidden inconsistencies faster.

Step 3: Check homogeneity where physics requires it

Apply the strongest valid test for the structure at hand:

  • sum/difference: every addend must have identical dimensions
  • equality: left-hand side and right-hand side must match
  • exponentials/logs/trig arguments: the argument must be dimensionless unless the user is explicitly using a known convention and states it
  • powers/roots: the dimensional consequences must be explicit
  • vector equations: dimensions must match componentwise; note separately if geometric meaning is still unclear

When a formula mixes terms with different dimensions, point to the first exact place the mismatch appears.

Step 4: Inspect dimensionless groups and leftover factors

After the basic check:

  • identify dimensionless groups that naturally emerge
  • flag parameters that should cancel but do not
  • flag terms that are dimensionally allowed but physically suspicious
  • note when the expression implies a hidden scale the user never introduced

A dimensionally valid term still needs a sentence explaining what contribution it stands for physically.

Step 5: Run the physical meaning audit

For each surviving term or grouped contribution, ask:

  • what mechanism does this term represent?
  • is that mechanism supposed to be present in the stated model?
  • if this term vanished, what physical limit would that correspond to?
  • if this term dominates, what regime would that imply?

If a term passes units but nobody can say what it means, call it out. That usually signals cargo-cult algebra or a missing modeling assumption.

Step 6: Report confidence honestly

Use these outcome labels:

  • pass — dimensionally consistent under stated assumptions
  • fail — definite inconsistency found
  • ambiguous — cannot judge cleanly because notation, units, or conventions are underspecified
  • partial pass — some steps check out, but at least one symbol or conversion remains unresolved

Deterministic path vs fallback path

If code execution is available

Prefer this repository's own checker first — it is standard-library only, so it runs anywhere:

python3 ../_shared/scripts/dimcheck.py expressions.dim

Write the dimension map into a [symbols] section (v = L T^-1) and each expression into [check] as name = expression, with the declared dimension after a ;. To check an equation, write it as lhs == rhs (or name = lhs == rhs to name it): both sides must share a dimension, and a side written as 0 matches any dimension. A plain lhs = rhs is also checked as an equation unless lhs is a single new name, which that line defines. Use [compare] to assert that several named terms share a dimension. Put fractional exponents in parentheses, x^(1/2); x^1/2 and v^2/2 are rejected as ambiguous, so write (v^2)/2 or 1/2*v^2 for division. The checker reports each mismatch, refuses to add unlike terms, rejects dimensional arguments to exp/log/trig and to symbolic exponents, and lists every symbol that was never declared — which doubles as a check for quantities that appeared out of nowhere. Exit status 0 means all checks passed; 1 means a dimensional inconsistency or an undeclared symbol; 2 means the input itself could not be parsed, which is a problem with the .dim file to fix and rerun, not a finding about the physics. --selftest verifies the checker itself.

Reach for SymPy or another CAS only for what dimcheck.py deliberately does not do:

  • simplifying and enumerating candidate dimensionless groups
  • solving the dimension matrix for its rank (the k in Buckingham's n − k)
  • algebraic simplification of the expression itself

If no code execution is available

Use a manual table method:

  1. rewrite each symbol in base dimensions
  2. multiply/add exponents term by term
  3. compare addends and both sides of the equation
  4. record the first mismatch explicitly

The skill should still work without any vendor-specific runtime. Label these checks as manual in the report; never write that the script ran or that anything was verified by script.

Guardrails

  • Do not invent units for a symbol without marking them assumed.
  • Do not pretend dimensional validity proves physical correctness.
  • Do not hide ambiguity caused by natural-unit or nondimensional conventions.
  • Do not hand over a finished solution, a full derivation, or a submission-ready corrected formula for work the user will submit; name the factor where the first inconsistency sits and leave the correction to the user. This applies to every request, including a repeated one (../_shared/physics-evidence-contract.md §4).
  • If the expression is actually a fitted empirical law, say that dimensional consistency may constrain form but not prove mechanism.

Handoff guidance

Hand off to another skill or workflow when:

  • the expression passes units but fails a limiting case
  • the mechanism list is unclear even though the dimensions work
  • the user needs uncertainty propagation rather than unit checking
  • the main problem is symbol collision across a longer document

Recommended neighbors (all available):

  • physics-mechanism-decomposer — open-phenomenon mechanism ranking
  • problem-formalization-coach — when the real problem is that a law was used without stating why it applies
  • limiting-case-validator — regime checks: send each parameter to 0 and to infinity and check that the expression returns to a known special case
  • derivation-step-checker — algebra plus law-by-law validation, step by step
  • concept-to-formula-deriver — a derivation from first principles rather than a check
  • answer-plausibility-checker — a numerical result to sanity-check rather than a formula
  • uncertainty-propagator — uncertainty propagation rather than unit checking

References

Shared physics material lives one level up, loaded on demand:

  • ../_shared/dimensionless-groups.md — Buckingham's theorem (how k and n get miscounted), the standard groups, and the discipline for comparing magnitudes
  • ../_shared/law-applicability-table.md — when a dimensionally valid term still violates the conditions of the law it came from
  • ../_shared/physics-evidence-contract.md — status tags, significant figures, which constants are exact by definition and which must be cited with a date, and the academic-integrity boundary (§4) behind the guardrail above
  • ../_shared/scripts/dimcheck.py — the deterministic checker

Example prompts

  • "Check whether this drag-force model is dimensionally consistent."
  • "I derived an oscillation period formula; find the first unit mismatch if there is one."
  • "These two heat-transfer terms are being added together. Is that legal dimensionally?"
  • "Here is a modeling draft equation set. Build a symbol table and flag suspicious leftover parameters."

Minimal response template

Scope
- Checked: ...
- Unit system: ...

Dimension map
- symbol: meaning | dimension/unit | status

Checks
- Eq. (1): pass/fail/ambiguous
- Eq. (2): ...

Findings
- First mismatch: ...
- Suspicious leftover factor: ...

Physical meaning audit
- Term A represents ...
- Term B represents ...

Next move
- ...

变更记录 / Changelog

版本日期变更类型
0.1.12026-09-26跟随 dimcheck.py 修复写明 [check] 的方程写法、分数指数加括号与退出状态 0/1/2;诚信条款改为无条件并引用证据契约 §4;相邻 skill 去掉过时的 planned 标注并改用实名;π 定理引用改为"k 与 n 被数错的方式";补 dimcheck 路径与无执行能力两个用例patch
0.1.02026-08-30Initial cross-agent version with explicit manual fallback and evidence-status reporting.minor

Reviews

No reviews yet. Tell others what you thought.

Comments

No login needed. Share how it worked for you, ask a question, or note where it did not run.

No comments yet. Be the first to write one.

Comments are published right away. Do not include personal information such as email addresses or phone numbers. Up to 2 URLs.

0 / 1,000 characters

This form is protected by reCAPTCHA, and the Google Privacy Policy and Terms of Service apply.

More skills from this repository

当学生说"Common App 活动栏写不下"、"这段活动描述超字数了"、"帮我把这几条压到限制内"时使用。先按官方申请表核对当季字符限额,再逐条检查;一次把所有条目量完并直接给出压缩版,只在需要砍掉实质内容时才用选择题问该保哪部分。每改一版都用工具重新数一遍字符,绝不凭感觉说"这样应该够了"。只压缩,不代写空白。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

当学生说"我参加过一些活动但没整理过"、"帮我把经历录进去"、"我的活动档案是空的"时使用。让学生一口气把记得的活动说出来,直接把这段话拆成结构化的长期事项(角色、组织、起止时间、做了什么、结果、级别),说不清的字段留空标"待补"而不是编,再用一张选择题卡把级别判定与是否重复这类关键项一次问完,然后提案入库。只记录学生真正说出口的内容,级别按事实判定,绝不往高了写。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

当学生问"招生官会怎么看我的档案"、"我的背景还差什么"、"帮我评估一下现在的申请竞争力"时使用。以顶尖大学招生官的视角通读学生的档案、长期活动与已写下的反思,不问任何前置问题直接产出一份指名道姓的坦诚点评:这份材料的亮点、招生官真实的解读方式、明显的短板与空白、以及接下来最值得做的一到两件事。只读不写,不修改学生的任何数据,也不代写任何申请材料。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

当使用者说"帮我填词"、"按这个字数模板写歌词"、"用多Agent对抗式写词"、"这首副歌帮我想几句"时使用,前提是字数骨架和这首歌写什么都已经有了;只有主题、还没定写什么时先用 lyric-concept-builder。拿一份字数骨架和意象系统,派三个 sonnet 子代理按不同路子并行独立起草(场景派 / 口语派 / 意象派),再派一个红队子代理逐句挑毛病,主 Agent 按句裁决拼稿,最后统一辙口与意象。收敛判据卡死:字数用 lyric-doctor 的脚本对模板数、每段同辙、hook 不含陈词、主歌二对主歌一有推进。不抄现有歌词,不替使用者决定这首歌要说什么。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

当想知道一段 AI 回答"哪些能直接用、哪些必须先验证、哪些只能当建议"时使用。按声明类型分四级——低风险草稿材料、观点与策略建议、可查证的事实声明、会改变状态的可执行指令——每级配一句默认处置动作;再按影响半径排序,给出最小的下一步检查。可执行类一律标"不能直接执行;先做代码审阅/沙箱测试/回滚准备",其中破坏性或提权的命令排在最前。教的是一套可复用的复查习惯,不是替使用者把所有内容都核实一遍:本 skill 只分级、排序、定处置,要逐条核实走 ai-output-fact-checker,整段代码要做入库体检走 ai-code-onboarding-checklist。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

当拿到一段 AI 生成的代码,还没决定要不要信、要不要跑、要不要往上继续加东西时使用。先做一遍客观体检:行数与嵌套深度、有没有测试、有没有硬编码密钥或遗留 TODO、依赖是不是真实存在、有没有危险调用(eval/exec、shell=True、递归删除、反序列化、提权、外发网络,按正文给的 grep 模式逐类查);再给风险评级和下一步动作。老实写明它查不了算法正确性——体检通过不等于代码是对的。回答里文字、事实和代码混在一起时先用 ai-answer-triage 分级;只审相对已有代码的一份改动用 ai-diff-review-protocol。

The English summary is being prepared. Showing the original description.

ChromiteCr/Skills4Updated Oct 19, 2026

See all skills by ChromiteCr

Report a problem with this skill