Is it possible to formulate the theory of rings using a 3-place relation? If I have a finite theory with a signature with finitely many constant, function, and relation symbols, then I can sometimes (possibly always) formulate an equivalent theory associated with a signature with a single relation symbol.
I have an explicit 4-place relation symbol that can express the theory of commutative rings $Q(x, y, z, w) \leftrightarrow w=(x+y)\cdot z $.
I'm wondering whether this is the best we can do, or whether there's a three-place relation that can capture the theory of rings.

I'm interested in whether rings can be expressed using a three-place relation symbol.
For example, the theory of groups has the following signature $\{e, {}^{-1}, \cdot\}$, but all of these can be expressed in terms of a single ternary relation.
$$ R(x, y, z) \;\; \text{if and only if} \;\; x \cdot y = z $$
The identity element in the sole element in the domain satisfying the following
$$ \forall x \mathop R(e, x, x) $$
The inverse of $x$ is $y$ if and only if the following holds.
$$R(x, y, e)$$
For rings, I am pretty sure the best that I can do is a four-place relation
$$ Q(x, y, z, w) \;\; \text{if and only if} \;\; (x+y)*z = w $$
$0$ is the multiplicative annihilator. $$\forall x \forall y Q(x, y, k, k) \;\text{holds}\;\; \text{if and only if}\;\; k = 0 $$.
$1$ is the multiplicative identity.
$$ \forall x Q(x, 0, k, x) \; \text{holds} \;\; \text{if and only if} \;\; k = 1 $$
I can define the sum of $x$ and $y$.
$$ Q(x, y, 1, z) \;\; \text{if and only if $z$ is the sum of $x$ and $y$} $$
I can define the product of $x$ and $y$.
$$ Q(x, 0, y, z) \;\; \text{if and only if $z$ is the product of $x$ and $y$} $$
 A: The operations of any ring can be defined (in first-order logic) from the relation $$x\cdot y=z\vee x+y=z.$$  Let me think of this relation as defining a binary "quasi-operation" $x*y$ that can take two different values, either $xy$ or $x+y$.  I will write $x*y=z$ to mean that $z$ is one of the values of $x*y$, though of course we must be careful with this notation since this use of "$=$" is not transitive.  If our ring has one element, then our task is trivial, so we may assume it has more than one element (and in particular it satisfies $0\neq 1$).
First note that we can define $0$ as the unique $a$ such that $a$ is the only value of $a*a$.  Once we have $0$, we can define $1$ as the unique $a\neq 0$ such that $a*y=y$ for all $y$.  We can then define $x+1$ as the value of $x*1$ that is different from $x$.  Then $x-1$ is the unique $a$ such that $a+1=x$, and in particular we can define $-1=0-1$.  Then we can define $-x$ as the value of $(-1)*x$ that is different from $x-1$ (or the unique value of $(-1)*x$ if there is only one).  Also, we can define the condition $xy=1$ to mean that either $1$ is the only value of $x*y$ or that $x*y=1$ and $y\neq 1+(-x)$.
Finally, we can define $x+y$ as follows:

*

*If $xy=1$, then $x+y$ is the value of $x*y$ other than $1$ (or $1$ if that is the only value of $x*y$).

*If $xy\neq 1$, then $x+y$ is the unique value $a$ of $x*y$ such that both $a*(-y)=x$ and $a*(-y+1)=x+1$.

The only way the second case could fail to uniquely describe $x+y$ is if both $xy(-y)=x$ and $xy(-y+1)=x+1$.  But these two equations together give $xy=1$, and so the first case handles that.
And of course, once we have $x+y$, we can define $xy$ as the value of $x*y$ other than $x+y$ (or the unique value if there is only one).
A: I don't have an example of a 3-place predicate for rings, but I can offer some insight for why your 4-place relation works for rings and why your 3-place relation works for groups, and why you shouldn't expect this approach to give you a 3-place predicate for rings.
First, it's well-known that groups can be axiomatixed using only the $\cdot$ function. The axioms are

*

*$\exists e \forall x (e \cdot x = x \land \exists y (y \cdot x = e))$

