• Skip to main content
  • Skip to search
  • Skip to footer
Cadence Home
  • This search text may be transcribed, used, stored, or accessed by our third-party service providers per our Cookie Policy and Privacy Policy.

  1. Community Forums
  2. Custom IC Design
  3. Syntax in ADE output expression for finding the minimum...

Stats

  • Locked Locked
  • Replies 3
  • Subscribers 126
  • Views 7439
  • Members are here 0
This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Syntax in ADE output expression for finding the minimum of two or more numbers

yxie
yxie over 2 years ago

Product: IC6.1.8

An output "A" is defined and its value is returned (i.e., updated, refreshed) per Spectre simulation run. Then I want to define another output "B", whose value is the smallest of output "A" and "0.5" (for example). How do I construct the output expression for "B"? I was thinking something like B = min(A, 0.5).

I've tried Calculator function "ymin" like this B = ymin(A 0.5), but for ymin, the syntax of A 0.5 is wrong, apparently, my sense is that A 0.5 has to form a vector, but how? I don't know. I've tried [A 0.5], or {A 0.5}, i.e., B = ymin([A 0.5]), that didn't work. When I searched Cadence knowledge base, I found this article but it leads to nowhere.

https://community.cadence.com/cadence_technology_forums/f/custom-ic-design/23964/about-selecting-the-minimum-value-among-two-or-more

Would someone please help?

  • Cancel
Parents
  • ShawnLogan
    ShawnLogan over 2 years ago

    Dear yxie,

    yxie said:
    An output "A" is defined and its value is returned (i.e., updated, refreshed) per Spectre simulation run. Then I want to define another output "B", whose value is the smallest of output "A" and "0.5" (for example). How do I construct the output expression for "B"? I was thinking something like B = min(A, 0.5).

    Have you considered using a conditional expression to define your variable B? For example:

    B is a new design variable dependent on the value of A. Hence define variable B as:

    if( (VAL("A") < 0.5) then VAL("A") else 0.5)

    Shawn

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
  • Andrew Beckett
    Andrew Beckett over 2 years ago in reply to ShawnLogan

    yxie, sadly Shawn's answer won't work because a) you're talking about an output expression, and b) he uses a function VAL() that doesn't exist (I assume he meant VAR()).

    Anyway, the way to do this would indeed to be have an output with an expression min(A 0.5) - the min function does support waveform objects as well as numbers, so this should work fine (at least it does in current versions; I just tested it; I'm not sure which IC sub-version you're using since you didn't say).

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Reply
  • Andrew Beckett
    Andrew Beckett over 2 years ago in reply to ShawnLogan

    yxie, sadly Shawn's answer won't work because a) you're talking about an output expression, and b) he uses a function VAL() that doesn't exist (I assume he meant VAR()).

    Anyway, the way to do this would indeed to be have an output with an expression min(A 0.5) - the min function does support waveform objects as well as numbers, so this should work fine (at least it does in current versions; I just tested it; I'm not sure which IC sub-version you're using since you didn't say).

    Andrew

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel
Children
  • yxie
    yxie over 2 years ago in reply to Andrew Beckett

    Yeah, thanks, Andrew, it works with this subversion I am now working with IC6.1.8-64b.500.25. Also, thank Shawn - yes, I did try that as well; somehow the subversion I was working with then didn't seem to work. Anyhow, the min/max function allows me set the upper and lower limit to a trim code which also a design variable, that based on a measurement on simulation result of previous run.

    • Cancel
    • Vote Up 0 Vote Down
    • Cancel

Community Guidelines

The Cadence Design Communities support Cadence users and technologists interacting to exchange ideas, news, technical information, and best practices to solve problems and get the most from Cadence technology. The community is open to everyone, and to provide the most value, we require participants to follow our Community Guidelines that facilitate a quality exchange of ideas and information. By accessing, contributing, using or downloading any materials from the site, you agree to be bound by the full Community Guidelines.

© 2025 Cadence Design Systems, Inc. All Rights Reserved.

  • Terms of Use
  • Privacy
  • Cookie Policy
  • US Trademarks
  • Do Not Sell or Share My Personal Information