I have two functions
funk1 <- (t,a,b,c) { a* exp(-k*t)* b* exp(-c*t) }
funk2 <- (t,a,b,c) { (A*t^k +a)* b* exp(-c*t) }
where, k and A are known.
I am trying to estimate parameters a,b,c by fitting these two functions funk1 & funk2 simultaneously to two different data-sets Y1 & Y2 respectively.
Y1 <- seq(5*10^7, 1*10^7, -2*10^5)
Y2 <- seq(0.01, 0.85, 0.0042)
I am using Optim to fit the models by maximising joint likelihood. But the parameter values I am getting are pretty un-realistic. (I think optimiser wandering in wrong directions and finding local maxima and I can't use a gradient function.)
I wish to use nls() to fit these two functions to respective data-sets, 'simultaneoulsy'. I am not sure how to do it?
Thanks in advance.