Formalizing Print Success Rate and Reward

Here's a breakdown of the mathematical formula for calculating the print success rate and reward:

Variables:

  • p: Print completion rate (a decimal between 0 and 1, representing the percentage of successful prints)

  • f: First-attempt success indicator (1 for success, 0 for failure)

  • R_max: Maximum reward as a percentage of order value (e.g., 0.005 for 0.5%)

  • R_min: Minimum reward as a percentage of order value (e.g., 0.002 for 0.2%)

  • p_min: Minimum completion rate threshold for minimum reward (e.g., 0.8)

  • order_value: Value of the order in tokens

Formula

success_rate = f * R_max + (1 - f) * p * R_min * I(p >= p_min)
  • I(p >= p_min) is the indicator function, returning 1 if p >= p_min (eligible for minimum reward) and 0 otherwise.

  1. Reward:

reward = success_rate * order_value

Explanation

  1. The formula captures the key aspects:

  • If successful in first attempt (f=1), get the maximum reward (f * R_max).

  • If not successful in first attempt (f=0):

    • If completion rate >= threshold (p >= p_min), get the minimum reward ((1 - f) * p * R_min).

    • If completion rate < threshold (p < p_min), no reward (I(p >= p_min) = 0).

  1. The reward is then calculated by multiplying the success rate by the order value.

Example

  • p = 0.95 (95% completion rate)

  • f = 1 (successful in first attempt)

  • R_max = 0.005 (maximum reward of 0.5%)

  • R_min = 0.002 (minimum reward of 0.2%)

  • p_min = 0.8 (minimum completion rate for minimum reward)

  • order_value = 100 (order value in tokens)

Calculations

  • success_rate = 1 * 0.005 + (1 - 1) * 0.95 * 0.002 * 1 = 0.005

  • reward = 0.005 * 100 = 0.5 tokens

Output

  • Success rate: 0.005 (or 0.5%)

  • Reward: 0.5 tokens

Last updated