Showing posts with label maximum entropy. Show all posts
Showing posts with label maximum entropy. Show all posts

Thursday, September 17, 2015

Hot potatoes and entropy; QE and inflation



Roger Farmer has a picture of QE overlaid with 1-year market inflation expectations (shown above). Something looked very familiar. I also have an issue with his timing ... he says:
From January of 2007, through September of 2008, expected inflation fluctuated between two percent and three and a half percent. When Lehman Brothers declared bankruptcy in September 2008, expected inflation fell by nearly eight hundred basis points in the space of two months and by October of 2008 it reached a low of negative four and half percent. 
Immediately following the Federal Reserve purchase of one point three trillion dollars of new securities, expected inflation went back up into positive territory.
Actually, it appears that the 800 bp drop coincides with the onset of QE. But maybe Roger is referring to the start of the onset of MBS purchases. In any case, this looks a lot like this picture ...


Which shows the simple "hot potato" model linked above (and here) -- the total amount of high powered money (yellow) and the entropy of the distribution (blue). Here are the animations from that link above showing the QE as well ...



If we take the entropy as corresponding to inflation expectations, the QE caused the fall in inflation (interest rates). Base reserves weren't distributed in a maximum entropy distribution (probably a Pareto distribution for banks) and instead were coordinated (concentrated among a few banks). This sudden correlation brought on by QE disappeared over time via random transactions.

Note this is analysis of the non-equilibrium dynamics of market expectations of inflation, not actual inflation which appears to have nothing to do with QE.

Tuesday, September 15, 2015

Maximum entropy better than game theory

From NPR's Planet Money.

Richard Thaler has an article up where he discusses the Keynesian beauty contest. He does the test that he did with the Financial Times in 1997 again in 2015. That test is as follows: You win if you correctly guess 2/3 of the average of all entrants' choice of a number between 0 and 100.
  • The Nash equilibrium of this game is zero (essentially an infinite regress of guessing and second-guessing 33, 22, 15, ...).
  • The maximum entropy (information equilibrium) solution is 2/3*(50) = 33 (all states are equally likely, therefore 2/3 of the ensemble average of 50 is 33).

The final results of the contest were 18.9 (in 1997 with 1382 contestants) and 17.3 (in 2015 with 583 contestants) which means the error is:

  • 19 (17 in 2015) for Nash equilibrium
  • 14 (16 in 2015) for maximum entropy

So the two models are about the same.

However! This also illustrates the negative impact of expectations via non-ideal information transfer as the "price" (i.e. guess) in this case "should" be 33 -- the average guess should be 50 if we weren't second guessing each other and driving the price to zero.

The information transfer model in its full generality would say x ≤ 33 if you don't know that the market is ideal. An ideal market would have x = 33.

Since the information transfer framework understands its own limitations, it is a better model than the game theory result of x = 0. Basically x ≤ 33 beats x = 0 as an answer.

This also explains the the Keynesian idea that Paul Krugman put on his blog today:
Economies sometimes produce much less than they could, and employ many fewer workers than they should, because there just isn’t enough spending. Such episodes can happen for a variety of reasons; the question is how to respond.

Sometimes markets aren't ideal and you have non-ideal information transfer. That results in lower prices and less output (measured in money).

...

Update:

I am thinking about how MaxEnt would be applied to the cutest animal contest in the picture at the top (a picture I also reference here). My best guess is 1) something like the Monty Hall problem leads us to 2/3 = 67% and 1/6 = 16% for the other two or 2) that the logic that 1/3 will choose a given animal and 2/3 of those people will choose a different animal, leading to an approximate floor of 1/9 = 11% for the low performers (and a ceiling of 7/9 = 78% for the best).

Wednesday, September 9, 2015

The emergent representative agent [1]

