## 1. Introduction

Heterogeneous agent models are present in various fields of economic analysis, such as market maker models, exchange rate models, monetary policy models, overlapping generations models and models of socio-economic behaviour. Yet the field with the most systematic and perhaps most promising nonlinear dynamic approach seems to be asset price modelling. Contributions by Brock and Hommes (1998), LeBaron (2000), Hommes et al. (2002), Chiarella and He (2002), Chiarella et al. (2003), Gaunersdorfer et al. (2003), Brock et al. (2005), Hommes et al. (2005), and Hommes (2006) thoroughly demonstrate how a simple standard pricing model is able to lead to complex dynamics that makes it extremely hard to predict the evolution of prices in asset markets. The main framework of analysis of such asset pricing models constitutes a financial market application for the evolutionary selection of expectation rules, introduced by Brock and Hommes (1997a) and is called the adaptive belief system.

As a model in which different agents have the ability to switch beliefs, the adaptive belief system in a standard discounted value asset pricing set-up is derived from mean-variance maximization and extended to the case of heterogeneous beliefs (Hommes, 2006, p. 47). It can be formulated in terms of deviations from a benchmark fundamental and therefore used in experimental and empirical testing of deviations from the rational expectations benchmark. Agents are boundedly rational, act independently of each other and select a forecasting or investment strategy based upon its recent relative performance. The key feature of such systems, which often incorporate active learning and adaptation, is endogenous heterogeneity (* cf*. LeBaron, 2002), which means that markets can move through periods that support a diverse population of beliefs, and others in which these beliefs and strategies might collapse down to a very small set.

The mixture of different trader types leads to diverse dynamics exhibiting some stylized, qualitative features observed in practice on financial markets (* cf*. Campbell et al., 1997; Johnson et al., 2003), e.g. persistence in asset prices, unpredictability of returns at daily horizon, mean reversion at long horizons, excess volatility, clustered volatility, and leptokurtosis of asset returns. An important finding so far was that irregular and chaotic behaviour is caused by rational choice of prediction strategies in the bounded-rationality framework, and that this also exhibits quantitative features of asset price fluctuations, observed in financial markets. Namely, due to differences in beliefs these models generate a high and persistent trading volume, which is in sharp contrast to no trade theorems in rational expectations models. Fractions of different trading strategies fluctuate over time and simple technical trading rules can survive evolutionary competition. On average, technical analysts may even earn profits comparable to the profits earned by fundamentalists or value traders.

While recent literature on asset price modelling focuses mainly on impacts of heterogeneity of beliefs in the standard adaptive belief system as set up by Brock and Hommes (1997a) on market dynamics and stability on one hand, and the possibility of the survival of such ‘irrational’ and speculative traders in the market on the other, several crucial issues regarding the foundations of asset price modelling and its underlying theoretical findings remain open and indeterminate. One of those issues is related to heterogeneity in investors’ time horizon; both their planning and their evaluation perspective. Namely, it has been scarcely addressed so far how memory in the fitness measure, i.e. the share of past information that boundedly rational economic agents take into account as decision makers, affects stability of evolutionary adaptive systems and survival of technical trading.

LeBaron (2002) was using simulated agent-based financial markets of individuals following relatively simple behavioural rules that are updated over time. Actually, time was an essential and critical feature of the model. It has been argued that someone believing that the world is stationary should use all available information in forming his or her beliefs, while if one views the world as constantly in a state of change, then it will be better to use time series reaching a shorter length into the past. The dilemma is thus seen as an evolutionary challenge where long-memory agents, using lots of past data, are pitted against short-memory agents to see who takes over the market. Agents with a short-term perspective appear to both influence the market in terms of increasing volatility and create an evolutionary space where they are able to prosper. Changing the population to more long-memory types has led to a reliable convergence in strategies. Memory or perhaps the lack of it therefore appeared to be an important aspect of the market that is likely to keep it from converging and prevent the elimination of ‘irrational’, speculative strategies from the market.

Honkapohja and Mitra (2003) provided basic analytical results for dynamics of adaptive learning when the learning rule had finite memory and the presence of random shocks precluded exact convergence to the rational expectations equilibrium. The authors focused on the case of learning a stochastic steady state. Even though their work is not done in the heterogeneous agent setting, the results they obtained are interesting for our analysis. Their fundamental outcome was that the expectational stability principle, which plays a central role in situations of complete learning, as discussed e.g. in Evans and Honkapohja (2001), retains its importance in the analysis of incomplete learning, though it takes a new form. In the models that were analyzed, expectational stability guaranteed stationary dynamics in the learning economy and unbiased forecasts.

Chiarella et al. (2006) proposed a dynamic financial market model in which demand for traded assets had both a fundamentalist and a chartist component in the boundedly rational framework. The chartist demand was governed by the difference between current price and a (long-run) moving average. By examining the price dynamics of the moving average rule they found out that an increase of the window length of the moving average rule can destabilize an otherwise stable system, leading to more complicated, even chaotic behaviour. The analysis of the corresponding stochastic model was able to explain various market price phenomena, including temporary bubbles, sudden market crashes, price resistance and price switching between different levels.

