Compute the G value given lamda (the parameter of ellipsoidal function) and beam direction.
Useful links