Skip to content

Potential rounding issues #32

@klayoutmatthias

Description

@klayoutmatthias

Here is a way to reproduce the issue mentioned in https://www.klayout.de/forum/comments.php?DiscussionID=994&page=1#Comment_4547:

  • Create a layout, start with a database unit of 0.001 (the default)
  • Create a cell and a sub-cell, please some shapes, place the subcell somewhere
  • Change to DBU to 0.00100000000001. This requires two steps: first change to something "very different", like 0.002 and then to 0.00100000000001. Note it's shown as "0.001", but the true value can be checked using this Ruby line: RBA::CellView::active.layout.dbu
  • Now change the position of the child instance using the instance properties. Enter a value like "5"

Effect: it will round down to 4.999.

This is partially comprehensible since the DBU is bigger than 0.001. But expectation is that the value would be rounded to 5000 DBU rendering 5.00000000005, not less.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions