# `WolframModel.RuleSet`
[🔗](https://github.com/sragli/wolfram_model/blob/main/lib/wolfram_model/rule_set.ex#L1)

Rule sets responsible for the evolution of the Wolfram Model.

# `rule`

```elixir
@type rule() :: %{pattern: [[term()]], replacement: [[term()]], name: String.t()}
```

# `basic_rules`

```elixir
@spec basic_rules() :: [rule()]
```

Defines a set of basic evolution rules for experimentation.

# `rule_set`

```elixir
@spec rule_set(atom()) :: [rule()]
```

Creates some interesting specialized rule sets.

# `rule_set`

```elixir
@spec rule_set(:wolfram, atom()) :: [rule()]
```

Classic benchmark rules from the Wolfram Physics Project.

All rules use the canonical integer variable notation and are expressed
as N-pattern rules (requiring the general N-pattern matcher).

Available rule sets:
- `:rule_1` — binary split: `{{1,2},{1,3}} -> {{2,3},{1,4}}`
- `:rule_2` — triangle rewrite: `{{1,2},{1,3},{2,3}} -> {{1,4},{2,4},{3,4},{1,2,3}}`
- `:rule_3` — three-edge rewrite: `{{1,2},{3,4},{2,3}} -> {{1,2},{2,3},{3,4},{4,1}}`
- `:rule_4` — growth rule (spatial): `{{1,2,3},{1,4,5}} -> {{1,2,3},{1,4,5},{2,4,6}}`
- `:rule_5` — self-referential: `{{1,1},{1,2}} -> {{1,2},{1,3},{2,3}}`

# `wolfram_rules`

```elixir
@spec wolfram_rules() :: %{required(atom()) =&gt; [rule()]}
```

Returns the full map of named Wolfram benchmark rules.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
