Payouts and Pricing Intuition

Max Payout (bounded structures)

Max Payout = Strike Width × Number of Contracts

Strike Width by Type

  • Spreads (2 strikes):

    const [k1, k2] = order.strikes.map(s => s / 1e8);
    const width = Math.abs(k2 - k1);
  • Butterflies (3 strikes):

    const [lo, mid, hi] = order.strikes.map(s => s / 1e8);
    const width = mid - lo; // symmetric
  • Condors (4 strikes):

    const k = order.strikes.map(s => s / 1e8);
    const width = k[1] - k[0]; // simplified

Payout at Settlement (simplified, untested)

function payoutAtPrice(order, numContracts, S) {
  const K = order.strikes.map(s => s / 1e8);
  const isCall = order.isCall;

  if (K.length === 2) { // spreads
    const [L, U] = K;
    if (isCall) {
      if (S <= L) return 0;
      if (S >= U) return (U - L) * numContracts;
      return (S - L) * numContracts;
    } else {
      if (S >= U) return 0;
      if (S <= L) return (U - L) * numContracts;
      return (U - S) * numContracts;
    }
  }

  if (K.length === 3) { // butterflies
    const [L, M, U] = K; const w = M - L;
    if (S <= L || S >= U) return 0;
    if (S === M) return w * numContracts;
    return (S < M)
      ? ((S - L) / w) * w * numContracts
      : ((U - S) / w) * w * numContracts;
  }

  if (K.length === 4) { // condors
    const [K1, K2, K3, K4] = K;
    const max = (K2 - K1) * numContracts; // simplified
    if (S <= K1 || S >= K4) return 0;
    if (S >= K2 && S <= K3) return max;
    if (S < K2) return ((S - K1) / (K2 - K1)) * max;
    return ((K4 - S) / (K4 - K3)) * max;
  }

  return 0;
}

Last updated