Subject: RE: Infinity in Verilog-AMS
From: Martin O'Leary (oleary@cadence.com)
Date: Tue Apr 29 2003 - 17:06:08 PDT
Geoffrey
> -----Original Message-----
> From: Geoffrey.Coram [mailto:Geoffrey.Coram@analog.com]
> Sent: Tuesday, April 29, 2003 10:30 AM
> To: Martin O'Leary
> Cc: Kevin Cameron x3251; verilog-ams@eda.org
> Subject: Re: Infinity in Verilog-AMS
>
> Martin -
> The requirement I have is not related to knowing whether the
> parameter was set or not. (Although I like the idea of
> having a way to ask that question.)
>
> The question is in regards to device modeling concepts
> like Early voltages, where the model will do something
> with 1/VA, and it's important to know whether 1/VA
> is really zero or whether it's just "close."
>
> The Cadence Verilog-A Language Reference suggests that I
> Change all illegal references to 'inf to a large number
> such as 1M.
>
> However, 1M (meaning 1e6) is not "large" enough for the
> general case, and probably not even large enough for
> this example.
Nothing wrong with picking a larger number. Kevin's suggestion of defining 'HUGE sounds like it might help. We could add this definition to the constants file.
>
> Perhaps you are meaning that, if a parameter such as the
> Early voltage is not specified, then I could use the
> $param_given construct to make the module behave as
> though VA had a default of infinity.
This is not what I had in mind but if it works great ... - I was more thinking of a request that I have heard over the years for modelers to be able to tell if a parameter has been set or not so they ignore that aspect of the model as the user is not interested.
>
> -Geoffrey
>
>
> Martin O'Leary wrote:
> >
> > Geoffrey,
> > It was removed as inf is not a valid number.
> > Understand the requirement you have - my take is that adding a system
> task such as $param_given is a better way to know if a parameter was set
> or not.
> > Thanks,
> > --Martin
>
> --
> Geoffrey J. Coram, Ph.D. Senior CAD Engineer
> Analog Devices, Inc. Geoffrey.Coram@analog.com
> 804 Woburn St., MS-422, Tel (781) 937-1924
> Wilmington, MA 01887 Fax (781) 937-1014
>
>
>
This archive was generated by hypermail 2b28 : Tue Apr 29 2003 - 17:07:14 PDT