Debugging help needed

Debugging help needed - Getting error message on variable in formula, but when printing separately the value is there - Messages

#1 Posted: 11/16/2020 10:19:38 AM
Terje B

Terje B

0 likes in 5 posts.

Group: User

Trying first time with some bigger formula set, but now I have run into a problem with some error propagating into the calculation. Seems more or less lie anything becomes a problem some way down and even if I reformulate the formulas there pops up another problem with a value not being set as shown in the attachment. When I rewrote the formula then another value was marked red.

Feeling like the program is either running out of memory or there is a problem somewhere else causing the problem in the last part.SMath error.png

I saw someone else looking into the text file here on the forum and I see there are some error message there without me understanding how to debug it:


SMath error - 1.png>




G.3
1
2
H.O2_CO2
K.O2
*
H.N2_CO2
K.N2
*
+
(
*
+
H.O2_CO2
2
^
K.O2
2
^
*
+
H.O2_CO2
H.N2_CO2
*
K.O2
*
K.N2
*
+
H.N2_CO2
H.O2_CO2
*
K.N2
*
K.O2
*
+
H.N2_CO2
2
^
K.N2
2
^
*
+
:


#







Hope someone have time to tell kick me in the right direction here


Terje
#2 Posted: 11/16/2020 11:28:07 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

Hope someone have time to tell kick me in the right direction here


Attach the document [no monkey see, no monkey do].
Define the undefined or make the formula dependent of the parameters.
#3 Posted: 11/16/2020 1:23:35 PM
overlord

overlord

547 likes in 1330 posts.

Group: Moderator

Wrote

Attach the document [no monkey see, no monkey do].
Define the undefined or make the formula dependent of the parameters.


Jean is right.You want something that is very time consuming for other people to recreate the document they see on a screenshot and debug it while the document can be simply posted.

Regards
#4 Posted: 11/26/2020 9:53:51 AM
Terje B

Terje B

0 likes in 5 posts.

Group: User

Thanks for answering, I didn't attache the file because I wasn't sure it was OK to do this in here.

Blandingers viskositet_R01.sm (272 KiB) downloaded 38 time(s).Attached is the file.




Best Regards,

Terje
#5 Posted: 11/26/2020 11:42:07 AM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Your numerical engine is scrap from other gyzma(s).
That kind of bug is not possible in native Smath.

BugBugBug.PNG
#6 Posted: 11/26/2020 1:21:54 PM
Andrey Ivashov

Andrey Ivashov

2269 likes in 3729 posts.

Group: Super Administrator

Program says μr_O2 - not defined:

mega_1.jpg

Searching for μr_O2:

mega_2.jpg

It is really not defined. This equation is only one place where μr_O2 can be found.

This is an error.
#7 Posted: 11/26/2020 3:29:29 PM
Jean Giraud

Jean Giraud

983 likes in 6866 posts.

Group: User

Wrote

This is an error.


Quite a curiosity !

Curiosity.PNG
#8 Posted: 11/30/2020 8:11:22 AM
Terje B

Terje B

0 likes in 5 posts.

Group: User

Hello,
As far as I can see I have defined the variable here:

mu_r-O2.png

Have I done something wrong in this definition?


When I try to print the variable other places in the document it seems like it is defined since it returns a value of zero (which it should have).

Did a test with different value

mu_r-O2-1.png

and it still is a problem even if the value is defined:

mu_r-O2-2.png


Appreciate all help from you here!



Terje
#9 Posted: 11/30/2020 9:33:22 AM
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 likes in 1674 posts.

Group: User

Hi. The error msg is about mr_O2, even red colored another expression. But notice that you define "m.r_O2" not "mr_O2", see the difference in the dot.

Clipboard01.jpg

Clipboard02.jpg

Best regards.
Alvaro.
#10 Posted: 12/4/2020 7:23:27 AM
Terje B

Terje B

0 likes in 5 posts.

Group: User

Thanks Alvaro and the rest for assisting me here! Finally found the error with your help now.

I see you use an Unknowns() function, is there some documentation of that one? Did not get same result as you when I tried to enter it.



Terje


#11 Posted: 12/4/2020 4:35:50 PM
Alvaro Diaz Falconi

Alvaro Diaz Falconi

992 likes in 1674 posts.

Group: User

Hi Terje.

Under Tools / Plugins open the "Interactive Book" named "Interactive SMath Handbook", which it's an extensive and excellent documentation for SMath and almost all it's plugins, by Martin Kraska.
Then look under plugins / Special solvers. There is an entry for Unknows.

Clipboard01.jpg

Clipboard02.jpg

Best regards.
Alvaro.
  • New Posts New Posts
  • No New Posts No New Posts