Skip to main content

Combine

The Combine tool performs arithmetic operations between two volume images, creating a result that represents the mathematical combination of the inputs. This is useful for image comparison, fusion, and analysis.

Accessing the Tool

  1. Navigate to the Image tab in the ribbon.
  2. Click Combine in the Operations section.

Parameters

Operation

Select the mathematical operation to perform:

OperationFormulaDescription
AddA + BSum of intensity values
SubtractA − BDifference between volumes
MultiplyA × BProduct of intensity values
DivideA ÷ BRatio of intensity values
Mean(A + B) / 2Average of intensity values
Minimummin(A, B)Lower value at each voxel
Maximummax(A, B)Higher value at each voxel

Input Volumes

ParameterDescription
Input 1First operand volume
Input 2Second operand volume
ResultTarget for the output (existing volume or new object)

Output Options

OptionDescription
Create new objectGenerate a new volume with the result
Overwrite targetStore result in an existing volume

Operation Details

Add

Combines intensities additively:

Result(x,y,z)=Volume1(x,y,z)+Volume2(x,y,z)\text{Result}(x,y,z) = \text{Volume}_1(x,y,z) + \text{Volume}_2(x,y,z)

Use case: Fusing complementary datasets, combining signal from multiple acquisitions.

Subtract

Calculates the difference between volumes:

Result(x,y,z)=Volume1(x,y,z)Volume2(x,y,z)\text{Result}(x,y,z) = \text{Volume}_1(x,y,z) - \text{Volume}_2(x,y,z)

Use case: Detecting changes between timepoints, removing background.

Multiply

Multiplies corresponding voxel values:

Result(x,y,z)=Volume1(x,y,z)×Volume2(x,y,z)\text{Result}(x,y,z) = \text{Volume}_1(x,y,z) \times \text{Volume}_2(x,y,z)

Use case: Applying masks or weight maps, combining probability maps.

Divide

Computes the ratio of voxel values:

Result(x,y,z)=Volume1(x,y,z)Volume2(x,y,z)\text{Result}(x,y,z) = \frac{\text{Volume}_1(x,y,z)}{\text{Volume}_2(x,y,z)}

Use case: Normalization, ratio imaging.

warning

Division by zero produces undefined results. Ensure Input 2 does not contain zero values, or handle zeros appropriately.

Mean

Averages the two volumes:

Result(x,y,z)=Volume1(x,y,z)+Volume2(x,y,z)2\text{Result}(x,y,z) = \frac{\text{Volume}_1(x,y,z) + \text{Volume}_2(x,y,z)}{2}

Use case: Noise reduction by averaging multiple acquisitions.

Minimum

Takes the lower value at each position:

Result(x,y,z)=min(Volume1(x,y,z),Volume2(x,y,z))\text{Result}(x,y,z) = \min(\text{Volume}_1(x,y,z), \text{Volume}_2(x,y,z))

Use case: Finding common low-intensity regions.

Maximum

Takes the higher value at each position:

Result(x,y,z)=max(Volume1(x,y,z),Volume2(x,y,z))\text{Result}(x,y,z) = \max(\text{Volume}_1(x,y,z), \text{Volume}_2(x,y,z))

Use case: Maximum intensity projection from multiple angles, combining highlights.


Workflow

  1. Open the Combine tool from the Image tab.
  2. Select the desired Operation.
  3. Choose Input 1 and Input 2 volumes.
  4. Select or name the Result volume.
  5. Click Apply to perform the operation.

Requirements

  • Both input volumes must have the same dimensions (voxel count in X, Y, Z).
  • Volumes should be spatially aligned for meaningful results.
  • If dimensions differ, resample one volume to match the other first.
info

The Combine operation works on the voxel grid. Volumes with different spacing but the same dimensions will combine based on voxel index, not physical position.

Use Cases

Change Detection

Compare scans from different timepoints:

  1. Register the follow-up scan to the baseline.
  2. Use Subtract to create a difference image.
  3. Positive values indicate increased intensity; negative indicate decreased.

Multi-Modal Fusion

Combine information from different imaging modalities:

  1. Register CT and MRI datasets.
  2. Use Add with appropriate scaling or Maximum to combine.
  3. Results show features from both modalities.

Background Removal

Remove a known background pattern:

  1. Acquire or calculate the background volume.
  2. Use Subtract to remove background from the signal.

Probability Map Combination

Combine multiple segmentation probability maps:

  1. Use Mean for equal weighting.
  2. Use Maximum to take the highest confidence.
  3. Use Multiply for intersection (AND-like behavior).

Scripting

The combine operation is available via the Python scripting API.

import ScriptingApi as api

app = api.Application()
volume_operations = app.get_volume_operations()

# Add two volumes, create new object
result_name = volume_operations.combine(
"Volume1", # Input 1
"Volume2", # Input 2
"CombinedResult", # Result name
api.CombineOperation.Addition, # operation: Addition, Subtraction, Multiplication, Division, Mean, Minimum, Maximum
True # create_new_object
)

See the VolumeOperations API Reference for details.