Is its possible in gnuplot to plot and fit a function that has two variables? For example, a physical function that depends on hight h and Temperature T where the T dependence should only be calculated but not plotted (for f, h and T experimental data exists):
f(h,T) = a * h * (1 + alpha * T) + f0
where a and f0 are to be determined by the fit, alpha is known. In the end I need a plot with f on the y-axis and h on the x-axis. The whole T dependence should be taken care of in the fit, but I don't need it displayed with splot.
The following is what I tried and failed. I assume because one can't set two dummy variables:
set term png;
set output 'test.png';
set dummy h;
set dummy T;
f(h,T) = a * h * (1 + alpha * T) + f0;
fit f(h,T) 'data.txt' using 2:4:1 via a, f0;
plot f(h,T);
gives undefined variable: h. Any ideas?
set dummystuff and just dofit f(x,y) 'data.txt' using 2:4:1:(1) via a,f0?