Skip to content

Does order_book_path[0] represent the parent node of order_before? #4

@cryptocj

Description

@cryptocj

In circuit/src/matching_engine.rs, the get_quote function uses order_book_path[0]:

let sibling_ask_base_diff =
    builder.sub(order_book_path[0].ask_base_sum, order_before.ask_base_sum);

Does order_book_path[0] represent the parent node of order_before?

If so, this would mean order_book_path[0] is not the leaf level, but rather the first internal node (level 1) above the leaf.

Thank you!

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