I am studying term rewriting using Baader and Nipkow's book "Term Rewriting and All That". I am trying to solve the following exercise about word problems:
4.1 Give a trivial example of a finite set of identities $E$ such that the ground word problem for $E$ is decidable, but the word problem is not.
My idea to solve this relies on an example the authors give in this section, shown below with minor modifications:
Example 4.1.4
$$\{(xy)z \approx x(yz), \ aba^2b^2 \approx b^2a^2ba, \ a^2bab^2a \approx b^2a^3ba, \\ aba^3b^2 \approx ab^2aba^2, \ b^3a^2b^2a^2ba \approx b^3a^2b^2a^4, \ a^4b^2a^2ba \approx b^2a^4 \}$$
The equations above show a finitely presented semigroup with undecidable ground word problem due to Matijasevic [170]. In the terminology of this book, we have one binary infix function $\cdot$ and two constants $a$ and $b$, together with the identities shown above. For readability $x \cdot y$ and $x \cdot \cdot \cdot x$ are written $xy$ and $x^n$. Associativity allows us to drop brackets.
After that the authors note that:
We can recast this example in terms of unary function symbols only, drop "$\cdot$" and the associativity rule, turn $a$ and $b$ into unary functions, and interpret an identity like $ab \approx ba$ as $a(b(x)) \approx b(a(x))$. Because there are no ground terms, this only yields the undecidability of the word problem.
So, as far as I understood the transformation described in the comment above by the authors already solves the exercise. The ground word problem would be decidable vacuously since there are no ground terms and the word problem obtained by doing the mentioned transformation is undecidable since it is equivalent to the ground word problem proved undecidable by Matijasevic.
Is this reasoning correct and is that all I need to do for this question? Or is there a simpler example that I missed?
Thank you in advance.