IDEAS home Printed from https://ideas.repec.org/p/arx/papers/2509.13623.html
   My bibliography  Save this paper

Deep Learning in the Sequence Space

Author

Listed:
  • Marlon Azinovic-Yang
  • Jan v{Z}emliv{c}ka

Abstract

We develop a deep learning algorithm for approximating functional rational expectations equilibria of dynamic stochastic economies in the sequence space. We use deep neural networks to parameterize equilibrium objects of the economy as a function of truncated histories of exogenous shocks. We train the neural networks to fulfill all equilibrium conditions along simulated paths of the economy. To illustrate the performance of our method, we solve three economies of increasing complexity: the stochastic growth model, a high-dimensional overlapping generations economy with multiple sources of aggregate risk, and finally an economy where households and firms face uninsurable idiosyncratic risk, shocks to aggregate productivity, and shocks to idiosyncratic and aggregate volatility. Furthermore, we show how to design practical neural policy function architectures that guarantee monotonicity of the predicted policies, facilitating the use of the endogenous grid method to simplify parts of our algorithm.

Suggested Citation

  • Marlon Azinovic-Yang & Jan v{Z}emliv{c}ka, 2025. "Deep Learning in the Sequence Space," Papers 2509.13623, arXiv.org.
  • Handle: RePEc:arx:papers:2509.13623
    as

    Download full text from publisher

    File URL: http://arxiv.org/pdf/2509.13623
    File Function: Latest version
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Jiequn Han & Yucheng Yang & Weinan E, 2021. "DeepHAM: A Global Solution Method for Heterogeneous Agent Models with Aggregate Shocks," Papers 2112.14377, arXiv.org, revised Feb 2022.
    2. Duffy, John & McNelis, Paul D., 2001. "Approximating and simulating the stochastic growth model: Parameterized expectations, neural networks, and the genetic algorithm," Journal of Economic Dynamics and Control, Elsevier, vol. 25(9), pages 1273-1303, September.
    3. Boppart, Timo & Krusell, Per & Mitman, Kurt, 2018. "Exploiting MIT shocks in heterogeneous-agent economies: the impulse response as a numerical derivative," Journal of Economic Dynamics and Control, Elsevier, vol. 89(C), pages 68-92.
    4. Nicholas Bloom & Max Floetotto & Nir Jaimovich & Itay Saporta†Eksten & Stephen J. Terry, 2018. "Really Uncertain Business Cycles," Econometrica, Econometric Society, vol. 86(3), pages 1031-1065, May.
    5. Victor Duarte & Julia Fonseca & Aaron S. Goodman & Jonathan A. Parker, 2021. "Simple Allocation Rules and Optimal Portfolio Choice Over the Lifecycle," NBER Working Papers 29559, National Bureau of Economic Research, Inc.
    6. Andriy Norets, 2012. "Estimation of Dynamic Discrete Choice Models Using Artificial Neural Network Approximations," Econometric Reviews, Taylor & Francis Journals, vol. 31(1), pages 84-106.
    7. Aryan Eftekhari & Doris Folini & Aleksandra Friedl & Felix Kubler & Simon Scheidegger & Olaf Schenk, 2024. "Building Interpretable Climate Emulators for Economics," Papers 2411.10768, arXiv.org, revised Jun 2025.
    8. Kenneth L. Judd, 1998. "Numerical Methods in Economics," MIT Press Books, The MIT Press, edition 1, volume 1, number 0262100711, December.
    9. Yili Chien & Harold Cole & Hanno Lustig, 2011. "A Multiplier Approach to Understanding the Macro Implications of Household Finance," The Review of Economic Studies, Review of Economic Studies Ltd, vol. 78(1), pages 199-234.
    10. Adrien Auclert & Bence Bardóczy & Matthew Rognlie & Ludwig Straub, 2021. "Using the Sequence‐Space Jacobian to Solve and Estimate Heterogeneous‐Agent Models," Econometrica, Econometric Society, vol. 89(5), pages 2375-2408, September.
    11. Bewley, Truman, 1977. "The permanent income hypothesis: A theoretical formulation," Journal of Economic Theory, Elsevier, vol. 16(2), pages 252-292, December.
    12. Aubhik Khan & Julia K. Thomas, 2008. "Idiosyncratic Shocks and the Role of Nonconvexities in Plant and Aggregate Investment Dynamics," Econometrica, Econometric Society, vol. 76(2), pages 395-436, March.
    13. Druedahl, Jeppe & Jørgensen, Thomas Høgholm, 2017. "A general endogenous grid method for multi-dimensional models with non-convexities and constraints," Journal of Economic Dynamics and Control, Elsevier, vol. 74(C), pages 87-107.
    14. Reiter, Michael, 2009. "Solving heterogeneous-agent models by projection and perturbation," Journal of Economic Dynamics and Control, Elsevier, vol. 33(3), pages 649-665, March.
    15. Krueger, Dirk & Kubler, Felix, 2004. "Computing equilibrium in OLG models with stochastic production," Journal of Economic Dynamics and Control, Elsevier, vol. 28(7), pages 1411-1436, April.
    16. Doris Folini & Aleksandra Friedl & Felix Kübler & Simon Scheidegger, 2025. "The Climate in Climate Economics," The Review of Economic Studies, Review of Economic Studies Ltd, vol. 92(1), pages 299-338.
    17. Tauchen, George, 1986. "Statistical Properties of Generalized Method-of-Moments Estimators of Structural Parameters Obtained from Financial Market Data: Reply," Journal of Business & Economic Statistics, American Statistical Association, vol. 4(4), pages 423-425, October.
    18. S. Rao Aiyagari, 1994. "Uninsured Idiosyncratic Risk and Aggregate Saving," The Quarterly Journal of Economics, President and Fellows of Harvard College, vol. 109(3), pages 659-684.
    19. Carroll, Christopher D., 2006. "The method of endogenous gridpoints for solving dynamic stochastic optimization problems," Economics Letters, Elsevier, vol. 91(3), pages 312-320, June.
    20. Per Krusell & Anthony A. Smith & Jr., 1998. "Income and Wealth Heterogeneity in the Macroeconomy," Journal of Political Economy, University of Chicago Press, vol. 106(5), pages 867-896, October.
    21. Young, Eric R., 2010. "Solving the incomplete markets model with aggregate uncertainty using the Krusell-Smith algorithm and non-stochastic simulations," Journal of Economic Dynamics and Control, Elsevier, vol. 34(1), pages 36-41, January.
    22. Vytautas Valaitis & Alessandro T. Villa, 2024. "A machine learning projection method for macro‐finance models," Quantitative Economics, Econometric Society, vol. 15(1), pages 145-173, January.
    23. Christian Bayer & Ralph Luetticke, 2020. "Solving discrete time heterogeneous agent models with aggregate risk and many idiosyncratic states by perturbation," Quantitative Economics, Econometric Society, vol. 11(4), pages 1253-1288, November.
    24. Jesús Fernández‐Villaverde & Samuel Hurtado & Galo Nuño, 2025. "Corrigendum: Financial Frictions and the Wealth Distribution," Econometrica, Econometric Society, vol. 93(4), pages 1491-1496, July.
    25. William A. Brock & Leonard J. Mirman, 2001. "Optimal Economic Growth And Uncertainty: The Discounted Case," Chapters, in: W. D. Dechert (ed.), Growth Theory, Nonlinear Dynamics and Economic Modelling, chapter 1, pages 3-37, Edward Elgar Publishing.
    26. Marlon Azinovic & Luca Gaegauf & Simon Scheidegger, 2022. "Deep Equilibrium Nets," International Economic Review, Department of Economics, University of Pennsylvania and Osaka University Institute of Social and Economic Research Association, vol. 63(4), pages 1471-1525, November.
    27. Marlon Azinovic & Harold L. Cole & Felix Kübler, 2023. "Asset Pricing in a Low Rate Environment," Swiss Finance Institute Research Paper Series 23-31, Swiss Finance Institute.
    28. Houyuan Jiang, 1999. "Global Convergence Analysis of the Generalized Newton and Gauss-Newton Methods of the Fischer-Burmeister Equation for the Complementarity Problem," Mathematics of Operations Research, INFORMS, vol. 24(3), pages 529-543, August.
    29. Johannes Brumm & Simon Scheidegger, 2017. "Using Adaptive Sparse Grids to Solve High‐Dimensional Dynamic Models," Econometrica, Econometric Society, vol. 85, pages 1575-1612, September.
    30. Cai, Yongyang & Judd, Kenneth L., 2012. "Dynamic programming with shape-preserving rational spline Hermite interpolation," Economics Letters, Elsevier, vol. 117(1), pages 161-164.
    31. Zhouzhou Gu & Mathieu Laurière & Sebastian Merkel & Jonathan Payne, 2023. "Deep Learning Solutions to Master Equations for Continuous Time Heterogeneous Agent Macroeconomic Models," Working Papers 2023-19, Princeton University. Economics Department..
    32. Maliar, Lilia & Maliar, Serguei & Winant, Pablo, 2021. "Deep learning for solving dynamic economic models," Journal of Monetary Economics, Elsevier, vol. 122(C), pages 76-101.
    33. Marlon Azinovic-Yang & Harold L. Cole & Felix Kubler, 2023. "Low Risk-Free Rates and Intertemporal Arbitrage," NBER Working Papers 31832, National Bureau of Economic Research, Inc.
    34. Goutham Gopalakrishna, 2021. "ALIENs and Continuous Time Economies," Swiss Finance Institute Research Paper Series 21-34, Swiss Finance Institute.
    35. Huggett, Mark, 1993. "The risk-free rate in heterogeneous-agent incomplete-insurance economies," Journal of Economic Dynamics and Control, Elsevier, vol. 17(5-6), pages 953-969.
    36. Tauchen, George, 1986. "Statistical Properties of Generalized Method-of-Moments Estimators of Structural Parameters Obtained from Financial Market Data," Journal of Business & Economic Statistics, American Statistical Association, vol. 4(4), pages 397-416, October.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Marlon Azinovic & Luca Gaegauf & Simon Scheidegger, 2022. "Deep Equilibrium Nets," International Economic Review, Department of Economics, University of Pennsylvania and Osaka University Institute of Social and Economic Research Association, vol. 63(4), pages 1471-1525, November.
    2. Zhouzhou Gu & Mathieu Lauri`ere & Sebastian Merkel & Jonathan Payne, 2024. "Global Solutions to Master Equations for Continuous Time Heterogeneous Agent Macroeconomic Models," Papers 2406.13726, arXiv.org.
    3. Fernández-Villaverde, Jesús & Marbet, Joël & Nuño, Galo & Rachedi, Omar, 2025. "Inequality and the zero lower bound," Journal of Econometrics, Elsevier, vol. 249(PC).
    4. Pascal, Julien, 2024. "Artificial neural networks to solve dynamic programming problems: A bias-corrected Monte Carlo operator," Journal of Economic Dynamics and Control, Elsevier, vol. 162(C).
    5. François Le Grand & Xavier Ragot, 2022. "Managing Inequality Over Business Cycles: Optimal Policies With Heterogeneous Agents And Aggregate Shocks," International Economic Review, Department of Economics, University of Pennsylvania and Osaka University Institute of Social and Economic Research Association, vol. 63(1), pages 511-540, February.
    6. Kase, Hanno & Melosi, Leonardo & Rottner, Matthias, 2022. "Estimating Nonlinear Heterogeneous Agents Models with Neural Networks," CEPR Discussion Papers 17391, C.E.P.R. Discussion Papers.
    7. Schesch, Constantin, 2024. "Pseudospectral methods for continuous-time heterogeneous-agent models," Journal of Economic Dynamics and Control, Elsevier, vol. 163(C).
    8. Adrien Auclert & Bence Bardóczy & Matthew Rognlie & Ludwig Straub, 2021. "Using the Sequence‐Space Jacobian to Solve and Estimate Heterogeneous‐Agent Models," Econometrica, Econometric Society, vol. 89(5), pages 2375-2408, September.
    9. Dobrew, Michael & Gerke, Rafael & Giesen, Sebastian & Röttger, Joost, 2025. "Make-up strategies with incomplete markets and bounded rationality," European Economic Review, Elsevier, vol. 173(C).
    10. Bruce Preston & Mauro Roca, 2007. "Incomplete Markets, Heterogeneity and Macroeconomic Dynamics," NBER Working Papers 13260, National Bureau of Economic Research, Inc.
    11. Aryan Eftekhari & Michel Juillard & Normann Rion & Simon Scheidegger, 2025. "Scalable Global Solution Techniques for High-Dimensional Models in Dynare," Papers 2503.11464, arXiv.org.
    12. Victor Duarte & Diogo Duarte & Dejanir H. Silva, 2024. "Machine Learning for Continuous-Time Finance," CESifo Working Paper Series 10909, CESifo.
    13. Isaiah Hull & Or Sattath & Eleni Diamanti & Göran Wendin, 2024. "Quantum Technology for Economists," Contributions to Economics, Springer, number 978-3-031-50780-9.
    14. Judd, Kenneth L. & Maliar, Lilia & Maliar, Serguei & Valero, Rafael, 2014. "Smolyak method for solving dynamic economic models: Lagrange interpolation, anisotropic grid and adaptive domain," Journal of Economic Dynamics and Control, Elsevier, vol. 44(C), pages 92-123.
    15. Sergio Ocampo & Baxter Robinson, 2024. "Computing Longitudinal Moments for Heterogeneous Agent Models," Computational Economics, Springer;Society for Computational Economics, vol. 64(3), pages 1891-1912, September.
    16. Ivo Bakota, 2023. "Market Clearing and Krusell-Smith Algorithm in an Economy with Multiple Assets," Computational Economics, Springer;Society for Computational Economics, vol. 62(3), pages 1007-1045, October.
    17. Karsten O. Chipeniuk, 2020. "Optimal Grid Selection for the Numerical Solution of Dynamic Stochastic Optimization Problems," Computational Economics, Springer;Society for Computational Economics, vol. 56(4), pages 883-928, December.
    18. Marlon Azinovic & Jan v{Z}emliv{c}ka, 2023. "Economics-Inspired Neural Networks with Stabilizing Homotopies," Papers 2303.14802, arXiv.org.
    19. Francesco Ferlaino, 2024. "Does the financial accelerator accelerate inequalities?," Working Papers 538, University of Milano-Bicocca, Department of Economics.
    20. Thomas J. Sargent & John Stachurski, 2024. "Dynamic Programming: Finite States," Papers 2401.10473, arXiv.org.

    More about this item

    NEP fields

    This paper has been announced in the following NEP Reports:

    Statistics

    Access and download statistics

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:arx:papers:2509.13623. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: arXiv administrators (email available below). General contact details of provider: http://arxiv.org/ .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.