Respiratory motion causes errors when planning and delivering radiotherapy treatment to lung cancer patients. To reduce these errors, methods of acquiring and using four-dimensional computed tomography (4DCT) datasets have been developed. We have developed a novel method of constructing computational motion models from 4DCT. The motion models attempt to describe an average respiratory cycle, which reduces the effects of variation between different cycles. They require substantially less memory than a 4DCT dataset, are continuous in space and time, and facilitate automatic target propagation and combining of doses over the respiratory cycle. The motion models are constructed from CT data acquired in cine mode while the patient is free breathing (free breathing CT - FBCT). A "slab" of data is acquired at each couch position, with 3-4 contiguous slabs being acquired per patient. For each slab a sequence of 20 or 30 volumes was acquired over 20 seconds. A respiratory signal is simultaneously recorded in order to calculate the position in the respiratory cycle for each FBCT. Additionally, a high quality reference CT volume is acquired at breath hold. The reference volume is nonrigidly registered to each of the FBCT volumes. A motion model is then constructed for each slab by temporally fitting the nonrigid registration results. The value of each of the registration parameters is related to the position in the respiratory cycle by fitting an approximating B spline to the registration results. As an approximating function is used, and the data is acquired over several respiratory cycles, the function should model an average respiratory cycle. This can then be used to calculate the value of each degree of freedom at any desired position in the respiratory cycle. The resulting nonrigid transformation will deform the reference volume to predict the contents of the slab at the desired position in the respiratory cycle. The slab model predictions are then concatenated to produce a combined prediction over the entire region of interest. We have performed a number of experiments to assess the accuracy of the nonrigid registration results and the motion model predictions. The individual slab models were evaluated by expert visual assessment and the tracking of easily identifiable anatomical points. The combined models were evaluated by calculating the discontinuities between the transformations at the slab boundaries. The experiments were performed on five patients with a total of 18 slabs between them. For the point tracking experiments, the mean distance between where a clinician manually identified a point and where the registration results located the point, the target registration error (TRE), was 1.3 mm. The mean distance between a manually identified point and the models prediction of the point's location, the target model error (TME), was 1.6 mm. The mean discontinuity between model predictions at the slab boundaries, the Continuity Error, was 2.2 mm. The results show that the motion models perform with a level of accuracy comparable to the slice thickness of 1.5 mm.