The objective of this chapter is to lay the foundations for a competent and critical theoretical analysis setting the memory assumption in a simple, analytically tractable asset pricing model with heterogeneous beliefs. We shall thus analyze the effects of additional memory in the fitness measure on evolutionary adaptive systems and the nature of consequences for survival of technical trading. In order to examine our research hypothesis adequately, both analytical and numerical analysis will have to be employed and complemented. Therefore, we shall first expand the asset pricing model to include more memory, and then solve it both analytically and numerically. Two cases are going to be analyzed, hopefully sufficiently general to cover some main aspects of financial markets; (1) a two-type case of fundamentalists versus contrarians and (2) a three-type case of fundamentalists versus opposite biased beliefs. Complementing the stability analysis with local bifurcation theory (* cf*. Awrejcewicz, 1991; Palis and Takens, 1993; Kuznetsov, 1995; Awrejcewicz and Lamarque, 2003), we will also be able to analyze numerically the effects of adding different amounts of additional memory to fitness measure on stability of the standard asset pricing model and survival of technical trading. Thus the analysis of both local and global stability can be performed for different combinations of trader types in the market.

## 2. The heterogeneous agents model

The adaptive belief system employs a mechanism dealing with interaction between fractions of market traders of different types, and the distance between the fundamental and the actual price. Financial markets are thus viewed as an evolutionary system, where price fluctuations are driven by an evolutionary dynamics between different expectation schemes. Pioneering work in this field has been done by Brock and Hommes (1997a), who attempted to conciliate the two main perspectives concerning economic fluctuations, i.e. the new classical and the Keynesian view (* cf*. Hommes, 2006, pp. 1-5), and the underlying rules relating to the formation of expectations. In order to get some insight into possible ways of theoretical analysis to follow, we shall describe a simple, analytically tractable version of the asset pricing model as constructed by Brock and Hommes (1998). The model can be viewed as composed of two simultaneous parts; present value asset pricing and the evolutionary selection of strategies, resulting in equilibrium pricing equation and fractions of belief types equation. We shall also make an indication of where memory in the fitness measure (and in expectation rules) enters the model and how it might affect the analysis.

### 2.1. Present value asset pricing

The model incorporates one risky asset and one risk free asset. The latter is perfectly elastically supplied at given gross return * R*, where

*= 1 +*R

*. Investors of different types*r

*have different beliefs about the conditional expectation and the conditional variance of modelling variables based on a publicly available information set consisting of past prices and dividends. The present value asset pricing part of the adaptive demand system is used to model each investor type as a myopic mean variance maximizer of expected wealth demand,*h

E

_{h,t}

W

_{t}, for the risky asset:

where _{t} is the price (ex dividend) at time * t*per share of risky asset,

y

_{t}is an IID dividend process at time

*of the risky asset,*t

z

_{h,t}is number of shares purchased at date

*by agent of type*t

*, and*h

In order to perform myopic mean variance maximization of expected wealth demand for risky asset of type * h*, we seek for

z

_{h,t}that solves:

and thus:

where the belief about expected value of wealth at time * t*+ 1, conditional on all publicly available information at time

*, for a trader of type*t

*is*h

*, which is constant over time*a

Gaunersdorfer (2000) investigated the case of time varying variance and supported the assumption of a constant and homogeneous variance term.

.Solving this optimization problem produces quantities of shares purchased by agents of different types, which enables us to seek for the equilibrium between the constant supply of the risky asset per trader ^{s} and the sum of demands:

where the fraction of traders of type * h*out of altogether

*types at time*H

*is denoted by*t

n

_{h,t}, where

where

In the simplest case of IID dividends with mean _{t} at time * t*is determined by:

where a noise term is included, which represents random fluctuations in the supply of risky shares. Considering a special case with a constant zero supply of outside shares, i.e.

_{t}

*= 0, we obtain:*z

^{s}

If we instead consider for a moment the case of homogeneous beliefs with no noise and all traders being rational, the pricing equation simplifies to:

In equilibrium the expectations of the price will be the same and equal to the fundamental price. The constant fundamental value of the price of the risky asset p* in the case of homogeneous beliefs is derived from the expression:

By imposing a transversality condition on expression (7) with infinitely many solutions we exclude bubble solutions (* cf*. Cuthbertson, 1996) and expression (8) now has only one solution. We are thus able to derive the fundamental price as the discounted sum of expected future dividends:

By simplification of the fundamental price equation for the case of the IID dividend process with constant conditional expectation we thus obtain the standard benchmark notion of the ‘fundamental’, i.e.

Taking into account the appropriate form of heterogeneous beliefs of future prices, i.e. including some deterministic function * f*, which can differ across trader types:

_{h,t}

we restrict beliefs about the next deviation of the actual from the fundamental price, * x*, to deterministic functions of past deviations from the fundamental:

_{t}

where * L*is the number of lags of past information, taken into account. Since the deterministic function in the expectation rule depends on preceding price deviations, it can also be seen as including memory. However, due to rapidly increasing analytical complexity,

*. including more preceding price deviations rapidly increases the dimension of the system, this issue has so far mainly been neglected. In this chapter we are focusing on the memory in the fitness measure and will thus include only one lag in the memory in the expectation rule, i.e.*viz

Taking into account that* x*=

_{t}

*–*p

_{t}

**:*p

The particular form of deterministic function in the forecasting or expectation rule is thus what determines different types of heterogeneous agents in an adaptive belief system. In general, we distinguish between two typical investor types; fundamentalists and ‘noise traders’ or technical analysts. Fundamentalists believe that the price of an asset is defined solely by its efficient market hypothesis fundamental value (Fama, 1991), i.e. the present value of the stream of future dividends. Since they have no knowledge about other beliefs and fractions, * f*0. Actual financial data show that fundamentalists have a stabilizing effect on prices (De Grauwe and Grimaldi, 2006).

