Polyanimals Logo

“One day a biologist walked into my office at the University of Michigan and asked if I could help him with a combinatiorial problem. He wanted to investigate a theory of evolution for very small animals, beginning with one cell and growing just one cell at a time.” -- Frank Harary, “Achieving the Skinny Animal," Eureka, Summer 1982

Think you've mastered tic-tac-toe? Think again! Polyanimals! takes the classic game to a whole new level with geometric patterns that will challenge your spatial reasoning and strategic thinking.

What makes it special? Instead of just getting three in a row, you're racing to complete intricate patterns like Tippy, Elly, and Cross before your opponent does the same.

Meet the "animals" - these quirky geometric patterns are the heart of the game, named by mathematician Frank Harary who mapped out this fascinating variant in the late 1970s. The game has been called Harary's tic-tac-toe or animal tic-tac-toe.

📋 Table of Contents

🎯 Why You'll Love Polyanimals!

⚡ Quick Start (30 seconds)

  1. Choose your pattern - Pick from Tippy, Elly, Cross, and more
  2. Select board size - 3x3 to 10x10 (we recommend 7x7 for beginners)
  3. Pick your opponent - Human, AI, or watch AI vs AI
  4. Start playing - Click any square to place your piece
  5. Win by completing the pattern first!

🎯 Target Animals

The set of possible target animals to choose from, one of which will be the target in a given game, are as follows:

Target Animals Grid - 20 different geometric patterns including El, Tic, Boxy, Elly, Knobby, Skinny, Tippy, Cross, Ducky, F, I, L, P, Steppy, Tee, U, C, S, Snaky, and Y patterns

Click on any pattern to select it as your target for the game. Each pattern has unique strategic properties and varying numbers of possible orientations.

🎲 Game Board

The board is a square grid of tiles, with size selectable from 3x3 to 10x10. For example, a 7x7 grid:

7x7 game board grid showing clickable squares with purple diamond markers

The game board consists of clickable squares where players place their pieces. Board sizes range from 3x3 to 10x10, with larger boards offering more strategic possibilities.

🎮 Gameplay

You can play against another human, challenge an AI, or watch AI players battle it out! Players take turns until one of them creates the target animal.

For example, in this case the human player (shamrock tiles) was able to successfully place the given target animal Tippy and win the game!

Game win example showing completed 8x8 board with Tippy pattern formed by player pieces, victory message displayed

The game shows a completed board with the winning pattern formed by the player's pieces. The target animal "Tippy" has been successfully placed, resulting in a victory!

Pattern Orientations

For Tippy, there are 4 such orientations:

Four different orientations of the Tippy pattern showing rotations and reflections

The Tippy pattern can be rotated and reflected to create 4 unique orientations. Any of these orientations counts as a valid win condition.

For some, like Elly, there are 8:

Eight different orientations of the Elly pattern showing rotations and reflections of the L-shape

The Elly pattern has 8 unique orientations due to its L-shape, allowing for more flexibility in placement compared to patterns like Tippy.

Others, like Cross and Boxy, may have just one unique orientation:

Cross and Boxy patterns showing their single unique orientations

Some patterns like Cross and Boxy have only one unique orientation, making them more predictable but potentially easier to block.

🤖 Meet Your AI Opponents

Each AI player has a unique personality and playing style. Will you challenge the methodical Frank Harary, the aggressive Paul Erdős, or the unpredictable Squirrel?

The default players are Human (you) and Computer (Frank Harary). In all there are nine computer players to select from:

Nine AI players including Frank Harary, Paul Erdős, Hypatia, Katherine Johnson, Ada Lovelace, Srinivasa Ramanujan, Liu Hui, Scarecrow, and Squirrel with their portraits and descriptions

Each AI player has a unique personality and playing style, from the methodical Frank Harary to the unpredictable Squirrel. Choose your opponent based on your preferred challenge level!

🎛️ Game Controls

Basic Controls

Player Setup

Player 1 goes first, so in Human vs. Computer games, it's best for flexibility to have Human as Player 1 and Computer as Player 2. If you (the Human) want to let the Computer play first, that can be accomplished by clicking on PASS.

Timeline Navigation

The arrow controls are back and step, for possibly going back and forth in the current timeline. This allows you to recapitulate the game if desired. If at any prior point in the timeline you select a different square than the one you had previously chosen in the current timeline, a "new timeline" message is generated and the game proceeds from that new branch. This allows you to take back moves.

Computer vs. Computer Mode

In computer vs. computer mode, game play between the players is automatic and the controls are a little different:

🎲 Game Characteristics

Pro tip: When two deterministic AI's are playing each other, games often proceed straight to the conclusion. There is some randomness when presented with equivalent moves and the AI has to pick one randomly, but even then there are probably not that many different game paths given two players and a target pattern.

🧠 Strategy

Understanding the Game

