Page 1
S I L E S I A N U N I V E R S I T Y O F T E C H N O L O G Y P U B L I S H I N G H O U S E
SCIENTIFIC PAPERS OF THE SILESIAN UNIVERSITY OF TECHNOLOGY 2020
ORGANISATION AND MANAGEMENT SERIES NO. 144
http://dx.doi.org/10.29119/1641-3466.2020.144.16 https://www.polsl.pl/Wydzialy/ROZ/Strony/Zeszytynaukowe.aspx
APPLYING CHAOS THEORY TO RISK MANAGEMENT 1
IN A GAME OF CHANCE 2
Ireneusz J. JÓŹWIAK1*, Aleksander MARIAŃSKI2 , Jan SWITANA3, 3
Michał SZCZEPANIK4 4
1 Wroclaw University of Science and Technology, Faculty of Computer Science and Management, Wrocław; 5 [email protected] , ORCID: 0000-0002-2160-7077 6
2 Wroclaw University of Science and Technology, Faculty of Computer Science and Management, Wrocław; 7 [email protected] , ORCID: 0000-0003-0638-196X 8
3 Wroclaw University of Science and Technology, Faculty of Mechanics, Wrocław; [email protected] 9 4 Wroclaw University of Science and Technology, Faculty of Computer Science and Management, Wrocław; 10
[email protected] , ORCID: 0000-0001-9801-992X 11 * Correspondence author 12
Purpose: The purpose of the paper is to illustrate the usage of techniques known from chaos 13
theory to analyze the risk 14
Design/methodology/approach: In this case the objects of application are winnings graphs of 15
different poker players. Two types of players are presented; winning players (those with positive 16
expected value) and breaking even players (expected value close to zero). 17
Findings: Charts were analyzed with a fractal dimension calculated with the box method. 18
Originality/value: Relation between fractal dimension and Hurst exponent is shown. 19
Relation between risk in sense of chaos theory and players’ long-term winning is also described. 20
Further applications of chaos theory to analyze the risk in games of chance are also proposed. 21
Keywords: risk analysis, game theory, hazard game, chaos theory, fractal dimension. 22
Category of the paper: Research paper. 23
1. Introduction 24
Applying chaos theory to risk management is a new trend in game theory. However, 25
it has already developed so far that no analyst can ignore the new paradigm. The strand started 26
by Edgar Peters (Peters, 1994), motivated the application of this new approach to market 27
analysis, and Ehlers (Ehlers, 2005) and Borowski (Borowski, 2019) finally suggested practical 28
application of fractals in FRAMA (fractal adaptive moving average). It is used by stock analysts 29
to find signs of upcoming upswings or downswings. 30
Page 2
196 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
For many people poker is considered as a pure game of luck, where the only payee is the 31
organizer of the game (e.g. casino) due to rake. However, there are others who indicate that the 32
casino is not the only winner. They claim that choosing a proper strategy concludes long-term 33
winnings being equal to other player’s loss. According to this definition poker may be 34
considered as gambling. Risk in poker can be minimized by applying a proper strategy. 35
Usually the strategy is based on knowledge about opponents’ style, manners, behaviour etc. 36
So far, risk management based on chaos theory usually referred to capital markets and stock 37
exchange. In this paper another application is shown. Chaos theory can be used to analyse risk 38
of poker play of different players. 39
2. Chaos theory 40
Chaos theory describes phenomena, where little changes of parameters cause large effects. 41
The equations are very responsive to these changes. Commonly such chaotic behaviour of 42
systems is called the butterfly effect. Little change of starting conditions may cause huge 43
changes of its influence in long-term scale. Good illustration of this effect can be Edwards 44
Lorenz question: "Predictability: does the flap of a butterfly's wings in Brazil set off a tornado 45
in Texas?” (Alejandrino, 2011). 46
Weather analysis gave a good example of importance of chaos theory in science. As shown 47
in (Kalnay, 2003) non-linear differential equations are used to weather forecasting. 48
These equations are being solved by supercomputers. As Lorenz proved (Lorenz, 1963) in 1963 49
exact weather calculation is impossible. It was also shown that equation which describes 50
weather also tends to show chaotic behaviour. This means that in long-term we can expect 51
randomness. Therefore, we can expect a correct forecast for the next day, however, 52
it is impossible to predict exact values of temperature or pressure for the upcoming month. 53
The chaos theory also describes geometrical objects called fractals. Fractals are self-similar 54
or infinitely subtle objects (Kudrewicz, 2007). In this paper we focus on self-similar objects 55
which means that a subset of such set is similar to the entire set. More specific description can 56
be found in (Falconer, 2003) and (Kudrewicz, 2007). Image 1 shows an example of a self-57
similar fractal. 58
59
Figure 1. Banach fractal (Fiałkowski, 2006). 60
Page 3
Applying chaos theory to risk management in a game of chance 197
As Peters showed in (Peters, 1994) graphs in capital market also tend to become self-similar. 61
Let us imagine that a three dimensional sheet of paper has no thickness. Assuming that, 62
we can consider it as a two-dimensional object which can be described by means of Euclidean 63
geometry. If we crumple this paper sheet into a paper ball it does not become a three-64
dimensional object but it is also hard to consider it as two dimensional one. 65
In such case chaos theory comes up with a fragmentary dimension or fractal dimension, 66
which cannot be described with an integer value. Describing crumpled sheet of paper with 67
Euclidean geometry is a difficult task, even for a computer program. Fractal dimension is much 68
help in this case. It helps us describe how do objects fill the space. 69
Usually an object exists in a space which has higher dimension than the object itself. 70
Crumpled paper is a good example, which can be considered three dimensional but obviously 71
does not fill the entire three-dimensional space. Likewise, a graph of a function is called two 72
dimensional but also does not fill the entire two-dimensional space. The same can be said about 73
a square or circle. 74
Mandelbrot (Mandelbrot, 1982) gives an example of limited usage of Euclidean geometry 75
when calculating length of Great Britain coastline. He claims that it is impossible to calculate 76
the exact length of the coastline. The accuracy of the calculation will always depend on the 77
length of the measure we use. We can imagine trying to measure the coastline using two 78
different measures; one kilometre long and one meter long. Obviously, using longer measure 79
will make us ignore many gaps and bays in the coastline. However, they will be included when 80
using shorter measure. This leads to the conclusion that the shorter measure we use the more 81
precise value we gain. Therefore, the length of a coastline depends on the length of used 82
measure. Mandelbrot proposed the fractal dimension to calculate Great Britain coastline. 83
There are many ways to calculate the fractal dimension. One of them is the box method. 84
Algorithm of calculating the fractal dimension with box method is the following. Firstly, 85
we take the starting size of the box and denote it as „r”. Secondly, we draw in the space a net 86
of boxes sized „r”. Then we count the boxes which contain any part of examined object and 87
obtain the number N(r). Then we decrease the size of the box linearly or exceptionally 88
depending on the chosen method (Weisstein, 2018), (Weisstein, 2019) and obtain consecutive 89
numbers „r” and N(r). We draw the function y = log (N(r)) as function from log(1/r). 90
We designate the line of regression. We measure the gradient of the regression line obtaining 91
the fractal dimension. The formula for the box dimension is the following: 92
𝐷 =𝑙𝑜𝑔(𝑁(𝑟))
𝑙𝑜𝑔(1𝑟)
(1)
This algorithm was elaborated basing on (Peters, 1994), (Weisstein, 2019) and (Sutherland, 93
2002). 94
95
Page 4
198 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
Similarly we can calculate the fractal dimension with the circle method obtaining dimension 96
of Bouligand-Minkowski described in (Weisstein, 2019) and (Sutherland, 2002). According to 97
measures (Peters, 1994) fractal dimension of Great Britain coastline is 1.3. In the case of 98
Norway it is 1.52. 99
Fractal dimension describes how torn the object is against a space one dimension higher. 100
Having that said, we can claim that Norway in comparison to Great Britain has got much more 101
cragged coastline. From (Peters, 1994) we know that the more cragged the coastline is, 102
the closer to 2 its fractal dimension is. 103
In probability theory it is common to colligate risk with variance. The chaos theory does 104
not negate this idea but introduces a new approach to problems connected with risk. Following 105
Markowitz (Markowitz, 1952) we can talk about higher risk on a stock market when we observe 106
higher variability on stock prices. This variability can be described with standard aberration. 107
However, we can use standard aberration only if we have got to do with a random system. 108
Studies described in (Peters, 1994) showed that risk calculated with standard aberration often 109
does not give the proper sense of risk in terms of economy. 110
Figure 2 illustrates the example found in (Peters, 1994) showing the difference between 111
understanding the risk in terms of chaos theory and probability theory. 112
113
Figure 2. Rates of return S1 and S2 (Peters, 1994). 114
For stocks S1 and S2 the standard aberration is respectively 1.86 and 1.87; almost equal in 115
both cases. S1 fractal dimension is 1.42 and in S2 it is 1.13 (Peters, 1994). In terms of economy 116
Lower risk is observed when investing in S2. Statistical analysis proves that the risk is equal in 117
both cases, however the fractal dimension points unambiguously to S1 as the stock with higher 118
risk. 119
In fractal analysis Hurst exponent is used very commonly. The formula which enables us to 120
calculate the Hurst exponent is given in (Peters, 1994). It has a key meaning in designating the 121
risk from a given graph. Strict relation between fractal dimension and Hurst exponent has been 122
shown in (Peters, 1994) and is given by the formula: 123
𝐻 = 2 − 𝐷 (2)
Therefore, in this paper we focus on evaluating the risk only with the fractal dimension. 124
1 2 3 4 5 6
-4
-2
0
2
4
6
8
S1
S2
Page 5
Applying chaos theory to risk management in a game of chance 199
3. Games of chance 125
3.1. Definition of a game of chance 126
In this paper we define game of chance following (Act of 2009) as a random slot machine 127
game or mutual bets, where more or less the result of the game is random. Many people do 128
claim that such games with random factor do not always have to be gambling games. 129
In such games, having proper skills, it is possible to obtain expected value above zero. 130
These people use ‘gambling’ expression to describe games where independently to players’ 131
skills their expected value is always below zero. 132
Good example of such a game can be roulette. Let us assume that player bets S on a field 133
which has probability of hitting k/n. For standard 37 roulette fields the expected value is – 134
S/37 for S money put at risk. It happens because when the ball hits our filed we gain S*n/k and 135
when it misses, we get zero. This makes the casinos expected value positive. 136
Poker can be an example of a game where expected value depends on players’ skills. 137
The game itself is too complex to prove it formally. Therefore a hypothetical game of luck 138
which is generally based on the same idea as poker is introduced. 139
Let us imagine a game for two players who draw randomly 0 or 1 and play using the 140
following rules: 141
1. Each player draws a number independently. Both can have the same number. Probability 142
of each number is 0.5. 143
2. Each player can add 1 PLN to the pot. The players do not know of the other player’s 144
actions. 145
3. If one player added 1 PLN to the pot and the other did not, the one who added wins the 146
pot (1 PLN). 147
4. If both players added 1 PLN the winner is the one with higher number and they take the 148
pot (2 PLN). If the numbers are equal they split the pot (1 PLN for each of them). 149
5. If none of them addend 1 PLN next turn is played (go back to 1). 150
Let us assume that player A has got the following strategy; if I draw 1, I add to the pot, 151
if I draw 0, I don’t. Player B has any other strategy which can be expressed this way; 152
if I draw 1, I add in x% of cases; if I draw 0, I add in y% of cases. Situation where player drew 153
0 and adds to the pot will be called a bluff. 154
Let us show that the expected value of player A is: 155
𝐸𝑉(𝑝𝑙𝑎𝑦𝑒𝑟𝐴) = ½ ∗ ½ ∗ 𝑥 ∗ 0 +½ ∗½ ∗ (1 − 𝑥) ∗ 0 +½ ∗½ ∗ 𝑦 ∗ 1 +½ ∗½ ∗ (1 − 𝑦) ∗ 0 ¼𝑦
(3)
156
Page 6
200 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
The first two lines of (3) describe situation where both players drew 1. In the first line player 157
B adds to the pot (with probability x) and does not add (with probability 1-x). Third and fourth 158
lines describe the situation where player A drew 1 and player B drew zero. Third line describes 159
those cases where player B bluffs, and fourth line when they do not add 1 PLN to the pot. 160
Situation where player A does not add 1 PLN does not affect their expected value. 161
In conclusion, player A expected value is equal or higher than zero, regardless of player’s 162
B strategy. The above game can be complicated and optimal strategies for those games can be 163
searched. 164
3.2. Mathematical model of a game of chance 165
Game of chance is a game in terms of game theory. It consists of n players. In a game of 166
chance we can talk about rounds. A single round in roulette will be a single spin and in poker it 167
will be one hand. Each player takes part in k rounds (this number can be different for different 168
players). During each round player takes m actions. Each action has its specific structure 169
depending on the kind of game. 170
Taking action influences players result in the relevant round. Summary score will give us 171
players result in the entire game. In each round a player can bring into the round some amount 172
of money denoted w. Actions taken by a player with probability pi will make them earn (or lose) 173
zi, of money, where i=1,2,…,m depends on what kind of game they play. Therefore, we can 174
conclude that the expected value of their winnings in each round is given by the formula: 175
𝐸𝑉 =∑𝑝𝑖𝑧𝑖
𝑚
𝑖=1
(4)
Actions taken by player influence the partial benefit in a relevant round. However, expected 176
value of an action, especially in poker, is very difficult to describe with a mathematical formula. 177
Therefore, this problem is being left unfinished. 178
Restrictions are also parts of the model. In each round potential maximal loss (min(zi)) 179
cannot be higher than absolute value of w. Without this restriction it would be possible to obtain 180
a negative balance. Games of chance are usually prepaid, therefore the above restriction is 181
justified. 182
Sum of all pi from 1 to m must be 1. 183
Expected value of winnings of all players is negative in most games of chance. Absolute 184
value of this expected value will be called rake. It is the expected value of casinos winnings in 185
a relevant round. Some players however, depending on their strategy of play, can have positive 186
expected value of winnings. This was shown in subchapter 3.1. This phenomenon is the subject 187
of discussion whether poker should be classified as gambling. 188
Analysis of the general mathematical model of a game of chance leads us to the conclusion 189
that the casino has always a positive expected value of winnings. Players cannot win playing 190
against the casino. The only chance for a player to achieve a positive result of the game is by 191
playing out their opponents which requires a proper strategy. 192
Page 7
Applying chaos theory to risk management in a game of chance 201
3.3. 10 player No limit Texas Hold’em Cash Game description 193
Texas Hold’em is a game of chance where having a proper strategy should guarantee higher 194
expected value of winnings than the opponents’. It is played at the table; usually ten players 195
take part in the game. One of them is marked as the dealer. Each round the dealer mark moves 196
to the next player clockwise. Player sitting left to the dealer is marked as small blind. The player 197
sitting left to the small blind is marked as the big blind. 198
At the beginning of each round the dealer deals two cards (from a standard 52 cards deck) 199
face down to each player (to the dealer as well). These two cards are called a players starting 200
hand. After dealing the cards and betting blind bets the round begins. Blind bets must be bet by 201
small and big blind. Usually small blind is equal to half of the big blind, e.g.1 PLN/2 PLN. 202
The round can be divided into four parts called: preflop, flop, turn, river. In each part 203
a player can take the following action: pass (fold), call a bet (call), wait (check) or raise the bet 204
(raise). A player takes action after all players before took action. In case of raise a player must 205
tell the exact value of the raise (limited by the amount of money they have at the table). 206
In the preflop phase player left to the big blinds is the first to act. In other phases first player 207
left to the dealer who has not folded, is the first to act. The round can be finished in any case 208
when all players except one have folded. Phase finishes when all player to act called the bets of 209
the other players or folded. 210
Player wins the round when all players except them folded or their cards setup is best among 211
other players left in the round. Before the flop, three cards are dealt cross the middle of the table 212
face up. Before turn and river another card is dealt into the table face up bringing its total count 213
to five. These are the community cards any player can use (combining them with their starting 214
cards) to make the best five card poker hand. A player loses every time if at least one player has 215
a better five card setup. If two or more players have the best combination the pot is divided 216
between them equally. 217
There is a restriction in Texas Hold’em. A player cannot check when any other player before 218
them raised. In practice this constrains to the situations where someone raised or the player is 219
in the preflop phase and has not called the big blind bet. Player cannot raise more than the 220
amount of their money at the table. If a player raises for all their money and other players have 221
more money than them, we consider a special case where a side pot is being created 222
(Rules, 2019). After folding no action can be taken during the round by the player who folded. 223
Of course, they lose the money they had brought into the pot. Other special restrictions in Texas 224
Hold’em are described in (Sklansky, 2005). 225
Player can bring into the pot certain amount of money using raise and call actions. 226
Depending on taken actions during the round they increase or decrease their expected value of 227
winnings. It is a game with incomplete probabilistic information, so the player needs to predict 228
other player’s range of starting hands, basing on action they take. 229
Page 8
202 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
In Texas Hold’em we can very rarely be sure of winding or looping a hand. Winning or 230
looping almost always depends on other players’ cards. However, we can predict (with some 231
probability) range of their cards according to action they took this round and knowledge about 232
history of their play. Thanks to this we can assume some range of opponent’s cards and evaluate 233
worthwhileness of specific actions we can take. The above is a base for building Texas Hold’em 234
strategies described in (Become, 2019). 235
3.4. Partial mathematical model of 10 player No Limit Texas Hold’em Cash Game 236
Texas Hold’em is a game of chance. Number of players, in this case is n = 10. Each player 237
takes part in any number of rounds k. A player can be earlier forbidden to play if they lose all 238
their money brought to the game. 239
The number of taken actions during a single round is limited only by the size of players 240
stack (amount of their money at the table). Impossibility to act after folding is also an important 241
restriction. When player calls or raises they can bring to the pot no more money than they have 242
left at the table. 243
Determining the influence of a certain action to the expected value is a mathematically 244
difficult problem. However, we can estimate expected value of winning in a round by predicting 245
the range of starting cards of our opponents and calculating worthwhileness of each action. 246
For example let us imagine a situation where player holds third best starting hand QQ 247
(pair of queens) in preflop phase. The player has got 800 PLN left (200 PLN was already 248
invested in the pot). The only opponent raises for all their money which is 1,000 PLN. 249
Therefore, there is 1,200 PLN in the pot. Player judged the range of opponent’s cards to only 250
better hands than theirs (pair of kings or aces). Using (Become, 2019), the player calculated 251
that probability of winning is about 18%. Therefore the expected value of calling can be 252
calculated: 253
𝐸𝑉 = 0,18 ∗ 1200 − 0,82 ∗ 800 = −440 254
Having that said, we can see that calling that bet is absolutely unjustified. However, 255
let us imagine the same situation but this time the player assumes wider range of cards; not only 256
pair of aces or king but also pair of queens, pair of jacks, and AK (ace and king). This range 257
gives them 47% probability of winning the round (Become, 2019). The opponent will still win 258
more often (53%) (Become, 2019), but the expected value of calling this bet will be: 259
𝐸𝑉 = 0,47 ∗ 1200 − 0,53 ∗ 800 = 140 260
As we can see the expected value of calling is positive. That means that although the 261
opponent is still more likely to win this hand, calling this bet is the correct action. 262
It is also worth mentioning that the estimated expected value is usually measured basing on 263
the history of the game. Main assumption here is that players change their style of play very 264
little in long-term and the strategy of the player remains the same... It is being assumed that 265
a good player wins equality of ten big blinds every hundred hands. Therefore expected value of 266
such player in a single round is 0.1 of a big blind. For example, when playing 1 PLN/2 PLN 267
blinds, the expected value is 0.2 PLN. 268
Page 9
Applying chaos theory to risk management in a game of chance 203
It is also important to mention that a player needs to play against strategies which are losing 269
against their strategy. It was explained in subchapter 3.2. The Casino always has positive 270
expected value. In this case the casino’s expected value is the rake taken from every pot. 271
Concluding, No Limit Texas Hold'em is a game of chance which fits the assumptions made 272
in subchapter 3.2. Full mathematical model of poker game is very complex. What is more, 273
finding a winning strategy for such a complicated model is almost impossible. 274
3.5. Description of types of players depending on their benefits 275
Specific strategy of play depending on other player’s strategies can result in possible 276
winnings or loses. We can divide players into three groups basing on their benefits: 277
1. Winning – having positive expected value. 278
2. Losing – having negative expected value. 279
3. Breaking-even – their expected value is close to zero. 280
It is crucial to remember that the rake taken by the casino should be added to the expected 281
value. Some casinos like Full Tilt Poker offer partial return of the rake known as rake-back. 282
Thanks to this fact breaking-even players can also benefit from their play. Those players usually 283
characterize themselves with very risky play on the border of profitability. 284
To judge to which group specific player belongs we can do mathematical analysis of their 285
and their opponents’ strategies. However, remembering that the opponents switch very often 286
and mathematical model of the game is very complex, it appears almost impossible to conduct 287
such strict mathematical analysis. Example of the solution to this problem is the assumption 288
that opponents use one of the popular strategies (described in (Become, 2019)). Next we should 289
implement poker Simulator and input players strategy and their opponents’ strategies. 290
Then after running the Simulator we can see how our strategy copes with popular strategies. 291
This approach can be named empirical estimation of the expected value. 292
The approach described above has got few important disadvantages. It completely ignores 293
opponents’ alternation or the fact that they can make different decisions according to so-called 294
table image of the player. More commonly used approach is the analysis of historical data about 295
the hands that a player already played. Analysing respectively big sample of such data we draw 296
the graph of winnings of the player. Then we analyse the trend of the player; if it is ascending 297
then we can tell that it is a winning player. If the trend is descending then, of course, we observe 298
a losing player. 299
Examples of graphs of two players; winning player and breaking-even player (as described 300
above) are shown in figures 3 and 4. 301
The strategy is being entered into the program which plays instead of the player, often on 302
many tables simultaneously. We need to mention here that usage of such programs is forbidden 303
in many casinos. To achieve a successful strategy we need to model behaviour of our opponents. 304
Proposal of modelling such parameters as probability of folding and probability of bluffing was 305
described in detail in (Salim, and Rohwer, 2005). Finally, basing on conducted strategy tests, 306
we can reason if our strategy is winning after long time of play by the robot. 307
Page 10
204 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
308
Figure 3. Winnings graph of breaking-even player (Forum, 2019). 309
310
Figure 4. Winnings graph of winning player (Forum, 2019). 311
Other popular method of testing strategies is using programs which play poker instead of 312
the player. It is possible because there are many casinos where anybody with a computer with 313
access to Internet can play. 314
Concluding, we can use different meanings of expected value of winnings in poker. 315
There are many ways to designate it empirically. 316
3.6. Risk in poker 317
Risk in poker is a term which is ambiguous in respect to economy or mathematics. Therefore, 318
measuring risk in poker is not an easy task. Every action in each round is saddled with risk. 319
Even possessing better hand in one phase of the round, the situation may turn around in the very 320
next phase. Risk in poker can be measured in a sense of a single action, single round or whole 321
set of rounds which were played. 322
323
Page 11
Applying chaos theory to risk management in a game of chance 205
Risk in context of a single action from scenarios shown in subchapter 3.4 can be calculated 324
by the formula for the standard aberration Std(X): 325
𝑆𝑡𝑑(𝑋) = √∑(𝑥𝑖 − 𝐸(𝑋))2𝑝(𝑥𝑖) (5)
where: 326
E(X) – expected value of random variables X, 327
p(xi) – probability of xi random variable, for i = 1, 2, 3, …, n. 328
329
Therefore risk of the first action described in subchapter 3.4 is 768 PLN. The risk of the 330
second action is 998 PLN. 331
Speaking about risk in poker it is impossible to ignore the sill of proper bankroll 332
management which enables players to minimize the risk. Let us imagine a situation shown in 333
subchapter 3.4 but with ten times smaller stakes. Then we can win 120 PLN or lose 80 PLN. 334
Let us assume that we came cross that situation ten times. Then, the expected value of the first 335
case is still -440 PLN and 140 PLN in the second case. However, the standard aberration 336
changes noticeably. After calculations from formula given before, standard aberration is about 337
243 PLN in the first case and about 316 PLN in the second case. We conclude that proper 338
bankroll management can give us the same expected value while the risk is noticeably 339
minimized. Unfortunately it affects time of gaining the same profits which in this case is ten 340
times longer. 341
Risk analysis basing on historical data of player hands is an interesting task to consider. 342
Now, we mainly come across empirical analyses based on other players’ experiences like in 343
(Become, 2019) and (Forum, 2019). Risk analysis there is often based on intuitive 344
understanding of the problem and it is common that advice given there has no support in 345
mathematics. Therefore, application of new methods of risk analysis to achieve results is 346
mathematically correct. 347
4. Risk management in a game of luck 348
4.1. Transforming graphs into images which allow fractal risk analysis 349
Graphs given by the poker analytic programs usually contain other data which disables 350
instant fractal analysis. Poker Tracker is an example of such program (Poker tracker, 2019). 351
Therefore we need to erase that data to prevent them from disturbing the results of fractal 352
analysis. Our goal is having black graph on a white background. 353
354
Page 12
206 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
Each of the graphs contains data about axis markings. In case of winnings graphs on one 355
axis there are winnings measured with set currency or big blinds multiplications. On the other 356
axis is the number of hands played till the time of generating the graph. Additionally, 357
some programs add special net on the graph which helps to read values from particular rounds. 358
A text box with information about the graph is also very common. All the information is 359
illustrated on images 3 and 4. 360
We usually come across graphs which colour is different than the colour of the axes. 361
If we have uncompressed image (e.g. *.png or *.gif) then it is enough to change every colour 362
to white (except the graph colour, of course) and then change the graph colour to white. 363
If we have a compressed image (e.g. *.jpg) then the colour of the graph is not flat. Sometimes 364
it even gets too similar to axes colour. Then we need to use more advanced software like Gimp 365
or Adobe Photoshop. We use the „magic wand" tool (Adobe Creative Team, 2005) to select and 366
cut the graph of our interest. 367
This way we obtain black graph on white background without any redundant hypes. 368
4.2. Using program ‘Fractalyse’ to measure fractal dimension 369
The program Fractalyse (Fractalyse, 2019) is used for broadly understood image fractal 370
analysis. It lets us, inter alia, calculate the fractal dimension of an image. It uses linear or 371
exponential increase of the size of the box. It also generates the graph mentioned in 372
subchapter 2.3. From the angle of the regression line it obtains the fractal dimension. 373
It is also worth mentioning that the program can calculate the fractal dimension in a way 374
similar to Bouligand-Minkowski method described in (Weisstein, 2019). The main difference 375
is that it uses squares, not circles, to calculate the fractal dimension. The program searches for 376
the lowest number of squares of an even size which can cover the examined object. According 377
to (Fractalyse, 2019) it is more general method of calculating the fractal dimension. 378
We have chosen five graphs of winning players and five graphs of breaking even players to 379
conduct our research. Firstly the graphs were prepared as explained in subchapter 4.1. 380
Graphs were found on the Internet on sites covering poker subjects (Forum, 2019). 381
Most of them were published with a request to evaluate them by other players. We can conclude 382
that they are authentic graphs of players. 383
4.3. Research process 384
Research was conducted in the following way: Firstly the selection was done. Players with 385
obvious winning tendency were selected. Players with results close to zero were selected to the 386
second group. Then, using Fractalyse (Fractalyse, 2019), the calculation of fractal dimension 387
was performed. Additional measures were performed on different numbers of played hands to 388
check if length of playing period has influence to the measures. Results are shown in Table 1. 389
390
Page 13
Applying chaos theory to risk management in a game of chance 207
4.4. Research results 391
The results were put together in table 1. Columns mean respectively: Lp. – number of 392
measure, L – number of hands used to generalise the measure (in thousands), Q – quality of the 393
player 1 – winning, 0 – breaking even, D – fractal dimension of the players graph. 394
Table 1. 395 Research results 396
Lp. L Q D
1 20 0 1.259
2 73 0 1.427
3 100 0 1.396
4 220 0 1.354
5 380 0 1.377
6 40 1 1.044
7 50 1 1.087
8 100 1 1.132
9 275 1 1.198
10 400 1 1.033
397
The research was conducted with a minimal size of the box equal to one pixel with linear 398
increase (Weisstein, 2019) equal to four pixels and stop condition when a single box covers the 399
entire graph. 400
401 Figure 5. Graph Lp. 10; low fractal dimension and almost straight graph are worth noticing. 402
403
Page 14
208 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
4.5. Observations 404
The results are shown in table 1. They show a strict relation between expected value of 405
a player and fractal dimension of their winnings graph generated in time of their play. 406
Let us notice that for winning players fractal dimension was in any case no higher than 1.2. 407
On the other hand, players who break even find their graphs fractal dimension between 408
1.2 and 1.5. The fact confirms that the fractal dimension is not dependent on quantity of played 409
hands. 410
Analysing graphs and table results we can also conclude that the lower the fractal dimension 411
is the less ragged the graph is. Examples of graphs with lowest and highest fractal dimensions 412
are shown in figures 5 and 6. 413
414
Figure 6. Graph Lp. ,2; high fractal dimension and very ragged graph are worth noticing. 415
4.6. Conclusion 416
According to Markowitz’s theory (Markowitz, 1952) the higher the alternation is the higher 417
the risk is. In our case poker table is the market and risk is measured with fractal dimension. 418
We can conclude that breaking even players play much in a more risky way than winning 419
players, because the fractal dimension of winning players is much lower. 420
421
Page 15
Applying chaos theory to risk management in a game of chance 209
Taking into consideration the fact that the fractal dimension is not dependent on number of 422
played hands we can conclude that these graphs are self-similar. It satisfies the basic fractal 423
condition described in (Kudrewicz, 2007). Having that said, we can consider fractal analysis of 424
poker players’ graphs as manageable and faultless. 425
The fact that all values of fractal dimensions are shown in figures, 1.5 gives a strong base to 426
claim that poker is not a random result game. According to (Peters, 1994) when the Hurst 427
exponent belongs to interval [0.5, 1] we may consider a reliable strategy. The higher the Hurst 428
exponent is the less probable the randomness is. Therefore it is claimed that, considering 429
winning players, there exists a relation between consecutive observations of the graph and 430
possibility of highly probable prediction of further part of the graph. According to Hurst theory 431
the same phenomenon can be observed but in a limited degree. Having that said, we can claim 432
that breaking even players are more expose to randomness and their play is more similar to 433
random stray. However, as long as their fractal dimension is 1.5, their play does not show vital 434
traits of random stray according to fractal analysis, so from a purely mathematical point of view 435
we can consider their play as following some kind of strategy. 436
Graph analysis lets us confirm the assumptions about the relation between fractal dimension 437
and how much ragged the graph is. The higher the fractal dimension is, the more ragged the 438
graph is. 439
Summarizing, we can reason that fractal dimension describes the risk in compliance with 440
intuitional understanding of risk. Fractal analysis leads us to a conclusion that players who use 441
winning strategies make less risky decisions in comparison to other players. 442
5. Performance review and further research 443
In this paper we have shown both basics of chaos theory and basics of games of chance, 444
especially No Limit Texas Hold’em. Mathematical model of a game of chance was analysed 445
and detailed to partial model of Texas Hold’em poker. Research, which purpose was to analyse 446
the risk in poker, was conducted. 447
Risk management in poker is not an easy task. Fractal analysis is surely a new approach to 448
this problem. Nowadays, strictly probabilistic approach is used to analyse the risk of poker 449
games and on its base proper bankroll management is determined. Similar situation is observed 450
on capital markets, however, in this case we do not invest in well prospering player. The payers 451
invest in themselves and they are the ones who need tools which will lead them to increasing 452
their benefits and effectiveness of their game. 453
When developing work covering risk management in poker it is worth. above all, to pay 454
attention to players who win and want to win even more as well as those who have just began 455
their journey to the top. It is crucial to consider minimization of the risk of decisions being 456
Page 16
210 I.J. Jóźwiak, A. Mariański, J. Switana, M. Szczepanik
made as well as increasing expected value. Another important aspect is using the influence of 457
psychology in a poker game. There are plenty directions in which this subject can be developed. 458
The main conclusion of our deliberations about risk in games of chance is that there is 459
a strong need of further development of this inscrutable and often underrated branch of science. 460
References 461
1. Adobe Creative Team (2005). Adobe Photoshop CS Classroom in a Book, Adobe Press. 462
2. Alejandrino, I. (2011). Butterfly Effects – Variations on a Meme. clearnightsky.com, 463
20.10.2018. 464
3. Become a successful poker player today. Available online http://www.pokerstrategy.com, 465
05.11.2019 466
4. Falconer, K. (2003). Fractal Geometry: Mathematical Foundations and Applications. 467
West Sussex: John Wiley & Sons. 468
5. Forum Two Plus Two. Available online http://forumserver.twoplustwo.com, 09.11.2019. 469
6. Fractalyse – Fractal Analysis Software. Available online http://www.fractalyse.org, 470
09.11.2019. 471
7. Kalnay, E. (2003). Atmospheric Modelling, Data Assimilation and Predictability. 472
Cambridge: Cambridge University Press. 473
8. Kudrewicz, J. (2007). Fraktale i chaos. Warszawa: WNT. 474
9. Lorenz, E.N. (1963). Deterministic Nonperiodic Flow, Journal of the Atmospheric 475
Sciences, 20, p. 130-141. 476
10. Mandelbrot, B.B. (1982). The Fractal Geometry of Nature. New York: W.H. Freeman 477
and Co. 478
11. Markowitz, H.M. (1952). Portfolio Selection. The Journal of Finance, 7, p. 77-91. 479
12. Peters, E. (1994). Fractal Market Analysis: Applying Chaos Theory to Investment and 480
Economics. West Sussex: John Wiley & Sons. 481
13. Poker tracker. Available online http://www.pokertracker.com, 09.11.2019. 482
14. Rules for Poker All-In Situations. Poker Side Pot Calculator. Available online 483
http://www.learn-texas-holdem.com, 09.11.2019. 484
15. Salim, M., Rohwer P. (2005). Poker Opponent Modelling, Computer Science Department 485
Indiana University. 486
16. Sklansky, D. (2005). The Theory of Poker. Las Vegas. 487
17. Sutherland, S. (2002). Fractal Dimension. Retrieved from http://www.math.sunysb.edu, 488
08.11.2019. 489
18. Ustawa z dnia 19 listopada 2009 r. o grach hazardowych, Dziennik Ustaw (2009). 490
Page 17
Applying chaos theory to risk management in a game of chance 211
19. Weisstein, E.W. (2018). Geometric Sequence. Retrieved from http://mathworld. 491
wolfram.com, 05.11.2018. 492
20. Weisstein, E.W. (2019). Arithmetic Progression. Retrieved from http://mathworld. 493
wolfram.com, 08.09.2019 494
21. Weisstein, E.W. (2019). Minkowski-Bouligand Dimension. Retrieved from 495
http://mathworld.wolfram.com, 08.11.2019. 496