*$\forall x \forall y \forall z (x \cdot (y \cdot z) = (x \cdot y) \cdot z)$
Briefly, I'll prove the other group laws.
Take some $e$ such that $\forall x (e \cdot x = x \land \exists y (y \cdot x = e))$.
I claim that for all $x$ and $y$, if $y \cdot x = e$ then $x \cdot y = e$. Indeed, we see that $y = e \cdot y = (y \cdot x) \cdot y = y \cdot (x \cdot y)$. Take some $z$ such that $z \cdot y = e$. Then we have $e = z \cdot y = z \cdot (y \cdot (x \cdot y)) = (z \cdot y) \cdot (x \cdot y) = e \cdot (x \cdot y) = x \cdot y$.
Now, I claim that $x \cdot e = x$ for all $x$. Indeed, take $y$ such that $y \cdot x = e$. By above, we have $x \cdot y = e$. Then we have $x = e \cdot x = (x \cdot y) \cdot x = x \cdot (y \cdot x) = x \cdot e$.
Now suppose we had another left identity, call it $e'$. Then we have $e = e' \cdot e = e'$. Thus, there is a unique left identity - call it $e$. We've already shown that this is a right identity.
Finally, suppose $y$ and $y'$ are both left inverses of $x$. Then we have $y = e \cdot y = (y' \cdot x) \cdot y = y' \cdot (x \cdot y) = y' \cdot e = y'$. Then each $x$ has a unique left identity - call it $x^{-1}$. We've already shown that this is a right inverse.
Thus, we've recovered the full signature $\{e, ^{-1}, \cdot\}$ from $\cdot$ alone.
Obviously, whenever you have a $n$-ary function symbol $f$, you can instead axiomatise using an $n + 1$-ary predicate symbol $P$ (where the implied semantics is $P(x_1, ..., x_n, y) :\equiv f(x_1, ..., x_n) = y$). This is how you axiomatised groups with a single $3$-ary predicate.
Similarly, it's possible to axiomatise rings with the single operator $g$, which is understood to mean $g(a, b, c) = (a + b) \cdot c$. The axioms here are probably not so nice, but it's clearly possible to axiomatise by postulating the existence of zero and one and then quoting all the normal operations, with $a + b$ replaced by $g(a, b, one) = (a + b) \cdot one$ and $a \cdot b$ being replaced by $g(a, zero, b) = (a + zero) \cdot b$ and adding one last axiom that $g(a, b, c) = (a + b) \cdot c = g(g(a, b, one), zero, c)$.
Replacing that 3-place function with a 4-place predicate gives you your axioms for rings.
For describing rings with a 3-place predicate using the above approach, we'd have to find a binary function which is enough to recover all information about the ring. I don't think this is possible, but I definitely can't prove it.
It's definitely plausible there's some other way to axiomatise rings that doesn't involve turning a 2-place function into a 3-place predicate and gives us a 3-place predicate axiomatisation. But I have no idea how to find such a system.
A: I have a way to do this for exponential fields, but it's really horrible and I'm not sure it works beyond the complex numbers. Thanks Noah Schweber for the idea to insert conditionals into the predicate and the suggestion to look at the complex numbers specifically.
Here's the ternary predicate and definition when applied to the complex numbers. We will use this definition informally to check that the structure that we build on top of $P$ has the correct semantics in real life, but from the perspective of this answer, we are taking $P$ as primitive and defining $+$, $\cdot$, $\exp$, $0$ and $1$ in terms of it.
$$ P(x, y, z) \\ \text{if and only if} \\ \{x, y, z\} = \{0\} \;\;\text{or}\;\; \{x, y, z\} = \{1\} \; \text{or} \;\; (y=1 \land \text{exp}(x) = z) \;\;\text{or}\;\; xy + z = 1 $$
With that out of the way, let's show that we can recover $0, 1, +, \cdot$ from $P$ alone.
$c$ and $d$ are equal to $0$ and $1$ respectively if and only if the satisfy the following statements
$$ P(c, c, c) \\
P(d, d, d) \\
c \ne d \\
\forall x P(x, c, d) \\
\forall x P(c, x, d) \\
$$
Next, let's define a new predicate $Q$ that captures the $xy+z=1$ meaning of $P$. $Q$ is intended to be created as an orthographic abbreviation defined in terms of $P$
$$ Q(x, y, z) \\
\text{if and only if} \\ 
P(x, y, z) \land P(y, x, z) \land \lnot(x=y=z=0) \land \lnot (x=y=z=1) \land (x=1 \land y = 1 \to z=0) $$
We can also define another predicate $E(x, z)$ that captures just the $\exp(x)=z$ meaning.
$$ E(x, z) = P(x, 1, z) \land \lnot (x=z=1) \land \lnot Q(x,1,z) $$
Next, let's define a function $f(x, y) = 1-xy$.
$$ f(x, y) = z \;\; \text{if and only if} \;\; Q(x, y, z) $$
Next, let's define multiplication.
$$ z = x \cdot y \;\; \text{if and only if} \;\; z = f(1, f(x, y)) $$
Then, let's define exponentiation as a function.
$$ z = \exp(x) \;\; \text{if and only if}\;\; z = E(x, z) $$
Now, we can define addition in terms of multiplication and exponentiation
$$ z = x + y \;\; \text{if and only if} \;\; \exp(z) = \exp(x) \cdot \exp(y) $$
So, we have an extremely inconvenient way of talking about the functions $+$ and $\cdot$ ... which means that we can bootstrap our way into an extremely inconvenient statement of the ring axioms and the statement for an exponential map.
A: For infinite rings we can do slightly better than a three-place predicate, namely a single binary operator $\star$:

*

*Require as an axiom that there is a unique element $0$ such that for all $x, y$ we have $x\star 0=y\star 0$.

*Define $a+b = (a \star a) \star (0 \star (b \star b))$.

*Define $a\times b = (0 \star (a \star a)) \star (b \star b)$.

*Insert ring axioms here.

We can construct a working $\star$ for an arbitrary infinite ring $R$ by choosing injections $g, h: R\to R$ such that $R$ is the disjoint sum $\{0\}\uplus g(R)\uplus h(R)$. Then define $\star$ as follows:
$$\begin{array}{c|ccc}
a\star b & a=0 & a=g(x) & a=h(x) \\ \hline
b=0 & g(b) & g(b) & g(b) \\
b=g(y) & h(y) & g(b) & xy \\
b=h(y) & 0 & x+y & g(b) 
\end{array}
$$
The value of $0 \star h(y)$ can be arbitrary.
$g(x)\star g(y)$ or $h(x)\star h(y)$ when $x\ne y$ are not important either.

The downside of this (aside from not working for finite rings at all) is that $\star$ encodes arbitrary choices that are not visible at the ring level. So we can't require ring homomorphism to be maps that are compatible with $\star$ (or define subrings as subsets that are closed under $\star$, etc).

In fact, we can take this style of cheating even further and make do with a single binary relation $\in_R$, if we put $R$ in bijective correspondence with the class of its own one- and two-element subsets, plus a single remaining element. The one- or two-element subsets will allow us to build Kuratowski ordered pairs, and the remaining element (characterized as the only one with more than two $\in_R$-predecessors) will be the set of all $\langle\langle x,y\rangle,\langle x+y, xy\rangle\rangle$.
