Structural isomer counting

From XuShuwenn/RedAct · View interactive version

Structural isomer counting is an AI agent skill from the GitHub repository XuShuwenn/RedAct. Count constitutional isomers from a molecular formula, with a fast path for small acyclic alkanes and strict output formatting.

How to use this skill

Skill file

Structural Isomer Counting

Reusable workflow to determine the number of constitutional (structural) isomers given a molecular formula, write the exact required output line, and avoid common scope and formatting mistakes.

When to Use

Activate this skill when:

Core Workflow

  1. Read and Normalize Input
  1. Parse the Formula
  1. Assess Saturation via Index of Hydrogen Deficiency (IHD/DBE)
  1. Fast Path (Acyclic Alkanes Only)
  1. General Case (Beyond Acyclic Alkanes)
  1. Write Output in Exact Format

Verification

Before finalizing:

Common Pitfalls

Optional Script Usage

Use the helper to parse formulas, compute DBE, and return counts for small acyclic alkanes.

Success Criteria:

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.