BigShort Docs

Precision and Mathematical Conventions

Consistent Token, native18, external6, bps, and fixed-point conventions distinguish continuous models from contract integer execution.

Distinguish Amounts from Raw Integers First

Contracts do not store floating-point USDC or Token amounts. Human-readable examples in this manual use expressions such as 1,000 USDC; formulas labeled integer implementation use raw on-chain integers.

NotationUnit in integer formulasExample
T, a, bToken181 Token = 10¹⁸
Q, N, C, Anative18 USDC1 USDC = 10¹⁸
E, Rexternal6 USDC1 USDC = 10⁶
σPrecision conversion factor 10¹²Not a currency exchange rate
BPSRatio denominator 10,000100 bps = 1%
PPMRatio denominator 1,000,00010 ppm = 0.001%

In the source, ether is Solidity's numeric suffix for 10¹⁸ ; it does not mean that this protocol uses ETH as its quote asset. The current adaptation treats native Arc USDC and the ERC-20 USDC interface with 18/6 decimals; this property cannot be generalized directly to every EVM network.

Converting between USDC Precisions

From external6 to native18:

Q=Eσ,σ=1012

Rounding down from native18:

E=⌊Qσ⌋,ε=Qmodσ

ε is native18 dust. Exact conversion requires:

Qmodσ=0

For example, rounding down 1.234567890123456789 USDC yields 1.234567 USDC, with a remainder of 0.000000890123456789 USDC. An exact-conversion path rejects this input instead of silently rounding it.

Rounding Notation

SymbolMeaningCommon uses
floor(x) / ⌊x⌋Round downRatio progress, partial allocation, index accumulation
sqrtFloor(x)Integer square root rounded downTheoretical reserves in the risk model
sqrtCeil(x)Integer square root rounded upConservative remaining reserves in risk capacity
feeUp(A,f)=⌈Af10,000⌉

Standard V2 exact-output input calculation uses floor(ratio) + 1. It adds 1 even when ratio is already an integer, so it cannot always be replaced by ceil(ratio). The Quoter's maximum executable capacity also preserves a strict boundary for this reason.

Operations Whose Order Cannot Be Exchanged

In general:

⌊ab⌋c≠⌊acb⌋

Fixed-Point Indices

TWAP cumulative prices use 2¹¹² scaling; Funding and Legacy use 2¹²⁸ . Taking Funding as an example:

ΔI=⌊rΔt2128106⋅86,400⌋,F=⌊NΔI2128⌋

The index separates the globally accumulated rate from individual position shares, avoiding a storage write for every position every second. Two downward rounding steps may produce tiny differences from floating-point approximations; Legacy separately retains a high-precision remainder as well.

Fixed Supply Basis for Market Cap

The protocol's internal market cap is based on Curve supply S = 1,000,000,000 Token:

M=⌊QST⌋

It is neither FDV calculated using the total supply of 1,199,861,071 Token nor a circulating-supply measure. Public displays should distinguish raw spot market cap from clamped risk market cap and avoid substituting one metric for another.

BigShort Protocol · ARCIssue · Trade · Short