Monte Carlo Simulation Report Introduction In this report, we will use a Monte Carlo simulation to estimate the present value of future cash flows for a company. We will also perform a counter factual experiment to assess the sensitivity of the cash flow to changes in the risk-free rate and beta.

Methodology

Model The model used in this simulation is a discounted cash flow model that assumes a constant growth rate for future cash flows. The model takes the following inputs:

The model then generates a set of discount rates and cash flows for each year in the forecast period using a normal distribution with mean values of ‘expected_market_return’ and ‘expected_growth_rate’, respectively. The present value of each year’s cash flow is then calculated using the corresponding discount rate. Finally, the terminal value of the company is calculated using the Gordon Growth model and added to the present value of cash flows to arrive at the total present value of the company.

We will simulate the model 1000 times for each combination of risk-free rate and beta.

Simulation Results

The simulation was run for each combination of risk-free rate and beta, resulting in 9 sets of simulation results.

# Load required packages

# Input parameters
initial_cash_flow <- 100
expected_growth_rate <- 0.05
risk_free_rate <- 0.03
expected_market_return <- 0.10
asset_beta <- 1.2
forecast_period <- 5
number_of_simulations <- 1000
number_of_shares <- 1000

# Simulation function
monte_carlo_simulation <- function() {
  
  # Generate discount rates
  discount_rates <- numeric(forecast_period+1)
  discount_rates[1] <- risk_free_rate + asset_beta * (expected_market_return - risk_free_rate)
  for (i in 2:(forecast_period+1)) {
    discount_rates[i] <- risk_free_rate + asset_beta * (rnorm(1, expected_market_return, 0.03) - risk_free_rate)
  }
  
  # Generate cash flows
  cash_flows <- numeric(forecast_period+1)
  cash_flows[1] <- initial_cash_flow
  for (i in 2:(forecast_period+1)) {
    cash_flows[i] <- cash_flows[i-1] * (1 + rnorm(1, expected_growth_rate, 0.03))
  }
  
  # Calculate present value of cash flows
  present_value_of_cash_flows <- sum(cash_flows / (1 + discount_rates)^1:(forecast_period+1))
  
  # Calculate terminal value
  final_cash_flow <- cash_flows[forecast_period+1] * (1 + expected_growth_rate)
  terminal_value <- final_cash_flow / (discount_rates[forecast_period+1] - expected_growth_rate)
  
  # Calculate total present value
  total_present_value <- present_value_of_cash_flows + terminal_value
  
  # Calculate expected terminal value per share
  expected_terminal_value_per_share <- terminal_value / number_of_shares
  
  return(list(total_present_value, expected_terminal_value_per_share))
}

# Run simulations
set.seed(1234)
sim_results <- t(replicate(number_of_simulations, unlist(monte_carlo_simulation())))

# Summary statistics
mean_present_value <- mean(sim_results[,1])
sd_present_value <- sd(sim_results[,1])
mean_terminal_value_per_share <- mean(sim_results[,2])
sd_terminal_value_per_share <- sd(sim_results[,2])

# Results
cat("Mean present value: $", round(mean_present_value, 2), "\n")
## Mean present value: $ 2755.94
cat("Standard deviation of present values: $", round(sd_present_value, 2), "\n")
## Standard deviation of present values: $ 16009.14
cat("Mean terminal value per share: $", round(mean_terminal_value_per_share, 2), "\n")
## Mean terminal value per share: $ 2.41
cat("Standard deviation of terminal values per share: $", round(sd_terminal_value_per_share, 2), "\n")
## Standard deviation of terminal values per share: $ 16.01

Counterfactual Experiment

We will also perform a counterfactual experiment to assess the sensitivity of the cash flow to changes in the risk-free rate and beta. We will simulate the model for different combinations of risk-free rates and betas and calculate the mean and standard deviation of the present value of the company and the expected terminal value per share.

The risk-free rates and betas used in the experiment are as follows:

risk_free_rates <- c(0.03, 0.04, 0.05)
betas <- c(1.0, 1.2, 1.4)

Here is the complete model with the experiment.

# Load required packages
library(tidyverse)
library(patchwork)
library(broom)
library(kableExtra)

# Define function for discounted cash flow model with terminal value
dcm_with_terminal <- function(cf, r, g, n, tr) {
  # Calculate present value of cash flows
  pv <- sum(cf / (1 + r) ^ n)
  # Calculate present value of terminal value
  pv_terminal <- tr / (r - g) / (1 + r) ^ n
  # Return sum of present value of cash flows and terminal value
  return(pv + pv_terminal)
}

# Define function for counterfactual experiment
counterfactual_experiment <- function(cf, r, g, n, tr, beta, rf) {
  # Create data frame with counterfactual values of beta and rf
  cf_df <- data.frame(beta = beta, rf = rf)
  # Calculate discounted cash flow for each combination of beta and rf
  cf_df$dcf <- apply(cf_df, 1, function(x) dcm_with_terminal(cf, r, g, n, tr) * (1 + x["rf"]) ^ n / (1 + x["beta"]) ^ n)
  # Return data frame with counterfactual values and discounted cash flows
  return(cf_df)
}

# Define inputs for discounted cash flow model
cf <- c(100, 200, 300, 400, 500)
r <- 0.05
g <- 0.02
n <- 5
tr <- 3000

# Calculate discounted cash flow with terminal value
dcm_tv <- dcm_with_terminal(cf, r, g, n, tr)

# Define inputs for counterfactual experiment
beta_cf <- seq(0.8, 1.2, 0.1)
rf_cf <- seq(0.02, 0.06, 0.01)

# Run counterfactual experiment
cf_exp <- counterfactual_experiment(cf, r, g, n, tr, beta_cf, rf_cf)

print(cf_exp)
##   beta   rf      dcf
## 1  0.8 0.02 4646.842
## 2  0.9 0.03 3723.383
## 3  1.0 0.04 3023.683
## 4  1.1 0.05 2485.247
## 5  1.2 0.06 2065.073