Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X
Havin trouble understanding why this function, which worked in Prime 9, no longer works in Prime 10? Unfortunately, it requires an add-in that I doubt many have (Refprop wrapper for Mathcad).
It really makes no sense that Refprop would have anything to do with the underlying problem based on the fix (to get the function that worked in Prime 9 to work in Prime 10), which is this:
Obviously, this required a change to a program which literally served to assign a -1 value to alpha prior to the function on line 2. However, nothing of the original equation required modification. Seems odd to me but hoping that someone would have thoughts on what could have changed between 9 and 10 to require this mod.
Thanks,
Bob Wilson
Solved! Go to Solution.
Just created a simplified example and i guess that you experience the same error message:
Needless to say it works as it should in Prime 9
In Prime 10 any dummy assignment is required as a workaround
Another workaround would be to use the symbolic evaluation
But this workaround does not work for all functions, especially it fails if the function contains a conditional expression.
So the dummy local assignment seems to be the way to go until the bug is fixed by PTC.
The simplest way without having to use a two-liner seems to be this:
Can you duplicate the problem with a simple user written program without using the Refprop wrapper and then post the sheet?
I see no reason why the first expression should not work, but don't have any thoughts (other than it might be yet another newly introduced bug in Prime) without having a sheet to play with, not even knowing which error message is thrown.
P.S.: It looks like a severe bug was introduced with P10 which concerns derivatives of functions with more than two arguments.
See:
Error in a function of a root function PRIME10 - PTC Community
Solved: Re: A function or a variable name is required when... - PTC Community
The workaround you found is similar to the one I posted in the second thread. There I found that ANY assignment would do. So you can try to assign "alpha <-- 123" and don't use alpha at all in the second line.
Your problem looks like the very same bug and as @DJNewman wrote in that thread he reported it to PTC support. So hopefully this bug will be fixed in the next version. Unfortunately PTC seems not to be able/willing to provide hot fixes or updates for current already delivered versions.
Just created a simplified example and i guess that you experience the same error message:
Needless to say it works as it should in Prime 9
In Prime 10 any dummy assignment is required as a workaround
Another workaround would be to use the symbolic evaluation
But this workaround does not work for all functions, especially it fails if the function contains a conditional expression.
So the dummy local assignment seems to be the way to go until the bug is fixed by PTC.
The simplest way without having to use a two-liner seems to be this:
Thank you, Werner. I am working with someone that wrote the original function by posting here on his behalf. He suspected and you confirm that this is a bug. Quite the strange one though. Do you think PTC is aware of this? I somehow missed your second reply. I apologize for this. Glad to hear PTC is aware of the problem.
Bob
So all we can do is crossing our fingers and hoping that PTC takes the problem serious enough to provide a fix in the very next version.