# dfg is distance from goal (State - Goal)

# here, delta is 1 indicating strong sensitivity to distance from goal
strong.fun <- function(dfg) {return(
  
  1 / (1 + exp(-dfg * 1))
  
)}


# here, delta is .01, indicating low sensitivity to distance from goal
weak.fun <- function(dfg) {return(
  
  1 / (1 + exp(-dfg * .01))
  
)}


plot(1, xlim = c(-100, 100), ylim = c(0, 1), type = "n")
abline(h = .5, lty = 2)

curve(expr = strong.fun, add = TRUE, col = "red")

text(5, .9, "Delta = 1 (Strong Sensitivity)", pos = 4)

curve(expr = weak.fun, add = TRUE, col = "blue")
text(-100, .2, "Delta = .01 (Weak Sensitivity)", adj = 0)