CpowR   xtlang


Defined in:  https://github.com/digego/extempore/tree/v0.8.9/libs/contrib/gsl.xtm

Implementation

(bind-func CpowR
  (lambda (num1:gsl_complex* num2:double)
    (let ((num3:gsl_complex* (alloc))
    (cres (gsl_complex_pow_real (pref num1 0) num2))
          (res (tref cres 0)))
      (aset! (tref-ptr num3 0) 0 (aref res 0))
      (aset! (tref-ptr num3 0) 1 (aref res 1))
      num3)))


Back to Index