World History in Maps Notes

These are notes to accompany the interactive map (below and on its own page) of the last five millennia of nations, empires and dynasties. You can click on the map to navigate geopraphically or use the slider to navigate in time. You can also click the blue links within one of up to four additional tables, depending on the context.

Notes

Original Data

The original data used for this visualisation can be divided into two kinds:

  1. Graphical images based on the maps in Atlas of World History.1
  2. Quantitative data collected by Taagepera.2-5
I noticed that the values used for historical areas in most of the sideboxes on Wikipedia pages are the Taagepera figures.

Collated Data

Map Images

mask.gif

The map images are based on a 1920-by-1080 (full HD) mask GIF: mask.gif

This is the Robinson projection with λ₀ set to 10°, as used by many Wikipedia maps. White areas are land, blue areas are sea and black areas are beyond the projection limits. The value of the red (or green) channel tells you how "landy" a pixel is (from no land at 0x00 to 100% land at 0xFF). The value of the blue channel tells you how "oceany" a pixel is.

Due to the nature of Robinson's projection, the land area represented by a single pixel in the mask is a function of the latitude and the pixel's red value; the longitude is irrelevant. Fully-white pixels near the equator represent 340 km². Those at the poles represent less than 6 km².

year-*.gif

These thirty GIF files are hand-transcribed approximations (using Paint Shop Pro 5!) of the following maps from the Atlas of World History:1

GIF nameYearReferenceSectionGIF image

Each GIF file uses the index of each pixel to assign that section of land to a particular region. Indices 0x00 and 0xFF are reserved for "Ocean" and "Unclaimed" respectively, but other indices are assigned to different regions in different files. For instance, index 0x03 is assigned to the "Roman Empire" in "year-b0200.gif" but to "Andorra" in "year-1848.gif". The mappings are explicitly defined in whim.tsv.

whim.tsv

This tab-separated value text (TSV) file holds the main chronology. Each line represents a single, timed entry. Comments are preceded by a hash "#". The columns are as follows:

  1. Column 1 holds the year or year range. Years are expressed in decimal with a preceding tilde "~" signifying "BCE". Ranges are two years separated by a hyphen "-". For example, "~123-456" represents the year range 123BCE to 456CE.
  2. Column 2 holds the "verb". See the table below for supported verbs.
  3. Columns 3 onwards are parameters to the "verb".
