Community Tip - Have a PTC product question you need answered fast? Chances are someone has asked it before. Learn about the community search. X
Hi all,
I'm having a problem with the Minerr(x, var1,var2...) function within a Mathcad sheet. It performs well provided the function I'm try to minimize to is relatively simple.
for example; see file 1. In this sheet my constaint is met easily and a good fit is acquired.
However, when the complexity of the function is increased, no value will ever be returned and the solve block seems to break down.
Any way to combat this? Is there something I'm overlooking?
Any help will be appreciated,
Thanks.
Hi Neil,
2 problems that cause you equations to fail.
1. in the definition of H1 you have parameters a1, b1 c1 but use the values a, b & c which are constants carried over from the file 1 calculation.
More interesting is :
2.
Although the equations look identical there is a problem with the | ... |, delete & retype this & it all works.
(Another oddity for Valery to add to his ever increasing list)
Regards
Andy
Thanks Andy, it's nice to see a bit of progress can be made with this!
Also, the fit seems very good for this example, however, for my problem it still seems to be having a problem.
I'll try and upload the sheet that I'm having trouble with but it has some sensitive data so I'll have to lock a region so that just the relevant functions are visible.
Is there any reason you can think of why a Rayleigh distribution function may be causing Minerr a problem in particular?
Neil
Is there any reason you can think of why a Rayleigh distribution function may be causing Minerr a problem in particular?
No. Minerr does not like discontinuous functions or functions with flat areas, but other than that it doesn't care.
One thing to bear in mind is that there is only ever one error message from a solve block: "this variable is undefined". You get this error regardless of what the actual problem is.
Although the equations look identical there is a problem with the | ... |, delete & retype this & it all works.
(Another oddity for Valery to add to his ever increasing list)
Right click on the operator and set it to "absolute value" (it somehow got set to "square matrix determinant").