composition
Pydantic models for system composition (mixedbox, bilayer, LNP).
funcdistribute_counts(fractions, total) → list[int]Distribute total into integer counts preserving the sum exactly.
Uses floor + largest fractional part method to ensure the sum of returned counts equals total exactly, while respecting proportions.
paramfractionslist[float]Fractions for each species (must sum to 1.0).
paramtotalintTotal count to distribute.
Returns
listInteger counts that sum to exactly total.
