‘But I want to use a vector "f" insted of a single number to have a vector of "TL" values.’
I cannot run that because there are insufficient data provided, and the online Run feature is currently down for scheduled maintenance.
Otherwise, the integral2 function cannot integrate arrays, although integral can. The way to deal with that problem with respect to a double integral is essentially:
fcn = @(x,y) sin(2*pi*f.*x) .* exp(0.1*f.*y);
int2 = integral(@(y) integral(@(x) fcn(x,y), 0, 1, 'ArrayValued',1), -1, 0, 'ArrayValued',1);
This returns a vector the size of ‘f’.