Trade and the allocation of talent with capital market imperfections ☆

Tradeliberalizationinthe1980sand1990shasbeenassociatedwithasharpincreaseintheskillpremiumin both developed and developing countries. This is in apparent con ﬂ ict with neoclassical theory, according to which trade should decrease the relative return on the relatively scarce factor, and thus decrease the skill premium in skill-scarce developing countries. We develop a simple model of trade with talent heterogeneity and capital market imperfections, and show that trade can increase the skill premium in a skill-scarce South that opens upto askill-abundantNorth,bothintheshortrun aswellasinthelongrun.Weshowthattradehastwoeffects: itreduces the skilled wage, and therefore drives non talentedagents out ofthe skilledlabor force.It alsoreduces the cost of subsistence, thereby allowing the talented offspring of unskilled workers to go to school. This compositional effect has a positive effect on the observed skill premium, potentially strong enough to out- weigh the decrease in the skilled wage. In our framework, trade liberalization may trigger an increase in the skill-premium in both the North and the South.


Introduction
One of the most important results in Heckscher-Ohlin models of international trade, the Stolper-Samuelson theorem, predicts that when a country opens up to international tradeand thus, its relative price of skill-intensive goods decreasesthe return of unskilled workers should increase, relative to the return of skilled workers. 1 This prediction has been confirmed in a number of unskilled labor-abundant "early globalizers" (such as Italy, Singapore, South Korea and Taiwan) where trade has increased the unskilled wage relative to the skilled wage (thus decreasing the skill premium). However in the case of unskilled labor-abundant countries that have globalized in the 1980s and 1990s (such as most of Latin America, India and Hong Kong), trade seems to have increased the skill premium, rather than reducing it. 2 This fact, sometimes called the "skill premium puzzle", has attracted a fair bit of attention. On the one hand, the trade literature has sought to reconcile the Latin American experience with Heckscher-Ohlin theory (HO from now on) by arguing that trade liberalization disproportionately affected unskilled labor-intensive industries (Revenga, 1997), or that countries such as China, Indonesia and Pakistan made the world outside Latin America actually unskilled labor-abundant (Davis, 1996;Wood, 1999). In these contexts, HO theory would correctly predict an increase in the skill premium in Latin America. One problem with these interpretations is that they predict that skill intensity should have decreased across sectors in Latin America, a prediction that has not been confirmed in the data. 3 In response to these shortcomings, the literature has turned to alternative trade models to explain the generalized increase in wage inequality, 4 or to non-trade explanations, such as, skill biased technical change.
In this paper, we propose a way to reconcile a traditional HO model of trade liberalization between an unskilled labor-abundant South and a skill labor-abundant North with an increase of the skill premium in the South as well as in the North. We do so by enriching the baseline model with talent heterogeneity, human capital accumulation, and credit constraints. The literature on trade liberalization in the presence of credit constraints (discussed below in detail) has shown that trade may increase human capital accumulation by relaxing the credit constraints faced by the poor, thereby improving their access to the education system. We show that when this is the case, trade may improve the allocation of talent to the skilled labor force, both in the short and in the long run. This compositional effect generates an upward pressure on the observed skilled wage, which can be strong enough to overturn the Stolper-Samuelson prediction of a lower skill premium in the South following trade liberalization. While reconciling the Stolper-Samuelson theorem with the Latin American experience, our model preserves the other main features of standard HO theory, including the fact that all industries in the South become more skill-intensive after trade liberalization. 5 Our mechanism works as follows. Because of capital market imperfections, young agents cannot borrow to pay for their subsistence while attending school. Thus, only those whose parents have a high wage can possibly go to school. In an economy with little human capital, unskilled wages are low, and the cost of subsistence is high relative to the income of unskilled workers. This creates one equilibrium in which there are few skilled workers, the skilled wage is high, and all and only the offspring of skilled workers go to school. With heterogeneous talent, this equilibrium is "bad" in efficiency terms, in that many talented offspring of unskilled workers are prevented from going to school while many offspring of skilled workers go to school despite being non-talented. This is in contrast to a "good" equilibrium in which there are many skilled workers, the skilled wage is low, and all and only the talented workers go to school independently of the economic status of their families.
We consider an economy that is skill-scarce because it is stuck at the bad equilibrium, and study its reaction to the liberalization of trade with a skill-abundant world. By putting a downward pressure on the skilled wage, trade may induce many non-talented skilled workers to drop out of the skilled labor force. At the same time, it reduces the cost of subsistence for unskilled workers, thus making it easier for their offspring to go to school. Because many of these previously-excluded agents are highly talented, they may still find it optimal to join the skilled labor force despite the trade-induced drop in the skilled wage. These two effects may move the economy from its initial equilibrium to the good equilibrium, thus increasing the average quality of the skilled labor force. This creates an upward force on the average observed skill premium, that can more than compensate the negative effect of trade on the skilled wage. Thus, the skill premium may increase in the skill-scarce country, both in the short run and in the long run. 6 Our results suggest that the Stolper-Samuelson theorem needs to be modified in the context of talent heterogeneity and imperfect credit markets, to account for the possibility of compositional changes in the skilled labor force.
The literature on trade with capital market imperfections is now quite large. An important part of it has focused on how comparative advantage and the pattern of trade are determined by cross country heterogeneity in the efficiency of capital markets (see for example Kletzer and Bardhan, 1987;Wynne, 2005;and Manova, 2008). Although our result is compatible with the idea that comparative advantage in the export of skill-intensive products may be driven by differences in capital market development, the focus of our paper is different. More connected to our paper is the literature on trade liberalization and skill acquisition in the presence of credit market frictions. This literature has studied several ways in which trade liberalization may affect domestic credit constraints and, through this channel, skill acquisition. In an important contribution Cartiglia (1997) shows that trade liberalization reduces the cost of schooling in a skill-scarce South by reducing the relative wage of skilled workers à la Stolper-Samuelson, thus making it easier for poor, credit constrained households to send their children to school. This effect may be large enough to offset the standard result that trade discourages the accumulation of the scarce factor (via the Stolper-Samuelson decrease in its relative return; see Findlay andKierzkowski, 1983, andGrossman andHelpman, 1991), thus creating a positive association between trade liberalization and skill accumulation in the South. Ranjan (2001aRanjan ( , 2003 enriches the setting in Cartiglia (1997) by studying how trade may affect credit constraints also through the distribution of income and wealth. The main intuition here is that trade increases (decreases) the wage income and long-run wealth of unskilled workers in the South (North). Assuming that credit constraints affect mainly the children of unskilled workers, trade results in a lessening of credit constraints in the South, and a strengthening of credit constraints in the North (unless credit constraints are institutionally less present in the North). 7 Building on this latter result, Chesnokova and Krishna (2009) show that the supply of skill-intensive goods in the North may actually decrease following trade liberalization, due to a strengthening of credit constraints. This carries the intriguing implication that trade may decrease welfare in such a country. 8 We borrow from this literature the basic insight that, in the presence of credit constraints, trade may increase the supply of skilled labor in the South. In particular, our result that trade may shift South from a low-skill equilibrium to a high-skill equilibrium in the long run has much in common with the results in Ranjan (2003). Our main innovation lies in the introduction of the kind of talent heterogeneity that maps into heterogeneity in productivity per worker. This allows us to investigate the compositional effects of the trade-induced increase in the skilled-labor supply. 9 Our main findingthat trade may lead to an increase in the observed skill premiumis novel to the literature. 10 It points to the importance of considering compositional effects of trade 5 Another HO feature that is preserved in our model is the fact that labor reallocates towards labor-intensive industries in the South. While Verhoogen (2008) finds evidence of such reallocation for Mexico, Wacziarg and Wallack (2004) find little evidence of labor re-allocation across sectors following trade liberalization in a sample of 20 countries. Importantly, we argue that our mechanism would survive if we allowed for labor market frictions (such as a high cost of firing) to slow down the inter-sectoral reallocation of labor. Rigid labor market has been indicated as one of the main reasons why labor reallocation to industries where a country has comparative advantage has been very slow in many countries (see, for example, Kambourov, 2009). 6 A similar result applies in the two-country version of the model (see the working paper version of the paper: Bonfatti and Ghatak, 2011). There, we show that trade may increase the skill premium in the skill-scarce country, while it always increases it in the skill-abundant country. 7 In contrast with this literature, Chesnokova (2007) provides an interesting example in which, rather than lessening the credit constraints of workers in comparative advantage sectors, trade strengthens the credit constraints of workers in non-comparative advantage sectors. This may lead to underinvestment in non-comparative advantage sectors, possibly making trade liberalization welfare-decreasing. 8 Our paper is also related to the literature on trade, credit constraints and child labor, see in particular Ranjan (2001b). 9 Ranjan (2003) and Chesnokova and Krishna (2009) assume talent heterogeneity that maps into heterogeneity in the cost of education. While yielding similar predictions for the impact of trade on the supply of skilled labor, this approach is not well-suited to investigate the impact of trade on the average productivity of the skilled labor force. Ranjan (2001a) and Das (2005) assume talent heterogeneity that maps into heterogeneity in productivity per worker. They do not, however, look at the consequences of this for the distribution of productivity in the skilled labor force. 10 Bardhan et al. (2010) have also argued that trade liberalization in the presence of credit constraint may lead to an increase in wage inequality in South. Their mechanism is, however, substantially different from our own. In their model, credit constraints allow only a few Southern entrepreneurs (or "managers") to invest in scale, which is a pre-requisite for accessing a market of quality-conscious consumers in North. This creates reputational rents for managers in labor-intensive industries in the South. In this context, an export-led boom in the labor-intensive industries in the South may lead to higher reputational rents and skill premium in this country.
alongside standard effects on relative wages in efficiency units, which is what the previous literature has implicitly focused on. The paper is organized as follows. Section 2 presents our argument in an intuitive way. Section 3 develops the formal model, while Section 4 provides some generalizations. Finally, Section 5 concludes.

Our argument
In this section, we illustrate the intuitive logic of our argument. To do so, we begin by setting out the simple trade model that will be embedded in an overlapping generation model in our formal model fully fleshed out in the next section.
Consider the case of a "Home" country (H) where two tradable intermediate goods, x and y, are produced using skilled (S) and unskilled (U) labor. Production of x is relatively unskilled labor-intensive, while production of y is relatively skilled labor-intensive. We capture this by the following functional forms 11 : The two intermediate goods are assembled into a non tradable final good z, using a Cobb-Douglass technology: where A is total factor productivity in the z sector. There is also another non tradable final good f in this economy, produced with constant returns to scale and using unskilled labor only (f = U). 12 The economy is populated with a mass 2n of agents, endowed with identical preferences. They obtain utility from consuming the two final goods 13 : We assume throughout that ϕ is small enough, so that all agents can afford to spend ϕ on good z. This implies that all agents allocate positive expenditure on good f, which must then be produced in equilibrium.
Suppose that our economy is endowed with stocks Ū and S of unskilled and skilled labor, which are constant over time. For reasons that will be clear below, we normalize the stock of skilled labor by n, thus defining s≡ S n . A competitive equilibrium of this economy consists of an unskilled wage (w), a skilled wage (v), two prices of the intermediate goods (p x and p y ), and two prices of the final goods (p z and p f ) such that these markets clear, given that all agents behave optimally. We normalize the unskilled wage to 1. Since good f is always produced in equilibrium, the zero-profit condition in the f industry implies that p f = 1. Similarly, given constant returns, the zero-profit conditions in the x and y industries straightforwardly imply that p x = 1 and p y = v. To simplify the notation, we rename p z ≡ p. The competitive equilibrium is then concisely described by two prices, v and p. Now p is a straightforward function of v, given the zero profit condition in the z sector: Therefore, we can describe the competitive equilibrium even more concisely by looking at v only. We denote the competitive equilibrium at a given time t by a subscript "t" on all prices.
We now want to study the impact of trade liberalization on this economy. Suppose that, at time T − 1, country H is in autarchy. The competitive equilibrium is then straightforward to derive. Because the price of f is 1 and ϕ is low, all agents allocate expenditure ϕ to good z. This implies that the total revenue in the z sector is 2nϕ. In autarchy, these revenues must be entirely transferred to domestic producers of the intermediate goods, and so total revenues in sectors x and y are nϕ each. It follows that the total reward to skilled and unskilled labor in these sectors is nϕ each. But equilibrium in the skilled labor market then requires that nϕ v T−1 ¼ sn, or: Now suppose that, at time T, country H starts trading freely with the outside world (W). We assume that W has the same production technology of H, but that it is relatively skill-abundant. Furthermore, we assume that W is large relative to H, so that, following trade liberalization, H's price of tradable goods (x and y) are equalized to world prices. 14 Since W is relatively skill-abundant, the pre-trade wage ratio must be lower in W than in H, i.e., v Ã w Ã bv T−1 . By equalizing prices of tradable goods (x and y), trade equalizes salaries as well. It follows that we can still normalize the unskilled wage to 1 everywhere, and trade must decrease the skilled wage in H v T bv T−1 ¼ ϕ s . Fig. 1 describes the impact of trade on the competitive equilibrium. The figure represents equilibrium wages and final good prices as functions of the equilibrium skilled wage. As we have just seen, trade liberalization at time T decreases the skilled wage from ϕ s to some lower value v T . Clearly, trade has two consequences for the structure of wages in the domestic economy. First, it decreases the skill premium, which we define in this paper as the ratio of average, observed skilled to unskilled wages (here simply π t ≡ vt wt ¼ v t ). Second, it decreases the purchasing power of skilled wages in terms of the final goods, while it increases the purchasing power of unskilled wage. 15 This is, of course, nothing but an application of the standard Stolper-Samuelson theorem.
Having set out the trade model that we will be using throughout the paper, we are now ready to sketch our main argument. Suppose that the supply of skilled labor is not exogenously given but is determined by the educational and occupational choices of agents. As such, supply will be responsive to market conditions, both because educated adults can choose whether or not to be skilled workers, and because young agents can choose whether or not to acquire an education and be skilled workers in the future. Suppose further that agents have different levels of talent, and this maps into different levels of productivity. Since talent is best manifested in complex activities, it is natural to assume that the productivity gap between highly talented and little talented agents is higher in the skilled labor force than in the unskilled labor force. In a world in which educational and occupational choices are always optimalthat is, with no credit constraintsthe supply of skilled labor will always be upward-sloping in v. This is because a higher v will induce more educated adults to choose being skilled workers, and more young agents to get educated. It is also easy to imagine that high-talent (low talent) agents will sort into the skilled (unskilled) 11 The logic of our argument goes through for a whole class of standard production technologies where both types of labor are used in both activities. See the working paper version of the paper for an example with Cobb-Douglas technologies (Bonfatti and Ghatak, 2011). 12 Notice that we do not strictly need z to be non tradable; however this simplifies the description of the trade equilibrium. To fix ideas, we may think of f as products and services typical of the "traditional" economy (e.g. subsistence agriculture, constructions, retail trade, and simple business services) and of z as services of the "modern" economy (e.g. utilities, telecommunications, financial services, and health care). In this context, x could represent materials and basic manufactures, while y could represent more complex machines (such as computers). 13 Our results are robust to using other functional forms from the widely-used class where v(.) is differentiable, increasing, and strictly concave. However, the choice v(.) = ϕ log(.) simplifies the calculations by ensuring that the expenditure on good z is fixed.
14 We also assume W to be at steady state, so that world prices remain constant over time. 15 Notice that both v p and u p z ¼ v fall following trade liberalization, while w p ¼ 1 p increases and w p z remains constant at 1. labor force in this world, since it will be more attractive for high-talent agents to bear the cost of education than for low-talent agents. Now suppose that young agents can only go to school if their family can afford to provide them with enough means to pay for their subsistence costs while in school. If this is not the case, young agents must work as unskilled workers instead of going to school, thus losing the chance to be skilled workers in their adulthood. Under these circumstances, it is conceivable that v may be very high, and yet the supply of skilled labor may be very low (explaining why v is high in the first place). The intuition for this is provided by Fig. 1. When v is very high, the cost of subsistencewhich in our setting is fully captured by p 16is high for families of unskilled workers, while it is low for families of skilled workers. Thus, there will be a threshold v cc such that if v > v cc , it is only the families of skilled workers who can pay for their children's subsistence while in school. For any initially low stock of s, there will then be an equilibrium in which v is very high, and the supply of skilled workers is very low. The key thing is to notice that since v is very high in these equilibria, children of skilled workers will have strong incentives to go to school even if they are low-talent. The existence of low-talent workers in the skilled labor force will then drag down the observable, average skilled wage in the economy.
What happens if country H is opened up to trade with W, along the lines described above? Just as before, trade must decrease v: thus, the skill premium within any given pair of skilled-unskilled workers must also decrease, along standard Stolper-Samuelson lines. But what does trade do to the relative composition of the skilled/unskilled labor force? Here, there are two effects. On the one hand, because v is now lower, some low-talent educated adults who have an education only because they were children of skilled workers in a high-v, pre-trade economy, may want to drop out of the skilled labor force. On the other hand, some high-talent children of unskilled workers who would have been excluded from school in the pre-trade economy may now be able to go to school. This is because trade has increased the purchasing power of families of unskilled workers, and thus their capacity to pay for their children's subsistence while in school. Both effects push for a net transfer of talent away from the unskilled labor force and into the skilled labor force. When we look at the observed, average skilled premium in the economy, this talent re-allocation will make sure that trade always has a less negative effect on the skill premium than in a world with homogenous agents and no credit constraints. In fact, we show in the next section that trade may even have a positive effect on the skill premium. Thus, talent heterogeneity and credit constraints make it possible that for an economy experiencing a fall in the relative price of skill-intensive goods, the predictions of the Stolper-Samuelson theorem can be reversed. We now move to illustrating this result more formally.

The model
In this section, we begin by combining the simple trade model developed in the previous section with a model of overlapping generations (Section 3.1), where the decision to become skilled is endogenous (Section 3.2). After summarizing the sequence of events in each period (Section 3.3), we solve for the autarchic steady state of this combined model (Section 3.4). Our main results are contained in Section 3.5, where we study the impact of trade liberalization on the observed skill premium in this economy.

Demographics
At any given time t, the economy is populated by two overlapping generations of agents, who live for two periods. "Generation t − 1 " is made up of agents who were born in period t − 1, and are adult in period t. There is a mass n of such agents. "Generation t" is made up of children of generation t − 1. They are born at the beginning of period t, and are young in this period. Since each adult agent gives birth exactly to one child, there is a mass n of young agents in period t. Thus, the total mass of agents in this period is 2n.
We still use the utility function in Eq.
(1) to describe how agents obtain utility from the consumption of final goods, but enrich the structure of agents' preferences in two important ways. First, all agents face a "survival constraint", in the sense that if the agent's utility falls below a threshold ū in any of her two periods of life, this agent dies of starvation (and gets utility − ∞). Second, adult agents also care about the gift (in terms of utility) that they give to their children. 17 We represent the agent's inter-temporal optimization problem as follows: where u t,s i = f t,s i + ϕ log z t,s i represents the utility obtained by agent i from generation t in period s, and b t i the gift (in terms of utility) given by agent i in generation t.
Notice that, as long as ϕ is small, the above optimization problem has two very convenient properties. First, since all agents allocate expenditure ϕ to the consumption of z, the competitive equilibrium is identical to the one derived in the previous section. Second, in both periods the marginal utility of income is constant and equal to 1 when income is more than sufficient to achieve the subsistence level of utility; it is, instead, infinitely high when income is just sufficient to achieve this level. 18 As we will illustrate in Section 3.2.2, this formulation allows us to introduce credit constraints in a very analytically tractable way.
Finally, we assume that goods are perishable, and that there are no financial markets. Thus, income cannot be transferred across periods.

Schooling
All agents are endowed with one unit of time in each period, and are born unskilled. In their first period of life, they can choose whether to 16 Recall that the price of the other final good is normalized at 1. 17 Transfers from adult agents to their offspring are often interpreted as bequests in the literature. In our setting, the transfers occur while the adult agents are still alive and therefore, gift seems like a more appropriate term. 18 A low ϕthat is, a low optimal expense on zensures that the marginal utility of income is 1 in the first period. The functional form for second-period utility ensures that the marginal utility of income is constant and equal to 1 in the second period as well (see Appendix B for more details). To allow for more general functional forms would greatly complicate the algebra, without changing the logic of the argument. use their time to be unskilled workers, or to go to school. If they work, they can only be unskilled workers in their second period. If they go to school, on the contrary, they become "educated" and acquire the option of being skilled workers in the second period. Educated parents retain the option to be unskilled workers in the second period. Thus, there may be three distinct groups of parents in any period t: non educated parents, educated parents who are skilled workers, and educated parents who are unskilled workers.
Agents differ in their level of talent, Θ. For simplicity, talent can take only two values, Θ = 1 and Θ = θ > 1. We will refer to agents with these talent levels as "untalented" or "low-talent" and "talented" or "high-talent", respectively. We assume that talent is not inherited, but distributed randomly across the population with a probability of observing a talented agent being equal to β. Thus, each generation has a mass βn of talented agents and a mass (1− β)n of non-talented agents, and the average talent in the population is: While all agents are equally productive when they work as unskilled workers, there is a one-to-one mapping between an agent's level of talent and her productivity as a skilled worker. In other words, a nontalented worker can only contribute 1 efficiency unit of skilled labor, while a talented worker can contribute θ units. This maps into a higher wage awarded by a competitive skilled labor market to talented agents (who receive θv) compared to non-talented agents (who receive v). In what follows we continue to refer to v as the skilled wage, but it should be borne in mind that what it really indicates is the skilled wage of non-talented agents, or the skilled wage per efficiency unit of labor.

Participation constraints
We assume that going to school is free, as would be the case of a country where education is fully subsidized by the government. 19 Despite being free, however, going to school comes at the cost of lost unskilled wages in the agent's first period of life. When choosing whether to go to school or not, agents compare this cost to the difference in wages that they can expect to receive working as skilled workers in their second period of life. Since agents with different levels of talent can expect to receive different skilled wages, they will also have different participation constraints. In particular, denoting by v t+1 e the skilled wage expected by period t's young agents for period t+1, an agent of talent Θ i goes to school if and only if Θ i v t+1 e − 1>1. This gives the following participation constraints for talented and non talented agents: Notice that it is always ex-post optimal for an educated agent to be a skilled worker in period t + 1, provided that her expectations in period t were correct. 20 Intuitively, the cost of education is sunk in period t +1, while the agent's productivity is unchanged. Rational initial decisions must then be optimal, unless external conditions have changed.

Credit constraints
Under the assumption that credit markets do not exist, we now move to consider how the schooling decisions of agents are driven not only by income maximization (as described in Eqs. (4) and (5)), but also by parental wealth. While school is free of charge, agents can only afford to go to school if the gift that they receive from their parents is high enough to cover their subsistence expense while in school. If this is not the case, agents must join the unskilled labor force and pay for their own subsistence expense, or else die of starvation. Thus, the distribution of gifts determines who can and cannot go to school from the set of young agents. We will refer to the latter group as credit constrained young agents.
The assumption that wage income is harder to give up for poor young agents than for rich ones is broadly consistent with the way in which educational credit constraints are modeled in the literature. 21 For example, Ranjan (2003) assumes a continuously decreasing marginal utility of income, which, coupled with the inability to borrow from financial markets, implies that the participation constraint of the poor is less likely to be satisfied than that of the rich. Our innovation is that we model the marginal utility of income as decreasing at a single point of the income distributioninfinite at the level of income that is needed to pay for subsistence, constant and equal to 1 thereafter. The advantage of this formulation is that it allows us to model credit constraints separately from participation constraints, keeping the latter linear. 22 While fully preserving the logic of the mechanism, this allows us to simplify the algebra a great deal. This way of modeling educational credit constraints is in line with abundant empirical evidence suggesting that a major force keeping the poor out of school is the high opportunity cost from lost labor opportunities, given their proximity to the subsistence level of income. 23 We now proceed to study the shape of the distribution of gifts, and its impact on the schooling decisions of agents. In any period t, parents can fall into three income brackets: unskilled workers (income 1), skilled but non-talented workers (income v), or skilled and talented workers (income vθ). Because educated parents are free to choose whether to work in the skilled or unskilled labor force, income in the two latter brackets cannot fall below 1 in equilibrium. Thus, the minimum gift that is transferred in period t is 1 2 , which is what the offspring of unskilled workers receive.
These agents are the first to become credit constrained when the cost of achieving the subsistence level of utility increases. Specifically, for these agents not to be credit constrained in period t the following condition must hold: where e(ū, p t ) is the expenditure function valued at the subsistence level of utility and at current prices. When condition (6) does not hold, the offspring of unskilled workers must work as unskilled workers in their first period of life, or else die of starvation. Importantly, we can focus on that part of the expenditure function around the threshold value 1 2 : since ϕb 1 2 by assumption, and ϕ is the optimal expenditure on good z, the relevant part of the expenditure function is the one at which consumption of good z is at its optimum value ( ϕ p t ). Since the utility from consuming this amount of z is ϕ log ϕ p t , the relevant part of the expenditure function is simply: That is, the cost of achieving utility ū is given by the cost of the optimal consumption of z (ϕ), augmented by the cost of increasing utility from ϕ log ϕ p t to ū through consumption of f. We can now re-write the expenditure function in terms of v t by plugging in Eq. (2): where F u; A ð Þ≡ϕ þ u−ϕ log ϕA 2 . Not surprisingly, the cost of subsistence is always strictly increasing in va measure of the scarcity of skilled labor in the economy, and thus the cost of producing z. Moreover, the cost of subsistence takes value in the open interval (0, ∞) for v t ∈ (0, ∞). 24 Plugging Eq. (7) into Eq. (6), we obtain: Inequality (8) defines a threshold for the current skilled wage that is critical in determining whether the offspring of unskilled agents are credit constrained or not. In particular, if v t ≤ v cc the offspring of unskilled agents are not credit constrained, while they are if v t ≤ v cc . Intuitively, an increase in v t (that is, a more scarce skilled labor force) is associated with a high cost of production in the z sector, a higher p t , and a higher subsistence cost (recall that e(ū, p) is increasing in p). For the offspring of unskilled workers, this increase in subsistence cost is not matched by an increase in gifts, which is only linked to the unskilled wage. Thus, a high enough v t implies that the offspring of unskilled agents must work as unskilled workers in the first period of their life to meet their subsistence needs. Not surprisingly, the threshold v cc is always increasing in A, the total factor productivity in the z sector. Intuitively, a more productive economy makes the cost of subsistence smaller for any existing stock of skilled labor, thus reducing the probability that the offspring of unskilled workers are credit constrained. In fact, we can always set A large enough so that v t ≤ v cc , and credit constraints are not an issue for this group of agents.
We have established that a high skilled wage may be bad news for the offspring of unskilled workers, in that it may force them to remain in the unskilled labor force as well. But how about the credit constraints of the offspring of skilled workers? As we have already noticed, these agents must be at least as wealthy as the offspring of unskilled workers in equilibrium. Thus, if the latter are not credit constrained in equilibrium (it is v t ≤ v cc ), the offspring of skilled workers cannot be. If the offspring of unskilled workers are credit constrained (it is v t > v cc ), we show in Appendix A that a sufficient condition for the offspring of skilled workers not to be credit constrained is that v cc >1. Intuitively, a high enough v t must be good news for the offspring of skilled workers: this is because the gift that these agents receive is linear in v t , while the cost of subsistence is concave. It must then be the case that the former overtakes the latter for v t higher than a certain threshold. The condition v cc > 1 makes sure that this threshold is lower than v cc , implying that the offspring of skilled workers will never be credit constrained for v t > v cc . Since we will anyway want to restrict our attention to cases in which v cc is high (and higher than 1, see Section 3.4), we can safely conclude that the offspring of skilled workers will never be credit constrained in equilibrium.
In the rest of the paper, we will study how a trade-induced decrease in v t may lead to a relaxation in the credit constraints of the offspring of unskilled workers. In this context, the results derived above may be seen as a corollary of the classic Stolper-Samuelson theorem. This states that a trade-induced rise in the relative price of a good raises the real return of the factor used intensively in the production of that good, and lowers the real return of the other factor, in terms of both goods in the economy. In our model, trade will increase the price of good x, thus increasing the real return to unskilled labor in terms of both x and y (and thus z). This will then result into a lower cost of subsistence for the offspring of unskilled workers, relaxing their credit constraints.
Notice that the existence of a subsistence level of utility must put a constraint on the minimum endowment of productive factors in an economy. In this model with human capital accumulation, this requires ruling out that there are too few educated agents at any point in time. To see this, notice that if e(ū, p)> 1, unskilled workers are never able to reach the subsistence level of utilitynot even if they do not give any gifts to their offspring. Thus, all unskilled workers would pass away in this case, and the economy would collapse. To avoid this, we require e(ū,p t )≤1 at all t. Using Eq. (7), this can be equivalently written as: Furthermore, being a linear function of v cc , vdepends on A just as v cc does. In what follows, we will only consider the case in which the economy never collapses, or in which v t b v in all periods. This requires imposing some restrictions on initial conditions, as v t b v will then emerge naturally from the agents' schooling decisions under the model's assumptions.

Timing and equilibrium concepts
The following events take place in each period t: t.1 Generation t is born from parents of generation t − 1; t.2 Educated parents decide whether to be skilled or unskilled workers. At the same time, individuals of generation t decide whether to join the unskilled labor force or go to school. t.3 Production takes place; all markets clear. t.4 Gifts are made, consumption takes place. t.5 Parents pass away.
Just as in Section 2, a competitive equilibrium at time t is defined as a vector of prices such that all markets clear, given that all agents behave optimally and a positive amount of good f is produced. It is important to notice that, with endogenous schooling and working decisions, this definition includes two additional requirements on the optimal behavior of agents. First, the schooling decisions of young agents in t − 1 (and thus the supply of educated parents in t) must be optimal given the prices that are realized in t. We consider this to be a feature of period t's equilibrium (rather than period t − 1's) because schooling decisions in period t − 1 only affect prices in period t. 25 Second, the working decisions of educated parents at time t (and thus the supply of skilled labor in t) must also be optimal given the prices in period t. 24 When the cost of subsistence is above ϕ, Eq. (7) is the relevant expression for it. Clearly, this is strictly increasing in v t , and converges to ∞ as v t converges to ∞. When the cost of subsistence falls below ϕ, the relevant expression becomes e u; p t vt ð Þ since compensated demand for f and z is, respectively, zero and exp u ϕ . This is also strictly increasing in v t , and converges to 0 as v t converges to zero. 25 This important feature of the model relies on the fact that good f is always produced, and the relative wage does not depend on the amount of unskilled workers in the economy.
While the competitive equilibrium in period t is never affected by the equilibrium in period t + 1, it may well be affected by the competitive equilibrium in period t − 1. To illustrate this, it is useful to consider a specific parametric specification where this "path dependency" does not take place, and then contrast it with a more general specification of the model. Suppose that ū → − ∞, so that e(ū,p t−1 ) → 0. In this case, no agents are ever credit constrained, and schooling decisions at time t − 1 are only affected by expected prices at time t: in other words, the equilibrium at time t is not affected by conditions prevailing at any previous period. Suppose now that e(ū, p t−1 ) > 0. In this case, the children of unskilled agents will be credit constrained for v t−1 > v cc . Thus schooling decisions at time t − 1 (a feature of the equilibrium at time t) will be affected by the level of prices at time t − 1 (a feature of the equilibrium at time t − 1).
In what follows, we will be interested both in the model's transitional dynamicsthat is, the evolution of the competitive equilibrium over timeand its steady state. The latter is achieved at time t if the competitive equilibrium realized at that time is identical to those realized at times t + s, were s=1,…,∞. That is, all generations make the same schooling and occupational choices in steady state, and prices remain constant over time. Notice that the model only displays a transitional dynamics if there is path dependency (and thus credit constraints): clearly, if the competitive equilibrium at any given point in time does not depend on earlier conditions, the economy must be in a steady state.
Having defined our equilibrium concept, we now move to describing the competitive equilibrium of country H.

Autarchy equilibrium
We begin by making two assumptions on the distribution of talent and on the level of credit constraints in the economy: Assumption 2.
v cc > 2: Assumption 1 requires that the number of talented agents in the population be "intermediate", where the lower bound of the allowed range is decreasing in the ratio of the high level of talent to the low level of talent (θ). As will be clear below, this assumption merely simplifies the description of the equilibrium, given the discreteness of the distribution of talent. Assumption 2 requires that productivity in the economy be high enough, so that the threshold above which the offspring of unskilled agents are credit constrained is not too small. This assumption is necessary to make sure that there exists an equilibrium in which talented agents are not credit constrained. This is the interesting case for us, as it is the one in which trade may lead to a better allocation of talent in H, thus affecting the skill premium in a non-standard way. Notice also that Assumption 2 implies v cc >1, and so that we are safe to assume that the offspring of skilled workers are never credit constrained in equilibrium (see Section 3.2.2).
We are now ready to describe the autarchy steady state of country H. For conciseness, we only report the schooling decisions of agents and the skilled wage in steady state: Proposition 1. From any (feasible) initial stock of educated parents at t =1, the economy converges to a unique steady state no later than t =3. Depending on the initial stock, this can be: • A "good steady state" in which v ¼ ϕ βθ , and all and only the talented agents go to school.
• One from a continuum of "bad steady states" in which v∈ v cc ; v ð > ϕ βθ , and all and only the offspring of skilled workers go to school.
Proof. See Appendix C. ▪ Proposition 1 argues that from any initial stock of educated parents (which cannot be too small, or else the economy would implode due to starvation) the economy quickly converges to a steady state, and that there is a one-to-one mapping between the initial stock and the type of steady state that the economy converges to. There are two, quite distinct types of steady states. On the one hand, there is a unique "good" steady state in which all and only the talented agents go to school, and the skilled wage is relatively low. This is a steady state in which credit constraints are not binding, and talent is efficiently allocated to the skilled labor force. On the other hand, there is a whole class of "bad" long-run steady states in which all and only the offspring of skilled workers go to school, and the skilled wage is relatively high. In these steady states credit constraints are binding for a fraction of the population, and the allocation of talent to the skilled labor force is inefficient. Intuitively, the offspring of unskilled workers cannot afford to go to school if v>v cc , while the offspring of skilled workers can. This implies that it will be only the offspring of skilled workers who go to school for v >v cc . Furthermore, since v cc >2, it must be the case that all of them to go to school, creating a steady state in which the skilled labor force self-perpetuates itself over time. 26 The only constraint on this class of steady states is that v cannot be greater than v, or the economy would collapse. 27 Fig. 2 illustrates convergence to the steady state from any (feasible) stock of educated parents at t = 1, and thus any (feasible) v 1 . Because the working decisions of young agents do not affect the competitive equilibrium in period 1, we can treat v 1 as exogenous to the schooling decisions of generation 1. The left-hand panel represents the case in which v 1 ≤ v cc . In this case, no one is credit constrained in period 1. Because of rational expectations and certainty, this implies that the skilled labor supply at t=2 will include all of the talented agents of generation 1 if v 2 > 2 θ , and all of generation 1 if v 2 >2. Under Assumption 1, demand and supply meet in the first vertical portion of the supply schedule. Thus, the competitive equilibrium in period 2 is such that all and only the talented agents go to school in period 1, and v 2 ¼ ϕ βθ . Because ϕ βθ bv cc by Assumption 2, this is also a steady state (the "good" steady state described in Proposition 1).
The right-hand panel represents the case in which v 1 ≤ v cc . In this case, the offspring of skilled workers are the only ones who can go to school in period 1. The supply of skilled labor in period 2 is then everywhere lower than in the previous case, reflecting the fact that schools can only attract students from a portion of the population. There are then two distinct cases. If educated parents in period 1 are not too few in number, the supply of skilled labor in period 2 is not too low (s 2 s schedule), and v 2 ≤ v cc . Because credit constraints are not binding in period 2, supply in period 3 (s 3 s schedule) is identical to supply in the left-hand panel, and the economy converges to the good steady state in period 3. If instead there are very few educated parents and v 2 > v cc ((s 2 s )′schedule), credit constraints are still binding in period 2, and the offspring of skilled workers are again the only ones that can go to school. Because v 2 > 2, the number of skilled workers 26 Notice that we could relax Assumption 2 to vcc > ϕ βθ . This would imply a slightly more complicated transitional dynamics for the case in which v 1 ∈ (v cc , 2], but not change the result that the economy converges to one of the "bad" steady states when v 1 > v cc . 27 Notice that the cost of subsistence ranges from 1 2 to 1 as v ranges from v cc to v. For these high values of the cost of subsistence, unskilled parents live as a gift less than a share 1 2 of their second period's income to their offspring. This does not matter for our result, however, as these offspring would have been credit constrained anyway for v > v cc . in t = 2 must be the same as in t = 1. It follows that the supply of skilled labor in t=3((s 3 s )′schedule) will be identical to supply in t =2, and a "bad" steady state is reached.
Having found all the possible steady states at which H can be in autarchy, we next move to consider how the steady state of this country may be affected by opening up to trade with a foreign country.

Trade equilibrium
We now study what happens if, at time T, H opens up to trade with the external world (W). As explained in Section 2, we assume that W is relatively large, and is in steady state. This implies that the world prices of x and y are exogenous and constant over time, and H's prices are equalized to them following trade liberalization. We also assume that W's relative price of y is initially lower than H's, so that W's skilled wage per efficiency unit of labor, v * , is lower than v before trade liberalization. 28 Clearly, this is equivalent to assuming that W is more skillabundant than H before trade liberalization.
Since we are interested in the impact of trade on a credit constrained economy, we assume that H starts out at one of the bad steady states described in Proposition 1. There are then two kinds of reasons why W may be initially more skill-abundant than H. On the one hand, this may be due purely to weaker credit constraints in W than in H, so that a higher proportion of people (and/or more talented people) go to school in W than in F. Alternatively, W may be more skill-abundant due to a variety of structural factorssuch as a more skill-biased technology or a better educational systemthat make the effective supply of skilled labor higher in W, for any given level of credit constraints. While in both cases W has an initial comparative advantage in the production of y, in the first case this may be dissipated over time, or even reversed. This is because trade may move H to an equilibrium with weaker credit constraints, thus making it as skill-abundant as W or even more. For simplicity, we assume that there are some structural factors underpinning W's comparative advantage in the production of y, such that this does not fully dissipate if H converges to its "good" equilibrium. The existence of this "structural" comparative advantage of W requires that we assume v Ã b ϕ βθ from now on. 29 Before investigating the impact of trade on schooling and working decisions, we must specify the timing of trade liberalization and its relation to agents' expectations. A full-fledged analysis of trade liberalization in a model with rational expectations would require us to specify to what extent trade liberalization at time T is foreseen by agents in previous periods. This is important because, for example, the possibility of trade liberalization affects the expected skilled wage at time T, thus influencing the schooling decisions at time T − 1. While making the analysis more coherent, to account for the expectation of trade liberalization would greatly complicate the model, as it would link the autarchy equilibria of the two countries to each other even before trade is opened. At the same time, this extension would not undermine the logic of our argument unless trade liberalization is fully foreseena case that we consider unlikely. For these reasons, we choose to model trade liberalization as a fully unexpected event in period T. To facilitate the intuition, this simple model can be thought of as substantially equivalent to one in which trade is opened in period T, and the probability perceived beforehand that this would happen was very low.
To introduce trade in our framework, we enrich the timing at period T (and at period T only) by adding the following event: T.0 Trade is opened (to remain open forever after).
That is, trade is opened immediately before generation T is born in T.1, and remains open forever after. At time T.2, educated parents decide whether to join the skilled labor force or not. As in autarchy, this choice and the prices that form in period T.3 must constitute a competitive equilibrium. Because conditions have unexpectedly changed, however, schooling decisions in period T − 1 need not be optimal anymore. In particular, it may well be the case that some of the educated parents decide to stay out of the skilled labor force, as trade has depressed the skilled wage to a level well below what they expected when they decided to go to school. This misalignment between expected and real prices lasts for one period only. Because there is no uncertainty after period Ttrade remains forever open, and this is common knowledgegeneration T's schooling decisions must correctly reflect prices as they will form under free trade in period T + 1. Notice that trade affects the schooling decisions of generation T in two ways. It may affect their participation constraints, by changing the level of the skilled wage in T + 1; and it may affect their credit constraints, by changing the level of the skilled wage in T.
Our first result is presented in the following proposition: Proposition 2. Opening up to W in period T shifts H to a new steady state in period T+1, where v = v*, no one is credit constrained, and only talented agents go to school. If W's comparative advantage in the skill-intensive sector is not too strong, this is the good equilibrium where all of the talented agents go to school. At all t ≥ T, H, H is a net importer of y.
Proof. See Appendix C. ▪ Proposition 2 suggests that if H is at a bad steady state and it opens up to a relatively skill-abundant world, trade may trigger a mechanism Fig. 2. Autarchy steady states. 28 Since trade equalizes salaries, we can normalize the skilled wage to 1 both in H and in W. 29 A natural way to obtain this pattern of comparative advantage is to assume that W is itself at the good equilibrium, but that its technology is biased in favor of skilled occupations (e.g. x*=U and y*=A*S*, with A* > 1). Total supply of skilled labor would then be Aβθ > βθ, leading to v Ã b ϕ βθ . Notice that it is only to simplify the exposition that we assume this structural comparative advantage of W. We could allow for W's comparative advantage to dissipate fully, or be reversed, as H converges to its good equilibrium, and all of our results would still hold for some value of the parameters. For example where W's comparative advantage fully dissipates over time, the interested reader is referred to the working paper version of the paper (Bonfatti and Ghatak, 2011). that shifts H to the good steady state within a generation. The intuition for this result is straightforward. Because W has a comparative advantage in y, trade reduces the price of this good in H. This reduces the reward to skilled labor, the factor in which production of y is relatively intensive. This reduction is assumed to be large enough to take the skilled wage below the threshold v cc . But for v T b v cc the offspring of unskilled workers are not credit constrained anymore, and all of generation T's talented agents can choose to go to school in period T. Furthermore, while the (expected) skilled wage has fallen relative to its pre-trade level, it may still be high enough to motivate at least some of these agents to go to school. Of course, this is only possible because credit constraints, and not participation constraints, prevented these agents from joining the skilled labor force in autarchy. On the contrary, the non-talented offspring of skilled workerswho would have gone to school had the (expected) skilled wage remained at its pretrade levelare now better off opting out of the schooling system. It follows that all and only the talented agents go to school after trade is opened, and the economy moves to the good steady state in period T +1. 30 The result that trade may move the unskilled labor-abundant country from a low human capital equilibrium to a high human capital equilibrium is very similar to the results found by Ranjan (2003). More generally, that trade may lead to an increase in school enrollment among the offspring of unskilled workers is a key result in the literature on trade with credit market frictions and trade, beginning with Cartiglia (1997). These results are consistent with a few recent empirical studies on the impact of trade liberalization on child labor. For example, Edmonds and Pavcnik (2005) find that a trade-induced increase in the price of rice in Vietnam was associated with a decrease in child labor in households that were net sellers of rice, but with an increase in households that were net buyers. Similarly, Kis-Katos and Sparrow (2011) exploits variation in the degree of trade liberalization across Indonesian districts to argue that trade liberalization is associated with a decrease in child labor, and that this effect is the strongest for children from low-skill backgrounds.
We now turn to the main focus of the paper, which is to consider the consequences of trade for the skill premium. Notice that the skill premium in any period t is now given by: whereθ S t denotes the average talent of members of H's skilled labor force in period t. Following the empirical literature, we define the skill premium as the ratio of the average wage of members of the skilled labor force by the average wage of the members of the unskilled labor force (which is always 1 in equilibrium in our model), not controlling for the unobservable talent of workers. We begin by considering the impact of trade on the skill premium in steady state, and then we will comment on its impact during the transitional dynamics.
The long-run effect of trade on the skill premium is described in the following proposition: Proposition 3. Following trade liberalization in period T, H's skill premium at all t ≥ T + 1 is given by: Proof. From Proposition 2, we know thatθ S T ¼ θ for all t ≥ T +1, and therefore π t = θv*. From Proposition 1, and because we have assumed that H starts out at one of the bad steady states, we know thatθ S T−1 ¼θ, and therefore π T−1 ¼θv T−1 . We may then write: ▪ Proposition 3 studies the effect of trade on the skill premium in the new steady state. Since trade is opened in period T but the new steady state is reached only in period T + 1 (see Proposition 2), we will also refer to this as the "long-run" impact of trade on the skill premium.
The proposition suggests that the new steady state skill premium in H is the product of its pre-trade liberalization level and two distinct terms. The first is the ratio of the level of the skilled wage post-trade liberalization to its level pre-trade liberalization ( v Ã v T−1 ). Because H is on the unskilled labor-abundant side of the trade relation, this term must be smaller than 1 in equilibrium. Thus, the impact of trade on the skill premium as described by the first term is just as in a standard Stolper-Samuelson world: trade decreases the skill premium in the unskilled labor-abundant country, because it decreases the skilled wage relative to the unskilled wage. However, the second term in the product, namely θθ, introduces an important qualification to this conclusion. The term captures the extent of talent re-allocation following trade liberalization, or, alternatively, the degree of talent misallocation in H before trade liberalization. Since θ >θtrade always improves the allocation of talent to the skilled labor forcethis term must be greater than 1. Thus, the immediate gist of Proposition 3 is that the Stolper-Samuelson effect on the skill premium is always moderated by the reallocation of talent. In Appendix D we show that it is possible to have θθ > v Ã v T−1 in our parameter space, i.e., the Stolper-Samuelson effect may be reversed when the initial degree of talent misallocation in H is large enough. 31 We have thus found that in a world with credit constraints that affect the acquisition of human capital, trade with a large skill-abundant world will have a less negative, and possibly a positive effect on the steady state skill-premium of a skill-scarce country. The intuition for this result is straightforward. By increasing the real purchasing power of unskilled workers in terms of the tradable goods in the economy, trade increases the capacity of the talented offspring of unskilled workers to pay for their subsistence expenses when going to school. At the same time, by lowering the skilled wage per efficiency unit of labor, trade discourages the non-talented offspring of skilled workers to go to school as they would have done in the pre-trade world. These two forces increase the average talent of those who go to school after trade liberalization, leading to higher remunerations and possibly to a reversal of the Stolper-Samuelson theorem.
The result that trade liberalization may trigger convergence to a new, high skill-premium steady state is consistent with evidence documenting an increase in the skill premium for a protracted period of time (between eight and fifteen years) following trade liberalization. This evidence has been presented for Chile, Mexico, Argentina, Brazil, Colombia and India (see Goldberg and Pavcnik, 2007, pp. 52-53 for a review of the literature).
It is important to notice that the increase in the skill premium after trade liberalization is only possible if, for a given increase in the school enrollment of talented people, there is a sufficiently large decrease in the school enrollment of non-talented people. These opposite movements (in and out of the schooling system) might explain why aggregate school enrollment increased relatively little after trade liberalization in Latin America, while the skill premium increased significantly. This compares with the case of South-East Asia, where trade liberalization was followed by a much larger increase in aggregate enrollment and by a decrease in the skill premium. This latter pattern is consistent with the prediction of the Stolper-Samuelson theorem and of our model for the case in which the movement out of the schooling system is very small relative to the movement into the schooling system. We next consider the effect of trade liberalization on the skill premium during the transitional dynamics, or in the "short run". This is summarized in the following proposition: Proposition 4. Following trade liberalization in period T, H's skill premium in period T is given by: Proof. If v* > 1, all educated parents opt for staying in the skilled labor force in period T. Thus, it isθ S T ¼θ S T−1 ¼θ. It follows that π T ¼ v Ã v T−1 π T−1 , since π T ¼θv Ã and π T−1 ¼θv T−1 . If v* b 1, all non talented educated parents opt out of the skilled labor force, and it Proposition 4 studies the short-run effect of trade on the skill premium in H. In other words, it studies the transitional dynamics of the skill premium, before this converges to the steady state value described in Proposition 3.
Just as in the long-run, our model may display non standard predictions for the impact of trade on H's skill premium in the short run. Proposition 4 distinguishes between two cases. If v* > 1, the effect of trade on the skill premium is unambiguously negative in the short run (since v Ã v T−1 b1 always holds). Intuitively, the trade-induced decrease in the skilled wage is not too large in this case, and all educated parents must then remain in the skilled labor force. This implies that the average talent in the skilled labor force does not change, and the skill premium must then decrease. Thus, when H opens up to a world that is not too skill-abundantand consequently, the price of skill-intensive goods does not fall by too muchthe Stolper-Samuelson predictions are satisfied, since our talent-reallocation channel is effectively shut down. If v T−1 * b 1, on the contrary, this channel can be fully at play. In particular, the extent of talent reallocation is as high as in the long run (θθ). This is for a slightly different reason, however: in the short run, the initial misallocation of talent is corrected through the exit of the nontalented educated parents from the skilled labor force. 32 Thus, we have shown that trade-induced compositional change may result in an increase in the skill premium in the unskilled labor-abundant country, both in the short run and in the long run. In the short run, the downward pressure put by trade on the skilled wage may induce the least talented of the existing skilled workers to drop out of the skilled labor force, thus increasing its average quality. When it happens in the short run, this compositional change always extends to the long run, as only talented young agents find it optimal to go to school after trade has been opened. Even if it does not happen in the short run, however, this compositional change still occurs in the long run. This is because non-talented agents are more likely to join the unskilled labor force when they are young and unskilled, rather than when they are old and already skilled.
It is easy to show that, if H was a skill-abundant country, trade liberalization would always lead to an increase in the skill premium in the short run. 33 Thus, our results are consistent with the fact that trade between unskilled labor-abundant Latin America and various skilled labor-abundant parts of the world resulted in an increase in the skill premium in both places. Because it preserves the standard Heckscher-Ohlin structure in which the skilled wage per efficiency unit of labor decreases in H, our model is also consistent with the finding that skill intensity in most Latin American industries increased after trade liberalization. 34 Finally, our results are also compatible with the observation that the skill premium increased homogeneously across industries in skill-scarce countries, independently of the degree of trade liberalization to which each industry had been exposed (see Attanasio et al., 2004, for the case of Colombia).
It is important to highlight that our short-term compositional effect may apply to all cohorts of agents that have already acquired an education at the time of trade liberalization. This implies that our mechanism is not incompatible with the observation that, in many countries, trade liberalization has led to an increase in the relative wage of college graduates over a very short period of time (see, for example, Cragg and Epelbaum, 1996, for the case of Mexico). Following trade liberalization, low-talent agents who are close to finishing college may still find it optimal to complete their education. Still, because of the new market conditions triggered by trade, they may find it hard to find a skilled occupation, and may eventually decide to accept a less skilled occupation. Thus, at least in principle, the short-run compositional effect of trade may be at play even for agents that graduate not only before, but also immediately after, trade liberalization. Similarly, our long-run compositional effect of trade may take no more than a few years to manifest itself. This depends on how fast pupils close to making a higher education decision are in reacting to changing market conditions, both on the side of their participation constraints (for the least talented of them) and on the side of their credit constraints (for the most talented). 35

Generalizations
In this section, we generalize the distribution of talent. Suppose that agents may differ in their productivity both in the skilled and unskilled labor force. In particular, we assume that individual productivity is a random variable drawn from a bivariate distribution θ U , θ S defined over [1, ∞) × [1, ∞). Denote by θ the level of productivity in the skilled labor force, relative to the productivity in the unskilled labor force . This is also a random variable, with probability density function g r (.) and cumulative distribution function G r (.) defined over [0, ∞). The participation constraint for a young agent with relative productivity θ i is now: v e tþ1 θ i > 2: There is now a potentially infinite number of parental income brackets: this is because, whether they work as skilled or unskilled, 32 This outflow of labor from the tradable sectors is consistent with evidence from Brazil suggesting that trade liberalization induced labor displacement from the formal sector to the informal and self-employment sector (see Menezes-Filho and Muendler, 2007). 33 See for example the working paper version of the paper (Bonfatti and Ghatak, 2011). 34 Notice, however, that in a two-country world the model would predict a decline in skill-intensity in the North, which is not in line with the empirical evidence. This suggests that factors other than trade-induced changes in factor pricesfor example, a disproportionate increase in productivity in skill-intensive occupations in Northmust have been at play. 35 In principle, our mechanism may apply to any fixed investment in education that agents have to undertake, including the decision on whether to go to secondary school or not. Notice, however, that our simple educational model does not account for the fact that agents with an intermediate level of skills may drop out of their category not only by working as unskilled, but also by deciding to acquire a higher education. Further research is needed to study the compositional impact of trade on the various levels of the skill premium. parents can have a potentially infinite number of different productivity levels. However since the income of unskilled workers cannot fall below 1, and skilled workers can always work as unskilled workers, the minimum gift that is transferred in each period must still be greater than 1 2 . The model displays two additional similarities to the simpler model developed in the previous sections. First, the threshold below which none of the children of unskilled workers is credit constrained is still defined by v cc (Eq. (8)). Second, the children of skilled workers are never credit constrained. 36 However one important difference is that in this more general model, some children of highly productive unskilled workers may not be credit constrained for v t > v cc . The implications of this are discussed further below.
Define v g as the skilled wage at a hypothetical, "good" steady state in which no one is credit constrained. Just as before, we introduce an assumption to guarantee that such a steady state exists. To do this, we first need to introduce some notation. Denote by θ S (v) the distribution of productivity in the skilled labor force, when only agents with relative productivityθ≥ 2 v are in it. Notice that it is θ S (v)=θ S for all v > 2 in steady state. 37 Denote by θ S v ð Þ the average of θ S (v). Then, a sufficient condition for a good steady state to exist is: Assumption 3 requires that demand for skilled labor at v=v cc be strictly lower than supply, given that all agents are free to decide whether to go to school or not. 38 Just as Assumption 2, this boils down to a requirement that v cc , or the productivity in the economy, be high enough. At the same time, to avoid complicated cases in which some children of skilled workers may also be credit constrained, we continue to assume that v cc must be greater than 1.
With a general distribution of talent, to prove the existence of bad steady states in which v>v cc is a very complicated task. In the simpler model, any two subsequent periods in which v>v cc featured an equal number of agents going to school, and with an equal average productivity. This was because all and only the children of unskilled workers were credit constrained, while, for this high level of the skilled wage, all children of skilled workers found it optimal to go to school. A steady state was then achieved in which the skilled labor force self-perpetuated itself through the generations, displaying a constant average productivity because of the non transmissibility of talent. In the more general model that we are now looking at, however, the condition v>v cc is not sufficient to rule out intergenerational mobility, since the children of some highly productive unskilled workers may not be credit constrained. To find a steady state, we would then need to derive a set of initial conditions, and conditions on the productivity distribution, such that the number of such highly productive unskilled workers remains constant over time. 39 Because our main interest lies in analyzing the transition from a bad steady state to the good steady state, we sidestep these complications by simply assuming that bad steady states exist, and that the home economy may be stuck at one of them before trade liberalization. As H opens up in period T to a large, relatively skill-abundant world, the skilled wage in H falls from v T−1 to v*, to remain at that level at all subsequent periods. Just as before, we allow for the possibility that v* ≤ v g , that is, W's comparative advantage in exporting the skill-intensive good may be due to factors other than the severity of credit constraints in H before trade liberalization. In fact, we now remain more general as to the severity of such credit constraints. Thus, for a given v g , H's relatively high pre-trade skilled wage (v T − 1 ) may now be due to both credit constraints and other factors To shorten the exposition, we only focus on the impact of trade on the skill premium in the long-run.
A new version of Proposition 2 can be stated: Proposition 2a. Opening up to W in period T shifts H to a new steady state in period T + 1, where v = v* and no one is credit constrained. At all t ≥ T, H is a net importer of y.
Proof. See Appendix C. ▪ Before moving on, we introduce a final bit of notation. Denote by θ U (v) the distribution of productivity in the unskilled labor force when only agents with relative productivity θ≤ 2 v are in it. Notice that it is θ U (∞) =θ U . Denote by θ u v ð Þ the average of θ U (v). With a slight abuse of notation, denote by θ −u v ð Þ the average productivity of agents in the unskilled labor force when only agents with relative productivity θ > 2 v are in it. Finally, denote by λ t the share of young agents that are credit constrained in period t. Then, the general version of Proposition 3 is: Proposition 3a. Following trade liberalization in T, H's skill premium at all t ≥ T + 1 is given by: where: Proof. See Appendix C. ▪ Just as in the simpler model, the total impact of trade on the steady state skill premium is equal to the product of a Stolper-Samuelson term v Ã vT 1 and a compositional term. The latter, however, is now significantly more complicated, being itself the product of two distinct terms. The first term is the result of the fact that trade increases the relative productivity threshold above which agents work as skilled. This implies that some agents with intermediate relative productivitybut one that was high enough to join the skilled labor force in the pre-trade worldnow exit the skilled labor force. If these agents' absolute productivity is low compared to that of the surviving members of the skilled labor force, this results in an increase in the average absolute productivity in the skilled labor force. Such an increase always goes in the opposite direction relative to the Stolper-Samuelson effect (since ), and may actually reverse it. This is what happened in our simpler model, where the overall impact of trade on the skill premium could be positive for a reasonable range of parameters (see Appendix D). The second term is also the result of the increase in the relative productivity threshold, but there is also a direct effect of the elimination 36 Just as in Section 3.2.2, they cannot be credit constrained for v t ≤ v cc , since their parents cannot earn less than the minimum earned by unskilled workers; nor can they be for v t > v cc , if v cc > 1 (for the formal proof, see Appendix A). 37 For v > 2 in steady state, skilled workers in any period are all the non creditconstrained young agents of the previous period. Because talent does not depend on parental income, the productivity distribution of this subset of agent must be identical to that of the general population. 38 This is sufficient to guarantee that a good steady state exists for the same exact argument used in the proof of Proposition 1. First, demand is continuous and decreasing, while supply is continuous and non-decreasing. Second, demand converges to infinity as v falls to zero, while supply converges to zero. Thus, if no one is credit constrained in period t, schooling decisions lead to v t+1 = v g ∈ (0, v cc ) in period t + 1. But since no one is credit constrained for this level of the skilled wage, schooling decisions in period t + 1 are exactly the same as in period t, and a steady state is achieved. 39 More precisely, for the economy to be at a bad equilibrium, we would need that, in each generation, the increase in skilled labor due to the children of highly productive unskilled workers that decide to go to school perfectly offsets the decrease in skilled labor due to the children of skilled workers who decide not to go to school. of credit constraints following trade liberalization. On the one hand, the term captures the fact that some agents with an intermediate relative productivitybut one that was too high for them to join the unskilled labor force in the pre-trade worldnow join the unskilled labor force. If these agents' absolute productivity is high compared to that of the "old" members of the unskilled labor force, this results in an increase in the average productivity of the unskilled labor force. Such an increase goes in the same direction as the Stolper-Samuelson effect (since ). On the other hand, the term captures the fact that some agents with a high relative productivitywho could not join the skilled labor force in the pre-trade world because they were credit constrainedcan now leave the unskilled labor force and join the skilled labor force. While this does not affect the average productivity of the skilled labor force (which is made larger, but not compositionally different), it does affect the average productivity of the unskilled labor force. In particular, if the productivity of previously constrained agents was high, their exit will decrease the average productivity of the unskilled labor force. This discussion suggests an important point: trade liberalization is now likely to have a compositional effect on the skilled and unskilled labor force, even if there are no initial credit constraints. This is because the impact of trade on the participation constraints is, by itself, moving agents from one kind of occupation to the other. The fact that these agents are marginal, rather than average, implies that such a movement may affect the average productivity in the two kinds of occupations in interesting ways. Of course, initial credit constraints may still have an important role in the more general model. On the one hand, the more severe are initial credit constraints, the more the autarchy steady state will have both kinds of misallocation of talentagents with a comparative disadvantage in skilled occupations being part of the skilled labor force, and agents with a comparative advantage in skilled occupations being stuck in the unskilled labor force. As we shall see momentarily, under reasonable assumptions on the productivity distribution this will link initial credit constraints to the compositional effect in a way that is very similar to what we found in our simple model. On the other hand, higher initial credit constraints imply that trade liberalization is associated with a larger movement from unskilled to skilled occupations, with potentially important implications for how to interpret the recorded increase in inequality in welfare terms.
While this discussion confirms that the compositional effect of trade liberalization must be taken into account when studying the relation between trade and income inequality, our next goal is to derive meaningful sufficient conditions under which the compositional effect goes in the opposite direction than the Stolper-Samuelson effect, and can thus be called to account for some of the increase in inequality that has characterized many developing countries after trade liberalization. Our results are contained in the following two corollaries, that follow immediately from Proposition 3a: Corollary 1. With no initial credit constraints, a sufficient condition for the compositional effect to go in the opposite direction to the Stolper-Samuelson effect is: for any k and k′ such that G r (k),G r (k′)∈(0,1), and kb k′.
Corollary 2. Jointly sufficient conditions for a higher level of initial credit constraints to map into a compositional effect that dominates the Stolper-Samuelson effect are: • For a given k k ′ b1; where k and k′ are such that G r (k), G r (k′) ∈ (0, 1).
Corollary 1 has an intuitive explanation. Suppose that we divide the population in two groups, the first including only agents with relative productivity above threshold 2 k , the second including all other agents. Clearly, θ S k ð Þ θ U k ð Þ is a measure of the average productivity of agents in the first group who are skilled workers, relative to the average productivity of agents in the second group who are unskilled workers. Corollary 1 then requires that as the threshold 2 k moves up, the measure θ S k ð Þ θ U k ð Þ also moves up. This condition obtains if, for example, productivity in both types of occupations increases with θ rsay agents with a stronger comparative advantage in skilled occupations are more talented, and have thus a higher absolute productivity in both occupationsbut being talented matters more for skilled occupations than for unskilled occupations. In this case, the agents that drop out of the skilled labor force when the threshold moves up increase the average productivity of the skilled labor force by a lot (as they were very low-productivity compared to other skilled workers), while they increase the average productivity of the unskilled labor force by little (as their productivity is similar to that of other unskilled workers). 40 Corollary 2 suggests two intuitive reasons why higher initial credit constraints are likely to map into a compositional effect that dominates the Stolper-Samuelson effect. These reflect two peculiar features of a credit constrained economy. On the one hand, a credit-constrained economy can admit a very high effective skilled wage, since this is not competed away by massive inflows into the skilled labor force. 41 Many rich agents are then pushed into skilled occupations, despite having a comparative disadvantage at them. Now if these agents are also less productive at skilled occupations, and the distribution of θ is skewed towards the bottom, the compositional impact of these agents moving out of the skilled labor force is likely to be stronger when initial credit constraints are higher, since there would then be more lowproductivity agents leaving the skilled labor force following trade liberalization. 42 On the other hand, a credit constrained economy features many poor agents working in the unskilled labor force, despite having a comparative advantage at skilled activities. To the extent that, on average , agents with a stronger comparative advantage at skilled occupations are also more productive in unskilled occupations (for example, because they are more talented), 43 the negative impact of these agents moving out of the unskilled labor force will be stronger when credit constraints are initially tighter, since there would then be more of them.
One final point relates to the impact of trade liberalization on within-group wage inequality in our framework. In the simple model of Section 3, trade liberalization always leads to a decline in wage inequality in the skilled labor force (while we have assumed away wage inequality in the unskilled labor force). This result, however, does not necessarily carry through to a more general setting. With a general distribution of talent as the one that we have used in this section, it is in principle possible that trade liberalization leads to an increase in wage inequality in either groups, or in both. We conjecture that this could happen if dispersion in relative and absolute productivity was higher at the top-end of the distribution, so that agents migrating from the skilled to unskilled labor force were relatively homogenous for the former, and relatively heterogeneous for the latter. While beyond the 40 It is interesting to notice that if talent does not matter for productivity in unskilled activities and θ = θ S has a Pareto distribution, then the compositional effect exactly offsets the Stolper-Samuelson effect. This is because the Pareto distribution has a linearly increasing mean residual life, implying that it is always the case that θ S v Ã ð Þ θ S vT−1 ð Þ ¼ vT−1 v Ã . 41 On the contrary, the effective skilled wage does not need to be high in an economy that, say, is skill-scarce because of a skill-adverse technology. In such a case, the skilled wage would reflect the low relative productivity of skilled labor. 42 The first sufficient condition in Corollary 2 suggests that this must be weighed against the changing impact of this shift on the average productivity in the unskilled labor force. 43 In other words, not only does a CEO have a comparative advantage over her secretary in performing her own CEO job, but she also has an absolute advantage in both her own job and that of her secretary. scope of the current paper, this extension could help interpret some recent evidence of a rise in within group inequality following trade liberalization. 44

Conclusion
In this paper we develop a model of trade liberalization and occupational choice, with capital market imperfections. When an economy is unskilled labor-abundant because of credit constraints that affect the schooling decisions of agents, trade liberalization may have a non-standard effect on the skill premium. This is for two reasons. First, credit constraints may have allowed a large number of non-talented agents in the skilled labor force. Having been attracted to the skilled labor force by a high autarchic skilled wage, these agents may find it optimal to join the unskilled labor force when trade puts a downward pressure on the skilled wage. Second, credit constraints may have kept many talented agents out of the skilled labor force. To these agents, a trade-induced decrease in the cost of subsistence implies a lessening of credit constraints, and thus a better chance of upward mobility. Both of these effects result in an increase in the average talent of the skilled labor force, which may lead to an increase in the skill premium despite the trade-induced decrease in the skilled wage per efficiency unit of labor.
Our results provide a possible explanation for the fact that trade liberalization in unskilled labor-abundant Latin America led to an increase in the skill premium in both Latin America and its skill-abundant trade partners. One implication of this is that the increase in the skill premium in Latin America does not necessarily need to result in a massive increase in income inequality, as it may be (at least partly) due to a better allocation of talent and more intergenerational mobility.
While reconciling the predictions of the Stolper-Samuelson theorem with the Latin American experience, our mechanism is not incompatible with alternative explanations that have highlighted the role of skillbiased technical change or of quality upgrading. In fact, one interesting extension of our model is to consider the interaction of talent reallocation with these other trade-induced changes in the structure of production. Other potential extensions include studying our mechanism in the context of more structural sources of comparative advantage (such as differences in physical capital, quality of schooling, etc.), and letting the decisions of agents be affected by the wealth distribution.
Our results lead to several empirical predictions. First, trade liberalization should result in a higher proportion of not-so-talented educated children of well-off families to "leave" the skilled labor force. Such shifts could take place in the context of normal (or enhanced) labor market turnover, whereby these agents become less numerous among the newly-hired in the more competitive skilled professions, since they prefer something easier (and, in addition, earn rent income). In this context, our specific predictionone that, admittedly, may be hard to testwould be that the average quality of newly-hired skilled workers should increase following trade liberalization. Second, we expect trade liberalization to lead to a higher degree of upward mobility in the South. In particular, we should observe that, for countries where initially it is mostly skilled workers who send their children to school, trade liberalization would lead to a larger number of unskilled workers to also send their children to school. Equivalently, we should observe that the family background of skilled workers displays an increasing proportion of disadvantaged backgrounds following trade liberalization. Evidence of the latter kind would provide support for our mechanism, but would also provide support for the broader literature on trade liberalization and skill acquisition, in the presence of credit market frictions (e.g. Ranjan, 2003).
Finally, our other main empirical prediction is that, following trade liberalization, the average talent of people completing their education in a credit-constrained South should increase. While changes in the talent composition are typically not observable, the most recent literature on the evolution of the US skill premium has devised techniques to identify such changes (see, for example Lee, 2011). Carneiro and Lee (2011) find that a rise in college enrolment in 1960-2000 was associated with a decrease in the average quality of college graduates, and this had a substantial effect on the college premium. While our focus is on a credit-constrained South, this result is compatible with what the model would have predicted for the impact of trade liberalization on a non credit-constrained North. 45 Since our model suggests that the compositional effect of trade liberalization may be even more substantial in the South than in the Northas it implies not only the exit of marginal agents from the skilled labor force, but also the movement of more talented agents into the skilled labor forcewe believe an interesting avenue for future research would be to apply these identification techniques to the case of a developing country that has opened up to international trade. distinguish two cases: v 1 ≤ v cc and v 1 ∈ v cc ; v ð .
If v 1 ≤ v cc , no agent is credit constrained, and schooling decisions in period 1 maximize lifetime income given an expected skilled wage in period 2 (v 2 e ).
With rational expectations and certainty, it is always optimal for an agent who has gone to school in t =1 to be a skilled worker in t =2. Thus, the supply of skilled labor in t= 2 depends only on v 2 e :