# Probability Calculators Dice, card and lottery odds, multinomials, expected value, exact distribution tables, gambler's ruin, Bayes and streaks. ## How to pay Machine-payable over x402. USDC on: Base (eip155:8453), Solana (solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp), Polygon (eip155:137), Arbitrum One (eip155:42161). No accounts. No API keys. No signup. The paying wallet is the account. ## Machine-readable - OpenAPI: https://probability-calc.x402tookit.com/openapi.json - x402 manifest: https://probability-calc.x402tookit.com/.well-known/x402 - Catalog (free): https://probability-calc.x402tookit.com/catalog - Health (free): https://probability-calc.x402tookit.com/health - Uptime (free): https://probability-calc.x402tookit.com/uptime ## Endpoints (10) ### GET /bayes — $0.02 Bayes' theorem: posterior probability from a prior, sensitivity and false-positive rate, with natural frequencies and odds form. Params: prior: number, sensitivity: number, falsePositiveRate?: number, specificity?: number, population?: integer Example: https://probability-calc.x402tookit.com/bayes?prior=0.01&sensitivity=0.8&falsePositiveRate=0.096 ### GET /birthday-problem — $0.02 Birthday problem: chance two people in a group share a birthday, chance someone shares yours, group size for 50 or 99 percent. Params: people: integer, days?: integer Example: https://probability-calc.x402tookit.com/birthday-problem?people=23 ### GET /card-odds — $0.02 Card odds: 5-card and 7-card poker hand probabilities, chance of hitting your outs by the river, blackjack natural odds. Params: mode: string, outs?: integer, stage?: string, decks?: integer Example: https://probability-calc.x402tookit.com/card-odds?mode=outs&outs=9&stage=flop ### GET /dice-odds — $0.02 Exact odds for dice pools: sum distribution, chance of reaching a target, mean and variance; supports drop-lowest like 4d6. Params: dice: integer, faces: integer, target?: integer, dropLowest?: integer, faceValue?: integer Example: https://probability-calc.x402tookit.com/dice-odds?dice=3&faces=6&target=10 ### GET /distribution-table — $0.02 Exact pmf, cumulative and tail tables for geometric, negative binomial, hypergeometric, binomial and Poisson. Params: dist: string, p?: number, r?: integer, n?: integer, N?: integer, K?: integer, lambda?: number, k?: integer Example: https://probability-calc.x402tookit.com/distribution-table?dist=hypergeometric&N=52&K=13&n=5 ### GET /expected-value — $0.02 Expected value, variance, standard deviation and chance of profit for a list of payoffs with probabilities or weights. Params: outcomes: string, cost?: number, normalize?: string Example: https://probability-calc.x402tookit.com/expected-value?outcomes=35%3A1%2C-1%3A37&normalize=true ### GET /gamblers-ruin — $0.02 Gambler's ruin: probability of going broke before hitting a target, and expected number of bets, for repeated unit bets. Params: p: number, bankroll: integer, target?: integer Example: https://probability-calc.x402tookit.com/gamblers-ruin?p=0.473684&bankroll=100&target=200 ### GET /lottery-odds — $0.02 Lottery odds: jackpot odds and every match tier for pick-k-of-N games with an optional bonus pool (Powerball, EuroMillions). Params: pick: integer, poolSize: integer, bonusPick?: integer, bonusPool?: integer, jackpot?: number, ticketPrice?: number Example: https://probability-calc.x402tookit.com/lottery-odds?pick=5&poolSize=69&bonusPool=26 ### GET /multinomial — $0.02 Multinomial coefficient (arrangements of repeated items like MISSISSIPPI) and multinomial probability for given odds. Params: counts?: string, word?: string, probs?: string Example: https://probability-calc.x402tookit.com/multinomial?word=MISSISSIPPI ### GET /streak-odds — $0.02 Chance of a run: r successes in a row (or r identical outcomes) somewhere in n independent trials, like coin flips. Params: n: integer, r: integer, p?: number, kind?: string Example: https://probability-calc.x402tookit.com/streak-odds?n=100&r=5 ## Terms Exact or closed-form probability maths computed locally, provided as is. Gambling, lottery and card odds describe fair, independent, uniformly random draws and ignore house rules, rake, taxes and prize sharing. Not gambling, investment or medical advice, and no system beats a negative-expectation game. Combinatorics basics (nCr, nPr, derangements) and the binomial, Poisson and normal distribution values live in the math-stats shelf and are not repeated here.