Community Tip - Did you get called away in the middle of writing a post? Don't worry you can find your unfinished post later in the Drafts section of your profile page. X
I have a serious problem with my graduating thesys... I have to solve a system of four non linear equation but I'm not able to do it... Could you help me please???
Solved! Go to Solution.
You'd simply forgotten to make we a function of m in the 2nd equation within the solve block - see attached.
Alan
Two errors spotted:
I'm am confused about the parameters (x,y,z,k) of your function F() as none of those parameters is used anywhere. So the result of the solve block would be the same constant every time. In case of the guess values and equations you provided Mathcad does not find a solution anyway (at least not with Y.3 set to 1, as I did). The first equation yields something about 10^19 if evaluated with your guess values - a bit far away from the zero you want it to be. So it may be you have to check your guesses and/or your equations.
The error message you get with a solve block is usually more than misleading and confusing. Use the right click menu and chose trace error to get a hint what the real problem could be.
I corrected the error abut Y3 but it doesn't find a solution again... substantially I have to find the stationary solution of a system of differential equations and placing d/dt equal to zero I obtained the non linear equations system I sent you before. Now I send you both 2 files, the diff eq system and the non linear one. Thanks for the help
In your dynamic model you should set ORIGIN:=1 as you are clearly counting from 1, biut Mathcad's default is to count from zero.
In your static model, remove t, Y3 should be Ti, divide the equations through by n, and create a function for ni so you only have to solve for 3 parameters (actually, if you know that ni is always going to be twice n then you could simply replace ni by 2n).
See attached.
Alan
could you send me the 2 files in an elder mathcad format please? I can't open these in mathcad 13, my version
Please find this worksheets for Mathcad 13 in attachment.
thanks VladimirN! Alan, your solution, according to me, isn't correct because the results are the same guess values setted up before the system and the command "Find" remains as an error message.
Tonino Perri wrote:
... Alan, your solution, according to me, isn't correct because the results are the same guess values setted up before the system and the command "Find" remains as an error message.
Strange! That isn't the case for me - see the image below:
This image is captured from my M15 worksheet. You can see the initial guesses and final results are different.
Alan
maybe a problem connected to my version of mathcad?? could you send me this file in mathcad 13 version please? because it's very strange
Tonino Perri wrote:
maybe a problem connected to my version of mathcad?? could you send me this file in mathcad 13 version please? because it's very strange
Here it is, though I don't think it's any different from the one Vladimir produced.
Your equations have a huge range of numbers and the solutions are sensitive to the initial guesses. It might be worth examining your equations to see if you can introduce some scaling.
Alan
As I said before, this system of equations comes from the stationary solution of the diff one. Looking the graphics of that file I setted the guess values that seem to be near to stationary solution
Tonino
Ok. I tried the file on my version of MC13. It works if I choose Conjugate gradient method, but doesn't if I choose L-M method (odd, because it works in M15 using the L-M method!). Right-click on Find to select the different options. However, MC13 gives me a different result for Te (0.25). Perhaps this last isn't surprising - with the huge range of magnitudes that your variables span, there are undoubtedly going to be some numerical inaccuracies.
Alan
My file doesn't work again please could you send me this file too? the Conjugate gradient method one
Tonino Perri wrote:
My file doesn't work again please could you send me this file too? the Conjugate gradient method one
It's the same file. You just right-click on the word Find, go to non-linear and select Conjugate gradient. I've also just noticed that the first term in the last equation has an ni instead of an Omega2 (when compared with the last equation of your dynamic file).
(Incidentally, I was wrong about MC15 choosing the L-M method - I've just checked and it automatically chooses the conjugate gradient method).
Alan
On my pc it doesn't work again. I can't understand
Tonino Perri wrote:
On my pc it doesn't work again. I can't understand
Do you mean the file doesn't do anything at all, or you get an error in the Given...Find block? Have you been able to select Conjugate gradient? What version of MC13 are you using (go to Help/About to find out)?
Alan
Now it works!!! thank you for help Alan!!!
Tonino Perri wrote:
Now it works!!! thank you for help Alan!!!
Good, but I'm suspicious of the accuracy of the results. Change the initial conditions (say, set Te to 50) and see if you get the same results. Check if the results make the LHS of the equations zero.
Alan
Alan I just realized that the condition ni=n is verified only as a boundary condition for the dynamic problem. So I have to solve the 4 equations system. Could I solve the system without setting that condition? I tried but it gives me error.
See attached. I've manipulated your equations to reduce the numerical problems. You must check that I've not made a mistake in doing so!
Alan
The assumptions you did seem to be correct but, on my version, the values of Te and Ti are the same guess values... And Find operation is red again. It'so in MC15 too?
Tonino Perri wrote:
.... And Find operation is red again. It'so in MC15 too?
No. It works ok in MC15. I've attached a slightly improved version (improvements are cosmetic), together with a pdf copy so you can see the whole of the MC15 worksheet.
I haven't actually run it in MC13 - perhaps I'll go and do that now (MC13 is on my old PC).
Alan
Ok. Now I've run it on MC13. The problem seems to arise from the fact that the MC13 symbolic processor doesn't like the absolute value function in the definition of function P. One can safely remove this and everything works as it should. See attached.
Alan
I found some errors in your system, the correct form is contained in the file that I attached. It doesn't work again
You'd simply forgotten to make we a function of m in the 2nd equation within the solve block - see attached.
Alan
It works!!!! Thank you so much Alan!!!