This is a nice article by unlearning economics on Pieria about some assumptions in microeconomics. I have a couple of things to add to this (I'll leave the great discussion of game theory for another time) ... as well as a possible solution to the issues raised.

First, the assumption of transitivity (or the different but related assumption of GARP) is actually equivalent to the idea that humans have a measure called "utility". Basically all that is involved is that the manifold of [transitive] preferences has a structure that allows them to be related by a diffeomorphism to the manifold of real numbers ... numbers we call utility. A real number we can maximize.

There is no [meaningful] difference between assuming "well-behaved preferences" or "transitivity" and assuming there is a property of economic agents called "utility" measured by a real number.

Another assumption mentioned in the article is monotonicity of utility functions. This is required in order for the utility maximum to saturate the budget constraint and be a single point on that constraint. Again, this assumption is only required because you want to use utility (to come up with a single solution).

So here we are making strange assumptions that are only required because we want to use utility to analyze economic problems.

It reminds me of the history of physics where physicists came up with a bunch of odd assumptions in order to continue to use a theoretical construct. It was called the aether and it asked physicists to assume partial aether dragging and length contraction.

What if I told you you could get the same general results as utility without assuming transitivity or monotonicity? And what if I told you it had a single assumption: the principle of indifference.

Let's start with a basket of consumption goods (or intertemporal consumption periods or both) C₁, C₂, C₃, ... Cn subject to the budget constraint Σ Ci ≤ M.

Let's assume every consumption "state" Ci = pi xi in this d-dimensional space is equally likely (the principle of indifference). This could be intertemporal consumption (i ≤ d indexing time) or different goods (i ≤ d indexing goods) or even intertemporal consumption of different goods (i ≤ d indexing goods and time).

Here is what we have for d = 2:


And here is d = 3:



How can I saturate the budget constraint (and select a point on it) using this? Dimensionality. As d → ∞, the distribution of points becomes highly concentrated around Σ Ci = Σ pi xi = M as can be seen in this graph:


For an infinite number of goods and/or an infinite number of time periods, the 'representative' (average) point approximately saturates the budget constraint. The (emergent) representative agent spends all of its money. However individual agents can vary from spending all to saving all of their money.

This representative agent also appears to engage in consumption smoothing (if you look at i indexing time in the intertemporal problem, all time periods are roughly equal in terms of the value of consumption ... [a symmetry that can be broken by the rate of interest]). Consumption smoothing is an emergent property of the ensemble of agents that are free to choose any point in the domain (and any given agent is unlikely to have very smooth consumption).

This maximum entropy view reproduces the basics of the utility maximization model without the utility. In fact, utility can be seen as emergent [2]. And since utility, a real number, can be used to describe the solutions (equilibria) we see in the maximum entropy view we see that transitivity (or GARP, both equivalent to real number utility) is an emergent property of the emergent representative agent. This is important: transitivity is explicitly not true of the individual agents -- they have random consumption baskets that they have revealed they prefer! Their preferences are not transitive -- they aren't even stable! Agent 9000 prefers A to B one day and B to A another.

So here's a list of some emergent properties of the emergent representative agent:

  • Transitive preferences (a consequence of emergent utility)
  • Monotonicity of utility (satiation)
  • Consumption smoothing

And here's a list of properties of the underlying individual agents:

  • Preferences are not transitive and are unstable (random preferences)
  • No preference to more or less of a good (random preferences)
  • Consumption fluctuates (random consumption)

The idea of a rational utility maximizing representative agent is an emergent construct [1] in the entropy maximization paradigm; real individual people need not have any of these properties.

...

Footnotes:

[1] Noah Smith references emergent representative agents in a recent post:
For example, suppose psychologists find that most human beings are incapable of forming the kind of expectations that time-varying utility models say they do. That would mean one of two things. It could mean that the economy as a whole behaves qualitatively differently than the individuals who make it up (in physics jargon, that would mean that the representative agent is "emergent"). Or it could mean that time-varying utility models must not be the reason for excess volatility.
[2] This is a bit subtle -- entropy maximization chooses a particular utility function (or really a class of utility functions that are maximized at the entropy maximization point).

Wednesday, August 12, 2015

A trivial maximum entropy model and the quantity theory

This is a trivial maximum entropy model, but I still think the result is interesting.

Let's take an economy with d = 100 dimensions subjected to a budget constraint Σ m = M(t) where t is time, m is the (randomly chosen) allocation of the total amount of money M to each dimension (these could be "markets", "firms" or even "agents"). This is effectively this picture except d = 3 here (the Ci are the dimensions):



If we take the derivative of the ensemble average d/dt log 〈m〉(assuming a uniform distribution), we get something (blue paths) that roughly follows d/dt log NGDP (yellow path):


The paths obviously converge to d/dt log M (black path) ... it doesn't even depend on d because 〈m〉= α M with constant α even if we don't have d >> 1 since

d/dt log α M = d/dt (log M + log α) = d/dt log M

If d >> 1 then we have α ~ d/(d + 1) → 1, but this isn't terribly important. What this does show is that

d/dt log M ~ d/dt log NGDP

k M ~ NGDP

and we have a simplistic quantity theory of money based on randomly allocating money to different markets.

Sunday, July 26, 2015

Resolving the paradox of fiat money

As the dimension of this simplex defined by the budget constraint Σ Ci = M increases, most points are near the budget constraint hyperplane ... and therefore the most likely point will be near the hyperplane.

In his recent post on neo-Fisherism, David Glasner links to an earlier post about the paradox of fiat money -- that money only has value because it is expected to have value:
But the problem for monetary theory is that without a real-value equivalent to assign to money, the value of money in our macroeconomic models became theoretically indeterminate. If the value of money is theoretically indeterminate, so, too, is the rate of inflation. The value of money and the rate of inflation are simply, as Fischer Black understood, whatever people in the aggregate expect them to be.
The problem then becomes the problem of the "greater sucker"; rational people would only accept money because they expect they will be able to find a greater sucker to accept it before its value vanishes. But since at some point e.g. the world will end and there won't be a greater sucker, the expected value should be zero today. Note that the idea of the future rushing into the present is a general problem of expectations, as I wrote about here.

After getting a question from Tom Brown about this, I started answering in comments. Now I think the information transfer framework gives us a way to invert that value argument -- that if you don't accept money, you are the greater sucker. The argument creates a stable system of fiat currencies.

The argument starts here; I'll quickly summarize the link. If we imagine a budget constraint that represents the total amount of money in the economy at a given time being used in transactions for various goods, services, investments, etc C₁, C₂, C₃, ... Cn, then using a maximum entropy argument with n >> 1 we find the most likely state of the economy saturates the budget constraint and minimizes non-ideal information transfer (see the picture at the top of this post for n = 3). And since:

k N/M ≥ dN/dM ≡ P

we can say minimized non-ideal information transfer maximizes prices for a given level of goods and services {Cn} because P is as close to k N/M as it can be. We would think of arrangements of trust (credit) or barter exchange as less ideal (very non-ideal) information transfer than using money or some money-like commodity.

This maximized monetary value critically depends on n >> 1 -- that as many goods and services are exchangeable for whatever is being used as money as possible. This means that whoever trades their goods and services for the most widely used money gets a higher price (more ideal information transfer) for those goods and services. If I don't accept money, then I'm getting a worse deal and I'm the greater sucker. That would stabilize an existing fiat currency system because if I refuse to take money, I'd contribute to the downfall of my own personal wealth. I'd also get a worse deal in that particular transaction.

I've explained this argument in terms of rational agents. However in the information transfer framework we'd think of this argument as money allowing agents to access larger portions of state space and hence achieve higher entropy. We would think of money as a dissipative structure, like convection cells in heated water or even life itself, arising in order to maximize entropy production to move the system towards equilibrium. Convection cells only cease to exist when the water reaches a uniform temperature. Analogously, money only loses its value when every scarce resource is equally allocated among everyone (the Star Trek economy) -- the economic equivalent of heat death.

Update +3 hours:

Although the money value argument admits a rational agent explanation, the truth is that there may not be any such explanation that is valid in terms of microeconomics -- that money is an emergent structure and its effects are entropic forces. The rational explanation may be like incentives or Calvo pricing: an attempt to 'microfound' a force (effect, or structure) that only exists at the macro level. Osmosis and diffusion have no microscopic mechanism (although you could invent one, an effective force [1]) and maybe the value of money has no micro explanation that is actually true.

Footnotes:

[1] An example of a (possible) entropic force that we tend to explain with an invented micro force is gravity. We think of it as mediated by gravitons that behave similarly to photons, but it might be closer to the stickiness of glue. It is important to note that because it is an entropic macro force doesn't mean it is impossible to model as a micro force.

Tuesday, July 21, 2015

Implicit models: minimum wage and maximum entropy

One of my favorite things Paul Krugman has said is this:
Any time you make any kind of causal statement about economics, you are at least implicitly using a model of how the economy works. And when you refuse to be explicit about that model, you almost always end up – whether you know it or not – de facto using models that are much more simplistic than the crossing curves or whatever your intellectual opponents are using.
I think he's actually mentioned it a couple times. If you're not using an explicit model, the implicit model you're using is likely dumb. At the very least you're making assumptions that you haven't told us that tend to be just your gut feelings about things with frighteningly high probability.

I thought of this a couple times recently while reading some posts at Marginal Revolution (which I read to see what the latest arguments are in favor of comforting the comfortable). First, Tyler Cowen is ... scared?
[In places where the median wage is below 15 dollars], a 15 [dollar] an hour minimum wage is…shall we say…risky?
We have no idea what model Cowen is using here. And what is the risk? That aggregate supply (and thus the labor required) will fall to a level to where prices support the new wage scheme? That people will move out of Arkansas? That everything will be fine and economics 101 analysis will be discredited?

We can work out some of its properties -- for one Cowen assumes there's a significant probability that employees making less than 15 dollars per hour have sufficient market power to negotiate a wage roughly equal to their marginal product. Is this true? We don't really know for sure, but Cowen is assuming a high prior probability for it anyway.

Alex Tabarrok makes similarly implicit assumptions about the form of unobservable utility functions (and their parameter values!) in his discussion of the new proposed contractor/employee designation rules. In a sense, Tabarrok is making the same implicit assumption: that contractors have sufficient market power to negotiate the terms of their contractor status -- that they don't want to be employees. Is this true? Who knows, but Tabarrok is assuming it without telling us.

You have to let us know what your model is. If I analyze these two issues in the most naive possible way in the information equilibrium model, there's no effect from a minimum wage. I'm not saying there's no effect -- there probably is -- it's just that the model has to get more complex.

For example, if we take a maximum entropy view of the intertemporal utility maximization problem, the consideration is whether the minimum wage is comparable to the budget constraint for total compensation. Take a three period model where wages paid in each period are subject to a budget constraint w1 + w2 + w3 = W. Here, W represents the maximum profitable total pay for an employee over their career -- i.e. the total marginal product in all three periods. The typical employee is paid 0.75 W over the three periods (and most likely w1 = w2 = w3 = 0.25 W). The median wage is about 0.79 W. If we set a minimum wage at (0.8/3) W = 0.27 W in each period (i.e. higher than the median wage), we actually bump median total compensation to about 0.96 W (typically realized as w1 = w2 = w3 = 0.32 W). This is illustrated in the graphics below:


Note, this doesn't throw the other people out of the distribution -- they just all get concentrated at in the new allowed volume. I didn't show it in the picture because it made it hard to see what was going on. The distribution just shifts to higher wages, reducing the probability of occupying a wage state below 0.8 W to zero:


Is that a realistic model? Probably not, but at least it's not implicit modeling!

Tuesday, June 30, 2015

The Euler equation as a maximum entropy condition


In the discussion of the RCK model on these two posts I realized the Euler equation could be written as a maximum entropy condition. It's actually a fairly trivial application of the entropy maximizing version of the asset pricing equation:

$$
p_{i} = \frac{\alpha_{i}}{\alpha_{j}} \frac{\partial U/\partial c_{j}}{\partial U/\partial c_{i}} p_{j}
$$

To get to the typical macroeconomic Euler equation, define $\alpha_{i}/\alpha_{j} \equiv \beta$ and re-arrange:

$$
\frac{\partial U}{\partial c_{i}} = \beta \; \frac{p_{j}}{p_{i}} \; \frac{\partial U}{\partial c_{j}}
$$

The price at time $t_{j}$ divided by the price at time $t_{i}$ is just (one plus) the interest rate $R$ (for the time $t_{j} - t_{i}$), so:

$$
\frac{\partial U}{\partial c_{i}} = \beta (1 + R) \; \frac{\partial U}{\partial c_{j}}
$$

And we're done.

The intuition behind the traditional economic Euler equation is (borrowed from these lecture notes [pdf])
The Euler equation essentially says that [an agent] must be indifferent between consuming one more unit today on the one hand and saving that unit and consuming in the future on the other [if utility is maximized].
The intuition for the maximum entropy version is different. It does involve the assumption of a large number of consumption periods (otherwise the intertemporal budget constraint wouldn't be saturated), but that isn't terribly important. The entropy maximum is actually given by (Eq. 4 at the link, re-arranged and using $p_{j}/p_{i} = 1 + R$):

$$
c_{j} = c_{i} (1 + R)
$$

The form of the utility function $U$ allows us to transform it into the equation above, but this is the more fundamental version from the information equilibrium standpoint. This equation says that since you could be anywhere along the blue line between $c_{j}$ maximized and $c_{i}$ maximized on this graph:


the typical location for an economic agent is in the middle of that blue line [1]. Agents themselves might not be indifferent to their location on the blue line (or even the interior of the triangle), but a maximum entropy ensemble of agents is. Another way to put it is that the maximum entropy ensemble doesn't break the underlying symmetry of the system -- the interest rate does. If the interest rate was zero, all consumption periods would be the same and consumption would be equal. A finite interest rate transforms both the coordinate system and the location of maximum entropy point. You'd imagine deforming the n-dimensional simplex so that each axis was scaled by $(1 + r)$ where $r$ is the interest rate between $t_{i}$ and $t_{i + 1}$.

Footnotes:

[1] The graph shown is actually for a large finite dimensional system (a large, but finite number of consumption periods); the true entropy maximum would fall just inside the blue line/intertemporal budget constraint.

Wednesday, June 17, 2015

3/4 of a knife, 3/4 of a fork and 3/4 of a spoon

Cesar Hidalgo is looking into information theory with his new book. I haven't read it; however I have read Diane Coyle's review (H/T Mike Norman) and it seems like it might be a great source of analogies for this blog. This one immediately struck me:
Hidalgo makes the same point as the final chapter of [Diane Coyle's] GDP book, that in adding things up in terms of their monetary value we are not capturing the value of diversity: three spoons are not as valuable as a knife, fork and spoon.
That is actually the exact point of this post here. We'll almost exactly. If we have M dollars to spend on knives, forks and spoons, (assuming they equally cost one Euro [1] WOLOG) then all consumption possibilities (blue points) are located under the budget constraint hyperplane in the first (left side) figure:


The maximum entropy point is given by the black dot in the second (right side) figure. Now for three items, that point is actually at {M/4, M/4, M/4} so if you had 4 €, you'd have 1 fork, 1 knife and 1 spoon at the maximum entropy point (and 1 € left over).

The entropy maximum is related to equilibrium in the information transfer model  as well as effectively ideal markets. Under certain (ideal) conditions, it recovers all of the properties of maximizing utility.

I would disagree with the analogy of crystallizing imagination Hidalgo uses -- that is a lower entropy state for one thing. The key idea we want to capture is Jaynes' dither. We want to make the world safe for people to move about the space of possibilities -- to try and fail.

PS This also maximizes entropy.

Update +15 minutes:

Since the maximum entropy state (3/4, 3/4, 3/4) with budget constraint M = 3 is not realizable given quantized knives, forks and spoons, you'd actually have a combination of the states (1, 1, 1), (1, 1, 0), (1, 0, 1) and (0, 1, 1) realized among a quarter of the population each.

Footnotes:

[1] I'm using Euros (€) here because the dollar symbol messes with mathjax.

Monday, June 15, 2015

The definition, origin and purpose of money

How is that for a bold title? Well, you're in for a (surprisingly short) strange ride from abstract mathematics to ancient history.

I have made the argument several times (first here, most recently here) that the most likely allocation against a n dimensional budget constraint with n >> 1, even when allowing states that don't saturate it, is actually at the budget constraint (M) because the location of the centroid of the n-dimensional polytope gets closer to the n − 1 dimensional budget constraint hyperplane as n → ∞. Here is a picture:




The hyperplane is the blue triangle (with maximum values of Cᵢ = M at the corners), and there are random points uniformly distributed along axes C₁ - C. You can see how the centroid (black) is a bit closer to the hyperplane than you'd expect for the 2D triangle that appears in the edge-on view of the budget constraint hyperplane. 

Let's imagine that budget constraint represents the total amount of money in the economy at a given time being used in transactions for various goods, services, investments, etc C, C₂, C₃, ... Cn.

What does the argument above imply? It means that (at any given time) money, if there isn't some coordinating factor, will most likely be completely allocated towards goods, services, investment, etc and that the difference between the information content in the money allocation [the information required to e.g. store everyone's bank balance] and the information content of the allocation of all goods and services [the information required to store the list of which goods belong to whom] I(N) − I(M) will be minimized so that if  I(N) ≥ I(M)

α I(N) = I(M)

for some  0 < α ≤ 1, and the information transfer equation (in the system N→M) becomes:

α (N/dN) log kn = (M/dM) log km

N/dN = k' M/dM 

with k' = (1/α) (log km/log kn). That is to say we've recovered an effective version of the original information transfer equation with a modified information transfer index k' but without non-ideal information transfer where N/dN  ≥  k M/dM. Maximum entropy results in the ideal information transfer condition I(N) = I(M) we've just assumed in the past (or taken to be a first order approximation).

Because of the increased number of identical states when goods are measured in terms of money, money helps saturate the entropy bound and therefore the budget constraint hyperplane. Combined with this post on how money can be introduced to mediate information equilibrium between two quantities leaving you with a theory that only requires one of the quantities and money when the information equilibrium equation holds ... we have a pretty complete theory of what money is and does.
Money is a thing that mediates transactions and has high information entropy
It maximizes information entropy when it has no intrinsic purpose other than mediating transactions -- i.e. if it is one of the commodities (or goods, or services, or investments, etc) C₁, C₂, C₃, ... Cn -- it will more likely line up along that dimension, resulting in C₁ + C₂ + C₃ + ... + Cn < M.

Note that we will fail to have ideal information transfer if the dimension is low (there will be larger fluctuations away from saturation) or the allocation of money becomes coordinated (e.g. panic and race towards one of the commodities Cᵢ). So a large, diverse economy that is totally random [1] is an ideal information transfer system -- an effectively ideal market.

...

The above definition leads to an interesting theory of the evolution of money. If gold or other metals were valuable and had intrinsic purposes besides mediating transactions (like being made into things), it is unlikely they would lead directly to money. Instead, the theory above suggests we should start out with the tokens of Mesopotamia that were likely used to keep track of transactions (see e.g. here):

Accounting tokens (?) of Mesopotamia. Image from here.
These are already intrinsically worthless except in exchange -- meeting the first definition of money above. One of these would have marginally greater information entropy than the others (and it likely wouldn't be the least valuable one or most valuable one), leading it to be taken in lieu of other tokens at various (market) rates, and eventually leading to that one becoming the precursor to money.

Now here's some wild speculation: what if we ended up with coins (flattish round things) in the West and Middle East because that was the shape of the Mesopotamian token with the highest information entropy? Like that one at the top left [2] ... eventually cast in metal because it needed to be durable (high information entropy means it's traded a lot), not because of the value of the metal (although there could have been some mixing of the two paradigms).

Update 6/17/2015:

Added "effective" in the narrative above. The result isn't an ideal market where I(N) = I(M) but rather an effectively ideal market where I(N) = α I(M) with α being some constant less than one.

Update 7/14/2015:

Here is some more evidence for my wild speculation: in China, cowrie shells were used as an early currency and subsequently cast in bronze/copper. See here. Picture below ...



Footnotes

[1] This suggests that news coverage of markets (the WSJ, CNBC, Bloomberg, etc) actually make markets less ideal as they can lead to coordinated behavior.

[2] I don't really mean it has to be the one in the picture. But there seem to have been a lot of similar-looking disc shaped ones that dealt with clothing, sheep, wool, etc. Even to the point of where a whole sheep probably had some interest rate relative to the wool of one sheep, leading to 5 wool = one sheep and the invention of exact change. The industrial revolution can be seen as revolving around clothing, why not the invention of money?

Monday, June 8, 2015

Maximum entropy and the 'natural rate' of unemployment

I mentioned in this post that maximum entropy in the MINIMAC model gives us a pretty simple mechanism to generate a 'natural rate' of unemployment. Not a perfect model, but pretty good:



You'd imagine policy to kick in if the unemployment rate got to high (stimulus) or too low (tight money to reign in inflation), which would shape the distribution ... and there's the finite number of measurements ...

But it's a heck of simple model! Large number of consumption periods (D >> 1) + finite supply of labor (constraint L) = natural rate (L' < L). Just use this diagram (from here)


MINIMAC as an information equilibrium model


Nick Rowe has a post up where he blegs the impossible ... A 3D Edgeworth box does not exist (it is at a minimum 6D as I mention in a comment at the post) [1]. However, Nick does cite MINIMAC, a minimal macro model described by Paul Krugman here. It gives us a fun new example to apply the information equilibrium framework!

We'll start with our typical utility framework (see e.g. here or here) with

$$
U \rightarrow C_{i}
$$

$$
U \rightarrow M_{i}
$$

Where there are a large number of periods $i = 1 ... n$. Our utility function is:


$$
U \sim \prod_{i}^{n} C_{i}^{s} \prod_{j}^{n} M_{j}^{\sigma}
$$

I'm going to build in a connection to the information transfer model right off the bat by adding (assuming constant information transfer index for simplicity):

$$
P : N \rightarrow M
$$

so that:

$$
P \sim M^{k - 1}
$$

and more importantly for us:

$$
\left( \frac{M}{P} \right)^{1 - s} \sim M^{(2 - k)(1 - s)}
$$

Which means that our utility function matches the MINIMAC utility function up to a logarithm (our $U$ would be $\log U$ using Krugman's $U$) if $\sigma = (2 - k) (1 -s)$:

$$
U \sim \prod_{i}^{n} C_{i}^{s} \prod_{j}^{n} \left( \frac{M_{j}}{P_{j}} \right)^{1 - s}
$$

The general budget constraint is given by:

$$
L = \sum_{i} C_{i} + \sum_{j} M_{j}
$$

In the MINIMAC model, we're only concerned with two periods (call them $i$ and $j$). Essentially in period $i$, $C_{k \leq i} = 0$ and $M_{k \leq i} = M$ and in period $j$, $C_{k \geq j} = C$ and $M_{k \geq j} = M'$ to make the connection with Krugman's notation. We'll use the maximum entropy assumption with a large number of time periods so that the most likely point is near the budget constraint (first shown here):

My terrible handwriting and the maximum entropy solution for a large number of periods (high dimensional volume). The orange dots represent the density of states for a high dimensional system. Connection with Krugman's notation also shown.

There are some interesting observations. If $k = 2$, which is $\kappa = 1/2$, then we have the quantity theory of money, but $\sigma = 0$, so utility only depends on consumption. Also if we take $M_{i} = M_{j}$ (constant money supply), we should randomly observe cases of unemployment where $L' < L$ and consumption is below the maximum entropy level near the budget constraint:

Occasionally, you observe a point (red) that moves away from the budget constraint resulting in unemployment.
In fact, we should typically observe $L' < L$ since the maximum entropy point is near, but not exactly at the budget constraint. Voilà! The natural rate of unemployment is essentially dependent on the dimensionality of the consumption periods. With an infinite number, you'd observe no unemployment. For two time periods, you'd observe ~ 50% unemployment (the red dot in the image above would appear near the center of the triangle most of the time). In our world with some large, but not infinite, number of periods we have a distribution that peaks around a natural rate around ~ 5%:

The natural rate is given by the dimensionality of the temporal structure of the model. In some large, but finite, number of time periods you have an unemployment rate near e.g. 5%.



Footnotes:

[1] You can easily fit a pair of xy axes together where x1 = x0 - x2 and y1 = y0 - y2 (flip both axes) but you can't do it for three sets of xyz axes since x1 = x0 - x2 -x3 (i.e. it depends on two axes). As Nick mentions in reply to my comment, you can do it for 2 agents and 3 goods. And he's right that the math works out fine -- it's basically a three-good Arrow-Debreu general equilibrium model. For my next trick, I think I will build Nick's model.

Wednesday, May 27, 2015

The basic asset pricing equation as a maximum entropy condition


Commenter LAL has brought up the basic asset pricing equation a couple of times, and so I had a go at looking at it as a maximum entropy/information equilibrium model. Turns out it works out. In Cochrane's book (updated with link) the equation appears as:

$$
\text{(1) }\; p_{t} = E \left[ \beta \frac{u'(c_{t+1})}{u'(c_{t})} x_{t+1} \right]
$$

Where $p_{t}$ is the price at time $t$, $c_{t}$ is consumption at time $t$, $u$ is a utility function, and $\beta$ is a future discount factor. Now $x_{t}$ is also the price at time $t$ (although it's called the payoff) and of course there is the funny business of the $E$ that essentially says all the terms at a time $t+1$ exist only in the minds of humans (and turns an $x$ into a $p$). Rational expectations is the assumption that the $E$ is largely meaningless on average (i.e. approximately equal to the identity function).

As a physicist, I'm not particularly squeamish about the future appearing in an equation (or time dropping out of the model altogether), so I will rewrite equation (0) as:

$$
\text{(1) }\; p_{i} = \beta \frac{u'(c_{j})}{u'(c_{i})} p_{j}
$$

It turns out much of the machinery is the same as the Diamond-Dybvig model, so I'll just adapt the beginning of that post for this one.

The asset pricing equation is originally a model of consumption in two time periods, but we will take that to be a large number of time periods (for reasons that will be clear later). Time $t$ will be between 0 and 1.

Let's define a utility function $U(c_{1}, c_{2}, ...)$ to be the information source in the markets

$$
MU_{c_{i}} : U \rightarrow c_{i}
$$

for $i = 1 ... n$ where $MU_{c_{i}}$ is the marginal utility (a detector) for the consumption $c_{i}$ in the $i^{th}$ period (information destination). We can immediately write down the main information transfer model equation:

$$
MU_{c_{i}} = \frac{\partial U}{\partial c_{i}} = \alpha_{i} \; \frac{U}{c_{i}}
$$

Solving the differential equations, our utility function $U(c_{1}, c_{2}, ...)$ is

$$
U(c_{1}, c_{2}, ...) = a \prod_{i} \left( \frac{c_{i}}{C_{i}} \right)^{\alpha_{i}}
$$

Where the $C_{i}$ and $a$ are constants. The basic timeline we will consider is here:


Period $i$ is some "early" time period near $t = 0$ with consumption $c_{i}$ while period $j$ is some "late" time period near $t = 1$ with consumption $c_{j}$. We'll only be making changes in these two time periods. The "relevant" (i.e. changing) piece of the utility function is (taking a logarithm):

$$
\text{(2) }\; \log U \sim \;\; ... + \alpha_{i} \log c_{i} + ... + \alpha_{j} \log c_{j} + ... + \log U_{0}
$$

where all the various $C_{i}$'s, $\alpha_{i}$'s and $a$ ended up in $\log U_{0}$.

Now the derivation of the asset pricing equation sets up a utility maximization problem where normal consumption in period $i$ (called $e_{i}$) is reduced to purchase $\xi$ of some asset at price $p_{i}$, and added back to consumption in period $j$ at some new expected price $p_{j}$. So we have:

$$
\text{(3a) }\; c_{i} = e_{i} - p_{i} \xi
$$

$$
\text{(3b) }\; c_{j} = e_{j} + p_{j} \xi
$$

Normally, you'd plug these into the utility equation (2), and maximize (i.e. take a derivative with respect to $\xi$ and set equal to zero). The picture appears in this diagram (utility level curves are in gray):


The change in the amount $\xi$ of the asset held represents wiggling around the point $(e_{i}, e_{j})$ along a line with slope defined by the relative size of the prices $p_{i}$ and $p_{j}$ to reach the point labeled with an 'x': the utility maximum constrained to the light blue line.

Instead of doing that, we will use entropy maximization to find the 'equilibrium'. In that case, we can actually be more general, allowing for the case that e.g. you don't (in period $j$) sell all of the asset you acquired in period $i$ -- i.e. any combination below the blue line is allowed. However, if there are a large number of time periods (a high dimensional consumption space), the most probable values of consumption are still near the blue line (more on that here, here). Yes, that was a bit of a detour to get back to the same place, but I think it is important to emphasize the generality here.

If the states along the blue line are all equally probable (maximum entropy assumption), then the average state will appear at the midpoint of the blue line. I won't bore you with the algebra, but that gives us the maximum entropy equilibrium:

$$
\xi = \frac{e_{i} p_{j} - e_{j} p_{i}}{2 p_{i} p_{j}}
$$

If we assume we have an "optimal portfolio", i.e we are already holding as much of the asset as we'd like, we can take $\xi = 0$, which tells us $e_{k} = c_{k}$ via the equations (3) above, and we obtain the condition:

$$
\text{(4) }\; p_{i} = \frac{c_{i}}{c_{j}} p_{j}
$$

Not quite equation (1), yet. However, note that

$$
\frac{1}{U} \frac{\partial U}{\partial c_{i}}  = \frac{\partial \log U}{\partial c_{i}} = \frac{\alpha_{i}}{c_{i}}
$$

So we can re-write (4) as (note that the $j$, i.e. the future, and $i$, i.e. the present, flip from numerator and denominator):

$$
\text{(5) }\; p_{i} = \frac{\alpha_{i}}{\alpha_{j}} \frac{\partial U/\partial c_{j}}{\partial U/\partial c_{i}} p_{j}
$$

Which is formally similar to equation (1) if we identify $\beta \equiv \alpha_{i}/\alpha_{j}$. You can stick the $E$ and brackets around it if you'd like.

I thought this was pretty cool.

Now just because you can use the information equilibrium model and some maximum entropy arguments to arrive at equation (5) doesn't mean equation (1) is a correct model of asset prices -- much like how you can build the IS-LM model and the quantity theory of money in the information equilibrium framework, this is just another model with a information equilibrium description. Actually equation (4) is more fundamental in the information equilibrium view and basically says that the condition you'd meet for the optimal portfolio is simply that the ratio of the current to expected future consumption is equal to the ratio of the current to the expected price of that asset. Essentially if you think the price of some asset is going to go up 10%, you will adjust your portfolio so your expected future consumption goes up by 10%.

Sunday, April 19, 2015

Diamond-Dybvig as a maximum entropy model


I'm pretty sure this is not the standard way to present Diamond-Dybvig (which seems more commonly to be presented as a game theory problem).  However, this presentation will allow me to leverage some of the machinery of this post on utility and information equilibrium. I'm also hoping I haven't completely misunderstood the model.

Diamond-Dybvig is originally a model of consumption in 3 time periods, but we will take that to be a large number of time periods (for reasons that will be clear later). Time $t$ will be between 0 and 1.

Let's define a utility function $U(c_{1}, c_{2}, ...)$ to be the information source in the markets

$$
MU_{c_{i}} : U \rightarrow c_{i}
$$

for $i = 1 ... n$ where $MU_{c_{i}}$ is the marginal utility (a detector) for the consumption $c_{i}$ in the $i^{th}$ period (information destination). We can immediately write down the main information transfer model equation:

$$
MU_{c_{i}} = \frac{\partial U}{\partial c_{i}} = k_{i} \; \frac{U}{c_{i}}
$$

Solving the differential equations, our utility function $U(c_{1}, c_{2}, ...)$ is

$$
U(c_{1}, c_{2}, ...) = a \prod_{i} \left( \frac{c_{i}}{C_{i}} \right)^{k_{i}}
$$

Where the $C_{i}$ and $a$ are constants. The basic timeline we will consider is here:


Periods $i$ and $k$ are some "early" time periods near $t = 0$ with consumption $c_{i}$ and $c_{k}$ while period $j$ is a "late" time period near $t = 1$ with consumption $c_{j}$. We introduce a "budget constraint" that basically says if you take your money out of a bank early, you don't get any interest. This is roughly the same as in the normal model except now period 1 is the early period $i$ and period 2 is the late period $j$. We define $t$ to be $t_{j} - t_{i}$ with $t_{j} \approx 1$ so the bank's budget constraint is

$$
\text{(1) }\;\; t c_{i} + \frac{(1-t) c_{j}}{1+r} = 1
$$

The total available state space is therefore an $n$-dimensional polytope with vertices along axes $c_{1}$, $c_{2}$, ... $c_{n}$. For example, in three dimensions (periods) we have something that looks like this:


Visualizing this in higher dimensions is harder. Each point inside this region is taken to be equally likely (equipartition or maximum information entropy). Since we are looking at a higher dimensional space, we can take advantage of the fact that nearly all of the points are near the surface ... here, for example is the probability density of the location of the points in a 50-dimensional polytope (where 1 indicates saturation of the budget constraint):


Therefore the most likely point will be just inside the center of that surface (e.g. the center of the triangle in the 3D model above). If we just look at our two important dimensions -- an early and late period -- we have the following picture:


The green line is Eq. (1) the bank's budget constraint (all green shaded points are equally likely, and the intercepts are given by the constraint equation above) and the blue dashed line is the maximum density of states just inside the surface defined by the budget constraint. The blue 45 degree line is the case where consumption is perfectly smoothed over every period -- which is assumed to be the desired social optimum [0]. The most likely state with equal consumption in every period is given by E in the diagram.

The "no bank" solution is labeled NB where consumption in the early period is $c_{i} \approx 1$. The maximum entropy solution where all consumption smoothing (and even consumption "roughening") states are possible because of the existence of banks is labeled B.

The utility level curves are derived from the Cobb-Douglas utility function at the top of this post. You can see that in this case we have B at higher utility than E or NB and that having banks allows us to reach closer to E than NB.

If people move their consumption forward in time (looking at time $t_{k} < t_{i}$), you can get a bank run as the solution utility (red, below) passes beyond the utility curve that goes through the NB solution. Here are the two cases where there isn't a run (labeled NR) and there is a run (labeled R):


Of course, the utility curves are unnecessary for the information equilibrium/maximum entropy model and we can get essentially the same results without referencing them [1], except that in the maximum entropy case we can only say a run happens when R reaches $c_{i} \approx 1$ (the condition dividing the two solutions becomes the consumption in the early period is equal to the consumption in the case of no banks, rather than the utility of the consumption in the first period is equal to the utility of the consumption in the case of no banks).

I got into looking at Diamond Dybvig earlier today because of this post by Frances Coppola, who wanted to add in a bunch of dynamics of money and lending with a central bank. The thing is that the maximum entropy approach is agnostic about how consumption is mediated or the source of the interest rate. So it is actually a pretty general mechanism that should be valid across a wide array of models. In fact, we see here that the Diamond Dybvig mechanism derives mostly from the idea of the bank budget constraint (see footnote [1], too), so in any model where banks have a budget constraint of the form Eq. (1) above, you can achieve bank runs. Therefore deposit insurance generally works by alleviating the budget constraint. No amount of bells and whistles can help you understand this basic message better.

It would be easy to add this model of the interest rate so that we take (allowing the possibility of non-ideal information transfer)

$$
r \leq \left( \frac{1}{k_{p}} \; \frac{NGDP}{MB} \right)^{1/k_{r}}
$$

This would be equality in the ideal information transfer (information equilibrium) case. Adding in the price level model, we'd have two regimes: high and low inflation. In the high inflation scenario, monetary expansion raises interest rates (and contraction lowers them); in the low inflation scenario, monetary expansion lowers interest rates (and contraction raises them). See e.g. here. I'll try to work through the consequences of that in a later post ... it mostly moves the bank budget constraint Eq. (1).

Footnotes:

[0] Why? I'm not sure. It makes more sense to me that people would want to spend more when they take in more ... I guess it is just one of those times in economics where this applies: ¯\_(ツ)_/¯

[1] In that case the diagrams are much less cluttered and look like this:




Monday, March 23, 2015

Supply and demand as entropy


Continuing in a series with the previous posts, here I'd like to show the forces of supply and demand as entropy. At the moment of the shock, we either add or remove points from the supply or demand. This produces shifts in the supply and demand curves (shocks), and the system returns to equilibrium. I used the differential equation:

$$
P = \frac{dD}{dS} = k \; \frac{D}{S}
$$

to determine the price. The model for partial equilibrium (i.e. supply and demand curves) is here for reference. Here are the four cases ... (demand is in blue on the left, supply in red on the right)

Increase in demand, leading to an increase in price:



Increase in supply, leading to a fall in price:



Fall in demand, leading to a fall in price:



Fall in supply, leading to an increase in price: