Changeset 1269 for applications/robust
- Timestamp:
- 01/07/11 10:09:42 (14 years ago)
- Location:
- applications/robust
- Files:
-
- 3 modified
Legend:
- Unmodified
- Added
- Removed
-
applications/robust/main.cpp
r1268 r1269 13 13 using namespace bdm; 14 14 15 const int emlig_size = 3;15 const int emlig_size = 2; 16 16 17 17 int main ( int argc, char* argv[] ) { -
applications/robust/robustlib.cpp
r1268 r1269 18 18 triangulation.push_back(new_simplex); 19 19 20 if(should_integrate) 20 int condition_order = ((toprow*)this)->condition_order-1; 21 if(should_integrate && condition_order-my_emlig->number_of_parameters >= 0) 21 22 { 22 23 emlig* current_emlig; … … 67 68 for(map<double,int>::iterator as_ref = as.begin();as_ref!=as.end();as_ref++) 68 69 { 69 int condition_order = ((toprow*)this)->condition_order-1;70 71 70 double multiplier = det_jacobian; 72 71 if(a_0!=(*as_ref).first) … … 100 99 } 101 100 102 double bracket = fact(condition_order-1-number_of_factors)/fact(as1_order-1)/*/pow((*as_ref).first-a_0,condition_order-1-number_of_factors)*/; 101 double facti = fact(0); 102 103 double bracket = fact(condition_order-number_of_factors)/fact(as1_order-1)/pow((*as_ref).first-a_0,condition_order-number_of_factors); 103 104 for(int k = 0;k < as1_order-1;k++) 104 105 { 105 double bracket_factor = pow((double)-1,k+1)*fact(condition_order- 2-number_of_factors-k)/fact(as1_order-2-k)/pow((*as_ref).first-a_0,condition_order-2-number_of_factors-k);106 double bracket_factor = pow((double)-1,k+1)*fact(condition_order-1-number_of_factors-k)/fact(as1_order-2-k)/pow((*as_ref).first-a_0,condition_order-1-number_of_factors-k); 106 107 107 108 for(set<my_ivec>::iterator combi_ref = this->my_emlig->correction_factors[k].begin();combi_ref!=this->my_emlig->correction_factors[k].end();combi_ref++) -
applications/robust/robustlib.h
r1268 r1269 960 960 vec new_coordinates = coordinates1*t+(coordinates2(1,coordinates2.size()-1)-coordinates1); 961 961 962 vertex* neutral_vertex = new vertex(new_coordinates); 963 964 neutral_vertex->my_emlig = this; 962 vertex* neutral_vertex = new vertex(new_coordinates); 965 963 966 964 new_totally_neutral_child = neutral_vertex; … … 968 966 else 969 967 { 970 toprow* neutral_toprow = new toprow(); 971 972 neutral_toprow->my_emlig = this; 968 toprow* neutral_toprow = new toprow(); 973 969 974 970 new_totally_neutral_child = neutral_toprow; 975 971 } 972 973 new_totally_neutral_child->my_emlig = this; 976 974 977 975 new_totally_neutral_child->children.insert(new_totally_neutral_child->children.end(), … … 985 983 new_totally_neutral_child->vertices.insert((*grand_ref)->vertices.begin(),(*grand_ref)->vertices.end()); 986 984 } 985 986 cout << ((toprow*)current_polyhedron)->condition << endl << toadd << endl; 987 987 988 988 toprow* positive_poly = new toprow(((toprow*)current_polyhedron)->condition+toadd, ((toprow*)current_polyhedron)->condition_order+1); … … 1071 1071 } 1072 1072 1073 1074 } 1075 1073 /* 1074 for(polyhedron* topr_ref = statistic.rows[statistic.size()-1];topr_ref!=statistic.row_ends[statistic.size()-1]->next_poly;topr_ref=topr_ref->next_poly) 1075 { 1076 cout << ((toprow*)topr_ref)->condition << endl; 1077 } 1078 */ 1079 1080 } 1076 1081 1077 1082 void set_correction_factors(int order)