my main problem is that, i don't understand what argmax means in this equation (page 134., figure 4., the output part)
I want to write a code, but i don't understand this equation. Is there any simpler form of this equation ? (maybe an example)
This is how i understand it: 1. i count the sum first 2. i find the argmax
Sorry for my dummy question, but i am not realy good in this area. Thanks for your answers !
$\endgroup$ 32 Answers
$\begingroup$Lets say we have a funktion $f(x) = -(x-2)^2 + 3$, which has a global maximum at $x_0=2$ with $f(x_0)=3$.
This means that $\max(f) = 3$. $\arg\!\max$ answers not how high the maximum is, but where it occurs: $\arg\!\max(f) = 2$.
Note that $f(\arg\!\max(f)) = \max(f)$.
$\endgroup$ 1 $\begingroup$In general $$x^*=\arg \max_x f(x) $$ means return $x$ that maximizes $f(x)$.
How to find $x^*$? 1) Find $f(x)$ for all possible values of $x$ as $\{x_n,\,f(x_n)\}$. 2) Find the maximum value of $f(x)$ in the set $\{f(x_n)\}$, let's denote it by $f(x_\max)$. 3) return $x_\max$.
You don't have to store all values. You can start by saying that $x_\max=x_1,\,f_\max=f(x_1)$. Then if $f(x_2)>f_\max$ update the values as $x_\max=x_2,\,f_\max=f(x_2)$. If not, keep the previous values. When all the possible values of $x$ are considered, your $x_\max$ at the end will be the value you are looking for.
Apply this to your situation.
$\endgroup$