fsolve the Levenberg−Marquardt algorithm
Show older comments
I have an equation but i don't know how use the fsolve levenberg - marqurdt algorithm to turn it ODE equation:
Dp (3Cn+1 - 4Cn + Cn-1)/2h +Pp Ds (3Cn+1 - 4Cn+ Cn-1)/2h d/dCn+1(Krp/1+Arp* Cn+1^B) = kf (C-Cn+1)
I need help please
thanks
2 Comments
John D'Errico
on 5 Feb 2020
Edited: John D'Errico
on 5 Feb 2020
Yours is one of those questions that will very possibly never get a useful answer, at least not until you explain far more clearly what you are trying to do. You show a relationship between a bunch of undefined variables. I can't even really call them variables, just stuff. Some of them may be functions, or perhaps you just don't bother to use an * for multiplication. But are they intended as functions? In MATLAB Ds(stuff) is how you call a function, or perhaps how you index a variable. It is NOT how you multiply things. So we cannot know what you inrtended.
As well, we see what MAY be subscripts on some variables. Or, are they new variables, where we are supposed to multiply C with the (variable?) n, and then add 1? This is the problem when you use ambiguous notation. If Cn+1 really intended as a subscript of (n+1) to the vector C? We cannot read your mind. We might make a random guess. But most of the time, guesses turn out randomly wrong.
That alone makes it confusing. A long equation like this is meaningless out of context. Unless we know what it is, what the "variables" mean, etc., It has no meaning, beyond a list of random characters.
Finally, you introduce some random ideas, ones that you must think will be necessary. However, fsolve cannot turn an equation into an ODE, nor is it a tool designed to solve an ODE, Levenberg-Marquart or not.
Typically, when I see highly confusing questions like this, it means the person was also highly confused. So they throw out some random pieces of vaguely mathematical jargon, hoping that something will make sense. That does not help, in fact, it probably leads some people (who might try to answer) astray, trying to guess what you really want to do.
What you need to do, if you really want an answer, is to SLOW DOWN. Explain in very clear words, what it is that you are trying to do. Don't just throw an equation onto the page, and assume that everyone can read your mind. Be CLEAR. After all, if you want help, then if it is easy to help you, you will far more often be successful in your goal.
So edit your question. Make it CLEAR. Do not add an answer. If you prefer, add a comment, just as I did now. Help those who could possibly help you. Otherwise, people will just glance at your question, shake their heads in consternation, and go onto another they can understand.
Walter Roberson
on 5 Feb 2020
Perhaps you have a boundary value problem? If so there are routines to solve those.
Answers (0)
Categories
Find more on Tuning, Analysis, and Validation in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!