Timeline for The method to use for MultiNonlinearModelFit
Current License: CC BY-SA 4.0
6 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Apr 8, 2023 at 1:03 | comment | added | VladM |
Ok, I found the source of the trouble. Using ComplexExpand[ReIm[Model]] is a really bad idea. This function is trying to separate your Model into real and imaginary parts analytically. The result is a horrible expression of 1000's terms long when your Model is complicated enough. You need to define instead a numerical function Modelnum[c1_,c2_,...,x_,y_]:={Re[Model],Im[Model]} where c1,c2 ... are parameters of your function and z=x+Iy. Then it evaluates the Model function numerically and converges instantly. ComplexExpand can be only used when your model is really simple.
|
|
Apr 8, 2023 at 0:58 | comment | added | VladM | Ok, I found the source of the trouble. Using ComplexExpand[ReIm[Model]] is a really bad idea. This function is trying to separate your Model into real and imaginary parts analytically. The result is a horrible expression of 1000's terms long when your Model is complicated enough. | |
Apr 7, 2023 at 8:22 | comment | added | VladM | Thanks, I corrected the code, it was in LaTeX but the system was not accepting it. Regarding equal variances, two sets of data are real and imaginary parts of the function. I guess it is a reasonable assumption. | |
Apr 7, 2023 at 8:20 | history | edited | VladM | CC BY-SA 4.0 |
deleted 5 characters in body
|
Apr 7, 2023 at 5:05 | comment | added | JimB |
The code for f[z] is a bit off. Underscores aren't a valid option in variable names and you have what probably should be a pair of parentheses that starts with a ( and ends with a } . Also, MultiNonlinearModelFit assumes equal variances for the two sets of data. Is that a reasonable assumption?
|
|
Apr 7, 2023 at 3:16 | history | asked | VladM | CC BY-SA 4.0 |