On 23 May 2009, at 00:00, [email protected] wrote: > Octave developers, > I am writing a circuit simulator for octave and matlab, in > order to release the > source code as an octave-forge package. Currently I am > stuck at transient analysis > algorithm. I already implemented a simplicistic > explicit-euler integrator which > works, but unfortunately euler is the worst > algorithm both for stability and accuracy. > So, I thought of using ode solvers > available both for octave and matlab in order to > obtain better performances. >
This is all implemented in the OCS package which you can find at http://octave.sourceforge.net/ocs/index.html > Transient analysis is an initial value problem, described by a set of > differential algebraic equation as follows: > > M(x) * x' = u(t) - A(x) > > where > state-dependence of the mass matrix M comes substantially from > junction > depletion capacitances. > > In matlab I used ode15s and ode23t with no problems. > > Unfortunately none of the available solvers for octave seems to handle > state- > dependence of mass-matrix M. Actually DASPK and DASSL do allow for time dependent mass matrix. And a mex implementation of IDA is available from the sundials website. OCS has interfaces to all of these DAE solvers, look at the inst/TST directory in the source code. Anyway, by writing down the MNA equations in a clever way you can obtain a constant mass matrix in almost all practical cases. > I thought about using an implicit ode solver, > but in that case I should specify > the derivative of the solution that is really > unknown. Could I use a constant mass-matrix > solver for a short timestep and > then shift to an implicit solver? > > Reading the OdePkg help I found the solver > mebdefv from Jeff Cash, that suits my needs > ( http://www.ma.ic.ac. > uk/~jcash/IVP_software/vtest/mebdfv.f ) > but, even if i were able to write an > octave wrapper to that function, I am afraid > this is not licensed under GPL, so > it couldn't be included in any octave package. > I wasn't able to find anything > else useful. > > So, can someone help me? > > Marco Merlin there's lots of space for improvement in OCS (especially wrt more advanced device models and standard netlist format pasers), if instead of starting your own independent project from scratch you would like to build on the work already done for implementing OCS that would be greatly appreciated. c. ------------------------------------------------------------------------------ Register Now for Creativity and Technology (CaT), June 3rd, NYC. CaT is a gathering of tech-side developers & brand creativity professionals. Meet the minds behind Google Creative Lab, Visual Complexity, Processing, & iPhoneDevCamp asthey present alongside digital heavyweights like Barbarian Group, R/GA, & Big Spaceship. http://www.creativitycat.com _______________________________________________ Octave-dev mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/octave-dev
