Fit DTM to Object
The basic functions of this command are described in chapter Fit DTM to Object of the manual „Introduction to CadnaA“.
Application
By the command Fit DTM to Object (in the context menu of objects or as an action on the Modify Objects dialog) the entire terrain model will get modified by cutting existing and inserting new terrain contour lines.
When using this command, it is assumed that the current height (height z, i.e. the absolute height) of the object/objects, is correct and relevant to which the terrain model is going to get fit. This implies that the actual terrain model is assumed to be less correct and less relevant than the object height/s.
The decision whether the object heights or the terrain model is/are relevant or not, cannot be decided by the software, it is up to the user.
Example
In this example, the command Fit DTM to Object causes to „clear up“ the road‘s surfaces from overlapping ground. Just from the existing data, however, it is not possible to assess whether the resulting geometry corresponds to reality in this area or not.
![]() |
![]() |
![]() |
![]() |
Consequences
Using this command may cause severe changes to the original terrain model without being able to decide in advance, whether the resulting terrain model is more „real“ than the previous one. Accepting that a measure for the accuracy would be the „real terrain profile“, it would require in any case that a terrain model with a finer resolution would be available for each project in order to examine the deviations. This is, in practice, not possible for time and cost reasons.
It is, therefore, strongly recommended to not use this command routinely, but only in situations where a preliminary study has shown that the resulting heights difference before and after applying the command are deemed acceptable.
Procedure
In the following, a procedure is described to display the height differences on the grid before and after executing the command Fit DTM to Object. The situation as shown in the former example will be used assuming that the two situations are available in separate files:
-
A file with contour lines prior to execution of the command.
-
A file with contour lines after execution of the command.
Proceed as follows:
- First, open the file containing the contour lines before executing the command Fit DTM to Object.
- Now, sort the values in column „Height, top (m)" of the table height line in ascending numerical order to determine the range of values of the altitude.

Sorting the first heights of the contour lines in ascending order
- Check by scrolling in the table for the minimum and maximum height.
- Open the dialog Grid Appearance from the Grid menu and enable the „Level Range“ option.
- Enter a value below the minimum and above the maximum height as established by the scrolling from above (e.g. „70“ and „210“ for 70 m and 210 m).
- Enter a class width of 5 m (meters and not dB in this case).
Thus, the interpolation will be run using these specifications. Make sure prior to the calculation that no grid interpolation is set on the „General“ tab (menu Configuration|Calculation).
- Enter on the Grid|Specification menu a receiver spacing of 5 m by 5 m.
- Now, execute the grid calculation by selecting the command Calc Grid from the Grid menu.
- Toggle via the list box on the symbol bar to the ground grid.

- If necessary, adjust the grid appearance (see Grid Appearance).
- Save the grid via menu File|Save As (e.g. with the filename
grid prior DGMtoObj.cnr). - Save the CadnaA file using a new name.
Afterwards we proceed in the same way with the file the contour lines after execution of the command Fit DTM to Object.
- Save the grid via the menu File|Save As (e.g. with the filename
grid after DGMtoObj.cnr). - Save this CadnaA file under a new name.
Now, the difference grid is generated from the grid files.
- Open the file containing the contour lines after execution of the command Fit DTM to Object, the dialog Grid Arithmetic from the Grid menu.
- Download both grid files and execute operation illustrated below with the ground grids r1g and r2g from.

Generating the difference grid r1g-r2g
- If required, adjust the grid appearance by selecting a suitable color palette for evaluation parameter LP1 (see Grid Appearance).
The following diagram makes use the provided color palette „pal_0_5_step_05".

Grid with height differences (grid spacing 5 m by 5 m)
For the major part of the project area, the absolute height differences between the two terrain models are less than one meter (light green and dark green areas). In the street canyon, in the middle of the project area, however, the absolute height differences are locally more than 5 meters. This is due to the fact that the height profile of the road prior to execution of the command was already below terrain. As a result, the biggest local changes in height occur when fitting the terrain to the road‘s geometry.
Note
When using different grid spacings in the interpolation, different results may occur different.



