Skip to main content
Formal Specification

Cat and Mouse / Circle Barrier Chase — Formal Specification

Vietnam · chase-tag · Confidence: medium

← Back to game page

Implementation Suitability

Suitability: engine-readyFidelity: discretizedGap-fills: 4
# Mèo đuổi chuột — AI-optimized specification ## General idea Mèo đuổi chuột is a classic Vietnamese children's circle pursuit-evasion game with a strict topological path-replication constraint. The Mouse weaves between the clasped arms of a surrounding human circle; the Cat must pursue the Mouse by traversing the *exact sequence of gate openings* used by the Mouse. The surrounding circle players cooperate with the Mouse by raising arms to facilitate passage while lowering arms to delay the Cat. ## Formal model - **Abstraction taken:** The continuous play area is discretized into a planar bipartite graph consisting of an Interior zone Zin, an Exterior zone Zout, and K peripheral gate nodes G1,…,GK arranged in a circular ring [gap-fill: continuous running and circular human barriers are discretized into a planar graph with an interior zone, exterior zone, and N barrier gate nodes with traversal costs]. - **Player/agent count:** 2 decision agents: Cat (C) and Mouse (M), operating in an environment parameterized by K circle barrier nodes (K∈[8,16]). - **Turn model:** Simultaneous discrete tick-by-tick action execution (t=1,…,Tmax). ## Formal rules R1. Topological Graph Setup: - Graph nodes: V={Zin}∪{Zout}∪{g1,g2,…,gK}. - Edges: Each gate gk connects Zin and Zout (i.e., undirected edges (Zin,gk) and (gk,Zout) for all k∈{1..K}). - Both Cat and Mouse start in Zin at t=0. - Mouse maintains a path queue Qpath=[] tracking the sequence of gate transitions. R2. Movement Rules: - Mouse movement: From Zin, Mouse can move to any gate gk, and then into Zout, or vice-versa. - When Mouse transitions through gate gk, gate ID k is appended to Qpath: Qpath.push(k). - [gap-fill] Cat Path-Replication Rule: Cat is legally permitted to transition between Zin and Zout *only* by passing through the gate g∗=Qpath.peek() at the head of the path queue. Upon completing passage through g∗, Qpath.pop(). R3. [gap-fill] Circle Gate Resistance / Traversal Delay: - When Mouse traverses gate gk, traversal duration is 1 tick (gate is open). - When Cat traverses gate gk, the barrier delay imposes a cost of 2 ticks (gate is closed/obstructed by circle players). R4. Tagging and Catch Condition: - If at the end of tick t, both Cat and Mouse occupy the exact same node (e.g. pC=pM=Zin, pC=pM=Zout, or pC=pM=gk) and the Cat's path queue is completely synchronized with the Mouse (|Qpath|=0): - Cat tags the Mouse (`TAG` event). - Cat wins the round immediately. R5. [gap-fill] Round Time Limit / Mouse Victory: - The round is capped at Tmax=60 ticks. - If Tmax expires without the Cat tagging the Mouse, the Mouse wins the round. R6. Role Inversion: - When the Cat wins, the captured Mouse becomes the Cat for the subsequent round. ## Edge cases - Tie at the end condition: Not applicable; either Cat captures Mouse before Tmax (Cat win), or time expires (Mouse win). - A player with no legal move: Both agents always have legal movements to adjacent connected nodes. - Repetition / cycles: Bounded by the hard round limit Tmax=60 in R5. - Simultaneous claims on the same resource or position: When Cat and Mouse occupy the same node, it immediately triggers the win-tag check. - Player elimination mid-round; turn order repair: No elimination; 2 agents maintain active roles throughout the round. - Resource exhaustion: Path queue Qpath is dynamically consumed by Cat's movement; bounded in length by Tmax. - Termination guarantee: why the game provably ends: Guaranteed by R5 (t≤60 ticks). ## State representation - Persistent state: - `num_gates`: integer K∈[8,16]. - `round_wins_Cat`, `round_wins_Mouse`: integers. - Per-round ephemeral state: - `mouse_pos`, `cat_pos`: node IDs ∈V. - `path_queue`: FIFO queue of gate indices [k1,k2,…]. - `cat_delay_timer`: integer ∈{0,1} (tracking barrier resistance). - `current_tick`: integer t∈[0,60]. - Observable information: - Mouse: Fully observes current graph state, own position, Cat position, and Qpath. - Cat: Fully observes current graph state, own position, Mouse position, and head of Qpath. ## Action space - Mouse: - `move_to(target_node)`: target_node ∈Neighbors(pM). - Cat: - `move_to(target_node)`: target_node ∈Neighbors(pC), constrained by R2 path queue. ## Playability notes - Single-player-vs-AI: Highly playable; human plays as the evasive Mouse planning deceptive path loops, or as the Cat computing shortest constrained chase paths. - Group games (n>4): The traditional game uses 10–25 children to form the living circle; here, the circle is formalized as the topological gate graph with asymmetrical traversal costs, reducing seamlessly to a 2-agent strategic pursuit game. - Physical-skill games: Physical ducking under arms and sprinting agility are mapped into the discrete graph topology and barrier delay cost. - What is lost in the adaptation: The joyous group singing of the folk poem, the physical squirming beneath clasped arms, and the playful teasing of the Cat. ## Implementation hints - Implement as a graph traversal environment where legal moves for Cat are filtered through `path_queue`. - Graph can be rendered as a 2D ring of K gates with inner/outer concentric zones. - Suggested first milestone: Implement graph topology and path-queue validation, verifying that Cat cannot cut corners across unvisited gates.

Download as JSON

Download the full game corpus entry for this game as structured JSON.

Download JSON
Cite this page

Cat and Mouse / Circle Barrier Chase (Vietnam). (n.d.). Games of Countries. https://gamesofcountries.com/games/vn-vietnam/meo-duoi-chuot

@misc{gamesofcountries-vn-vietnam-meo-duoi-chuot,
  title = {Cat and Mouse / Circle Barrier Chase (Vietnam)},
  year = {n.d.},
  publisher = {Games of Countries},
  url = {https://gamesofcountries.com/games/vn-vietnam/meo-duoi-chuot}
}