equilibrium.
Macroeconomics: The Study of the Economy as a Whole
Now, let's switch gears and talk about macroeconomics. Macroeconomics is the branch of
economics that studies the behavior of the economy as a whole, focusing on issues like
economic growth, inflation, and unemployment.
Imagine you're a policymaker, and you're trying to understand how to stimulate economic
growth. You might look at macroeconomic indicators like GDP (Gross Domestic Product),
inflation rate, and unemployment rate to get a sense of the overall state of the economy.
GDP: A Key Macroeconomic Indicator
GDP is the total value of all final goods and services produced within a country's borders. It's a
widely used indicator of a country's economic activity and growth.
For example, let's say the GDP of a country is $100 billion. This means that the country
produced $100 billion worth of goods and services in a given year. If the GDP increases to $110
billion the next year, this represents a 10% increase in economic growth.
Step-by-Step Calculation: GDP Growth Rate
GDP (Year 1) = $100 billion
GDP (Year 2) = $110 billion
GDP Growth Rate = (GDP Year 2 - GDP Year 1) / GDP Year 1
GDP Growth Rate = ($110 billion - $100 billion) / $100 billion
GDP Growth Rate = 10%
Inflation: A Macroeconomic Phenomenon
Inflation is a sustained increase in the general price level of goods and services in an economy
over time. It's a macroeconomic phenomenon that affects the purchasing power of consumers.
For example, let's say the inflation rate is 2%. This means that the prices of goods and services
are increasing by 2% every year. If your income is not increasing at the same rate, your
purchasing power is actually decreasing.
Code Sample: Calculating Inflation Rate
def calculate_inflation_rate(current_price, previous_price):
inflation_rate = (current_price - previous_price) / previous_price
return inflation_rate