## Formal analysis

### June 18, 2011

Keynes is rather dismissive of what he calls ‘“mathematical” economics’. The following passage is from chapter 21 of *The General Theory*:

The object of our analysis is, not to provide a machine, or method of blind manipulation, which will furnish an infallible answer, but to provide ourselves with an organised and orderly method of thinking out particular problems; and, after we have reached a provisional conclusion by isolating the complicating factors one by one, we then have to go back on ourselves and allow, as well as we can, for the probable interactions of the factors amongst themselves. This is the nature of economic thinking. Any other way of applying our formal principles of thought (without which, however, we shall be lost in the wood) will lead us into error. It is a great fault of symbolic pseudo-mathematical methods of formalising a system of economic analysis, such as we shall set down in section vi of this chapter, that they expressly assume strict independence between the factors involved and lose all their cogency and authority if this hypothesis is disallowed; whereas, in ordinary discourse, where we are not blindly manipulating but know all the time what we are doing and what the words mean, we can keep “at the back of our heads” the necessary reserves and qualifications and the adjustments which we shall have to make later on, in a way in which we cannot keep complicated partial differentials “at the back” of several pages of algebra which assume that they all vanish. Too large a proportion of recent “mathematical” economics are mere concoctions, as imprecise as the initial assumptions they rest on, which allow the author to lose sight of the complexities and interdependencies of the real world in a maze of pretentious and unhelpful symbols.

There is much truth in the above, I think, and it is truth that applies not only to “economic thinking” but to any kind of thinking that relies on formalization. Statistical analysis is plagued with this kind of problems. Keynes does lay too much stress on the matter of interaction between factors. The problem with formal methods is not particularly with neglecting various effects – it is that they simply are false in various ways (neglecting various effects is only one of the sources of falsehoods). Informal methods have the same problem, of course – and in addition have problems associated with informality.

## Party affiliation and general outlook 1991-2011

### May 24, 2011

The proportions of Americans who are politically affiliated with one of the two major parties has been very stable over the last 20 years, at about 60% with a slight downward trend (+ marks and thick trend line in the chart below). Over the same period, the general outlook of the public has fluctuated wildly, with those who say the country is “going in the right direction” reaching over 50% at one point and falling 5 years later to 20% (circles and thin trend line). The public mood seems to be optimistic immediately following presidential elections (vertical dashed lines), and pessimistic immediately before them.

Data source: New York Times/CBS poll, April 15-20, 2011.

## Sliding window statistics calculation complexity

### May 11, 2011

The following C++ code takes a sequence of *n* elements, *a _{1}, a_{2}, …, a_{n}*, and outputs a sequence of

*n – k + 1*elements. The

*i*-th output element is a maximal element in the subsequence

*a*. The runtime complexity of the code is

_{i}, a_{i + 1}, …, a_{i + k – 1}*O(n)*.

template <typename T> void insert(std::list< std::pair<T,unsigned int> > &l, T v) { unsigned int sp = 0; while (!l.empty() && l.back().first < v) { sp++; l.pop_back(); } l.push_back(std::pair<T,unsigned int>(v,sp)); } template <typename T> void advance(std::list< std::pair<T,unsigned int> > &l) { if (l.front().second > 0) l.front().second--; else l.pop_front(); } template <typename T> void max_in_window(T const *in, T *out, size_t n, size_t k) { std::list< std::pair<T,unsigned int> > l; unsigned int i; for (i = 0; i < k - 1 && i < n; i++) insert(l,in[i]); for (; i < n; i++) { insert(l,in[i]); out[0] = l.front().first; out++; advance(l); } }

Interestingly, an algorithm for the median in a sliding window will have runtime of at least *O(n log k)*, since such an algorithm can be used to sort *O(n / k)* sequences of length *O(k)* each:

Let *a _{1}, a_{2}, …, a_{n}* be a sequence of numbers in a known interval, say

*(0, 1)*. Create a sequence of length

*3n – 2*by padding the sequence with a prefix of

*(n – 1)*

*0*‘s and a suffix of

*(n – 1)*

*1*‘s. Now execute the sliding window median algorithm with the padded sequence as input, and with

*k = 2n – 1*.

The *i*-th output element will be the median of a sequence that is made of the entire sequence *a _{1}, a_{2}, …, a_{n}*,

*n – i*zeros, and

*i – 1*ones. That median is

*a*, the

_{(i)}*i*-th smallest elements of the sequence

*a*. Thus, the output of the algorithm will be the sorted sequence

_{1}, a_{2}, …, a_{n}*a*.

_{(1)}, a_{(2)}, …, a_{(n)}## Medical Doctor degrees conferred in the U.S.

### April 18, 2011

The number of Medical Doctor degrees conferred in the U.S. has remained unchanged since 1985 – about 15,000 degrees a year. Therefore, the number of MD degrees conferred per U.S. resident has fallen since 1985 by the same rate as the growth of the population – about 25% cumulatively.

That period has also seen a significant increase in the median MD earnings, as measured by the BLS (Current Population Survey – CPS, Weekly & Hourly Earnings): In the decade between 2000 and 2010, physicians and surgeons have seen their nominal median income increase 51%, while lawyers saw an increase of 37%, and the average worker saw an increase of 30% (series LEU0254541000, LEU0254536800, LEU0252881500). The 30% increase, incidentally, represents a 2.5% inflation-adjusted increase according to the BLS.

