# Based on the theoretical model introduced by Liu and Mumtaz

Based on the theoretical model introduced by Liu and Mumtaz (2011) which utilizes the open-economy model proposed by Justiniano and Preston (2010) and by adopting the method formulated by Farmer et al. (2008), this paper employs regime shifts in certain parameters, such as those of the monetary policy rule, of inflation persistence, and of volatility shocks on the Brazilian economy after the Real Plan, between 1996 and 2012. Presumably, these parameters were not constant over the analyzed period, given the changes in the Brazilian economy, such as the adoption of the inflation targeting system, replacement of the Central Bank of Brazil\'s president, and the swearing-in of the new Brazilian president.
Aside from the introduction, this paper is organized as follows. Section 2 introduces the open-economy DSGE model with the inclusion of Markov regimes. Section 3 deals with the MS-DSGE model solution and estimation methods. Section 4 analyzes the results, and Section 5 then concludes.

The MS-DSGE model
Based on Gali and Monacelli (2005) and Monacelli (2005), Justiniano and Preston (2010) introduced important features into DSGE models for a small open economy, such as incomplete asset market, habit formation, and price indexation to past inflation.
The empirical literature uses log-linear approximation of the model\'s optimality conditions around a non-stochastic steady state. In what follows, we present the equations pertaining to this analysis. All variables are construed as the log of deviations from the respective steady state values. The model proposed by Justiniano and Preston (2010) is shown next, according to the work of Liu and Mumtaz (2011).
The log-linear Euler equation, obtained from the householdsâ€™ intertemporal maximization problem, is expressed by:where the log of current consumption depends on consumption at , on the expected future consumption and on the real interest rate . Parameter is the degree of habit persistence, is the inverse of the intertemporal elasticity of Rimonabant and is the preference shock. The log-linear approximation of the commodity market equilibrium condition is given by:where is the domestic output, denotes the terms of trade, is the real exchange rate and is the foreign output. Eq. (2) shows that the domestic output is the sum of domestic consumption and exports, while parameter represents the level of economic openness and is the elasticity of substitution between domestic and imported goods. The law of one price is given by:where is the deviation from the law of one price. The terms of trade are given by . This implies:where is the imported inflation and is the domestic inflation. Thus, steady-state domestic consumption depends on domestic output and on three sources of external disturbances: the terms of trade, deviation from the law of one price, and foreign output.
The relationship between the real exchange rate and the terms of trade can be expressed by the equation:
The Phillips curve for domestic inflation is given by the following equation:where is the real marginal cost function of each firm, is the technology shock, is the intertemporal discount rate, measures the indexation rate, is the fraction of firms that do not adjust their prices every period and is the inverse of the elasticity of labor supply. Therefore, domestic inflation depends on past inflation and on its expectation for the subsequent period, and on the current marginal cost .
The Phillips curve for imported inflation is given by:
Similarly to Eq. (6), Eq. (7) incorporates the deviations of the law of one price (Eq. (3)) for imported goods, given the hypothesis that import retailers engage in monopolistic competition. Furthermore, an exogenous cost-push shock that captures inefficient variations in mark-ups is taken into account.
Current inflation relates to domestic and imported inflation as follows:
The uncovered interest rate parity condition is given by Eq. (9):where is the level of foreign assets, is the elasticity of debt relative to the interest rate premium and is the risk premium shock. The flow of budgetary constraint of assets can be represented by