You'll find these advanced functions listed on the right side panel of the Calculator's formula builder. A short description is displayed as well when hovering above an operator on the side panel.
Returns the largest of all input numbers
Returns the smallest of all input numbers
Rounds input numbers to decimal places
Power of / exponent function
Returns a random number from a specified range
Returns the next lowest integer value by rounding down
Returns the next highest integer value by rounding up
Square root (√) of a number
Base 2 logarithm of a number
Base 10 logarithm of a number
Natural logarithm of a number
Function to check how many files were uploaded. Can only be used with File Upload elements.
Function to calculate how many days are in the range of two dates (including both dates). Can only be used with Date & Time elements.
Conditional logic operators:
IF(condition, then case, else case)
The conditions below can only be used inside the first parameter of an IF function:
Is true if Q1 is greater than one
Is true if Q1 is smaller than on
Equals or greater than
Is true if Q1 is greater than one or equals one
Equals or smaller than
Is true if Q1 is smaller than one or equals one
Is different than / is not (negation)
Is true if Q1 is not 5
Is true if Q1 is 5
Logical operator that combines two conditions. Is true if both conditions are true
Is true of Q1 is greater than 1 and Q1 is smaller than 10
Logical operator that combines two conditions. Is true when one of two conditions is true
Is true of Q1 is smaller than 5 or Q1 is greater than 10
Function to check if the question was answered
Is true if Q1 was answered
Function to check if the negation of a value is true
Is true if Q1 is false
Function to assert if an Opt-in Checkbox element was CHECKED, meaning the checkbox was ticked.
Is true if Q1 was ticked (and Q1 is an Opt-in checkbox element).
Function to check if a Free Text Input element contains text (in full or partially).
Is true if Q1 contains the text "needle" (and Q1 is a Free Text Input element which collects text input).
Can be nested to be negated: NOT(CONTAINS(Q1,"needle"))
Function to check if a Date&Time element was answered with a value before a given date/time.
Is true if Q1 was answered with a date earlier than "2023-01-01" (and Q1 is a Date&Time element.
Function to check if a Date&Time element was answered with a value after a given date/time.
Is true if Q1 was answered with a date later than "2023-01-01" (and Q1 is a Date&Time element.
Function to check if a Date&Time element was answered with a value in the past (at the time of evaluation).
Is true if Q1 was answered with a date earlier than now (and Q1 is a Date&Time element).
Function to check if a Date&Time element was answered with a value in the future (at the time of evaluation).
Is true if Q1 was answered with a date later than now (and Q1 is a Date&Time element).
Function returns current Date&Time.
BEFORE(Q1,NOW()) is true if Q1 is a date earlier dan the current date.
These advanced functions will allow you to build more customized calculations. You'll find some example formulas for different use cases below:
Quantity dependent shipping price calculator
Calculator formula: =IF(Q2>5,Q1*Q2+10,IF(Q2>3,Q1*Q2+5,Q1*Q2+2))
Where Q1 is the price of the selected item, and Q2 is the quantity of the items ordered.
In the example above, two nested IF functions are used to check for the quantity ordered.
The leftmost IF function checks if there are more than 5 items in the order. If true, $10 will be charged for shipping, which is added to the ordered products' price. If the condition isn't true (less than 6 items ordered), the nested IF function checks if the amount of items is more than 3, in which case $5 will be charged for shipping. If the nested IF function's condition isn't true, the else case will be calculated, which charges $2 for shipping.
Coupon code checker
Calculator formula: IF(CONTAINS(Q2,'COUPONCODE'),Q1*0.8,Q1)
Where Q1 is the price of the selected product, and Q2 is the coupon code entered by the participant.
In the example above, the CONTAINS function checks if Q2 includes the predefined text, which is COUPONCODE in this case. If a match is found, the formula applies a 20% discount to the chosen product's value (achieved by the multiplication with 0.8).
If no match is found, the calculator's output will be the full value of the chosen product (Q1).
You'll find more use case examples in our blog post.