I want to calculate the hamming weight of a S-Box using this formula: $\text{hw}(f) = \sum_{x=0}^{2^n-1} f(x)$. Where $f: \{0, 1\}^n \rightarrow \{0, 1\}$
My problem is that I don't know how to get the $f$-function.
I found that helpful paper: THE DESIGN OF S-BOXES. At Page 9 (18) boolean functions are described. But she only prints the truth table (Table 2.1) without describing her $f$-function. She only says $f$ is a linear function, therefore I think $f$ depends on my S-Box?
For example, if I have this $2 \times 2$ S-Box:
0 1 2 3
1 3 0 2
$00 \rightarrow 01\\ 01 \rightarrow 11\\ 10 \rightarrow 00\\ 11 \rightarrow 10$
What are the $f$-functions and what is the hamming weight?