VerbParametersNotesExample
NATIONcode hue name Introduces a new nation, code. hue is an integer representing a hue angle (in degrees) from the HWB colour space. name is the English-language name of the new nation. 873 NATION JE 300 Jersey
REGIONcode parent [hue] name Introduces a new region, code, that is a child of parent. If hue is missing, the new region inherits the hue of its parent. name is the English-language name of the new region. 1250 REGION FI SE 210 Finland
EMPIREcode hue name Introduces a new empire, code. Empires do not have pixels assigned directly to them, but may contain a hierarchy of other empires, nations and regions. name is the English-language name of the empire. 1282 EMPIRE ~AT 165 Habsburg Empire
PARTOFcode parent Changes the parent of a nation/region/empire, code, to a different nation/region/empire, parent. 1066 PARTOF JE GB
DEPARTcode parent Detaches the nation/region/empire, code, from its current parent nation/region/empire, parent. 1990 DEPART LT ~RU
DEFUNCTcode Removes an existing nation/region/empire, code. It must not belong to a hierarchy nor have any remaining pixels. 1990 DEFUNCT DD
NAMEcode name Changes the name of a nation/region/empire, code, to name. name is the English-language name. Names can change through time. 1990 NAME NA Namibia
HUEcode hue Changes the hue of a nation/region/empire, code, to hue. hue is an integer representing a hue angle (in degrees) from the HWB colour space. Hues can change through time. 1635 HUE MN 210
CAPITALcode name latitude longitude Specifies the capital city for nation/region/empire, code. name is the English-language name of the capital city. latitude and longitude are the capital's geographic coordinates expressed as signed decimals. Capitals can change through time. 226 CAPITAL IQ Baghdad 33.3153 44.3661
EMBLEMcode stub Specifies the emblem or flag file for nation/region/empire code. If stub file name does not start with an underscore "_", the image is assumed to be a flag and is rendered without a coloured background oval. See below for a list of emblems. 1940 EMBLEM ~FR fr-1940
APPEARcode stub index Fades in a nation/region, code, based on the pixels with index index in checkpoint GIF file stub. The new nation/region is expected to have no visible pixels on the map before this instruction and does not cover existing nations/regions. The transition occurs between the years specified in the range. If only one year is specified, the range is computed based on that year (longer durations for earlier years). 800 APPEAR HOLY year-0800 1
SNAPcode stub index Like 'APPEAR' but happens instantaneously. The new nation/region is expected to have no visible pixels on the map before this instruction and does not cover existing nations/regions. 1959 SNAP AQ year-1974 255
CONJUREcode stub index Like 'SNAP' but covers at least one existing nation/region. The new nation/region is expected to have no visible pixels on the map before this instruction. Note that this is the least aesthetically pleasing transition. 1945 CONJURE YU year-1950 252
EMERGEcode stub index Grows an existing nation/region, code, until it matches the pixels with index index in checkpoint GIF file stub. The transition occurs between the years specified in the range. 1137-1270 EMERGE ET year-1279 13
EXPANDcode stub index Grows an existing nation/region, code, into pixels with index index in checkpoint GIF file stub. Extant pixels not in stub are not removed. The transition occurs between the years specified in the range. 1783-1812 EXPAND US year-1812 1
SHRINKcode stub index Shrinks an existing nation/region, code, leaving only pixels with index index in checkpoint GIF file stub. Pixels in stub that would result in growth are ignored. The transition occurs between the years specified in the range. 1848-1880 SHRINK ET year-1880 49
ERODEcode Shrinks an existing nation/region, code, to nothing. The transition occurs between the years specified in the range. 1783-1806 ERODE HOLY
MORPHcode stub index Grows/shrinks an existing nation/region, code, until it matches the pixels with index index in checkpoint GIF file stub. The transition occurs between the years specified in the range. 1783-1812 MORPH RU year-1812 16
EVOLVEcode before after evolutions Evolves an existing nation/region, code, from specification before to specification after using the rules listed in evolutions. See below for the format of specifications and evolutions. The transition occurs between the years specified in the range. 1880-1914 EVOLVE BR latest year-1914 already:BR:31,expand:*:31,shrink:BR:34:CO,shrink:BR:161:VE
SPLITbefore after stub index Splits part of an existing nation/region, before, to create a new nation/region, after. The pixels to be split off are those in checkpoint GIF file stub with index index. The new nation/region is expected to have no visible pixels on the map before this instruction. The split occurs between the years specified in the range. If only one year is specified, the range is computed based on that year (longer durations for earlier years). 1888 SPLIT MY BN year-1914 27
FLIPbefore after Flips all pixels of an existing nation/region, before, to another nation/region, after. The transition occurs between the years specified in the range. If only one year is specified, the range is computed based on that year (longer durations for earlier years). 1950 FLIP TIBET CN
EVENTnotes Adds an event to the history. notes is the English-language text with references to empires/nations/regions denoted by their codes enclosed in square brackets, "[]". The special form "[|]" is used to refer to the original name of the code before the preceding 'NAME' or 'DEPART' instruction. 1453 EVENT [|] succeeded by [TR] after fall of Constantinople
CHECKPOINTstub indices ignore Marks a checkpoint GIF file, stub. indices is a comma-separated list of codes corresponding to the pixel indices in the image. ignore is a comma-separated list of codes to ignore during sanity checking. See the source code for more details. ~3000 CHECKPOINT year-b3000 EG,SD,MINOA,PERSIA,GR,INDUS,ANDES,CN2 XX
SKIPyear Fast forwards most pixel transition processing until year year. Only useful during development to speed up response times. ~3000 SKIP 2025
Specifications