_{h,t}

Technical analysts or chartists, on the other hand, believe that asset prices are not completely determined by fundamentals, but may be predicted by inferences on past prices. Depending on the purpose of analysis, it is possible to distinguish between (pure) trend chasers with expectation rule* g*is the trend and

_{h}

*is the bias (difference between*b

_{h}

** and trader’s belief of*p

**) of the trader of type*p

*.*h

### 2.2. Evolutionary selection of strategies

In order to be able to understand the dynamics of fractions of different trader types, we consider the appropriate formulations of realized excess return * R*from expression (1), and demand of different types of market traders,

_{t}

where * C*represents the costs traders have to pay to use strategy

_{h}

*. Albeit introducing additional analytical complexity, we usually take into account the costs for predictor of particular trader type, since more information-intense predictors are evidently more costly. It is of course convenient to rewrite profits of different types of traders in terms of deviations from the benchmark fundamental:*h

The fitness function or performance measure of each trader type can now be defined in terms of its realized profits. In fact, it can be expressed as the weighted sum of realized profits, i.e. as the sum of current realized profits and a share of past fitness, which is in turn defined as past realized profits:

where current realized profits are defined in the following final form:

The fitness function can for _{h}_{,0} = 0 also be rewritten in the following expanded form with exponentially declining weights:

In case of the equilibrium pricing equation, herein formulated as the sum over trader types of products of a fraction of particular trader type and its deterministic function, the fitnesses enter the adaptive belief system before the equilibrium price is observed. This is suitable for analyzing the asset pricing model as an explicit nonlinear difference equation. Even though nonlinear asset pricing dynamics can be modelled either as a deterministic or a stochastic process, only the latter enables investigation of the effects of noise upon the asset pricing dynamics.

The share of past fitness in the performance measure is expressed by the parameter w; 0 w 1, called memory strength. When the value of this parameter is zero (w = 0), the fitness is given by most recent net realized profit. Due to analytical tractability this is at present, y for the most part, the case in the existing literature on asset pricing models with heterogeneous agents, though not in this chapter. The main contribution of this chapter is that it analyzes the case of nonzero memory in the fitness measure. When the memory strength parameter takes a positive value, some share of current realized profits in any given period is taken into account when calculating the performance measure in the next time period. If the value of memory strength parameter amounts to one then of course the entire accumulated wealth is taken into account.

The expression (14) for the fitness function is somewhat different that the one used in Brock and Hommes (1998), where the coefficient of the current realized profits was fixed to 1. Namely, if we rewrite the memory strength parameter as

which is equivalent to taking the last T observations into account with equal weight (as benchmark). When T approaches infinity, the memory parameter approaches 1 and the entire accumulated wealth is taken into account. We thus believe the expression (14) to be a more suitable formulation of the fitness measure than the one used in Brock and Hommes (1998), and in several other contributions.

Finally, we can express fractions of belief types, * n*, which are updated in each period, as a discrete choice probability by a multinomial logit model:

_{h,t}

by using parameter , determining the intensity of choice. The latter measures how fast economic agents switch between different prediction strategies; if the value of intensity of choice is zero, then all trader types have equal weight and the mass of traders distributes itself evenly across the set of available strategies, while on the other hand the entire mass of traders tends to use the best predictor, i.e. the strategy with the highest fitness, when the intensity of choice approaches infinity (the neoclassical limit).

Trader fractions are therefore determined by fitness and intensity of choice. Rationality in the asset pricing model is evidently bounded, since fractions are ranked according to fitness, but not all agents choose the best predictor. To ensure that fractions of belief types depend only upon observable deviations from the fundamental at any given time period, fitness function in the fractions of belief types equation may only depend on past fitness and past return. This indeed ensures that past realized profits are observable quantities that can be used in predictor selection.

One might wonder whether the traders’ myopic mean-variance maximization is a reasonable assumption, especially when we allow for traders with a longer memory span. This assumption is widely used in modelling in economics and finance, though it would certainly be interesting to let traders plan longer ahead, even with an infinite planning horizon, as in the Lucas (1978) asset pricing model. However, in this kind of model one usually assumes perfect rationality to keep the analysis tractable. So far very little work has been done on infinite horizon models with bounded rationality and heterogeneous beliefs. Furthermore, one can also discuss whether individuals are really able to plan over a long horizon, or whether they might use simple heuristics over a short horizon and occasionally adapt them. After all, memory in the fitness measure is not equivalent to the planning horizon, but rather an “evaluation horizon” used to decide whether or not to switch strategies. There is empirical and experimental evidence that humans give more weight to the recent past than the far distant past, and this is formalized in our model.

## 3. Fundamentalists versus Contrarians

The first case we are going to examine is a two-type heterogeneous agents model with fundamentalists and contrarians as market participants. Fundamentalists exhibit deterministic function of the form:

and have some positive information gathering costs * C*, i.e.

*> 0. Contrarians exhibit a deterministic function:*C

and zero information gathering costs. It is thus a case of fundamentalists versus pure contrarians. We have the following fractions of belief types equation:

For convenience we shall also introduce a difference in fractions * m*:

_{t}

Finally, we have the fitness measure equation of each type:

In order to analyze memory in our heterogeneous asset pricing model, we shall first determine the position and stability of the steady state and the period two-cycle in relation to the memory strength parameter. We will also examine the possible qualitative changes in dynamics. Then we will perform some numerical simulations to combine global stability analysis with local stability analysis.

