# Is there a way to force 'Simplify' to use some assumptions?

First time poster. I have a basic question about 'Simplify'.

I am encountering a problem when trying to simplify some algebraic expressions, where I find an unexpected behaviour of the 'Simplify' function. I am using Mathematica 13.3 on Windows.

Consider the following problem: we have a somewhat complicated expression expr depending on many variables, and we have a system of equations eqs that these variables satisfy. We then want to simplify expr using eqs, by calling

Simplify[expr,eqs]

Unfortunately, this does not seem to always give the desired result... Here is the simplest example in which I managed to produce a puzzling (to me) behaviour of 'Simplify'. Consider the following expression and equations:

expr = 2 + k[1, 1, 1, 0];
eqs1 = k[1, 1, 1, 0] == u[2, 0];
eqs2 = k[1, 1, 1, 0] == x;
Simplify[expr, eqs1]
Simplify[expr, eqs2]

where I am considering k[1,1,1,0], u[2,0], and x as some coefficients in a more complicated expression. When I run the above code, it returns

2+u[2,0]
2+k[1,1,1,0]

It's like Mathematica has decided that u[2,0] is simpler than k[1,1,1,0], while x is more complicated, and I can't understand why. I have tried using some other simple ComplexityFunction, as well as 'FullSimplify', but I keep finding the same behaviour. Hence my question: is there a way to force Simplify to consider x to be simpler than the other object k[1,1,1,0]?

P.s. I realise that this simple example could be solved by using a rule, rather than asking Simplify to handle the renaming of the variables. However, I am interested in a situation where I have a large set of variables and equations, and using a rule in that case seems to me to be more complicated...

• Not sure why it does not work, nor why this does: eqs2 = k[1, 1, 1, 0] == Unevaluated@x. Commented Mar 27 at 23:38
• I think you should perhaps look into Eliminate rather than Simplify. It may be a more appropriate tool for the task. Commented Mar 28 at 1:11
• expr /. Rule @@ eqs2 Commented Mar 28 at 2:24
• You defined expr and then referenced exp. Your code would not execute as written. Commented Mar 28 at 5:55
• @Ghoster thank you, I corrected the typo. Commented Mar 28 at 12:15