vvdot   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/core/math.xtm

Implementation

(bind-func vvdot
  (let ((i 0))
    (lambda (v1:double* v2:double* len:i64)
      (let ((res 0.0))
        (dotimes (i len)
          (set! res (+ res (* (pref v1 i) (pref v2 i)))))
        res))))


Back to Index

Similar Entries