### 3.1. Position of the steady state

In our two-type heterogeneous agents model of fundamentalists versus contrarians the equilibrium pricing equation has the following form:

where

A steady state price deviation * x*is a fixed point of the system, if it satisfies

*=*x

*(*f

*) for mapping*x

*(*f

*). In our two-type heterogeneous agents model of fundamentalists versus contrarians we have:*x

where either

Since it follows from expressions (22) and (23) that * w*1, the steady state difference in fractions simplifies:

Possible other (non-fundamental) steady states should satisfy:

Since it can be derived that

Therefore we can state the following lemma.

Proof. of Lemma 1:

### 3.2. Stability of the steady state

In order to analyze stability of the steady state we shall rewrite our system as a difference equation:

where

We therefore obtain the following 5-dimensional first-order difference equation:

The local stability of a steady state is determined by the eigenvalues of the Jacobian matrix, which we do not present here due to the spatial limitations. We then compute the Jacobian matrix of the 5-dimensional map. At the fundamental steady state X^{eq} = (0, 0, 0, –C, 0) we obtain the new Jacobian matrix. A straightforward computation shows that the characteristic equation is in our case given by:

with solutions (eigenvalues):^{eq} is stable for

Thus we can state the following lemma.

Proof. of Lemma 2:

* From the characteristic*equation (36)

we can observe three eigenvalues, where two of them are in fact double eigenvalues. The first eigenvalue assures stability when

, while the second and third (double) eigenvalue always assure stability. The fundamental steady state is stable for

, but since

depends on other parameters of the system and g < 0, stability is (more conveniently) guaranteed at least for

. Since the memory strength parameter is represented (only) by the third (double) eigenvalue, memory does not affect the stability of the steady state, as has been shown by the reduced system.

### 3.3. Bifurcations and the Period Two-cycle

A bifurcation is a qualitative change of the dynamical behaviour that occurs when parameters are varied (Brock and Hommes, 1998). A specific type of bifurcation that occurs when one parameter is varied is called a co-dimension one bifurcation. There are several types of such bifurcations, * viz*. period doubling, saddle-node and Hopf bifurcations. The first type has eigenvalue –1 of the Jacobian matrix, the second type has eigenvalue 1 and the third type has complex eigenvalues on the unit circle.

If we take a look at the eigenvalue _{1}, which we are in our case interested in, we can observe that a saddle-node bifurcation can never occur. Namely, the expression:

can never hold, since the left-hand side is a positive constant and the right-hand side is always negative for * g*< 0,

*> 0 and*R

may be satisfied for-value:

which has been computed by plugging .

Now we can check the existence of a period two-cycle

Therefore we can state the following lemma.

^{eq}) is unstable for g < –2R and there exists a period two-cycle^{eq}) is the unique, globally stable steady state, while (2) if^{eq}) is unstable and there exists a period two-cycle

Proof. of Lemma 3:

* For g < –2R it is clear from the expression for eigenvalue *equation (36)

_{1}of the characteristic

that the fundamental steady state is unstable. Furthermore, since 0 < m

^{*}< 1, the expression (40) has two solutions, x

^{*}and –x

^{*}. If expression (38) is satisfied, it then follows from expressions

and (40) that

is a period two-cycle. Finally, for –2R < g < –R, the fundamental steady state is unstable and expression (40) has solutions

if and only if

. Since the memory strength parameter does not affect the difference in fractions of belief types, memory does not affect the position of the period two-cycle.

As in the paper of Brock and Hommes (1998), very strong contrarians with * g*< –2

*may lead to the existence of a period two-cycle, even when there are no costs for fundamentalists (*R

*= 0). When the fundamentalists’ costs are positive (*C

*> 0), strong contrarians with –2*C

*<*R

*< –*g

*may lead to a period two-cycle. As the intensity of choice increases to*R

*=*

**, a period doubling bifurcation occurs in which the fundamental steady state becomes unstable and a (stable) period two-cycle is created, with one point above and the other one below the fundamental.*

When the intensity of choice further increases, we are likely to find a value =

***, for which the period two-cycle becomes unstable and a Hopf bifurcation of this period two-cycle occurs, as in Brock and Hommes (1998). The model would then get an attractor consisting of two invariant circles around each of the two (unstable) period two-points, one lying above and the other one below the fundamental. Immediately after such a Hopf bifurcation, the price dynamics is either periodic or quasi-periodic, jumping back and forth between the two circles. The proof of this phenomenon is not straightforward due to the non-zero period points, although the 5-dimensional system (31) – (35) is still symmetric with respect to the origin. We shall thus demonstrate the occurrence of the Hopf bifurcation and the emergence of the attractor numerically in the next section.*

### 3.4. Numerical analysis

Our numerical analysis in the case of fundamentalists and contrarians will be conducted for fixed values of parameters * R*= 1.1,

*= 1.0,*k

*= 1.0 and*C

*= –1.5. We shall thus vary the intensity of choice parameter*g

*and of course the memory strength parameter*

*. Four analytical tools will be used*w

However, we will not discuss these tools here in more detail, since they are fairly well-known; instead we will direct the interested reader to more detailed discussions in Arrowsmith and Place (1990), Shone (1997), and Brock and Hommes (1998).

