#include "mdd.h"
Go to the source code of this file.
Functions | |
mdd_t * | mdd_func3 (mdd_manager *mgr, int mvar1, int mvar2, int mvar3, boolean(*func3)(int, int, int)) |
boolean | eq_plus3 (int x, int y, int z) |
boolean | geq_plus3 (int x, int y, int z) |
boolean | gt_plus3 (int x, int y, int z) |
boolean | leq_plus3 (int x, int y, int z) |
boolean | lt_plus3 (int x, int y, int z) |
boolean | neq_plus3 (int x, int y, int z) |
boolean | eq_minus3 (int x, int y, int z) |
boolean | geq_minus3 (int x, int y, int z) |
boolean | gt_minus3 (int x, int y, int z) |
boolean | leq_minus3 (int x, int y, int z) |
boolean | lt_minus3 (int x, int y, int z) |
boolean | neq_minus3 (int x, int y, int z) |
boolean eq_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 126 of file mdd_func3.c.
boolean eq_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 90 of file mdd_func3.c.
boolean geq_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 132 of file mdd_func3.c.
boolean geq_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 96 of file mdd_func3.c.
boolean gt_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 138 of file mdd_func3.c.
boolean gt_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 102 of file mdd_func3.c.
boolean leq_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 144 of file mdd_func3.c.
boolean leq_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 108 of file mdd_func3.c.
boolean lt_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 150 of file mdd_func3.c.
boolean lt_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 114 of file mdd_func3.c.
mdd_t* mdd_func3 | ( | mdd_manager * | mgr, | |
int | mvar1, | |||
int | mvar2, | |||
int | mvar3, | |||
boolean(*)(int, int, int) | func3 | |||
) |
Definition at line 19 of file mdd_func3.c.
00025 { 00026 mvar_type x, y, z; 00027 array_t *child_list_x, *child_list_y, *child_list_z; 00028 int i, j, k; 00029 mdd_t *tx, *ty, *tz; 00030 array_t *mvar_list = mdd_ret_mvar_list(mgr); 00031 mdd_t *one, *zero; 00032 00033 one = mdd_one(mgr); 00034 zero = mdd_zero(mgr); 00035 00036 x = array_fetch(mvar_type, mvar_list, mvar1); 00037 y = array_fetch(mvar_type, mvar_list, mvar2); 00038 z = array_fetch(mvar_type, mvar_list, mvar3); 00039 00040 if (x.status == MDD_BUNDLED) { 00041 (void) fprintf(stderr, 00042 "\nWarning: mdd_func3, bundled variable %s is used\n", x.name); 00043 fail(""); 00044 } 00045 00046 if (y.status == MDD_BUNDLED) { 00047 (void) fprintf(stderr, 00048 "\nWarning: mdd_func3, bundled variable %s is used\n", y.name); 00049 fail(""); 00050 } 00051 00052 if (z.status == MDD_BUNDLED) { 00053 (void) fprintf(stderr, 00054 "\nWarning: mdd_func3, bundled variable %s is used\n", z.name); 00055 fail(""); 00056 } 00057 00058 00059 child_list_x = array_alloc(mdd_t *, 0); 00060 for (i=0; i<x.values; i++) { 00061 child_list_y = array_alloc(mdd_t *, 0); 00062 for (j=0; j<y.values; j++) { 00063 child_list_z = array_alloc(mdd_t *, 0); 00064 for (k=0; k<z.values; k++) { 00065 if (func3(i,j,k)) 00066 array_insert_last(mdd_t *, child_list_z, one); 00067 else 00068 array_insert_last(mdd_t *, child_list_z, zero); 00069 } 00070 tz = mdd_case(mgr, mvar3, child_list_z); 00071 array_insert_last(mdd_t *, child_list_y, tz); 00072 array_free(child_list_z); 00073 } 00074 ty = mdd_case(mgr, mvar2, child_list_y); 00075 array_insert_last(mdd_t *, child_list_x, ty); 00076 array_free(child_list_y); 00077 } 00078 tx = mdd_case(mgr, mvar1, child_list_x); 00079 array_free(child_list_x); 00080 00081 mdd_free(one); 00082 mdd_free(zero); 00083 00084 return tx; 00085 }
boolean neq_minus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 156 of file mdd_func3.c.
boolean neq_plus3 | ( | int | x, | |
int | y, | |||
int | z | |||
) |
Definition at line 120 of file mdd_func3.c.