Well log calculator
The Well Log Calculator in g-Space is a tool that allows users to generate custom well log curves through mathematical expressions applied to existing well data. It is accessible from the Calculators Bar by clicking on the Well Log Calculator button, which opens a user-friendly wizard interface for quick and efficient log creation.

The wizard consists of two main tabs: General and Preview.
In the General tab, users can define the core parameters for the calculation process. It contains the following key components:
- Output Log: Users can either select an existing well log curve from the dropdown menu or create a new curve by naming it. This output will store the results of the calculation.
- Expression: This is the central area for performing operations. Users must input an arithmetic expression using the available well log curves (e.g., porosity, density) and mathematical operators. Expressions can be as simple or complex as needed, enabling flexibility in creating derived curves. Refer to the Trace Headers Math for a description of the available mathematical functions.
- History: g-Space automatically saves previous expressions, making it easier for users to reapply calculations they have used in the past without having to rewrite them.

The Preview tab provides a real-time visualization of the data before finalizing the calculation. It consists of two columns:
- Depth: Displays the depth intervals for the well data in ascending or descending order.
- Values: Shows the resulting values based on the arithmetic expression entered in the General tab. This preview ensures that users can verify the output and confirm the expression before applying it to the entire dataset.

After completing the calculation, the newly generated curve is automatically saved in the Las folder within the Data Manager for each well in the project.
The curve will be calculated for the Current well on the Location map.

Running the calculator from the Petrophysics ribbon
The Log calculator is also available from the Petrophysics ribbon tab, in the Execute group. Opened this way it provides an expanded calculator interface with a built-in keypad, function buttons, a well selector and an expression history. In this interface the output curve name and the expression are typed together in the Expression field using the form name = expression (for example, NPHI_calc = ...). The part before the equals sign becomes the name of the new curve.
The main controls are:
- Curves and Paste — select an available curve (or MD for measured depth) and click Paste to insert its name into the expression. Use U for the undefined value.
- Algebra, Logic and Trig tabs and the keypad — insert mathematical functions, operators and digits into the expression.
- Angle mode (Rad, Deg, Grad) — sets how trigonometric functions interpret angle values.
- Step MD — the sampling interval, in depth, used to resample the input curves and store the result.
Click ENTER (or Apply) to run the calculation. The dialog stays open so you can create several curves in one session; close it with Cancel. Each calculated curve is added to the well's LAS data in the Data Manager; if a curve with the same name already exists you are asked whether to replace it.
Calculating for several wells
The well selector row at the top of the dialog controls which wells the expression is applied to:
- Well — choose a single well. By default the calculation is applied to this well only.
- Batch calculation — turn on this check box (off by default) to run the calculation on a group of wells instead of a single well. The single-well list is then disabled and the scope drop-down beside it becomes active.
- Scope drop-down — choose All wells to process every well in the project, or select a well filter, a Data Manager well folder, or a well section to limit the calculation to that group.
When the run finishes, g-Space reports how many wells were processed and lists any wells that were skipped, for example because an input curve was missing, the expression produced no defined values, or the output curve already existed and was not overwritten.
Expression history
The Expression field is a drop-down that remembers the last five expressions you applied, so you can reapply a previous calculation without retyping it. The most recent expression appears at the top of the list, and duplicate entries are not repeated — select an entry to reuse it.
The history is stored separately for each project, and each calculator keeps its own list, so the Log calculator, Map calculator, Seismic calculator and Marker attributes calculator do not share expressions.