For all HP 50g users,
The SUBST command works only correct for substituting names, but not for expressions, like "X=SIN(R*T)" when you have additonal names "R" or "T" in the expression where you want to substitute the "X".
A little program is able to overcome that behavier. I wrote this because of a thread in the hp own calculator forum with that topic.
Thank you pin224466 (that person who started the thread) for clarifying that problem. I have to post here, because I left the hp own forum some time ago. I hope that is okay to go that way.
<< EQ-> 2 ->LIST -> MATCHLST
<< WHILE MATCHLST "UP"MATCH
REPEAT END
>>
>>'CHGEX' STO
As Input you have same syntax like for SUBST, but ist works now fine without isolating to other names. And even better it can be used with placeholders as "&A"!
For example:
STACK 2: 'COS(3*X+7*SIN(X^2 - R*T))'
STACK 1: 'X=R/T'CHGEX
STACK 1: 'COS(3*R/T+7*SIN((R/T)^2-R*T))'
Greetings
peacecalc