; bifurcation diagrams, largest Lyapunov characteristic exponent (LCE) plots, phase plots, and time series plots.The dynamic behaviour of the system can first and foremost be determined by investigating bifurcation diagrams. In Figure 1 the bifurcation diagrams for two different values of the memory strength parameter are presented. We can observe that for low values of we have a stable steady state, i.e. the fundamental steady state. As has been proven in Lemma 1, the position of this steady state, i.e.

*= 0, is independent of the memory, which is clearly demonstrated by the simulations. For increasing*x

^{eq}

*a (primary) period doubling bifurcation occurs at*

*=*

**; the steady state becomes unstable and a stable period two-cycle appears, as proven in Lemma 3. As can be seen from the simulations, this bifurcation value is also independent of the memory. The stability of the steady state is thus unaffected by the memory, as proven in Lemma 2.*

If increases further, indeed a (secondary) Hopf bifurcation occurs at

*=*

***, as has been claimed in Section 3.3; the period two-cycle becomes unstable and an attractor appears consisting of two invariant circles around each of the two (unstable) period two-points, one lying above and the other one below the fundamental. It is a supercritical Hopf bifurcation, where the steady state gradually changes either into an unstable equilibrium or into an attractor (*

*. Guckenheimer and Holmes, 1983; Frøyland, 1992; Kuznetsov, 1995). The position of the period two-cycle is independent of the memory, but it is not independent of the intensity of choice, as can be seen from expression (40). Numerical simulations suggest that the secondary bifurcation value also does not vary with changing memory strength parameter*cf

*. For*w

*>*

*** chaotic dynamic behaviour appears, which is interspersed with many (mostly higher order) stable cycles. Such a bifurcation route to chaos was also called the rational route to randomness (Brock and Hommes, 1997a), while the last part of it has been referred to as the breaking of an invariant circle.*

By examining largest Lyapunov characteristic exponent (LCE) plots of we arrive at the same conclusions about the dynamic behaviour of the system. It can be seen from Figure 1 that the largest LCE is smaller than 0 and the system is thus stable until the primary bifurcation, which is independent of memory. At the bifurcation value, a qualitative change in dynamics occurs, i.e. a period doubling bifurcation and we obtain a stable period two-cycle. Largest LCE is again smaller than 0 and the system is thus stable until the secondary bifurcation. At this bifurcation value, again a qualitative change in dynamics occurs, i.e. a Hopf bifurcation, but the dynamics is more complicated.

For lower values of * w*the largest LCE after

*** is non-positive, but close to 0, which implies quasi-periodic dynamics. After some transient period the largest LCE becomes mainly positive with exceptions, which implies chaotic dynamics, interspersed with stable cycles. In fact, the largest LCE plot has a fractal structure (*

*. Brock and Hommes, 1998, p. 1258). In the case of*cf

*= 0.9 the global dynamics after*w

*** immediately becomes chaotic. Memory thus certainly affects the dynamics after the secondary bifurcation. Since the latter is a period doubling bifurcation, we are talking about period doubling routes to chaos.*

Next, we shall examine plots of the attractors in the (* x*,

_{t}

x

_{t}

_{–1}) plane and in the (

*,*x

_{t}

n

_{1,}

*) plane*

_{t}

Attractors in the (xt, n2,t) plane are just flipped (rotated by 180 degrees) images of attractors in the (xt, n1,t) plane and will thus not be separately examined.

without noise and with IID noise added to the supply of risky shares. In the upper left plot of each of the four parts of Figures 2 and 3 we can first observe the appearance of an attractor for the intensity of choice beyond the secondary bifurcation value. The orbits converge on such an attractor consisting of two invariant ‘circles’ around each of the two (unstable) period two-pointsThough we are topologically speaking about circles, the actual shape of such an attractor can be quite diverse, as seen from the figures.

*= 0, whereas the unstable manifold,*x

^{eq}

For as Brock and Hommes (1998, p. 1254) have proven for the asset pricing model without additional memory, at infinite intensity of choice and strong contrarians, * g*< –

*, that unstable manifold*R

Again, we can observe that memory has an impact on the global dynamics of the system. That is, both the convergence of the system on an attractor consisting of two invariant ‘circles’ around each of the two unstable period two-points and the ‘moving’ of the circles closer to each other seem to be happening faster (at lower intensity of choice) when more memory is present in the model. Moreover, at the same intensity of choice we seem to be closer to obtaining a system that has a homoclinic intersection between the stable and unstable manifolds of the fundamental steady state when the memory strength is higher.

Finally, we shall examine time series plots of deviations of the price from the fundamental value and of the fraction of fundamentalists

Since the fraction of contrarians is just the unity complement of the fraction of fundamentalists, i.e. n1,t + n2,t = 1, the former will thus not be separately graphically examined.

. Figure 4 shows some time series corresponding to the attractors in Figures 2 and 3, with and without noise added to the supply of risky shares. Similarly to the findings of Brock and Hommes (1998), we can observe that the asset prices are characterized by an irregular switching between a stable phase with prices close to their (unstable) fundamental value and an unstable phase of up and down price fluctuations with increasing amplitude.This irregular switching is of course reflected in the fractions of fundamentalists and contrarians in the market. Namely, when the oscillations of the price around the unstable steady state gain sufficient momentum, it becomes profitable for the trader to follow efficient market hypothesis fundamental value despite the costs that are involved in this strategy. The fraction of fundamentalists approaches unity and the asset price stabilizes. But then the nonzero costs of fundamentalists bring them into position where they are unable to compete in the market; the fraction of fundamentalists rapidly decreases to zero, while the fraction of contrarians with no costs approaches unity with equal speed. The higher the intensity of choice, * ceteris paribus*, the faster this transition is complete; when

