% Function computes the conditional expectation of 'a'

function f = afa4(a)
global sd
f = a.*exp((-1)*a/sd)./(sd*(1+exp((-1)*a/sd)).^2.);
