x ray attenuation calc free loop