QuCS

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

QuCS

Ahsan Shahid
Hi Richard!
I am interested in development of  QuCS interface for Octave. Can you guide me where to start and what do I have to know for its development?
I can have a few hours spare which I think I can spend on its development.

Regards
-Ahsan
Reply | Threaded
Open this post in threaded view
|

Re: QuCS

Richard Crozier
On 22/10/2013 19:43, Ahsan Shahid wrote:
> Hi Richard!
> I am interested in development of  QuCS interface for Octave. Can you
> guide me where to start and what do I have to know for its development?
> I can have a few hours spare which I think I can spend on its development.
>
> Regards
> -Ahsan

Hi Ahsan,

The qucs developers list may be a better place to discuss this, but the
Octave folk might be interested too (for those who don't know Qucs is a
circuit simulator).

So first what is the status, well, what exists at the moment is a rough
proof of concept of running a qucs circuit simulation from Octave
through a mex interface. This is based on classdef syntax, which is only
present in the classdef branch of the Octave development sources.

There are two ways of running a circuit simulation, asynchronous, which
works, and synchronous, which sort-of works, a bit. In asynchronous
mode, you give qucs two time steps, and it solves the circuit between
these time steps, internally choosing appropriate smaller steps, and
returns the branch voltages and currents at the end.

In synchronous mode, octave is supposed to control all the time steps,
and do the error control, and I intend to use the octave ode solvers for
this.

The generic external interface code, and the octave stuff can be found
in the qucs git repo here:

http://sourceforge.net/p/qucs/git/ci/master/tree/qucs-core/src/interface/

I have a script that runs an example circuit using the interface, but
this is not in the repo and not convenient for me right now, but I can
send (or upload) it later if you are still interested.

Building the interface is unfortunately not very streamlined yet. At the
moment you must build the qucs-core development sources as normal using
maintainer mode, then I have used a code::blocks file to create a static
library (libqucsatorfull.a) for linking with the mex interface. It's all
very involved, but if you are still interested in helping I can provide
you with more help and information and try and improve it. There's a lot
to do.

Incidentally, if you just want the final output of the circuit and don't
care what happens during simulation till the end there are existing
function to load qucs output into Octave. The aim of the interface is to
ultimately change circuit parameters during simulation etc.

Richard




--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.

Reply | Threaded
Open this post in threaded view
|

Re: QuCS

Ahsan Shahid
Hi Richard!
Yeah I am definitely interested in this project.
I think I should first try out some examples to get a feel of what has already been done. I want to see the script that runs the example circuit. I also need some info what do I have to learn to get involved in this project from where should I get started.  So if you guide me what is needed  to be done , I will eventually become more comfortable with this and will help out with this project in much better way.

Regards
Ahsan


On Wed, Oct 23, 2013 at 1:36 AM, Richard Crozier <[hidden email]> wrote:
On 22/10/2013 19:43, Ahsan Shahid wrote:
Hi Richard!
I am interested in development of  QuCS interface for Octave. Can you
guide me where to start and what do I have to know for its development?
I can have a few hours spare which I think I can spend on its development.

Regards
-Ahsan

Hi Ahsan,

The qucs developers list may be a better place to discuss this, but the Octave folk might be interested too (for those who don't know Qucs is a circuit simulator).

So first what is the status, well, what exists at the moment is a rough proof of concept of running a qucs circuit simulation from Octave through a mex interface. This is based on classdef syntax, which is only present in the classdef branch of the Octave development sources.

There are two ways of running a circuit simulation, asynchronous, which works, and synchronous, which sort-of works, a bit. In asynchronous mode, you give qucs two time steps, and it solves the circuit between these time steps, internally choosing appropriate smaller steps, and returns the branch voltages and currents at the end.

In synchronous mode, octave is supposed to control all the time steps, and do the error control, and I intend to use the octave ode solvers for this.

The generic external interface code, and the octave stuff can be found in the qucs git repo here:

http://sourceforge.net/p/qucs/git/ci/master/tree/qucs-core/src/interface/

I have a script that runs an example circuit using the interface, but this is not in the repo and not convenient for me right now, but I can send (or upload) it later if you are still interested.

Building the interface is unfortunately not very streamlined yet. At the moment you must build the qucs-core development sources as normal using maintainer mode, then I have used a code::blocks file to create a static library (libqucsatorfull.a) for linking with the mex interface. It's all very involved, but if you are still interested in helping I can provide you with more help and information and try and improve it. There's a lot to do.

Incidentally, if you just want the final output of the circuit and don't care what happens during simulation till the end there are existing function to load qucs output into Octave. The aim of the interface is to ultimately change circuit parameters during simulation etc.

Richard




--
The University of Edinburgh is a charitable body, registered in
Scotland, with registration number SC005336.