using latin squares to test video gamesuregina.ca/~meagherk/talk.pdf · using latin squares to test...

94
Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of Regina Regina, Saskatchewan, Canada

Upload: others

Post on 11-Oct-2020

9 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Using Latin Squares to Test Video Games

Karen Meagher

Department of Mathematics and StatisticsUniversity of Regina

Regina, Saskatchewan, Canada

Page 2: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

A Dream Job

You are a video game tester and you have to test a retroversion of PacMan.

Page 3: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

A Dream Job

You are a video game tester and you have to test a retroversion of PacMan.

Page 4: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.

If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 5: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 6: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 7: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 8: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 9: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Why Test?

The original version of PacMan was released with an error.If you get to level 256 this is what you see,

They only allocated 8 bits ofmemory for the level counter.

In binary the largest 8 bitnumber is

11111111

which is equal to

27+26+25+24+23+22+21+20 = 255.

Page 10: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 11: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 12: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed:

Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 13: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast

2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 14: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 15: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal

Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 16: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue

Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 17: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 18: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze:

α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 19: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ

4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 20: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 21: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana

Orange Cherries

You need to test all of these parameters, so you make a chart

Page 22: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange

Cherries

You need to test all of these parameters, so you make a chart

Page 23: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 24: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

What to test

There are several “parameters” in the game.

1. PacMan’s speed: Slow, Medium, Fast2. Ghosts’ image:

Normal Blue Flashing

3. Maze: α, β, γ4. Fruit on screen:

Banana Orange Cherries

You need to test all of these parameters, so you make a chart

Page 25: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 26: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 27: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 28: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β

......

......

...

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 29: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 30: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 31: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Your Chart

Speed Ghosts Maze Type Fruit

test 1 slow α

test 2 slow α

test 3 slow α

test 4 slow β

test 5 slow β

test 6 slow β...

......

......

There are 3↑

speed

× 3↑

ghost

× 3↑

maze

× 3↑

fruit

= 81 different combinations!

Playing PacMan will become really boring before you finish.

Page 32: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 33: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 34: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

→ test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 35: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

→ test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 36: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

→ test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 37: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

→ test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 38: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

→ test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 39: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

→ test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 40: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

→ test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 41: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

→ test 3: slow γ

test 4: medium β

test 5: medium γ

test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 42: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Karen’s Solution to get to an Early Lunch

Speed Ghosts Maze Fruit

test 1: slow α

test 2: slow β

test 3: slow γ

test 4: medium β

test 5: medium γ

→ test 6: medium α

test 7: fast γ

test 8: fast α

test 9: fast β

This will test all nine possible pairs for any two parameters.

Page 43: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 44: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 45: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.

This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 46: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 47: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 48: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares

The first three columns can be written as a square:

Slow α β γMedium β γ αFast γ α β

Each symbol occurs once in every row and column.This is called a Latin square.

The fourth column can also be written as a square:

Slow

Medium

Fast

Page 49: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Greco-Latin Squares

We can put these to Latin squares together to make aGreco-Latin square.

Slow α, β, γ,

Medium β, γ, α,

Fast γ, α, β,

I get every maze/fruit combintation exactly once!

Page 50: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Greco-Latin Squares

We can put these to Latin squares together to make aGreco-Latin square.

Slow α, β, γ,

Medium β, γ, α,

Fast γ, α, β,

I get every maze/fruit combintation exactly once!

Page 51: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Greco-Latin Squares

We can put these to Latin squares together to make aGreco-Latin square.

Slow α, β, γ,

Medium β, γ, α,

Fast γ, α, β,

I get every maze/fruit combintation exactly once!

Page 52: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Everyone loves Latin Squares!

Sudoko games are 9× 9 Latin squares.

Page 53: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

History

This was a “recreatational” math problem from 1725:

Take all aces, kings, queens and jacks from astandard deck of cards, and arrange them in a 4x4grid such that each row and each column contained allfour suits as well as one of each face value.

Page 54: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

History

This was a “recreatational” math problem from 1725:

Take all aces, kings, queens and jacks from astandard deck of cards,

and arrange them in a 4x4grid such that each row and each column contained allfour suits as well as one of each face value.

Page 55: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

History

This was a “recreatational” math problem from 1725:

Take all aces, kings, queens and jacks from astandard deck of cards, and arrange them in a 4x4grid

such that each row and each column contained allfour suits as well as one of each face value.

Page 56: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

History

This was a “recreatational” math problem from 1725:

Take all aces, kings, queens and jacks from astandard deck of cards, and arrange them in a 4x4grid such that each row and each column contained allfour suits as well as one of each face value.

Page 57: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

History

This was a “recreatational” math problem from 1725:

Take all aces, kings, queens and jacks from astandard deck of cards, and arrange them in a 4x4grid such that each row and each column contained allfour suits as well as one of each face value.

Page 58: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares are good for “art”

This is a 7× 7 Greco-Latin square (it is a baby blanket I madefor my Ph.D. supervisor’s baby).

Page 59: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares are good for “art”

This is a 7× 7 Greco-Latin square

(it is a baby blanket I madefor my Ph.D. supervisor’s baby).

Page 60: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Latin Squares are good for “art”

This is a 7× 7 Greco-Latin square (it is a baby blanket I madefor my Ph.D. supervisor’s baby).