Polyanimals! is fundamentally a pattern recognition and strategic blocking game. Unlike traditional tic-tac-toe, the winning condition is more complex and varies by pattern, creating rich strategic possibilities.

Core Strategic Principles

1. Pattern Recognition

2. Offensive Strategy

3. Defensive Strategy

4. Board Size Considerations

Advanced Tactics

The Two-Move Threat

Create a position where you can win in two different ways on your next turn. This forces your opponent to block one threat, allowing you to complete the other.

Pattern Interference

Use your pieces to interfere with your opponent's pattern while advancing your own. A well-placed piece can serve both offensive and defensive purposes.

Timing and Tempo

Pattern-Specific Strategies

El

For the player with the opening move, El is unstoppable on any board 3x3 or larger:


Tic

On a 4x4 or larger board, the player with the opening move can force a Tic win in three moves:


Elly

On a 4x4 or larger board, the player with the opening move can force an Elly win in four moves:


Knobby

On a 5x5 or larger board, Knobby can also force a win in four moves:


Tippy

Tippy is a forced win in four moves very much along the lines above for Knobby:


Other known winners: Skinny, Ducky, L and Z

Skinny
Ducky
L
Y

These four target patterns are known to be forced wins with optimal play on sufficiently large boards, but the strategies can be complex and are left as exercises for the player!


Snaky

Snaky is unique among the polyanimals--it's unknown with mathematical certainty whether Snaky is a winner or loser and under what conditions (e.g. minimum board size). Harary (1982) conjectured that Snaky is a winner on a large enough board:

"My plausibility consideration for this assertion is that my former student, Dr. Geoffrey Exoo, won his last 20 games of Snaky achievement played on a sheet of graph paper."

If Harary's conjecture is true, then Snaky is the only winner among the hexominoes. There are no forced winners among heptominoes or greater.

Of course, this all is predicated on perfect, optimal play. With imperfect play on the part of the opponent, any pattern can be a winner!


Psychological Elements

Against AI Players

Against Human Players

Practice and Improvement

  1. Study Pattern Transformations: Understand how each pattern can be rotated and reflected
  2. Analyze Completed Games: Review your games to identify missed opportunities
  3. Practice Against Different AI Levels: Start with weaker AI and work your way up
  4. Experiment with Different Board Sizes: Each size offers different strategic challenges
  5. Watch AI vs AI: Observe different AI players compete to learn new strategies

Common Mistakes to Avoid

🚀 Ready to Play?

That's about it for a quick start—give it a try! The AI's are generally pretty good at defense and offense but they are not perfect (even Paul Erdős makes mistakes!), so bring your A-game and see if you can outsmart them!

Remember: Polyanimals! rewards both tactical skill and strategic thinking. The best players combine pattern recognition, forward planning, and adaptability to their opponent's style.

🔬 Geeking Out: Game Theory

For the mathematically curious, Polyanimals! offers fascinating insights into game theory and computational complexity.

Nash's Theorem and First-Mover Advantage

In 1951, John Nash proved a remarkable result: in any finite, symmetric, perfect-information game, the first player has a guaranteed advantage. This means that with perfect play, Player 1 can either force a win or guarantee at least a draw. This applies to Polyanimals! as well!

The proof uses the elegant strategy-stealing argument: if Player 2 had a winning strategy, Player 1 could "steal" it by making an arbitrary first move, then following Player 2's strategy. This creates a contradiction, proving Player 1 must have the advantage.

The Mystery of Optimal Play

Here's the fascinating part: no one knows what the optimal strategy actually is for most patterns in Polyanimals! This includes the AI players in this app - they're using sophisticated heuristics, but they're not playing perfectly.

Computational Complexity

Polyanimals! belongs to a class of games that are PSPACE-complete when generalized. This means:

Why This Matters

This computational complexity explains why:

Open Questions

Some tantalizing unsolved problems:

Nash Equilibrium Analysis

The AI players in Polyanimals! augment their threat-based move analysis with a simplified form of Nash equilibrium evaluation. While not a true game theory application of Nash equilibrium (which would require analyzing the complete strategy space), this approach evaluates whether a move creates a stable advantage or gives the opponent opportunities to gain the upper hand. The AI considers moves that maintain this 'equilibrium' as generally preferable, as they don't allow the opponent to improve their position. This is essentially a heuristic that borrows the concept of strategic stability from Nash equilibrium theory but applies it in a more limited, move-by-move context.

AI Player Configuration

Each AI player has a unique personality defined by configuration parameters that control their strategic behavior. These parameters include randomness levels, threat evaluation weights, search depths, and fork handling preferences. For detailed information about the default configuration values and how to create custom AI personalities, see Nash Configuration Defaults.

Further Reading

Vibe-coded with ChatGPT5/Cursor by Joe Knapp

Contact: jmknapp@gmail.com