static void free_expr (EORB_CPP_node * n) { switch (n->op) { case 0: break; case '-': if (n->left) { free_expr(n->left); } free_expr(n->right); break; case '!': case '~': free_expr(n->right); break; case 'd': os_free(n->name); break; default: free_expr(n->left); free_expr(n->right); break; } OLD(n); }
static int exec_free (EORB_CPP_node * n) { int rv = 0; int l; int r; switch (n->op) { case 0: rv = n->leaf; break; case '-': if (n->left) { rv = exec_free(n->left); } else { rv = 0; } rv -= exec_free(n->right); break; case '!': rv = ! exec_free(n->right); break; case '~': rv = ~ exec_free(n->right); break; case 'd': rv = !! find_def(n->name); os_free(n->name); break; #define BIN(key,op) case key:l=exec_free(n->left);r=exec_free(n->right);rv=l op r;break; ALLBINS #undef BIN } OLD(n); return (rv); }
double lowNE6SSM_convergence_tester<Two_scale>::max_rel_diff() const { const lowNE6SSM<Two_scale>* ol = get_last_iteration_model(); const lowNE6SSM<Two_scale>* ne = get_model(); double diff[81] = { 0 }; diff[0] = MaxRelDiff(OLD1(MGlu),NEW1(MGlu)); diff[1] = MaxRelDiff(OLD1(MChaP),NEW1(MChaP)); diff[2] = MaxRelDiff(OLD1(MVZp),NEW1(MVZp)); for (unsigned i = 0; i < 6; ++i) { diff[i + 3] = MaxRelDiff(OLD(MSd,i),NEW(MSd,i)); } for (unsigned i = 0; i < 3; ++i) { diff[i + 9] = MaxRelDiff(OLD(MSv,i),NEW(MSv,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 12] = MaxRelDiff(OLD(MSu,i),NEW(MSu,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 18] = MaxRelDiff(OLD(MSe,i),NEW(MSe,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 24] = MaxRelDiff(OLD(MSDX,i),NEW(MSDX,i)); } for (unsigned i = 0; i < 5; ++i) { diff[i + 30] = MaxRelDiff(OLD(Mhh,i),NEW(Mhh,i)); } for (unsigned i = 2; i < 5; ++i) { diff[i + 35] = MaxRelDiff(OLD(MAh,i),NEW(MAh,i)); } for (unsigned i = 1; i < 2; ++i) { diff[i + 40] = MaxRelDiff(OLD(MHpm,i),NEW(MHpm,i)); } for (unsigned i = 0; i < 8; ++i) { diff[i + 42] = MaxRelDiff(OLD(MChi,i),NEW(MChi,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 50] = MaxRelDiff(OLD(MCha,i),NEW(MCha,i)); } for (unsigned i = 0; i < 3; ++i) { diff[i + 52] = MaxRelDiff(OLD(MFDX,i),NEW(MFDX,i)); } for (unsigned i = 0; i < 7; ++i) { diff[i + 55] = MaxRelDiff(OLD(MSHI0,i),NEW(MSHI0,i)); } for (unsigned i = 0; i < 4; ++i) { diff[i + 62] = MaxRelDiff(OLD(MSHIPM,i),NEW(MSHIPM,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 66] = MaxRelDiff(OLD(MChaI,i),NEW(MChaI,i)); } for (unsigned i = 0; i < 7; ++i) { diff[i + 68] = MaxRelDiff(OLD(MChiI,i),NEW(MChiI,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 75] = MaxRelDiff(OLD(MSHp0,i),NEW(MSHp0,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 77] = MaxRelDiff(OLD(MSHpp,i),NEW(MSHpp,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 79] = MaxRelDiff(OLD(MChiP,i),NEW(MChiP,i)); } return *std::max_element(diff, diff + 81); }
double E6SSM_convergence_tester<Two_scale>::max_rel_diff() const { const E6SSM<Two_scale>* ol = get_last_iteration_model(); const E6SSM<Two_scale>* ne = get_model(); double diff[73] = { 0 }; diff[0] = MaxRelDiff(OLD1(MGlu),NEW1(MGlu)); diff[1] = MaxRelDiff(OLD1(MChaP),NEW1(MChaP)); diff[2] = MaxRelDiff(OLD1(MVZp),NEW1(MVZp)); for (unsigned i = 0; i < 6; ++i) { diff[i + 3] = MaxRelDiff(OLD(MSd,i),NEW(MSd,i)); } for (unsigned i = 0; i < 3; ++i) { diff[i + 9] = MaxRelDiff(OLD(MSv,i),NEW(MSv,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 12] = MaxRelDiff(OLD(MSu,i),NEW(MSu,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 18] = MaxRelDiff(OLD(MSe,i),NEW(MSe,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 24] = MaxRelDiff(OLD(MSDX,i),NEW(MSDX,i)); } for (unsigned i = 0; i < 3; ++i) { diff[i + 30] = MaxRelDiff(OLD(Mhh,i),NEW(Mhh,i)); } for (unsigned i = 2; i < 3; ++i) { diff[i + 33] = MaxRelDiff(OLD(MAh,i),NEW(MAh,i)); } for (unsigned i = 1; i < 2; ++i) { diff[i + 36] = MaxRelDiff(OLD(MHpm,i),NEW(MHpm,i)); } for (unsigned i = 0; i < 6; ++i) { diff[i + 38] = MaxRelDiff(OLD(MChi,i),NEW(MChi,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 44] = MaxRelDiff(OLD(MCha,i),NEW(MCha,i)); } for (unsigned i = 0; i < 3; ++i) { diff[i + 46] = MaxRelDiff(OLD(MFDX,i),NEW(MFDX,i)); } for (unsigned i = 0; i < 4; ++i) { diff[i + 49] = MaxRelDiff(OLD(MSHI0,i),NEW(MSHI0,i)); } for (unsigned i = 0; i < 4; ++i) { diff[i + 53] = MaxRelDiff(OLD(MSHIp,i),NEW(MSHIp,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 57] = MaxRelDiff(OLD(MChaI,i),NEW(MChaI,i)); } for (unsigned i = 0; i < 4; ++i) { diff[i + 59] = MaxRelDiff(OLD(MChiI,i),NEW(MChiI,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 63] = MaxRelDiff(OLD(MSSI0,i),NEW(MSSI0,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 65] = MaxRelDiff(OLD(MFSI,i),NEW(MFSI,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 67] = MaxRelDiff(OLD(MSHp0,i),NEW(MSHp0,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 69] = MaxRelDiff(OLD(MSHpp,i),NEW(MSHpp,i)); } for (unsigned i = 0; i < 2; ++i) { diff[i + 71] = MaxRelDiff(OLD(MChiP,i),NEW(MChiP,i)); } return *std::max_element(diff, diff + 73); }