Re: POLY in ng-spice

From: betula electronique (betula_at_aldebaran.systems)
Date: 01/27/05


Date: Thu, 27 Jan 2005 20:15:58 +0100

Le Thu, 27 Jan 2005 10:36:12 +0000, Charles DH Williams a écrit :

> In article <pan.2005.01.27.08.44.26.26716@mynewserverposfix.com>,
> habib bouaziz-viallet <habib@mynewserverposfix.com> wrote:
>
>> Le Wed, 26 Jan 2005 23:40:55 +0000, Stuart Brorson a écrit :
>>
>> > habib bouaziz-viallet <habib@mynewserverposfix.com> wrote:
>> > : Hi all,
>> >
>> > : POLY() sources constructions does not work from within ng-spice even
>> > : spice3f5.
>> >
>> > : Any method to fix it ?
>> >
>> > Please post your troublesome netlist and an accompanying session log.
>> >
>> > Also, which version of ngspice are you using?
>> >
>> > Stuart
>
> The MacSpice transplation of the polys() is:
> ===============================================================
> MacSpice 5 -> source Test
>
> Circuit: test
>
> Note -- MacSpice converts spice2 'polys' to spice3 'B' sources,
> use 'listing physical expand' to inspect the result(s).
> Note -- Line 2 spice2 'poly' source converted.
> Note -- Line 3 spice2 'poly' source converted.
> MacSpice 6 -> listing physical expand
> test
>
> 1 : test
> 2 : *egnd 99 0 poly(2) (3,0) (4,0) 0 .5 .5
> 2 : bsp2_egnd 99 0 v=(0+v(3)*.5+v(4)*.5)
> 3 : *fb 7 99 poly(5) vb vc ve vlp vln 0 7e6 -1e3 1e3 6e6 -6e6
> 3 : bsp2_fb 7 99 i=(0+i(vb)*7e6+i(vc)*(-1e3)+i(ve)*1e3+i(vlp)*6e6+i(vln)*(-6e6))
> ------ : .end
> MacSpice 7 ->
> ===============================================================
>
> I suspect that the problem with ngspice is caused by using (,) as
> separators which which confuse the ngspice tokeniser into thinking that
> (3,0) is a single token. Try instead:
>
> egnd 99 0 poly(2) 3 0 4 0 0 .5 .5
>
> Charles

Thanks Charles,

This very .cir description works well with spice-opus
http://www.fe.uni-lj.si/spice/welcome.html

and not (for the moment) with ng-spice 1.5. May be Xspice extensions not
may not work with ... it's very surprising, mmmh...!

Habib