Dust emission and absorption change only slowly as a function of frequency. Small frequency shifts caused by Doppler effect are unimportant so that the velocity field in the cloud does not affect continuum calculations. On the other hand, in addition to absorption we must consider how photons are scattered from dust grains. Size and material of grains determine how large fraction of incoming radiation is scattered and in what directions. Scattering depends on the frequency of the radiation. This means that each frequency included in the calculations must be simulated separately.
Calculations start with a simulation of the radiation field. This usually means radiation coming from outside the cloud (general interstellar radiation field) or from internal sources. Only in very dense clouds does emission from dust grains inside the cloud become important. In Monte Carlo simulation we start a photon package from a random location towards a random direction. We follow the path of the package as it moves and occationally scatters towards a new direction. At the same time we remove from the package photons that are absorbed along the path. Absorbed photons are counted separately for each cell in the model cloud. The simulation is repeated many times and for many frequencies so that we get an accurate picture of the radiation field.
In the second phase we compute grain temperatures. These are obtained by balancing the heating caused by absorbed photons and the cooling that results from radiation emitted by dust grains. Temperature of small grains fluctuates as they absorb individual photons and we need to calculate their temperature distributions. Once we know how many grains there are at each temperature we know how they radiate. When we sum emission along a line-of-sight and repeat this at many frequencies we get a full spectrum that can again be compared with observations.
I have written a computer program that is used to compute dust emission from three-dimensional cloud models. The cloud is again divided into cubic cells. The simulation of radiation field (although it often is a rather lengthy process) can be done for fairly large models. The problem is the time that is needed to solve the temperature distributions of small grains. This may take less than one second for one cell. However, a three-dimensional model may easily contain more than 128x128x128 cells - and calculation would take already more than ~600 hours!
The time consuming part is actually a part of a process where we deduce from local radiation field the resulting dust emission. In a three-dimensional cloud there must be many very similar cells so that it should not be necessary to solve this for each individual cell. In my program the idea is to first establish a mapping between properties of incoming radiation and the resulting dust emission. Different cases are characterized based on the intensity of radiation field at a few reference frequencies. Dust emission is calculated for these representative cases. Once the mapping exists one can take any cell, look at the intensities at reference wavelengths and simply read from a table what the corresponding emission should be. Another benefit is that radiation field need to be simulated only at those few reference wavelengths.
Below is an example of dust emission calculations.
In the previous example dust emission was calculated towards one fixed direction. Once the dust temperatures are known one can, however, very easily calculate the resulting dust emission in any direction. Below is an animation which shows 12Ám infrared emission for one model. As the cloud rotates one can see how projection effects create 'clumps' in the infrared map. These can arise when line-of-sight crosses several filaments or when we happen to look along some elongated density structures.