Hello.
I’m relatively new to new to Mathematica and have following problem:
I want to define a function using a variable which has a lot of content stored on it.
For example(very simplified):
Clear[x, y, z, is, q, f];
q = x^2 + y^2 + z^2 - 5 is;
f[x_, y_, z_, is_] := q;
f[1, 1, 1, 1]
The ouput is:
-5 is + x^2 + y^2 + z^2
But that is not the output I want. I need a way to get the expression from q into the defintion of the function f. One way would be to just let the programm show me the output of q and copy that in the function. However in my case, the output is 500 lines long and therefore the notebook gets needlessly long and confusing.
I hope you understand my problem and that there is an easy way to deal with it.