*approaches the neoclassical limit, the entire mass of traders tends to use the best predictor with respect to costs, i.e. the strategy with the highest fitness.*

Additional memory does not change the pattern of asset prices * per se*, but it does affect its period. Namely, at the same intensity of choice and higher memory strength the period of this irregular cycle appears to be elongated on average, in such a way that the stable phase with prices close to their fundamental value lasts longer, while the duration of the unstable phase of up and down price fluctuations does not change significantly. The effect of including more memory thus mainly appears to be stabilizing with regard to asset prices. With regard to fractions of different trader types we could say that including additional memory affects the transition from the short period of fundamentalists’ dominance to the longer period of contrarians’ dominance in the market. This transition takes more time to complete at the same intensity of choice. More memory thus causes the traders to stick longer to the strategy that has been profitable in the past, but might not be so profitable in the recent periods.

## 4. Fundamentalists versus opposite biased beliefs

The second case we are going to examine is a three-type heterogeneous agents model with fundamentalists and opposite biased beliefs as market participants. Fundamentalists again exhibit a deterministic function of the form:

though this time with no information gathering costs, i.e. * C*= 0. Biased beliefs exhibit deterministic functions:

for optimist and pessimist biases, respectively

In this chapter we will mainly focus on the symmetric case.

. Biases also exhibit zero information gathering costs. We have the following fractions of belief types equation:Finally, we have the fitness measures of each type:

In order to analyze memory in our heterogeneous asset pricing model, we shall first determine the position and stability of the steady state, and then examine the possible qualitative changes in dynamics; all in relation to the memory strength parameter. Then we shall perform some numerical simulations to combine global stability analysis with local stability analysis.

### 4.1. Position of the steady state

In our three-type heterogeneous agents model of fundamentalists versus biased beliefs, we shall again start by rewriting our system as a difference equation:

where

We therefore obtain the following 5-dimensional first-order difference equation:

Our three-type heterogeneous agents model of fundamentalists versus biased beliefs in general can have the following steady state price deviations:

We obtain the fundamental steady state for * w*1 and consequently by

By performing a generalization we can state the following lemma.

_{h} (including fundamentalists with b_{1} = 0). Proceeding from the non-transformed variables the system is:

* where r = R – 1. Since a steady state has to satisfy expression (60), following*Brock and Hommes (1998

, p. 1271), a straightforward computation shows that:

_{h} is drawn with probability n_{h}. Therefore,

### 4.2. Stability of the steady state and bifurcations

The local stability of a steady state is again determined by the eigenvalues of the Jacobian matrix. At the fundamental steady state * X*= (0, 0, 0, 0, 0) the Jacobian matrix exhibits the characteristic equation that is in our case given by:

^{eq}

which has the following three solutions, two of them being double:

The fundamental steady state is stable for

Thus we can state the following lemma.

From the characteristic equation (62) we can observe five eigenvalues. The first three eigenvalues always assure stability, while the last two eigenvalues limit stability. Given k > 0, b > 0, 0, R > 1 and 0 w 1, the condition for stability in terms of implies

If we now take a look at the eigenvalues _{4,5} of the characteristic equation (62), which are of interest in our case, we can observe that a saddle-node bifurcation would occur for:

This can never hold, since

This can never hold either, since

The remaining qualitative change of the three discussed in Section 4.3 is the Hopf bifurcation. For this to occur, a complex conjugate pair of eigenvalues has to cross the unit circle. Eigenvalues _{4,5} are complex for

We therefore state the following lemma.

** Lemma 6:**There exists an intensity of choice value * such that the fundamental steady state, which is stable for

As we have just established, in the case of fundamentalists versus opposite biased beliefs increasing intensity of choice to switch predictors destabilizes the fundamental steady state. This happens through a Hopf bifurcation. We can thus conclude, as did Brock and Hommes (1998) for the simpler version of the model, that in the presence of biased agents the first step towards complicated price fluctuations is different from that in the presence of contrarians. This fact does not change when we take memory into account.

Proof. of Lemma 6:

_{4,5} increase as well, and one of the eigenvalues has to cross the unit circle at some critical* . The fundamental steady state thus becomes unstable. Since it is obvious from the characteristic*equation (62)

that for all

we have

and

, a bifurcation has to occur. At the moment of the bifurcation the product of eigenvalues

has to be equal one, i.e.

. This happens either when we have two real eigenvalues with product equal to one or a complex conjugate pair of eigenvalues. Since

falls into the interval (65) for any given finite memory strength, we can conclude that for

the eigenvalues have to be complex and thus a Hopf bifurcation occurs. Since the memory strength parameter is present in the expression for *, memory affects the emergence of this bifurcation; the higher the value of this parameter, the higher the bifurcation value.

### 4.3. Numerical analysis

Our numerical analysis in the case of fundamentalists and opposite biased beliefs will be conducted for fixed values of parameters * R*= 1.1,

*= 1.0,*k

b

_{2}= 0.2 and

b

_{3}= –0.2. We shall thus vary the memory strength parameter

*and the intensity of choice parameter*w

*. The same four analytical tools will be used than in Section 3.4.*

Dynamic behaviour of the system can again first and foremost be determined by investigating bifurcation diagrams. From Figure 5 we can observe that for low values of we have a stable steady state, i.e. the fundamental steady state. As has been proven in Lemma 4, the position of this steady state, i.e.

