Analytical modeling of thin film neutron converters and its application to thermal neutron gas detectors