Universidade Federal da Paraíba

Curso de Graduação em Economia

Análise Microeconômica I

options(OutDec=",")

# Criar sequências de 50 números ordenados entre 1 e 25 - horas trabalhadas
x <- seq(1,25,length=50)

# Definir função de produção CD beta = 1/2
y <- function(L) {L^0.5}

# Definir função de produção marginal
pmg <- function(L) {0.5*L^-0.5}

# Definir função de produção média
pme <- function(L) {L^-0.5}

par(oma=c(0,1.8,0,0.8))
plot(x,pmg(x),type="o",bty="l",cex.lab=0.8,cex.axis=0.8,col="brown",lwd=2,las=1,
     ylab=expression(f(L)),xlab=expression(L))
grid(col=grey(0.80))
points(x,pme(x),type="o",col="blue")
par(fig=c(0, 1, 0, 1), oma=c(0, 0, 0, 0),mar=c(0, 0, 0, 0), new=TRUE)
plot(0,axes=F,xlab="",ylab="",col="transparent")
legend("topright",c(expression(PMgL(L) == 0.5*L^-0.5),expression(PMeL(K,L) == L^-0.5)),
       bty="n", pch =c(1,1),col=c("brown","blue"),cex=0.9)

# resultados da simulação:
data.frame(L=round(x,1),Y=round(y(x),1),PMgL=round(pmg(x),1),PMeL=round(pme(x),1))
##       L   Y PMgL PMeL
## 1   1,0 1,0  0,5  1,0
## 2   1,5 1,2  0,4  0,8
## 3   2,0 1,4  0,4  0,7
## 4   2,5 1,6  0,3  0,6
## 5   3,0 1,7  0,3  0,6
## 6   3,4 1,9  0,3  0,5
## 7   3,9 2,0  0,3  0,5
## 8   4,4 2,1  0,2  0,5
## 9   4,9 2,2  0,2  0,5
## 10  5,4 2,3  0,2  0,4
## 11  5,9 2,4  0,2  0,4
## 12  6,4 2,5  0,2  0,4
## 13  6,9 2,6  0,2  0,4
## 14  7,4 2,7  0,2  0,4
## 15  7,9 2,8  0,2  0,4
## 16  8,3 2,9  0,2  0,3
## 17  8,8 3,0  0,2  0,3
## 18  9,3 3,1  0,2  0,3
## 19  9,8 3,1  0,2  0,3
## 20 10,3 3,2  0,2  0,3
## 21 10,8 3,3  0,2  0,3
## 22 11,3 3,4  0,1  0,3
## 23 11,8 3,4  0,1  0,3
## 24 12,3 3,5  0,1  0,3
## 25 12,8 3,6  0,1  0,3
## 26 13,2 3,6  0,1  0,3
## 27 13,7 3,7  0,1  0,3
## 28 14,2 3,8  0,1  0,3
## 29 14,7 3,8  0,1  0,3
## 30 15,2 3,9  0,1  0,3
## 31 15,7 4,0  0,1  0,3
## 32 16,2 4,0  0,1  0,2
## 33 16,7 4,1  0,1  0,2
## 34 17,2 4,1  0,1  0,2
## 35 17,7 4,2  0,1  0,2
## 36 18,1 4,3  0,1  0,2
## 37 18,6 4,3  0,1  0,2
## 38 19,1 4,4  0,1  0,2
## 39 19,6 4,4  0,1  0,2
## 40 20,1 4,5  0,1  0,2
## 41 20,6 4,5  0,1  0,2
## 42 21,1 4,6  0,1  0,2
## 43 21,6 4,6  0,1  0,2
## 44 22,1 4,7  0,1  0,2
## 45 22,6 4,7  0,1  0,2
## 46 23,0 4,8  0,1  0,2
## 47 23,5 4,9  0,1  0,2
## 48 24,0 4,9  0,1  0,2
## 49 24,5 5,0  0,1  0,2
## 50 25,0 5,0  0,1  0,2