SMath Studio Forum
»
SMath Studio
»
Questions
»
simple structural stress equation  solver fails..(?)
Rank: Newbie
Groups: Registered
Joined: 03/08/2022(UTC) Posts: 3

Dear all, 1st off  I am new to SM and experienced this problem with simple structural stress equation (stress due to bending) that I am unable to resolve  see attached. Solver returns error "No real roots". I know there is as solution but I am unable to accomplish it. Q1: Please advise  what am I doing wrong? Q2: What is a best way to solve this as a system of equations (instead of substitution in order to arrive to a single eqn presented)? 5614.sm (93kb) downloaded 17 time(s).Thanks!




Rank: Advanced Member Groups: Registered
Joined: 23/03/2016(UTC) Posts: 240 Was thanked: 77 time(s) in 48 post(s)

You can use units. Don't listen to Jean on this point. One solution  use maxima. 5614.sm (96kb) downloaded 14 time(s). 5614.pdf (564kb) downloaded 3 time(s). 




Rank: Advanced Member Groups: Registered
Joined: 23/12/2011(UTC) Posts: 305 Location: italy Was thanked: 105 time(s) in 89 post(s)

Considering the internal solutors of Smath, the only one who contains the units of measurement is "FindRoot". Otherwise there are all the solutors of the plugins (something has already been proposed to you for Maxima). Also careful not to fix "b" with a value, otherwise it is no longer an unknown for the solutor (For this, Clear ( b ) was used in the example with Maxima). 5614ser.sm (89kb) downloaded 16 time(s).sergio Edited by user 03 August 2022 17:22:31(UTC)
 Reason: Not specified




Rank: Advanced Member Groups: Registered
Joined: 28/08/2014(UTC) Posts: 1,012 Was thanked: 560 time(s) in 364 post(s)

Well, you have a solution with Maxima, another with FindRoot ... this is a solution with solve or roots. 5614.sm (93kb) downloaded 27 time(s).Best regards. Alvaro.




Rank: Member Groups: Registered
Joined: 11/01/2018(UTC) Posts: 28 Location: Wisconsin Was thanked: 9 time(s) in 7 post(s)

Greetings, There are several forums that discuss similar issues; I would encourage you to look though these threads:
 https://en.smath.com/for...realrootsresult.aspx
 https://en.smath.com/for...quationswithSolve.aspx
 https://en.smath.com/for...orMissingVariable.aspx
