</head><bodyclass="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><navclass="mobile-topbar"><buttonclass="sidebar-menu-toggle">☰</button><aclass="sidebar-logo"href="../../../halo2_gadgets/index.html"><divclass="logo-container"><imgclass="rust-logo"src="../../../rust-logo.svg"alt="logo"></div>
</a><h2class="location"><ahref="#">Module chip</a></h2><divclass="sidebar-elems"><section><divclass="block"><ul><li><ahref="#modules">Modules</a></li><li><ahref="#structs">Structs</a></li><li><ahref="#enums">Enums</a></li><li><ahref="#traits">Traits</a></li></ul></div></section></div></nav><main><divclass="width-limiter"><divclass="sub-container"><aclass="sub-logo-container"href="../../../halo2_gadgets/index.html"><imgclass="rust-logo"src="../../../rust-logo.svg"alt="logo"></a><navclass="sub"><formclass="search-form"><divclass="search-container"><span></span><inputclass="search-input"name="search"autocomplete="off"spellcheck="false"placeholder="Click or press ‘S’ to search, ‘?’ for more options…"type="search"><divid="help-button"title="help"tabindex="-1"><buttontype="button">?</button></div><divid="settings-menu"tabindex="-1">
<h1class="fqn"><spanclass="in-band">Module <ahref="../../index.html">halo2_gadgets</a>::<wbr><ahref="../index.html">ecc</a>::<wbr><aclass="mod"href="#">chip</a><buttonid="copy-path"onclick="copy_path(this)"title="Copy item path to clipboard"><imgsrc="../../../clipboard.svg"width="19"height="18"alt="Copy item path"></button></span></h1><spanclass="out-of-band"><aclass="srclink"href="../../../src/halo2_gadgets/ecc/chip.rs.html#1-614">source</a> · <aid="toggle-all-docs"href="javascript:void(0)"title="collapse all docs">[<spanclass="inner">−</span>]</a></span></div><detailsclass="rustdoc-toggle top-doc"open><summaryclass="hideme"><span>Expand description</span></summary><divclass="docblock"><p>Chip implementations for the ECC gadgets.</p>
<divclass="item-table"><divclass="item-row"><divclass="item-left import-item"><code>pub use <aclass="mod"href="constants/index.html"title="mod halo2_gadgets::ecc::chip::constants">constants</a>::*;</code></div><divclass="item-right docblock-short"></div></div></div><h2id="modules"class="small-section-header"><ahref="#modules">Modules</a></h2>
<divclass="item-table"><divclass="item-row"><divclass="item-left module-item"><aclass="mod"href="constants/index.html"title="halo2_gadgets::ecc::chip::constants mod">constants</a></div><divclass="item-right docblock-short"><p>Constants required for the ECC chip.</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="struct"href="struct.EccPoint.html"title="halo2_gadgets::ecc::chip::EccPoint struct">EccPoint</a></div><divclass="item-right docblock-short"><p>A curve point represented in affine (x, y) coordinates, or the
identity represented as (0, 0).
Each coordinate is assigned to a cell.</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="struct"href="struct.EccScalarFixed.html"title="halo2_gadgets::ecc::chip::EccScalarFixed struct">EccScalarFixed</a></div><divclass="item-right docblock-short"><p>A full-width scalar used for fixed-base scalar multiplication.
This is decomposed into 85 3-bit windows in little-endian order,
i.e. <code>windows</code> = [k_0, k_1, …, k_84] (for a 255-bit scalar)
where <code>scalar = k_0 + k_1 * (2^3) + ... + k_84 * (2^3)^84</code> and
each <code>k_i</code> is in the range [0..2^3).</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="struct"href="struct.EccScalarFixedShort.html"title="halo2_gadgets::ecc::chip::EccScalarFixedShort struct">EccScalarFixedShort</a></div><divclass="item-right docblock-short"><p>A signed short scalar used for fixed-base scalar multiplication.
A short scalar must have magnitude in the range [0..2^64), with
a sign of either 1 or -1.
This is decomposed into 3-bit windows in little-endian order
using a running sum <code>z</code>, where z_{i+1} = (z_i - a_i) / (2^3)
for element α = a_0 + (2^3) a_1 + … + (2^{3(n-1)}) a_{n-1}.
Each <code>a_i</code> is in the range [0..2^3).</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="struct"href="struct.NonIdentityEccPoint.html"title="halo2_gadgets::ecc::chip::NonIdentityEccPoint struct">NonIdentityEccPoint</a></div><divclass="item-right docblock-short"><p>A non-identity point represented in affine (x, y) coordinates.
<divclass="item-table"><divclass="item-row"><divclass="item-left module-item"><aclass="enum"href="enum.BaseFieldElem.html"title="halo2_gadgets::ecc::chip::BaseFieldElem enum">BaseFieldElem</a></div><divclass="item-right docblock-short"><p>Type marker representing a base field element being used as a scalar in fixed-base
scalar multiplication.</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="enum"href="enum.FullScalar.html"title="halo2_gadgets::ecc::chip::FullScalar enum">FullScalar</a></div><divclass="item-right docblock-short"><p>Type marker representing a full-width scalar for use in fixed-base scalar
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="enum"href="enum.ScalarVar.html"title="halo2_gadgets::ecc::chip::ScalarVar enum">ScalarVar</a></div><divclass="item-right docblock-short"><p>An enumeration of the possible types of scalars used in variable-base
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="enum"href="enum.ShortScalar.html"title="halo2_gadgets::ecc::chip::ShortScalar enum">ShortScalar</a></div><divclass="item-right docblock-short"><p>Type marker representing a signed 64-bit scalar for use in fixed-base scalar
<divclass="item-table"><divclass="item-row"><divclass="item-left module-item"><aclass="trait"href="trait.FixedPoint.html"title="halo2_gadgets::ecc::chip::FixedPoint trait">FixedPoint</a></div><divclass="item-right docblock-short"><p>Returns information about a fixed point that is required by <ahref="struct.EccChip.html"title="EccChip"><code>EccChip</code></a>.</p>
</div></div><divclass="item-row"><divclass="item-left module-item"><aclass="trait"href="trait.FixedScalarKind.html"title="halo2_gadgets::ecc::chip::FixedScalarKind trait">FixedScalarKind</a></div><divclass="item-right docblock-short"><p>A trait representing the kind of scalar used with a particular <code>FixedPoint</code>.</p>