simplex_step

std.optim.simplex_step · Level L4

One pivot of the fraction-free simplex method on an integer tableau, by Bland's rule: the entering column is the first with a negative reduced cost; the leaving row has the smallest ratio rhs/column over positive entries, compared by cross-multiplication, ties to the smallest basic variable. Every row but the pivot row becomes (p·row − T[i, k]·row r)/D, an exact integer division, and D becomes the pivot p. With no entering column the status becomes 1 (optimal); with no leaving row, 0 (unbounded). The body simplex_max runs.

Tᵢ ← (p·Tᵢ − Tᵢₖ·Tᵣ)/D (i ≠ r), D ← p

Signature

simplex_step(T: i64[m+1, n+m+1], basis: i64[m], D: i64[], status: i64[]) → i64[m+1, n+m+1], i64[m], i64[], i64[]

Structure

The function as NOVA stores it: one box per input, operation and output, and arrows that carry values. A double border marks another library function this one runs — called once, or by Scan once per element; select it to open that function.

statusi64[]basisi64[m]Di64[]Ti64[m+1, n+m+1]SliceobjrIotaiiReshapebas_cReshapebas_rSlicerowsIotatiReshapeobjReshapeii_cReshapeii_rEqualbsameLessblSlicerhsc0SlicecostEqualsameLessearlier1.0ReshaperhsLessnegSubtractotherReshaperhs_cReshaperhs_rReduceMaxhas_kArgMaxkCastkiGathercolkGathercolfGreaterposReshapecol_rReshapecol_cReshapecolf_c2ReduceMaxhas_rReshapepos_cMultiplyLMultiplyRm1WhereunbMultiplygoEqualeqLesslessWherestatus2Multiplytie2aMultiplytieMultiplytie2Addbeats1AddbeatsSubtractlose_mMultiplylose_oMatMullost_cReshapelost0.0EqualunbeatenMultiplywinArgMaxrEqualat_rEqualis_rCastrrWherenbGatherpGatherrowrWherebasis2WhereD2MultiplypTReshaperowr_rMultiplyouterSubtractnumFloorDivfullWherepivotedWhereT2status2i64[]basis2i64[m]D2i64[]T2i64[m+1, n+m+1]
  • input
  • operation
  • constant
  • call
  • output

Verification

  • Signature proven by NOVA’s shape solver, for every size.
  • Equal to the reference Bland's entering column and leaving row; (p·row − T[i, k]·row r) // D in exact rational arithmetic, on all 40 test cases.
  • All 1,196 int64 results are exact: the error is zero.
  • Interpreter and NumPy backend return bit-identical results.
  • At float32 too: the 40 test cases rounded to float32, and 40 of them exact, with zero error.
Accuracy in detail
correctly rounded (the int64 nearest the exact value)
100%
bit-equal to the NumPy formula in int64
100%
largest error, in units in the last place
0

Identity

Calls
—
Called by
sha256:cfc09f3e102967cbf330d2511a0790df39a39edb3dde43691b5bc3f6b19e1fc0

The semantic hash of the graph. It changes when the program changes, and never when only its documentation does.

Control handle

Symbol
Ω:std.optim.simplex_step · Ω:simplex_step
Pins
sha256:6cd233d9a9df664dc367aaac612069144007c796d4a407bb9d0d84e2c270ffebthis graph alone
Evidence
sha256:5bcca69136af887d3dfe52542fd1fc389580fade8e7ab2089a3763b0579c9c00the hash of its verification record
Needs
no capability: a pure function

Through NOVA’s control layer, the symbol launches this function only while the program still matches what it pins: a change to this graph, or to any graph it reaches, needs a migration first.

ΣEML 2026

Efficient New Language — a high-density semantic overlay for humans and AI agents.

This site’s demos run on the real EML toolchain, in your browser.

© 2026 EveMissLab (一言諾科技有限公司) / Neo.K. All rights reserved.