*= 0, is independent of the memory, which is clearly demonstrated by the simulations. For increasing*x

^{eq}

*a bifurcation occurs at*

*=*

**, which is a Hopf bifurcation; the steady state becomes unstable and an attractor appears, consisting of an invariant circle around the (unstable) steady state. It is again a supercritical Hopf bifurcation, where the steady state gradually changes either into an unstable equilibrium or into an attractor.*

The bifurcation value varies with changing memory strength parameter, as given by expression in Lemma 6. As can also be seen from Figure 5 at higher memory strength the bifurcation occurs later. For >

** complex dynamical behaviour appears, which is interspersed with stable cycles. As we have already discovered in Section 4.2, irrespective of the amount of additional memory that is taken into account such a (bifurcation) route to complicated dynamics is different from that in the presence of contrarians, where we observed period doubling route to chaos (rational route to randomness).*

By examining largest Lyapunov characteristic exponent (LCE) plots of we arrive at more precise conclusions about the dynamic behaviour of the system. It can be seen from Figure 5 that the largest LCE is smaller than 0 and the system is thus stable until the bifurcation. At the bifurcation value a qualitative change in dynamics occurs, i.e. a Hopf bifurcation. The dynamics is somewhat more complicated. Namely, we can observe that the largest LCE after

*=*

** is non-positive, but mainly close to 0, which implies periodic and quasi-periodic dynamics, i.e. for high values of the intensity of choice only regular (quasi-)periodic fluctuations around the unstable fundamental steady state occur. An important finding is that the predominating quasi-periodic dynamics does not seem to evolve to chaotic dynamics and the route to complex dynamics is indeed different from the routes examined so far.*

Next, we shall examine plots of the attractors in the planes, determined by (* x*,

_{t}

x

_{t}

_{–1}) and (

*,*x

_{t}

n

_{1,t}). In the upper left plot of each of the two parts of Figure 6 we can first observe the appearance of an attractor for the intensity of choice beyond the bifurcation value. The orbits converge to such an attractor consisting of an invariant ‘circle’ around the (unstable) fundamental steady state. The attractor obtained in the (

*,*x

_{t}

n

_{1,t}) plane is somewhat different. Namely, the unstable steady state dissipates into numerous points and evolves into a ‘loop’ shape, as shown in Figure 7.

As the intensity of choice increases, the dynamics remains periodic or quasi-periodic; in case of past deviations of prices from the fundamental value and fractions of biased beliefs the invariant circle slowly changes its shape into a ‘(full) square’ (see Figure 6), while in case of fractions of fundamentalists the loop slowly changes into a ‘three-sided square’ (see Figure 7). For high values of intensity of choice we seem to obtain (stable) higher period cycles; in the case of past deviations of prices from the fundamental value and fractions of biased beliefs we seem to attain a stable period four-cycle, while in the case of fractions of fundamentalists it is difficult to obtain any solid indications based solely on numerical simulations due to convergence problems for very high values of intensity of choice. In the latter case we can observe stable period four- and six-cycles, however (see lower right plot of each of the two parts of Figure 7). Indeed, Brock and Hommes (1998) proved for the case of exactly opposite biased beliefs and infinite intensity of choice in their simpler version of the model without additional memory that the system has a stable four-cycle attracting all orbits, except for hairline cases converging on the unstable fundamental steady state. Additionally, they discovered that for all three trader types average profits along the four-cycle equal ^{2}.

Again, we can observe that the memory has an impact on the dynamics of the system. Namely, both the convergence of the system on an attractor and the further development of such an attractor seem to be dependent on the value of the memory strength parameter. The precise impact of memory is somewhat more difficult to establish due to the dependence of the bifurcation value on memory strength and the subsequent need to choose higher intensities of choice with higher memory strength in order to demonstrate different nature of attractors of the system. However, we can still establish that at the same intensity of choice (after the bifurcation value) the system apparently needs less additional memory in order to develop a specific stage of an attractor or even a (stable) higher period cycle.

Finally, we shall examine time series plots of deviations of the price from the fundamental value and of the fractions of all three types of traders. Figure 8 shows some time series corresponding to the attractors in Figures 6 and 7. We can observe that opposite biases may cause perpetual oscillations around the fundamental, even when there are no costs for fundamentalists, but can not lead to chaotic movements. Furthermore, as has already been indicated by the appearance of stable higher period cycles for high intensities of choice, in a three-type world, even when there are no costs and memory is infinite, fundamentalist beliefs can not drive out opposite purely biased beliefs, when the intensity of choice to switch strategies is high.

Hence, according to the argumentation of Brock and Hommes (1998, p. 1260), the market can protect a biased trader from his own folly if he is part of a group of traders whose biases are ‘balanced’ in the sense that they average out to zero over the set of types. Centralized market institutions can make it difficult for unbiased traders to prey on a set of biased traders provided they remain ‘balanced’ at zero. On the other hand, in a pit trading situation unbiased traders could learn which types are balanced and simply take the opposite side of the trade. In such situations biased traders would be eliminated, whereas a centralized trading institution could ‘protect’ them.

