Find linerarly independent vectors in subalgebra We have a finite set $K$ and a family of real valued functions $\mathcal{F}$ such that:


*

*if $f,\ g\in \mathcal{F}$ then $f+g\in \mathcal{F},\ f\cdot g \in \mathcal{F}$ and for all $\lambda\in \mathbb{R},\ \lambda f\in \mathcal{F}$

*for all $x,y\in K$ such that $x\neq y$ there exists $f\in \mathcal{F}$ such that $f(x)\neq f(y)$

*for all $x\in K$ there exists $f$ such that $f(x)\neq 0$
We want to show that $\mathcal{F}$ contains every function $g:K\rightarrow \mathbb{R}$.
We see that since $|K|=n$, the set of all functions from $K$ to $\mathbb{R}$ is simply $\mathbb{R}^n$, namely the set of tuples $(x_1, x_2,\ldots,x_n)$.
For $|K|=1$ we have that from property 3 that there exists an element $(x)\in \mathcal{F}$ such that $x\neq 0$, so $\frac{1}{x}\cdot(x)=(1)\in \mathcal{F}$, so then we can simply multiply $1$ by any real number to obtain that $\mathcal{F} = \mathbb{R}$. I am trying to prove that $\mathcal{F}$ contains a basis of $\mathbb{R}^n$ for general $n$. 
Am I approaching this the right way? Is there another solution?
 A: We may assume that $K=\{1,2,\dots,n\}$. Let $\mathcal{G}$ be the set of functions 
$$
\mathcal{G}=\{f|_{\{1,2,\dots,n-1\}}: f\in \mathcal{F}\},
$$
i.e. the restrictions of every function in $\mathcal{F}$ to $\{1,2,\dots,n-1\}$. Then certainly $\mathcal{G}$  satisfies all properties above, so it consists of all functions from $\{1,2,\dots,n-1\}$ to $\mathbb{R}$. In particular, the indicator functions 
$$
\delta_i:\delta_i(j)=\begin{cases}1\text{ if }i=j\\0\text{ else}\end{cases}
$$
lie in $\mathcal{G}$. By definition, these came from the restrictions of $f_i:\{1,2,\dots,n\}\to\mathbb{R}$.
Thus $\mathcal{F}$ contains $n-1$ functions $f_i$ which vanish on all but at most two coordinates.
Case 1: $f_i(n)=0$ for all $i$. Then choose a function $f_n$ for which $f_n(n)\neq 0$ (this must exist in $\mathcal{F}$ by our assumptions), and show $f_1,\dots,f_n$ span all functions from $K$ to $\mathbb{R}$.
Case 2: $f_i(n)=1$ for all $i$. If $n=2$, then you can easily deal with this case using (2). If $n>2$, then let $g=f_1+f_2$. Then $g\cdot g$ is of the form $(1,1,0,\dots,0,2)$, so that $g\cdot g-f_1-f_2$ is of the form $(0,\dots,0,2)$, and again you can finish.
Case 3: $f_i(n)\not \in \{0,1\}$ for some $i$. Then $f_i\cdot f_i-f_i$ is again of the form $(0,\dots,0,c)$, and again you can finish.
