Andre Luis Alves Neves

MaplePrimes Activity


These are questions asked by Andre Luis Alves Neves

Hello,

I am generating a code to describe how drug dosages (starting from 1 until dosage 2) are metabolized by the body.

The plot looks weird becasue it does not start from C0 = 4. I don't know how to set t=L so that C0 starts at 4. I suspect that I am misssing something in the piecewise function?  

My code is the follwoing:

C0 := 4;
k := 0.2;
L := 1;
C := t -> C0*(1 + exp(-k*L))*exp(-k*(t - L));
L := piecewise(L <= t and t < 2*L, 0, C(t));

plot(C(t), t = 1 .. 10) 

Thanks,

Andre

Hello,

How do I isolate the variable ng in the following expression:

rho := `&rho;g`*ng + `&rho;p`*np + `&rho;w`*nw;
B := np/Kp + nw/Kw + ng/Kg;

C := (B/rho)^(1/2);

As you can see, I am running the isolate command, but it is not including the variable C, or it returns the wrong result.

isolate(((np/Kp + nw/Kw + ng/Kg)/(`&rho;g`*ng + `&rho;p`*np + `&rho;w`*nw))^(1/2), ng);
                               ( Kp nw + Kw np) Kg
                   ng = -     -----------------

                                          Kw Kp       

 

isolate(C=((np/Kp + nw/Kw + ng/Kg)/(`&rho;g`*ng + `&rho;p`*np + `&rho;w`*nw))^(1/2), ng);
                             0 = 0

Thanks.                

Page 1 of 1