Additional memory does not change the pattern of asset prices and trader fractions * per se*, but it does affect its period. Namely, at the same intensity of choice and higher memory strength the period of these cycles appears to be elongated on average, in a way that both the negative and the positive deviation of the price from the fundamental value last longer. The same is valid for fractions ob biased traders, while in the case of fractions of fundamentalists the prolongation of the period of the irregular cycle appears in the form of less frequent ‘spikes’, which is understandable, since more persistent deviations of prices from the fundamental imply more space for biased traders and less chance for appearance of the fundamentalists. More memory causes the traders to stick longer to the strategy that has been profitable in the past, but might not be so profitable in the recent periods; therefore the system approaches purely quasi-periodic dynamics when the memory strength increases at given intensity of choice.

## 5. Concluding remarks

In a market with fundamentalists and contrarians the fundamental steady state is the unique steady state of the system, which arises for low values of intensity of choice. Memory affects neither the position of this steady state nor its stability. For increasing intensity of choice a primary bifurcation, i.e. a period doubling bifurcation occurs; the steady state becomes unstable and a stable period two-cycle appears. Both the primary bifurcation value and the position of the period two-cycle are independent of the memory. For further increasing intensity of choice a secondary bifurcation, i.e. a supercritical Hopf bifurcation, occurs; the period two-cycle becomes unstable and an attractor appears consisting of two invariant circles around each of the two (unstable) period two-points, one lying above and the other one below the fundamental. For high intensity of choice chaotic asset price dynamics occurs, interspersed with many stable period cycles. Such a bifurcation route to chaos is often called the rational route to randomness.

In case of strong contrarians and high intensity of choice it is reasonable to expect that we will obtain a system that is close to having a homoclinic intersection between the stable and unstable manifolds of the fundamental steady state, which indicates the occurrence of chaos. There exists a certain limited interval of memory strength values, for which at a given intensity of choice we are more likely to obtain such a system with more additional memory in the model. A rational choice between fundamentalists’ and contrarians’ beliefs triggers situations that do not reach fruition due to practical considerations and are thus unattainable, ‘castles in the air’, as Brock and Hommes (1998, p. 1258) would put it. As a consequence we obtain market instability, characterized by irregular up and down oscillations around the unstable efficient market hypothesis fundamental price. Additional memory lengthens on average the period of this irregular cycle and mainly appears to be stabilizing with regard to asset prices.

In a market with fundamentalists and opposite biases the fundamental steady state is also the unique steady state of the system, arising for low values of intensity of choice. Memory does not affect the position of this steady state, but does affect its stability. For increasing intensity of choice a supercritical Hopf bifurcation occurs; the steady state becomes unstable and an attractor appears. Memory affects the emergence of this bifurcation; the higher the memory strength, the higher the bifurcation value. More memory thus has a stabilizing effect on dynamics. For high intensity of choice the dynamic behaviour is more complex. However, irrespective of the amount of additional memory such a route to complicated dynamics is different from that in the presence of contrarians, for after the bifurcation value only regular (quasi-)periodic fluctuations around the unstable fundamental steady state occur. Consequently, an important finding is that the predominating quasi-periodic dynamics does not seem to evolve to chaotic dynamics.

After the incidence of the bifurcation the higher value of the memory strength parameter causes the dynamics to be less periodic and more quasi-periodic; the dynamics therefore converges on purely quasi-periodic behaviour with increasing memory strength. Opposite biases may cause perpetual oscillations around the fundamental, even without costs for fundamentalists, but can not lead to chaotic movements. Furthermore, in a three-type world, even when there are no costs and memory is infinite, fundamentalist beliefs can not drive out opposite purely biased beliefs, when the intensity of choice to switch strategies is high. Hence, following the argumentation of Brock and Hommes (1998, p. 1260), the market can protect a biased trader from his own folly if he is part of a group of traders whose biases are balanced.

In conclusion, both our analytical work and our numerical simulations suggest that biases alone do not trigger chaotic asset price fluctuations. Sensitivity to initial states and irregular switching between different phases seem to be triggered by trend extrapolators; in our case by contrarians. Apparently, some (strong) trend extrapolator beliefs are needed, such as strong trend followers or strong contrarians, in order to trigger chaotic asset price fluctuations. A key feature of our heterogeneous beliefs model is that the irregular fluctuations in asset prices are triggered by a rational choice in prediction strategies, based upon realized profits, * viz*. the observed deviations from the fundamentals are driven by short-run profit seeking. We can also talk about rational animal spirits that, according to Brock and Hommes (1997b), exhibit some qualitative features of asset price fluctuations in the actual financial markets, such as the autocorrelation structure of prices and returns.

## Acknowledgement

I am grateful for very helpful suggestions and comments from Cars H. Hommes, Valentyn Panchenko, Jan Tuinstra and Florian O. O. Wagener from the University of Amsterdam.

## Notes

- Gaunersdorfer (2000) investigated the case of time varying variance and supported the assumption of a constant and homogeneous variance term.
- However, we will not discuss these tools here in more detail, since they are fairly well-known; instead we will direct the interested reader to more detailed discussions in Arrowsmith and Place (1990), Shone (1997), and Brock and Hommes (1998).
- Attractors in the (xt, n2,t) plane are just flipped (rotated by 180 degrees) images of attractors in the (xt, n1,t) plane and will thus not be separately examined.
- Though we are topologically speaking about circles, the actual shape of such an attractor can be quite diverse, as seen from the figures.
- Since the fraction of contrarians is just the unity complement of the fraction of fundamentalists, i.e. n1,t + n2,t = 1, the former will thus not be separately graphically examined.
- In this chapter we will mainly focus on the symmetric case.