>[!abstract]
>Intransitivity means there is no consistent global ranking (e.g., in rock–paper–scissors, A beats B, B beats C, but C beats A). In almost-intransitive systems, this cycle does not hold universally but emerges statistically: given enough iterations of the dynamics, we observe cyclic dominance or non-hierarchical relations with overwhelming frequency, even though exceptions exist. This happens in situations in decision theory and probability where preferences or comparisons between options are nearly, but not fully, intransitive—meaning that while A is preferred to B and B to C, C is not strictly preferred to A, yet the cycle is weak or probabilistic rather than absolute. This phenomenon arises in contexts such as competitive games, voting systems, and probabilistic choice, where small margins or uncertainty create preference loops. These loops remind me of M. C. Escher's "Upstairs and Downstairs" lithography — in both cases a seemingly-paradoxical loop appears but is only illusory. Almost-intransivity highlights the instability of ranking systems under uncertainty and the challenges of modeling rational choice when preferences approach intransitivity without fully violating transitive order.
Note: almost-intransivity has a different meaning in nonlinear systems and chaos theory, where it refers to systems with more than one equilibrium, and the ability to suddenly move from one to the other with no discernable cause:
>[!quote]
>An almost-intransitive system displays one sort of average behavior for a very long time, fluctuating within certain bounds. Then, for no reason whatsoever, it shifts into a different sort of behavior, still fluctuating but producing a different average. [...] Then, to explain large changes in climate, [the people who design computer models] look for external causes — changes in the earth's orbit around the sun, for example. Yet it takes no great imagination for a climatologist to see that almost-intransivity might well explain why the earth's climate has drifted in and out of long Ice Ages at mysterious, irregular intervals. If so, no physical cause need be found for the timing. The Ice Ages may simply be a byproduct of chaos ([[Gleick, 1987]], p. 170).
## Demonstrating almost-intransitivity in R
In this example, we will explore the concept of almost-transitivity using non-standard dice. Almost-transitivity occurs when we have three options (in this case, dice) such that option A tends to beat option B, option B tends to beat option C, but option C tends to beat option A. “Tends to” comes from the probabilities of winning in pairwise comparisons between the dice (e.g., dice A beats dice B most but not all of the time). This is unlike the game of rock-paper-scissors, which is perfectly intransitive with no statistical emergence (e.g., rock always beats scissors).
Assume three six-sided dice $A, B, C$ with non-standard numbering of the dice as follows:
``` r
A <- c(3, 4, 4, 5, 5, 10)
B <- c(1, 2, 2, 8, 9, 10)
C <- c(1, 4, 5, 7, 7, 8)
```
Let’s define and run a function that generates a $6 \times 6$ matrix comparing the outcomes of any two dice:
``` r
outcome_matrix <- function(d1, d2) {
D <- outer(d1, d2, "-") # Pairwise differences
M <- (D > 0) - (D < 0) # Maps to 1 for win, 0 for tie, -1 for loss
dimnames(M) <- list(d1, d2) # Set row & column names to dice values
M
}
M_AB <- outcome_matrix(A, B) # A vs B
M_BC <- outcome_matrix(B, C) # B vs C
M_CA <- outcome_matrix(C, A) # C vs A
```
Let’s now look at those three matrices which reveal in which combinations of outcomes die A beats die B ($P(A>B)$), die B beats die C ($P(B>C)$), and die C beats die A ($P(C>A)$). The winning probabilities (where the value of the first die in rows is greater than the value of the second die in columns) appear as 1s in the matrices.
``` r
# Convert matrices to data frame for nice Markdown rendering
as_table <- function(M, row_values, col_values) {
df <- as.data.frame(M) # Convert to dataframe
names(df) <- as.character(col_values) # Set column names
rownames(df) <- NULL # Remove row names
df <- cbind(Die = as.character(row_values), df) # Add row names as a column
df
}
# Render die A vs die B
knitr::kable(as_table(M_AB, A, B), format = "pipe")
```
| Die | 1 | 2 | 2 | 8 | 9 | 10 |
|:----|----:|----:|----:|----:|----:|----:|
| 3 | 1 | 1 | 1 | -1 | -1 | -1 |
| 4 | 1 | 1 | 1 | -1 | -1 | -1 |
| 4 | 1 | 1 | 1 | -1 | -1 | -1 |
| 5 | 1 | 1 | 1 | -1 | -1 | -1 |
| 5 | 1 | 1 | 1 | -1 | -1 | -1 |
| 10 | 1 | 1 | 1 | 1 | 1 | 0 |
``` r
# Render die B vs die C
knitr::kable(as_table(M_BC, B, C), format = "pipe")
```
| Die | 1 | 4 | 5 | 7 | 7 | 8 |
|:----|----:|----:|----:|----:|----:|----:|
| 1 | 0 | -1 | -1 | -1 | -1 | -1 |
| 2 | 1 | -1 | -1 | -1 | -1 | -1 |
| 2 | 1 | -1 | -1 | -1 | -1 | -1 |
| 8 | 1 | 1 | 1 | 1 | 1 | 0 |
| 9 | 1 | 1 | 1 | 1 | 1 | 1 |
| 10 | 1 | 1 | 1 | 1 | 1 | 1 |
``` r
# Render die C vs die A
knitr::kable(as_table(M_CA, C, A), format = "pipe")
```
| Die | 3 | 4 | 4 | 5 | 5 | 10 |
|:----|----:|----:|----:|----:|----:|----:|
| 1 | -1 | -1 | -1 | -1 | -1 | -1 |
| 4 | 1 | 0 | 0 | -1 | -1 | -1 |
| 5 | 1 | 1 | 1 | 0 | 0 | -1 |
| 7 | 1 | 1 | 1 | 1 | 1 | -1 |
| 7 | 1 | 1 | 1 | 1 | 1 | -1 |
| 8 | 1 | 1 | 1 | 1 | 1 | -1 |
Let’s define and run a function that computes the win probabilities for each dice pair:
``` r
prob <- function(mat) {
wins <- sum(mat == 1)
ties <- sum(mat == 0)
total <- length(mat)
list(
wins = wins,
total = total,
win_prob = wins / total,
tie_prob = ties / total
)
}
# P(A > B)
cat("P(A > B) =", prob(M_AB)$wins, "/", prob(M_AB)$total, "=", prob(M_AB)$win_prob)
```
P(A > B) = 20 / 36 = 0.5555556
``` r
# P(B > C)
cat("P(B > C) =", prob(M_BC)$wins, "/", prob(M_BC)$total, "=", prob(M_BC)$win_prob)
```
P(B > C) = 19 / 36 = 0.5277778
``` r
# P(C > A)
cat("P(C > A) =", prob(M_CA)$wins, "/", prob(M_CA)$total, "=", prob(M_CA)$win_prob)
```
P(C > A) = 19 / 36 = 0.5277778
We see that die A beats die B with a probability of ~56%, die B beats die C with a probability of ~53%, and die C beats die A with a probability of ~53%. This is an example of almost-transitivity, and the seemingly-paradoxical loop that it creates.
>[!related]
>- **North** (upstream): [[Social choice theory]]
>- **West** (similar): [[Condorcet paradox]] (collective preferences can be cyclic even if individual ones are transitive)
>- **East** (different): [[Perfect transitivity]] (classical rational choice axiom: if A > B and B > C, then A > C)
>- **South** (downstream): [[Preference cycles]] (situations where group or individual preferences loop without a stable ordering)