You will notice a lot of different approaches; I am personally bias to using maple to solve these problems (In order to run maple functions, you need to install the "Maple Tools Plugins" ) [Using Maple]: Since you already constructed f( b ), all you need to do is perform a symbolic evaluation ( keypress [Ctrl] + [.] instead of [=]). This will produce the following: . . . NOTE: you cannot have any of the variables defined, else those values will be treated as constants and thus substituted into the equation.You can copy the text below and paste it into your worksheet; this will generate the result based off of your variables (I work in imperial, thus 'ft' is referenced): Code:{1143*((nthroot(L.1*(2*σ.a*(Q.m*σ.a+sqrt(Q.m*(Q.m*σ.a^2+γ^3*L.1^5)))+γ^3*L.1^5),3))^2+γ^2*L.1^4+γ*L.1^2*nthroot(L.1*(2*σ.a*(Q.m*σ.a+sqrt(Q.m*(Q.m*σ.a^2+γ^3*L.1^5)))+γ^3*L.1^5),3))}/{5000*σ.a*nthroot(L.1*(2*σ.a*(Q.m*σ.a+sqrt(Q.m*(Q.m*σ.a^2+γ^3*L.1^5)))+γ^3*L.1^5),3)*'ft}
This brings us to units; by solving symbolically, you can identify those variables where the units "don't match". It looks like pressure is your culprit... I haven't had much success using pressure with regards to force; there is something with regards to the gravitational constant that doesn't quite work right. Therefore, I consider pressure to be of units force/ area instead of mass/ area. This will cause the units of your inputs to change as such: . . . I hope this Helps! Kenny Lemens, P.E.




Rank: Newbie
Groups: Registered
Joined: 03/08/2022(UTC) Posts: 3

Dear experts, Thank you for your solutions! I like the elegance presented which answers my question Q2 above on substitution. Re units / unitless project: I eventually managed to solve it with polyroots (before reading your posts) after rearranging the eqn in the form of polynomial order b^3 (disadvantage: I do the math instead of SM..). What I noticed is that with units result is 0.152 m while unitless returns value 3.8664 ratio of these being 25.47 which is (close to) units ratio mm/inch. Coincidence or Bug? How can one be sure on the output in case of professional application ? Real world example of not using units properly and catastrophic outcome here https://www.wired.com/20...climateobserverreport/ and the same topic on YouTube video "Advanced Problem Solving with PTC Mathcad" @ 4th min. Nostalgic side note: my old handheld hp48 returns correct result (0.152 m) in no time. 5614  Unitless.sm (94kb) downloaded 5 time(s).Edited by user 04 August 2022 10:52:59(UTC)
 Reason: Not specified




Rank: Newbie
Groups: Registered
Joined: 03/08/2022(UTC) Posts: 3

Originally Posted by: PompelmoTell Considering the internal solutors of Smath, the only one who contains the units of measurement is "FindRoot". Otherwise there are all the solutors of the plugins (something has already been proposed to you for Maxima). Also careful not to fix "b" with a value, otherwise it is no longer an unknown for the solutor (For this, Clear ( b ) was used in the example with Maxima). 5614ser.sm (89kb) downloaded 16 time(s).sergio Thank you Sergio! I like the elegance presented. However, changing initial guess value (b0) returns different results...(?) For [b0] between 1 mm to 300 mm result is 152 mm while for b0=500 mm returns 145 mm, for b0=600 mm result is 39 mm. (?) What is going on here? Why this sensitivity to initial values and different results ? Edited by user 04 August 2022 12:37:59(UTC)
 Reason: Not specified




Rank: Advanced Member Groups: Registered
Joined: 23/12/2011(UTC) Posts: 305 Location: italy Was thanked: 105 time(s) in 89 post(s)

These are non linear equation, the solutions also depend on the research interval (especially with numerical solution methods) it is appropriate to proceed with a sanity check and sometimes trace the graph of the function to identify the search interval. 5614ser2.sm (94kb) downloaded 13 time(s).sergio




Rank: Advanced Member Groups: Registered
Joined: 28/08/2014(UTC) Posts: 1,012 Was thanked: 560 time(s) in 364 post(s)

Hi Ante. Another example about what important is work with units, as you well point too. And the Smath relevance just because is the only one unit friendly math program today. Notice that taking out the units requires the introduction of their multipliers like giga, kilo or mili in the unitless version. So there are not a bug there.
Best regards Alvaro




Rank: Advanced Member Groups: Registered
Joined: 23/07/2013(UTC) Posts: 829 Was thanked: 290 time(s) in 204 post(s)

Originally Posted by: Ante021 Q1: Please advise  what am I doing wrong? Q2: What is a best way to solve this as a system of equations (instead of substitution in order to arrive to a single eqn presented)? While solve() and roots() can't work with units, you can "trick" them by altering your equation. And there are many possible ways to solve with units, please check the examples below. 5614.sm (128kb) downloaded 18 time(s).Originally Posted by: alyles You can use units. Don't listen to Jean on this point. I agree with alyles about Jean, never ever listen to him about engineering calculations. He may have some good examples about math calculations, but most of his samples are only for himself. Worst of all he is notorious with his wrong formulas, faulty approach for basic engineering calculations, Don Quixote like crusade against units, etc. And there are some aspects to use temperature units with SMath, read forums and help files carefully before using them. Jean simply don't know how to work with units, because he never did use them. And according to his own samples, he gets wrong results whenever units are involved and important. Regards




SMath Studio Forum
»
SMath Studio
»
Questions
»
simple structural stress equation  solver fails..(?)
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.