diff options
Diffstat (limited to 'src/mean.c')
-rw-r--r-- | src/mean.c | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -42,7 +42,7 @@ int mean(Int_Array monomial, Polynomial* out, Fields_Table fields, Polynomial_Ma *out=polynomial_one(); // sort first - monomial_sort(monomial, 0, monomial.length-1, fields, &sign); + monomial_sort(monomial, fields, &sign); polynomial_multiply_Qscalar(*out, quot(sign,1)); // get internals // (*out).monomials is the first element of out but it only has 1 element @@ -417,7 +417,7 @@ int mean_symbols(Int_Array monomial, Polynomial* output, Fields_Table fields, Po if(check_monomial_match(tmp_monomial, fields)==1){ // sort monomial sign=1; - monomial_sort(tmp_monomial, 0, tmp_monomial.length-1, fields, &sign); + monomial_sort(tmp_monomial, fields, &sign); number_Qprod_chain(quot(sign,1), &tmp_num); // mean @@ -628,7 +628,7 @@ int mean_groups(Int_Array monomial, Polynomial* output, Fields_Table fields, Pol init_Polynomial(output, MONOMIAL_SIZE); // check whether there are symbols - // requires the symbols to be at the end of the monomial + // IMPORTANT: the symbols must be at the end of the monomial if(monomial.length==0 || field_type(monomial.values[monomial.length-1], fields)!=FIELD_SYMBOL){ // mean mean(monomial, &num_mean, fields, propagator); @@ -639,7 +639,7 @@ int mean_groups(Int_Array monomial, Polynomial* output, Fields_Table fields, Pol // sort into groups if(groups.length>0){ sign=1; - monomial_sort_groups(monomial, 0, monomial.length-1, fields, groups, &sign); + monomial_sort_groups(monomial, fields, groups, &sign); } // construct groups and take mean init_Int_Array(&tmp_monomial, MONOMIAL_SIZE); |