MCPcopy Create free account
hub / github.com/PolyhedraZK/ExpanderCompilerCollection / Add

Method Add

ecgo/builder/api.go:37–41  ·  view source on GitHub ↗

--------------------------------------------------------------------------------------------- Arithmetic Add computes the sum i1+i2+...in and returns the result.

(i1, i2 frontend.Variable, in ...frontend.Variable)

Source from the content-addressed store, hash-verified

35
36// Add computes the sum i1+i2+...in and returns the result.
37func (builder *builder) Add(i1, i2 frontend.Variable, in ...frontend.Variable) frontend.Variable {
38 // extract frontend.Variables from input
39 vars := builder.toVariableIds(append([]frontend.Variable{i1, i2}, in...)...)
40 return builder.add(vars, false)
41}
42
43func (builder *builder) MulAcc(a, b, c frontend.Variable) frontend.Variable {
44 return builder.Add(builder.Mul(b, c), a)

Callers 4

MulAccMethod · 0.95
SelectMethod · 0.95
Lookup2Method · 0.95
addMethod · 0.45

Calls 2

toVariableIdsMethod · 0.95
addMethod · 0.95

Tested by

no test coverage detected