inner_prod
stdlib/inner_prod.nbv
inner_prod(lhs, rhs)
Take two vectors. Mutiply each element and sum the resulting vector.
- Precompiles
assert_eq!,len!,loop_map_sum!- Used by
bits/from_bits,ext/ext_mle_eval,ext/ext_mul,slip/slip_r1cs_arg_verify
Source
# Take two vectors. Mutiply each element and sum
# the resulting vector.
(lhs, rhs)
assert_eq! (len! lhs), len! rhs
loop_map_sum! (len! lhs), i {
lhs[i] * rhs[i]
}