53 p->nWeightLimit = 1 - fUse0;
62 int * pWeigtCounts, nDivCount, Weight, i, c;;
66 memset( pWeigtCounts, 0,
sizeof(
int) * 1000 );
73 pWeigtCounts[Weight]++;
77 for ( c = 999; c >= 0; c-- )
79 nDivCount += pWeigtCounts[c];
80 if ( nDivCount >= nSingleMax )
94 if ( k/3 == nSingleMax )
136 for ( pLitH = pLitV->
pHPrev; pLitH; pLitH = pLitH->
pHPrev )
159 WeightCur = Coin - 2;
161 if ( WeightCur >= p->nWeightLimit )
165 Vec_PtrPush( vSingles, (
void *)(ABC_PTRUINT_T)WeightCur );
196 for ( pLitH = pLitV->
pHPrev; pLitH; pLitH = pLitH->
pHPrev )
219 WeightCur = Coin - 2;
223 if ( WeightCur >= p->nWeightLimit )
252 if ( pLit1 && pLit2 )
273 else if ( pLit1 && !pLit2 )
275 else if ( !pLit1 && pLit2 )
typedefABC_NAMESPACE_HEADER_START struct Vec_Ptr_t_ Vec_Ptr_t
INCLUDES ///.
void Fxu_MatrixComputeSingles(Fxu_Matrix *p, int fUse0, int nSingleMax)
FUNCTION DEFINITIONS ///.
#define Fxu_MatrixForEachVarInRing(Matrix, Var)
static void Vec_PtrPush(Vec_Ptr_t *p, void *Entry)
#define ABC_ALLOC(type, num)
int Fxu_SingleCountCoincidence(Fxu_Matrix *p, Fxu_Var *pVar1, Fxu_Var *pVar2)
static int Vec_PtrSize(Vec_Ptr_t *p)
void Fxu_MatrixComputeSinglesOne(Fxu_Matrix *p, Fxu_Var *pVar)
#define Fxu_MatrixForEachVariable(Matrix, Var)
#define Fxu_MatrixRingVarsStart(Matrix)
static ABC_NAMESPACE_IMPL_START void Fxu_MatrixComputeSinglesOneCollect(Fxu_Matrix *p, Fxu_Var *pVar, Vec_Ptr_t *vSingles)
DECLARATIONS ///.
#define ABC_NAMESPACE_IMPL_END
void Fxu_MatrixRingVarsUnmark(Fxu_Matrix *p)
#define Fxu_MatrixRingVarsAdd(Matrix, Var)
void Fxu_MatrixAddSingle(Fxu_Matrix *p, Fxu_Var *pVar1, Fxu_Var *pVar2, int Weight)
static void Vec_PtrWriteEntry(Vec_Ptr_t *p, int i, void *Entry)
#define ABC_NAMESPACE_IMPL_START
static void * Vec_PtrEntry(Vec_Ptr_t *p, int i)
static Vec_Ptr_t * Vec_PtrAlloc(int nCap)
FUNCTION DEFINITIONS ///.
#define Fxu_MatrixRingVarsStop(Matrix)
typedefABC_NAMESPACE_HEADER_START struct FxuMatrix Fxu_Matrix
INCLUDES ///.
static void Vec_PtrShrink(Vec_Ptr_t *p, int nSizeNew)
static void Vec_PtrFree(Vec_Ptr_t *p)