You can follow the recipe in this answer to use external functions, in this case Python. Create the external file function.py
:
import sys
x=float(sys.argv[1])
i=int(sys.argv[2])
p = 1
for j in range(0,i+1):
p *= x + j - 3
print p
Now in gnuplot you can define the following product and sum functions:
prod(x,i) = real(system(sprintf("python function.py %g %i", x, i)))
f(x) = sum[i=0:int(x)](prod(x,i))
plot[0:3] f(x)

Note that x
needs to be integer to be used to define the limits of the summation. Also note that calling external functions is quite slow.