Bipolar charging of nanometer-sized aerosol particles in a tube containing a radioactive source has been investigated theoretically. A model has been developed which accounts for diffusion losses of particles and ions to the tube wall, as well as for the spatial dependency of the ion-pair generation rate. The ion generation rate profile along the tube axial direction as a function of the source size and of the tube length and radius has been evaluated and, subsequently, used to examine the aerosol charging process. Comparative calculations were also performed for uniform ion generation and negligible diffusion losses. In a real charger, where diffusion losses are unavoidable, particles cannot attain a steady charge distribution. On the contrary, provided the nt product (ion mean concentration × mean aerosol residence time) is large enough, the number concentration of charged particles of a given size reaches a maximum at a certain axial location and thereafter decreases. The extrinsic charging efficiency (fraction of originally neutral particles which carry a net charge at the ionizer outlet) depends in a complex manner on a number of parameters: particle size and polarity, tube length and radius, nt product, and relative aerosol-to-ion concentration.