Вы находитесь на странице: 1из 2

Using php, for the x x array

N1 N2 Nx G1 EN1 ,G1 EN2 ,G1 ENx ,G1 G2 EN1 ,G2 EN2 ,G2 ENx ,G2

..

..

..

..

Gx EN1 ,Gx EN2 ,Gx ENx ,Gx ,

how could I compare the sums of the numbers representing each of the possible non-repeating permutations? (If this were the 3 3 array
EN1 ,G1 EN2 ,G1 EN1 ,G2 EN2 ,G2 EN3 ,G1 EN3 ,G2

EN1 ,G3 EN2 ,G3 EN3 ,G3 ,

the results would be for


EN1 ,G1 + EN2 ,G2 + EN3 ,G3 ,

EN1 ,G1

 


EN2 ,G2

 
EN3 ,G3

and for
EN1 ,G1 + EN2 ,G3 + EN3 ,G2 , EN1 ,G1

 

 
EN2 ,G3


EN3 ,G2

and for
EN1 ,G2 + EN2 ,G1 + EN3 ,G3 ,


EN1 ,G2

EN2 ,G1

and for

 

 
EN3 ,G3

EN1 ,G2 + EN2 ,G3 + EN3 ,G1 ,


EN1 ,G2

and for

 
EN2 ,G3

EN3 ,G1

 

EN1 ,G3 + EN2 ,G1 + EN3 ,G2 ,

  and for
EN1 ,G3

EN2 ,G1

  


EN3 ,G2

EN1 ,G3 + EN2 ,G2 + EN3 ,G1 ,

 
EN1 ,G3

EN3 ,G1

EN2 ,G2

 .