Data source: Statistical Abstract of the U.S. 2011 edition, Table 300 (spreadsheet); 1980 edition, Table 293.

## Supreme intellectual achievement

### March 17, 2011

Ricardo offers us the supreme intellectual achievement, unattainable by weaker spirits, of adopting a hypothetical world remote from experience as though it were the world of experience and then living in it consistently. With most of his successors common sense cannot help breaking in — with injury to their logical consistency.

John Maynard Keynes,

The General Theory of Employment, Interest and Money, Appendix to Chapter 14

## Deaths breakdown by cause

### February 28, 2011

Data source: CDC, National Vital Statistics Reports, Volume 58, Number 19. Deaths: Final Data for 2007. May 20, 2010. Table 10. Number of deaths from 113 selected causes and Enterocolitis due to Clostridium difficile, by age: United States, 2007.

## Guicciardini’s Dialogue on the Government of Florence (concluded)

### February 16, 2011

First part here.

**Book II**

P. 85:

Since cities were founded and survive for no other reason than for the benefit of their inhabitants, which is based principally in preserving the common good, this cannot be restricted to one particular person or individual except at the expense of all the others. So what, I ask you, could be more pernicious or contrary to the essence of a city than for one part of it to be, quite unjustly and for no reason, excluded from all or part of the public benefits and consequently made to suffer greater disadvantages and burdens more than the other?

P. 103:

[A]lthough it [the Venetian government] has a different name from the one we want to use, because it is called a government of nobles and ours will be called a popular government, it is not for this reason of a different type, since it is simply a government in which everybody who is qualified for office participates, making no distinction either for wealth or for family, as happens when the

ottimatirule, but all are equally admitted to everything, and they are very numerous – perhaps more so than in ours. And if the plebs don’t participate, the don’t in ours either, since infinite numbers of workers, newcomers to the city and others, do not belong to our Council. And although it is more difficult in Venice for the ineligible to be qualified for office than with us, this is not because the type of government is different, but because within the same type they have different institutions. […] So if we were to call our citizens gentlemen and reserved this title for those who were qualified for office, you would find that the government of Venice is as ‘popular’ as ours and that ours is no less a government of optimates than theirs.

## Minor party entry barrier

### February 8, 2011

Elections are first and foremost a mechanism for eliminating non-elite competitors for power – their role as an inter-elite arbitration mechanism is merely a derivative of their primary function. The filtering function is most severe in first-past-the-post systems, where there are often just two credible competitors, and rarely more than 3.

[ Due to typesetting constraints, I am using *[ … ]* as shorthand for the reciprocal of the expression in the square brackets. That is *[ x ] = 1 / x*. ]

Within the Tullock contest model, the entry barrier for minor parties can be calculated. The Tullock contest model specifies the chance of party *k* winning power as *p _{k }= x_{k} [ t_{k} ] [ x_{1} / t_{1} + … + x_{n / }t_{n} ]*, where

*x*is the amount of resources spent by party

_{i}*i*, and

*t*is the (in)effectiveness of the party’s campaign efforts.

_{i}Each party is characterized by its campaign effectiveness and its fund raising effectiveness *f _{i}*. Given the benefits of power,

*G*, the expected return for party

*k*is:

*U _{k} = p_{k} G – x_{k} [ f_{k} ] = x_{k} [ t_{k} ] [ x_{1} / t_{1} + ^{ … } + x_{n / }t_{n} ] G – x_{k} [ f_{k }].*

The model assumes that parties spend the amount that maximizes their expected returns. Under the model assumptions there will always be at least two parties with non-zero expenditures, since a party that finds itself without a spending opponent reduces its spending, until the derivative of the expected return for a competitor becomes positive at *0*.

Let *z _{i} = x_{i} [ t_{i} ] [ G ], Z = z_{1} + ^{ … } + z_{n}*, and

*r*=

_{i}*t*Then,

_{i}[ G f_{i}], i = 1, …, n.*U _{k} = G ( z_{k} [ Z ] – r_{k} z_{k} ),*

And

*d U _{k} [ d z_{k} ] = G ( (Z – z_{k}) [ Z^{2} ] – r_{k} )*.

An equilibrium with *n* parties *1, …, n* exists if there exists a solution to the n simultaneous equations,

*d Ri [d z _{i}] = 0, i = 1, …, n,*

such that *z _{i} > 0, i = 1, …, n*.

If the solution exists, then, summing the n equations:

*Z = (n – 1) [ R ],*

where *R = r _{1} + ^{…} + r_{n}.*

Then,

*z _{k} = Z (1 – r_{k} Z).*

Then *z _{k} > 0* if

*r*, which is true if and only if

_{k}> [ Z ] = R [ n – 1 ]*r _{k} > (R – r_{k}) [ n – 2 ].*

Thus, a solution exists if

*min _{k} r_{k} = r_{(n)} > (r_{(1)} + ^{…} + r_{(n – 1)}) [ n – 2 ],*

and the number of parties at equilibrium will be the maximum number *n* such that

*r _{(n)} ≥ (r_{(1)} + ^{…} + r_{(n – 1)}) [ n – 2 ].*

In particular, this implies that any party which has *r > r _{(1)} + r_{(2)}* will have negative benefit from engaging in an election campaign.