The integrand

 

Sub INTG_Integrand()

' This routine is used by INTG to evaluate the path integral
' It specifies the spatial and frequency dependence of the refractive index

  Dim y, x, grad
  Dim rindex, opt_path, temp, factor, n_o
 
  x = INTG.getx      ' set the frequency dependency of the refractive index
  n_o = 10.0 * (1.0 - 0.12 * frequency)
  y = params(0) * x * x * x + params(1) * x * x + params(2) * x + y_shift
  grad = params(0) * x * x * 3.0 + params(1) * x * 2.0 + params(2)
  temp = y * y + (1.25 - x) * (1.25 - x)
  factor = Sqr(temp)
' the spatial depencence of the refractive index
  rindex = n_o * Exp(-factor * atmospheric_factor)
  rindex = rindex + 1.0
  temp = 1.0 + grad * grad
  opt_path = rindex * Sqr(temp)
  value = opt_path
  INTG.getfunval = value
End Sub
Previous slide Next slide