Additional Opportunity ($1200 + Co-Authoring)
Up to an additional (12) $100 awards will be awarded to the 12 best write-ups that competitors (winners and non-winners) submit to describe their approach used. These methods will be evaluated by a panel of experts from MIT and Crowd Innovation Laboratory at Harvard University. The main evaluation criteria are validity, flexibility, performance and originality. The competitors having developed the best approach, as judged by Harvard and MIT, will not only have a chance to win an extra $100 per person but may also be invited as co-authors to write a research paper featuring the results of the challenge. Note that winners are required to write a description of the approach used to be awarded any of the prizes (see the "Requirements To Win A Prize" section below).
This challenge is the warm-up for what will be a larger match later in the year.
How much of its income should a nation save? To tackle this problem, economists traditionally use mathematical models focused on the decisions of a representative agent living for T periods. At each period, the agent chooses how much to consume and save while facing uncertainty about future income. The agent's overall well-being is measured by a utility function that is increasing in consumption and the utility of future consumption is discounted by a factor β < 1. The agent gets an income that can be either consumed or invested into capital Kt+1. The returns on this investment are uncertain and will generate the agent's income in the next period.
In this challenge, your task is to develop an algorithm that dictates how much the agent should consume and save at each period in order to maximize his or her expected well-being. This task can be thought of as if you were the main adviser of a policy maker that is deciding about the optimal level of investments of a country in order to maximize the national welfare.
You have to make a series of decisions about consumption Ct and invested capital Kt+1 to solve the following maximization problem.
The operator Et is the expectation with respect to consumption at a given time t. Your preferences towards consumption in a given period are characterized by the following utility function.
You'd rather prefer to consume a given quantity today than tomorrow. That is, utility in future periods is discounted by a discounting factor 0 < β < 1. The sum of consumption and invested capital must be less than or equal to the wage Wt which is determined by:
where 0 ≤ δ < 1 is the depreciation rate of capital, 0 < α < 1 is the productivity of capital and Zt is the realization of an exogenous random variable distributed as follows.
where 0 < ρ < 1 is the degree of correlation with past shocks and εt is a normal random variable with zero mean and standard deviation σ. Initial conditions K0 > 0 and Z0 > 0 are given.
To solve the problem, you have to develop a decision rule for consumption which delivers the optimal choice of consumption Ct as a function of the level of capital Kt, the realized shock Zt, and the parameters of the economy that satisfies the following optimality conditions.
Analytical decision rules that satisfy these optimality conditions are not known. Researchers typically turn to numerical methods to find approximate solutions. For example, a standard procedure is based upon a Taylor's series expansion of the decision rule when shocks are deterministic. The effectiveness of many of these algorithms is discussed by Taylor and Uhlig (1990). You are encouraged to implement one of such methods or come up with a new one.
Your task is to develop two functions: SetEconomyParameters and ConsumptionDecisionRule. SetEconomyParameters will be called once at the beginning of each test case. ConsumptionDecisionRule will be called iteratively T times for each test case (for times t = 0 to t = T-1) with each call considering N concurrent simulations.
SetEconomyParameters recieves the following arguments:
ConsumptionDecisionRule recieves the following arguments:
ConsumptionDecisionRule must return the consumption for this time period for each of the N concurrent simulations. Consumption at each time period for each simulation must be real, non-negative, and not greater than the current wage.
Test cases are defined by a specific configuration of the economy's parameters, the time horizon T, and the number of simulations N. Test cases have been randomly split into three sets: example, provisional, and system. The example set contains 800 test cases can be downloaded here. The provisional set contains 400 test cases and is used for scoring during the contest. The system set contains 800 test cases and is used for final testing resulting in your final score and placement.
For each test case, the method ConsumptionDecisionRule is called iteratively for each time t from t = 0 to t = T-1.
Your score for each test case is the averaged Euler conditions residuals over all N simulations multiplied by 1,000,000. Scores over each test case in a set of test cases (example, provisional, or system) are averaged to find your final score.
You are encouraged to check the source code for exact implementation of the simulation and score calculation. Feel free to use the simulator code in your solution.
Free MATLAB! Mathworks has very kindly agreed to support this challenge by granting access to MATLAB for competitors! Competitors can click here to request software from MATLAB. License periods are 30 days. Here is the link to the trial instructions.
IMPORTANT NOTE: MATLAB solutions cannot be submitted in the marathon platform but can be submitted in our simultaneously running "MATLAB only" contest here which will run in parallel alongside this marathon contest. The scores of the submissions to the "MATLAB only" contest will be manually inserted into the marathon leaderboard of this contest periodically. These MATLAB submissions will qualify for the prizes in this contest.
Requirements to Win a Prize
In order to receive a prize, you must do all the following:
Your report must be at least 2 pages long, contain at least the following sections, and use the section and bullet names below.
This section must contain at least the following:
Please describe your algorithm so that we know what you did even before seeing your code. Use line references to refer to specific portions of your code.
This section must contain at least the following:
This problem statement is the exclusive and proprietary property of TopCoder, Inc. Any unauthorized use or reproduction of this information without the prior written consent of TopCoder, Inc. is strictly prohibited. (c)2020, TopCoder, Inc. All rights reserved.