If $\ ref(A)= \begin{bmatrix} 1 & 1 & 1 \\ 0&1&1 \\ 0&0&1 \\ 0&0&0 \end{bmatrix}$, then the only solution to $\begin{bmatrix} 1 & 1 & 1 \\ 0&1&1 \\ 3&1&0 \\ 0&2&1 \end{bmatrix} \begin{bmatrix} x_1\\x_2 \\x_3 \end{bmatrix}= \begin{bmatrix} 0\\0 \\0\\0 \end{bmatrix}$ is the zero
vector, which is never a member of any spanning set. Thus, the kernel has dimension zero. By the rank-nullity theorem, $dim(im(A))+dim(ker(A))=3.$ Thus, the image has dimension three. Notice that each column of the row reduced matrix has a pivot. Then the range is the span of $\Big\{\begin{bmatrix} 1\\0 \\3\\0 \end{bmatrix},\begin{bmatrix} 1\\1 \\1\\2 \end{bmatrix},\begin{bmatrix} 1\\1 \\0\\1 \end{bmatrix} \Big\}$
There are multiple errors/unclear parts in your question. I'm not very sure what the set $K$ is, so I will be assuming it's the field $\mathbb{R}$.
Also, the codomain of $f$ seems to be $K^2$ rather than $K^3$, so I assume $f:V \to K^3$ was a typographic error on your part.
Now, a "matrix representation of a linear transformation $g:A \to B$" only makes sense when we're given specific ordered bases of $A$ and $B$. You gave us $B_{K_2}=(e_1,e_2)$ for $K^2$ but ordered the basis of $V$ with respect to which we will find the matrix representation is not very clear. I will assume it is the ordered basis $B_{V}=((1,1,0),(-2,0,1))$.
I will assume that you are familiar with the theory behind matrix representations of a linear transformation and I will simply find the representation. If anything within this process is unclear, just let me know.
First, we will find the images of elements of $B_V$ under $f$, expressed as linear combinations of elements of $B_{K^2}$.
$$f(1,1,0)=(1-0,1-3 \cdot 0)=(1,1)=1 \cdot (1,0) + 1\cdot (0,1) = \textbf{1} \cdot e_1 + \textbf{1} \cdot e_2$$
$$f(-2,0,1)=(-2-1,0-3\cdot 1)=(-3,-3)=(-3) \cdot(1,0) + (-3) \cdot (0,1) = \textbf{(-3)} \cdot e_1 + \textbf{(-3)} \cdot e_2$$
Now, we will simply take the coefficients written in bold and place them in our representation matrix. Remember, the i-th column represents the coefficients of the linear combination of the i-th element of $B_V$ in terms of the elements of $B_{K^2}$.
$$[f]^{B_V}_{B_{K^2}}= \begin{bmatrix}
1 & -3 \\
1 & -3
\end{bmatrix}$$
Best Answer
Here is the more general setting.
Let $V$ (resp. $W$) be an $n$ (resp. $m$) dimensional vector space over $\mathbb{F}$. Let $\alpha=(v_1,\cdots,v_n)$ be an ordered basis in $V$ and $\beta=(w_1,\cdots,w_m)$ an ordered basis in $W$.
In your question, $V=U$ and $W=\mathbb{F}^3$. You have found $\alpha$. Note that $\beta$ is given. Also, $n=2$ and $m=2$.
For any vector $x\in V$, denote its coordinate w.r.t. the basis $\alpha$ as $ [x]_\alpha=(x_1,\cdots,x_n)^T $ and for any vector $y\in W$, denote its coordinate w.r.t. the basis $\beta$ as $ [y]_\beta=(y_1,\cdots,y_m)^T. $
So what are the steps to find $[T]^\alpha_\beta$?
For the very last step, you need to know how to find $[z]_{\beta}$ given $z\in W$. Suppose $[z]_\beta=(z_1,\cdots,z_m)^T$ Then by the definition of coordinates: $$ z=\sum_1^m z_iw_i $$ which essentially gives you a linear equation about the $z_i$'s.