Index: /pom.xml
===================================================================
--- /pom.xml	(revision 45)
+++ /pom.xml	(revision 46)
@@ -7,5 +7,5 @@
 	<artifactId>runserver</artifactId>
 	<packaging>war</packaging>
-	<version>2.1.6</version>
+	<version>2.2.1</version>
 	<name>runserver Maven Webapp</name>
 	<url>http://maven.apache.org</url>
@@ -79,5 +79,5 @@
 			<groupId>tudelft.utilities</groupId>
 			<artifactId>utilities</artifactId>
-			<version>1.2.1</version>
+			<version>1.3.1</version>
 		</dependency>
 
Index: /src/main/webapp/newsession.xhtml
===================================================================
--- /src/main/webapp/newsession.xhtml	(revision 45)
+++ /src/main/webapp/newsession.xhtml	(revision 46)
@@ -50,5 +50,5 @@
 	<br /> Domain/Profile Server:
 	<input type="url" name="url" id="profilesserverurl"
-		value="localhost:8080/profilesserver-2.1.6"
+		value="localhost:8080/profilesserver-2.2.1"
 		pattern=".*:[0-9]+/profilesserver.*" size="30"
 		onchange="connectDomain()"> </input>
@@ -65,5 +65,5 @@
 		<br /> <b>Participants</b> <br /> Parties Server: <input type="url"
 			name="url" id="partiesserverurl"
-			value="localhost:8080/partiesserver-2.1.6"
+			value="localhost:8080/partiesserver-2.2.1"
 			pattern=".*:[0-9]+/partiesserver.*" size="30"
 			onchange="connectParties()"> </input> <br /> <br /> <b>Party
@@ -356,8 +356,8 @@
 	 refresh table: copy all parties elements in there.
 	 Typically parties is something like
-	 [{"uri":"http:130.161.180.1:8080/partiesserver/run/randomparty-2.1.6",
+	 [{"uri":"http:130.161.180.1:8080/partiesserver/run/randomparty-2.2.1",
 		 "capabilities":{"protocols":["SAOP"]},
 		 "description":"places random bids until it can accept an offer with utility >0.6",
-		 "id":"randomparty-2.1.6",
+		 "id":"randomparty-2.2.1",
 		 "partyClass":"geniusweb.exampleparties.randomparty.RandomParty"},
 		 		 ...]
@@ -736,6 +736,6 @@
 	function init() {
 		selectProtocol();
-		document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-2.1.6"
-		document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-2.1.6"
+		document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-2.2.1"
+		document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-2.2.1"
 		connectDomain();
 		connectParties();
Index: /src/main/webapp/newtournament.xhtml
===================================================================
--- /src/main/webapp/newtournament.xhtml	(revision 45)
+++ /src/main/webapp/newtournament.xhtml	(revision 46)
@@ -683,6 +683,6 @@
 	*/
 	function init() {
-		document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-2.1.6";
-		document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-2.1.6";
+		document.getElementById("partiesserverurl").value =window.location.hostname+":8080/partiesserver-2.2.1";
+		document.getElementById("profilesserverurl").value =window.location.hostname+":8080/profilesserver-2.2.1";
 
 		selectSessionProtocol();
Index: /src/main/webapp/plotlog.xhtml
===================================================================
--- /src/main/webapp/plotlog.xhtml	(revision 45)
+++ /src/main/webapp/plotlog.xhtml	(revision 46)
@@ -56,4 +56,8 @@
         
         var ws = null;
+        
+        function arrayequals(array1, array2) {
+        	return array1.length === array2.length && array1.every(function(value, index) { return value === array2[index]})
+        }
 
         <!-- Most functions are reactive programming written out-->
@@ -179,9 +183,9 @@
             ws.onmessage = function (event) {
             	var profile = JSON.parse(event.data);
-            	if (profile['LinearAdditiveUtilitySpace']==undefined) {
-                    setStatus('Fatal: profile '+uri+" does not contain a LinearAdditiveUtilitySpace.");
+            	if (profile['LinearAdditiveUtilitySpace']==undefined && profile['SumOfGroupsUtilitySpace']==undefined) {
+                    setStatus('Fatal: profile '+uri+" does not contain a LinearAdditive- or SumOfGroups UtilitySpace.");
                     return;
             	}
-            	partyprofiles[party]=profile['LinearAdditiveUtilitySpace'];
+            	partyprofiles[party]=profile;
             	getProfiles(json, partyprofileURIs, protocol, partyprofiles);
             };
@@ -381,13 +385,54 @@
         
    
+    function utility(profile, issueValues) {
+    	if (profile['LinearAdditiveUtilitySpace']!=undefined) 
+    		return linearUtility(profile['LinearAdditiveUtilitySpace'], issueValues);
+
+	    	if (profile['SumOfGroupsUtilitySpace']!=undefined) 
+    		return groupUtility(profile['SumOfGroupsUtilitySpace'], issueValues);
+    	
+    }
+
+	/**
+ 	Compute utilityes for a linear-additive profile
+ 	@param linadditive the linear additive utility space
+ 	@param issueValues the bid containing dict with values for the issues
+ 	@return utility of issueValues
+ 	*/
+ 	function groupUtility(profile, issueValues) {
+		var util=0;
+		
+		for (var part in profile['partUtilities']) {
+			util = util + grouputil(profile['partUtilities'][part]['PartsUtilities'], issueValues );
+		}
+		return util;
+	}
+	
+	function grouputil(partutils, issueValues) {
+		
+		// extract the exact value list of this group
+		var value = []
+		for (const iss of partutils['issues']) {
+			value.push( issueValues[iss] )
+		}
+		
+		// find the utility in the utilslist
+		for (const item of partutils['utilslist']) {
+			if ( arrayequals(  item['values'], value))
+				return item['util']
+		}
+		return 0; // fallback, not found. Maybe error?
+		
+	}	
+
+	
     
-	 	
 	/**
-	 	Compute utilityes
+	 	Compute utilityes for a linear-additive profile
 	 	@param linadditive the linear additive utility space
 	 	@param issueValues the bid containing dict with values for the issues
 	 	@return utility of issueValues
 	 	*/
-	 	function utility(profile, issueValues) {
+	 	function linearUtility(profile, issueValues) {
 			var util=0;
 			var weights = profile['issueWeights'];
@@ -399,5 +444,6 @@
 		}
 	
-	 	/**
+
+	/**
 	 	Bit hacky, javascript version of evaluator of utility space. 
 	 	Would be much nicer if we could use java here
@@ -437,4 +483,5 @@
 
 
+
 </script>
 
