An indifference curve
indifference_func.Rd
This function gives points along an indifference curve in
(q_dot_s/q_dot_s_orig, C_dot_o/C_dot_o_orig) space.
The indifference curve assumes CES utility.
The equation of the indifference curve is
u_dot/u_dot_orig = [f_Cs*(q_dot_s/q_dot_s_orig)^rho + (1-f_Cs)*(C_dot_o/C_dot_o_orig)^rho]^(1/rho)
.
Arguments
- qs_qs0
The ratio
q_dot_s/q_dot_s_orig
. Sweeping this variable (x) gives the indifference curve parameterized by the other arguments.- qs1_qs0
The x coordinate of a point on this indifference curve.
- Co1_Co0
The y coordinate of a point on this indifference curve.
- f_Cs_orig
The fraction of original spending on the energy service relative to the sum of energy service and other goods spending, calculated by
C_dot_s_orig / (C_dot_s_orig + C_dot_o_orig)
.- sigma
The elasticity of substitution between the energy service and other goods.
- rho
The exponent in the CES utility function. Default is
(sigma-1)/sigma
.
Examples
qs1_qs0 <- 1
Co1_Co0 <- 1
sigma <- 0.3
f_Cs_orig <- 0.01
DF <- data.frame(x = seq(0.5, 1.5, by = 0.1)) %>%
dplyr::mutate(
y = indifference_func(x, qs1_qs0 = qs1_qs0, Co1_Co0 = Co1_Co0,
f_Cs_orig = f_Cs_orig, sigma = sigma)
)
DF
#> x y
#> 1 0.5 1.0180150
#> 2 0.6 1.0100956
#> 3 0.7 1.0056743
#> 4 0.8 1.0029720
#> 5 0.9 1.0012089
#> 6 1.0 1.0000000
#> 7 1.1 0.9991380
#> 8 1.2 0.9985037
#> 9 1.3 0.9980246
#> 10 1.4 0.9976545
#> 11 1.5 0.9973634