Consider the standard intertemporal optimization problem facing a generic consumer with access to N different assets. Consumption and portfolio decisions are assumed to follow from the maximization of the expected lifetime value of utility from consumption (appropriately discounted) subject to an intertemporal budget constraint that reflects the intertemporal allocation possibilities available. Assuming that lifetime utility displays additive separability (and omitting individual indexes for simplicity) the maximization problem can be written as follows: Source

where Cs denotes (non durable) consumption in period j, v denotes other factors that might affect the (marginal) utility of non durable consumption such as demographic variables, /3 is the discount factor, Ak is the amount of wealth held in asset к and / is the rate of return on that asset.

If asset к is held in periods / and t+ /, a first order condition for this problem is

where wt+1 is the intertemporal marginal rate of substitution between consumption in / and t+1, and n are the assets held by the consumer in non-zero amounts, assumed to be, without loss of generality, the first я. For the remaining N-я assets, equation (3) does not hold as an equality. Note that equation (3) can also be expressed in terms of excess returns, for example between a risk}7 and a safe asset: