Hi everybody, As most of you know the simulations that I do for the UCN program are done in 3 phases with 3 different programs: MCNPX to go from 800 MeV proton spallation in W to a (cold) neutron energy spectrum in the SD2; NIC to go from the cold flux spectrum to UCN production in the SD2; and, TRANSIT to follow the individual UCN from their birth in the SD2 to their eventual fates within the transport system or the UCNA experiment. Yan-Ping has expressed an interest in getting a copy of NIC and I thought others of you might also be interested so I have put a version of the code on this web page. NIC is an interactive Mathematica notebook that enables you study UCN production in moderators and/or various converters. This particular version has 2 input sections. The first section deals with moderators and will plot and integrate the Maxwell-Boltzman distribution up to a specified Vmax for a specified neutron density in equilibrium with a moderator at a specified temperature. It's a simple learning tool that will tell you more than anything you probably ever wanted to know about the Maxwell Boltzman distribution as a function of energy, velocity or wavelength. I have used it primarily to establish the UCN density in a moderator as a function of Vmax and T and to convert neutron fluxes to densities. The second section calculates UCN production via down-scattering in a solid using single phonon scattering assuming a Debye phonon frequency spectrum and applying the incoherent approximation. The relevant equations are taken from a book by Turchin ("Slow Neutrons", 1965) that is very hard (impossible?) to find but are reproduced in the paper of Yu, Malik and Golub on thin-film sources of UCN. (Zeit fur Physik B, Condensed Matter 62, 137-142, 1986). This paper is also the source of the fact that SD2 can be reasonably characterized as a Debye solid with a Debye temperature of 110 K . Here the incident neutron spectrum can be characterized as a Maxwellian or read in as a text file. I usually take an MCNPX tally (histogram) of E(MeV) at the bottom of a bin and n/cm^2/p within the bin and convert it to E(K) at the center of the bin and n/cm^2/microC/K. If these 2 quantities are then input in columns 1 and 2 (space delimited) of the text file, NIC will calculate the UCN production rate as UCN/cm^3/microC. I have included an example of such a file ("ColdFlux.txt") that corresponds to a production rate of 1068 UCN/cm^3/microC in 5 K SD2. The program was developed with earlier versions of Mathematica but I have been using it with Mathematica 4.2. I hope you will find it useful. At the very least it will provide some guidance to the uninitiated about how to do batch I/O, plot labeling and some other esoteric features of Mathematica that I had to learn by trial and error. Regards, Roger