Specifications in the 'EVOLVE' instructions (and internally within the code) adhere to the following syntax:

SpecificationNotesExample
empty An empty set of pixels. empty
latest The latest set of pixels for the relevant nation/region code. latest
(x,y) A single pixel at full HD coordinates (x,y). (1090,310)
stub The set of pixels in checkpoint GIF file stub for the relevant nation/region code. year-1812
Evolutions

Evolutions in the 'EVOLVE' instructions (and internally within the code) adhere to the following syntax:

EvolutionNotesExample
already:before:after Matches pixels that are before in the source specification and after in the destination specification. before is a code string. after is either a code string or an index integer, depending on the destination specification. These pixels will be left untouched. already:ELAM:9
expand:before:after[:target] Matches pixels that are before in the source specification and after in the destination specification. before is a code string or "*" meaning any unmatched pixel value. after is an index integer. target is a code string for the desired pixel value. If target is omitted, it is assumed to be the code for the relevant nation/region. Matching pixels will be transitioned to target. expand:*:15
shrink:before:after[:target] Matches pixels that are before in the source specification and after in the destination specification. before is a code string. after is an index integer or "*" meaning any unmatched pixel value. target is a code string for the desired pixel value. If target is omitted, it is assumed to be "XX". Matching pixels will be transitioned to target. shrink:BR:17:BO

Emblems

PNG stubEmblemPNG image

Precomputed Data

It takes close to a minute to compute the values of all two million pixels over the course of five thousand years. To speed up page load, pixel values are precomputed and stored in a simple TSV file. Although many megabytes in uncompressed size, it is far quicker to load these values than recompute them. The TSV file has the following columns:

  1. The integer x-ordinate of the pixel.
  2. The integer y-ordinate of the pixel.
  3. The start year of this period as a floating-point number.
  4. The code of this pixel at the start of the period.
  5. The end year of this period as a floating-point number.
  6. The code of this pixel at the end of the period.

Floating-point numbers are necessary here because pixel transitions are not guaranteed to occur on integer year boundaries due to the nature of the pixel flood algorithms. However, three decimal places is more than enough accuracy.

User Interface

The user interface is fairly minimal. Clicking on the main map canvas generates a pixel coordinate that is converted to latitude and longitude via the Robinson projection. This is used to update the tables:

The year slider changes the current year or "plays" time forwards and/or backwards. When the year "settles" to a specific value, it is used to update the tables:

Clicking on a blue link within a table updates the currently-selected year and/or region. The tables are then updated appropriately.

Animations

A separate web page, whimrec.html, is used to generate individual frames of animation. These can be composited into an animated GIF or a video using gifski or ffmpeg:

These are rendered as sixty second clips at thirty frames per second, by default.

Known Issues and Further Work

Code Issues

Data Issues

Enhancements

References

  1. Haywood, J. (2006). Atlas of World History. Sandcasle Books, ISBN 0-95524787-X
  2. Taagepera, R. (1978). Size and Duration of Empires: Systematics of size. Social Science Research, 7(2), 108-127
  3. Taagepera, R. (1978). Size and Duration of Empires: Systematics of size. Social Science Research, 7(2), 108-127
  4. Taagepera, R. (1978). Size and Duration of Empires: Growth-Decline Curves, 3000 to 600 B.C. Social Science Research, 7(2), 180-196
  5. Taagepera, R. (1979). Size and Duration of Empires: Growth-Decline Curves, 600 B.C. to 600 A.D. Social Science Research, 3(3/4), 115-138
  6. Taagepera, R. (1997). Expansion and Contraction Patterns of Large Polities: Context for Russia. International Studies Quarterly, 41(3), 475-504
  7. Stearns, P. (2001). Encyclopedia of World History. James Clark & Co, ISBN 0-22767968-7