fyi, a function in Mathematica is defined using _ as in f[w_,x_,y_,z_]:=
. btw, your functions always seem to generate very large values: N@f[1, 1, 1, 1]
gives 1.9489499245*10^21714
which is really a large number. Is there a way you can normalize your function first?