Page 61: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 62: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 63: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 64: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 65: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 66: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

36 Officers Problem

(from Wikipedia) The thirty-six officers problem is amathematical puzzle proposed by Leonhard Euler in 1782.

The problem asks if it is possible to arrange sixregiments consisting of six officers each of differentranks in a 6× 6 square so that no rank or regiment willbe repeated in any row or column.

This problem is asking for a6× 6 Latin square

In 1901 it was shown that it isnot possible to make a 6× 6Greco-Latin square!

Page 67: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

10× 10 Latin Square

For a long time it was unknown if it was possible to build a10× 10 Greco-Latin square.

Page 68: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

10× 10 Latin Square

For a long time it was unknown if it was possible to build a10× 10 Greco-Latin square.

Page 69: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

10× 10 Latin Square

For a long time it was unknown if it was possible to build a10× 10 Greco-Latin square.

Page 70: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

A computer in 1959?

This is the type of computerthat was used to find the first10× 10 Greco-Latin square.

Page 71: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

A computer in 1959?

This is the type of computerthat was used to find the first10× 10 Greco-Latin square.

Page 72: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 73: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 74: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 75: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n

2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 76: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 1

3 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 77: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2

...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 78: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 79: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number.

It is easy, if you have a finite field!

Page 80: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We look for ways to build them:

I can build an n × n Latin square for any n:

1 2 3 . . . n − 1 n2 3 4 . . . n 13 4 5 . . . 1 2...n 1 2 . . . n − 2 n − 1

I can also build an n × n Greco-Latin square if n is the power ofa prime number. It is easy, if you have a finite field!

Page 81: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We try to count Latin squares:

There are two or order 2:

1 22 1

2 11 2

Order Number3 124 5765 1612806 812 851 200

Page 82: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We try to count Latin squares:

There are two or order 2:

1 22 1

2 11 2

Order Number3 124 5765 1612806 812 851 200

Page 83: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We try to count Latin squares:

There are two or order 2:

1 22 1

2 11 2

Order Number3 124 5765 1612806 812 851 200

Page 84: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We try to count Latin squares:

There are two or order 2:

1 22 1

2 11 2

Order Number3 124 5765 1612806 812 851 200

Page 85: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We classify Latin squares:

1 2 3 42 3 4 13 4 1 24 1 2 3

1 4 2 33 2 4 14 1 3 22 3 1 4

no transversal transversal

Page 86: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We classify Latin squares:

1 2 3 42 3 4 13 4 1 24 1 2 3

1 4 2 33 2 4 14 1 3 22 3 1 4

no transversal transversal

Page 87: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We classify Latin squares:

1 2 3 42 3 4 13 4 1 24 1 2 3

1 4 2 33 2 4 14 1 3 22 3 1 4

no transversal transversal

Page 88: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We classify Latin squares:

1 2 3 42 3 4 13 4 1 24 1 2 3

1 4 2 33 2 4 14 1 3 22 3 1 4

no transversal transversal

Page 89: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Open Problems with Latin Squares

We classify Latin squares:

1 2 3 42 3 4 13 4 1 24 1 2 3

1 4 2 33 2 4 14 1 3 22 3 1 4

no transversal transversal

Page 90: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Last Slide

Still LOTS of open problems with Latin squares andGraeco-Latin squares and experimental design.

I Build better test sets:I test sets that avoid combinations;I tests sets that balance other aspects;I tests sets that test only give pairs of the parameters.

I Latin Squares are important in other aspects of math:I finite fields—these are important for cyptography;I decompositions of graphs;I extremal combinatorics.

Page 91: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Last Slide

Still LOTS of open problems with Latin squares andGraeco-Latin squares and experimental design.

I Build better test sets:

I test sets that avoid combinations;I tests sets that balance other aspects;I tests sets that test only give pairs of the parameters.

I Latin Squares are important in other aspects of math:I finite fields—these are important for cyptography;I decompositions of graphs;I extremal combinatorics.

Page 92: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Last Slide

Still LOTS of open problems with Latin squares andGraeco-Latin squares and experimental design.

I Build better test sets:I test sets that avoid combinations;I tests sets that balance other aspects;I tests sets that test only give pairs of the parameters.

I Latin Squares are important in other aspects of math:I finite fields—these are important for cyptography;I decompositions of graphs;I extremal combinatorics.

Page 93: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Last Slide

Still LOTS of open problems with Latin squares andGraeco-Latin squares and experimental design.

I Build better test sets:I test sets that avoid combinations;I tests sets that balance other aspects;I tests sets that test only give pairs of the parameters.

I Latin Squares are important in other aspects of math:

I finite fields—these are important for cyptography;I decompositions of graphs;I extremal combinatorics.

Page 94: Using Latin Squares to Test Video Gamesuregina.ca/~meagherk/talk.pdf · Using Latin Squares to Test Video Games Karen Meagher Department of Mathematics and Statistics University of

Last Slide

Still LOTS of open problems with Latin squares andGraeco-Latin squares and experimental design.

I Build better test sets:I test sets that avoid combinations;I tests sets that balance other aspects;I tests sets that test only give pairs of the parameters.

I Latin Squares are important in other aspects of math:I finite fields—these are important for cyptography;I decompositions of graphs;I extremal combinatorics.