I have a functional polynomial expression of the form:
expr = f[x] + f[x] g[w] + Conjugate[f[y]] g[z] + Conjugate[g[z]] + g[w] + f[x] f[y] g[w] + 1 + Conjugate[a] f[t] + Conjugate[b] Conjugate[c]
I would like to write a function that selects terms that are up to linear (i.e. zero and first order) in the functions
g, eg. in my case the correct output would be:
1 + f[x] + Conjugate[g[z]] + g[w] + Conjugate[a] f[t] + Conjugate[b] Conjugate[c]
Note that the functions are complex, and the conjugate terms are also considered. I basically just want to neglect second-order terms and higher.