Gravar-mail: Optimizing detector geometry for trace element mapping by X-ray fluorescence