Beispiel #1
0
        /// <summary>
        /// Return init state based on init value of variables
        /// </summary>
        /// <returns></returns>
        private CUDDNode GetInitState()
        {
            if (modules.init != null)
            {
                return(EncodeExpression(modules.init));
            }
            else
            {
                CUDDNode result = CUDD.Constant(1);

                for (int i = 0; i < varList.GetNumberOfVar(); i++)
                {
                    CUDDNode tmp = CUDD.Matrix.SetVectorElement(CUDD.Constant(0), rowVars[i], varList.GetVarInit(i) - varList.GetVarLow(i), 1);
                    result = CUDD.Function.And(result, tmp);
                }

                return(result);
            }
        }