Prev: date on x axis feather plot
Next: Need Help Attempted to access hx(0,0); index must be a positive integer or logical.
From: Alina Stoian on 16 Jun 2010 02:07 Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote in message <1219076111.346913.1276584486604.JavaMail.root(a)gallium.mathforum.org>... > > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote > > in message > > <9593155.331588.1276528402857.JavaMail.root(a)gallium.ma > > thforum.org>... > > > Hi Alina, > > > > > > Let's compare our results: > > > > > > At which times did you output the concentrations > > listed > > > in you last mail, and to which h-values do they > > > belong ? > > > > > > Best wishes > > > Torsten. > > > > Hello, > > I specified in tspan to output the results at each > > 3600 s ! So I displayed the values of the liquid > > concentration at each volume center (I remind you > > that I devised the liquid volume in 10 , and that the > > heights are all equal to 3e-4). > > Best regards, > > A. Stoian > > Hi Alina, > > tightening the tolerances for rtol and atol to a very > small value (1e-11) keeps concentrations positive > with my solver. > To be sure about the results, you should make a second > calculation with a finer grid (maybe 5 times the number > of points in each compartment). > > Best wishes > Torsten. Hello, I tried what you told me and seems that it works, but I gave it to compute until 24*3600 s and not until 48*3600 s ( this is my finish time) because it is taking a lot of time to compute the solution. Therefore I didn't yet had the time to refine my grid! What can I do to make it compute much faster ? Best regards, A. Stoian
From: Torsten Hennig on 15 Jun 2010 23:06 > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote > in message > <1219076111.346913.1276584486604.JavaMail.root(a)gallium > .mathforum.org>... > > > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> > wrote > > > in message > > > > <9593155.331588.1276528402857.JavaMail.root(a)gallium.ma > > > thforum.org>... > > > > Hi Alina, > > > > > > > > Let's compare our results: > > > > > > > > At which times did you output the > concentrations > > > listed > > > > in you last mail, and to which h-values do they > > > > belong ? > > > > > > > > Best wishes > > > > Torsten. > > > > > > Hello, > > > I specified in tspan to output the results at > each > > > 3600 s ! So I displayed the values of the liquid > > > concentration at each volume center (I remind you > > > that I devised the liquid volume in 10 , and that > the > > > heights are all equal to 3e-4). > > > Best regards, > > > A. Stoian > > > > Hi Alina, > > > > tightening the tolerances for rtol and atol to a > very > > small value (1e-11) keeps concentrations positive > > with my solver. > > To be sure about the results, you should make a > second > > calculation with a finer grid (maybe 5 times the > number > > of points in each compartment). > > > > Best wishes > > Torsten. > > Hello, > > I tried what you told me and seems that it works, but > I gave it to compute until 24*3600 s and not until > 48*3600 s ( this is my finish time) because it is > taking a lot of time to compute the solution. > Therefore I didn't yet had the time to refine my > grid! What can I do to make it compute much faster ? > > > Best regards, > A. Stoian Hi Alina, if you compare the results obtained with an error tolerance of 1e-6 and 1e-11, I think you will see no big difference. At least for me it would be no problem to interprete 'negative' concentrations in an order of magnitude of about -1e-6 as 0. I think it's much more important to check results obtained on grids of different size. In order to make these computations faster, you could try the following: Usually the ODE solver has to calculate and factorize the Jacobian matrix in each time step. Because your Jacobian matrix is _constant_ over time, there should be an option within the ODE solver to supply the Jacobian once and for all times. By the way: I solved your system with 10 times the number of grid points in each compartment, and the simulation took about 30 seconds. The program I use is reliable, but it's written in FORTRAN. If you have a FORTRAN 90 compiler available, I could send it to you and you could give it a try. Best wishes Torsten.
From: Alina Stoian on 16 Jun 2010 05:27 Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote in message <503067907.352469.1276672009516.JavaMail.root(a)gallium.mathforum.org>... > > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote > > in message > > <1219076111.346913.1276584486604.JavaMail.root(a)gallium > > .mathforum.org>... > > > > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> > > wrote > > > > in message > > > > > > <9593155.331588.1276528402857.JavaMail.root(a)gallium.ma > > > > thforum.org>... > > > > > Hi Alina, > > > > > > > > > > Let's compare our results: > > > > > > > > > > At which times did you output the > > concentrations > > > > listed > > > > > in you last mail, and to which h-values do they > > > > > belong ? > > > > > > > > > > Best wishes > > > > > Torsten. > > > > > > > > Hello, > > > > I specified in tspan to output the results at > > each > > > > 3600 s ! So I displayed the values of the liquid > > > > concentration at each volume center (I remind you > > > > that I devised the liquid volume in 10 , and that > > the > > > > heights are all equal to 3e-4). > > > > Best regards, > > > > A. Stoian > > > > > > Hi Alina, > > > > > > tightening the tolerances for rtol and atol to a > > very > > > small value (1e-11) keeps concentrations positive > > > with my solver. > > > To be sure about the results, you should make a > > second > > > calculation with a finer grid (maybe 5 times the > > number > > > of points in each compartment). > > > > > > Best wishes > > > Torsten. > > > > Hello, > > > > I tried what you told me and seems that it works, but > > I gave it to compute until 24*3600 s and not until > > 48*3600 s ( this is my finish time) because it is > > taking a lot of time to compute the solution. > > Therefore I didn't yet had the time to refine my > > grid! What can I do to make it compute much faster ? > > > > > > Best regards, > > A. Stoian > > > Hi Alina, > > if you compare the results obtained with an error > tolerance of 1e-6 and 1e-11, I think you will see > no big difference. At least for me it would be no > problem to interprete 'negative' concentrations > in an order of magnitude of about -1e-6 as 0. > > I think it's much more important to check results > obtained on grids of different size. > In order to make these computations faster, you could > try the following: > > Usually the ODE solver has to calculate and > factorize the Jacobian matrix in each time step. > Because your Jacobian matrix is _constant_ over time, > there should be an option within the ODE solver > to supply the Jacobian once and for all times. > > By the way: > I solved your system with 10 times the number of grid > points in each compartment, and the simulation took > about 30 seconds. > The program I use is reliable, but it's written in > FORTRAN. If you have a FORTRAN 90 compiler available, > I could send it to you and you could give it a try. > > Best wishes > Torsten. Hello, Thank you very much for your time and help....it worked :D ! With a defined constant Jacobian matrix it computes really fast and using a finer mesh it arrives to do it in max 3 minutes! So once more.... THANKS ! Best regards, Alina Stoian
From: Torsten Hennig on 16 Jun 2010 03:46
> Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> wrote > in message > <503067907.352469.1276672009516.JavaMail.root(a)gallium. > mathforum.org>... > > > Torsten Hennig <Torsten.Hennig(a)umsicht.fhg.de> > wrote > > > in message > > > > <1219076111.346913.1276584486604.JavaMail.root(a)gallium > > > .mathforum.org>... > > > > > Torsten Hennig > <Torsten.Hennig(a)umsicht.fhg.de> > > > wrote > > > > > in message > > > > > > > > > <9593155.331588.1276528402857.JavaMail.root(a)gallium.ma > > > > > thforum.org>... > > > > > > Hi Alina, > > > > > > > > > > > > Let's compare our results: > > > > > > > > > > > > At which times did you output the > > > concentrations > > > > > listed > > > > > > in you last mail, and to which h-values do > they > > > > > > belong ? > > > > > > > > > > > > Best wishes > > > > > > Torsten. > > > > > > > > > > Hello, > > > > > I specified in tspan to output the results > at > > > each > > > > > 3600 s ! So I displayed the values of the > liquid > > > > > concentration at each volume center (I remind > you > > > > > that I devised the liquid volume in 10 , and > that > > > the > > > > > heights are all equal to 3e-4). > > > > > Best regards, > > > > > A. Stoian > > > > > > > > Hi Alina, > > > > > > > > tightening the tolerances for rtol and atol to > a > > > very > > > > small value (1e-11) keeps concentrations > positive > > > > with my solver. > > > > To be sure about the results, you should make a > > > second > > > > calculation with a finer grid (maybe 5 times > the > > > number > > > > of points in each compartment). > > > > > > > > Best wishes > > > > Torsten. > > > > > > Hello, > > > > > > I tried what you told me and seems that it works, > but > > > I gave it to compute until 24*3600 s and not > until > > > 48*3600 s ( this is my finish time) because it is > > > taking a lot of time to compute the solution. > > > Therefore I didn't yet had the time to refine my > > > grid! What can I do to make it compute much > faster ? > > > > > > > > > Best regards, > > > A. Stoian > > > > > > Hi Alina, > > > > if you compare the results obtained with an error > > tolerance of 1e-6 and 1e-11, I think you will see > > no big difference. At least for me it would be no > > problem to interprete 'negative' concentrations > > in an order of magnitude of about -1e-6 as 0. > > > > I think it's much more important to check results > > obtained on grids of different size. > > In order to make these computations faster, you > could > > try the following: > > > > Usually the ODE solver has to calculate and > > factorize the Jacobian matrix in each time step. > > Because your Jacobian matrix is _constant_ over > time, > > there should be an option within the ODE solver > > to supply the Jacobian once and for all times. > > > > By the way: > > I solved your system with 10 times the number of > grid > > points in each compartment, and the simulation took > > > about 30 seconds. > > The program I use is reliable, but it's written in > > FORTRAN. If you have a FORTRAN 90 compiler > available, > > I could send it to you and you could give it a try. > > > > Best wishes > > Torsten. > > Hello, > > Thank you very much for your time and help....it > worked :D ! With a defined constant Jacobian matrix > it computes really fast and using a finer mesh it > t arrives to do it in max 3 minutes! So once more.... > THANKS ! > Best regards, > Alina Stoian Avec plaisir. Best wishes Torsten. |