normalization function

Normalize tripartite and tetrapartite values