I need some helps on NDSolve. Here are my equations:
k1 = 0.000192;
k2 = 0.000159;
Clear[x, y, z, h]
eqnf1 = {x'[t] == -k1*x[t]*y[t]/h[t] + k2*z[t],
y'[t] == 3*(-k1*x[t]*y[t]/h[t] + k2*z[t]),
z'[t] == k1*x[t]*y[t]/h[t] - k2*z[t],
h'[t] == -3*(-k1*x[t]*y[t]/h[t] + k2*z[t]),
x[0] == .001, z[0] == 0, y[0] == 0.2, h[0] == .001};
sol2 = NDSolve[eqnf1, {x, y, z, h}, {t, 0, 1000}][[1]]
X[t_] = x[t] /. sol2;
Y[t_] = y[t] /. sol2;
Z[t_] = z[t] /. sol2;
H[t_] = h[t] /. sol2;
I used this part to solve y[t], which will be using later for my other function. And here is 2nd part of my function:
Da = 1.33*10 - 4;
eqnm1 = {D[yc[x, t], {t, 1}] ==
Da* D[ D[yc[x, t], {x, 1}], {x, 1}] ,
yc[x, 0] == 0,
yc[0, t] == Z[t], (D[yc[x, t], {x, 1}] /. x -> 1) == 0};
solmem1 =
First[yc /. NDSolve[eqnm1, yc, {x, 10^-20, 1}, {t, 0, 1000}]]
Here I obtained another interpolating function, yc[x,t], which will be used in the last part of the problem that I'm not able to solve. The last part of the problem needs function from the 1st and 2nd parts - y[t] & yc[x,t] which both are interpolating functions. And the 3rd part is only 1D function, which is xs[t]. I tried
eqns1 = {xs'[t] == -k1*xs[t]*First[Evaluate[y[t] /. eqnf1]]/hs[t] +
k2*First[Evaluate[yc[x, t] /. x -> 1 /. solmem1]],
hs'[t] == -3*(-k1*xs[t]*First[Evaluate[y[t] /. eqnf1]]/hs[t] +
k2*First[Evaluate[yc[x, t] /. x -> 1 /. solmem1]]),
xs[0] == 0, hs[0] == 1};
But it has some errors that I think is caused by the 2nd part of the problem that is 2-D (ys[x,t]). Does anyone know how to solve xs(t) and hs(s)? TThanks

