This paper studies a consumption-portfolio problem where money enters the agent's utility function. We solve the corresponding Hamilton-Jacobi-Bellman equation and provide closed-form solutions for the optimal consumption and portfolio strategy both in an infinite- and finite-horizon setting. For the infinite-horizon problem, the optimal stock demand is one particular root of a polynomial. In the finite-horizon case, the optimal stock demand is given by the inverse of the solution to an ordinary differential equation that can be solved explicitly. We also prove verification results showing that the solution to the Bellman equation is indeed the value function of the problem. From an economic point of view, we find that in the finite-horizon case the optimal stock demand is typically decreasing in age, which is in line with rules of thumb given by financial advisers and also with recent empirical evidence.
consumption-portfolio choice money in the utility function stock demand stochastic control