Carregando WebR...
# ============================================ # Imposto sobre o monopolista # Exercicio Resolvido 15.3 # ============================================ # --- Parametros --- a <- 60 # demanda: p = a - q c <- 12 # custo marginal t <- 8 # imposto unitario cat("====== IMPOSTO SOBRE O MONOPOLISTA ======\n") cat("Demanda: p =", a, "- q\n") cat("CMg =", c, " Imposto t =", t, "\n\n") # --- Antes do imposto --- qm0 <- (a - c) / 2 pm0 <- a - qm0 lucro0 <- (pm0 - c) * qm0 EC0 <- 0.5 * (a - pm0) * qm0 cat("--- Antes do imposto ---\n") cat("q^m =", qm0, " p^m =", pm0, "\n") cat("Lucro =", lucro0, " EC =", EC0, "\n\n") # --- Depois do imposto --- c_eff <- c + t qm1 <- (a - c_eff) / 2 pm1 <- a - qm1 lucro1 <- (pm1 - c_eff) * qm1 EC1 <- 0.5 * (a - pm1) * qm1 receita_fiscal <- t * qm1 cat("--- Depois do imposto ---\n") cat("CMg efetivo =", c_eff, "\n") cat("q^m(t) =", qm1, " p^m(t) =", pm1, "\n") cat("Lucro (liq. imposto) =", lucro1, " EC =", EC1, "\n") cat("Receita fiscal = t*q =", receita_fiscal, "\n\n") # --- Analise do repasse --- delta_p <- pm1 - pm0 repasse <- delta_p / t * 100 delta_EC <- EC1 - EC0 delta_lucro <- lucro1 - lucro0 cat("--- Analise do repasse ---\n") cat("Delta p =", delta_p, " (repasse:", repasse, "%)\n") cat("Delta EC =", delta_EC, "\n") cat("Delta lucro =", delta_lucro, "\n") cat("Receita fiscal =", receita_fiscal, "\n") # PPM antes e depois qc <- a - c PPM0 <- 0.5 * (pm0 - c) * (qc - qm0) qc1 <- a - c_eff PPM1 <- 0.5 * (pm1 - c_eff) * (qc1 - qm1) delta_PPM <- PPM1 - PPM0 cat("\nPPM antes =", PPM0, " PPM depois =", PPM1, "\n") cat("Delta PPM =", delta_PPM, "\n") cat("Perda total (consumidor+produtor) =", abs(delta_EC) + abs(delta_lucro), "\n") cat("Receita fiscal =", receita_fiscal, "\n") cat("Diferenca =", abs(delta_EC) + abs(delta_lucro) - receita_fiscal, "= Delta PPM\n") # --- Grafico --- par(mfrow = c(1, 2), mar = c(4.5, 4.5, 3, 1), bg = "#f8f9fa") # Painel 1: Antes e depois q_seq <- seq(0, 55, length = 300) p_dem <- a - q_seq RMg0 <- a - 2 * q_seq plot(q_seq, p_dem, type = "l", lwd = 3, col = "#0d6efd", ylim = c(0, 65), xlim = c(0, 55), xlab = "q", ylab = "p", main = "Efeito do imposto unitario") lines(q_seq, RMg0, lwd = 2, col = "#6f42c1", lty = 2) abline(h = c, col = "#198754", lwd = 2) abline(h = c_eff, col = "#dc3545", lwd = 2, lty = 3) points(qm0, pm0, pch = 19, col = "#198754", cex = 1.8) points(qm1, pm1, pch = 17, col = "#dc3545", cex = 1.8) arrows(qm0 - 0.5, pm0 + 0.5, qm1 + 0.5, pm1 - 0.5, col = "#fd7e14", lwd = 2, length = 0.08) text(qm0 + 1.5, pm0 - 2, "Antes", col = "#198754", cex = 0.8, font = 2) text(qm1 - 1, pm1 + 2.5, "Depois", col = "#dc3545", cex = 0.8, font = 2) legend("topright", legend = c("Demanda", "RMg", paste0("CMg = ", c), paste0("CMg+t = ", c_eff)), col = c("#0d6efd", "#6f42c1", "#198754", "#dc3545"), lwd = c(3, 2, 2, 2), lty = c(1, 2, 1, 3), cex = 0.65, bg = "white") # Painel 2: Repasse vs taxa t_seq <- seq(0, a - c - 1, length = 200) repasse_pct <- rep(50, length(t_seq)) # sempre 50% com demanda linear lucro_seq <- ((a - c - t_seq) / 2)^2 receita_seq <- t_seq * (a - c - t_seq) / 2 plot(t_seq, receita_seq, type = "l", lwd = 3, col = "#0d6efd", xlab = "Imposto (t)", ylab = "R$ / %", main = "Receita fiscal e lucro", ylim = c(0, max(lucro_seq) * 1.1)) lines(t_seq, lucro_seq, lwd = 3, col = "#198754") abline(v = t, col = "#fd7e14", lty = 2, lwd = 1.5) abline(h = 50, col = "#adb5bd", lty = 3) text(t + 1, max(lucro_seq) * 0.9, paste0("t = ", t), col = "#fd7e14", cex = 0.8, font = 2) legend("topright", legend = c("Receita fiscal", "Lucro", "Repasse = 50%"), col = c("#0d6efd", "#198754", "#adb5bd"), lwd = c(3, 3, 1), lty = c(1, 1, 3), cex = 0.65, bg = "white")
▶ Executar
↻ Resetar
(Aguardando WebR...)