Why can two functions represent the same preferences? I wonder why two functions can represent the same preferences?
Suppose I strictly prefer Apple ($A$) to Banana ($B$) and that these are the only two goods in existence.

Consider the following functions:†


The function $u$ with $u(A)=1$, $u(B)=0$.
The function $v$ with $v(A)=-99$, $v(B)=-100$.
The function $w$ with $w(A)=0.1$, $w(B)=0.01$.


Each of the above functions correctly represents my preference because in each case, the function's value at $A$ exceeds that at $B$.

A utility function (representation) is merely a (very) convenient way to numerically encode my preference. Here there are only two goods and I prefer $A$ to $B$. So, any function whose value at $A$ is greater than that at $B$ would correctly represent my preference.

In this example, we have only two goods, so a utility function isn't particularly useful or convenient.

But with more goods (and sometimes also more assumptions), utility functions can help to produce useful results that tell us something about the real world.



†Real-valued, with domain $\{A,B\}$.