Prev: I want to create a m-file by command: edit filename. something wrong!
Next: Overlapping Circular Area Problem
From: p on 14 Apr 2010 12:53 I have a differential dI/dz which depends on I(t,z) and N(t,z). I(t,z) and N(t,z) are vectors with varying element values...ie. their initial conditions are also vectors. The ODE's only want conditions with single element vectors. Any suggestions to functions or methods for this problem?
From: Jan Simon on 14 Apr 2010 15:14 Dera p! > I have a differential dI/dz which depends on I(t,z) and N(t,z). > I(t,z) and N(t,z) are vectors with varying element values...ie. their initial conditions are also vectors. > > The ODE's only want conditions with single element vectors. Any suggestions to functions or methods for this problem? Please read the documentation of e.g. ODE45. The inputs Y0 and P1, P2, ... can be vectors also. Good luck, Jan
From: p on 15 Apr 2010 05:27 "Jan Simon" <matlab.THIS_YEAR(a)nMINUSsimon.de> wrote in message <hq545s$e7d$1(a)fred.mathworks.com>... > Dera p! > > > I have a differential dI/dz which depends on I(t,z) and N(t,z). > > I(t,z) and N(t,z) are vectors with varying element values...ie. their initial conditions are also vectors. > > > > The ODE's only want conditions with single element vectors. Any suggestions to functions or methods for this problem? > > Please read the documentation of e.g. ODE45. The inputs Y0 and P1, P2, ... can be vectors also. > > Good luck, Jan You are right that the inputs Y0, P1 etc are vectors, but if you have two functions I(t,z) and N(t,z) then the vector length for Y0 must only have 2 elements (1 for each function)... my issue is that each function I(t,z) and N(t,z) have a hundred elements each so no ODE solver can be used directly.
From: Torsten Hennig on 15 Apr 2010 02:05
> "Jan Simon" <matlab.THIS_YEAR(a)nMINUSsimon.de> wrote > in message <hq545s$e7d$1(a)fred.mathworks.com>... > > Dera p! > > > > > I have a differential dI/dz which depends on > I(t,z) and N(t,z). > > > I(t,z) and N(t,z) are vectors with varying > element values...ie. their initial conditions are > also vectors. > > > > > > The ODE's only want conditions with single > element vectors. Any suggestions to functions or > methods for this problem? > > > > Please read the documentation of e.g. ODE45. The > inputs Y0 and P1, P2, ... can be vectors also. > > > > Good luck, Jan > > You are right that the inputs Y0, P1 etc are vectors, > but if you have two functions I(t,z) and N(t,z) then > the vector length for Y0 must only have 2 elements (1 > for each function)... my issue is that each function > I(t,z) and N(t,z) have a hundred elements each so no > ODE solver can be used directly. Let Y = (I1,I2,I3,...,I_end,N1,N2,...,N_end) ... Best wishes Torsten. |