Open topic with navigation

You are here: Define Geology > About > Models > User Calculations
GEOVIA MineSched

|  | Print

# User Calculations

You create user calculations to define your own mathematical expressions to target and report on.

User calculations allow you to perform:

- ratio calculations

  The ratio between two qualities cannot be calculated in the block model and carried through the schedule. If you try to calculate ratios between qualities in the block model and carry them through to the schedule, the results are mathematically incorrect. You must define ratios with a user calculation.

  For example, consider a scenario which contains two blocks of equal size, where Quality A has a value of 1 for both blocks and Quality B has a value of 1 for the first block and 2 for the second block. If the ratio of A/B is calculated in the block model, the two blocks will have ratio values of 1 and 0.5. Reporting the average ratio value of all blocks mined will give 0.75, which is incorrect. The correct result is 0.667, which is calculated by dividing the average of A (1.0) by the average of B (1.5) for the two blocks. You can correctly calculate and report this ratio using a user calculation.

- total product calculations

  You can include volume and mass in user calculations. When you multiply volume or mass by qualities and recovery factors, you create total product calculations.

- calculations incorporating user parameters

  You can include any User parameter you have defined in a user calculation. The ability to include user parameters into user calculations extends the power of user calculations because they can contain values which vary by location and which change over time.

  For example, you can include unit mining cost into a user calculation by first creating a user parameter. Unit mining cost (that is, mining cost per tonne) often varies by location or depth because of a variety of factors. Unit mining cost is also likely to increase over time. You can model the unit mining cost as a user parameter and then include it in user calculations.

- time-dependent calculations

  You can include a number of time-based codes in user calculations. Using time-based codes allows you to perform time discounted calculations.

  For example, you use time-based codes to calculate Net Present Value (NPV).

### Columns in the User Calculations Data Grid

Column | Description
--- | ---
Active | Selected: The calculation is performed. Cleared: The calculation is not performed. Tip: When you clear the Active check box, you make the user calculation ineffective without deleting the equation.
Name | The name of the calculation. Note: The name is case-sensitive and cannot contain spaces.
Expression | The mathematical formula for the calculation. When you click this field, you see a list of items for Standard codes, Qualities, User parameters, and Common operations that you can use to create the expression. Standard codes: Codes for parameters of the scenario. Standard codes available are: LENGTH: The length. MASS: The mass. PERIOD_DAYS: The total number of days in the current period. PERIOD_NUM: The period number. Period numbers are integers starting at 1. PERIOD_WORK_DAYS: The number of working days in the current period taking into account the resource working and holiday calendars. SCHEDULE_DAYS: The total number of days from the start of the schedule. VOLUME: The volume. Qualities: The qualities you defined in the Qualities data grid. User parameters: The parameters you defined in the User parameters data grid. Common operations: Common mathematical operators you can include in the expression. Operations available are: + : Addition. - : Subtraction. / : Division. * : Multiplication. ( : Used to group parts of the expression, to ensure the calculations in the expression are performed in the correct order. ) : Used to group parts of the expression, to ensure the calculations in the expression are performed in the correct order. User calculations: If you have already defined other user calculations, the names of the calculations are displayed in the list. You can create an expression using only the options available in the lists, by keyboard entry, or using a combination of the options in the lists and keyboard entry. Mathematical operations you can include in an expression using keyboard entry are defined and described in the following table.
Expression | Description | Example | Example Result
--- | --- | --- | ---
ABS | The absolute value of any real number | ABS(-121) | 121
CEIL | Round a real number up to the nearest integer | CEIL(3.2) | 4
FLOOR | Round a real number down to the nearest integer | FLOOR(61.8) | 61
NINT | Round a real number to the nearest integer | NINT(8.547) | 9
INT | Return the integer part of a real number | INT(8.547) | 8
FRAC | Return the fractional part of a real number | INT(8.547) | 0.547
LOG | Return the natural log of any real number | LOG(177147) | 12.08
LOG10 | Return the log with base 10 of any real number | LOG10(100) | 2
EXP | Return the value of e (Euler's number) to the power of any real number | EXP(3) | 20.09
SQRT | Return the square root of any real number greater than zero | SQRT(25) | 5
POW | Return the value of one number to the power of another number | POW(5,3) | 125
IIF | Return the value based on a conditional statement | IIF(3>2,100,0) | 100
Comments | Any notes you want to make about the user calculation.

### See also

- Define User Calculations
- Qualities Data Grid
- User Parameters Data Grid

Open topic with navigation