
Razonar and Jean thanks for the quick replies, I tried Razonar's suggestion and it does fix the issue! I do like the idea to ensure f(2)=4 and f(-9)=81 to ensure the function works correctly.
Jean very helpful as well, I attempted to implement your example and haven't gotten it yet. Not sure if this is MathCad or SMath, I cannot get the "if" statement to work as you have it. So far I get only the "if" "else" from the programming toolbar only. The matrix's work though, so hopefully I get your example working in SMath soon.