src/sylvan_ldd.c
static void
lddmc_nodecount_levels_mark(MDD mdd, size_t *variables)
{
    if (mdd <= lddmc_true) return;
    mddnode_t n = LDD_GETNODE(mdd);
    if (!mddnode_getmark(n)) {
        mddnode_setmark(n, 1);
        (*variables) += 1;
        lddmc_nodecount_levels_mark(mddnode_getright(n), variables);
        lddmc_nodecount_levels_mark(mddnode_getdown(n), variables+1);
    }
}
/**
 * Count number of nodes for each level
 */
Count number of nodes for each level
Count number of nodes for each level
static void
lddmc_nodecount_levels_mark(MDD mdd, size_t *variables)
{
    if (mdd <= lddmc_true) return;
    mddnode_t n = LDD_GETNODE(mdd);
    if (!mddnode_getmark(n)) {
        mddnode_setmark(n, 1);
        (*variables) += 1;
        lddmc_nodecount_levels_mark(mddnode_getright(n), variables);
        lddmc_nodecount_levels_mark(mddnode_getdown(n), variables+1);
    }
}
static void lddmc_nodecount_levels_mark ( MDD mdd , size_t * variables ) { if ( mdd <= lddmc_true ) return ; mddnode_t n = LDD_GETNODE ( mdd ) ; if ( ! mddnode_getmark ( n ) ) { mddnode_setmark ( n , 1 ) ; ( * variables ) += 1 ; lddmc_nodecount_levels_mark ( mddnode_getright ( n ) , variables ) ; lddmc_nodecount_levels_mark ( mddnode_getdown ( n ) , variables + 1 ) ; } }
Count number of nodes for each level
Count number of nodes for each level