Dear All
 
I have the following data (somewhat simplyfied):
 
TINF <-1
a <-c(500,750,1000,1250,1500,1750,2000)
b <-c(8,12,18,24,36,48,60,72,96)
 
following function:
 
infcprodessa <-function (D, tin, tau, ts) 
  (D * (1 - exp(-0.048 * tin))/(tin * (0.048*79) * (1 - exp(-0.048 * tau)))) * exp(-0.048 * (ts - tin))

z <-sapply(1:1, function(n) infcprodessa(1000,TINF,12,12-TINF))
 
is there a way to select the combination of respective a and b values that would result in a calculated z that is between 15 and 20? In this case the a would be 1000 and the b would be 12 (other combinations are also possible), but how could I automatically find them? perhaps a loop?
 
Apreciate the help,
 
Sincerely,
 
Andras
	[[alternative HTML version deleted]]

