I am new to Mathematica I have a simple question.
I have the following definition:
f[i_,j_] := Integrate[KroneckerDelta[i, j] - ki * kj + Exp[-(kx^2+ky^2)],
{kx, 0, 10}, {ky, 0, 100}]
I would like to write it in a way that if I call f[x,x]
it would compute:
f[x,x] = Integrate[KroneckerDelta[x, x] - kx * kx + Exp[-(kx^2+ky^2)],{kx, 0,
10}, {ky, 0, 100}]
or if I call f[x,y]
it returns:
f[x,y] = Integrate[KroneckerDelta[x, y] - kx * ky + Exp[-(kx^2+ky^2)],{kx, 0,
10}, {ky, 0, 100}]`
f[x_] := A^2 x^2
andf[b_, q_] := A^2 b q
? $\endgroup$f[a_, b_: 0] := 10^(a + b)
. Or why do you even need such a "function"? $\endgroup$