# Formal linear combination/Definition

## Definition

Let [ilmath]S[/ilmath] be a set and let [ilmath]\mathbb{F} [/ilmath] be a field[Note 1], then[1]:

• Informally[Note 2] a formal linear combination is an expression of the form:
• $\lambda_1 s_1 + \lambda_2 s_2 + \cdots + \lambda_{m-1} s_{m-1} + \lambda_m s _m\eq \sum^m_{i\eq 1}\lambda_i s_i$
• for some [ilmath]m\in\mathbb{N} [/ilmath], some [ilmath]\lambda_i\in\mathbb{F} [/ilmath] and some [ilmath]s_i\in S[/ilmath]
• We never actually define [ilmath]\lambda s[/ilmath] (the multiplication of [ilmath]s\in S[/ilmath] by a [ilmath]\lambda\in\mathbb{F} [/ilmath]) nor do we define any sort of "addition" operation, this is simply an expression.
• We want it to behave as a linear combination normally would, i.e.:
1. For example: $\big(\lambda_1 s_1+\lambda_2 s_2\big)+\big(\mu_1 s_1 + \mu_2 s_3 + \mu_3 s_4\big)\eq \alpha s_1 + \lambda_2 s_2 + \mu_2 s_3 + \mu_3 s_4$ say, where [ilmath]\alpha:\eq \lambda_1 + \mu_1[/ilmath] - which is defined as [ilmath]\lambda_i,\mu_j\in\mathbb{F} [/ilmath] remember. And
2. For example: $\mu(\lambda_1 s_1 + \cdots + \lambda_n s_n)\eq \alpha_1 s_ 1 + \cdots + \alpha_n s_n$ where [ilmath]\alpha_i:\eq \mu\lambda_i[/ilmath] - which is defined as [ilmath]\lambda_i,\mu\in\mathbb{F} [/ilmath] of course.
• Even though we can never give it a value
• Formally, a formal linear combination of elements of [ilmath]S[/ilmath] with respect to the field [ilmath]\mathbb{F} [/ilmath] is a function[1]:
• [ilmath]f:S\rightarrow\mathbb{F} [/ilmath] such that [ilmath]\big\vert\{s\in S\ \vert\ f(s)\neq 0\}\big\vert\in\mathbb{N} [/ilmath]Warning:[Note 3], [Note 4] (where [ilmath]\big\vert\cdot\big\vert[/ilmath] denotes cardinality)
• That is to say [ilmath]f[/ilmath] takes non-zero values a finite number of times only, it is zero "almost everywhere"
• [ilmath]f[/ilmath] represents $\sum_{s\in S}f(s)s$ as a linear combination, even if the sum were formally defined to have meaning, we still use the usual abuse of notation when only finitely many elements of the summation are non-zero whereby $\sum_{s\in S}f(s)s$ means $\sum_{\begin{array}{cc}s\in S\\ f(s)\neq 0\end{array} }f(s)s$, hence the requirement that [ilmath]f[/ilmath] only maps finitely many things to non-zero things.

## Notes

1. We could probably step back and define this the same way on a ring, as a field is itself a ring it'd be the same thing. Modules are very similar to vec spaces after all
2. Ignore the "informally a formal ..."
3. Caveat:Be aware that [ilmath]\big\vert\{f(s)\neq 0\ \vert\ s\in S\}\big\vert\in\mathbb{N} [/ilmath] is different to [ilmath]\big\vert\{s\in S\ \vert\ f(s)\neq 0\}\big\vert\in\mathbb{N} [/ilmath] as the first set is the number of non-zero things the function maps to not the number of things that map to non-zero things. For example:
• if we take the function [ilmath]f:\mathbb{N}\rightarrow\mathbb{N} [/ilmath] given by [ilmath]f:n\mapsto\left\{\begin{array}{lr}0 & \text{if }n\text{ is odd}\\ 1 & \text{otherwise}\end{array}\right.[/ilmath] then [ilmath]\big\vert\{f(n)\neq 0\ \vert\ n\in \mathbb{N}\}\big\vert\in\mathbb{N} [/ilmath] indeed holds, as [ilmath]\vert\{1\}\vert\eq 1[/ilmath] however [ilmath]\big\vert\{n\in \mathbb{N}\ \vert\ f(n)\neq 0\}\big\vert\in\mathbb{N} [/ilmath] doesn't hold as the set of even numbers is not finite.
4. Zero here denotes the "additive identity" of the field, [ilmath]\mathbb{F} [/ilmath]