I have a question from Pollack and Guillemin's book: let $X$ be a smooth manifold. $f:X\to \mathbb R^n$ an immersion, $f=(f_1,....f_n)$. show that for almost all $a_1,...,a_n$, the function $a_1f_1+.....a_nf_n$ is a morse function on $X$. I know so far that if the thm. is true locally it will be true because I can get countable open cover for $X$ but I can't prove it yet. the hint says to read the proof for the case X sits inside R^k but I don't understand the proof. I would like for some help,
I add a link for it : http://www.cs.unicam.it/piergallini/home/materiale/geom4/testi/Guillemin-Pollack:Differential%20topology.pdf the question is in page 48 question 21. the proof is in page 43-44, thanks