// BesselJArr returns an array of Jn(x) where n runs from nmin to nmax inclusive func BesselJArr(nmin, nmax int, x float64) []float64 { arr := make([]float64, nmax-nmin+1) ret := C.gsl_sf_bessel_Jn_array(C.int(nmin), C.int(nmax), C.double(x), (*C.double)(&arr[0])) if ret != 0 { panic(gsl.Errno(ret)) } return arr }
func BesselJnArray(nmin, nmax int, x float64, result *[]float64) (e error) { resptr := (*C.double)((unsafe.Pointer)(&(*result)[0])) er := (C.gsl_sf_bessel_Jn_array((C.int)(nmin), (C.int)(nmax), (C.double)(x), resptr)) if er == (C.int)(0) { e = nil } else { e = gsl.NewGSLError(int(er)) } return }
func JnArray(nmin int32, nmax int32, x float64, resultArray []float64) int32 { _slice_header_3 := (*reflect.SliceHeader)(unsafe.Pointer(&resultArray)) return int32(C.gsl_sf_bessel_Jn_array(C.int(nmin), C.int(nmax), C.double(x), (*C.double)(unsafe.Pointer(_slice_header_3.Data)))) }