Fit with numerical integration and global variables
I am trying to write a fit function that requires numerical integration of a function with three parameters: one fixed, one fit parameter, and the integration variable. I noticed that Integrate1D can only call user functions with a single local variable, and others need to be passed as global variables. Will it cause problems that one of my fit parameters is a global variable?
Thank you.
Suppose you have a fitting function that has two fitting variables w[0] and w[1]. Suppose further that w[1] is involved in the integration function. Your fitting function will look like this:
I hope this helps,
A.G.
January 17, 2017 at 03:15 pm - Permalink