You can subscribe to this list here.
| 2008 |
Jan
|
Feb
|
Mar
(35) |
Apr
(96) |
May
(39) |
Jun
(25) |
Jul
(7) |
Aug
(7) |
Sep
(44) |
Oct
(17) |
Nov
(14) |
Dec
(9) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2009 |
Jan
(5) |
Feb
(28) |
Mar
(26) |
Apr
(14) |
May
(3) |
Jun
(3) |
Jul
(13) |
Aug
(41) |
Sep
(12) |
Oct
|
Nov
(2) |
Dec
(17) |
| 2010 |
Jan
(9) |
Feb
(5) |
Mar
(11) |
Apr
(3) |
May
(4) |
Jun
(2) |
Jul
(3) |
Aug
(8) |
Sep
(2) |
Oct
(11) |
Nov
(3) |
Dec
(1) |
| 2011 |
Jan
|
Feb
(1) |
Mar
(8) |
Apr
(4) |
May
(4) |
Jun
(5) |
Jul
(3) |
Aug
(2) |
Sep
(7) |
Oct
(4) |
Nov
(4) |
Dec
(2) |
| 2012 |
Jan
|
Feb
|
Mar
(4) |
Apr
(11) |
May
(8) |
Jun
(2) |
Jul
(7) |
Aug
(6) |
Sep
(2) |
Oct
(2) |
Nov
|
Dec
(3) |
| 2013 |
Jan
|
Feb
(1) |
Mar
(7) |
Apr
(3) |
May
(1) |
Jun
(4) |
Jul
(8) |
Aug
(4) |
Sep
(4) |
Oct
(6) |
Nov
(8) |
Dec
(6) |
| 2014 |
Jan
|
Feb
|
Mar
(2) |
Apr
(4) |
May
(6) |
Jun
(10) |
Jul
|
Aug
(7) |
Sep
(15) |
Oct
(4) |
Nov
(1) |
Dec
(1) |
| 2015 |
Jan
|
Feb
(1) |
Mar
(10) |
Apr
(4) |
May
(6) |
Jun
(1) |
Jul
|
Aug
(2) |
Sep
(2) |
Oct
(5) |
Nov
(6) |
Dec
(12) |
| 2016 |
Jan
(1) |
Feb
(4) |
Mar
(7) |
Apr
(30) |
May
(5) |
Jun
|
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: <jom...@us...> - 2008-04-30 17:21:34
|
Revision: 1281
http://jason.svn.sourceforge.net/jason/?rev=1281&view=rev
Author: jomifred
Date: 2008-04-30 10:21:29 -0700 (Wed, 30 Apr 2008)
Log Message:
-----------
jason team: several changes!
Modified Paths:
--------------
trunk/applications/as-unit-test/src/jason/tests/TestLoop.java
trunk/applications/jason-moise/lib/moise.jar
trunk/applications/jason-moise/src/jmoise/OrgManager.java
trunk/applications/jason-moise/src/jmoise/broadcast.java
trunk/applications/jason-team/AC-Local-Dummies.mas2j
trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
trunk/applications/jason-team/dummies.xml
trunk/applications/jason-team/gauchos.xml
trunk/applications/jason-team/src/asl/dummy.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/java/arch/ACArchitecture.java
trunk/applications/jason-team/src/java/arch/ACProxy.java
trunk/applications/jason-team/src/java/arch/CowboyArch.java
trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
trunk/applications/jason-team/src/java/arch/WriteStatusThread.java
Added Paths:
-----------
trunk/applications/jason-team/src/java/test/MindView.java
Modified: trunk/applications/as-unit-test/src/jason/tests/TestLoop.java
===================================================================
--- trunk/applications/as-unit-test/src/jason/tests/TestLoop.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/as-unit-test/src/jason/tests/TestLoop.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -17,21 +17,40 @@
// defines the agent's AgentSpeak code
ag.parseAScode(
"b(1). "+
+ "p(1,a). p(2,a). p(3,b). p(4,b). p(6,a). "+
"+!test1 <- .while( .count(b(_),N) & N < 4, {+b(N+1) })."+
- "+!test2 <- L=4; .while( .count(b(_)) < L, { ?b(X); +b(X+1) }); jason.asunit.print(end)."
+ "+!test2 <- L=4; .while( .count(b(_)) < L, { ?b(X); +b(X+1) }); jason.asunit.print(end). "+
+
+ "+!test3 <- L=4; .for( p(N,a) & N < L, { jason.asunit.print(N) }); jason.asunit.print(end). "+
+
+ "+!test4 <- .for( .member(N, [1,3,4]), { jason.asunit.print(N) }); jason.asunit.print(end). "
);
}
@Test
- public void test1() {
+ public void testWhile1() {
ag.addGoal("test1");
ag.assertBel("b(4)", 20);
}
@Test
- public void test2() {
+ public void testWhile2() {
ag.addGoal("test2");
ag.assertBel("b(4)", 30);
}
+
+ @Test
+ public void testFor1() {
+ ag.addGoal("test3");
+ ag.assertPrint("2", 10);
+ ag.assertPrint("end", 10);
+ }
+
+ @Test
+ public void testFor2() {
+ ag.addGoal("test4");
+ ag.assertPrint("4", 10);
+ ag.assertPrint("end", 10);
+ }
}
Modified: trunk/applications/jason-moise/lib/moise.jar
===================================================================
(Binary files differ)
Modified: trunk/applications/jason-moise/src/jmoise/OrgManager.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -194,10 +194,10 @@
}
// notify others in the group about this new player
- updateMembersOE(gr.getAgentsInThisGroupAndSubGroups(), "play(" + sender + "," + roleId + "," + grId + ")", true, true);
+ updateMembersOE(gr.getAgents(true), "play(" + sender + "," + roleId + "," + grId + ")", true, true);
// send players of this group to sender
- for (RolePlayer rp : gr.getPlayers()) {
+ for (RolePlayer rp : gr.getPlayers(null, true)) {
if (!rp.getPlayer().getId().equals(sender)) {
updateMembersOE(sender, "play(" + rp.getPlayer().getId() + "," + rp.getRole().getId() + "," + grId + ")", false, true);
}
@@ -216,7 +216,7 @@
GroupInstance gr = currentOE.findGroup(grId);
// notify other players
- updateMembersOE(gr.getAgentsInThisGroupAndSubGroups(), "play(" + sender + "," + roleId + "," + grId + ")", false, false);
+ updateMembersOE(gr.getAgents(true), "play(" + sender + "," + roleId + "," + grId + ")", false, false);
}
}
Modified: trunk/applications/jason-moise/src/jmoise/broadcast.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/broadcast.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-moise/src/jmoise/broadcast.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -58,7 +58,7 @@
// try group
GroupInstance gi = oag.getOE().findGroup(target.toString());
if (gi != null) {
- for (OEAgent ag: gi.getAgents()) {
+ for (OEAgent ag: gi.getAgents(true)) {
if (!ag.getId().equals(oag.getAgName())) {
oag.sendMsg(new Message(ilf.toString(), null, ag.getId(), pcnt));
}
Modified: trunk/applications/jason-team/AC-Local-Dummies.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-Dummies.mas2j 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/AC-Local-Dummies.mas2j 2008-04-30 17:21:29 UTC (rev 1281)
@@ -15,32 +15,32 @@
host="localhost", port=12300, username=botagent1, password="1"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
dummy2 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent2, password="2"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
dummy3 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent3, password="3"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
dummy4 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent4, password="4"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
dummy5 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent5, password="5"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
dummy6 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent6, password="6"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
aslSourcePath: "src/asl";
}
Modified: trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-30 17:21:29 UTC (rev 1281)
@@ -19,32 +19,32 @@
host="localhost", port=12300, username=participant1, password="1"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
gaucho2 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant2, password="2"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
gaucho3 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant3, password="3"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
gaucho4 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant4, password="4"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
gaucho5 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant5, password="5"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
gaucho6 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant6, password="6"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","ally_pos(key,_,_)","corral(_,_,_,_)");
aslSourcePath: "src/asl";
Modified: trunk/applications/jason-team/dummies.xml
===================================================================
--- trunk/applications/jason-team/dummies.xml 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/dummies.xml 2008-04-30 17:21:29 UTC (rev 1281)
@@ -27,9 +27,9 @@
<!-- tasks the user can override in his/her c-build.xml script -->
<target name="user-init">
+ <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
- <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
</target>
<target name="user-end">
</target>
Modified: trunk/applications/jason-team/gauchos.xml
===================================================================
--- trunk/applications/jason-team/gauchos.xml 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/gauchos.xml 2008-04-30 17:21:29 UTC (rev 1281)
@@ -27,9 +27,14 @@
<!-- tasks the user can override in his/her c-build.xml script -->
<target name="user-init">
+ <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
- <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
+
+ <mkdir dir="tmp-ag-mind" />
+ <!--delete failonerror="no" includeEmptyDirs="true" verbose="false">
+ <fileset dir="tmp-ag-mind" includes="*.xml"/>
+ </delete-->
</target>
<target name="user-end">
</target>
@@ -98,6 +103,13 @@
<antcall target="user-end" />
</target>
+ <target name="mind-view" depends="compile" >
+ <java classname="test.MindView" failonerror="true" fork="yes" dir="${basedir}" >
+ <classpath refid="project.classpath"/>
+ <arg line="0"/>
+ </java>
+ </target>
+
<target name="clean" >
<delete failonerror="no" includeEmptyDirs="true" verbose="true">
<fileset dir="${basedir}" includes="**/*.class"/>
Modified: trunk/applications/jason-team/src/asl/dummy.asl
===================================================================
--- trunk/applications/jason-team/src/asl/dummy.asl 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/asl/dummy.asl 2008-04-30 17:21:29 UTC (rev 1281)
@@ -7,11 +7,11 @@
steps(MaxSteps)
corral(UpperLeft.x,UpperLeft.y,DownRight.x,DownRight.y)
- Step:
+ Each step:
pos(X,Y,Step)
- cell(X,Y,Type)
- Type in { cow(Id), ally(Name), enemy(Id) }
- // the Id of enemy is not working
+ cow(Id,X,Y)
+ apply_pos(Name,X,Y)
+
End:
end_of_simulation(Result)
@@ -52,10 +52,6 @@
<- !decide_target.
-// add all cows in BB (used by the arch)
-+cell(X,Y,cow(_)) <- +cow(X,Y).
--cell(X,Y,cow(_)) <- -cow(X,Y).
-
/* -- decide a new target -- */
+!decide_target
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-30 17:21:29 UTC (rev 1281)
@@ -5,11 +5,10 @@
steps(MaxSteps)
corral(UpperLeft.x,UpperLeft.y,DownRight.x,DownRight.y)
- Step:
+ Each step:
pos(X,Y,Step)
- cell(X,Y,Type)
- Type in { cow(Id), ally(Name), enemy(Id) }
- // the Id of enemy is not working
+ cow(Id,X,Y)
+ apply_pos(Name,X,Y)
End:
end_of_simulation(Result)
@@ -94,16 +93,12 @@
+!share_seen_cows.
// simple implementation of share_cows (see TODO above)
-+cell(X,Y,cow(_))[source(percept)]
++cow(Id,X,Y)[source(percept)]
: .my_name(Me) & play(Me,_,Gr)
- <- C = cow(X,Y);
- +C;
- jmoise.broadcast(Gr, tell, C).
--cell(X,Y,cow(_))[source(percept)]
+ <- jmoise.broadcast(Gr, tell, cow(Id,X,Y)).
+-cow(Id,X,Y)[source(percept)]
: .my_name(Me) & play(Me,_,Gr)
- <- C = cow(X,Y);
- -C;
- jmoise.broadcast(Gr, untell, C).
+ <- jmoise.broadcast(Gr, untell, cow(Id,X,Y)).
Modified: trunk/applications/jason-team/src/java/arch/ACArchitecture.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -139,6 +139,7 @@
Lock lock = new ReentrantLock();
Condition cycle = lock.newCondition();
long timestartcycle = 0;
+ long timeLastAction = 0;
int cycleCounter = 0;
@@ -183,13 +184,13 @@
w = "*** ";
}
- long timetoact = 0;
- if (timestartcycle > 0) {
- timetoact = System.currentTimeMillis() - timestartcycle;
+ String timetoact = ". ";
+ if (lastActionInCurrentCycle != null && timestartcycle > 0) {
+ timetoact = " (act in "+ (timeLastAction - timestartcycle) +" ms)";
}
timestartcycle = System.currentTimeMillis();
- logger.info(w+"Last sent action was "+lastActionInCurrentCycle+" for cycle "+getCycle()+ " (act in "+timetoact+" ms). "+notsent);
+ logger.info(w+"Last sent action was "+lastActionInCurrentCycle+" for cycle "+getCycle()+ timetoact + notsent);
setLastAct(lastActionInCurrentCycle);
lastActionInCurrentCycle = null;
}
@@ -213,7 +214,7 @@
}
@Override
- synchronized public void run() {
+ public void run() {
while (true) {
try {
lastAction = null;
@@ -222,6 +223,7 @@
lastActionInCurrentCycle = lastAction.getActionTerm().getTerm(0).toString();
proxy.sendAction(lastActionInCurrentCycle);
toExecute.offer(lastAction);
+ timeLastAction = System.currentTimeMillis();
}
} catch (InterruptedException e) {
return; // condition to stop the thread
Modified: trunk/applications/jason-team/src/java/arch/ACProxy.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -2,7 +2,6 @@
import jason.asSyntax.Literal;
import jason.asSyntax.NumberTermImpl;
-import jason.asSyntax.Structure;
import jason.environment.grid.Location;
import java.util.ArrayList;
@@ -157,7 +156,8 @@
arq.initKnownCows();
- int enemyId = 1;
+ //int enemyId = 1;
+
// add in perception what is around
NodeList nl = perception.getElementsByTagName("cell");
for (int i=0; i < nl.getLength(); i++) {
@@ -178,17 +178,17 @@
// allies are managed by communication
//percepts.add(CowboyArch.createCellPerception(cellx, celly, CowboyArch.aALLY));
} else if (type.getAttribute("type").equals("enemy")) {
- Structure le = new Literal("enemy");
- le.addTerm(new NumberTermImpl( (enemyId++) )); // we need an id to work with UniqueBB
- percepts.add(CowboyArch.createCellPerception(cellx, celly, le));
+ //Structure le = new Literal("enemy");
+ //le.addTerm(new NumberTermImpl( (enemyId++) )); // we need an id to work with UniqueBB
+ //percepts.add(CowboyArch.createCellPerception(cellx, celly, le));
arq.enemyPerceived(absx, absy);
}
} else if (type.getNodeName().equals("cow")) {
int cowId = Integer.parseInt(type.getAttribute("ID"));
- Structure lc = new Literal("cow");
- lc.addTerm(new NumberTermImpl( cowId ));
- percepts.add(CowboyArch.createCellPerception(absx, absy, lc));
+ Literal lc = new Literal("cow");
+ lc.addTerms(new NumberTermImpl( cowId ), new NumberTermImpl( absx), new NumberTermImpl(absy));
+ percepts.add( lc); //CowboyArch.createCellPerception(absx, absy, lc));
//arq.cowPerceived(absx, absy);
} else if (type.getNodeName().equals("obstacle")) {
@@ -208,7 +208,7 @@
arq.startNextStep(step, percepts);
//if (logger.isLoggable(Level.FINE))
- logger.info("Request action for "+lpos+" / percepts: "+percepts);
+ logger.info("Request action for "+lpos+" / rid: "+rid+" / percepts: "+percepts);
} catch (Exception e) {
logger.log(Level.SEVERE, "error processing request",e);
}
@@ -216,7 +216,7 @@
public void sendAction(String action) {
try {
- logger.info("sending action "+action+" for step "+rid+" at "+arq.model.getAgPos(arq.getMyId()) );
+ logger.info("sending action "+action+" for rid "+rid+" at "+arq.model.getAgPos(arq.getMyId()) );
Document doc = documentbuilder.newDocument();
Element el_response = doc.createElement("message");
Modified: trunk/applications/jason-team/src/java/arch/CowboyArch.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -225,7 +225,7 @@
protected void addRestart() {
try {
logger.info("** Arch adding restart for "+getAgName());
- getTS().getC().create();
+ //getTS().getC().create();
getTS().getC().addAchvGoal(new Literal("restart"), Intention.EmptyInt);
lo2 = new Location(-1,-1); // to not restart again in the next cycle
} catch (Exception e) {
Modified: trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -93,7 +93,7 @@
return cows;
}
- private static final Literal cowLiteral = Literal.parseLiteral("cow(_,_)");
+ private static final Literal cowLiteral = Literal.parseLiteral("cow(Id,X,Y)");
private void updateCowsFromBB() {
if (bb == null) return;
@@ -112,8 +112,8 @@
if (i != null) {
while (i.hasNext()) {
Literal c = i.next();
- int x = (int)((NumberTerm)c.getTerm(0)).solve();
- int y = (int)((NumberTerm)c.getTerm(1)).solve();
+ int x = (int)((NumberTerm)c.getTerm(1)).solve();
+ int y = (int)((NumberTerm)c.getTerm(2)).solve();
addCow(x,y);
}
}
Modified: trunk/applications/jason-team/src/java/arch/WriteStatusThread.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/WriteStatusThread.java 2008-04-30 15:33:32 UTC (rev 1280)
+++ trunk/applications/jason-team/src/java/arch/WriteStatusThread.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -1,7 +1,10 @@
package arch;
import jason.environment.grid.Location;
+import jason.util.asl2xml;
+import java.io.File;
+import java.io.FileWriter;
import java.io.PrintWriter;
import java.util.HashMap;
import java.util.Iterator;
@@ -54,6 +57,14 @@
reset();
String fileName = "world-status.txt";
+ File dirmind = null;
+ try {
+ dirmind = new File("tmp-ag-mind");
+ dirmind.mkdir();
+ } catch (Exception e) {
+ dirmind = null;
+ }
+
PrintWriter out = null;
try {
out = new PrintWriter(fileName);
@@ -85,6 +96,15 @@
}
}
}
+
+ // store the agent'd mind
+ if (dirmind != null) {
+ String agmind = new asl2xml().transform(owner.getTS().getAg().getAgState());
+ FileWriter outmind = new FileWriter(new File(dirmind.getName()+"/"+owner.getCycle()+".xml"));
+ outmind.write(agmind);
+ outmind.close();
+ }
+
logger.info(s.toString());
out.println(s.toString());
out.flush();
Added: trunk/applications/jason-team/src/java/test/MindView.java
===================================================================
--- trunk/applications/jason-team/src/java/test/MindView.java (rev 0)
+++ trunk/applications/jason-team/src/java/test/MindView.java 2008-04-30 17:21:29 UTC (rev 1281)
@@ -0,0 +1,136 @@
+//----------------------------------------------------------------------------
+// Copyright (C) 2003 Rafael H. Bordini, Jomi F. Hubner, et al.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// To contact the authors:
+// http://www.dur.ac.uk/r.bordini
+// http://www.inf.furb.br/~jomi
+//
+//----------------------------------------------------------------------------
+
+package test;
+
+import jason.util.asl2html;
+
+import java.awt.BorderLayout;
+import java.awt.Dimension;
+import java.awt.FlowLayout;
+import java.awt.Toolkit;
+import java.awt.event.ActionEvent;
+import java.awt.event.ActionListener;
+
+import javax.swing.BorderFactory;
+import javax.swing.JButton;
+import javax.swing.JFrame;
+import javax.swing.JPanel;
+import javax.swing.JScrollPane;
+import javax.swing.JTextPane;
+import javax.swing.SwingUtilities;
+import javax.swing.border.TitledBorder;
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+
+import org.w3c.dom.Document;
+
+public class MindView {
+
+ public static void main(String[] args) throws Exception {
+ new MindView(Integer.parseInt(args[0]));
+ }
+
+ private int step = 1;
+ private asl2html agTransformerHtml = new asl2html("/xml/agInspection.xsl");
+ private DocumentBuilder builder;
+
+
+ public MindView(int step) throws ParserConfigurationException {
+ this.step = step;
+ builder = DocumentBuilderFactory.newInstance().newDocumentBuilder();
+ initComponents();
+ show();
+ }
+
+ // Interface components
+ JTextPane jTA = null;
+ JFrame frame;
+
+ void initComponents() {
+ frame = new JFrame();
+
+ JButton jBtNext = new JButton("Next");
+ jBtNext.setEnabled(true);
+ jBtNext.addActionListener(new ActionListener() {
+ public void actionPerformed(ActionEvent e) {
+ SwingUtilities.invokeLater(new Runnable() {
+ public void run() {
+ step++;
+ show();
+ }
+ });
+ }
+ });
+ JButton jBtPrev = new JButton("Previous");
+ jBtPrev.setEnabled(true);
+ jBtPrev.addActionListener(new ActionListener() {
+ public void actionPerformed(ActionEvent e) {
+ SwingUtilities.invokeLater(new Runnable() {
+ public void run() {
+ step--;
+ show();
+ }
+ });
+ }
+ });
+
+ jTA = new JTextPane();
+ jTA.setEditable(false);
+ jTA.setContentType("text/html");
+ jTA.setAutoscrolls(false);
+
+ JPanel spTA = new JPanel(new BorderLayout());
+ spTA.add(BorderLayout.CENTER, new JScrollPane(jTA));
+ spTA.setBorder(BorderFactory.createTitledBorder(BorderFactory
+ .createEtchedBorder(), "Agent Inspection", TitledBorder.LEFT, TitledBorder.TOP));
+
+ JPanel pAg = new JPanel(new BorderLayout());
+ pAg.add(BorderLayout.CENTER, spTA);
+
+
+ JPanel pButtons = new JPanel(new FlowLayout(FlowLayout.CENTER));
+ pButtons.add(jBtPrev);
+ pButtons.add(jBtNext);
+
+ frame.getContentPane().add(BorderLayout.SOUTH, pButtons);
+ frame.getContentPane().add(BorderLayout.CENTER, pAg);
+ frame.pack();
+ Dimension screenSize = Toolkit.getDefaultToolkit().getScreenSize();
+ int height = (int)(screenSize.height * 0.618);
+ frame.setBounds(80, 30, (int)(height*1.2), height);
+
+ frame.setVisible(true);
+ }
+
+ private void show() {
+ try {
+ frame.setTitle(":: Jason Mind Inspector :: "+step+" ::");
+ Document agState = builder.parse("tmp-ag-mind/"+step+".xml");
+ jTA.setText(agTransformerHtml.transform(agState));
+ } catch (Exception et) {
+ et.printStackTrace();
+ }
+ }
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-30 15:33:36
|
Revision: 1280
http://jason.svn.sourceforge.net/jason/?rev=1280&view=rev
Author: jomifred
Date: 2008-04-30 08:33:32 -0700 (Wed, 30 Apr 2008)
Log Message:
-----------
add internal action .for
Modified Paths:
--------------
trunk/src/jason/asSemantics/Agent.java
trunk/src/jason/asSemantics/Circumstance.java
trunk/src/jason/asSyntax/InternalActionLiteral.java
trunk/src/jason/asSyntax/ObjectTermImpl.java
trunk/src/jason/stdlib/loop.java
trunk/src/xml/agInspection.xsl
Added Paths:
-----------
trunk/src/jason/stdlib/foreach.java
Modified: trunk/src/jason/asSemantics/Agent.java
===================================================================
--- trunk/src/jason/asSemantics/Agent.java 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/jason/asSemantics/Agent.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -45,6 +45,7 @@
import jason.functions.RuleToFunction;
import jason.runtime.Settings;
import jason.stdlib.conditional;
+import jason.stdlib.foreach;
import jason.stdlib.loop;
import java.io.File;
@@ -247,6 +248,8 @@
return conditional.create();
if (iaName.equals(".while"))
return loop.create();
+ if (iaName.equals(".for"))
+ return foreach.create();
if (iaName.charAt(0) == '.')
iaName = "jason.stdlib" + iaName;
InternalAction objIA = internalActions.get(iaName);
@@ -675,6 +678,8 @@
}
}
Document document = builder.newDocument();
+ document.appendChild(document.createProcessingInstruction("xml-stylesheet", "href='agInspection.xsl' type='text/xsl' "));
+
Element ag = getAsDOM(document);
document.appendChild(ag);
Modified: trunk/src/jason/asSemantics/Circumstance.java
===================================================================
--- trunk/src/jason/asSemantics/Circumstance.java 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/jason/asSemantics/Circumstance.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -441,8 +441,9 @@
// intentions
Element ints = (Element) document.createElement("intentions");
Element selIntEle = null;
- if (getSelectedIntention() != null && !getSelectedIntention().isFinished()) {
- selIntEle = getSelectedIntention().getAsDOM(document);
+ Intention ci = getSelectedIntention();
+ if (ci != null && !ci.isFinished()) {
+ selIntEle = ci.getAsDOM(document);
selIntEle.setAttribute("selected", "true");
ints.appendChild(selIntEle);
}
Modified: trunk/src/jason/asSyntax/InternalActionLiteral.java
===================================================================
--- trunk/src/jason/asSyntax/InternalActionLiteral.java 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/jason/asSyntax/InternalActionLiteral.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -26,6 +26,7 @@
import jason.asSemantics.Agent;
import jason.asSemantics.InternalAction;
import jason.asSemantics.Unifier;
+import jason.stdlib.foreach;
import jason.stdlib.loop;
import java.util.Iterator;
@@ -80,7 +81,7 @@
@Override
public boolean apply(Unifier u) {
- if (this.ia != null && this.ia instanceof loop)
+ if (this.ia != null && (this.ia instanceof loop || this.ia instanceof foreach))
return false;
else
return super.apply(u);
Modified: trunk/src/jason/asSyntax/ObjectTermImpl.java
===================================================================
--- trunk/src/jason/asSyntax/ObjectTermImpl.java 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/jason/asSyntax/ObjectTermImpl.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -1,11 +1,15 @@
package jason.asSyntax;
+import java.lang.reflect.Method;
+
import org.w3c.dom.Document;
import org.w3c.dom.Element;
public class ObjectTermImpl extends DefaultTerm implements ObjectTerm {
private final Object o;
+ private Method mclone;
+ private boolean hasTestedClone = false;
/** Creates a new Term Wrapper for java object */
public ObjectTermImpl(Object o) {
@@ -29,12 +33,18 @@
@Override
public Object clone() {
try {
- return new ObjectTermImpl(o.getClass().getMethod("clone", (Class[])null).invoke(o, (Object[])null));
+ if (!hasTestedClone) {
+ hasTestedClone = true;
+ mclone = o.getClass().getMethod("clone", (Class[])null);
+ }
+ if (mclone != null) {
+ return new ObjectTermImpl(mclone.invoke(o, (Object[])null));
+ }
} catch (Exception e) {
- System.err.println("The object inside ObjectTerm should be clonable!");
- e.printStackTrace();
- return null;
+ //System.err.println("The object inside ObjectTerm should be clonable!");
+ //e.printStackTrace();
}
+ return this;
}
@Override
Added: trunk/src/jason/stdlib/foreach.java
===================================================================
--- trunk/src/jason/stdlib/foreach.java (rev 0)
+++ trunk/src/jason/stdlib/foreach.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -0,0 +1,96 @@
+//----------------------------------------------------------------------------
+// Copyright (C) 2003 Rafael H. Bordini, Jomi F. Hubner, et al.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// To contact the authors:
+// http://www.dur.ac.uk/r.bordini
+// http://www.inf.furb.br/~jomi
+//
+//----------------------------------------------------------------------------
+
+package jason.stdlib;
+
+import jason.JasonException;
+import jason.asSemantics.DefaultInternalAction;
+import jason.asSemantics.IntendedMeans;
+import jason.asSemantics.InternalAction;
+import jason.asSemantics.TransitionSystem;
+import jason.asSemantics.Unifier;
+import jason.asSyntax.LogicalFormula;
+import jason.asSyntax.ObjectTerm;
+import jason.asSyntax.ObjectTermImpl;
+import jason.asSyntax.PlanBody;
+import jason.asSyntax.PlanBodyImpl;
+import jason.asSyntax.Structure;
+import jason.asSyntax.Term;
+import jason.asSyntax.PlanBody.BodyType;
+
+import java.util.Iterator;
+
+// TODO: comments
+public class foreach extends DefaultInternalAction {
+
+ private static InternalAction singleton = null;
+ public static InternalAction create() {
+ if (singleton == null)
+ singleton = new foreach();
+ return singleton;
+ }
+
+ @SuppressWarnings("unchecked")
+ @Override
+ public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
+ try {
+ IntendedMeans im = ts.getC().getSelectedIntention().peek();
+ PlanBody foria = im.getCurrentStep();
+
+ Iterator<Unifier> iu;
+
+ if (args.length != 3) {
+ // first execution of while
+ if ( !(args[0] instanceof LogicalFormula))
+ throw new JasonException("The first argument of .for must be a logical formula.");
+ if ( !args[1].isPlanBody())
+ throw new JasonException("The second argument of .for must be a plan body term.");
+
+ // get the solutions for the loop
+ LogicalFormula logExpr = (LogicalFormula)args[0];
+ iu = logExpr.logicalConsequence(ts.getAg(), un.copy());
+ ((Structure)foria.getBodyTerm()).addTerm(new ObjectTermImpl(iu));
+ } else {
+ // restore the solutions
+ iu = (Iterator<Unifier>)((ObjectTerm)args[2]).getObject();
+ }
+
+ if (iu.hasNext()) {
+ un.clear();
+ un.compose(iu.next());
+ PlanBody whattoadd = (PlanBody)args[1].clone();
+ whattoadd.add(new PlanBodyImpl(BodyType.internalAction, (Term)foria.getBodyTerm().clone()));
+ whattoadd.setAsBodyTerm(false);
+ foria.add(1,whattoadd);
+ //System.out.println("new body="+foria.getBodyNext());
+ }
+ return true;
+ } catch (ArrayIndexOutOfBoundsException e) {
+ throw new JasonException("The internal action 'for' has not received the required arguments.");
+ } catch (JasonException e) {
+ throw e;
+ } catch (Exception e) {
+ throw new JasonException("Error in internal action 'for': " + e, e);
+ }
+ }
+}
Modified: trunk/src/jason/stdlib/loop.java
===================================================================
--- trunk/src/jason/stdlib/loop.java 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/jason/stdlib/loop.java 2008-04-30 15:33:32 UTC (rev 1280)
@@ -53,8 +53,6 @@
@Override
public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
try {
- if ( !(args[0] instanceof LogicalFormula))
- throw new JasonException("The first argument of .while must be a logical formula.");
IntendedMeans im = ts.getC().getSelectedIntention().peek();
PlanBody whileia = im.getCurrentStep();
@@ -62,33 +60,33 @@
// store a backup of the unifier for the next iteration
// if the IA has a backup unifier, use that (it is an object term)
- if (args.length == 3) {
+ if (args.length != 3) {
+ // first execution of while
+ if ( !(args[0] instanceof LogicalFormula))
+ throw new JasonException("The first argument of .while must be a logical formula.");
+ if ( !args[1].isPlanBody())
+ throw new JasonException("The second argument of .while must be a plan body term.");
+
+ // add backup unifier in the IA
+ ((Structure)whileia.getBodyTerm()).addTerm(new ObjectTermImpl(un.clone()));
+ } else {
// restore the unifier of previous iterations
Unifier ubak = (Unifier)((ObjectTerm)args[2]).getObject();
un.clear();
un.compose(ubak);
- } else {
- // add backup unifier in the IA
- //ubak = (Unifier)un.clone();
- ((Structure)whileia.getBodyTerm()).addTerm(new ObjectTermImpl(un.clone()));
}
- LogicalFormula logExpr = (LogicalFormula)args[0].clone();
- logExpr.apply(un); // need to apply since the internal action literal for while does not apply
- Iterator<Unifier> iu = logExpr.logicalConsequence(ts.getAg(), un); //(Unifier)un.clone());
+ LogicalFormula logExpr = (LogicalFormula)args[0]; //.clone();
+ //logExpr.apply(un); // need to apply since the internal action literal for while does not apply
+ Iterator<Unifier> iu = logExpr.logicalConsequence(ts.getAg(), un);
if (iu.hasNext()) {
- if ( !args[1].isPlanBody())
- throw new JasonException("The second argument of .while must be a plan body term.");
un.compose(iu.next());
PlanBody whattoadd = (PlanBody)args[1]; //.clone();
whattoadd.add(new PlanBodyImpl(BodyType.internalAction, (Term)whileia.getBodyTerm().clone())); //(PlanBody)whileia.clone()); // add the while after
whattoadd.setAsBodyTerm(false);
- if (whileia.getPlanSize() == 1)
- whileia.add(whattoadd);
- else
- whileia.add(1,whattoadd);
+ whileia.add(1,whattoadd);
//System.out.println("new body="+whileia.getBodyNext());
}
return true;
Modified: trunk/src/xml/agInspection.xsl
===================================================================
--- trunk/src/xml/agInspection.xsl 2008-04-29 21:13:16 UTC (rev 1279)
+++ trunk/src/xml/agInspection.xsl 2008-04-30 15:33:32 UTC (rev 1280)
@@ -27,8 +27,8 @@
<xsl:param name="show-mb" select="'true'" />
<xsl:param name="show-plan" select="'true'" />
<xsl:param name="show-int" select="'true'" />
- <xsl:param name="show-plan-details" select="'false'" />
- <xsl:param name="show-int-details" select="'false'" />
+ <xsl:param name="show-plan-details" select="'true'" />
+ <xsl:param name="show-int-details" select="'true'" />
<xsl:output method="html" />
<xsl:strip-space elements="*" />
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-29 21:13:18
|
Revision: 1279
http://jason.svn.sourceforge.net/jason/?rev=1279&view=rev
Author: jomifred
Date: 2008-04-29 14:13:16 -0700 (Tue, 29 Apr 2008)
Log Message:
-----------
fix ant scripts of jason team
Modified Paths:
--------------
trunk/applications/jason-team/contest.xml
trunk/applications/jason-team/dummies.xml
trunk/applications/jason-team/gauchos.xml
Modified: trunk/applications/jason-team/contest.xml
===================================================================
--- trunk/applications/jason-team/contest.xml 2008-04-29 21:03:59 UTC (rev 1278)
+++ trunk/applications/jason-team/contest.xml 2008-04-29 21:13:16 UTC (rev 1279)
@@ -12,7 +12,7 @@
basedir="."
default="run">
- <property name="mas2j.project.file" value="AC-official.mas2j"/>
+ <property name="mas2j.project.file" value="AC-jason-official.mas2j"/>
<property name="debug" value=""/> <!-- use "-debug" to run in debug mode -->
<property name="build.dir" value="${basedir}/bin/classes" />
@@ -23,13 +23,13 @@
<pathelement location="${build.dir}"/>
<pathelement location="${jasonJar}"/>
<fileset dir="${basedir}/lib" > <include name="*.jar" /> </fileset>
-
</path>
<!-- tasks the user can override in his/her c-build.xml script -->
<target name="user-init">
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
+ <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
</target>
<target name="user-end">
</target>
Modified: trunk/applications/jason-team/dummies.xml
===================================================================
--- trunk/applications/jason-team/dummies.xml 2008-04-29 21:03:59 UTC (rev 1278)
+++ trunk/applications/jason-team/dummies.xml 2008-04-29 21:13:16 UTC (rev 1279)
@@ -23,13 +23,13 @@
<pathelement location="${build.dir}"/>
<pathelement location="${jasonJar}"/>
<fileset dir="${basedir}/lib" > <include name="*.jar" /> </fileset>
-
</path>
<!-- tasks the user can override in his/her c-build.xml script -->
<target name="user-init">
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
+ <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
</target>
<target name="user-end">
</target>
Modified: trunk/applications/jason-team/gauchos.xml
===================================================================
--- trunk/applications/jason-team/gauchos.xml 2008-04-29 21:03:59 UTC (rev 1278)
+++ trunk/applications/jason-team/gauchos.xml 2008-04-29 21:13:16 UTC (rev 1279)
@@ -23,13 +23,13 @@
<pathelement location="${build.dir}"/>
<pathelement location="${jasonJar}"/>
<fileset dir="${basedir}/lib" > <include name="*.jar" /> </fileset>
-
</path>
<!-- tasks the user can override in his/her c-build.xml script -->
<target name="user-init">
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
+ <ant antfile="../jason-moise/build.xml" target="jar" inheritall="false" />
</target>
<target name="user-end">
</target>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-29 21:04:10
|
Revision: 1278
http://jason.svn.sourceforge.net/jason/?rev=1278&view=rev
Author: jomifred
Date: 2008-04-29 14:03:59 -0700 (Tue, 29 Apr 2008)
Log Message:
-----------
add ant for the official team
Modified Paths:
--------------
trunk/applications/jason-team/AC-Local-Dummies.mas2j
trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
trunk/applications/jason-team/src/java/jia/Search.java
Added Paths:
-----------
trunk/applications/jason-team/contest.xml
Modified: trunk/applications/jason-team/AC-Local-Dummies.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-Dummies.mas2j 2008-04-28 20:54:41 UTC (rev 1277)
+++ trunk/applications/jason-team/AC-Local-Dummies.mas2j 2008-04-29 21:03:59 UTC (rev 1278)
@@ -15,32 +15,32 @@
host="localhost", port=12300, username=botagent1, password="1"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
dummy2 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent2, password="2"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
dummy3 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent3, password="3"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
dummy4 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent4, password="4"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
dummy5 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent5, password="5"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
dummy6 dummy.asl
[verbose=1,host="localhost", port=12300, username=botagent6, password="6"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
aslSourcePath: "src/asl";
}
Added: trunk/applications/jason-team/contest.xml
===================================================================
--- trunk/applications/jason-team/contest.xml (rev 0)
+++ trunk/applications/jason-team/contest.xml 2008-04-29 21:03:59 UTC (rev 1278)
@@ -0,0 +1,67 @@
+<?xml version="1.0" encoding="ISO-8859-1" ?>
+
+<!--
+
+ This file was generated by Jason 1.1
+ http://jason.sf.net
+
+ April 10, 2008 - 23:19:55
+-->
+
+<project name ="jason_team"
+ basedir="."
+ default="run">
+
+ <property name="mas2j.project.file" value="AC-official.mas2j"/>
+ <property name="debug" value=""/> <!-- use "-debug" to run in debug mode -->
+ <property name="build.dir" value="${basedir}/bin/classes" />
+
+ <property name="jasonJar" value="../../lib/jason.jar"/>
+
+ <path id="project.classpath">
+ <pathelement location="${basedir}"/>
+ <pathelement location="${build.dir}"/>
+ <pathelement location="${jasonJar}"/>
+ <fileset dir="${basedir}/lib" > <include name="*.jar" /> </fileset>
+
+ </path>
+
+ <!-- tasks the user can override in his/her c-build.xml script -->
+ <target name="user-init">
+ <copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
+ <copy file="../jason-moise/lib/moise.jar" todir="lib" />
+ </target>
+ <target name="user-end">
+ </target>
+
+ <target name="init">
+ <mkdir dir="${build.dir}" />
+ <antcall target="user-init" />
+ </target>
+
+ <target name="compile" depends="init">
+ <condition property="srcdir" value="${basedir}/src/java" else="${basedir}" >
+ <available file="${basedir}/src/java" />
+ </condition>
+ <javac srcdir="${srcdir}" destdir="${build.dir}" debug="true" optimize="true" >
+ <classpath refid="project.classpath"/>
+ </javac>
+ </target>
+
+ <target name="run" depends="compile" >
+ <echo message="Running project ${ant.project.name}" />
+ <java classname="jason.infra.centralised.RunCentralisedMAS"
+ failonerror="true" fork="yes" dir="${basedir}" >
+ <classpath refid="project.classpath"/>
+ <arg line="${mas2j.project.file} ${debug} "/>
+ <jvmarg line="-Xmx750M"/>
+ </java>
+ <antcall target="user-end" />
+ </target>
+
+ <target name="clean" >
+ <delete failonerror="no" includeEmptyDirs="true" verbose="true">
+ <fileset dir="${basedir}" includes="**/*.class"/>
+ </delete>
+ </target>
+</project>
Modified: trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-28 20:54:41 UTC (rev 1277)
+++ trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-29 21:03:59 UTC (rev 1278)
@@ -23,30 +23,22 @@
*/
public class LocalWorldModel extends WorldModel {
- int[][] visited; // count the visited locations
- int minVisited = 0; // min value for near least visited
+ int[][] visited; // count the visited locations
+ int minVisited = 0; // min value for near least visited
- private Random random = new Random();
+ private Random random = new Random();
- Set<Vec> cows = new HashSet<Vec>();
- boolean isCowsUptodate = false;
+ Set<Vec> cows = new HashSet<Vec>();
+ boolean isCowsUptodate = false;
- int[][] cowsrep; // cows repulsion
- int[][] agsrep; // agents repulsion
- int[][] obsrep; // obstacle repulsion
+ int[][] cowsrep; // cows repulsion
+ int[][] agsrep; // agents repulsion
+ int[][] obsrep; // obstacle repulsion
- BeliefBase bb; // agent's BB
+ BeliefBase bb; // agent's BB
//private Logger logger = Logger.getLogger("jasonTeamSimLocal.mas2j." + LocalWorldModel.class.getName());
- //public static LocalWorldModel create(int w, int h, int nbAg) {
- // return new LocalWorldModel(w,h,nbAg);
- //}
-
- //public LocalWorldModel(int w, int h) {
- // this(w, h, 6);
- //}
-
public LocalWorldModel(int w, int h, int nbAg, BeliefBase bb) {
super(w, h, nbAg);
this.bb = bb;
Modified: trunk/applications/jason-team/src/java/jia/Search.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/Search.java 2008-04-28 20:54:41 UTC (rev 1277)
+++ trunk/applications/jason-team/src/java/jia/Search.java 2008-04-29 21:03:59 UTC (rev 1278)
@@ -22,7 +22,7 @@
public static final int DIST_FOR_AG_OBSTACLE = 2;
- final LocalWorldModel model;
+ final LocalWorldModel model;
final Location from, to;
final boolean considerAgentsAsObstacles;
final boolean considerCorralAsObstacles;
@@ -69,6 +69,7 @@
}
this.maxDistFromCluster = 4;
+ model.getCows(); // to update the cows in model.
}
public void setMaxDistFromCluster(int m) {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-28 20:54:44
|
Revision: 1277
http://jason.svn.sourceforge.net/jason/?rev=1277&view=rev
Author: jomifred
Date: 2008-04-28 13:54:41 -0700 (Mon, 28 Apr 2008)
Log Message:
-----------
jason team: improve share_cows alg
Modified Paths:
--------------
trunk/applications/jason-moise/lib/moise.jar
trunk/applications/jason-moise/src/jmoise/OrgManager.java
trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
trunk/applications/jason-team/massim-server/conf/serverconfig.xml
trunk/applications/jason-team/src/asl/dummy.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/java/agent/SelectEvent.java
trunk/applications/jason-team/src/java/arch/ACArchitecture.java
trunk/applications/jason-team/src/java/arch/ACProxy.java
trunk/applications/jason-team/src/java/arch/CowboyArch.java
trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
trunk/applications/jason-team/src/java/jia/Vec.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
Modified: trunk/applications/jason-moise/lib/moise.jar
===================================================================
(Binary files differ)
Modified: trunk/applications/jason-moise/src/jmoise/OrgManager.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -194,7 +194,7 @@
}
// notify others in the group about this new player
- updateMembersOE(gr.getAgents(), "play(" + sender + "," + roleId + "," + grId + ")", true, true);
+ updateMembersOE(gr.getAgentsInThisGroupAndSubGroups(), "play(" + sender + "," + roleId + "," + grId + ")", true, true);
// send players of this group to sender
for (RolePlayer rp : gr.getPlayers()) {
@@ -216,7 +216,7 @@
GroupInstance gr = currentOE.findGroup(grId);
// notify other players
- updateMembersOE(gr.getAgents(), "play(" + sender + "," + roleId + "," + grId + ")", false, false);
+ updateMembersOE(gr.getAgentsInThisGroupAndSubGroups(), "play(" + sender + "," + roleId + "," + grId + ")", false, false);
}
}
Modified: trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-28 20:54:41 UTC (rev 1277)
@@ -1,3 +1,4 @@
+
/* Jason Team for the
* Multi-Agent Programming Contest 2008
* (http://cig.in.tu-clausthal.de/AgentContest)
Modified: trunk/applications/jason-team/massim-server/conf/serverconfig.xml
===================================================================
--- trunk/applications/jason-team/massim-server/conf/serverconfig.xml 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/massim-server/conf/serverconfig.xml 2008-04-28 20:54:41 UTC (rev 1277)
@@ -266,52 +266,52 @@
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent1" password="1" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent2" password="2" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent3" password="3" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent4" password="4" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent5" password="5" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="botagent6" password="6" team="bot" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant1" password="1" team="participant" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant2" password="2" team="participant" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant3" password="3" team="participant" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant4" password="4" team="participant" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant5" password="5" team="participant" />
<account actionclassmap="Grid"
defaultactionclass="massim.simulation.GridSimulationAgentAction"
- timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ timeout="4000" auxtimeout="500" maxpacketlength="65536"
username="participant6" password="6" team="participant" />
</accounts>
Modified: trunk/applications/jason-team/src/asl/dummy.asl
===================================================================
--- trunk/applications/jason-team/src/asl/dummy.asl 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/asl/dummy.asl 2008-04-28 20:54:41 UTC (rev 1277)
@@ -50,8 +50,12 @@
+pos(Step,_,_) // new cycle
: Step mod 6 == 0
<- !decide_target.
-
+
+// add all cows in BB (used by the arch)
++cell(X,Y,cow(_)) <- +cow(X,Y).
+-cell(X,Y,cow(_)) <- -cow(X,Y).
+
/* -- decide a new target -- */
+!decide_target
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-28 20:54:41 UTC (rev 1277)
@@ -94,16 +94,16 @@
+!share_seen_cows.
// simple implementation of share_cows (see TODO above)
-+cell(X,Y,cow(_))
++cell(X,Y,cow(_))[source(percept)]
: .my_name(Me) & play(Me,_,Gr)
<- C = cow(X,Y);
+C;
- jmoise.broadcast(Gr, tell, C).
--cell(X,Y,cow(_))
+ jmoise.broadcast(Gr, tell, C).
+-cell(X,Y,cow(_))[source(percept)]
: .my_name(Me) & play(Me,_,Gr)
<- C = cow(X,Y);
-C;
- jmoise.broadcast(Gr, untell, C).
+ jmoise.broadcast(Gr, untell, C).
Modified: trunk/applications/jason-team/src/java/agent/SelectEvent.java
===================================================================
--- trunk/applications/jason-team/src/java/agent/SelectEvent.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/agent/SelectEvent.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -10,14 +10,13 @@
import java.util.Queue;
/**
- * change the default select event function to prefer cell(_,_,gold) events.
+ * change the default select event function to prefer cell(_,_,cow(_)) events.
*
* @author Jomi
*/
public class SelectEvent extends Agent {
- private Trigger gold = Trigger.parseTrigger("+cell(_,_,gold)");
- private Trigger restart = Trigger.parseTrigger("+restart");
+ private Trigger cow = Trigger.parseTrigger("+cell(_,_,cow(_))");
private Unifier un = new Unifier();
public Event selectEvent(Queue<Event> events) {
@@ -25,14 +24,11 @@
while (ie.hasNext()) {
un.clear();
Event e = ie.next();
- if (un.unifies(gold, e.getTrigger()) || un.unifies(restart, e.getTrigger())) {
- //getTS().getLogger().info("custom select event "+e);
+ if (un.unifies(cow, e.getTrigger())) {
ie.remove();
return e;
}
}
return super.selectEvent(events);
}
-
-
}
Modified: trunk/applications/jason-team/src/java/arch/ACArchitecture.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -131,7 +131,7 @@
}
*/
- class WaitSleep extends Thread {
+ class WaitSleep extends Thread {
ActionExec lastAction;
String lastActionInCurrentCycle;
@@ -141,6 +141,7 @@
long timestartcycle = 0;
int cycleCounter = 0;
+
WaitSleep() {
super("WaitSpeepToSendAction");
}
Modified: trunk/applications/jason-team/src/java/arch/ACProxy.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -188,8 +188,8 @@
int cowId = Integer.parseInt(type.getAttribute("ID"));
Structure lc = new Literal("cow");
lc.addTerm(new NumberTermImpl( cowId ));
- percepts.add(CowboyArch.createCellPerception(cellx, celly, lc));
- arq.cowPerceived(absx, absy);
+ percepts.add(CowboyArch.createCellPerception(absx, absy, lc));
+ //arq.cowPerceived(absx, absy);
} else if (type.getNodeName().equals("obstacle")) {
arq.obstaclePerceived(absx, absy, CowboyArch.createCellPerception(absx, absy, CowboyArch.aOBSTACLE));
Modified: trunk/applications/jason-team/src/java/arch/CowboyArch.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -14,8 +14,6 @@
import jason.mas2j.ClassParameters;
import jason.runtime.Settings;
-import java.util.ArrayList;
-import java.util.Collection;
import java.util.Iterator;
import java.util.logging.Level;
import java.util.logging.Logger;
@@ -31,7 +29,7 @@
*/
public class CowboyArch extends IdentifyCrashed {
- LocalWorldModel model = new LocalWorldModel(10,10);
+ LocalWorldModel model = null;
WorldView view = null;
String simId = null;
@@ -57,6 +55,8 @@
@Override
public void initAg(String agClass, ClassParameters bbPars, String asSrc, Settings stts) throws JasonException {
super.initAg(agClass, bbPars, asSrc, stts);
+
+ model = new LocalWorldModel(10,10, WorldModel.agsByTeam, getTS().getAg().getBB()); // just to have a default model
gui = "yes".equals(stts.getUserParameter("gui"));
if ("yes".equals(stts.getUserParameter("write_status"))) {
writeStatusThread = WriteStatusThread.create(this);
@@ -68,7 +68,6 @@
if (massimBackDir != null && massimBackDir.startsWith("\""))
massimBackDir = massimBackDir.substring(1,massimBackDir.length()-1);
logger = Logger.getLogger(CowboyArch.class.getName() + ".CA-" + getAgName());
-
}
@Override
@@ -110,7 +109,7 @@
/** The perception of the grid size is removed from the percepts list
and "directly" added as a belief */
void gsizePerceived(int w, int h, String opponent) throws RevisionFailedException {
- model = new LocalWorldModel(w, h);
+ model = new LocalWorldModel(w, h, WorldModel.agsByTeam, getTS().getAg().getBB());
getTS().getAg().addBel(Literal.parseLiteral("gsize("+w+","+h+")"));
playing = true;
@@ -242,9 +241,10 @@
return l;
}
- private static final Literal cowstoclean = Literal.parseLiteral("cell(_,_,cow(_))");
- private boolean cleanCows = false;
+ //private static final Literal cowstoclean = Literal.parseLiteral("cell(_,_,cow(_))");
+ //private boolean cleanCows = false;
+ /*
@Override
public synchronized void agDidPerceive() {
super.agDidPerceive();
@@ -255,15 +255,18 @@
cleanCows = false;
}
}
+ */
void initKnownCows() {
model.clearCows();
- cleanCows = true;
+ //cleanCows = true;
}
- void cowPerceived(int x, int y) {
- model.addCow(x,y);
- }
+ //void cowPerceived(int x, int y) {
+ // model.addCow(x,y);
+ //}
+
+ /*
void sendCowsToTeam() {
try {
Message m = new Message("tell-cows", null, null, new ArrayList<Location>(model.getCows()));
@@ -272,6 +275,7 @@
e.printStackTrace();
}
}
+ */
void enemyPerceived(int x, int y) {
model.add(WorldModel.ENEMY, x, y);
@@ -327,11 +331,13 @@
Message m = im.next();
if (m.getIlForce().equals("tell-cows")) {
im.remove();
+ /* not used anymore
if (model != null) {
for (Location l: (Collection<Location>)m.getPropCont()) {
cowPerceived(l.x, l.y);
}
}
+ */
} else {
String ms = m.getPropCont().toString();
if (ms.startsWith("cell") && ms.endsWith("obstacle)") && model != null) {
Modified: trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -1,14 +1,18 @@
package arch;
+import jason.asSyntax.Literal;
+import jason.asSyntax.NumberTerm;
+import jason.bb.BeliefBase;
import jason.environment.grid.Location;
import java.util.ArrayList;
-import java.util.Collection;
import java.util.HashSet;
+import java.util.Iterator;
import java.util.List;
import java.util.Random;
import java.util.Set;
+import jia.Vec;
import env.WorldModel;
@@ -24,24 +28,28 @@
private Random random = new Random();
- Set<Location> cows = new HashSet<Location>();
+ Set<Vec> cows = new HashSet<Vec>();
+ boolean isCowsUptodate = false;
int[][] cowsrep; // cows repulsion
int[][] agsrep; // agents repulsion
int[][] obsrep; // obstacle repulsion
+ BeliefBase bb; // agent's BB
+
//private Logger logger = Logger.getLogger("jasonTeamSimLocal.mas2j." + LocalWorldModel.class.getName());
- public static LocalWorldModel create(int w, int h, int nbAg) {
- return new LocalWorldModel(w,h,nbAg);
- }
+ //public static LocalWorldModel create(int w, int h, int nbAg) {
+ // return new LocalWorldModel(w,h,nbAg);
+ //}
- public LocalWorldModel(int w, int h) {
- this(w, h, 6);
- }
+ //public LocalWorldModel(int w, int h) {
+ // this(w, h, 6);
+ //}
- public LocalWorldModel(int w, int h, int nbAg) {
+ public LocalWorldModel(int w, int h, int nbAg, BeliefBase bb) {
super(w, h, nbAg);
+ this.bb = bb;
visited = new int[getWidth()][getHeight()];
for (int i = 0; i < getWidth(); i++)
@@ -81,40 +89,52 @@
}
}
-
+ // cows methods
+
public void clearCows() {
- removeAll(WorldModel.COW);
+ isCowsUptodate = false;
+ }
+
+ public Set<Vec> getCows() {
+ if (!isCowsUptodate)
+ updateCowsFromBB();
+ return cows;
+ }
- for (int i = 0; i < getWidth(); i++)
+ private static final Literal cowLiteral = Literal.parseLiteral("cow(_,_)");
+
+ private void updateCowsFromBB() {
+ if (bb == null) return;
+
+ // clean
+ removeAll(WorldModel.COW);
+
+ for (int i = 0; i < getWidth(); i++)
for (int j = 0; j < getHeight(); j++)
- cowsrep[i][j] = 0;
-
+ cowsrep[i][j] = 0;
+
cows.clear();
+
+ // rebuild
+ Iterator<Literal> i = bb.getCandidateBeliefs(cowLiteral, null);
+ if (i != null) {
+ while (i.hasNext()) {
+ Literal c = i.next();
+ int x = (int)((NumberTerm)c.getTerm(0)).solve();
+ int y = (int)((NumberTerm)c.getTerm(1)).solve();
+ addCow(x,y);
+ }
+ }
+ isCowsUptodate = true;
}
public void addCow(int x, int y) {
add(WorldModel.COW, x, y);
- cows.add(new Location(x,y));
-
+ cows.add(new Vec( this, x, y));
increp(cowsrep, x, y, 2, 1);
}
- private void increp(int[][] m, int x, int y, int maxr, int value) {
- for (int r = 1; r <= maxr; r++)
- for (int c = x-r; c <= x+r; c++)
- for (int l = y-r; l <= y+r; l++)
- if (inGrid(c,l))
- m[c][l] += value;
- }
-
- public void addCow(Location l) {
- addCow(l.x, l.y);
- }
-
- public Collection<Location> getCows() {
- return cows;
- }
-
+
public int getCowsRep(int x, int y) {
return cowsrep[x][y];
}
@@ -125,6 +145,14 @@
return obsrep[x][y];
}
+ private void increp(int[][] m, int x, int y, int maxr, int value) {
+ for (int r = 1; r <= maxr; r++)
+ for (int c = x-r; c <= x+r; c++)
+ for (int l = y-r; l <= y+r; l++)
+ if (inGrid(c,l))
+ m[c][l] += value;
+ }
+
public Location nearFree(Location l) throws Exception {
int w = 0;
List<Location> options = new ArrayList<Location>();
Modified: trunk/applications/jason-team/src/java/jia/Vec.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -3,6 +3,7 @@
import jason.environment.grid.Location;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.List;
import arch.LocalWorldModel;
@@ -31,6 +32,14 @@
this.t = Math.atan2(y,x);
}
+ /** create a vector based on a location in the model */
+ public Vec(LocalWorldModel model, int x, int y) {
+ this.x = x;
+ this.y = model.getHeight()-y-1;
+ this.r = Math.sqrt(x*x + this.y*this.y);
+ this.t = Math.atan2(this.y,x);
+ }
+
public int getX() { return (int)Math.round(x); }
public int getY() { return (int)Math.round(y); }
public double magnitude() { return r; }
@@ -91,6 +100,10 @@
return ((int)(temp/(Math.PI/2))%4);
}
+ @Override
+ public int hashCode() {
+ return (int)((x + y) * 37);
+ }
@Override
public boolean equals(Object o) {
@@ -123,7 +136,7 @@
// Useful static methods for list of vecs
//
- public static Vec max(List<Vec> vs) {
+ public static Vec max(Collection<Vec> vs) {
Vec max = null;
for (Vec v: vs) {
if (max == null || max.r < v.r)
@@ -132,7 +145,7 @@
return max;
}
- public static List<Vec> sub(List<Vec> vs, Vec ref) {
+ public static List<Vec> sub(Collection<Vec> vs, Vec ref) {
List<Vec> r = new ArrayList<Vec>(vs.size());
for (Vec v: vs) {
r.add(v.sub(ref));
@@ -157,7 +170,7 @@
}
*/
- public static Vec mean(List<Vec> vs) {
+ public static Vec mean(Collection<Vec> vs) {
if (vs.isEmpty())
return new Vec(0,0);
double x = 0, y = 0;
@@ -168,7 +181,7 @@
return new Vec(x/vs.size(), y/vs.size());
}
- public static Vec stddev(List<Vec> vs, Vec mean) {
+ public static Vec stddev(Collection<Vec> vs, Vec mean) {
if (vs.isEmpty())
return new Vec(0,0);
double x = 0, y = 0;
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -12,6 +12,7 @@
import jason.environment.grid.Location;
import java.util.ArrayList;
+import java.util.Collection;
import java.util.Collections;
import java.util.Iterator;
import java.util.List;
@@ -50,6 +51,7 @@
};
LocalWorldModel model;
+ List<Location> lastCluster = null;
public void setModel(LocalWorldModel model) {
this.model = model;
@@ -84,7 +86,7 @@
return un.unifies(args[1], new NumberTermImpl(agTarget.x)) &&
un.unifies(args[2], new NumberTermImpl(agTarget.y));
} else {
- ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(formation));
+ ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(formation)+" cluster is "+lastCluster);
}
} else {
// return all the locations for the formation
@@ -139,20 +141,18 @@
}
private List<Location> formationPlaces(Formation formation) throws Exception {
- List<Vec> cows = new ArrayList<Vec>();
- for (Location c: model.getCows()) {
- cows.add(new Vec(model, c));
- }
- if (cows.isEmpty())
- return null;
-
//cows = Vec.cluster(cows, 2); // find center/clusterise
- cows = cluster(cows, WorldModel.cowPerceptionRatio);
+ List<Vec>cows = cluster(model.getCows(), WorldModel.cowPerceptionRatio);
+
List<Location> clusterLocs = new ArrayList<Location>();
for (Vec v: cows) {
clusterLocs.add(v.getLocation(model));
}
+ lastCluster = clusterLocs;
+
+ if (cows.isEmpty())
+ return null;
Vec mean = Vec.mean(cows);
int stepsFromCenter = (int)Math.round(Vec.max(cows).sub(mean).magnitude())+1;
@@ -240,7 +240,7 @@
return t;
}
- public static List<Vec> cluster(List<Vec> cows, int maxDist) {
+ public static List<Vec> cluster(Collection<Vec> cows, int maxDist) {
/*
Vs = set of all seen cows (sorted by distance to the centre of cluster)
Cs = { the cow near to the center of Vs }
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-28 17:38:52 UTC (rev 1276)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-28 20:54:41 UTC (rev 1277)
@@ -22,13 +22,12 @@
public class TestBasicHerding {
- Vec[] cows;
Vec cowboy;
LocalWorldModel model;
@Before
public void scenario() {
- model = new LocalWorldModel(50,50);
+ model = new LocalWorldModel(50,50, WorldModel.agPerceptionRatio, null);
model.setCorral(new Location(0,49), new Location(2,49));
model.wall(7, 44, 7, 49);
}
@@ -37,38 +36,51 @@
cowboy = new Vec(3,5);
model.add(WorldModel.AGENT, cowboy.getLocation(model));
- cows = new Vec[5];
- cows[0] = new Vec(6,7);
- cows[1] = new Vec(5,30);
- cows[2] = new Vec(4,8);
- cows[3] = new Vec(5,10);
- cows[4] = new Vec(0,1);
-
- for (int i=0; i<cows.length; i++)
- model.addCow(cows[i].getLocation(model));
-
+ addToModel(
+ new Vec(6,7),
+ new Vec(5,30),
+ new Vec(4,8),
+ new Vec(5,10),
+ new Vec(0,1));
}
public void scenario2() {
cowboy = new Vec(11,3);
model.add(WorldModel.AGENT, cowboy.getLocation(model));
- cows = new Vec[9];
- cows[0] = new Vec(8,0);
- cows[1] = new Vec(9,0);
- cows[2] = new Vec(10,0);
- cows[3] = new Vec(8,1);
- cows[4] = new Vec(9,1);
- cows[5] = new Vec(10,1);
- cows[6] = new Vec(8,2);
- cows[7] = new Vec(9,2);
- cows[8] = new Vec(10,2);
+ addToModel(
+ new Vec(8,0),
+ new Vec(9,0),
+ new Vec(10,0),
+ new Vec(8,1),
+ new Vec(9,1),
+ new Vec(10,1),
+ new Vec(8,2),
+ new Vec(9,2),
+ new Vec(10,2));
+ }
- for (int i=0; i<cows.length; i++)
- model.addCow(cows[i].getLocation(model));
+ @Test
+ public void bigCluster() {
+ // big cluster
+ for (int x = 10; x < 30; x++) {
+ for (int y = 5; y < 20; y++) {
+ addToModel(new Vec(model,x,y));
+ }
+ }
+ List<Vec> cowsl = herd_position.cluster(model.getCows(), WorldModel.cowPerceptionRatio);
+ assertEquals(model.getCows().size(), cowsl.size());
}
+
+ private void addToModel(Vec... cows) {
+ for (int i=0; i<cows.length; i++) {
+ Location l = cows[i].getLocation(model);
+ model.addCow(l.x, l.y);
+ }
+ }
+
@Test
public void testVec() {
scenario1();
@@ -85,10 +97,7 @@
public void testVecSort() {
scenario1();
- List<Vec> cowsl = new ArrayList<Vec>();
- for (int i=0; i<cows.length; i++) {
- cowsl.add(cows[i]);
- }
+ List<Vec> cowsl = new ArrayList<Vec>(model.getCows());
Collections.sort(cowsl);
assertEquals(new Vec(0,1), cowsl.get(0));
assertEquals(new Vec(4,8), cowsl.get(1));
@@ -146,13 +155,8 @@
public void moveCows2() throws Exception {
scenario1();
- List<Vec> cowsl = new ArrayList<Vec>();
- for (int i=0; i<cows.length; i++) {
- cowsl.add(cows[i]);
- }
-
// find center/clusterise
- cowsl = herd_position.cluster(cowsl, WorldModel.cowPerceptionRatio);
+ List<Vec> cowsl = herd_position.cluster(model.getCows(), WorldModel.cowPerceptionRatio);
//Vec stddev = Vec.stddev(cowsl, Vec.mean(cowsl));
assertEquals(3, cowsl.size());
@@ -205,12 +209,7 @@
scenario2();
model.add(WorldModel.ENEMY, 11,48);
- List<Vec> cowsl = new ArrayList<Vec>();
- for (int i=0; i<cows.length; i++) {
- cowsl.add(cows[i]);
- }
-
- cowsl = herd_position.cluster(cowsl, WorldModel.cowPerceptionRatio);
+ List<Vec> cowsl = herd_position.cluster(model.getCows(), WorldModel.cowPerceptionRatio);
assertEquals(9, cowsl.size());
herd_position hp = new herd_position();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-28 17:39:03
|
Revision: 1276
http://jason.svn.sourceforge.net/jason/?rev=1276&view=rev
Author: jomifred
Date: 2008-04-28 10:38:52 -0700 (Mon, 28 Apr 2008)
Log Message:
-----------
jason team: new cluster alg
Modified Paths:
--------------
trunk/applications/jason-team/src/java/jia/Vec.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
Modified: trunk/applications/jason-team/src/java/jia/Vec.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-27 18:25:28 UTC (rev 1275)
+++ trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-28 17:38:52 UTC (rev 1276)
@@ -8,7 +8,7 @@
import arch.LocalWorldModel;
-public final class Vec implements Cloneable {
+public final class Vec implements Cloneable, Comparable<Vec> {
// immutable fields (for a immutable object)
public final double x,y;
@@ -67,22 +67,7 @@
public Vec newMagnitude(double r) {
return new Vec(r*Math.cos(t), r*Math.sin(t));
}
- @Override
- public boolean equals(Object o) {
- if (o == null) return false;
- if (o == this) return true;
- if (o instanceof Vec) {
- Vec v = (Vec)o;
- return (getX() == v.getX()) && (getY() == v.getY());
- }
- return false;
- }
-
- public Object clone() {
- return this; // it is an immutable object, no need to create a new one
- }
-
/**
* Provides info on which octant (0-7) the vector lies in.
* 0 indicates 0 radians +- PI/8 1-7 continue CCW.
@@ -106,7 +91,34 @@
return ((int)(temp/(Math.PI/2))%4);
}
+
+ @Override
+ public boolean equals(Object o) {
+ if (o == null) return false;
+ if (o == this) return true;
+ if (o instanceof Vec) {
+ Vec v = (Vec)o;
+ return (getX() == v.getX()) && (getY() == v.getY());
+ }
+ return false;
+ }
+
+ public int compareTo(Vec o) {
+ if (r > o.r) return 1;
+ if (r < o.r) return -1;
+ return 0;
+ }
+ public Object clone() {
+ return this; // it is an immutable object, no need to create a new one
+ }
+
+
+ @Override
+ public String toString() {
+ return getX() + "," + getY();
+ }
+
//
// Useful static methods for list of vecs
//
@@ -128,6 +140,7 @@
return r;
}
+ /*
public static List<Vec> cluster(List<Vec> vs, int maxstddev) {
vs = new ArrayList<Vec>(vs); // result vectors in the cluster
Vec mean = Vec.mean(vs);
@@ -142,6 +155,7 @@
}
return vs;
}
+ */
public static Vec mean(List<Vec> vs) {
if (vs.isEmpty())
@@ -168,9 +182,4 @@
return new Vec( Math.sqrt(x), Math.sqrt(y));
}
-
- @Override
- public String toString() {
- return getX() + "," + getY();
- }
}
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 18:25:28 UTC (rev 1275)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-28 17:38:52 UTC (rev 1276)
@@ -12,6 +12,8 @@
import jason.environment.grid.Location;
import java.util.ArrayList;
+import java.util.Collections;
+import java.util.Iterator;
import java.util.List;
import java.util.logging.Level;
@@ -34,7 +36,7 @@
public static final double maxStdDev = 3;
public static final int agDistanceInFormation = 4;
-
+
public enum Formation {
one { int[] getDistances() { return new int[] { 0 }; } },
two { int[] getDistances() { return new int[] { sd, -sd }; } },
@@ -47,14 +49,20 @@
private static final int sd = agDistanceInFormation/2;
};
+ LocalWorldModel model;
+
+ public void setModel(LocalWorldModel model) {
+ this.model = model;
+ }
+
@Override
public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
try {
CowboyArch arch = (CowboyArch)ts.getUserAgArch();
- LocalWorldModel model = arch.getModel();
+ model = arch.getModel();
if (model == null)
return false;
- Location agLoc = model.getAgPos(arch.getMyId());
+ Location agLoc = model.getAgPos(arch.getMyId());
// identify the formation id
Formation formation = Formation.six;
@@ -67,20 +75,20 @@
// update GUI
if (arch.hasGUI())
- setFormationLoc(model, formation);
+ setFormationLoc(formation);
// if the return is a location for one agent
if (args.length == 3) {
- Location agTarget = getAgTarget(model, formation, agLoc);
+ Location agTarget = getAgTarget(formation, agLoc);
if (agTarget != null) {
return un.unifies(args[1], new NumberTermImpl(agTarget.x)) &&
un.unifies(args[2], new NumberTermImpl(agTarget.y));
} else {
- ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(model, formation));
+ ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(formation));
}
} else {
// return all the locations for the formation
- List<Location> locs = formationPlaces(model, formation);
+ List<Location> locs = formationPlaces(formation);
if (locs != null) {
ListTerm r = new ListTermImpl();
ListTerm tail = r;
@@ -91,7 +99,7 @@
}
return un.unifies(args[1], r);
} else {
- ts.getLogger().info("No formation possible! I am at "+agLoc+" places are "+formationPlaces(model, formation));
+ ts.getLogger().info("No formation possible! I am at "+agLoc+" places are "+formationPlaces(formation));
}
}
} catch (Throwable e) {
@@ -100,9 +108,9 @@
return false;
}
- public Location getAgTarget(LocalWorldModel model, Formation formation, Location ag) throws Exception {
+ public Location getAgTarget(Formation formation, Location ag) throws Exception {
Location r = null;
- List<Location> locs = formationPlaces(model, formation);
+ List<Location> locs = formationPlaces(formation);
if (locs != null) {
for (Location l : locs) {
if (ag.equals(l) || // I am there
@@ -118,9 +126,9 @@
return r;
}
- public void setFormationLoc(LocalWorldModel model, Formation formation) throws Exception {
+ public void setFormationLoc(Formation formation) throws Exception {
model.removeAll(WorldModel.FORPLACE);
- List<Location> locs = formationPlaces(model, formation);
+ List<Location> locs = formationPlaces(formation);
if (locs != null) {
for (Location l : locs) {
if (model.inGrid(l)) {
@@ -130,7 +138,7 @@
}
}
- private List<Location> formationPlaces(LocalWorldModel model, Formation formation) throws Exception {
+ private List<Location> formationPlaces(Formation formation) throws Exception {
List<Vec> cows = new ArrayList<Vec>();
for (Location c: model.getCows()) {
cows.add(new Vec(model, c));
@@ -138,8 +146,14 @@
if (cows.isEmpty())
return null;
- cows = Vec.cluster(cows, 2); // find center/clusterise
+ //cows = Vec.cluster(cows, 2); // find center/clusterise
+ cows = cluster(cows, WorldModel.cowPerceptionRatio);
+ List<Location> clusterLocs = new ArrayList<Location>();
+ for (Vec v: cows) {
+ clusterLocs.add(v.getLocation(model));
+ }
+
Vec mean = Vec.mean(cows);
int stepsFromCenter = (int)Math.round(Vec.max(cows).sub(mean).magnitude())+1;
//Vec max = Vec.max(cows);
@@ -167,7 +181,7 @@
Location l = findFirstFreeLocTowardsTarget(agTarget, mean.add(agsTarget), initAgTS, dist, model);
//System.out.println(" = "+dist+" result "+l);
if (l != null)
- r.add(pathToNearCow(model, l));
+ r.add(pathToNearCow(l, clusterLocs));
/*
Location lastloc = null;
@@ -207,9 +221,9 @@
return l; //ref.getLocation(model); //target.add(ref).getLocation(model);
}
- private Location pathToNearCow(LocalWorldModel model, Location t) {
+ private Location pathToNearCow(Location t, List<Location> cluster) {
Location near = null;
- for (Location c: model.getCows()) {
+ for (Location c: cluster) {
if (near == null || t.maxBorder(c) < t.maxBorder(near))
near = c;
}
@@ -226,6 +240,59 @@
return t;
}
+ public static List<Vec> cluster(List<Vec> cows, int maxDist) {
+ /*
+ Vs = set of all seen cows (sorted by distance to the centre of cluster)
+ Cs = { the cow near to the center of Vs }
+
+ add = true
+ while (add)
+ add = false
+ for all v in Vs
+ if (some cow in Cs sees v)
+ move v from Vs to Cs
+ add = true
+ */
+ Vec mean = Vec.mean(cows);
+ List<Vec> vs = new ArrayList<Vec>();
+ // place all cows in ref to mean
+ for (Vec v: cows)
+ vs.add(v.sub(mean));
+
+ Collections.sort(vs);
+
+ List<Vec> cs = new ArrayList<Vec>();
+ if (!vs.isEmpty())
+ cs.add(vs.remove(0));
+
+ boolean add = true;
+ while (add) {
+ add = false;
+ Iterator<Vec> i = vs.iterator();
+ while (i.hasNext()) {
+ Vec v = i.next();
+
+ Iterator<Vec> j = cs.iterator();
+ while (j.hasNext()) {
+ Vec c = j.next();
+ if (c.sub(v).magnitude() < maxDist) {
+ cs.add(v);
+ i.remove();
+ add = true;
+ break;
+ }
+ }
+ }
+ }
+
+ List<Vec> r = new ArrayList<Vec>();
+ // place all cows in ref to 0,0
+ for (Vec v: cs)
+ r.add(v.add(mean));
+ return r;
+ }
+
+
/*
public Location nearFreeForAg(LocalWorldModel model, Location ag, Location t) throws Exception {
// run A* to get the path from ag to t
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-27 18:25:28 UTC (rev 1275)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-28 17:38:52 UTC (rev 1276)
@@ -1,10 +1,10 @@
package test;
import static org.junit.Assert.assertEquals;
-import static org.junit.Assert.assertTrue;
import jason.environment.grid.Location;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.List;
import jia.Search;
@@ -70,7 +70,7 @@
}
@Test
- public void testVect() {
+ public void testVec() {
scenario1();
//assertEquals(new Vec(6,7), cow.add(cowboy));
//assertEquals(new Location(6,42), cow.add(cowboy).getLocation(model));
@@ -80,6 +80,22 @@
Vec v = new Vec(3,2);
assertEquals(v, v.newAngle(v.angle()));
}
+
+ @Test
+ public void testVecSort() {
+ scenario1();
+
+ List<Vec> cowsl = new ArrayList<Vec>();
+ for (int i=0; i<cows.length; i++) {
+ cowsl.add(cows[i]);
+ }
+ Collections.sort(cowsl);
+ assertEquals(new Vec(0,1), cowsl.get(0));
+ assertEquals(new Vec(4,8), cowsl.get(1));
+ assertEquals(new Vec(6,7), cowsl.get(2));
+ assertEquals(new Vec(5,10), cowsl.get(3));
+ assertEquals(new Vec(5,30), cowsl.get(4));
+ }
@Test
public void testCowsRepMat() throws Exception {
@@ -136,9 +152,9 @@
}
// find center/clusterise
- cowsl = Vec.cluster(cowsl, 2);
- Vec stddev = Vec.stddev(cowsl, Vec.mean(cowsl));
- assertTrue(stddev.magnitude() < 3);
+ cowsl = herd_position.cluster(cowsl, WorldModel.cowPerceptionRatio);
+ //Vec stddev = Vec.stddev(cowsl, Vec.mean(cowsl));
+ assertEquals(3, cowsl.size());
Vec mean = Vec.mean(cowsl);
assertEquals(new Vec(5,8), mean);
@@ -149,30 +165,33 @@
int stepsFromCenter = (int)Math.round(Vec.max(cowsl).sub(mean).magnitude())+1;
assertEquals(3, stepsFromCenter);
- Location byIA = new herd_position().getAgTarget(model, Formation.one, cowboy.getLocation(model));
+ herd_position hp = new herd_position();
+ hp.setModel(model);
+
+ Location byIA = hp.getAgTarget(Formation.one, cowboy.getLocation(model));
assertEquals(new Location(6,38), byIA);
- byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
+ byIA = hp.getAgTarget(Formation.six, cowboy.getLocation(model));
assertEquals(new Location(6,39), byIA);
// add an agent in 6,39
model.add(WorldModel.AGENT, 6,39);
- byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
+ byIA = hp.getAgTarget(Formation.six, cowboy.getLocation(model));
assertEquals(new Location(5,38), byIA);
// add an agent in 5,38
model.add(WorldModel.AGENT, 5,38);
- byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
+ byIA = hp.getAgTarget(Formation.six,cowboy.getLocation(model));
assertEquals(new Location(7,42), byIA);
// add an agent in 7,42
model.add(WorldModel.AGENT, 7,42);
- byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
+ byIA = hp.getAgTarget(Formation.six,cowboy.getLocation(model));
assertEquals(new Location(4,38), byIA);
// add an agent in 4,38
model.add(WorldModel.AGENT, 4,38);
- byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
+ byIA = hp.getAgTarget(Formation.six,cowboy.getLocation(model));
assertEquals(null, byIA);
// add an agent in 5,37
@@ -185,7 +204,19 @@
public void moveCows3() throws Exception {
scenario2();
model.add(WorldModel.ENEMY, 11,48);
- Location byIA = new herd_position().getAgTarget(model, Formation.one, cowboy.getLocation(model));
+
+ List<Vec> cowsl = new ArrayList<Vec>();
+ for (int i=0; i<cows.length; i++) {
+ cowsl.add(cows[i]);
+ }
+
+ cowsl = herd_position.cluster(cowsl, WorldModel.cowPerceptionRatio);
+ assertEquals(9, cowsl.size());
+
+ herd_position hp = new herd_position();
+ hp.setModel(model);
+
+ Location byIA = hp.getAgTarget(Formation.one, cowboy.getLocation(model));
assertEquals(new Location(11,49), byIA);
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 18:25:32
|
Revision: 1275
http://jason.svn.sourceforge.net/jason/?rev=1275&view=rev
Author: jomifred
Date: 2008-04-27 11:25:28 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
add a constant to define the distance between agents in a formation
Modified Paths:
--------------
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/src/jason/stdlib/wait.java
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 18:11:57 UTC (rev 1274)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 18:25:28 UTC (rev 1275)
@@ -33,15 +33,18 @@
public class herd_position extends DefaultInternalAction {
public static final double maxStdDev = 3;
+ public static final int agDistanceInFormation = 4;
public enum Formation {
one { int[] getDistances() { return new int[] { 0 }; } },
- two { int[] getDistances() { return new int[] { 2, -2 }; } },
- three { int[] getDistances() { return new int[] { 0, 4, -4 }; } },
- four { int[] getDistances() { return new int[] { 2, -2, 6, -6 }; } },
- five { int[] getDistances() { return new int[] { 0, 4, -4, 8, -8 }; } },
- six { int[] getDistances() { return new int[] { 2, -2, 6, -6, 10, -10 }; } };
+ two { int[] getDistances() { return new int[] { sd, -sd }; } },
+ three { int[] getDistances() { return new int[] { 0, d, -d }; } },
+ four { int[] getDistances() { return new int[] { sd, -sd, d+sd, -(d+sd) }; } },
+ five { int[] getDistances() { return new int[] { 0, d, -d, d*2, -d*2 }; } },
+ six { int[] getDistances() { return new int[] { sd, -sd, d+sd, -(d+sd), d*2+sd, -(d*2+sd) }; } };
abstract int[] getDistances();
+ private static final int d = agDistanceInFormation;
+ private static final int sd = agDistanceInFormation/2;
};
@Override
Modified: trunk/src/jason/stdlib/wait.java
===================================================================
--- trunk/src/jason/stdlib/wait.java 2008-04-27 18:11:57 UTC (rev 1274)
+++ trunk/src/jason/stdlib/wait.java 2008-04-27 18:25:28 UTC (rev 1275)
@@ -54,7 +54,7 @@
<code>"+!go(X,Y)"</code>.
Although the argument is a string, the variables
- in the string will be unified with the event, i.e., the unifier have
+ in the string will be unified with the event, i.e., the unifier might have
values for X and Y after the execution of <code>.wait("+!go(X,Y)")</code>.
<p>Parameters:<ul>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 18:12:03
|
Revision: 1274
http://jason.svn.sourceforge.net/jason/?rev=1274&view=rev
Author: jomifred
Date: 2008-04-27 11:11:57 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
add comment in wait.java
Modified Paths:
--------------
trunk/src/jason/stdlib/wait.java
Modified: trunk/src/jason/stdlib/wait.java
===================================================================
--- trunk/src/jason/stdlib/wait.java 2008-04-27 18:05:25 UTC (rev 1273)
+++ trunk/src/jason/stdlib/wait.java 2008-04-27 18:11:57 UTC (rev 1274)
@@ -51,7 +51,11 @@
<p>Description: suspend the intention for the time specified by <i>T</i> (in
milliseconds) or until some event <i>E</i> happens. The events are
strings in AgentSpeak syntax, e.g. <code>"+bel(33)"</code>,
- <code>"+!go(X,Y)"</code>.
+ <code>"+!go(X,Y)"</code>.
+
+ Although the argument is a string, the variables
+ in the string will be unified with the event, i.e., the unifier have
+ values for X and Y after the execution of <code>.wait("+!go(X,Y)")</code>.
<p>Parameters:<ul>
<li><i>+ event</i> (string): the event to wait for.<br/>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 18:05:27
|
Revision: 1273
http://jason.svn.sourceforge.net/jason/?rev=1273&view=rev
Author: jomifred
Date: 2008-04-27 11:05:25 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
jason team: add path_length.java
Modified Paths:
--------------
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/herding.asl
Added Paths:
-----------
trunk/applications/jason-team/src/java/jia/path_length.java
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 17:57:30 UTC (rev 1272)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 18:05:25 UTC (rev 1273)
@@ -66,7 +66,7 @@
// find distance to even agents
.findall(ag_d(D,AgName),
- ally_pos(AgName,X,Y) & agent_id(AgName,Id) & Id mod 2 == 0 & jia.dist(MyX, MyY, X, Y, D),
+ ally_pos(AgName,X,Y) & agent_id(AgName,Id) & Id mod 2 == 0 & jia.path_length(MyX, MyY, X, Y, D),
LOdd);
.sort(LOdd, LSOdd);
Modified: trunk/applications/jason-team/src/asl/herding.asl
===================================================================
--- trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 17:57:30 UTC (rev 1272)
+++ trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 18:05:25 UTC (rev 1273)
@@ -36,7 +36,7 @@
// TODO: use min
+!closest([],S,S,P,D).
+!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
- : jia.dist(XH,YH,XP,YP,D) & D < LD // usar A*
+ : jia.path_length(XH,YH,XP,YP,D) & D < LD // usar A*
<- !closest(T,[pos(XH,YH)|Aux],S,pos(XP,YP),D).
+!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
<- .concat(Aux,[pos(XH,YH)],Aux2);
Added: trunk/applications/jason-team/src/java/jia/path_length.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/path_length.java (rev 0)
+++ trunk/applications/jason-team/src/java/jia/path_length.java 2008-04-27 18:05:25 UTC (rev 1273)
@@ -0,0 +1,51 @@
+package jia;
+
+import jason.asSemantics.DefaultInternalAction;
+import jason.asSemantics.TransitionSystem;
+import jason.asSemantics.Unifier;
+import jason.asSyntax.NumberTerm;
+import jason.asSyntax.NumberTermImpl;
+import jason.asSyntax.Term;
+import jason.environment.grid.Location;
+
+import java.util.logging.Level;
+
+import arch.CowboyArch;
+import arch.LocalWorldModel;
+import busca.Nodo;
+
+public class path_length extends DefaultInternalAction {
+
+ @Override
+ public Object execute(TransitionSystem ts, Unifier un, Term[] terms) throws Exception {
+ try {
+ LocalWorldModel model = ((CowboyArch)ts.getUserAgArch()).getModel();
+
+ int iagx = (int)((NumberTerm)terms[0]).solve();
+ int iagy = (int)((NumberTerm)terms[1]).solve();
+ int itox = (int)((NumberTerm)terms[2]).solve();
+ int itoy = (int)((NumberTerm)terms[3]).solve();
+
+ if (model.inGrid(itox,itoy)) {
+
+ // destination should be a free place
+ while (!model.isFreeOfObstacle(itox,itoy) && itox > 0) itox--;
+ while (!model.isFreeOfObstacle(itox,itoy) && itox < model.getWidth()) itox++;
+
+ Location from = new Location(iagx, iagy);
+ Location to = new Location(itox, itoy);
+
+ Nodo solution = new Search(model, from, to, ts.getUserAgArch()).search();
+ if (solution != null) {
+ int length = solution.getProfundidade();
+ return un.unifies(terms[4], new NumberTermImpl(length));
+ } else {
+ ts.getLogger().info("No route from "+from+" to "+to+"!"+"\n"+model);
+ }
+ }
+ } catch (Throwable e) {
+ ts.getLogger().log(Level.SEVERE, "jia.path_length error: "+e, e);
+ }
+ return false;
+ }
+}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 17:57:31
|
Revision: 1272
http://jason.svn.sourceforge.net/jason/?rev=1272&view=rev
Author: jomifred
Date: 2008-04-27 10:57:30 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
add internal action scouter_pos
Modified Paths:
--------------
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/java/env/WorldModel.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
Added Paths:
-----------
trunk/applications/jason-team/src/java/jia/scouter_pos.java
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 14:10:17 UTC (rev 1271)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 17:57:30 UTC (rev 1272)
@@ -133,9 +133,17 @@
-+target(LX,LY)
}, {
.print("ooo being in formation with leader.");
- do(skip)
+ .send(Leader,askOne,target(X,Y),target(TX,TY));
+ jia.scouter_pos(LX, LY, TX, TY, SX, SY);
+ -+target(SX,SY)
});
.wait("+pos(_,_,_)"); // wait next cycle
!!follow_leader[scheme(Sch),group(Gr)].
+-!follow_leader[scheme(Sch),group(Gr)]
+ <- .current_intention(I);
+ .print("ooo Failure to follow_leader ",I);
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!follow_leader[scheme(Sch),group(Gr)].
+
\ No newline at end of file
Modified: trunk/applications/jason-team/src/java/env/WorldModel.java
===================================================================
--- trunk/applications/jason-team/src/java/env/WorldModel.java 2008-04-27 14:10:17 UTC (rev 1271)
+++ trunk/applications/jason-team/src/java/env/WorldModel.java 2008-04-27 17:57:30 UTC (rev 1272)
@@ -23,7 +23,7 @@
public static final int agsByTeam = 6;
- public static final int agPerceptionRatio = 8;
+ public static final int agPerceptionRatio = 8;
public static final int cowPerceptionRatio = 4;
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 14:10:17 UTC (rev 1271)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 17:57:30 UTC (rev 1272)
@@ -186,11 +186,11 @@
if (dist < 0)
initAgTS = Math.abs(dist)+1;
}
- System.out.println("all places "+r);
+ //System.out.println("all places "+r);
return r;
}
- private Location findFirstFreeLocTowardsTarget(Vec target, Vec ref, int initialSize, int maxSize, LocalWorldModel model) {
+ public static Location findFirstFreeLocTowardsTarget(Vec target, Vec ref, int initialSize, int maxSize, LocalWorldModel model) {
Location lastloc = null;
maxSize = Math.abs(maxSize);
Location l = ref.getLocation(model);;
Added: trunk/applications/jason-team/src/java/jia/scouter_pos.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/scouter_pos.java (rev 0)
+++ trunk/applications/jason-team/src/java/jia/scouter_pos.java 2008-04-27 17:57:30 UTC (rev 1272)
@@ -0,0 +1,63 @@
+package jia;
+
+import jason.asSemantics.DefaultInternalAction;
+import jason.asSemantics.TransitionSystem;
+import jason.asSemantics.Unifier;
+import jason.asSyntax.NumberTerm;
+import jason.asSyntax.NumberTermImpl;
+import jason.asSyntax.Term;
+import jason.environment.grid.Location;
+
+import java.util.logging.Level;
+
+import arch.CowboyArch;
+import arch.LocalWorldModel;
+import env.WorldModel;
+
+/**
+ * Gives a good location for the scouter
+ *
+ * jia.scouter_pos( LeaderPos, LeaderTarget, Return).
+ *
+ * Example: jia.scouter_pos( 2,2, 5,6, X, Y)
+ *
+ * @author jomi
+ */
+public class scouter_pos extends DefaultInternalAction {
+
+ @Override
+ public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
+ try {
+ CowboyArch arch = (CowboyArch)ts.getUserAgArch();
+ LocalWorldModel model = arch.getModel();
+ if (model == null)
+ return false;
+
+ int lx = (int)((NumberTerm)args[0]).solve();
+ int ly = (int)((NumberTerm)args[1]).solve();
+ int tx = (int)((NumberTerm)args[2]).solve();
+ int ty = (int)((NumberTerm)args[3]).solve();
+ Location leaderPos = new Location(lx, ly);
+ Location leaderTarget = new Location(tx, ty);
+
+ Location agTarget = getScouterTarget(model, leaderPos, leaderTarget);
+ if (agTarget != null) {
+ return un.unifies(args[4], new NumberTermImpl(agTarget.x)) &&
+ un.unifies(args[5], new NumberTermImpl(agTarget.y));
+ } else {
+ ts.getLogger().info("No target for scouter!");
+ }
+ } catch (Throwable e) {
+ ts.getLogger().log(Level.SEVERE, "scouter_pos error: "+e, e);
+ }
+ return false;
+ }
+
+ public Location getScouterTarget(LocalWorldModel model, Location leaderPos, Location leaderTarget) throws Exception {
+ Vec leader = new Vec(model, leaderPos);
+ Vec target = new Vec(model, leaderTarget).sub(leader);
+ target = target.turn90CW();
+ return herd_position.findFirstFreeLocTowardsTarget(target, leader, 1, WorldModel.agPerceptionRatio*2-3, model);
+ }
+}
+
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-27 14:10:17 UTC (rev 1271)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-27 17:57:30 UTC (rev 1272)
@@ -10,6 +10,7 @@
import jia.Search;
import jia.Vec;
import jia.herd_position;
+import jia.scouter_pos;
import jia.herd_position.Formation;
import org.junit.Before;
@@ -188,6 +189,19 @@
assertEquals(new Location(11,49), byIA);
}
+ @Test
+ public void scouterPos() throws Exception {
+ scenario1();
+ Location byIA = new scouter_pos().getScouterTarget(model, new Location(2,46), new Location(6,42));
+ assertEquals(new Location(5,49), byIA);
+
+ byIA = new scouter_pos().getScouterTarget(model, new Location(2,46), new Location(3,42));
+ assertEquals(new Location(6,47), byIA);
+
+ byIA = new scouter_pos().getScouterTarget(model, new Location(9,46), new Location(9,42));
+ assertEquals(new Location(22,46), byIA);
+ }
+
/*
@Test
public void oneCow() throws Exception {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 14:10:21
|
Revision: 1271
http://jason.svn.sourceforge.net/jason/?rev=1271&view=rev
Author: jomifred
Date: 2008-04-27 07:10:17 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
the creation of groups/schemes for exploration are ok
start coding the scouter (not finished)
Modified Paths:
--------------
trunk/applications/jason-moise/src/jmoise/OrgAgent.java
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/asl/herding.asl
trunk/applications/jason-team/src/java/arch/WriteStatusThread.java
trunk/applications/jason-team/src/java/jia/herd_position.java
Modified: trunk/applications/jason-moise/src/jmoise/OrgAgent.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-27 14:10:17 UTC (rev 1271)
@@ -30,10 +30,12 @@
import java.util.logging.Logger;
import moise.oe.GoalInstance;
+import moise.oe.GroupInstance;
import moise.oe.MissionPlayer;
import moise.oe.OE;
import moise.oe.OEAgent;
import moise.oe.Permission;
+import moise.oe.RolePlayer;
import moise.oe.SchemeInstance;
import moise.os.fs.Goal;
import moise.os.fs.Goal.GoalType;
@@ -185,8 +187,9 @@
}
private void generateOrgGoalEvents() {
- for (GoalInstance gi : getMyOEAgent().getPossibleGoals()) {
- if (!alreadyGeneratedEvents.contains(gi)) {
+ OEAgent me = getMyOEAgent();
+ for (GoalInstance gi : getMyOEAgent().getPossibleGoals()) {
+ if (!alreadyGeneratedEvents.contains(gi)) {
alreadyGeneratedEvents.add(gi);
Literal l = Literal.parseLiteral(gi.getAsProlog());
@@ -203,13 +206,25 @@
// add source annot
l.addAnnot(managerSource);
- // "role(notimplemented),group(notimplemented)"+
- // TODO: add annots: role, group (percorrer as missoes do ag que
- // em GI, procurar os papel com obrigacao para essa missao)
+ // try to find the role/group of this goal
+ // (the first all resp group of the scheme where I am)
+ for (GroupInstance g: gi.getScheme().getResponsibleGroups()) {
+ for (RolePlayer rp: g.getPlayers()) {
+ if (rp.getPlayer().equals(me)) {
+ Structure role = new Structure("role");
+ role.addTerm(new Atom(rp.getRole().getId()));
+ l.addAnnot(role);
+
+ Structure group = new Structure("group");
+ group.addTerm(new Atom(rp.getGroup().getId()));
+ l.addAnnot(group);
+ }
+ }
+ }
getTS().updateEvents(new Event(new Trigger(TEOperator.add, TEType.achieve, l), Intention.EmptyInt));
if (logger.isLoggable(Level.FINE)) logger.fine("New goal: " + l);
- }
- }
+ }
+ }
}
private static final Atom aAchievementGoal = new Atom(GoalType.achievement.toString());
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 14:10:17 UTC (rev 1271)
@@ -119,9 +119,23 @@
/* -- plans for the goals of role scouter -- */
-+!follow_leader[scheme(Sch)]
- <- .print("ooo I should follow the leader!");
- // TODO:
++!follow_leader[scheme(Sch),group(Gr)]
+ : play(Leader, explorer, Gr)
+ <- .print("ooo I should follow the leader ",Leader);
+ ?pos(MyX,MyY,_);
+ ?ally_pos(Leader,LX,LY);
+ ?ag_perception_ratio(AGPR);
+ jia.dist(MyX, MyY, LX, LY, DistanceToLeader);
+
+ // If I am far from him, go to him
+ .if( DistanceToLeader > (AGPR * 2) -3, {
+ .print("ooo Approaching leader.");
+ -+target(LX,LY)
+ }, {
+ .print("ooo being in formation with leader.");
+ do(skip)
+ });
+
.wait("+pos(_,_,_)"); // wait next cycle
- !!follow_leader[scheme(Sch)].
+ !!follow_leader[scheme(Sch),group(Gr)].
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-27 14:10:17 UTC (rev 1271)
@@ -46,14 +46,15 @@
+end_of_simulation(_Result)
<- .abolish(group_area(_,_,_)).
-+!restart
- <- .print("*** restart ***");
++!restart.
+
+/* <- .print("*** restart ***").
//.drop_all_desires;
- .abolish(target(_,_)).
+ //.abolish(target(_,_)).
// TODO: what to do?
//!decide_target.
+*/
-
/* -- plans for the goals of all roles -- */
// get the list G of participants of the group where I play R
Modified: trunk/applications/jason-team/src/asl/herding.asl
===================================================================
--- trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 14:10:17 UTC (rev 1271)
@@ -14,9 +14,8 @@
+!define_formation[scheme(Sch)]
<- .print("ooo I should define the formation of my group!");
- ?my_group(G, herder);
- .length(G,NumP);
- jia.herd_position(NumP,L);
+ ?my_group_players(G, herder);
+ jia.herd_position(.length(G),L);
.print("ooo formation is ",L);
!alloc_all(G,L);
.wait("+pos(_,_,_)"); // wait next cycle
Modified: trunk/applications/jason-team/src/java/arch/WriteStatusThread.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/WriteStatusThread.java 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-team/src/java/arch/WriteStatusThread.java 2008-04-27 14:10:17 UTC (rev 1271)
@@ -102,7 +102,7 @@
}
public String shortActionFormat(String act) {
- if (act == null) return "";
+ if (act == null) return " ";
if (act.equals(WorldModel.Move.east.toString())) return "e ";
if (act.equals(WorldModel.Move.northeast.toString())) return "ne";
if (act.equals(WorldModel.Move.southeast.toString())) return "se";
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 13:25:39 UTC (rev 1270)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 14:10:17 UTC (rev 1271)
@@ -155,14 +155,14 @@
Vec agTarget = agsTarget;
//Location l = agTarget.add(mean).getLocation(model);
- System.out.println("....... "+dist+" antes angle "+agTarget);
+ //System.out.println("....... "+dist+" antes angle "+agTarget);
if (dist >= 0)
agTarget = agTarget.turn90CW();
else
agTarget = agTarget.turn90ACW();
Location l = findFirstFreeLocTowardsTarget(agTarget, mean.add(agsTarget), initAgTS, dist, model);
- System.out.println(" = "+dist+" result "+l);
+ //System.out.println(" = "+dist+" result "+l);
if (l != null)
r.add(pathToNearCow(model, l));
@@ -196,7 +196,7 @@
Location l = ref.getLocation(model);;
for (int s = initialSize; s <= maxSize; s++) {
l = target.newMagnitude(s).add(ref).getLocation(model);
- System.out.println("pos angle "+s+" = "+l);
+ //System.out.println("pos angle "+s+" = "+l);
if ( (!model.inGrid(l) || model.hasObject(WorldModel.OBSTACLE, l)) && lastloc != null)
return lastloc;
lastloc = l;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 13:25:42
|
Revision: 1270
http://jason.svn.sourceforge.net/jason/?rev=1270&view=rev
Author: jomifred
Date: 2008-04-27 06:25:39 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
Jason team: implement some changes as discussed with Rafael
Modified Paths:
--------------
trunk/applications/jason-team/dummies.xml
trunk/applications/jason-team/gauchos.xml
trunk/applications/jason-team/src/asl/dummy.asl
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/asl/herding.asl
trunk/applications/jason-team/src/java/arch/ACArchitecture.java
trunk/applications/jason-team/src/java/arch/ACProxy.java
trunk/applications/jason-team/src/java/arch/CowboyArch.java
trunk/applications/jason-team/src/java/env/WorldView.java
trunk/applications/jason-team/src/java/jia/Vec.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
trunk/applications/jason-team/src/team-os.xml
Modified: trunk/applications/jason-team/dummies.xml
===================================================================
--- trunk/applications/jason-team/dummies.xml 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/dummies.xml 2008-04-27 13:25:39 UTC (rev 1270)
@@ -30,7 +30,6 @@
<target name="user-init">
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
- <copy file="../jason-moise/src/asl/moise-common.asl" todir="src/asl" />
</target>
<target name="user-end">
</target>
Modified: trunk/applications/jason-team/gauchos.xml
===================================================================
--- trunk/applications/jason-team/gauchos.xml 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/gauchos.xml 2008-04-27 13:25:39 UTC (rev 1270)
@@ -30,7 +30,6 @@
<target name="user-init">
<copy file="../jason-moise/lib/jmoise.jar" todir="lib" />
<copy file="../jason-moise/lib/moise.jar" todir="lib" />
- <copy file="../jason-moise/src/asl/moise-common.asl" todir="src/asl" />
</target>
<target name="user-end">
</target>
Modified: trunk/applications/jason-team/src/asl/dummy.asl
===================================================================
--- trunk/applications/jason-team/src/asl/dummy.asl 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/asl/dummy.asl 2008-04-27 13:25:39 UTC (rev 1270)
@@ -30,7 +30,8 @@
pos(AgX,AgY,_) &
jia.random(RX,40) & RX > 5 & X = (RX-20)+AgX & X > 0 &
jia.random(RY,40,5) & RY > 5 & Y = (RY-20)+AgY &
- not jia.obstacle(X,Y).
+ not jia.obstacle(X,Y) &
+ not cell(X,Y,_).
/* -- initial goal */
@@ -47,7 +48,7 @@
// revise target each 4 steps
+pos(Step,_,_) // new cycle
- : Step mod 10 == 0
+ : Step mod 6 == 0
<- !decide_target.
@@ -66,7 +67,6 @@
-+target(X,Y).
+!decide_target // chose a new random pos
- : not cell(_,_,cow(_))
<- ?random_pos(NX,NY);
.print("New random target: ",NX,",",NY);
-+goal(search);
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-27 13:25:39 UTC (rev 1270)
@@ -3,11 +3,6 @@
/* -- initial beliefs -- */
-// missions I can commit to depend on the roles I adopt
-desired_mission(explore_sch, explore) :- desired_role(exploration_grp, explorer).
-desired_mission(explore_sch, scout) :- desired_role(exploration_grp, scouter).
-
-
/* -- initial goals -- */
//!test.
@@ -19,11 +14,10 @@
*/
-/* plans for agent 1 */
+/* plans for the team's groups creation */
-+gsize(_Weight,_Height) // new match has started
- : .my_name(gaucho1) // agent 1 is responsible for the team creation
- <- //.print("oooo creating team group");
++!create_team_group
+ <- .print("oooo creating team group");
.if( group(team,Old), {
jmoise.remove_group(Old)
});
@@ -31,13 +25,13 @@
+group(team,GId) // agent 1 is responsible for the creation of exploration groups
: .my_name(gaucho1)
- <- jmoise.create_group(exploration,GId);
- jmoise.create_group(exploration,GId);
- jmoise.create_group(exploration,GId).
-+group(exploration,_) // compute the area of the groups
+ <- jmoise.create_group(exploration_grp,GId);
+ jmoise.create_group(exploration_grp,GId);
+ jmoise.create_group(exploration_grp,GId).
++group(exploration_grp,_) // compute the area of the groups
: .my_name(gaucho1) &
- .findall(GId, group(exploration,GId), LG) &
- LG = [G1,G2,G3] // there are three groups
+ .findall(GId, group(exploration_grp,GId), LG) &
+ LG = [G1,G2,G3] // there are three groups
<- ?gsize(W,H);
X = math.round(((W*H)/3)/H);
+group_area(0, G1, area(0, 0, X, H-1));
@@ -51,24 +45,28 @@
/* plans for agents with odd id */
-+gsize(_,_)
++gsize(_,_) // new match has started
: .my_name(Me) &
agent_id(Me,AgId) &
AgId mod 2 == 1 // I have an odd Id
- <- .print("ooo Recruiting scouters for my explorer group....");
+ <- .if( .my_name(gaucho1), {
+ !create_team_group
+ });
+ .print("ooo Recruiting scouters for my explorer group....");
+
// wait my pos
?pos(MyX,MyY,_);
// wait others pos
- .while( .count(cell(_,_,ally(_)), N) & N < 5, {
+ .while( .count(ally_pos(_,_,_), N) & N < 5, {
.print("ooo waiting others pos ");
- .wait("+cell(_,_,ally(_))", 500, nofail)
+ .wait("+ally_pos(_,_,_)", 500, nofail)
});
// find distance to even agents
.findall(ag_d(D,AgName),
- cell(X,Y,ally(AgName)) & agent_id(AgName,Id) & Id mod 2 == 0 & jia.dist(MyX, MyY, X, Y, D),
+ ally_pos(AgName,X,Y) & agent_id(AgName,Id) & Id mod 2 == 0 & jia.dist(MyX, MyY, X, Y, D),
LOdd);
.sort(LOdd, LSOdd);
@@ -78,15 +76,13 @@
// adopt role explorer in the group
jmoise.adopt_role(explorer,G);
- +desired_role(exploration_grp, explorer); // needed for moise-common plans
- +desired_role(herding_grp, herder); // explorers will also be herders
!find_scouter(LSOdd, G).
+!find_scouter([],_)
<- .print("ooo I did not find a scouter to work with me!").
+!find_scouter([ag_d(_,AgName)|_],GId)
<- .print("ooo Ask ",AgName," to play scouter");
- .send(AgName, achieve, play_role(scouter,GId,exploration_grp));
+ .send(AgName, achieve, play_role(scouter,GId));
.wait("+play(Ag,scouter,GId)",2000).
-!find_scouter([_|LSOdd],GId) // in case the wait fails, try next agent
<- .print("ooo find_scouter failure, try another agent.");
@@ -96,23 +92,9 @@
+play(Ag,explorer,G)
: .my_name(Ag) &
not scheme_group(_,G)
- <- jmoise.create_scheme(exploring, [G]).
+ <- jmoise.create_scheme(explore_sch, [G]).
-/* plans for the others */
-
-+!play_role(Role,Group,Group_Spec)[source(Ag)]
- <- .print("ooo Adopting role ",Role,", asked by ",Ag);
- jmoise.adopt_role(Role, Group);
- +desired_role(Group_Spec, Role).
-
-// to keep plan above generic...
-// scouters will be herdboys
-// and need to tell t
-+desired_role(exploration_grp, scouter)
- <- +desired_role(herding_grp, herdboy).
-
-
/* -- plans for the goals of role explorer -- */
// TODO: make a pattern for organisational maintainance goal
@@ -120,7 +102,7 @@
+!goto_near_unvisited[scheme(Sch)]
<- .print("ooo I should find the nearest unvisited location and go there!");
.my_name(Me);
- ?play(Me,explorer,GroupId); // get the group where I play explorer
+ ?play(Me,explorer,GroupId); // get the group where I play explorer
?group_area(_,GroupId, Area); // get the area of this group
?pos(MeX, MeY, _); // get my location
jia.near_least_visited(MeX, MeY, Area, TargetX, TargetY);
@@ -143,17 +125,3 @@
.wait("+pos(_,_,_)"); // wait next cycle
!!follow_leader[scheme(Sch)].
-/* -- plans for the goals of all roles -- */
-
-+!share_seen_cows[scheme(Sch)]
- <- .print("ooo I should share cows!");
- ?cows_to_inform(C);
- jmoise.broadcast(Sch, tell, C);
- .wait("+pos(_,_,_)"); // wait next cycle
- !!share_seen_cows[scheme(Sch)].
-
-+cell(X,Y,cow(Id))
- <- +cow(Id,X,Y); //Jomi, tu nao vai gostar disso :D
- ?cows_to_inform(C);
- -+cows_to_inform([cow(Id,X,Y)|C]).
-
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-27 13:25:39 UTC (rev 1270)
@@ -44,7 +44,7 @@
+?group_area(Id,G,A) <- .wait("+group_area(Id,G,A)").
+end_of_simulation(_Result)
- <- .abolish(area(_,_,_,_,_,_)).
+ <- .abolish(group_area(_,_,_)).
+!restart
<- .print("*** restart ***");
@@ -53,10 +53,79 @@
// TODO: what to do?
//!decide_target.
+
+/* -- plans for the goals of all roles -- */
+
+// get the list G of participants of the group where I play R
++?my_group_players(G,R)
+ <- .my_name(Me);
+ play(Me,R,Gid);
+ .findall(P, play(P,_,Gid), G).
+
++!play_role(Role,Group)[source(Ag)]
+ : .my_name(Me) & not play(Me,_,_) // I can not play more than one role
+ <- .print("ooo Adopting role ",Role,", asked by ",Ag);
+ jmoise.adopt_role(Role, Group).
++!play_role(Role,Group)[source(Ag)]
+ <- .print("ooo Can NOT adopt role ",Role,", asked by ",Ag).
+
+/*
+
+TODO: use a list given by BUF
+
++!share_seen_cows[scheme(Sch)]
+ <- .print("ooo I should share cows!");
+ ?cows_to_inform(C);
+ jmoise.broadcast(Sch, tell, C);
+ // TODO: limpar -+cows_to_inform([])
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!share_seen_cows[scheme(Sch)].
+
++?cows_to_inform([]).
+
++cell(X,Y,cow(Id))
+ <- +cow(Id,X,Y); //Jomi, tu nao vai gostar disso :D
+ ?cows_to_inform(C);
+ -+cows_to_inform([cow(Id,X,Y)|C]).
+
+*/
+
++!share_seen_cows.
+
+// simple implementation of share_cows (see TODO above)
++cell(X,Y,cow(_))
+ : .my_name(Me) & play(Me,_,Gr)
+ <- C = cow(X,Y);
+ +C;
+ jmoise.broadcast(Gr, tell, C).
+-cell(X,Y,cow(_))
+ : .my_name(Me) & play(Me,_,Gr)
+ <- C = cow(X,Y);
+ -C;
+ jmoise.broadcast(Gr, untell, C).
+
+
+
+/* -- general organisational plans -- */
+
+// when I have an obligation or permission to a mission, commit to it
++obligation(Sch, Mission)
+ <- jmoise.commit_mission(Mission,Sch).
++permission(Sch, Mission)
+ <- jmoise.commit_mission(Mission,Sch).
+
+// if some scheme is finished, drop all intentions related to it.
+-scheme(_Spec,Id)
+ <- .drop_desire(_[scheme(Id)]).
+
++error(M)[source(orgManager)]
+ <- .print("Error in organisational action: ",M); -error(M)[source(orgManager)].
+
+
/* -- includes -- */
{ include("goto.asl") } // include plans for moving around
{ include("exploration.asl") } // include plans for exploration
{ include("herding.asl") } // include plans for herding
-{ include("moise-common.asl") } // include common plans for MOISE+ agents
+// { include("moise-common.asl") } // include common plans for MOISE+ agents
Modified: trunk/applications/jason-team/src/asl/herding.asl
===================================================================
--- trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/asl/herding.asl 2008-04-27 13:25:39 UTC (rev 1270)
@@ -2,11 +2,7 @@
/* -- initial beliefs -- */
-// missions I can commit to
-desired_mission(herd_sch, herd) :- desired_role(herding_grp, herder).
-desired_mission(herd_sch, help_herder) :- desired_role(herding_grp, herdboy).
-
/* -- plans for the goals of role herder -- */
+!recruit[scheme(Sch)]
@@ -26,15 +22,6 @@
.wait("+pos(_,_,_)"); // wait next cycle
!!define_formation[scheme(Sch)].
-// get the list G of participants of the group where I play R
-+?my_group(G,R)
- <- .my_name(Me);
- play(Me,R,Gid);
- .findall(P, play(P,_,Gid), G);
- +my_group(G,R).
-// TODO, IMPORTANT: Quando tiver mudanca no grupo, apagar essa crenca
-// pra deixar esse plano rodar de novo.
-
+!alloc_all([],LA).
+!alloc_all([HA|TA],LA)
<- !find_closest(HA,LA,pos(X,Y),NLA);
@@ -42,21 +29,20 @@
-+alloc_target(HA,Alloc);
!alloc_all(TA,NLA).
-+!find_closest(Ag, List, Alloc, Rest)
- <- ?alloc_target(Ag,pos(X,Y));
++!find_closest(Ag, List, Alloc, Rest) // rule
+ <- ?ally_pos(Ag,XY);
!closest(List,[],Sorted,pos(X,Y),9999);
Sorted = [Alloc|Rest];
.print("FIND CLOSEST: ",Sorted).
-
+// TODO: use min
+!closest([],S,S,P,D).
+!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
- : jia.dist(XH,YH,XP,YP,D) & D < LD
+ : jia.dist(XH,YH,XP,YP,D) & D < LD // usar A*
<- !closest(T,[pos(XH,YH)|Aux],S,pos(XP,YP),D).
+!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
<- .concat(Aux,[pos(XH,YH)],Aux2);
!closest(T,Aux2,S,pos(XP,YP),LD).
-+?alloc_target(Ag,X,Y) <- .send(Ag, askOne, pos(X,Y,_), pos(X,Y,_)).
/* -- plans for the goals of all roles (herder and herdboy) -- */
Modified: trunk/applications/jason-team/src/java/arch/ACArchitecture.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -46,15 +46,15 @@
String password = stts.getUserParameter("password");
if (password.startsWith("\"")) password = password.substring(1,password.length()-1);
+ waitSleepThread = new WaitSleep();
+ waitSleepThread.start();
+
proxy = new ACProxy( this,
stts.getUserParameter("host"),
Integer.parseInt(stts.getUserParameter("port")),
username,
password);
new Thread(proxy,"AgentProxy"+username).start();
-
- waitSleepThread = new WaitSleep();
- waitSleepThread.start();
}
Modified: trunk/applications/jason-team/src/java/arch/ACProxy.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/arch/ACProxy.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -152,9 +152,7 @@
// add location in perception
Literal lpos = new Literal("pos");
- lpos.addTerm(new NumberTermImpl(agx));
- lpos.addTerm(new NumberTermImpl(agy));
- lpos.addTerm(new NumberTermImpl(step));
+ lpos.addTerms(new NumberTermImpl(agx), new NumberTermImpl(agy), new NumberTermImpl(step));
percepts.add(lpos);
arq.initKnownCows();
Modified: trunk/applications/jason-team/src/java/arch/CowboyArch.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -9,7 +9,6 @@
import jason.asSyntax.Literal;
import jason.asSyntax.NumberTerm;
import jason.asSyntax.NumberTermImpl;
-import jason.asSyntax.Structure;
import jason.asSyntax.Term;
import jason.environment.grid.Location;
import jason.mas2j.ClassParameters;
@@ -237,9 +236,9 @@
public static Literal createCellPerception(int x, int y, Term obj) {
Literal l = new Literal("cell");
- l.addTerm(new NumberTermImpl(x));
- l.addTerm(new NumberTermImpl(y));
- l.addTerm(obj);
+ l.addTerms(new NumberTermImpl(x),
+ new NumberTermImpl(y),
+ obj);
return l;
}
@@ -358,9 +357,9 @@
if (acView != null) acView.getModel().setAgPos(agid, x, y);
model.incVisited(x, y);
//getTS().getAg().getLogger().info("ag pos "+getMinerId(m.getSender())+" = "+x+","+y);
- Structure tAlly = new Structure("ally");
- tAlly.addTerm(new Atom(m.getSender()));
- getTS().getAg().addBel( createCellPerception(x, y, tAlly));
+ Literal tAlly = new Literal("ally_pos");
+ tAlly.addTerms(new Atom(m.getSender()), new NumberTermImpl(x), new NumberTermImpl(y));
+ getTS().getAg().addBel( tAlly );
} catch (Exception e) {
e.printStackTrace();
}
Modified: trunk/applications/jason-team/src/java/env/WorldView.java
===================================================================
--- trunk/applications/jason-team/src/java/env/WorldView.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/env/WorldView.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -6,6 +6,8 @@
import java.awt.Color;
import java.awt.FlowLayout;
import java.awt.Graphics;
+import java.awt.event.MouseEvent;
+import java.awt.event.MouseMotionListener;
import javax.swing.BorderFactory;
import javax.swing.BoxLayout;
@@ -27,7 +29,7 @@
JLabel jCycle;
JLabel jCowsC;
- //JLabel jlMouseLoc;
+ JLabel jlMouseLoc;
//JComboBox scenarios;
//JSlider jSpeed;
@@ -96,16 +98,15 @@
msg.setBorder(BorderFactory.createEtchedBorder());
+ JPanel pmoise = new JPanel(new FlowLayout(FlowLayout.CENTER));
+ //p.add(new JLabel("Click on the cells to add new pieces of gold."));
+ //pmoise.add(new JLabel(" (mouse at:"));
+ jlMouseLoc = new JLabel("0,0");
+ pmoise.add(jlMouseLoc);
+ pmoise.setBorder(BorderFactory.createEtchedBorder());
+ //msg.add(p);
+
JPanel p = new JPanel(new FlowLayout(FlowLayout.CENTER));
- /*
- p.add(new JLabel("Click on the cells to add new pieces of gold."));
- p.add(new JLabel(" (mouse at:"));
- jlMouseLoc = new JLabel("0,0)");
- p.add(jlMouseLoc);
- msg.add(p);
- */
-
- p = new JPanel(new FlowLayout(FlowLayout.CENTER));
p.add(new JLabel("Cycle:"));
jCycle = new JLabel("0");
p.add(jCycle);
@@ -119,6 +120,7 @@
JPanel s = new JPanel(new BorderLayout());
s.add(BorderLayout.WEST, args);
s.add(BorderLayout.CENTER, msg);
+ s.add(BorderLayout.EAST, pmoise);
getContentPane().add(BorderLayout.SOUTH, s);
// Events handling
@@ -160,18 +162,16 @@
});
*/
- /*
getCanvas().addMouseMotionListener(new MouseMotionListener() {
public void mouseDragged(MouseEvent e) { }
public void mouseMoved(MouseEvent e) {
int col = e.getX() / cellSizeW;
int lin = e.getY() / cellSizeH;
if (col >= 0 && lin >= 0 && col < getModel().getWidth() && lin < getModel().getHeight()) {
- jlMouseLoc.setText(col+","+lin+")");
+ jlMouseLoc.setText(col+","+lin);
}
}
});
- */
}
/*
Modified: trunk/applications/jason-team/src/java/jia/Vec.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -54,6 +54,16 @@
while (t < 0) t = t + PI2;
return new Vec(r*Math.cos(t), r*Math.sin(t));
}
+
+ /** turn the vec to 90 degrees clockwise */
+ public Vec turn90CW() {
+ return new Vec(y, -x);
+ }
+ /** turn the vec to 90 degrees anticlockwise */
+ public Vec turn90ACW() {
+ return new Vec(-y, x);
+ }
+
public Vec newMagnitude(double r) {
return new Vec(r*Math.cos(t), r*Math.sin(t));
}
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -83,8 +83,7 @@
ListTerm tail = r;
for (Location l: locs) {
Structure p = new Structure("pos",2);
- p.addTerm(new NumberTermImpl(l.x));
- p.addTerm(new NumberTermImpl(l.y));
+ p.addTerms(new NumberTermImpl(l.x), new NumberTermImpl(l.y));
tail = tail.append(p);
}
return un.unifies(args[1], r);
@@ -103,9 +102,10 @@
List<Location> locs = formationPlaces(model, formation);
if (locs != null) {
for (Location l : locs) {
- r = l;
if (ag.equals(l) || // I am there
- !model.hasObject(WorldModel.AGENT, l)) { // no one else is there
+ //model.countObjInArea(WorldModel.AGENT, l, 1) == 0) { // no one else is there
+ !model.hasObject(WorldModel.AGENT, l)) {
+ r = l;
break;
}
}
@@ -153,14 +153,20 @@
int initAgTS = 1;
for (int dist: formation.getDistances()) { // 2, -2, 6, -6, ....
Vec agTarget = agsTarget;
- Location l = agTarget.add(mean).getLocation(model);
+ //Location l = agTarget.add(mean).getLocation(model);
- //System.out.println("....... "+dist+" antes angle "+agTarget);
+ System.out.println("....... "+dist+" antes angle "+agTarget);
if (dist >= 0)
- agTarget = new Vec( -agTarget.y, agTarget.x);
+ agTarget = agTarget.turn90CW();
else
- agTarget = new Vec( agTarget.y, -agTarget.x);
+ agTarget = agTarget.turn90ACW();
+ Location l = findFirstFreeLocTowardsTarget(agTarget, mean.add(agsTarget), initAgTS, dist, model);
+ System.out.println(" = "+dist+" result "+l);
+ if (l != null)
+ r.add(pathToNearCow(model, l));
+
+ /*
Location lastloc = null;
boolean uselast = false;
for (int agTargetSize = initAgTS; agTargetSize <= Math.abs(dist); agTargetSize++) {
@@ -175,13 +181,29 @@
}
if (!uselast)
r.add(pathToNearCow(model, l));
+ */
+
if (dist < 0)
initAgTS = Math.abs(dist)+1;
}
- //System.out.println("all places "+r);
+ System.out.println("all places "+r);
return r;
}
+ private Location findFirstFreeLocTowardsTarget(Vec target, Vec ref, int initialSize, int maxSize, LocalWorldModel model) {
+ Location lastloc = null;
+ maxSize = Math.abs(maxSize);
+ Location l = ref.getLocation(model);;
+ for (int s = initialSize; s <= maxSize; s++) {
+ l = target.newMagnitude(s).add(ref).getLocation(model);
+ System.out.println("pos angle "+s+" = "+l);
+ if ( (!model.inGrid(l) || model.hasObject(WorldModel.OBSTACLE, l)) && lastloc != null)
+ return lastloc;
+ lastloc = l;
+ }
+ return l; //ref.getLocation(model); //target.add(ref).getLocation(model);
+ }
+
private Location pathToNearCow(LocalWorldModel model, Location t) {
Location near = null;
for (Location c: model.getCows()) {
@@ -194,7 +216,7 @@
//System.out.println("Near cow to "+t+" is "+near+" vec = "+dircow);
for (int s = 1; s <= 20; s++) {
Location l = dircow.newMagnitude(s).add(nearcv).getLocation(model);
- if (model.isFree(l))
+ if (!model.hasObject(WorldModel.COW,l))
return l;
}
}
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-27 13:25:39 UTC (rev 1270)
@@ -152,17 +152,32 @@
assertEquals(new Location(6,38), byIA);
byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
- assertEquals(new Location(5,38), byIA);
+ assertEquals(new Location(6,39), byIA);
+ // add an agent in 6,39
+ model.add(WorldModel.AGENT, 6,39);
+ byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
+ assertEquals(new Location(5,38), byIA);
+
// add an agent in 5,38
model.add(WorldModel.AGENT, 5,38);
- byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
+ byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
assertEquals(new Location(7,42), byIA);
- // add an agent in 7,42
+ // add an agent in 7,42
model.add(WorldModel.AGENT, 7,42);
byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
- assertEquals(new Location(8,42), byIA);
+ assertEquals(new Location(4,38), byIA);
+
+ // add an agent in 4,38
+ model.add(WorldModel.AGENT, 4,38);
+ byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
+ assertEquals(null, byIA);
+
+ // add an agent in 5,37
+ //model.add(WorldModel.AGENT, 5,37);
+ //byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
+ //assertEquals(new Location(5,37), byIA);
}
@Test
Modified: trunk/applications/jason-team/src/team-os.xml
===================================================================
--- trunk/applications/jason-team/src/team-os.xml 2008-04-27 13:24:01 UTC (rev 1269)
+++ trunk/applications/jason-team/src/team-os.xml 2008-04-27 13:25:39 UTC (rev 1270)
@@ -108,10 +108,10 @@
</functional-specification>
<deontic-specification>
- <deontic-relation type="obligation" role="explorer" mission="mexplore" />
- <deontic-relation type="obligation" role="scouter" mission="mscout" />
- <deontic-relation type="obligation" role="herder" mission="mherd" />
- <deontic-relation type="obligation" role="herdboy" mission="mhelp_herder" />
+ <deontic-relation type="obligation" role="explorer" mission="explore" />
+ <deontic-relation type="obligation" role="scouter" mission="scout" />
+ <deontic-relation type="obligation" role="herder" mission="herd" />
+ <deontic-relation type="obligation" role="herdboy" mission="help_herder" />
</deontic-specification>
</organisational-specification>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 13:24:05
|
Revision: 1269
http://jason.svn.sourceforge.net/jason/?rev=1269&view=rev
Author: jomifred
Date: 2008-04-27 06:24:01 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
use addterms in examples
Modified Paths:
--------------
trunk/examples/gold-miners-II/env/MiningEnvironment.java
trunk/examples/sniffer/comm/SnifferCentralised.java
Modified: trunk/examples/gold-miners-II/env/MiningEnvironment.java
===================================================================
--- trunk/examples/gold-miners-II/env/MiningEnvironment.java 2008-04-27 13:23:14 UTC (rev 1268)
+++ trunk/examples/gold-miners-II/env/MiningEnvironment.java 2008-04-27 13:24:01 UTC (rev 1269)
@@ -203,9 +203,7 @@
// its location
Location l = model.getAgPos(ag);
Literal p = new Literal("pos");
- p.addTerm(new NumberTermImpl(l.x));
- p.addTerm(new NumberTermImpl(l.y));
- p.addTerm(new NumberTermImpl(getStep()));
+ p.addTerms(new NumberTermImpl(l.x), new NumberTermImpl(l.y), new NumberTermImpl(getStep()));
addPercept(agName, p);
Literal cg = new Literal("carrying_gold");
@@ -258,9 +256,9 @@
public static Literal createCellPerception(int x, int y, Atom obj) {
Literal l = new Literal("cell");
- l.addTerm(new NumberTermImpl(x));
- l.addTerm(new NumberTermImpl(y));
- l.addTerm(obj);
+ l.addTerms(new NumberTermImpl(x),
+ new NumberTermImpl(y),
+ obj);
return l;
}
Modified: trunk/examples/sniffer/comm/SnifferCentralised.java
===================================================================
--- trunk/examples/sniffer/comm/SnifferCentralised.java 2008-04-27 13:23:14 UTC (rev 1268)
+++ trunk/examples/sniffer/comm/SnifferCentralised.java 2008-04-27 13:24:01 UTC (rev 1269)
@@ -43,12 +43,13 @@
Calendar now = new GregorianCalendar();
Structure p = new Structure("time");
- p.addTerm(new NumberTermImpl(now.get(Calendar.YEAR)));
- p.addTerm(new NumberTermImpl(now.get(Calendar.MONTH)));
- p.addTerm(new NumberTermImpl(now.get(Calendar.DAY_OF_MONTH)));
- p.addTerm(new NumberTermImpl(now.get(Calendar.HOUR)));
- p.addTerm(new NumberTermImpl(now.get(Calendar.MINUTE)));
- p.addTerm(new NumberTermImpl(now.get(Calendar.SECOND)));
+ p.addTerms(
+ new NumberTermImpl(now.get(Calendar.YEAR)),
+ new NumberTermImpl(now.get(Calendar.MONTH)),
+ new NumberTermImpl(now.get(Calendar.DAY_OF_MONTH)),
+ new NumberTermImpl(now.get(Calendar.HOUR)),
+ new NumberTermImpl(now.get(Calendar.MINUTE)),
+ new NumberTermImpl(now.get(Calendar.SECOND)));
e.addTerm(p);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 13:23:39
|
Revision: 1268
http://jason.svn.sourceforge.net/jason/?rev=1268&view=rev
Author: jomifred
Date: 2008-04-27 06:23:14 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
use addTerms in jmoise
Modified Paths:
--------------
trunk/applications/jason-moise/src/asl/moise-common.asl
trunk/applications/jason-moise/src/jmoise/MoiseBaseIA.java
trunk/applications/jason-moise/src/jmoise/OrgAgent.java
Modified: trunk/applications/jason-moise/src/asl/moise-common.asl
===================================================================
--- trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-27 13:22:40 UTC (rev 1267)
+++ trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-27 13:23:14 UTC (rev 1268)
@@ -53,4 +53,5 @@
-scheme(_Spec,Id)
<- .drop_desire(_[scheme(Id)]).
-+error(M)[source(orgManager)] <- .print("Error in organisational action: ",M); -error(M)[source(orgManager)].
++error(M)[source(orgManager)]
+ <- .print("Error in organisational action: ",M); -error(M)[source(orgManager)].
Modified: trunk/applications/jason-moise/src/jmoise/MoiseBaseIA.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/MoiseBaseIA.java 2008-04-27 13:22:40 UTC (rev 1267)
+++ trunk/applications/jason-moise/src/jmoise/MoiseBaseIA.java 2008-04-27 13:23:14 UTC (rev 1268)
@@ -25,9 +25,7 @@
public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
String acName = this.getClass().getSimpleName(); // remove the package name "jmoise"
Structure acTerm = new Structure(acName);
- for (int i=0; i<args.length; i++) {
- acTerm.addTerm(args[i]);
- }
+ acTerm.addTerms(args);
if (logger.isLoggable(Level.FINE)) logger.fine("sending: "+acTerm);
// send acTerm as message to OrgManager
Modified: trunk/applications/jason-moise/src/jmoise/OrgAgent.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-27 13:22:40 UTC (rev 1267)
+++ trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-27 13:23:14 UTC (rev 1268)
@@ -318,11 +318,9 @@
}
// create the literal to be added
- Literal gil = new Literal("goal_state");
- gil.addTerm(new Atom(gi.getScheme().getId()));
- gil.addTerm(gap);
VarTerm S = new VarTerm("S");
- gil.addTerm(S);
+ Literal gil = new Literal("goal_state");
+ gil.addTerms(new Atom(gi.getScheme().getId()), gap, S);
gil.addAnnot(managerSource);
Unifier u = new Unifier();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-27 13:22:44
|
Revision: 1267
http://jason.svn.sourceforge.net/jason/?rev=1267&view=rev
Author: jomifred
Date: 2008-04-27 06:22:40 -0700 (Sun, 27 Apr 2008)
Log Message:
-----------
add method addTerms in structure
Modified Paths:
--------------
trunk/src/jason/asSemantics/TransitionSystem.java
trunk/src/jason/asSyntax/ArithExpr.java
trunk/src/jason/asSyntax/BinaryStructure.java
trunk/src/jason/asSyntax/Structure.java
trunk/src/jason/functions/RuleToFunction.java
Modified: trunk/src/jason/asSemantics/TransitionSystem.java
===================================================================
--- trunk/src/jason/asSemantics/TransitionSystem.java 2008-04-26 21:45:22 UTC (rev 1266)
+++ trunk/src/jason/asSemantics/TransitionSystem.java 2008-04-27 13:22:40 UTC (rev 1267)
@@ -179,10 +179,11 @@
// generate an event
Literal received = new Literal("kqml_received");
- received.addTerm(new Atom(m.getSender()));
- received.addTerm(new Atom(m.getIlForce()));
- received.addTerm(content);
- received.addTerm(new Atom(m.getMsgId()));
+ received.addTerms(
+ new Atom(m.getSender()),
+ new Atom(m.getIlForce()),
+ content,
+ new Atom(m.getMsgId()));
updateEvents(new Event(new Trigger(TEOperator.add, TEType.achieve, received), Intention.EmptyInt));
}
Modified: trunk/src/jason/asSyntax/ArithExpr.java
===================================================================
--- trunk/src/jason/asSyntax/ArithExpr.java 2008-04-26 21:45:22 UTC (rev 1266)
+++ trunk/src/jason/asSyntax/ArithExpr.java 2008-04-27 13:22:40 UTC (rev 1267)
@@ -122,8 +122,7 @@
public ArithExpr(NumberTerm t1, ArithmeticOp oper, NumberTerm t2) {
super(oper.toString(),2);
- addTerm(t1);
- addTerm(t2);
+ addTerms(t1, t2);
op = oper;
if (t1 instanceof SourceInfo) setSrc((SourceInfo)t1);
else if (t2 instanceof SourceInfo) setSrc((SourceInfo)t2);
Modified: trunk/src/jason/asSyntax/BinaryStructure.java
===================================================================
--- trunk/src/jason/asSyntax/BinaryStructure.java 2008-04-26 21:45:22 UTC (rev 1266)
+++ trunk/src/jason/asSyntax/BinaryStructure.java 2008-04-27 13:22:40 UTC (rev 1267)
@@ -35,8 +35,7 @@
/** Constructor for binary operator */
public BinaryStructure(Term t1, String id, Term t2) {
super(id,2);
- addTerm( t1 );
- addTerm( t2 );
+ addTerms( t1, t2 );
if (t1 instanceof SourceInfo) setSrc((SourceInfo)t1);
else if (t2 instanceof SourceInfo) setSrc((SourceInfo)t2);
}
Modified: trunk/src/jason/asSyntax/Structure.java
===================================================================
--- trunk/src/jason/asSyntax/Structure.java 2008-04-26 21:45:22 UTC (rev 1266)
+++ trunk/src/jason/asSyntax/Structure.java 2008-04-27 13:22:40 UTC (rev 1267)
@@ -224,10 +224,20 @@
resetHashCodeCache();
}
+ public void addTerms(Term ... ts ) {
+ for (Term t: ts) {
+ terms.add(t);
+ }
+ predicateIndicatorCache = null;
+ resetHashCodeCache();
+ }
+
public void addTerms(List<Term> l) {
for (Term t: l) {
- addTerm(t);
+ terms.add(t);
}
+ predicateIndicatorCache = null;
+ resetHashCodeCache();
}
public void setTerms(List<Term> l) {
Modified: trunk/src/jason/functions/RuleToFunction.java
===================================================================
--- trunk/src/jason/functions/RuleToFunction.java 2008-04-26 21:45:22 UTC (rev 1266)
+++ trunk/src/jason/functions/RuleToFunction.java 2008-04-27 13:22:40 UTC (rev 1267)
@@ -56,8 +56,8 @@
r = new InternalActionLiteral(literal);
else
r = new Literal(literal);
- for (Term t: args)
- r.addTerm(t);
+
+ r.addTerms(args);
VarTerm answer = new VarTerm("__RuleToFunctionResult");
r.addTerm(answer);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <bo...@us...> - 2008-04-26 21:45:32
|
Revision: 1266
http://jason.svn.sourceforge.net/jason/?rev=1266&view=rev
Author: bordini
Date: 2008-04-26 14:45:22 -0700 (Sat, 26 Apr 2008)
Log Message:
-----------
target allocation for herding formation and sharing of information about cow locations
Modified Paths:
--------------
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/asl/goto.asl
trunk/applications/jason-team/src/asl/herding.asl
trunk/applications/jason-team/src/team-os.xml
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-26 20:32:39 UTC (rev 1265)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-26 21:45:22 UTC (rev 1266)
@@ -3,9 +3,9 @@
/* -- initial beliefs -- */
-// missions I can commit to
-desired_mission(exploring, mexplorer).
-desired_mission(exploring, mscouter).
+// missions I can commit to depend on the roles I adopt
+desired_mission(explore_sch, explore) :- desired_role(exploration_grp, explorer).
+desired_mission(explore_sch, scout) :- desired_role(exploration_grp, scouter).
/* -- initial goals -- */
@@ -21,7 +21,7 @@
/* plans for agent 1 */
-+gsize(_Weight,_Height) // new match've started
++gsize(_Weight,_Height) // new match has started
: .my_name(gaucho1) // agent 1 is responsible for the team creation
<- //.print("oooo creating team group");
.if( group(team,Old), {
@@ -78,13 +78,15 @@
// adopt role explorer in the group
jmoise.adopt_role(explorer,G);
+ +desired_role(exploration_grp, explorer); // needed for moise-common plans
+ +desired_role(herding_grp, herder); // explorers will also be herders
!find_scouter(LSOdd, G).
+!find_scouter([],_)
- <- .print("ooo I do not find a scouter to work with me!").
+ <- .print("ooo I did not find a scouter to work with me!").
+!find_scouter([ag_d(_,AgName)|_],GId)
<- .print("ooo Ask ",AgName," to play scouter");
- .send(AgName, achieve, play_role(scouter,GId));
+ .send(AgName, achieve, play_role(scouter,GId,exploration_grp));
.wait("+play(Ag,scouter,GId)",2000).
-!find_scouter([_|LSOdd],GId) // in case the wait fails, try next agent
<- .print("ooo find_scouter failure, try another agent.");
@@ -99,17 +101,24 @@
/* plans for the others */
-+!play_role(Role,Group)[source(Ag)]
++!play_role(Role,Group,Group_Spec)[source(Ag)]
<- .print("ooo Adopting role ",Role,", asked by ",Ag);
- jmoise.adopt_role(Role,Group).
-
-
+ jmoise.adopt_role(Role, Group);
+ +desired_role(Group_Spec, Role).
+
+// to keep plan above generic...
+// scouters will be herdboys
+// and need to tell t
++desired_role(exploration_grp, scouter)
+ <- +desired_role(herding_grp, herdboy).
+
+
/* -- plans for the goals of role explorer -- */
// TODO: make a pattern for organisational maintainance goal
+!goto_near_unvisited[scheme(Sch)]
- <- .print("ooo I should find the near unvisited location and go there!");
+ <- .print("ooo I should find the nearest unvisited location and go there!");
.my_name(Me);
?play(Me,explorer,GroupId); // get the group where I play explorer
?group_area(_,GroupId, Area); // get the area of this group
@@ -136,9 +145,15 @@
/* -- plans for the goals of all roles -- */
-+!share_cows[scheme(Sch)]
++!share_seen_cows[scheme(Sch)]
<- .print("ooo I should share cows!");
- // TODO:
+ ?cows_to_inform(C);
+ jmoise.broadcast(Sch, tell, C);
.wait("+pos(_,_,_)"); // wait next cycle
- !!share_cows[scheme(Sch)].
+ !!share_seen_cows[scheme(Sch)].
++cell(X,Y,cow(Id))
+ <- +cow(Id,X,Y); //Jomi, tu nao vai gostar disso :D
+ ?cows_to_inform(C);
+ -+cows_to_inform([cow(Id,X,Y)|C]).
+
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-26 20:32:39 UTC (rev 1265)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-26 21:45:22 UTC (rev 1266)
@@ -18,18 +18,26 @@
/* -- initial beliefs -- */
-agent_id(gaucho1,0).
-agent_id(gaucho2,1).
-agent_id(gaucho3,2).
-agent_id(gaucho4,3).
-agent_id(gaucho5,4).
-agent_id(gaucho6,5).
+agent_id(gaucho1,1).
+agent_id(gaucho2,2).
+agent_id(gaucho3,3).
+agent_id(gaucho4,4).
+agent_id(gaucho5,5).
+agent_id(gaucho6,6).
ag_perception_ratio(8). // ratio of perception of the agent
cow_perception_ratio(4).
/* -- initial goals -- */
+/* Testing alloc
+alloc_target(a1,pos(10,10)).
+alloc_target(a2,pos(20,20)).
+alloc_target(a3,pos(30,30)).
+!test.
++!test <- !alloc_all([a1,a2,a3],[pos(31,31),pos(21,21),pos(11,11)]).
+*/
+
/* -- plans -- */
+?pos(X, Y, S) <- .wait("+pos(X,Y,S)").
@@ -47,7 +55,7 @@
/* -- includes -- */
-{ include("goto.asl") } // include plans for movimentation
+{ include("goto.asl") } // include plans for moving around
{ include("exploration.asl") } // include plans for exploration
{ include("herding.asl") } // include plans for herding
{ include("moise-common.asl") } // include common plans for MOISE+ agents
Modified: trunk/applications/jason-team/src/asl/goto.asl
===================================================================
--- trunk/applications/jason-team/src/asl/goto.asl 2008-04-26 20:32:39 UTC (rev 1265)
+++ trunk/applications/jason-team/src/asl/goto.asl 2008-04-26 21:45:22 UTC (rev 1266)
@@ -53,5 +53,6 @@
// in case of failure, move
-!move
- <- .current_intention(I); .println("failure in move, intention: ",I);
+ <- .current_intention(I); .println("failure in moving; intention was: ",I);
!move.
+
Modified: trunk/applications/jason-team/src/asl/herding.asl
===================================================================
--- trunk/applications/jason-team/src/asl/herding.asl 2008-04-26 20:32:39 UTC (rev 1265)
+++ trunk/applications/jason-team/src/asl/herding.asl 2008-04-26 21:45:22 UTC (rev 1266)
@@ -3,8 +3,8 @@
/* -- initial beliefs -- */
// missions I can commit to
-desired_mission(exploring, mherder).
-desired_mission(exploring, mherdboy).
+desired_mission(herd_sch, herd) :- desired_role(herding_grp, herder).
+desired_mission(herd_sch, help_herder) :- desired_role(herding_grp, herdboy).
/* -- plans for the goals of role herder -- */
@@ -18,13 +18,46 @@
+!define_formation[scheme(Sch)]
<- .print("ooo I should define the formation of my group!");
- jia.herd_position(2,L); // formation in two (TODO: get the number of players in the group or scheme)
+ ?my_group(G, herder);
+ .length(G,NumP);
+ jia.herd_position(NumP,L);
.print("ooo formation is ",L);
- // TODO: allocate and share the formation
+ !alloc_all(G,L);
.wait("+pos(_,_,_)"); // wait next cycle
!!define_formation[scheme(Sch)].
+// get the list G of participants of the group where I play R
++?my_group(G,R)
+ <- .my_name(Me);
+ play(Me,R,Gid);
+ .findall(P, play(P,_,Gid), G);
+ +my_group(G,R).
+// TODO, IMPORTANT: Quando tiver mudanca no grupo, apagar essa crenca
+// pra deixar esse plano rodar de novo.
++!alloc_all([],LA).
++!alloc_all([HA|TA],LA)
+ <- !find_closest(HA,LA,pos(X,Y),NLA);
+ .send(HA,tell,target(X,Y));
+ -+alloc_target(HA,Alloc);
+ !alloc_all(TA,NLA).
+
++!find_closest(Ag, List, Alloc, Rest)
+ <- ?alloc_target(Ag,pos(X,Y));
+ !closest(List,[],Sorted,pos(X,Y),9999);
+ Sorted = [Alloc|Rest];
+ .print("FIND CLOSEST: ",Sorted).
+
++!closest([],S,S,P,D).
++!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
+ : jia.dist(XH,YH,XP,YP,D) & D < LD
+ <- !closest(T,[pos(XH,YH)|Aux],S,pos(XP,YP),D).
++!closest([pos(XH,YH)|T],Aux,S,pos(XP,YP),LD)
+ <- .concat(Aux,[pos(XH,YH)],Aux2);
+ !closest(T,Aux2,S,pos(XP,YP),LD).
+
++?alloc_target(Ag,X,Y) <- .send(Ag, askOne, pos(X,Y,_), pos(X,Y,_)).
+
/* -- plans for the goals of all roles (herder and herdboy) -- */
+!be_in_formation[scheme(Sch)]
Modified: trunk/applications/jason-team/src/team-os.xml
===================================================================
--- trunk/applications/jason-team/src/team-os.xml 2008-04-26 20:32:39 UTC (rev 1265)
+++ trunk/applications/jason-team/src/team-os.xml 2008-04-26 21:45:22 UTC (rev 1266)
@@ -38,19 +38,20 @@
<sub-groups>
- <group-specification id="exploration" min="3" max="3" >
+ <group-specification id="exploration_grp" min="3" max="3" >
<roles>
<role id="explorer" min="1" max="1"/>
<role id="scouter" min="0" max="1"/>
</roles>
</group-specification>
- <group-specification id="herding" min="0" max="6" >
+ <group-specification id="herding_grp" min="0" max="6" >
<roles>
<role id="herder" min="1" max="1"/>
<role id="herdboy" min="0" max="3"/>
</roles>
</group-specification>
+
</sub-groups>
<formation-constraints>
@@ -64,53 +65,53 @@
<functional-specification>
- <scheme id="exploring" >
+ <scheme id="explore_sch" >
<goal id="find_cows" >
<plan operator="parallel">
<goal id="goto_near_unvisited" ds="go to the near unvisited location inside the area of the group" type="maintenance"/>
- <goal id="share_cows" ds="share seen cows with other agents in the scheme" type="maintenance"/>
+ <goal id="share_seen_cows" ds="share seen cows with other agents in the scheme" type="maintenance"/>
<goal id="follow_leader" ds="follows the leader of the scheme/group" type="maintenance"/>
</plan>
</goal>
- <mission id="mexplorer" min="1">
+ <mission id="explore" min="1">
<goal id="goto_near_unvisited" />
- <goal id="share_cows" />
+ <goal id="share_seen_cows" />
</mission>
- <mission id="mscouter" >
+ <mission id="scout" >
<goal id="follow_leader" />
- <goal id="share_cows" />
+ <goal id="share_seen_cows" />
</mission>
</scheme>
- <scheme id="herding" >
+ <scheme id="herd_sch" >
<goal id="herd_cows" >
<plan operator="parallel">
<goal id="recruit" ds="recruit more herdboys depending on the size of the cows cluster" type="maintenance"/>
<goal id="define_formation" ds="compute the ideal location of each member of the group and share this information with them" type="maintenance"/>
<goal id="be_in_formation" ds="go to the place allocated to the agent in the formation" type="maintenance"/>
- <goal id="share_cows" ds="share seen cows with other agents in the scheme" type="maintenance"/>
+ <goal id="share_seen_cows" ds="share seen cows with other agents in the scheme" type="maintenance"/>
</plan>
</goal>
- <mission id="mherder" min="1">
+ <mission id="herd" min="1">
<goal id="recruit" />
<goal id="define_formation" />
<goal id="be_in_formation" />
- <goal id="share_cows" />
+ <goal id="share_seen_cows" />
</mission>
- <mission id="mherdboy" >
+ <mission id="help_herder" >
<goal id="be_in_formation" />
- <goal id="share_cows" />
+ <goal id="share_seen_cows" />
</mission>
</scheme>
</functional-specification>
<deontic-specification>
- <deontic-relation type="obligation" role="explorer" mission="mexplorer" />
- <deontic-relation type="obligation" role="scouter" mission="mscouter" />
- <deontic-relation type="obligation" role="herder" mission="mherder" />
- <deontic-relation type="obligation" role="herdboy" mission="mherdboy" />
+ <deontic-relation type="obligation" role="explorer" mission="mexplore" />
+ <deontic-relation type="obligation" role="scouter" mission="mscout" />
+ <deontic-relation type="obligation" role="herder" mission="mherd" />
+ <deontic-relation type="obligation" role="herdboy" mission="mhelp_herder" />
</deontic-specification>
</organisational-specification>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-26 20:32:42
|
Revision: 1265
http://jason.svn.sourceforge.net/jason/?rev=1265&view=rev
Author: jomifred
Date: 2008-04-26 13:32:39 -0700 (Sat, 26 Apr 2008)
Log Message:
-----------
fix bug in OrgManager
Modified Paths:
--------------
trunk/applications/as-unit-test/src/jason/tests/TestAll.java
trunk/applications/jason-moise/src/jmoise/OrgManager.java
Modified: trunk/applications/as-unit-test/src/jason/tests/TestAll.java
===================================================================
--- trunk/applications/as-unit-test/src/jason/tests/TestAll.java 2008-04-26 14:12:31 UTC (rev 1264)
+++ trunk/applications/as-unit-test/src/jason/tests/TestAll.java 2008-04-26 20:32:39 UTC (rev 1265)
@@ -10,7 +10,8 @@
BugVarsInInitBels.class,
TestAddLogExprInBB.class,
TestGoalSource.class,
- TestIF.class,
+ TestIF.class,
+ TestLoop.class,
TestKQML.class,
TestPlanbodyAsTerm.class,
TestPlanFailure.class,
Modified: trunk/applications/jason-moise/src/jmoise/OrgManager.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-26 14:12:31 UTC (rev 1264)
+++ trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-26 20:32:39 UTC (rev 1265)
@@ -133,6 +133,9 @@
while (i.hasNext()) {
Message m = i.next();
i.remove(); // the agent do not receive this message
+ if (currentOE == null) break;
+ if (m.getSender() == null) break;
+
OEAgent agSender = currentOE.getAgent(m.getSender());
if (logger.isLoggable(Level.FINE)) logger.fine("Processing '" + m + "' for " + agSender);
try {
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-26 14:12:33
|
Revision: 1264
http://jason.svn.sourceforge.net/jason/?rev=1264&view=rev
Author: jomifred
Date: 2008-04-26 07:12:31 -0700 (Sat, 26 Apr 2008)
Log Message:
-----------
jason team: add org. goals (with no code) in the code of the agents
Modified Paths:
--------------
trunk/applications/jason-moise/lib/moise.jar
trunk/applications/jason-moise/src/asl/moise-common.asl
trunk/applications/jason-moise/src/jmoise/OrgManager.java
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/asl/herding.asl
trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
trunk/applications/jason-team/src/team-os.xml
trunk/src/jason/asSyntax/VarTerm.java
trunk/src/jason/environment/grid/Location.java
trunk/src/test/VarTermTest.java
Added Paths:
-----------
trunk/applications/jason-team/src/java/jia/near_least_visited.java
Modified: trunk/applications/jason-moise/lib/moise.jar
===================================================================
(Binary files differ)
Modified: trunk/applications/jason-moise/src/asl/moise-common.asl
===================================================================
--- trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-26 14:12:31 UTC (rev 1264)
@@ -51,6 +51,6 @@
// if some scheme is finished, drop all intentions related to it.
-scheme(_Spec,Id)
- <- .drop_desire(X[scheme(Id)]).
+ <- .drop_desire(_[scheme(Id)]).
+error(M)[source(orgManager)] <- .print("Error in organisational action: ",M); -error(M)[source(orgManager)].
Modified: trunk/applications/jason-moise/src/jmoise/OrgManager.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-moise/src/jmoise/OrgManager.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -103,6 +103,7 @@
addCommand(new SetGoalState());
addCommand(new SetGoalArg());
addCommand(new RemoveScheme());
+ addCommand(new AbortScheme());
addCommand(new AddAgent());
}
@@ -428,13 +429,24 @@
sendReply(sender, mId, "error(\"you are not the owner of the scheme " + schId + ", so you can not change it\")");
}
- currentOE.finishScheme(sch);
-
+ act(currentOE, sch);
// send untell to agents
updateMembersOE(currentOE.getAgents(), "scheme(" + sch.getSpec().getId() + "," + sch.getId() + ")[owner(" + sch.getOwner() + ")]", false, false);
}
+ protected void act(OE currentOE, SchemeInstance sch) throws MoiseException {
+ currentOE.finishScheme(sch);
+ }
}
+ class AbortScheme extends RemoveScheme {
+ public String getId() {
+ return "abort_scheme";
+ }
+ protected void act(OE currentOE, SchemeInstance sch) throws MoiseException {
+ currentOE.abortScheme(sch);
+ }
+ }
+
class SetGoalState implements OrgManagerCommand {
public String getId() {
return "set_goal_state";
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-26 14:12:31 UTC (rev 1264)
@@ -1,5 +1,13 @@
/* -- plans for exploration phase -- */
+
+/* -- initial beliefs -- */
+
+// missions I can commit to
+desired_mission(exploring, mexplorer).
+desired_mission(exploring, mscouter).
+
+
/* -- initial goals -- */
//!test.
@@ -34,8 +42,9 @@
X = math.round(((W*H)/3)/H);
+group_area(0, G1, area(0, 0, X, H-1));
+group_area(1, G2, area(X+1, 0, W-1, H/2));
- +group_area(2, G3, area(X+1, (H/2)+1, W-1, H-1)).
+ +group_area(2, G3, area(X+1, (H/2)+1, W-1, H-1)).
+
+group_area(ID,G,A)[source(self)]
<- .broadcast(tell, group_area(ID,G,A)).
@@ -81,8 +90,55 @@
<- .print("ooo find_scouter failure, try another agent.");
!find_scouter(LSOdd,GId).
+// If if start playing explorer in a group that has no scheme, create the scheme
++play(Ag,explorer,G)
+ : .my_name(Ag) &
+ not scheme_group(_,G)
+ <- jmoise.create_scheme(exploring, [G]).
+
-/* plans for agents the others */
+/* plans for the others */
-+!play_role(Role,Group)
- <- jmoise.adopt_role(Role,Group).
++!play_role(Role,Group)[source(Ag)]
+ <- .print("ooo Adopting role ",Role,", asked by ",Ag);
+ jmoise.adopt_role(Role,Group).
+
+
+/* -- plans for the goals of role explorer -- */
+
+// TODO: make a pattern for organisational maintainance goal
+
++!goto_near_unvisited[scheme(Sch)]
+ <- .print("ooo I should find the near unvisited location and go there!");
+ .my_name(Me);
+ ?play(Me,explorer,GroupId); // get the group where I play explorer
+ ?group_area(_,GroupId, Area); // get the area of this group
+ ?pos(MeX, MeY, _); // get my location
+ jia.near_least_visited(MeX, MeY, Area, TargetX, TargetY);
+ -+target(TargetX, TargetY);
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!goto_near_unvisited[scheme(Sch)].
+
+-!goto_near_unvisited[scheme(Sch)]
+ <- .current_intention(I);
+ .print("ooo Failure to goto_near_unvisited ",I);
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!goto_near_unvisited[scheme(Sch)].
+
+
+/* -- plans for the goals of role scouter -- */
+
++!follow_leader[scheme(Sch)]
+ <- .print("ooo I should follow the leader!");
+ // TODO:
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!follow_leader[scheme(Sch)].
+
+/* -- plans for the goals of all roles -- */
+
++!share_cows[scheme(Sch)]
+ <- .print("ooo I should share cows!");
+ // TODO:
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!share_cows[scheme(Sch)].
+
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-26 14:12:31 UTC (rev 1264)
@@ -32,9 +32,6 @@
/* -- plans -- */
-+pos(_,_,_) <- do(skip).
-
-
+?pos(X, Y, S) <- .wait("+pos(X,Y,S)").
+?group_area(Id,G,A) <- .wait("+group_area(Id,G,A)").
Modified: trunk/applications/jason-team/src/asl/herding.asl
===================================================================
--- trunk/applications/jason-team/src/asl/herding.asl 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/asl/herding.asl 2008-04-26 14:12:31 UTC (rev 1264)
@@ -1 +1,35 @@
/* -- plans for herding phase -- */
+
+/* -- initial beliefs -- */
+
+// missions I can commit to
+desired_mission(exploring, mherder).
+desired_mission(exploring, mherdboy).
+
+
+/* -- plans for the goals of role herder -- */
+
++!recruit[scheme(Sch)]
+ <- .print("ooo I should revise the size of the cluster and recruit!");
+ // TODO
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!recruit[scheme(Sch)].
+
+
++!define_formation[scheme(Sch)]
+ <- .print("ooo I should define the formation of my group!");
+ jia.herd_position(2,L); // formation in two (TODO: get the number of players in the group or scheme)
+ .print("ooo formation is ",L);
+ // TODO: allocate and share the formation
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!define_formation[scheme(Sch)].
+
+
+/* -- plans for the goals of all roles (herder and herdboy) -- */
+
++!be_in_formation[scheme(Sch)]
+ <- .print("ooo I should be in formation!");
+ // TODO
+ .wait("+pos(_,_,_)"); // wait next cycle
+ !!be_in_formation[scheme(Sch)].
+
Modified: trunk/applications/jason-team/src/java/arch/LocalWorldModel.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/java/arch/LocalWorldModel.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -185,10 +185,7 @@
}
/** returns the near location of x,y that was least visited */
- public Location getNearLeastVisited(int agx, int agy) {
- //int distanceToBorder = (agx < getWidth()/2 ? agx : getWidth() - agx) - 1;
- Location agloc = new Location(agx,agy);
-
+ public Location getNearLeastVisited(Location agloc, Location tr, Location bl) {
/*
logger.info("------");
for (int i = 0; i < getWidth(); i++) {
@@ -203,8 +200,8 @@
//int visitedTarget = 0;
while (true) {
- int x = agx;
- int y = agy;
+ int x = agloc.x;
+ int y = agloc.y;
int w = 1;
int dx = 0;
int dy = 0;
@@ -217,13 +214,13 @@
dx++;
break;
} else {
- stage = 2;//(x % 2 == 0) ? 2 : 3;
+ stage = 2;
}
case 2: if (dy < w) {
dy++;
break;
} else {
- stage = 3;//(x % 2 == 0) ? 3 : 1;
+ stage = 3;
}
case 3: if (dx > 0) {
dx--;
@@ -243,7 +240,7 @@
}
Location l = new Location(x+dx,y+dy);
- if (isFree(l) && !l.equals(agloc)) {
+ if (isFree(l) && !l.equals(agloc) && l.isInArea(tr, bl)) {
if (visited[l.x][l.y] < minVisited) { // a place better then minVisited! go there
return l;
} if (visited[l.x][l.y] == minVisited) { // a place in the minVisited level
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -3,7 +3,11 @@
import jason.asSemantics.DefaultInternalAction;
import jason.asSemantics.TransitionSystem;
import jason.asSemantics.Unifier;
+import jason.asSyntax.ListTerm;
+import jason.asSyntax.ListTermImpl;
+import jason.asSyntax.NumberTerm;
import jason.asSyntax.NumberTermImpl;
+import jason.asSyntax.Structure;
import jason.asSyntax.Term;
import jason.environment.grid.Location;
@@ -18,6 +22,11 @@
/**
* Gives a good location to herd cows
+ *
+ * the first argument is the formation id (one, two, ... 1, 2, ....)
+ *
+ * if it is called with 3 args, returns the a free location in the formation
+ * otherwise return a list of location for the formation
*
* @author jomi
*/
@@ -26,32 +35,62 @@
public static final double maxStdDev = 3;
public enum Formation {
- one { int[] getDistances() { return new int[] { 0 }; } },
- six { int[] getDistances() { return new int[] { 2, -2, 6, -6, 10, -10 }; } };
+ one { int[] getDistances() { return new int[] { 0 }; } },
+ two { int[] getDistances() { return new int[] { 2, -2 }; } },
+ three { int[] getDistances() { return new int[] { 0, 4, -4 }; } },
+ four { int[] getDistances() { return new int[] { 2, -2, 6, -6 }; } },
+ five { int[] getDistances() { return new int[] { 0, 4, -4, 8, -8 }; } },
+ six { int[] getDistances() { return new int[] { 2, -2, 6, -6, 10, -10 }; } };
abstract int[] getDistances();
};
@Override
- public Object execute(TransitionSystem ts, Unifier un, Term[] terms) throws Exception {
+ public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
try {
CowboyArch arch = (CowboyArch)ts.getUserAgArch();
LocalWorldModel model = arch.getModel();
if (model == null)
return false;
-
Location agLoc = model.getAgPos(arch.getMyId());
+ // identify the formation id
+ Formation formation = Formation.six;
+ if (args[0].isNumeric()) {
+ int index = (int)((NumberTerm)args[0]).solve();
+ formation = Formation.values()[ index-1 ];
+ } else {
+ formation = Formation.valueOf(args[0].toString());
+ }
+
// update GUI
if (arch.hasGUI())
- setFormationLoc(model, Formation.valueOf(terms[0].toString()));
+ setFormationLoc(model, formation);
- Location agTarget = getAgTarget(model, Formation.valueOf(terms[0].toString()), agLoc);
- if (agTarget != null) {
- agTarget = nearFreeForAg(model, agLoc, agTarget);
- return un.unifies(terms[1], new NumberTermImpl(agTarget.x)) &&
- un.unifies(terms[2], new NumberTermImpl(agTarget.y));
+ // if the return is a location for one agent
+ if (args.length == 3) {
+ Location agTarget = getAgTarget(model, formation, agLoc);
+ if (agTarget != null) {
+ return un.unifies(args[1], new NumberTermImpl(agTarget.x)) &&
+ un.unifies(args[2], new NumberTermImpl(agTarget.y));
+ } else {
+ ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(model, formation));
+ }
} else {
- ts.getLogger().info("No target! I am at "+agLoc+" places are "+formationPlaces(model, Formation.valueOf(terms[0].toString())));
+ // return all the locations for the formation
+ List<Location> locs = formationPlaces(model, formation);
+ if (locs != null) {
+ ListTerm r = new ListTermImpl();
+ ListTerm tail = r;
+ for (Location l: locs) {
+ Structure p = new Structure("pos",2);
+ p.addTerm(new NumberTermImpl(l.x));
+ p.addTerm(new NumberTermImpl(l.y));
+ tail = tail.append(p);
+ }
+ return un.unifies(args[1], r);
+ } else {
+ ts.getLogger().info("No formation possible! I am at "+agLoc+" places are "+formationPlaces(model, formation));
+ }
}
} catch (Throwable e) {
ts.getLogger().log(Level.SEVERE, "herd_position error: "+e, e);
@@ -66,11 +105,13 @@
for (Location l : locs) {
r = l;
if (ag.equals(l) || // I am there
- model.countObjInArea(WorldModel.AGENT, l, 1) == 0) { // no one else is there
+ !model.hasObject(WorldModel.AGENT, l)) { // no one else is there
break;
}
}
}
+ if (r != null)
+ r = model.nearFree(r);
return r;
}
@@ -125,7 +166,7 @@
for (int agTargetSize = initAgTS; agTargetSize <= Math.abs(dist); agTargetSize++) {
l = agTarget.newMagnitude(agTargetSize).add(mean).add(agsTarget).getLocation(model);
//System.out.println("pos angle "+agTargetSize);
- uselast = !model.inGrid(l) || model.hasObject(WorldModel.OBSTACLE, l) && lastloc != null;
+ uselast = (!model.inGrid(l) || model.hasObject(WorldModel.OBSTACLE, l)) && lastloc != null;
if (uselast) {
r.add(pathToNearCow(model, lastloc));
break;
@@ -160,8 +201,8 @@
return t;
}
+ /*
public Location nearFreeForAg(LocalWorldModel model, Location ag, Location t) throws Exception {
- /*
// run A* to get the path from ag to t
if (! model.inGrid(t))
t = model.nearFree(t);
@@ -179,8 +220,8 @@
if (i++ > 3) // do not go to far from target
break;
}
- */
return model.nearFree(t);
}
+ */
}
Added: trunk/applications/jason-team/src/java/jia/near_least_visited.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/near_least_visited.java (rev 0)
+++ trunk/applications/jason-team/src/java/jia/near_least_visited.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -0,0 +1,59 @@
+package jia;
+
+import jason.asSemantics.DefaultInternalAction;
+import jason.asSemantics.TransitionSystem;
+import jason.asSemantics.Unifier;
+import jason.asSyntax.NumberTerm;
+import jason.asSyntax.NumberTermImpl;
+import jason.asSyntax.Structure;
+import jason.asSyntax.Term;
+import jason.environment.grid.Location;
+
+import java.util.logging.Level;
+
+import arch.CowboyArch;
+import arch.LocalWorldModel;
+
+/**
+ * Gets the near least visited location for a location (args 0 and 1) inside an area (arg 2).
+ *
+ * Example: jia.near_least_visited(10,10,area(0,0,20,30),X,Y).
+ *
+ * Its is based on the agent's model of the world.
+ *
+ * @author jomi
+ */
+public class near_least_visited extends DefaultInternalAction {
+
+ @Override
+ public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
+ try {
+ LocalWorldModel model = ((CowboyArch)ts.getUserAgArch()).getModel();
+ if (model == null) {
+ ts.getLogger().log(Level.SEVERE, "no model to get near_least_visited!");
+ } else {
+ int agx = (int)((NumberTerm)args[0]).solve();
+ int agy = (int)((NumberTerm)args[1]).solve();
+ Location ag = new Location(agx, agy);
+
+ Structure sarea = (Structure)args[2];
+ int ax1 = (int)((NumberTerm)sarea.getTerm(0)).solve();
+ int ay1 = (int)((NumberTerm)sarea.getTerm(1)).solve();
+ int ax2 = (int)((NumberTerm)sarea.getTerm(2)).solve();
+ int ay2 = (int)((NumberTerm)sarea.getTerm(3)).solve();
+
+ Location tr = new Location(ax1, ay1);
+ Location bl = new Location(ax2, ay2);
+
+ Location n = model.getNearLeastVisited(ag, tr, bl);
+ un.unifies(args[3], new NumberTermImpl(n.x));
+ un.unifies(args[4], new NumberTermImpl(n.y));
+ //ts.getLogger().info("at "+agx+","+agy+" to "+n.x+","+n.y);
+ return true;
+ }
+ } catch (Throwable e) {
+ ts.getLogger().log(Level.SEVERE, "near_least_visited error: "+e, e);
+ }
+ return false;
+ }
+}
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -170,7 +170,6 @@
scenario2();
model.add(WorldModel.ENEMY, 11,48);
Location byIA = new herd_position().getAgTarget(model, Formation.one, cowboy.getLocation(model));
- byIA = new herd_position().nearFreeForAg(model, new Location(11,46), byIA);
assertEquals(new Location(11,49), byIA);
}
Modified: trunk/applications/jason-team/src/team-os.xml
===================================================================
--- trunk/applications/jason-team/src/team-os.xml 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/applications/jason-team/src/team-os.xml 2008-04-26 14:12:31 UTC (rev 1264)
@@ -107,8 +107,8 @@
</functional-specification>
<deontic-specification>
- <deontic-relation type="obligation" role="explorer" mission="mscouter" />
- <deontic-relation type="obligation" role="scouter" mission="mexplorer" />
+ <deontic-relation type="obligation" role="explorer" mission="mexplorer" />
+ <deontic-relation type="obligation" role="scouter" mission="mscouter" />
<deontic-relation type="obligation" role="herder" mission="mherder" />
<deontic-relation type="obligation" role="herdboy" mission="mherdboy" />
</deontic-specification>
Modified: trunk/src/jason/asSyntax/VarTerm.java
===================================================================
--- trunk/src/jason/asSyntax/VarTerm.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/src/jason/asSyntax/VarTerm.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -368,9 +368,12 @@
@Override
public void countVars(Map<VarTerm, Integer> c) {
- if (isVar()) {
- int n = c.containsKey(this) ? c.get(this) : 0;
- c.put(this, n+1);
+ if (value == null) {
+ int n = c.containsKey(this) ? c.get(this) : 0;
+ c.put(this, n+1);
+ super.countVars(c);
+ } else {
+ value.countVars(c);
}
}
Modified: trunk/src/jason/environment/grid/Location.java
===================================================================
--- trunk/src/jason/environment/grid/Location.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/src/jason/environment/grid/Location.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -23,7 +23,10 @@
return Math.max( Math.abs(this.x - l.x) , Math.abs(this.y - l.y));
}
- public boolean isNeigbour(Location l) {
+ public boolean isInArea(Location tr, Location bl) {
+ return x >= tr.x && x <= bl.x && y >= tr.y && y <= bl.y;
+ }
+ public boolean isNeigbour(Location l) {
return
distance(l) == 1 ||
equals(l) ||
Modified: trunk/src/test/VarTermTest.java
===================================================================
--- trunk/src/test/VarTermTest.java 2008-04-26 11:54:31 UTC (rev 1263)
+++ trunk/src/test/VarTermTest.java 2008-04-26 14:12:31 UTC (rev 1264)
@@ -23,7 +23,9 @@
import jason.infra.centralised.CentralisedAgArch;
import java.io.StringReader;
+import java.util.HashMap;
import java.util.Iterator;
+import java.util.Map;
import junit.framework.TestCase;
@@ -443,6 +445,13 @@
assertFalse(v.isGround());
}
+ public void testUnamedVarAnnots() {
+ Term t = DefaultTerm.parse("_[scheme(Id)]");
+ Map<VarTerm,Integer> c = new HashMap<VarTerm, Integer>();
+ t.countVars(c);
+ assertEquals(1,c.get(new VarTerm("Id")).intValue());
+ }
+
public void testUnifClone() {
VarTerm x1 = new VarTerm("X");
VarTerm x2 = new VarTerm("X");
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-26 11:54:33
|
Revision: 1263
http://jason.svn.sourceforge.net/jason/?rev=1263&view=rev
Author: jomifred
Date: 2008-04-26 04:54:31 -0700 (Sat, 26 Apr 2008)
Log Message:
-----------
fix bug in drop_desire
Modified Paths:
--------------
trunk/applications/jason-moise/lib/moise.jar
trunk/applications/jason-moise/src/asl/moise-common.asl
trunk/applications/jason-moise/src/jmoise/OrgAgent.java
trunk/applications/jason-moise/src/jmoise/link.java
trunk/applications/jason-team/src/java/jia/random.java
trunk/demos/tell-rule/rules/get_rules.java
trunk/examples/gold-miners-II/jia/random.java
trunk/examples/iterated-prisoners-dilemma/my/random.java
trunk/src/jason/asSemantics/Agent.java
trunk/src/jason/asSemantics/IntendedMeans.java
trunk/src/jason/asSemantics/Intention.java
trunk/src/jason/asSemantics/Unifier.java
trunk/src/jason/asSyntax/Literal.java
trunk/src/jason/asSyntax/Structure.java
trunk/src/jason/stdlib/drop_desire.java
trunk/src/jason/stdlib/drop_intention.java
Modified: trunk/applications/jason-moise/lib/moise.jar
===================================================================
(Binary files differ)
Modified: trunk/applications/jason-moise/src/asl/moise-common.asl
===================================================================
--- trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/applications/jason-moise/src/asl/moise-common.asl 2008-04-26 11:54:31 UTC (rev 1263)
@@ -48,5 +48,9 @@
+goal_state(Sch, G[root], achieved)
: true | .print("achieved ",G) // just to avoid G as singleton var warning
<- jmoise.remove_mission(Sch).
-
-+error(M)[source(orgManager)] <- .print("Error in organisational action: ",M); -error(M).
+
+// if some scheme is finished, drop all intentions related to it.
+-scheme(_Spec,Id)
+ <- .drop_desire(X[scheme(Id)]).
+
++error(M)[source(orgManager)] <- .print("Error in organisational action: ",M); -error(M)[source(orgManager)].
Modified: trunk/applications/jason-moise/src/jmoise/OrgAgent.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/applications/jason-moise/src/jmoise/OrgAgent.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -13,6 +13,7 @@
import jason.asSyntax.Literal;
import jason.asSyntax.Pred;
import jason.asSyntax.PredicateIndicator;
+import jason.asSyntax.Structure;
import jason.asSyntax.Term;
import jason.asSyntax.Trigger;
import jason.asSyntax.UnnamedVar;
@@ -34,6 +35,8 @@
import moise.oe.OEAgent;
import moise.oe.Permission;
import moise.oe.SchemeInstance;
+import moise.os.fs.Goal;
+import moise.os.fs.Goal.GoalType;
/**
* Organisational Architecture, binds Jason agent to
@@ -187,9 +190,19 @@
alreadyGeneratedEvents.add(gi);
Literal l = Literal.parseLiteral(gi.getAsProlog());
- Literal giID = new Literal("scheme");
+ // add annot with scheme id
+ Structure giID = new Structure("scheme", 1);
giID.addTerm(new Atom(gi.getScheme().getId()));
l.addAnnot(giID);
+
+ // add annot with type of goal
+ Structure type = new Structure("type", 1);
+ type.addTerm(getGoalTypeAtom(gi.getSpec()));
+ l.addAnnot(type);
+
+ // add source annot
+ l.addAnnot(managerSource);
+
// "role(notimplemented),group(notimplemented)"+
// TODO: add annots: role, group (percorrer as missoes do ag que
// em GI, procurar os papel com obrigacao para essa missao)
@@ -198,6 +211,17 @@
}
}
}
+
+ private static final Atom aAchievementGoal = new Atom(GoalType.achievement.toString());
+ private static final Atom aMaintenanceGoal = new Atom(GoalType.maintenance.toString());
+
+ public static Atom getGoalTypeAtom(Goal g) {
+ switch (g.getType()) {
+ case achievement: return aAchievementGoal;
+ case maintenance: return aMaintenanceGoal;
+ }
+ return null;
+ }
void removeAchieveEvents(String schId) {
Iterator<GoalInstance> i = alreadyGeneratedEvents.iterator();
Modified: trunk/applications/jason-moise/src/jmoise/link.java
===================================================================
--- trunk/applications/jason-moise/src/jmoise/link.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/applications/jason-moise/src/jmoise/link.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -75,7 +75,7 @@
gr = rp.getGroup();
}
for (OEAgent ag: currentOE.getAgents( gr, link.getTarget())) { // all agents of the target role
- Unifier c = (Unifier)un.clone();
+ Unifier c = un.copy();
// unifies the type and target
if (c.unifies(args[0], new Atom(link.getTypeStr())) &&
Modified: trunk/applications/jason-team/src/java/jia/random.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/random.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/applications/jason-team/src/java/jia/random.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -38,7 +38,7 @@
public Unifier next() {
i++;
- Unifier c = (Unifier)un.clone();
+ Unifier c = un.copy();
c.unifies(args[0], new NumberTermImpl(random.nextInt(max)));
return c;
}
Modified: trunk/demos/tell-rule/rules/get_rules.java
===================================================================
--- trunk/demos/tell-rule/rules/get_rules.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/demos/tell-rule/rules/get_rules.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -27,8 +27,7 @@
while (i.hasNext()) {
Literal l = i.next();
if (l.isRule()) {
- Unifier unc = (Unifier)un.clone();
- if (unc.unifies(pattern, l)) {
+ if (un.copy().unifies(pattern, l)) {
l = (Literal)l.clone();
l.delSources();
result.add(new StringTermImpl(l.toString()));
Modified: trunk/examples/gold-miners-II/jia/random.java
===================================================================
--- trunk/examples/gold-miners-II/jia/random.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/examples/gold-miners-II/jia/random.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -38,7 +38,7 @@
public Unifier next() {
i++;
- Unifier c = (Unifier)un.clone();
+ Unifier c = un.copy();
c.unifies(args[0], new NumberTermImpl(random.nextInt(max)));
return c;
}
Modified: trunk/examples/iterated-prisoners-dilemma/my/random.java
===================================================================
--- trunk/examples/iterated-prisoners-dilemma/my/random.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/examples/iterated-prisoners-dilemma/my/random.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -35,7 +35,7 @@
}
public Unifier next() {
- Unifier c = (Unifier)un.clone();
+ Unifier c = un.copy();
c.unifies(args[0], new NumberTermImpl(random.nextInt(max)));
return c;
}
Modified: trunk/src/jason/asSemantics/Agent.java
===================================================================
--- trunk/src/jason/asSemantics/Agent.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSemantics/Agent.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -649,7 +649,7 @@
Literal inBB = il.next();
if (!inBB.isRule()) {
// need to clone unifier since it is changed in previous iteration
- Unifier unC = (un == null ? new Unifier() : (Unifier)un.clone());
+ Unifier unC = (un == null ? new Unifier() : un.copy());
if (unC.unifiesNoUndo(bel, inBB)) {
toDel.add(inBB);
}
Modified: trunk/src/jason/asSemantics/IntendedMeans.java
===================================================================
--- trunk/src/jason/asSemantics/IntendedMeans.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSemantics/IntendedMeans.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -126,7 +126,7 @@
public Object clone() {
IntendedMeans c = new IntendedMeans();
- c.unif = (Unifier)this.unif.clone();
+ c.unif = this.unif.copy();
c.plan = (Plan)this.plan.clone();
c.trigger = (Trigger)this.trigger.clone();
return c;
Modified: trunk/src/jason/asSemantics/Intention.java
===================================================================
--- trunk/src/jason/asSemantics/Intention.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSemantics/Intention.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -130,6 +130,7 @@
/** returns the IntendedMeans with TE = g, returns null if there isn't one */
public IntendedMeans getIM(Trigger g, Unifier u) {
for (IntendedMeans im : intendedMeans) {
+ //System.out.println(g + " = "+ im.getTrigger()+" = "+u.unifies(g, im.getTrigger()));
if (u.unifies(g, im.getTrigger())) {
return im;
}
Modified: trunk/src/jason/asSemantics/Unifier.java
===================================================================
--- trunk/src/jason/asSemantics/Unifier.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSemantics/Unifier.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -348,6 +348,11 @@
}
}
+ /** same as clone but with typed return */
+ public Unifier copy() {
+ return (Unifier)clone();
+ }
+
public boolean equals(Object o) {
if (o == null) return false;
if (o == this) return true;
Modified: trunk/src/jason/asSyntax/Literal.java
===================================================================
--- trunk/src/jason/asSyntax/Literal.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSyntax/Literal.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -166,7 +166,7 @@
Literal rhead = rule.headClone();
rhead.apply(ruleUn);
- Unifier unC = (Unifier) un.clone();
+ Unifier unC = un.copy();
if (unC.unifiesNoUndo(Literal.this, rhead)) {
current = unC;
return;
Modified: trunk/src/jason/asSyntax/Structure.java
===================================================================
--- trunk/src/jason/asSyntax/Structure.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/asSyntax/Structure.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -76,8 +76,12 @@
setSrc(t);
}
- /** to be used by list term and atom to not create the array list for terms */
- protected Structure(String functor, int termsSize) {
+ /**
+ * Create a structure with a defined number of terms.
+ *
+ * It is used by list term and atom to not create the array list for terms.
+ */
+ public Structure(String functor, int termsSize) {
//this.functor = (functor == null ? null : functor.intern());
if (functor == null)
logger.log(Level.WARNING, "A structure functor should not be null!", new Exception());
Modified: trunk/src/jason/stdlib/drop_desire.java
===================================================================
--- trunk/src/jason/stdlib/drop_desire.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/stdlib/drop_desire.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -94,7 +94,7 @@
t = (Trigger) t.clone();
t.apply(ei.getIntention().peek().getUnif());
}
- if (un.unifies(t, te)) {
+ if (un.copy().unifiesNoUndo(t, te)) {
// old implementation: t.setTrigType(Trigger.TEDel); // Just changing "+!g" to "-!g"
ie.remove();
}
Modified: trunk/src/jason/stdlib/drop_intention.java
===================================================================
--- trunk/src/jason/stdlib/drop_intention.java 2008-04-26 08:07:38 UTC (rev 1262)
+++ trunk/src/jason/stdlib/drop_intention.java 2008-04-26 11:54:31 UTC (rev 1263)
@@ -84,7 +84,7 @@
Trigger g = new Trigger(TEOperator.add, TEType.achieve, l);
for (Intention i: C.getIntentions()) {
- if (i.hasTrigger(g, un)) {
+ if (i.hasTrigger(g, un.copy())) {
C.removeIntention(i);
}
}
@@ -92,7 +92,7 @@
// intention may be suspended in E
for (Event e: C.getEvents()) {
Intention i = e.getIntention();
- if (i != null && i.hasTrigger(g, un)) {
+ if (i != null && i.hasTrigger(g, un.copy())) {
C.removeEvent(e);
}
}
@@ -100,14 +100,14 @@
// intention may be suspended in PA! (in the new semantics)
for (ActionExec a: C.getPendingActions().values()) {
Intention i = a.getIntention();
- if (i.hasTrigger(g, un)) {
+ if (i.hasTrigger(g, un.copy())) {
C.dropPendingAction(i);
}
}
// intention may be suspended in PI! (in the new semantics)
for (Intention i: C.getPendingIntentions().values()) {
- if (i != null && i.hasTrigger(g, un)) {
+ if (i != null && i.hasTrigger(g, un.copy())) {
C.dropPendingIntention(i);
}
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-26 08:07:41
|
Revision: 1262
http://jason.svn.sourceforge.net/jason/?rev=1262&view=rev
Author: jomifred
Date: 2008-04-26 01:07:38 -0700 (Sat, 26 Apr 2008)
Log Message:
-----------
add schemes for herding and exploring in the org. spec.
define better cardinalities in org. spec.
Modified Paths:
--------------
trunk/applications/jason-moise/lib/moise.jar
trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
trunk/applications/jason-team/doc/roles/ac2008-roles.pdf
trunk/applications/jason-team/doc/roles/figures/jason-team-SS.pdf
trunk/applications/jason-team/src/java/arch/CowboyArch.java
trunk/applications/jason-team/src/team-os.xml
trunk/src/jason/infra/centralised/CentralisedAgArch.java
Added Paths:
-----------
trunk/applications/jason-team/doc/roles/figures/jason-team-SS.dia
trunk/src/jason/ReceiverNotFoundException.java
Removed Paths:
-------------
trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps
trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps
trunk/applications/jason-team/doc/roles/figures/partition.eps
trunk/src/jason/ReceiverDoesNotExistException.java
Modified: trunk/applications/jason-moise/lib/moise.jar
===================================================================
(Binary files differ)
Modified: trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-25 20:05:54 UTC (rev 1261)
+++ trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-26 08:07:38 UTC (rev 1262)
@@ -10,36 +10,36 @@
infrastructure: Centralised
agents:
- orgManager [osfile="src/team-os.xml",gui=no]
+ orgManager [osfile="src/team-os.xml",gui=yes]
agentArchClass jmoise.OrgManager;
- gaucho1 dummy.asl
+ gaucho1 gaucho.asl
[verbose=1, gui=yes, write_status=yes, ac_sim_back_dir="./massim-server/backup",
host="localhost", port=12300, username=participant1, password="1"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
- gaucho2 dummy.asl
+ gaucho2 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant2, password="2"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
- gaucho3 dummy.asl
+ gaucho3 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant3, password="3"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
- gaucho4 dummy.asl
+ gaucho4 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant4, password="4"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
- gaucho5 dummy.asl
+ gaucho5 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant5, password="5"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
- gaucho6 dummy.asl
+ gaucho6 gaucho.asl
[verbose=1,host="localhost", port=12300, username=participant6, password="6"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
Modified: trunk/applications/jason-team/doc/roles/ac2008-roles.pdf
===================================================================
(Binary files differ)
Deleted: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps
===================================================================
--- trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps 2008-04-25 20:05:54 UTC (rev 1261)
+++ trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps 2008-04-26 08:07:38 UTC (rev 1262)
@@ -1,382 +0,0 @@
-%!PS-Adobe-3.0 EPSF-3.0
-%%BoundingBox: 0 0 326 332
-%%Pages: 0
-%%Creator: Sun Microsystems, Inc.
-%%Title: none
-%%CreationDate: none
-%%LanguageLevel: 2
-%%EndComments
-%%BeginProlog
-%%BeginResource: procset SDRes-Prolog 1.0 0
-/b4_inc_state save def
-/dict_count countdictstack def
-/op_count count 1 sub def
-userdict begin
-0 setgray 0 setlinecap 1 setlinewidth 0 setlinejoin 10 setmiterlimit[] 0 setdash newpath
-/languagelevel where {pop languagelevel 1 ne {false setstrokeadjust false setoverprint} if} if
-/bdef {bind def} bind def
-/c {setrgbcolor} bdef
-/l {neg lineto} bdef
-/rl {neg rlineto} bdef
-/lc {setlinecap} bdef
-/lj {setlinejoin} bdef
-/lw {setlinewidth} bdef
-/ml {setmiterlimit} bdef
-/ld {setdash} bdef
-/m {neg moveto} bdef
-/ct {6 2 roll neg 6 2 roll neg 6 2 roll neg curveto} bdef
-/r {rotate} bdef
-/t {neg translate} bdef
-/s {scale} bdef
-/sw {show} bdef
-/gs {gsave} bdef
-/gr {grestore} bdef
-/f {findfont dup length dict begin
-{1 index /FID ne {def} {pop pop} ifelse} forall /Encoding ISOLatin1Encoding def
-currentdict end /NFont exch definefont pop /NFont findfont} bdef
-/p {closepath} bdef
-/sf {scalefont setfont} bdef
-/ef {eofill}bdef
-/pc {closepath stroke}bdef
-/ps {stroke}bdef
-/pum {matrix currentmatrix}bdef
-/pom {setmatrix}bdef
-/bs {/aString exch def /nXOfs exch def /nWidth exch def currentpoint nXOfs 0 rmoveto pum nWidth aString stringwidth pop div 1 scale aString show pom moveto} bdef
-%%EndResource
-%%EndProlog
-%%BeginSetup
-%%EndSetup
-%%Page: 1 1
-%%BeginPageSetup
-%%EndPageSetup
-pum
-0.02834 0.02831 s
-0 -11726 t
-/tm matrix currentmatrix def
-tm setmatrix
--2500 -11000 t
-1 1 s
-0.753 0.753 0.753 c 3500 20000 m 4067 20000 4500 20433 4500 21000 ct 4500 21567 4067 22000 3500 22000 ct
-2933 22000 2500 21567 2500 21000 ct 2500 20433 2933 20000 3500 20000 ct p ef
-0 lw 1 lj 0.003 0.003 0.003 c 3500 20000 m 4067 20000 4500 20433 4500 21000 ct
-4500 21567 4067 22000 3500 22000 ct 2933 22000 2500 21567 2500 21000 ct 2500 20433 2933 20000 3500 20000 ct
-pc
-0.648 0.648 0.648 c 3175 20588 m 3235 20588 3282 20635 3282 20695 ct 3282 20755 3235 20802 3175 20802 ct
-3115 20802 3068 20755 3068 20695 ct 3068 20635 3115 20588 3175 20588 ct p ef
-0.003 0.003 0.003 c 3175 20588 m 3235 20588 3282 20635 3282 20695 ct 3282 20755 3235 20802 3175 20802 ct
-3115 20802 3068 20755 3068 20695 ct 3068 20635 3115 20588 3175 20588 ct pc
-0.648 0.648 0.648 c 3823 20588 m 3883 20588 3930 20635 3930 20695 ct 3930 20755 3883 20802 3823 20802 ct
-3763 20802 3716 20755 3716 20695 ct 3716 20635 3763 20588 3823 20588 ct p ef
-0.003 0.003 0.003 c 3823 20588 m 3883 20588 3930 20635 3930 20695 ct 3930 20755 3883 20802 3823 20802 ct
-3763 20802 3716 20755 3716 20695 ct 3716 20635 3763 20588 3823 20588 ct pc
-2951 21436 m 3304 21623 3696 21623 4049 21436 ct ps
-gs
-gs
-pum
-10438 19614 t
-54 0 m 54 -455 l 385 -455 l 385 -399 l 114 -399 l 114 -261 l 365 -261 l
-365 -207 l 114 -207 l 114 -53 l 389 -53 l 389 0 l 54 0 l p
-222 -455 m 222 -455 l p ef
-543 -169 m 432 -331 l 505 -331 l 581 -214 l 658 -331 l 726 -329 l
-614 -169 l 731 0 l 660 0 l 577 -124 l 497 0 l 426 0 l 543 -169 l
-p ef
-923 -35 m 948 -35 969 -46 986 -68 ct 1003 -90 1012 -123 1012 -167 ct 1012 -193 1008 -216 1001 -236 ct
-986 -273 960 -291 923 -291 ct 884 -291 858 -271 844 -232 ct 837 -212 833 -185 833 -153 ct
-833 -127 837 -105 844 -87 ct 859 -52 885 -35 923 -35 ct p
-778 132 m 778 132 778 132 778 -330 ct 778 -330 778 -330 833 -330 ct 833 -330 833 -330 833 -286 ct
-844 -301 856 -313 869 -321 ct 888 -333 910 -339 935 -339 ct 973 -339 1005 -325 1031 -296 ct
-1057 -267 1070 -226 1070 -172 ct 1070 -99 1051 -48 1013 -17 ct 989 2 962 12 930 12 ct
-905 12 884 7 867 -3 ct 857 -9 846 -20 834 -35 ct 834 -35 834 -35 834 132 ct 834 132 834 132 778 132 ct
-p ef
-1134 0 m 1134 -454 l 1190 -454 l 1190 0 l 1134 0 l p ef
-1404 -35 m 1440 -35 1465 -49 1479 -77 ct 1492 -105 1499 -137 1499 -171 ct 1499 -202 1494 -227 1484 -247 ct
-1469 -278 1442 -293 1404 -293 ct 1371 -293 1346 -280 1331 -254 ct 1316 -228 1308 -196 1308 -159 ct
-1308 -124 1316 -94 1331 -70 ct 1346 -47 1370 -35 1404 -35 ct p
-1405 -341 m 1448 -341 1484 -327 1513 -298 ct 1542 -270 1557 -228 1557 -172 ct
-1557 -119 1544 -74 1518 -39 ct 1492 -4 1452 12 1398 12 ct 1353 12 1317 -2 1290 -33 ct
-1263 -64 1250 -106 1250 -158 ct 1250 -214 1264 -258 1292 -291 ct 1320 -324 1358 -341 1405 -341 ct
-p
-1404 -339 m 1404 -339 l p ef
-1625 0 m 1625 0 1625 0 1625 -332 ct 1625 -332 1625 -332 1678 -332 ct 1678 -332 1678 -332 1678 -275 ct
-1682 -286 1693 -299 1710 -315 ct 1727 -331 1747 -339 1769 -339 ct 1770 -339 1772 -339 1774 -339 ct
-1777 -338 1781 -338 1787 -337 ct 1787 -337 1787 -337 1787 -279 ct 1784 -280 1781 -280 1778 -281 ct
-1775 -281 1772 -281 1769 -281 ct 1740 -281 1719 -272 1704 -254 ct 1689 -235 1681 -214 1681 -191 ct
-1681 -191 1681 -191 1681 0 ct 1681 0 1681 0 1625 0 ct p ef
-1973 -339 m 1996 -339 2019 -333 2041 -322 ct 2063 -311 2079 -297 2091 -279 ct
-2102 -262 2109 -243 2113 -220 ct 2116 -205 2118 -180 2118 -147 ct 2118 -147 2118 -147 1877 -147 ct
-1878 -113 1886 -86 1901 -66 ct 1915 -45 1938 -35 1969 -35 ct 1998 -35 2021 -45 2038 -64 ct
-2047 -75 2054 -87 2058 -102 ct 2058 -102 2058 -102 2113 -102 ct 2112 -90 2107 -76 2099 -62 ct
-2090 -47 2081 -35 2071 -25 ct 2054 -9 2034 1 2009 7 ct 1996 10 1981 12 1964 12 ct
-1923 12 1888 -2 1860 -32 ct 1831 -62 1817 -105 1817 -159 ct 1817 -212 1831 -256 1860 -289 ct
-1889 -322 1926 -339 1973 -339 ct p
-1878 -191 m 1878 -191 1878 -191 2060 -191 ct 2058 -216 2053 -235 2044 -250 ct
-2029 -277 2004 -291 1969 -291 ct 1944 -291 1922 -282 1905 -263 ct 1888 -244 1879 -220 1878 -191 ct
-p
-1968 -339 m 1968 -339 l p ef
-2188 0 m 2188 0 2188 0 2188 -332 ct 2188 -332 2188 -332 2241 -332 ct 2241 -332 2241 -332 2241 -275 ct
-2245 -286 2256 -299 2273 -315 ct 2290 -331 2310 -339 2332 -339 ct 2333 -339 2335 -339 2337 -339 ct
-2340 -338 2344 -338 2350 -337 ct 2350 -337 2350 -337 2350 -279 ct 2347 -280 2344 -280 2341 -281 ct
-2338 -281 2335 -281 2332 -281 ct 2303 -281 2282 -272 2267 -254 ct 2252 -235 2244 -214 2244 -191 ct
-2244 -191 2244 -191 2244 0 ct 2244 0 2244 0 2188 0 ct p ef
-pom
-gr
-gr
-gs
-gs
-pum
-4246 22312 t
-31 -147 m 31 -147 31 -147 89 -147 ct 90 -121 96 -100 107 -84 ct 126 -54 161 -39 210 -39 ct
-233 -39 253 -42 271 -49 ct 306 -62 324 -85 324 -118 ct 324 -143 317 -161 302 -171 ct
-286 -181 263 -190 230 -197 ct 230 -197 230 -197 171 -211 ct 132 -220 104 -230 88 -241 ct
-60 -260 46 -288 46 -326 ct 46 -367 60 -401 87 -427 ct 115 -454 154 -467 204 -467 ct
-251 -467 290 -455 322 -432 ct 355 -409 371 -373 371 -322 ct 371 -322 371 -322 313 -322 ct
-310 -346 304 -365 294 -378 ct 276 -401 246 -413 203 -413 ct 168 -413 143 -405 128 -390 ct
-113 -375 105 -357 105 -337 ct 105 -315 114 -298 132 -288 ct 144 -281 170 -273 212 -263 ct
-212 -263 212 -263 273 -249 ct 303 -242 326 -232 342 -220 ct 370 -199 384 -168 384 -127 ct
-384 -77 366 -41 330 -19 ct 295 1 253 12 206 12 ct 151 12 108 -1 77 -30 ct 46 -59 30 -98 31 -147 ct
-p
-209 -467 m 209 -467 l p ef
-592 -341 m 629 -341 659 -332 683 -314 ct 706 -296 720 -264 725 -220 ct 725 -220 725 -220 671 -220 ct
-668 -240 660 -257 648 -271 ct 637 -284 618 -291 592 -291 ct 556 -291 531 -274 516 -239 ct
-506 -216 501 -188 501 -155 ct 501 -122 508 -94 522 -71 ct 536 -48 558 -37 588 -37 ct
-611 -37 630 -44 643 -58 ct 657 -72 666 -92 671 -116 ct 671 -116 671 -116 725 -116 ct
-719 -72 703 -40 679 -20 ct 654 0 622 10 583 10 ct 540 10 506 -5 480 -37 ct 454 -68 441 -108 441 -156 ct
-441 -214 455 -260 483 -292 ct 512 -325 548 -341 592 -341 ct p
-583 -339 m 583 -339 l p ef
-913 -35 m 949 -35 974 -49 988 -77 ct 1001 -105 1008 -137 1008 -171 ct 1008 -202 1003 -227 993 -247 ct
-978 -278 951 -293 913 -293 ct 880 -293 855 -280 840 -254 ct 825 -228 817 -196 817 -159 ct
-817 -124 825 -94 840 -70 ct 855 -47 879 -35 913 -35 ct p
-914 -341 m 957 -341 993 -327 1022 -298 ct 1051 -270 1066 -228 1066 -172 ct
-1066 -119 1053 -74 1027 -39 ct 1001 -4 961 12 907 12 ct 862 12 826 -2 799 -33 ct
-772 -64 759 -106 759 -158 ct 759 -214 773 -258 801 -291 ct 829 -324 867 -341 914 -341 ct
-p
-913 -339 m 913 -339 l p ef
-1132 -332 m 1132 -332 1132 -332 1188 -332 ct 1188 -332 1188 -332 1188 -110 ct
-1188 -93 1191 -79 1196 -68 ct 1206 -48 1224 -38 1250 -38 ct 1288 -38 1314 -55 1328 -90 ct
-1335 -109 1339 -135 1339 -168 ct 1339 -168 1339 -168 1339 -332 ct 1339 -332 1339 -332 1395 -332 ct
-1395 -332 1395 -332 1395 0 ct 1395 0 1395 0 1342 0 ct 1342 0 1342 0 1343 -47 ct
-1336 -34 1327 -24 1316 -15 ct 1295 1 1270 9 1240 9 ct 1194 9 1162 -6 1146 -38 ct
-1137 -55 1132 -77 1132 -106 ct 1132 -106 1132 -106 1132 -332 ct p
-1264 -339 m 1264 -339 l p ef
-1496 -332 m 1496 -332 1496 -332 1496 -424 ct 1496 -424 1496 -424 1552 -424 ct
-1552 -424 1552 -424 1552 -332 ct 1552 -332 1552 -332 1605 -332 ct 1605 -332 1605 -332 1605 -286 ct
-1605 -286 1605 -286 1552 -286 ct 1552 -286 1552 -286 1552 -70 ct 1552 -58 1556 -50 1564 -46 ct
-1568 -44 1575 -43 1585 -43 ct 1588 -43 1591 -43 1594 -43 ct 1597 -43 1601 -44 1605 -44 ct
-1605 -44 1605 -44 1605 0 ct 1599 2 1592 3 1585 4 ct 1578 5 1571 5 1563 5 ct 1537 5 1519 -1 1510 -14 ct
-1501 -27 1496 -45 1496 -66 ct 1496 -66 1496 -66 1496 -286 ct 1496 -286 1496 -286 1451 -286 ct
-1451 -286 1451 -286 1451 -332 ct 1451 -332 1451 -332 1496 -332 ct p ef
-pom
-gr
-gr
-gs
-gs
-pum
-11258 12708 t
-9 -455 m 377 -455 l 377 -401 l 224 -401 l 224 0 l 162 0 l 162 -401 l
-9 -401 l 9 -455 l p ef
-401 -87 m 401 -71 407 -58 419 -49 ct 430 -40 444 -35 461 -35 ct 480 -35 499 -40 518 -49 ct
-549 -64 564 -89 564 -123 ct 564 -123 564 -123 564 -168 ct 557 -163 548 -159 538 -156 ct
-527 -153 516 -151 506 -150 ct 506 -150 506 -150 472 -146 ct 452 -143 437 -139 427 -133 ct
-410 -123 401 -108 401 -87 ct p
-447 -189 m 447 -189 447 -189 536 -200 ct 549 -201 557 -207 562 -216 ct 565 -221 566 -228 566 -237 ct
-566 -256 559 -270 546 -278 ct 532 -287 513 -291 487 -291 ct 458 -291 438 -283 425 -268 ct
-419 -259 414 -246 412 -229 ct 412 -229 412 -229 360 -229 ct 361 -270 374 -299 400 -315 ct
-425 -331 455 -339 489 -339 ct 528 -339 559 -331 584 -316 ct 608 -301 620 -278 620 -247 ct
-620 -247 620 -247 620 -56 ct 620 -50 621 -46 624 -42 ct 626 -39 631 -37 639 -37 ct
-641 -37 644 -37 647 -37 ct 650 -38 653 -38 657 -39 ct 657 -39 657 -39 657 1 ct
-648 4 642 5 637 6 ct 633 7 626 7 618 7 ct 599 7 585 0 576 -12 ct 572 -20 569 -30 567 -43 ct
-555 -28 539 -15 518 -4 ct 497 6 473 12 448 12 ct 417 12 392 3 372 -15 ct 353 -34 343 -57 343 -85 ct
-343 -116 353 -140 372 -157 ct 391 -174 416 -185 447 -189 ct p
-490 -339 m 490 -339 l p ef
-711 0 m 711 0 711 0 711 -332 ct 711 -332 711 -332 764 -332 ct 764 -332 764 -332 764 -275 ct
-768 -286 779 -299 796 -315 ct 813 -331 833 -339 855 -339 ct 856 -339 858 -339 860 -339 ct
-863 -338 867 -338 873 -337 ct 873 -337 873 -337 873 -279 ct 870 -280 867 -280 864 -281 ct
-861 -281 858 -281 855 -281 ct 826 -281 805 -272 790 -254 ct 775 -235 767 -214 767 -191 ct
-767 -191 767 -191 767 0 ct 767 0 767 0 711 0 ct p ef
-1039 -337 m 1065 -337 1088 -331 1108 -318 ct 1118 -311 1129 -301 1140 -287 ct
-1140 -287 1140 -287 1140 -328 ct 1140 -328 1140 -328 1190 -328 ct 1190 -328 1190 -328 1190 -26 ct
-1190 15 1184 48 1171 72 ct 1148 117 1105 140 1040 140 ct 1004 140 974 132 950 116 ct
-926 100 912 75 909 41 ct 909 41 909 41 967 41 ct 970 56 975 67 983 75 ct 996 88 1016 94 1043 94 ct
-1086 94 1114 79 1127 49 ct 1135 31 1139 0 1138 -46 ct 1127 -29 1113 -16 1097 -8 ct
-1082 0 1061 4 1035 4 ct 999 4 967 -8 940 -33 ct 913 -59 899 -101 899 -160 ct 899 -216 913 -259 940 -290 ct
-967 -321 1000 -337 1039 -337 ct p
-1139 -167 m 1139 -209 1131 -239 1114 -259 ct 1097 -279 1075 -289 1049 -289 ct
-1010 -289 983 -271 968 -234 ct 961 -214 957 -188 957 -156 ct 957 -119 965 -90 980 -70 ct
-995 -51 1015 -41 1041 -41 ct 1081 -41 1109 -59 1125 -95 ct 1134 -116 1139 -140 1139 -167 ct
-p
-1045 -339 m 1045 -339 l p ef
-1410 -339 m 1433 -339 1456 -333 1478 -322 ct 1500 -311 1516 -297 1528 -279 ct
-1539 -262 1546 -243 1550 -220 ct 1553 -205 1555 -180 1555 -147 ct 1555 -147 1555 -147 1314 -147 ct
-1315 -113 1323 -86 1338 -66 ct 1352 -45 1375 -35 1406 -35 ct 1435 -35 1458 -45 1475 -64 ct
-1484 -75 1491 -87 1495 -102 ct 1495 -102 1495 -102 1550 -102 ct 1549 -90 1544 -76 1536 -62 ct
-1527 -47 1518 -35 1508 -25 ct 1491 -9 1471 1 1446 7 ct 1433 10 1418 12 1401 12 ct
-1360 12 1325 -2 1297 -32 ct 1268 -62 1254 -105 1254 -159 ct 1254 -212 1268 -256 1297 -289 ct
-1326 -322 1363 -339 1410 -339 ct p
-1315 -191 m 1315 -191 1315 -191 1497 -191 ct 1495 -216 1490 -235 1481 -250 ct
-1466 -277 1441 -291 1406 -291 ct 1381 -291 1359 -282 1342 -263 ct 1325 -244 1316 -220 1315 -191 ct
-p
-1405 -339 m 1405 -339 l p ef
-1635 -332 m 1635 -332 1635 -332 1635 -424 ct 1635 -424 1635 -424 1691 -424 ct
-1691 -424 1691 -424 1691 -332 ct 1691 -332 1691 -332 1744 -332 ct 1744 -332 1744 -332 1744 -286 ct
-1744 -286 1744 -286 1691 -286 ct 1691 -286 1691 -286 1691 -70 ct 1691 -58 1695 -50 1703 -46 ct
-1707 -44 1714 -43 1724 -43 ct 1727 -43 1730 -43 1733 -43 ct 1736 -43 1740 -44 1744 -44 ct
-1744 -44 1744 -44 1744 0 ct 1738 2 1731 3 1724 4 ct 1717 5 1710 5 1702 5 ct 1676 5 1658 -1 1649 -14 ct
-1640 -27 1635 -45 1635 -66 ct 1635 -66 1635 -66 1635 -286 ct 1635 -286 1635 -286 1590 -286 ct
-1590 -286 1590 -286 1590 -332 ct 1590 -332 1590 -332 1635 -332 ct p ef
-pom
-gr
-gr
-[ 51 51 51 51 ] 0 ld
-4500 21000 m 11500 21000 l ps
-[ ] 0 ld
-9250 21000 m 9000 21000 l 9000 20500 l 9500 20500 l 9500 21000 l 9250 21000 l
-pc
-8447 18860 m 8482 18953 l 8517 19046 l 8553 19140 l 8541 19145 l 8528 19150 l
-8516 19154 l 8481 19061 l 8446 18967 l 8410 18873 l 8422 18869 l 8435 18864 l
-8447 18860 l p ef
-4553 20640 m 4518 20547 l 4483 20454 l 4447 20360 l 4459 20355 l 4472 20350 l
-4484 20346 l 4519 20439 l 4554 20533 l 4590 20627 l 4578 20631 l 4565 20636 l
-4553 20640 l p ef
-1 lw 0 lj 8470 19011 m 8421 19030 l ps
-8371 19048 m 8321 19067 l ps
-8272 19086 m 8222 19104 l ps
-8172 19123 m 8122 19142 l ps
-8073 19160 m 8023 19179 l ps
-7973 19198 m 7924 19216 l ps
-7874 19235 m 7824 19253 l ps
-7774 19272 m 7725 19291 l ps
-7675 19309 m 7625 19328 l ps
-7576 19347 m 7526 19365 l ps
-7476 19384 m 7426 19403 l ps
-7377 19421 m 7327 19440 l ps
-7277 19458 m 7228 19477 l ps
-7178 19496 m 7128 19514 l ps
-7079 19533 m 7029 19552 l ps
-6979 19570 m 6929 19589 l ps
-6880 19608 m 6830 19626 l ps
-6780 19645 m 6731 19664 l ps
-6681 19682 m 6631 19701 l ps
-6581 19719 m 6532 19738 l ps
-6482 19757 m 6432 19775 l ps
-6383 19794 m 6333 19813 l ps
-6283 19831 m 6233 19850 l ps
-6184 19869 m 6134 19887 l ps
-6084 19906 m 6035 19925 l ps
-5985 19943 m 5935 19962 l ps
-5885 19980 m 5836 19999 l ps
-5786 20018 m 5736 20036 l ps
-5687 20055 m 5637 20074 l ps
-5587 20092 m 5537 20111 l ps
-5488 20130 m 5438 20148 l ps
-5388 20167 m 5339 20186 l ps
-5289 20204 m 5239 20223 l ps
-5189 20241 m 5140 20260 l ps
-5090 20279 m 5040 20297 l ps
-4991 20316 m 4941 20335 l ps
-4891 20353 m 4842 20372 l ps
-4792 20391 m 4742 20409 l ps
-4692 20428 m 4643 20446 l ps
-4593 20465 m 4543 20484 l ps
-9500 13000 m 9650 13450 l 9350 13450 l 9500 13000 l p ef
-9500 22500 m 9500 13360 l ps
-0.753 0.753 0.753 c 9500 17500 m 10067 17500 10500 17933 10500 18500 ct 10500 19067 10067 19500 9500 19500 ct
-8933 19500 8500 19067 8500 18500 ct 8500 17933 8933 17500 9500 17500 ct p ef
-0 lw 1 lj 0.003 0.003 0.003 c 9500 17500 m 10067 17500 10500 17933 10500 18500 ct
-10500 19067 10067 19500 9500 19500 ct 8933 19500 8500 19067 8500 18500 ct 8500 17933 8933 17500 9500 17500 ct
-pc
-0.648 0.648 0.648 c 9175 18088 m 9235 18088 9282 18135 9282 18195 ct 9282 18255 9235 18302 9175 18302 ct
-9115 18302 9068 18255 9068 18195 ct 9068 18135 9115 18088 9175 18088 ct p ef
-0.003 0.003 0.003 c 9175 18088 m 9235 18088 9282 18135 9282 18195 ct 9282 18255 9235 18302 9175 18302 ct
-9115 18302 9068 18255 9068 18195 ct 9068 18135 9115 18088 9175 18088 ct pc
-0.648 0.648 0.648 c 9823 18088 m 9883 18088 9930 18135 9930 18195 ct 9930 18255 9883 18302 9823 18302 ct
-9763 18302 9716 18255 9716 18195 ct 9716 18135 9763 18088 9823 18088 ct p ef
-0.003 0.003 0.003 c 9823 18088 m 9883 18088 9930 18135 9930 18195 ct 9930 18255 9883 18302 9823 18302 ct
-9763 18302 9716 18255 9716 18195 ct 9716 18135 9763 18088 9823 18088 ct pc
-8951 18936 m 9304 19123 9696 19123 10049 18936 ct ps
-gs
-gs
-pum
-5252 19449 t
-121 -23 m 138 -23 152 -30 164 -45 ct 175 -60 181 -82 181 -111 ct 181 -129 178 -144 173 -157 ct
-164 -182 146 -194 121 -194 ct 95 -194 77 -181 68 -155 ct 63 -141 60 -123 60 -102 ct
-60 -85 63 -70 68 -58 ct 77 -35 95 -23 121 -23 ct p
-24 88 m 24 88 24 88 24 -220 ct 24 -220 24 -220 60 -220 ct 60 -220 60 -220 60 -191 ct
-67 -201 76 -208 84 -214 ct 97 -222 112 -226 129 -226 ct 154 -226 175 -216 193 -197 ct
-210 -178 219 -150 219 -114 ct 219 -66 206 -31 181 -11 ct 165 1 146 8 125 8 ct 108 8 94 4 83 -2 ct
-77 -6 69 -13 61 -23 ct 61 -23 61 -23 61 88 ct 61 88 61 88 24 88 ct p ef
-356 -226 m 372 -226 387 -222 401 -215 ct 416 -208 427 -198 435 -187 ct 442 -176 447 -163 450 -148 ct
-452 -138 453 -121 453 -98 ct 453 -98 453 -98 292 -98 ct 293 -75 298 -57 308 -44 ct
-318 -30 333 -23 354 -23 ct 373 -23 388 -29 400 -42 ct 406 -50 410 -58 413 -68 ct
-413 -68 413 -68 450 -68 ct 449 -60 446 -51 440 -41 ct 435 -31 429 -23 422 -17 ct
-411 -6 397 1 380 5 ct 372 7 361 8 350 8 ct 323 8 300 -1 281 -21 ct 262 -41 252 -69 252 -106 ct
-252 -141 262 -170 281 -193 ct 300 -215 325 -226 356 -226 ct p
-293 -129 m 293 -129 293 -129 415 -129 ct 414 -145 410 -158 405 -167 ct 394 -185 378 -194 354 -194 ct
-337 -194 323 -188 311 -176 ct 300 -163 294 -148 293 -129 ct p
-353 -226 m 353 -226 l p ef
-501 0 m 501 0 501 0 501 -220 ct 501 -220 501 -220 537 -220 ct 537 -220 537 -220 537 -184 ct
-540 -191 547 -200 559 -210 ct 570 -221 584 -226 599 -226 ct 599 -226 601 -226 602 -226 ct
-604 -226 607 -225 611 -225 ct 611 -225 611 -225 611 -187 ct 609 -187 607 -188 605 -188 ct
-603 -188 601 -188 598 -188 ct 579 -188 564 -182 554 -170 ct 543 -158 538 -144 538 -128 ct
-538 -128 538 -128 538 0 ct 538 0 538 0 501 0 ct p ef
-726 -226 m 751 -226 771 -220 787 -208 ct 802 -196 812 -175 815 -146 ct 815 -146 815 -146 779 -146 ct
-777 -160 772 -171 764 -180 ct 756 -189 744 -194 726 -194 ct 703 -194 686 -182 676 -159 ct
-669 -144 666 -126 666 -104 ct 666 -82 671 -63 680 -48 ct 689 -33 704 -25 724 -25 ct
-739 -25 751 -30 760 -39 ct 769 -49 776 -62 779 -78 ct 779 -78 779 -78 815 -78 ct
-811 -49 801 -27 784 -13 ct 768 0 747 6 721 6 ct 692 6 669 -4 652 -25 ct 635 -46 626 -72 626 -103 ct
-626 -142 635 -172 654 -194 ct 673 -215 697 -226 726 -226 ct p
-720 -226 m 720 -226 l p ef
-945 -226 m 961 -226 976 -222 990 -215 ct 1005 -208 1016 -198 1024 -187 ct 1031 -176 1036 -163 1039 -148 ct
-1041 -138 1042 -121 1042 -98 ct 1042 -98 1042 -98 881 -98 ct 882 -75 887 -57 897 -44 ct
-907 -30 922 -23 943 -23 ct 962 -23 977 -29 989 -42 ct 995 -50 999 -58 1002 -68 ct
-1002 -68 1002 -68 1039 -68 ct 1038 -60 1035 -51 1029 -41 ct 1024 -31 1018 -23 1011 -17 ct
-1000 -6 986 1 969 5 ct 961 7 950 8 939 8 ct 912 8 889 -1 870 -21 ct 851 -41 841 -69 841 -106 ct
-841 -141 851 -170 870 -193 ct 889 -215 914 -226 945 -226 ct p
-882 -129 m 882 -129 882 -129 1004 -129 ct 1003 -145 999 -158 994 -167 ct 983 -185 967 -194 943 -194 ct
-926 -194 912 -188 900 -176 ct 889 -163 883 -148 882 -129 ct p
-942 -226 m 942 -226 l p ef
-1184 -23 m 1201 -23 1215 -30 1227 -45 ct 1238 -60 1244 -82 1244 -111 ct 1244 -129 1241 -144 1236 -157 ct
-1227 -182 1209 -194 1184 -194 ct 1158 -194 1140 -181 1131 -155 ct 1126 -141 1123 -123 1123 -102 ct
-1123 -85 1126 -70 1131 -58 ct 1140 -35 1158 -23 1184 -23 ct p
-1087 88 m 1087 88 1087 88 1087 -220 ct 1087 -220 1087 -220 1123 -220 ct 1123 -220 1123 -220 1123 -191 ct
-1130 -201 1139 -208 1147 -214 ct 1160 -222 1175 -226 1192 -226 ct 1217 -226 1238 -216 1256 -197 ct
-1273 -178 1282 -150 1282 -114 ct 1282 -66 1269 -31 1244 -11 ct 1228 1 1209 8 1188 8 ct
-1171 8 1157 4 1146 -2 ct 1140 -6 1132 -13 1124 -23 ct 1124 -23 1124 -23 1124 88 ct
-1124 88 1124 88 1087 88 ct p ef
-1334 -220 m 1334 -220 1334 -220 1334 -281 ct 1334 -281 1334 -281 1371 -281 ct
-1371 -281 1371 -281 1371 -220 ct 1371 -220 1371 -220 1407 -220 ct 1407 -220 1407 -220 1407 -189 ct
-1407 -189 1407 -189 1371 -189 ct 1371 -189 1371 -189 1371 -46 ct 1371 -38 1374 -33 1379 -30 ct
-1382 -29 1387 -28 1394 -28 ct 1396 -28 1398 -28 1400 -28 ct 1402 -28 1404 -29 1407 -29 ct
-1407 -29 1407 -29 1407 0 ct 1403 1 1398 2 1394 3 ct 1389 4 1384 4 1379 4 ct 1361 4 1350 0 1343 -8 ct
-1337 -17 1334 -29 1334 -43 ct 1334 -43 1334 -43 1334 -189 ct 1334 -189 1334 -189 1304 -189 ct
-1304 -189 1304 -189 1304 -220 ct 1304 -220 1304 -220 1334 -220 ct p ef
-1445 0 m 1445 -220 l 1482 -220 l 1482 0 l 1445 0 l p
-1445 -261 m 1445 -303 l 1482 -303 l 1482 -261 l 1445 -261 l p ef
-1626 -23 m 1650 -23 1667 -32 1676 -51 ct 1685 -70 1690 -90 1690 -113 ct 1690 -134 1687 -151 1680 -163 ct
-1670 -184 1652 -194 1626 -194 ct 1603 -194 1587 -185 1576 -168 ct 1566 -151 1561 -130 1561 -105 ct
-1561 -82 1566 -62 1576 -47 ct 1587 -31 1603 -23 1626 -23 ct p
-1627 -226 m 1655 -226 1679 -217 1699 -198 ct 1718 -179 1728 -151 1728 -114 ct
-1728 -78 1719 -49 1702 -26 ct 1685 -3 1658 8 1622 8 ct 1592 8 1568 -1 1550 -22 ct
-1532 -42 1523 -70 1523 -104 ct 1523 -142 1532 -171 1551 -193 ct 1570 -215 1595 -226 1627 -226 ct
-p
-1626 -226 m 1626 -226 l p ef
-1775 0 m 1775 0 1775 0 1775 -220 ct 1775 -220 1775 -220 1811 -220 ct 1811 -220 1811 -220 1811 -190 ct
-1821 -203 1832 -212 1844 -218 ct 1856 -223 1869 -226 1883 -226 ct 1914 -226 1935 -215 1946 -193 ct
-1952 -181 1955 -164 1955 -141 ct 1955 -141 1955 -141 1955 0 ct 1955 0 1955 0 1918 0 ct
-1918 0 1918 0 1918 -139 ct 1918 -153 1916 -164 1912 -172 ct 1905 -186 1893 -193 1876 -193 ct
-1867 -193 1860 -192 1854 -190 ct 1844 -187 1835 -181 1827 -172 ct 1821 -165 1817 -157 1815 -149 ct
-1813 -141 1812 -130 1812 -116 ct 1812 -116 1812 -116 1812 0 ct 1812 0 1812 0 1775 0 ct
-p
-1862 -226 m 1862 -226 l p ef
-pom
-gr
-gr
-0.753 0.753 0.753 c 9500 11000 m 10501 12000 l 9500 13001 l 8500 12000 l
-9500 11000 l 9500 11000 l p ef
-0.003 0.003 0.003 c 9500 11000 m 10501 12000 l 9500 13001 l 8500 12000 l
-9500 11000 l 9500 11000 l pc
-0 11726 t
-pom
-count op_count sub {pop} repeat countdictstack dict_count sub {end} repeat b4_inc_state restore
-%%PageTrailer
-%%Trailer
-%%EOF
Added: trunk/applications/jason-team/doc/roles/figures/jason-team-SS.dia
===================================================================
(Binary files differ)
Property changes on: trunk/applications/jason-team/doc/roles/figures/jason-team-SS.dia
___________________________________________________________________
Name: svn:executable
+ *
Name: svn:mime-type
+ application/octet-stream
Deleted: trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps
===================================================================
--- trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps 2008-04-25 20:05:54 UTC (rev 1261)
+++ trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps 2008-04-26 08:07:38 UTC (rev 1262)
@@ -1,6442 +0,0 @@
-%!PS-Adobe-2.0 EPSF-2.0
-%%Title: /media/JOMI/pubs/2008/agent-contest/proposal/figures/jason-team-SS.dia
-%%Creator: Dia v0.96.1
-%%CreationDate: Fri Mar 7 10:36:35 2008
-%%For: hubner
-%%Orientation: Portrait
-%%Magnification: 1.0000
-%%BoundingBox: 0 0 960 912
-%%BeginSetup
-%%EndSetup
-%%EndComments
-%%BeginProlog
-[ /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/.notdef /.notdef /space /exclam /quotedbl /numbersign /dollar /percent /ampersand /quoteright
-/parenleft /parenright /asterisk /plus /comma /hyphen /period /slash /zero /one
-/two /three /four /five /six /seven /eight /nine /colon /semicolon
-/less /equal /greater /question /at /A /B /C /D /E
-/F /G /H /I /J /K /L /M /N /O
-/P /Q /R /S /T /U /V /W /X /Y
-/Z /bracketleft /backslash /bracketright /asciicircum /underscore /quoteleft /a /b /c
-/d /e /f /g /h /i /j /k /l /m
-/n /o /p /q /r /s /t /u /v /w
-/x /y /z /braceleft /bar /braceright /asciitilde /.notdef /.notdef /.notdef
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
-/space /exclamdown /cent /sterling /currency /yen /brokenbar /section /dieresis /copyright
-/ordfeminine /guillemotleft /logicalnot /hyphen /registered /macron /degree /plusminus /twosuperior /threesuperior
-/acute /mu /paragraph /periodcentered /cedilla /onesuperior /ordmasculine /guillemotright /onequarter /onehalf
-/threequarters /questiondown /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla
-/Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis /Eth /Ntilde
-/Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply /Oslash /Ugrave /Uacute /Ucircumflex
-/Udieresis /Yacute /Thorn /germandbls /agrave /aacute /acircumflex /atilde /adieresis /aring
-/ae /ccedilla /egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis
-/eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide /oslash /ugrave
-/uacute /ucircumflex /udieresis /yacute /thorn /ydieresis] /isolatin1encoding exch def
-/cp {closepath} bind def
-/c {curveto} bind def
-/f {fill} bind def
-/a {arc} bind def
-/ef {eofill} bind def
-/ex {exch} bind def
-/gr {grestore} bind def
-/gs {gsave} bind def
-/sa {save} bind def
-/rs {restore} bind def
-/l {lineto} bind def
-/m {moveto} bind def
-/rm {rmoveto} bind def
-/n {newpath} bind def
-/s {stroke} bind def
-/sh {show} bind def
-/slc {setlinecap} bind def
-/slj {setlinejoin} bind def
-/slw {setlinewidth} bind def
-/srgb {setrgbcolor} bind def
-/rot {rotate} bind def
-/sc {scale} bind def
-/sd {setdash} bind def
-/ff {findfont} bind def
-/sf {setfont} bind def
-/scf {scalefont} bind def
-/sw {stringwidth pop} bind def
-/tr {translate} bind def
-
-/ellipsedict 8 dict def
-ellipsedict /mtrx matrix put
-/ellipse
-{ ellipsedict begin
- /endangle exch def
- /startangle exch def
- /yrad exch def
- /xrad exch def
- /y exch def
- /x exch def /savematrix mtrx currentmatrix def
- x y tr xrad yrad sc
- 0 0 1 startangle endangle arc
- savematrix setmatrix
- end
-} def
-
-/mergeprocs {
-dup length
-3 -1 roll
-dup
-length
-dup
-5 1 roll
-3 -1 roll
-add
-array cvx
-dup
-3 -1 roll
-0 exch
-putinterval
-dup
-4 2 roll
-putinterval
-} bind def
-/dpi_x 300 def
-/dpi_y 300 def
-/conicto {
- /to_y exch def
- /to_x exch def
- /conic_cntrl_y exch def
- /conic_cntrl_x exch def
- currentpoint
- /p0_y exch def
- /p0_x exch def
- /p1_x p0_x conic_cntrl_x p0_x sub 2 3 div mul add def
- /p1_y p0_y conic_cntrl_y p0_y sub 2 3 div mul add def
- /p2_x p1_x to_x p0_x sub 1 3 div mul add def
- /p2_y p1_y to_y p0_y sub 1 3 div mul add def
- p1_x p1_y p2_x p2_y to_x to_y curveto
-} bind def
-/start_ol { gsave 1.1 dpi_x div dup scale} bind def
-/end_ol { closepath fill grestore } bind def
-28.346000 -28.346000 scale
--5.910861 -38.117440 translate
-%%EndProlog
-
-
-0.100000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-0 slj
-0.100000 slw
-0 slc
-0 slj
-[] 0 sd
-1.000000 1.000000 1.000000 srgb
-n 15.565527 15.450000 m 19.827633 15.450000 l 20.416108 15.450000 20.893160 15.899306 20.893160 16.453553 c 20.893160 17.007801 20.416108 17.457107 19.827633 17.457107 c 15.565527 17.457107 l 14.977052 17.457107 14.500000 17.007801 14.500000 16.453553 c 14.500000 15.899306 14.977052 15.450000 15.565527 15.450000 c ef
-0.000000 0.000000 0.000000 srgb
-n 15.565527 15.450000 m 19.827633 15.450000 l 20.416108 15.450000 20.893160 15.899306 20.893160 16.453553 c 20.893160 17.007801 20.416108 17.457107 19.827633 17.457107 c 15.565527 17.457107 l 14.977052 17.457107 14.500000 17.007801 14.500000 16.453553 c 14.500000 15.899306 14.977052 15.450000 15.565527 15.450000 c s
-gsave 15.969080 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-3392 384 moveto
-2820 -64 2078 -64 conicto
-1241 -64 748 410 conicto
-256 884 256 1670 conicto
-256 2444 699 2918 conicto
-1142 3392 1870 3392 conicto
-2541 3392 2966 2928 conicto
-3392 2465 3392 1632 conicto
-3392 1408 lineto
-1152 1408 lineto
-1200 1106 1461 905 conicto
-1722 704 2085 704 conicto
-2659 704 3232 1024 conicto
-3392 384 lineto
-2496 2048 moveto
-2459 2371 2281 2561 conicto
-2104 2752 1846 2752 conicto
-1575 2752 1382 2561 conicto
-1189 2371 1152 2048 conicto
-2496 2048 lineto
-end_ol grestore
-gsave 16.456120 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-3536 0 moveto
-2536 0 lineto
-1771 1051 lineto
-1013 0 lineto
-48 0 lineto
-1284 1718 lineto
-112 3328 lineto
-1112 3328 lineto
-1781 2410 lineto
-2442 3328 lineto
-3408 3328 lineto
-2267 1742 lineto
-3536 0 lineto
-end_ol grestore
-gsave 16.943160 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-1344 2959 moveto
-1505 3150 1781 3271 conicto
-2057 3392 2347 3392 conicto
-2973 3392 3374 2937 conicto
-3776 2482 3776 1730 conicto
-3776 900 3374 418 conicto
-2973 -64 2347 -64 conicto
-1715 -64 1344 340 conicto
-1344 -1344 lineto
-448 -1344 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 2959 lineto
-1344 1087 moveto
-1656 704 2133 704 conicto
-2459 704 2669 966 conicto
-2880 1229 2880 1678 conicto
-2880 2139 2666 2381 conicto
-2452 2624 2124 2624 conicto
-1679 2624 1344 2216 conicto
-1344 1087 lineto
-end_ol grestore
-gsave 17.477660 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-1344 0 moveto
-448 0 lineto
-448 4800 lineto
-1344 4800 lineto
-1344 0 lineto
-end_ol grestore
-gsave 17.719927 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-2013 3392 moveto
-2806 3392 3291 2934 conicto
-3776 2476 3776 1664 conicto
-3776 852 3291 394 conicto
-2806 -64 2013 -64 conicto
-1220 -64 738 394 conicto
-256 852 256 1664 conicto
-256 2479 738 2935 conicto
-1220 3392 2013 3392 conicto
-2013 704 moveto
-2407 704 2643 965 conicto
-2880 1226 2880 1664 conicto
-2880 2105 2646 2364 conicto
-2413 2624 2013 2624 conicto
-1599 2624 1375 2372 conicto
-1152 2121 1152 1664 conicto
-1152 1219 1377 961 conicto
-1602 704 2013 704 conicto
-end_ol grestore
-gsave 18.254427 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-2624 3264 moveto
-2464 2496 lineto
-2324 2560 2171 2560 conicto
-1997 2560 1837 2458 conicto
-1677 2357 1510 2106 conicto
-1344 1856 1344 1810 conicto
-1344 0 lineto
-448 0 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 2688 lineto
-1529 3075 1724 3233 conicto
-1920 3392 2197 3392 conicto
-2452 3392 2624 3264 conicto
-end_ol grestore
-gsave 18.594102 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-3392 384 moveto
-2820 -64 2078 -64 conicto
-1241 -64 748 410 conicto
-256 884 256 1670 conicto
-256 2444 699 2918 conicto
-1142 3392 1870 3392 conicto
-2541 3392 2966 2928 conicto
-3392 2465 3392 1632 conicto
-3392 1408 lineto
-1152 1408 lineto
-1200 1106 1461 905 conicto
-1722 704 2085 704 conicto
-2659 704 3232 1024 conicto
-3392 384 lineto
-2496 2048 moveto
-2459 2371 2281 2561 conicto
-2104 2752 1846 2752 conicto
-1575 2752 1382 2561 conicto
-1189 2371 1152 2048 conicto
-2496 2048 lineto
-end_ol grestore
-gsave 19.081142 16.646053 translate 0.035278 -0.035278 scale
-start_ol
-2624 3264 moveto
-2464 2496 lineto
-2324 2560 2171 2560 conicto
-1997 2560 1837 2458 conicto
-1677 2357 1510 2106 conicto
-1344 1856 1344 1810 conicto
-1344 0 lineto
-448 0 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 2688 lineto
-1529 3075 1724 3233 conicto
-1920 3392 2197 3392 conicto
-2452 3392 2624 3264 conicto
-end_ol grestore
-0.100000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-n 13.774800 18.765100 m 13.776400 18.765100 l s
-0.100000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-0 slj
-0.100000 slw
-0 slc
-0 slj
-[] 0 sd
-1.000000 1.000000 1.000000 srgb
-n 23.946777 20.450000 m 27.333883 20.450000 l 27.801546 20.450000 28.180660 20.899306 28.180660 21.453553 c 28.180660 22.007801 27.801546 22.457107 27.333883 22.457107 c 23.946777 22.457107 l 23.479115 22.457107 23.100000 22.007801 23.100000 21.453553 c 23.100000 20.899306 23.479115 20.450000 23.946777 20.450000 c ef
-0.000000 0.000000 0.000000 srgb
-n 23.946777 20.450000 m 27.333883 20.450000 l 27.801546 20.450000 28.180660 20.899306 28.180660 21.453553 c 28.180660 22.007801 27.801546 22.457107 27.333883 22.457107 c 23.946777 22.457107 l 23.479115 22.457107 23.100000 22.007801 23.100000 21.453553 c 23.100000 20.899306 23.479115 20.450000 23.946777 20.450000 c s
-gsave 24.350330 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-2022 4800 moveto
-1003 0 lineto
-112 0 lineto
-1131 4800 lineto
-2022 4800 lineto
-end_ol grestore
-gsave 24.592597 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-3136 320 moveto
-2492 -64 1767 -64 conicto
-1095 -64 675 318 conicto
-256 700 256 1317 conicto
-256 2160 826 2776 conicto
-1396 3392 2206 3392 conicto
-2799 3392 3159 3055 conicto
-3520 2718 3520 2142 conicto
-3520 1994 3442 1472 conicto
-1216 1472 lineto
-1216 1076 1377 890 conicto
-1539 704 1883 704 conicto
-2366 704 2976 1024 conicto
-3136 320 lineto
-2688 2112 moveto
-2694 2166 2694 2194 conicto
-2694 2448 2561 2600 conicto
-2428 2752 2186 2752 conicto
-1916 2752 1685 2578 conicto
-1454 2405 1349 2112 conicto
-2688 2112 lineto
-end_ol grestore
-gsave 25.079638 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-704 3072 moveto
-994 3214 1360 3303 conicto
-1727 3392 2014 3392 conicto
-2700 3392 3021 3177 conicto
-3342 2962 3342 2511 conicto
-3342 2350 3313 2208 conicto
-3036 767 3014 631 conicto
-2992 496 2992 337 conicto
-2992 143 3072 0 conicto
-2163 0 lineto
-2098 119 2098 303 conicto
-2104 422 lineto
-1674 -64 1080 -64 conicto
-640 -64 384 190 conicto
-128 444 128 861 conicto
-128 1381 585 1683 conicto
-1042 1986 2417 2048 conicto
-2433 2109 lineto
-2465 2199 2465 2350 conicto
-2465 2505 2331 2596 conicto
-2198 2688 1950 2688 conicto
-1487 2688 864 2368 conicto
-704 3072 lineto
-2314 1536 moveto
-1525 1480 1242 1334 conicto
-960 1189 960 910 conicto
-960 793 1049 716 conicto
-1139 640 1261 640 conicto
-1581 640 1896 867 conicto
-2211 1094 2224 1155 conicto
-2314 1536 lineto
-end_ol grestore
-gsave 25.566678 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-4276 4864 moveto
-3243 0 lineto
-2352 0 lineto
-2424 340 lineto
-2256 170 1980 53 conicto
-1705 -64 1464 -64 conicto
-893 -64 574 282 conicto
-256 628 256 1263 conicto
-256 2132 785 2762 conicto
-1315 3392 2085 3392 conicto
-2698 3392 2986 2985 conicto
-3385 4864 lineto
-4276 4864 lineto
-2827 2241 moveto
-2611 2624 2163 2624 conicto
-1772 2624 1494 2237 conicto
-1216 1850 1216 1309 conicto
-1216 1011 1354 857 conicto
-1492 704 1716 704 conicto
-2179 704 2589 1113 conicto
-2827 2241 lineto
-end_ol grestore
-gsave 26.101177 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-3136 320 moveto
-2492 -64 1767 -64 conicto
-1095 -64 675 318 conicto
-256 700 256 1317 conicto
-256 2160 826 2776 conicto
-1396 3392 2206 3392 conicto
-2799 3392 3159 3055 conicto
-3520 2718 3520 2142 conicto
-3520 1994 3442 1472 conicto
-1216 1472 lineto
-1216 1076 1377 890 conicto
-1539 704 1883 704 conicto
-2366 704 2976 1024 conicto
-3136 320 lineto
-2688 2112 moveto
-2694 2166 2694 2194 conicto
-2694 2448 2561 2600 conicto
-2428 2752 2186 2752 conicto
-1916 2752 1685 2578 conicto
-1454 2405 1349 2112 conicto
-2688 2112 lineto
-end_ol grestore
-gsave 26.588217 21.646053 translate 0.035278 -0.035278 scale
-start_ol
-3008 3267 moveto
-2656 2496 lineto
-2542 2560 2381 2560 conicto
-2056 2560 1671 2148 conicto
-1397 1838 1343 1600 conicto
-1003 0 lineto
-112 0 lineto
-818 3328 lineto
-1709 3328 lineto
-1569 2666 lineto
-1843 3062 2081 3227 conicto
-2319 3392 2606 3392 conicto
-2866 3392 3008 3267 conicto
-end_ol grestore
-0.100000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-0 slj
-0.100000 slw
-0 slc
-0 slj
-[] 0 sd
-1.000000 1.000000 1.000000 srgb
-n 19.824752 11.746000 m 24.329358 11.746000 l 24.951315 11.746000 25.455510 12.195306 25.455510 12.749553 c 25.455510 13.303801 24.951315 13.753107 24.329358 13.753107 c 19.824752 13.753107 l 19.202795 13.753107 18.698600 13.303801 18.698600 12.749553 c 18.698600 12.195306 19.202795 11.746000 19.824752 11.746000 c ef
-0.000000 0.000000 0.000000 srgb
-n 19.824752 11.746000 m 24.329358 11.746000 l 24.951315 11.746000 25.455510 12.195306 25.455510 12.749553 c 25.455510 13.303801 24.951315 13.753107 24.329358 13.753107 c 19.824752 13.753107 l 19.202795 13.753107 18.698600 13.303801 18.698600 12.749553 c 18.698600 12.195306 19.202795 11.746000 19.824752 11.746000 c s
-gsave 20.228305 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3584 117 moveto
-3584 -618 3122 -1013 conicto
-2661 -1408 1819 -1408 conicto
-1066 -1408 448 -960 conicto
-672 -320 lineto
-1237 -640 1796 -640 conicto
-2223 -640 2455 -448 conicto
-2688 -257 2688 101 conicto
-2688 320 lineto
-2291 -64 1690 -64 conicto
-1060 -64 658 392 conicto
-256 849 256 1626 conicto
-256 2444 661 2918 conicto
-1067 3392 1732 3392 conicto
-2000 3392 2261 3287 conicto
-2523 3183 2688 3008 conicto
-2688 3392 lineto
-3584 3392 lineto
-3584 117 lineto
-2688 1088 moveto
-2688 2240 lineto
-2372 2624 1907 2624 conicto
-1577 2624 1364 2362 conicto
-1152 2101 1152 1649 conicto
-1152 1202 1359 953 conicto
-1567 704 1907 704 conicto
-2358 704 2688 1088 conicto
-end_ol grestore
-gsave 20.762805 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3584 0 moveto
-2688 0 lineto
-2688 466 lineto
-2266 -64 1600 -64 conicto
-1071 -64 759 244 conicto
-448 553 448 1103 conicto
-448 3328 lineto
-1344 3328 lineto
-1344 1400 lineto
-1344 704 1861 704 conicto
-2324 704 2688 1216 conicto
-2688 3328 lineto
-3584 3328 lineto
-3584 0 lineto
-end_ol grestore
-gsave 21.297304 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3344 0 moveto
-2448 0 lineto
-2304 210 2304 384 conicto
-1860 -64 1237 -64 conicto
-780 -64 518 208 conicto
-256 480 256 928 conicto
-256 1254 429 1496 conicto
-603 1738 945 1885 conicto
-1288 2032 1766 2070 conicto
-2304 2112 lineto
-2304 2174 lineto
-2304 2752 1680 2752 conicto
-1488 2752 1171 2676 conicto
-854 2601 608 2496 conicto
-384 3136 lineto
-697 3247 1105 3319 conicto
-1514 3392 1831 3392 conicto
-2502 3392 2851 3071 conicto
-3200 2750 3200 2130 conicto
-3200 788 lineto
-3200 321 3344 0 conicto
-2304 1024 moveto
-2304 1600 lineto
-1763 1540 1634 1516 conicto
-1505 1493 1365 1412 conicto
-1225 1331 1156 1212 conicto
-1088 1093 1088 942 conicto
-1088 788 1186 682 conicto
-1284 576 1452 576 conicto
-1921 576 2304 1024 conicto
-end_ol grestore
-gsave 21.784344 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-2624 3264 moveto
-2464 2496 lineto
-2324 2560 2171 2560 conicto
-1997 2560 1837 2458 conicto
-1677 2357 1510 2106 conicto
-1344 1856 1344 1810 conicto
-1344 0 lineto
-448 0 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 2688 lineto
-1529 3075 1724 3233 conicto
-1920 3392 2197 3392 conicto
-2452 3392 2624 3264 conicto
-end_ol grestore
-gsave 22.124020 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3584 0 moveto
-2688 0 lineto
-2688 347 lineto
-2284 -64 1684 -64 conicto
-1057 -64 656 391 conicto
-256 846 256 1601 conicto
-256 2428 656 2910 conicto
-1057 3392 1684 3392 conicto
-2317 3392 2688 2988 conicto
-2688 4800 lineto
-3584 4800 lineto
-3584 0 lineto
-2688 1113 moveto
-2688 2244 lineto
-2375 2624 1900 2624 conicto
-1574 2624 1363 2362 conicto
-1152 2101 1152 1649 conicto
-1152 1202 1359 953 conicto
-1567 704 1907 704 conicto
-2352 704 2688 1113 conicto
-end_ol grestore
-gsave 22.658520 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-894 4864 moveto
-1100 4864 1254 4712 conicto
-1408 4560 1408 4347 conicto
-1408 4141 1256 3990 conicto
-1104 3840 894 3840 conicto
-682 3840 533 3989 conicto
-384 4138 384 4347 conicto
-384 4563 533 4713 conicto
-682 4864 894 4864 conicto
-1344 0 moveto
-448 0 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 0 lineto
-end_ol grestore
-gsave 22.900787 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3344 0 moveto
-2448 0 lineto
-2304 210 2304 384 conicto
-1860 -64 1237 -64 conicto
-780 -64 518 208 conicto
-256 480 256 928 conicto
-256 1254 429 1496 conicto
-603 1738 945 1885 conicto
-1288 2032 1766 2070 conicto
-2304 2112 lineto
-2304 2174 lineto
-2304 2752 1680 2752 conicto
-1488 2752 1171 2676 conicto
-854 2601 608 2496 conicto
-384 3136 lineto
-697 3247 1105 3319 conicto
-1514 3392 1831 3392 conicto
-2502 3392 2851 3071 conicto
-3200 2750 3200 2130 conicto
-3200 788 lineto
-3200 321 3344 0 conicto
-2304 1024 moveto
-2304 1600 lineto
-1763 1540 1634 1516 conicto
-1505 1493 1365 1412 conicto
-1225 1331 1156 1212 conicto
-1088 1093 1088 942 conicto
-1088 788 1186 682 conicto
-1284 576 1452 576 conicto
-1921 576 2304 1024 conicto
-end_ol grestore
-gsave 23.387827 12.942053 translate 0.035278 -0.035278 scale
-start_ol
-3584 0 moveto
-2688 0 lineto
-2688 1926 lineto
-2688 2624 2169 2624 conicto
-1708 2624 1344 2135 conicto
-1344 0 lineto
-448 0 lineto
-448 3328 lineto
-1344 3328 lineto
-1344 2880 lineto
-1766 3392 2435 3392 conicto
-2961 3392 3272 3085 conicto
-3584 2778 3584 2225 conicto
-3584 0 lineto
-end_ol grestore
-0.100000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-0 slj
-0.100000 slw
-0 slc
-0 slj
-[] 0 sd
-1.000000 1.000000 1.000000 srgb
-n 20.840527 25.725000 m 24.907633 25.725000 l 25.469184 25.725000 25.924410 26.174306 25.924410 26.728553 c 25.924410 27.282801 25.469184 27.732107 24.907633 27.732107 c 20.840527 27.732107 l 20.278976 27.732107 19.823750 27.282801 19.823750 26.728553 c 19.823750 26.174306 20.278976 25.725000 20.840527 25.725000 c ef
-0.000000 0.000000 0.000000 srgb
-n 20.840527 25.725000 m 24.907633 25.725000 l 25.469184 25.725000 25.924410 26.174306 25.924410 26.728553 c 25.924410 27.282801 25.469184 27.732107 24.907633 27.732107 c 20.840527 27.732107 l 20.278976 27.732107 19.823750 27.282801 19.823750 26.728553 c 19.823750 26.174306 20.278976 25.725000 20.840527 25.725000 c s
-gsave 21.244080 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-3648 3008 moveto
-3240 2304 lineto
-2753 2624 2276 2624 conicto
-1858 2624 1537 2256 conicto
-1216 1888 1216 1383 conicto
-1216 1008 1404 856 conicto
-1593 704 1853 704 conicto
-2393 704 2976 1024 conicto
-3136 320 lineto
-2514 -64 1779 -64 conicto
-1082 -64 669 315 conicto
-256 694 256 1304 conicto
-256 2201 828 2796 conicto
-1401 3392 2309 3392 conicto
-3039 3392 3648 3008 conicto
-end_ol grestore
-gsave 21.731120 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-2290 3392 moveto
-3018 3392 3461 3021 conicto
-3904 2650 3904 2008 conicto
-3904 1061 3299 498 conicto
-2694 -64 1799 -64 conicto
-1094 -64 675 304 conicto
-256 672 256 1323 conicto
-256 2214 856 2803 conicto
-1456 3392 2290 3392 conicto
-1835 704 moveto
-2316 704 2630 1090 conicto
-2944 1476 2944 1967 conicto
-2944 2275 2764 2449 conicto
-2584 2624 2265 2624 conicto
-1825 2624 1520 2233 conicto
-1216 1843 1216 1361 conicto
-1216 1059 1386 881 conicto
-1557 704 1835 704 conicto
-end_ol grestore
-gsave 22.265620 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-5504 3328 moveto
-3669 0 lineto
-2949 0 lineto
-2688 2189 lineto
-1484 0 lineto
-749 0 lineto
-448 3354 lineto
-1360 3354 lineto
-1472 1291 lineto
-2606 3354 lineto
-3336 3354 lineto
-3584 1278 lineto
-4558 3354 lineto
-5504 3328 lineto
-end_ol grestore
-gsave 22.944979 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-1635 2985 moveto
-1811 3157 2099 3274 conicto
-2388 3392 2640 3392 conicto
-3237 3392 3570 3047 conicto
-3904 2703 3904 2065 conicto
-3904 1200 3355 568 conicto
-2807 -64 2008 -64 conicto
-1373 -64 1075 340 conicto
-1003 0 lineto
-112 0 lineto
-1145 4864 lineto
-2033 4864 lineto
-1635 2985 lineto
-1233 1087 moveto
-1462 704 1936 704 conicto
-2352 704 2648 1089 conicto
-2944 1475 2944 2019 conicto
-2944 2305 2798 2464 conicto
-2652 2624 2406 2624 conicto
-1911 2624 1472 2216 conicto
-1233 1087 lineto
-end_ol grestore
-gsave 23.479479 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-2290 3392 moveto
-3018 3392 3461 3021 conicto
-3904 2650 3904 2008 conicto
-3904 1061 3299 498 conicto
-2694 -64 1799 -64 conicto
-1094 -64 675 304 conicto
-256 672 256 1323 conicto
-256 2214 856 2803 conicto
-1456 3392 2290 3392 conicto
-1835 704 moveto
-2316 704 2630 1090 conicto
-2944 1476 2944 1967 conicto
-2944 2275 2764 2449 conicto
-2584 2624 2265 2624 conicto
-1825 2624 1520 2233 conicto
-1216 1843 1216 1361 conicto
-1216 1059 1386 881 conicto
-1557 704 1835 704 conicto
-end_ol grestore
-gsave 24.013978 26.921053 translate 0.035278 -0.035278 scale
-start_ol
-4032 3328 moveto
-1982 -64 lineto
-1564 -756 1160 -1082 conicto
-757 -1408 129 -1408 conicto
--291 -1408 -640 -1280 conicto
--352 -576 lineto
--95 -640 94 -640 conicto
-407 -640 602 -495 conicto
-798 -351 993 -10 conicto
-448 3328 lineto
-1377 3328 lineto
-1664 896 lineto
-3091 3328 lineto
-4032 3328 lineto
-end_ol grestore
-0.050000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-n 15.339386 8.877265 m 18.607242 8.279157 l s
-[] 0 sd
-0 slj
-0 slc
-1.000000 1.000000 1.000000 srgb
-n 19.718078 8.075843 m 19.181893 8.478963 l 18.537686 8.291887 l 19.073871 7.888767 l ef
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-0.000000 0.000000 0.000000 srgb
-n 19.718078 8.075843 m 19.181893 8.478963 l 18.537686 8.291887 l 19.073871 7.888767 l cp s
-0.050000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-n 29.781873 9.402666 m 25.441673 8.423379 l s
-[] 0 sd
-0 slj
-0 slc
-1.000000 1.000000 1.000000 srgb
-n 24.340077 8.174823 m 24.991393 8.014239 l 25.510650 8.438942 l 24.859333 8.599526 l ef
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-0.000000 0.000000 0.000000 srgb
-n 24.340077 8.174823 m 24.991393 8.014239 l 25.510650 8.438942 l 24.859333 8.599526 l cp s
-gsave 15.765400 8.161700 translate 0.035278 -0.035278 scale
-start_ol
-1582 3008 moveto
-1888 3008 2064 2745 conicto
-2240 2483 2240 1998 conicto
-2240 1523 2050 1027 conicto
-1861 532 1559 234 conicto
-1258 -64 941 -64 conicto
-256 -64 256 922 conicto
-256 1384 445 1891 conicto
-635 2399 940 2703 conicto
-1245 3008 1582 3008 conicto
-960 64 moveto
-1190 64 1392 457 conicto
-1595 851 1725 1474 conicto
-1856 2098 1856 2405 conicto
-1856 2880 1544 2880 conicto
-1300 2880 1094 2466 conicto
-888 2053 764 1405 conicto
-640 758 640 488 conicto
-640 64 960 64 conicto
-end_ol grestore
-gsave 16.057624 8.161700 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 16.202483 8.161700 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 16.347343 8.161700 translate 0.035278 -0.035278 scale
-start_ol
-1499 2113 moveto
-1552 2070 1793 2023 conicto
-2080 1970 2160 1906 conicto
-2240 1842 2240 1754 conicto
-2240 1690 2191 1645 conicto
-2142 1600 2077 1600 conicto
-2009 1600 1928 1641 conicto
-1848 1683 1692 1837 conicto
-1527 2002 1450 2034 conicto
-1450 1918 1532 1700 conicto
-1600 1520 1600 1444 conicto
-1600 1345 1548 1280 conicto
-1497 1216 1408 1216 conicto
-1319 1216 1267 1280 conicto
-1216 1345 1216 1444 conicto
-1216 1520 1282 1700 conicto
-1364 1918 1364 2034 conicto
-1287 2002 1122 1837 conicto
-966 1683 886 1641 conicto
-807 1600 739 1600 conicto
-672 1600 624 1645 conicto
-576 1690 576 1754 conicto
-576 1842 656 1906 conicto
-736 1970 1023 2023 conicto
-1264 2070 1317 2113 conicto
-1264 2154 1023 2201 conicto
-736 2254 656 2318 conicto
-576 2382 576 2470 conicto
-576 2536 625 2580 conicto
-675 2624 739 2624 conicto
-807 2624 886 2583 conicto
-966 2543 1122 2387 conicto
-1287 2222 1364 2190 conicto
-1364 2306 1282 2526 conicto
-1216 2704 1216 2780 conicto
-1216 2879 1267 2943 conicto
-1319 3008 1408 3008 conicto
-1497 3008 1548 2943 conicto
-1600 2879 1600 2780 conicto
-1600 2704 1532 2526 conicto
-1450 2306 1450 2190 conicto
-1527 2222 1692 2387 conicto
-1848 2543 1928 2583 conicto
-2009 2624 2077 2624 conicto
-2142 2624 2191 2579 conicto
-2240 2534 2240 2470 conicto
-2240 2382 2160 2318 conicto
-2080 2254 1793 2201 conicto
-1552 2154 1499 2113 conicto
-end_ol grestore
-gsave 22.625000 8.550000 translate 0.035278 -0.035278 scale
-start_ol
-1582 3008 moveto
-1888 3008 2064 2745 conicto
-2240 2483 2240 1998 conicto
-2240 1523 2050 1027 conicto
-1861 532 1559 234 conicto
-1258 -64 941 -64 conicto
-256 -64 256 922 conicto
-256 1384 445 1891 conicto
-635 2399 940 2703 conicto
-1245 3008 1582 3008 conicto
-960 64 moveto
-1190 64 1392 457 conicto
-1595 851 1725 1474 conicto
-1856 2098 1856 2405 conicto
-1856 2880 1544 2880 conicto
-1300 2880 1094 2466 conicto
-888 2053 764 1405 conicto
-640 758 640 488 conicto
-640 64 960 64 conicto
-end_ol grestore
-gsave 22.917224 8.550000 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 23.062083 8.550000 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 23.206943 8.550000 translate 0.035278 -0.035278 scale
-start_ol
-1879 3008 moveto
-1206 650 lineto
-1122 348 1122 296 conicto
-1122 216 1180 172 conicto
-1238 128 1458 128 conicto
-1432 0 lineto
-227 0 lineto
-253 128 lineto
-433 128 520 154 conicto
-608 181 669 272 conicto
-731 364 790 568 conicto
-1316 2414 lineto
-1333 2480 1333 2520 conicto
-1333 2580 1290 2602 conicto
-1248 2624 1142 2624 conicto
-846 2624 lineto
-878 2752 lineto
-1128 2752 1334 2805 conicto
-1540 2858 1793 3008 conicto
-1879 3008 lineto
-end_ol grestore
-gsave 35.250000 10.750000 translate 0.035278 -0.035278 scale
-start_ol
-1879 3008 moveto
-1206 650 lineto
-1122 348 1122 296 conicto
-1122 216 1180 172 conicto
-1238 128 1458 128 conicto
-1432 0 lineto
-227 0 lineto
-253 128 lineto
-433 128 520 154 conicto
-608 181 669 272 conicto
-731 364 790 568 conicto
-1316 2414 lineto
-1333 2480 1333 2520 conicto
-1333 2580 1290 2602 conicto
-1248 2624 1142 2624 conicto
-846 2624 lineto
-878 2752 lineto
-1128 2752 1334 2805 conicto
-1540 2858 1793 3008 conicto
-1879 3008 lineto
-end_ol grestore
-gsave 35.542224 10.750000 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 35.687083 10.750000 translate 0.035278 -0.035278 scale
-start_ol
-352 384 moveto
-445 384 510 319 conicto
-576 254 576 161 conicto
-576 68 510 2 conicto
-445 -64 352 -64 conicto
-259 -64 193 2 conicto
-128 68 128 161 conicto
-128 254 193 319 conicto
-259 384 352 384 conicto
-end_ol grestore
-gsave 35.831943 10.750000 translate 0.035278 -0.035278 scale
-start_ol
-512 2336 moveto
-661 2647 915 2827 conicto
-1169 3008 1471 3008 conicto
-1775 3008 1975 2809 conicto
-2176 2611 2176 2325 conicto
-2176 1860 1659 1388 conicto
-493 320 lineto
-1309 320 lineto
-1541 320 1635 408 conicto
-1730 497 1792 704 conicto
-1920 704 lineto
-1713 0 lineto
-64 0 lineto
-64 80 lineto
-1069 1002 lineto
-1361 1269 1510 1468 conicto
-1660 1668 1726 1838 conicto
-1792 2009 1792 2172 conicto
-1792 2395 1652 2541 conicto
-1512 2688 1272 2688 conicto
-861 2688 608 2304 conicto
-512 2336 lineto
-end_ol grestore
-0.050000 slw
-[] 0 sd
-[] 0 sd
-0 slj
-0 slc
-n 25.626596 26.018941 m 27.896641 24.628125 28.246641 27.278125 25.924410 26.728553 c s
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-n 25.924410 26.728553 m 25.950318 26.619077 26.110031 26.541267 26.243835 26.572933 c 26.377639 26.604598 26.485535 26.745740 26.459627 26.855216 c 26.433718 26.964692 26.274006 27.042502 26.140202 27.010837 c 26.006398 26.979171 25.898502 26.838029 25.924410 26.728553 c ef
-0.050000 slw
-[] 0 sd
-[] 0 sd
-0 slc
-n 22.066876 11.696295 m 22.050071 9.957532 l s
-[] 0 sd
-0 slj
-0 slc
-1.000000 1.000000 1.000000 srgb
-n 22.039158 8.828295 m 22.344942 9.425368 l 22.050755 10.028239 l 21.744970 9.431167 l ef
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-0.000000 0.000000 0.000000 srgb
-n 22.039158 8.828295 m 22.344942 9.425368 l 22.050755 10.028239 l 21.744970 9.431167 l cp s
-0.050000 slw
-[] 0 sd
-[] 0 sd
-0 slj
-0 slc
-n 25.640316 22.506205 m 25.640300 23.706250 l 22.874080 23.706250 l 22.874080 24.657685 l s
-0 slj
-1.000000 1.000000 1.000000 srgb
-n 22.474080 24.657685 m 22.874080 25.657685 l 23.274080 24.657685 l ef
-0.050000 slw
-[] 0 sd
-0 slj
-0.000000 0.000000 0.000000 srgb
-n 22.474080 24.657685 m 22.874080 25.657685 l 23.274080 24.657685 l cp s
-0.050000 slw
-[1.000000 0.200000 0.200000 0.200000 0.200000 0.200000] 0 sd
-[1.000000 0.200000 0.200000 0.200000 0.200000 0.200000] 0 sd
-0 slj
-n 7.062770 28.229700 m 38.042870 28.229700 l s
-n 7.062770 38.092440 m 38.042870 38.092440 l s
-n 7.062770 28.729700 0.500000 0.500000 180.000000 270.000000 ellipse s
-n 38.042870 28.729700 0.500000 0.500000 270.000000 360.000000 ellipse s
-n 6.562770 28.729700 m 6.562770 37.592440 l s
-n 38.542870 28.729700 m 38.542870 37.592440 l s
-n 7.062770 37.592440 0.500000 0.500000 90.000000 180.000000 ellipse s
-n 38.042870 37.592440 0.500000 0.500000 0.000000 90.000000 ellipse s
-0.050000 slw
-[0.200000] 0 sd
-[0.200000] 0 sd
-0 slj
-0 slc
-n 28.121800 31.592700 m 30.321800 30.942700 29.371800 32.142700 31.495691 31.588641 c s
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-n 30.956898 31.935890 m 31.583745 31.565671 l 30.855929 31.548843 l s
-0.050000 slw
-[0.200000] 0 sd
-[0.200000] 0 sd
-0 slj
-0 slc
-n 28.125400 33.387400 m 30.325400 32.737400 29.375400 33.937400 31.675400 33.337400 c s
-0.050000 slw
-[] 0 sd
-0 slj
-0 slc
-n 31.675400 33.337400 m 31.703797 33.446257 31.599148 33.589822 31.466100 33.624530 c 31.333053 33.659238 31.171608 33.585089 31.143211 33.476232 c 31.114813 33.367375 31.219463 33.223810 31.352510 33.189102 c 31.485558 33.154394 31.647003 33.228543 31.675400 33.337400 c ef
-0.050000 slw
-[0.200000] 0 sd
-[0.200000] 0 sd
-0 slj
-0 slc
-n 28.100400 35.383400 m 30.300400 34.733400 29.350400 35.933400 30.948877 35.516406 c s
-0 slj
-n 30.999362 35.709929 m 31.626210 35.339711 l 30.898393 35.322882 l ef
-0.100000 slw
-[0.200000] 0 sd
-[0.200000] 0 sd
-0 slj
-0 slc
-n 28.127400 37.010400 m 30.327400 36.360400 29.377400 37.560400 31.040148 37.126640 c s
-[] 0 sd
-0 slj
-0 slc
-n 31.677400 36.960400 m 31.353459 37.303273 l 30.903306 37.162338 l 31.227248 36.819464 l ef
-gsave 23.427400 31.644700 translate 0.035278 -0.035278 scale
-start_ol
-2512 0 moveto
-2064 0 lineto
-2005 54 1962 154 conicto
-1920 255 1920 320 conicto
-1486 -64 966 -64 conicto
-621 -64 406 115 conicto
-192 294 192 613 conicto
-192 866 320 1040 conicto
-449 1214 707 1312 conicto
-965 1411 1364 1437 conicto
-1920 1472 lineto
-1920 1551 lineto
-1920 1902 1777 2039 conicto
-1634 2176 1274 2176 conicto
-1101 2176 846 2098 conicto
-591 2021 416 1920 conicto
-320 2304 lineto
-526 2417 824 2488 conicto
-1122 2560 1370 2560 conicto
-1880 2560 2124 2334 conicto
-2368 2109 2368 1646 conicto
-2368 595 lineto
-2368 204 2512 0 conicto
-1920 704 moveto
-1920 1152 lineto
-1411 1123 1253 1106 conicto
-1095 1090 945 1034 conicto
-795 979 717 883 conicto
-640 788 640 646 conicto
-640 500 756 410 conicto
-872 320 1054 320 conicto
-1286 320 1529 426 conicto
-1772 532 1920 704 conicto
-end_ol grestore
-gsave 23.792054 31.644700 translate 0.035278 -0.035278 scale
-start_...
[truncated message content] |
|
From: <jom...@us...> - 2008-04-25 20:06:11
|
Revision: 1261
http://jason.svn.sourceforge.net/jason/?rev=1261&view=rev
Author: jomifred
Date: 2008-04-25 13:05:54 -0700 (Fri, 25 Apr 2008)
Log Message:
-----------
fix bug in .wait (it does not fail by timeout)
Modified Paths:
--------------
trunk/src/jason/asSyntax/PlanBodyImpl.java
trunk/src/jason/stdlib/conditional.java
trunk/src/jason/stdlib/wait.java
Modified: trunk/src/jason/asSyntax/PlanBodyImpl.java
===================================================================
--- trunk/src/jason/asSyntax/PlanBodyImpl.java 2008-04-25 17:33:58 UTC (rev 1260)
+++ trunk/src/jason/asSyntax/PlanBodyImpl.java 2008-04-25 20:05:54 UTC (rev 1261)
@@ -153,9 +153,10 @@
}
public boolean add(PlanBody bl) {
- if (term == null)
+ if (term == null) {
swap(bl);
- else if (next == null)
+ this.next = bl.getBodyNext();
+ } else if (next == null)
next = bl;
else
next.add(bl);
@@ -178,6 +179,8 @@
this.getLastBody().setBodyNext(newpb);
} else if (next != null) {
next.add(index - 1, bl);
+ } else {
+ next = bl;
}
return true;
}
Modified: trunk/src/jason/stdlib/conditional.java
===================================================================
--- trunk/src/jason/stdlib/conditional.java 2008-04-25 17:33:58 UTC (rev 1260)
+++ trunk/src/jason/stdlib/conditional.java 2008-04-25 20:05:54 UTC (rev 1261)
@@ -70,10 +70,7 @@
IntendedMeans im = ts.getC().getSelectedIntention().peek();
PlanBody ifia = im.getCurrentStep();
whattoadd.setAsBodyTerm(false);
- if (ifia.getPlanSize() == 1)
- ifia.add(whattoadd);
- else
- ifia.add(1,whattoadd);
+ ifia.add(1,whattoadd);
}
return true;
} catch (ArrayIndexOutOfBoundsException e) {
Modified: trunk/src/jason/stdlib/wait.java
===================================================================
--- trunk/src/jason/stdlib/wait.java 2008-04-25 17:33:58 UTC (rev 1260)
+++ trunk/src/jason/stdlib/wait.java 2008-04-25 20:05:54 UTC (rev 1261)
@@ -33,6 +33,7 @@
import jason.asSyntax.Atom;
import jason.asSyntax.InternalActionLiteral;
import jason.asSyntax.NumberTerm;
+import jason.asSyntax.PlanBody;
import jason.asSyntax.PlanBodyImpl;
import jason.asSyntax.StringTerm;
import jason.asSyntax.Term;
@@ -108,8 +109,8 @@
if (args.length == 2) {
timeout = (long) ((NumberTerm) args[1]).solve();
- if (args.length == 3 && args[2].toString().equals("nofail"));
- failontimeout = false;
+ if (args.length == 3 && args[2].toString().equals("nofail"))
+ failontimeout = false;
}
}
@@ -183,11 +184,12 @@
// add SI again in C.I if it was not removed and this
// wait was not dropped
if (c.getPendingIntentions().remove(sTE) == si && !c.getIntentions().contains(si) && !drop) {
- si.peek().removeCurrentStep();
if (stopByTimeout && te != null && failontimeout) {
// fail the .wait
- si.peek().getPlan().getBody().add(0, new PlanBodyImpl(BodyType.internalAction, new InternalActionLiteral(".fail")));
+ PlanBody body = si.peek().getPlan().getBody();
+ body.add(1, new PlanBodyImpl(BodyType.internalAction, new InternalActionLiteral(".fail")));
}
+ si.peek().removeCurrentStep();
if (si.isSuspended()) { // if the intention was suspended by .suspend
String k = suspend.SUSPENDED_INT+si.getId();
c.getPendingIntentions().put(k, si);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-25 17:34:12
|
Revision: 1260
http://jason.svn.sourceforge.net/jason/?rev=1260&view=rev
Author: jomifred
Date: 2008-04-25 10:33:58 -0700 (Fri, 25 Apr 2008)
Log Message:
-----------
jason team: new computation of herding positions
Modified Paths:
--------------
trunk/applications/as-unit-test/src/jason/tests/TestIF.java
trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
trunk/applications/jason-team/src/asl/dummy.asl
trunk/applications/jason-team/src/asl/exploration.asl
trunk/applications/jason-team/src/asl/gaucho.asl
trunk/applications/jason-team/src/asl/goto.asl
trunk/applications/jason-team/src/java/arch/ACArchitecture.java
trunk/applications/jason-team/src/java/arch/CowboyArch.java
trunk/applications/jason-team/src/java/jia/Vec.java
trunk/applications/jason-team/src/java/jia/herd_position.java
trunk/applications/jason-team/src/java/test/TestBasicHerding.java
trunk/src/jason/environment/grid/Location.java
Added Paths:
-----------
trunk/applications/as-unit-test/src/jason/tests/TestLoop.java
Modified: trunk/applications/as-unit-test/src/jason/tests/TestIF.java
===================================================================
--- trunk/applications/as-unit-test/src/jason/tests/TestIF.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/as-unit-test/src/jason/tests/TestIF.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -20,7 +20,11 @@
"+!test1 <- a1; "+
" .if( b(X), {jason.asunit.print(X); b1}, {jason.asunit.print(no)}); "+
" a2. "+
- "+!test2 <- -b(_); !test1. "
+
+ "+!test2 <- -b(_); !test1. "+
+
+ "+!test3 <- .if( b(X), { Y = X*10; Z = 10 }, { Y = 60; Z=20 }); jason.asunit.print(Y,\" \",Z). "+
+ "+!test4 <- -b(_); !test3. "
);
}
@@ -38,4 +42,12 @@
ag.assertPrint("no", 5);
ag.assertAct("a2", 5);
}
+
+ @Test
+ public void testUnifiyInThenElse() {
+ ag.addGoal("test3");
+ ag.assertPrint("30 10", 5);
+ ag.addGoal("test4");
+ ag.assertPrint("60 20", 10);
+ }
}
Added: trunk/applications/as-unit-test/src/jason/tests/TestLoop.java
===================================================================
--- trunk/applications/as-unit-test/src/jason/tests/TestLoop.java (rev 0)
+++ trunk/applications/as-unit-test/src/jason/tests/TestLoop.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -0,0 +1,37 @@
+package jason.tests;
+
+import jason.asunit.TestAgent;
+
+import org.junit.Before;
+import org.junit.Test;
+
+public class TestLoop {
+
+ TestAgent ag;
+
+ // initialisation of the agent test
+ @Before
+ public void setupAg() {
+ ag = new TestAgent();
+
+ // defines the agent's AgentSpeak code
+ ag.parseAScode(
+ "b(1). "+
+ "+!test1 <- .while( .count(b(_),N) & N < 4, {+b(N+1) })."+
+
+ "+!test2 <- L=4; .while( .count(b(_)) < L, { ?b(X); +b(X+1) }); jason.asunit.print(end)."
+ );
+ }
+
+ @Test
+ public void test1() {
+ ag.addGoal("test1");
+ ag.assertBel("b(4)", 20);
+ }
+
+ @Test
+ public void test2() {
+ ag.addGoal("test2");
+ ag.assertBel("b(4)", 30);
+ }
+}
Modified: trunk/applications/jason-team/AC-Local-JasonTeam.mas2j
===================================================================
--- trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/AC-Local-JasonTeam.mas2j 2008-04-25 17:33:58 UTC (rev 1260)
@@ -10,40 +10,40 @@
infrastructure: Centralised
agents:
- orgManager [osfile="src/team-os.xml",gui=yes]
+ orgManager [osfile="src/team-os.xml",gui=no]
agentArchClass jmoise.OrgManager;
- gaucho1 gaucho.asl
+ gaucho1 dummy.asl
[verbose=1, gui=yes, write_status=yes, ac_sim_back_dir="./massim-server/backup",
host="localhost", port=12300, username=participant1, password="1"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
- gaucho2 gaucho.asl
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ gaucho2 dummy.asl
[verbose=1,host="localhost", port=12300, username=participant2, password="2"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
- gaucho3 gaucho.asl
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ gaucho3 dummy.asl
[verbose=1,host="localhost", port=12300, username=participant3, password="3"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
- gaucho4 gaucho.asl
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ gaucho4 dummy.asl
[verbose=1,host="localhost", port=12300, username=participant4, password="4"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
- gaucho5 gaucho.asl
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ gaucho5 dummy.asl
[verbose=1,host="localhost", port=12300, username=participant5, password="5"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
- gaucho6 gaucho.asl
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
+ gaucho6 dummy.asl
[verbose=1,host="localhost", port=12300, username=participant6, password="6"]
agentArchClass arch.ACArchitecture
agentClass agent.SelectEvent
- beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)","pratio(_)");
+ beliefBaseClass agent.UniqueBelsBB("gsize(_,_)","steps(_)","cell(_,_,key)","corral(_,_,_,_)");
aslSourcePath: "src/asl";
Modified: trunk/applications/jason-team/src/asl/dummy.asl
===================================================================
--- trunk/applications/jason-team/src/asl/dummy.asl 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/asl/dummy.asl 2008-04-25 17:33:58 UTC (rev 1260)
@@ -47,7 +47,7 @@
// revise target each 4 steps
+pos(Step,_,_) // new cycle
- : Step mod 4 == 0
+ : Step mod 10 == 0
<- !decide_target.
Modified: trunk/applications/jason-team/src/asl/exploration.asl
===================================================================
--- trunk/applications/jason-team/src/asl/exploration.asl 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/asl/exploration.asl 2008-04-25 17:33:58 UTC (rev 1260)
@@ -15,7 +15,7 @@
+gsize(_Weight,_Height) // new match've started
: .my_name(gaucho1) // agent 1 is responsible for the team creation
- <- .print("oooo creating team group");
+ <- //.print("oooo creating team group");
.if( group(team,Old), {
jmoise.remove_group(Old)
});
@@ -40,40 +40,46 @@
<- .broadcast(tell, group_area(ID,G,A)).
-/* plans for agents with even id */
+/* plans for agents with odd id */
+gsize(_,_)
: .my_name(Me) &
agent_id(Me,AgId) &
- AgId mod 2 == 0 // I have an even Id
- <- // wait my pos
- .if(not pos(MyX, MyY,_), { MyX = 333; MyY = 444 }); //.wait("+pos(MyX,MyY,_)")
- .print("oooo ",MyX, MyY); //?pos(MyX, MyY,_);
+ AgId mod 2 == 1 // I have an odd Id
+ <- .print("ooo Recruiting scouters for my explorer group....");
+
+ // wait my pos
+ ?pos(MyX,MyY,_);
// wait others pos
- .if(not cell(_,_,ally(_)), { .wait("+cell(_,_,ally(_))") });
- .wait(200);
+ .while( .count(cell(_,_,ally(_)), N) & N < 5, {
+ .print("ooo waiting others pos ");
+ .wait("+cell(_,_,ally(_))", 500, nofail)
+ });
- // find distance to odd agents
+ // find distance to even agents
.findall(ag_d(D,AgName),
- cell(X,Y,ally(AgName)) & .print(AgName) & agent_id(AgName,Id) & .print(AgName," ooo ",Id) & Id mod 2 == 1 & jia.dist(MyX, MyY, X, Y, D),
+ cell(X,Y,ally(AgName)) & agent_id(AgName,Id) & Id mod 2 == 0 & jia.dist(MyX, MyY, X, Y, D),
LOdd);
.sort(LOdd, LSOdd);
+
// test if I received the area of my group
- .if( not group_area(AgId div 2,G,A), { .wait("+group_area(AgId div 2,G,A)") });
- .print("oooo Ags=", LSOdd," in area ",group_area(AgId div 2,G,A));
+ ?group_area(AgId div 2,G,A);
+ .print("ooo Scouters candidates =", LSOdd," in area ",group_area(AgId div 2,G,A));
// adopt role explorer in the group
jmoise.adopt_role(explorer,G);
!find_scouter(LSOdd, G).
+!find_scouter([],_)
- <- .print("oooo I do not find a scouter to work with me!").
+ <- .print("ooo I do not find a scouter to work with me!").
+!find_scouter([ag_d(_,AgName)|_],GId)
- <- .send(AgName, achieve, play_role(scouter,GId));
- .wait("+play(Ag,scouter,GId)",1000).
+ <- .print("ooo Ask ",AgName," to play scouter");
+ .send(AgName, achieve, play_role(scouter,GId));
+ .wait("+play(Ag,scouter,GId)",2000).
-!find_scouter([_|LSOdd],GId) // in case the wait fails, try next agent
- <- !find_scouter(LSOdd,GId).
+ <- .print("ooo find_scouter failure, try another agent.");
+ !find_scouter(LSOdd,GId).
/* plans for agents the others */
Modified: trunk/applications/jason-team/src/asl/gaucho.asl
===================================================================
--- trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/asl/gaucho.asl 2008-04-25 17:33:58 UTC (rev 1260)
@@ -32,12 +32,18 @@
/* -- plans -- */
++pos(_,_,_) <- do(skip).
+
+
++?pos(X, Y, S) <- .wait("+pos(X,Y,S)").
++?group_area(Id,G,A) <- .wait("+group_area(Id,G,A)").
+
+end_of_simulation(_Result)
<- .abolish(area(_,_,_,_,_,_)).
+!restart
- <- //.print("*** restart ***");
- .drop_all_desires;
+ <- .print("*** restart ***");
+ //.drop_all_desires;
.abolish(target(_,_)).
// TODO: what to do?
//!decide_target.
Modified: trunk/applications/jason-team/src/asl/goto.asl
===================================================================
--- trunk/applications/jason-team/src/asl/goto.asl 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/asl/goto.asl 2008-04-25 17:33:58 UTC (rev 1260)
@@ -24,12 +24,13 @@
!!move.
// I still do not know my location
+/*
+!move
: not pos(_,_,_)
<- .print("waiting my location....");
.wait("+pos(_,_,_)");
!move.
-
+*/
+!move
: not target(_,_)
<- .print("waiting my target....");
Modified: trunk/applications/jason-team/src/java/arch/ACArchitecture.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/java/arch/ACArchitecture.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -177,7 +177,7 @@
// prepare msg to print out
String w = "";
- if (lastActionInCurrentCycle == null && cycleCounter > 3) { // ignore problem in the first cycles (the agent is still in setup!)
+ if (lastActionInCurrentCycle == null && cycleCounter > 10) { // ignore problem in the first cycles (the agent is still in setup!)
addRestart();
w = "*** ";
}
Modified: trunk/applications/jason-team/src/java/arch/CowboyArch.java
===================================================================
--- trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/java/arch/CowboyArch.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -1,6 +1,7 @@
package arch;
import jason.JasonException;
+import jason.ReceiverDoesNotExistException;
import jason.RevisionFailedException;
import jason.asSemantics.Intention;
import jason.asSemantics.Message;
@@ -67,6 +68,8 @@
massimBackDir = stts.getUserParameter("ac_sim_back_dir");
if (massimBackDir != null && massimBackDir.startsWith("\""))
massimBackDir = massimBackDir.substring(1,massimBackDir.length()-1);
+ logger = Logger.getLogger(CowboyArch.class.getName() + ".CA-" + getAgName());
+
}
@Override
@@ -299,9 +302,15 @@
if (!getAgName().equals(oname)) {
Message msg = new Message(m);
msg.setReceiver(oname);
- try {
- sendMsg(msg);
- } catch (JasonException e) {} // no problem, the agent still does not exists
+ for (int t=0; t<4; t++) {
+ try {
+ sendMsg(msg);
+ break; // the for
+ } catch (ReceiverDoesNotExistException e) {
+ // wait and try again
+ Thread.sleep(500);
+ }
+ }
}
}
}
Modified: trunk/applications/jason-team/src/java/jia/Vec.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/java/jia/Vec.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -34,7 +34,7 @@
public int getX() { return (int)Math.round(x); }
public int getY() { return (int)Math.round(y); }
public double magnitude() { return r; }
- public double angle() { return t; }
+ public double angle() { return t; }
public Location getLocation(LocalWorldModel model) {
return new Location(getX(), model.getHeight()-getY()-1);
@@ -54,7 +54,9 @@
while (t < 0) t = t + PI2;
return new Vec(r*Math.cos(t), r*Math.sin(t));
}
-
+ public Vec newMagnitude(double r) {
+ return new Vec(r*Math.cos(t), r*Math.sin(t));
+ }
@Override
public boolean equals(Object o) {
if (o == null) return false;
Modified: trunk/applications/jason-team/src/java/jia/herd_position.java
===================================================================
--- trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/java/jia/herd_position.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -9,7 +9,6 @@
import java.util.ArrayList;
import java.util.List;
-import java.util.ListIterator;
import java.util.logging.Level;
import arch.CowboyArch;
@@ -27,9 +26,9 @@
public static final double maxStdDev = 3;
public enum Formation {
- one { int[] getAngles() { return new int[] { 0 }; } },
- six { int[] getAngles() { return new int[] { 10, -10, 30, -30, 60, -60 }; } };
- abstract int[] getAngles();
+ one { int[] getDistances() { return new int[] { 0 }; } },
+ six { int[] getDistances() { return new int[] { 2, -2, 6, -6, 10, -10 }; } };
+ abstract int[] getDistances();
};
@Override
@@ -99,6 +98,7 @@
Vec mean = Vec.mean(cows);
int stepsFromCenter = (int)Math.round(Vec.max(cows).sub(mean).magnitude())+1;
+ //Vec max = Vec.max(cows);
// run A* to see the cluster target in n steps
Search s = new Search(model, mean.getLocation(model), model.getCorralCenter(), null, false, false, false, true, null);
@@ -108,40 +108,60 @@
Vec cowstarget = new Vec(model, s.getNodeLocation(np.get(n)));
Vec agsTarget = mean.sub(cowstarget);
- Vec agTarget = agsTarget;
List<Location> r = new ArrayList<Location>();
- for (int angle: formation.getAngles()) {
- double nt = angle * (Math.PI / 180);
-
- agTarget = agsTarget.newAngle(agsTarget.angle() + nt);
- Location l = agTarget.add(mean).getLocation(model);
- r.add(l);
+ int initAgTS = 1;
+ for (int dist: formation.getDistances()) { // 2, -2, 6, -6, ....
+ Vec agTarget = agsTarget;
+ Location l = agTarget.add(mean).getLocation(model);
- // TODO: test the code below
- /*
- for (double varangle = nt; nt < 180; nt += 5) {
- agTarget = agsTarget.newAngle(agsTarget.angle() + varangle);
- Location l = agTarget.add(mean).getLocation(model);
-
- // if l is in the path of cows, continue with next varangle
- boolean inpath = false;
- for (Nodo pn: np) {
- if (l.maxBorder(s.getNodeLocation(pn)) <= 0) {
- inpath = true;
- break;
- }
- }
- if (!inpath) {
- r.add(l);
- break;
- }
+ //System.out.println("....... "+dist+" antes angle "+agTarget);
+ if (dist >= 0)
+ agTarget = new Vec( -agTarget.y, agTarget.x);
+ else
+ agTarget = new Vec( agTarget.y, -agTarget.x);
+
+ Location lastloc = null;
+ boolean uselast = false;
+ for (int agTargetSize = initAgTS; agTargetSize <= Math.abs(dist); agTargetSize++) {
+ l = agTarget.newMagnitude(agTargetSize).add(mean).add(agsTarget).getLocation(model);
+ //System.out.println("pos angle "+agTargetSize);
+ uselast = !model.inGrid(l) || model.hasObject(WorldModel.OBSTACLE, l) && lastloc != null;
+ if (uselast) {
+ r.add(pathToNearCow(model, lastloc));
+ break;
+ }
+ lastloc = l;
}
- */
+ if (!uselast)
+ r.add(pathToNearCow(model, l));
+ if (dist < 0)
+ initAgTS = Math.abs(dist)+1;
}
+ //System.out.println("all places "+r);
return r;
}
+ private Location pathToNearCow(LocalWorldModel model, Location t) {
+ Location near = null;
+ for (Location c: model.getCows()) {
+ if (near == null || t.maxBorder(c) < t.maxBorder(near))
+ near = c;
+ }
+ if (near != null) {
+ Vec nearcv = new Vec(model,near);
+ Vec dircow = new Vec(model,t).sub(nearcv);
+ //System.out.println("Near cow to "+t+" is "+near+" vec = "+dircow);
+ for (int s = 1; s <= 20; s++) {
+ Location l = dircow.newMagnitude(s).add(nearcv).getLocation(model);
+ if (model.isFree(l))
+ return l;
+ }
+ }
+ return t;
+ }
+
public Location nearFreeForAg(LocalWorldModel model, Location ag, Location t) throws Exception {
+ /*
// run A* to get the path from ag to t
if (! model.inGrid(t))
t = model.nearFree(t);
@@ -159,6 +179,7 @@
if (i++ > 3) // do not go to far from target
break;
}
+ */
return model.nearFree(t);
}
}
Modified: trunk/applications/jason-team/src/java/test/TestBasicHerding.java
===================================================================
--- trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/applications/jason-team/src/java/test/TestBasicHerding.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -149,20 +149,20 @@
assertEquals(3, stepsFromCenter);
Location byIA = new herd_position().getAgTarget(model, Formation.one, cowboy.getLocation(model));
- assertEquals(new Location(7,37), byIA);
+ assertEquals(new Location(6,38), byIA);
byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
- assertEquals(new Location(6,37), byIA);
+ assertEquals(new Location(5,38), byIA);
- // add an agent in 6,38
- model.add(WorldModel.AGENT, 6,38);
+ // add an agent in 5,38
+ model.add(WorldModel.AGENT, 5,38);
byIA = new herd_position().getAgTarget(model, Formation.six, cowboy.getLocation(model));
- assertEquals(new Location(8,38), byIA);
+ assertEquals(new Location(7,42), byIA);
- // add an agent in 8,39 (near 8,38)
- model.add(WorldModel.AGENT, 8,39);
+ // add an agent in 7,42
+ model.add(WorldModel.AGENT, 7,42);
byIA = new herd_position().getAgTarget(model, Formation.six,cowboy.getLocation(model));
- assertEquals(new Location(3,37), byIA);
+ assertEquals(new Location(8,42), byIA);
}
@Test
Modified: trunk/src/jason/environment/grid/Location.java
===================================================================
--- trunk/src/jason/environment/grid/Location.java 2008-04-25 14:39:27 UTC (rev 1259)
+++ trunk/src/jason/environment/grid/Location.java 2008-04-25 17:33:58 UTC (rev 1260)
@@ -41,6 +41,7 @@
@Override
public boolean equals(Object obj) {
+ if (obj == null) return false;
if (this == obj) return true;
if (getClass() != obj.getClass()) return false;
final Location other = (Location) obj;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <jom...@us...> - 2008-04-25 14:39:46
|
Revision: 1259
http://jason.svn.sourceforge.net/jason/?rev=1259&view=rev
Author: jomifred
Date: 2008-04-25 07:39:27 -0700 (Fri, 25 Apr 2008)
Log Message:
-----------
add .while internal action
Modified Paths:
--------------
trunk/src/jason/asSemantics/Agent.java
trunk/src/jason/asSyntax/ArithFunctionTerm.java
trunk/src/jason/asSyntax/InternalActionLiteral.java
trunk/src/jason/infra/centralised/CentralisedAgArch.java
trunk/src/jason/stdlib/wait.java
Added Paths:
-----------
trunk/src/jason/ReceiverDoesNotExistException.java
trunk/src/jason/stdlib/loop.java
Added: trunk/src/jason/ReceiverDoesNotExistException.java
===================================================================
--- trunk/src/jason/ReceiverDoesNotExistException.java (rev 0)
+++ trunk/src/jason/ReceiverDoesNotExistException.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -0,0 +1,44 @@
+//----------------------------------------------------------------------------
+// Copyright (C) 2003 Rafael H. Bordini, Jomi F. Hubner, et al.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// To contact the authors:
+// http://www.dur.ac.uk/r.bordini
+// http://www.inf.furb.br/~jomi
+//
+//----------------------------------------------------------------------------
+
+
+package jason;
+
+
+public class ReceiverDoesNotExistException extends java.lang.Exception {
+
+ private static final long serialVersionUID = 1L;
+
+ public ReceiverDoesNotExistException() {
+ }
+
+ public ReceiverDoesNotExistException(String msg) {
+ super(msg);
+ }
+
+ public ReceiverDoesNotExistException(String msg, Exception cause) {
+ super(msg);
+ initCause(cause);
+ }
+
+}
Modified: trunk/src/jason/asSemantics/Agent.java
===================================================================
--- trunk/src/jason/asSemantics/Agent.java 2008-04-25 13:29:38 UTC (rev 1258)
+++ trunk/src/jason/asSemantics/Agent.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -45,6 +45,7 @@
import jason.functions.RuleToFunction;
import jason.runtime.Settings;
import jason.stdlib.conditional;
+import jason.stdlib.loop;
import java.io.File;
import java.io.FileInputStream;
@@ -244,6 +245,8 @@
String iaName = action.getFunctor();
if (iaName.equals(".if"))
return conditional.create();
+ if (iaName.equals(".while"))
+ return loop.create();
if (iaName.charAt(0) == '.')
iaName = "jason.stdlib" + iaName;
InternalAction objIA = internalActions.get(iaName);
Modified: trunk/src/jason/asSyntax/ArithFunctionTerm.java
===================================================================
--- trunk/src/jason/asSyntax/ArithFunctionTerm.java 2008-04-25 13:29:38 UTC (rev 1258)
+++ trunk/src/jason/asSyntax/ArithFunctionTerm.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -99,8 +99,8 @@
} catch (Exception e) {
logger.log(Level.SEVERE, getErrorMsg()+ " -- "+ e);
}
- } else {
- logger.warning(getErrorMsg()+ " -- this function has unground arguments and can not be evaluated!");
+ //} else {
+ // logger.warning(getErrorMsg()+ " -- this function has unground arguments and can not be evaluated! Unifier is "+u);
}
return false;
Modified: trunk/src/jason/asSyntax/InternalActionLiteral.java
===================================================================
--- trunk/src/jason/asSyntax/InternalActionLiteral.java 2008-04-25 13:29:38 UTC (rev 1258)
+++ trunk/src/jason/asSyntax/InternalActionLiteral.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -26,6 +26,7 @@
import jason.asSemantics.Agent;
import jason.asSemantics.InternalAction;
import jason.asSemantics.Unifier;
+import jason.stdlib.loop;
import java.util.Iterator;
import java.util.logging.Level;
@@ -61,7 +62,7 @@
if (ag != null)
ia = ag.getIA(this);
}
-
+
@Override
public boolean isInternalAction() {
return true;
@@ -76,7 +77,16 @@
public boolean canBeAddedInBB() {
return false;
}
-
+
+ @Override
+ public boolean apply(Unifier u) {
+ if (this.ia != null && this.ia instanceof loop)
+ return false;
+ else
+ return super.apply(u);
+ }
+
+
@SuppressWarnings("unchecked")
public Iterator<Unifier> logicalConsequence(Agent ag, Unifier un) {
if (ag.getTS().getUserAgArch().isRunning()) {
Modified: trunk/src/jason/infra/centralised/CentralisedAgArch.java
===================================================================
--- trunk/src/jason/infra/centralised/CentralisedAgArch.java 2008-04-25 13:29:38 UTC (rev 1258)
+++ trunk/src/jason/infra/centralised/CentralisedAgArch.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -24,6 +24,7 @@
package jason.infra.centralised;
import jason.JasonException;
+import jason.ReceiverDoesNotExistException;
import jason.architecture.AgArch;
import jason.architecture.AgArchInfraTier;
import jason.asSemantics.ActionExec;
@@ -230,14 +231,14 @@
}
// this is used by the .send internal action in stdlib
- public void sendMsg(Message m) throws Exception {
+ public void sendMsg(Message m) throws ReceiverDoesNotExistException {
// actually send the message
m.setSender(getAgName());
CentralisedAgArch rec = masRunner.getAg(m.getReceiver());
if (rec == null) {
if (isRunning())
- throw new JasonException("Receiver '" + m.getReceiver() + "' does not exists! Could not send " + m);
+ throw new ReceiverDoesNotExistException("Receiver '" + m.getReceiver() + "' does not exists! Could not send " + m);
else
return;
}
Added: trunk/src/jason/stdlib/loop.java
===================================================================
--- trunk/src/jason/stdlib/loop.java (rev 0)
+++ trunk/src/jason/stdlib/loop.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -0,0 +1,103 @@
+//----------------------------------------------------------------------------
+// Copyright (C) 2003 Rafael H. Bordini, Jomi F. Hubner, et al.
+//
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License, or (at your option) any later version.
+//
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
+//
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+// To contact the authors:
+// http://www.dur.ac.uk/r.bordini
+// http://www.inf.furb.br/~jomi
+//
+//----------------------------------------------------------------------------
+
+package jason.stdlib;
+
+import jason.JasonException;
+import jason.asSemantics.DefaultInternalAction;
+import jason.asSemantics.IntendedMeans;
+import jason.asSemantics.InternalAction;
+import jason.asSemantics.TransitionSystem;
+import jason.asSemantics.Unifier;
+import jason.asSyntax.LogicalFormula;
+import jason.asSyntax.ObjectTerm;
+import jason.asSyntax.ObjectTermImpl;
+import jason.asSyntax.PlanBody;
+import jason.asSyntax.PlanBodyImpl;
+import jason.asSyntax.Structure;
+import jason.asSyntax.Term;
+import jason.asSyntax.PlanBody.BodyType;
+
+import java.util.Iterator;
+
+// TODO: comments
+public class loop extends DefaultInternalAction {
+
+ private static InternalAction singleton = null;
+ public static InternalAction create() {
+ if (singleton == null)
+ singleton = new loop();
+ return singleton;
+ }
+
+ @Override
+ public Object execute(TransitionSystem ts, Unifier un, Term[] args) throws Exception {
+ try {
+ if ( !(args[0] instanceof LogicalFormula))
+ throw new JasonException("The first argument of .while must be a logical formula.");
+
+ IntendedMeans im = ts.getC().getSelectedIntention().peek();
+ PlanBody whileia = im.getCurrentStep();
+
+ // store a backup of the unifier for the next iteration
+
+ // if the IA has a backup unifier, use that (it is an object term)
+ if (args.length == 3) {
+ // restore the unifier of previous iterations
+ Unifier ubak = (Unifier)((ObjectTerm)args[2]).getObject();
+ un.clear();
+ un.compose(ubak);
+ } else {
+ // add backup unifier in the IA
+ //ubak = (Unifier)un.clone();
+ ((Structure)whileia.getBodyTerm()).addTerm(new ObjectTermImpl(un.clone()));
+ }
+
+ LogicalFormula logExpr = (LogicalFormula)args[0].clone();
+ logExpr.apply(un); // need to apply since the internal action literal for while does not apply
+ Iterator<Unifier> iu = logExpr.logicalConsequence(ts.getAg(), un); //(Unifier)un.clone());
+ if (iu.hasNext()) {
+ if ( !args[1].isPlanBody())
+ throw new JasonException("The second argument of .while must be a plan body term.");
+
+ un.compose(iu.next());
+
+ PlanBody whattoadd = (PlanBody)args[1]; //.clone();
+ whattoadd.add(new PlanBodyImpl(BodyType.internalAction, (Term)whileia.getBodyTerm().clone())); //(PlanBody)whileia.clone()); // add the while after
+ whattoadd.setAsBodyTerm(false);
+ if (whileia.getPlanSize() == 1)
+ whileia.add(whattoadd);
+ else
+ whileia.add(1,whattoadd);
+ //System.out.println("new body="+whileia.getBodyNext());
+ }
+ return true;
+ } catch (ArrayIndexOutOfBoundsException e) {
+ throw new JasonException("The internal action 'while' has not received the required arguments.");
+ } catch (JasonException e) {
+ throw e;
+ } catch (Exception e) {
+ throw new JasonException("Error in internal action 'while': " + e, e);
+ }
+ }
+}
Modified: trunk/src/jason/stdlib/wait.java
===================================================================
--- trunk/src/jason/stdlib/wait.java 2008-04-25 13:29:38 UTC (rev 1258)
+++ trunk/src/jason/stdlib/wait.java 2008-04-25 14:39:27 UTC (rev 1259)
@@ -67,8 +67,12 @@
<li> <code>.wait("+!g", 2000)</code>: suspend the intention until the goal
<code>g</code> is triggered or 2 seconds have passed, whatever happens
first. In case the event does not happens in two seconds, the internal action
- fails.
+ fails.
+ <li> <code>.wait("+!g", 2000, nofail)</code>: suspend the intention until the goal
+ <code>g</code> is triggered or 2 seconds have passed, whatever happens
+ first. In case the event does not happens in two seconds, the internal action does not
+ fail.
</ul>
@see jason.stdlib.at
@@ -88,6 +92,8 @@
public Object execute(final TransitionSystem ts, Unifier un, Term[] args) throws Exception {
long timeout = -1;
Trigger te = null;
+
+ boolean failontimeout = true;
try {
if (args[0].isNumeric()) {
// time in milliseconds
@@ -101,8 +107,9 @@
te = Trigger.parseTrigger(st.getString());
if (args.length == 2) {
- NumberTerm tot = (NumberTerm) args[1];
- timeout = (long) tot.solve();
+ timeout = (long) ((NumberTerm) args[1]).solve();
+ if (args.length == 3 && args[2].toString().equals("nofail"));
+ failontimeout = false;
}
}
@@ -110,7 +117,7 @@
ts.getLogger().log(Level.SEVERE, "Error at .wait.", e);
return false;
}
- WaitEvent wet = new WaitEvent(te, un, ts, timeout);
+ WaitEvent wet = new WaitEvent(te, un, ts, timeout, failontimeout);
wet.start();
return true;
}
@@ -139,9 +146,10 @@
boolean ok = false;
boolean drop = false;
boolean stopByTimeout = false;
+ boolean failontimeout;
long timeout = -1;
- WaitEvent(Trigger te, Unifier un, TransitionSystem ts, long to) {
+ WaitEvent(Trigger te, Unifier un, TransitionSystem ts, long to, boolean failontimeout) {
super("wait "+te);
this.te = te;
this.un = un;
@@ -149,6 +157,7 @@
c = ts.getC();
si = c.getSelectedIntention();
this.timeout = to;
+ this.failontimeout = failontimeout;
// register listener
c.addEventListener(this);
@@ -175,7 +184,7 @@
// wait was not dropped
if (c.getPendingIntentions().remove(sTE) == si && !c.getIntentions().contains(si) && !drop) {
si.peek().removeCurrentStep();
- if (stopByTimeout && te != null) {
+ if (stopByTimeout && te != null && failontimeout) {
// fail the .wait
si.peek().getPlan().getBody().add(0, new PlanBodyImpl(BodyType.internalAction, new InternalActionLiteral(".fail")));
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ga...@us...> - 2008-04-25 13:29:43
|
Revision: 1258
http://jason.svn.sourceforge.net/jason/?rev=1258&view=rev
Author: gauth
Date: 2008-04-25 06:29:38 -0700 (Fri, 25 Apr 2008)
Log Message:
-----------
Documentation on role dynamics
Added Paths:
-----------
trunk/applications/jason-team/doc/roles/
trunk/applications/jason-team/doc/roles/ac2008-roles.aux
trunk/applications/jason-team/doc/roles/ac2008-roles.pdf
trunk/applications/jason-team/doc/roles/ac2008-roles.tex
trunk/applications/jason-team/doc/roles/figures/
trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps
trunk/applications/jason-team/doc/roles/figures/exploration-positioning.odg
trunk/applications/jason-team/doc/roles/figures/exploration-positioning.pdf
trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps
trunk/applications/jason-team/doc/roles/figures/jason-team-SS.pdf
trunk/applications/jason-team/doc/roles/figures/partition.eps
trunk/applications/jason-team/doc/roles/figures/partition.odg
trunk/applications/jason-team/doc/roles/figures/partition.pdf
trunk/applications/jason-team/doc/roles/llncs.cls
trunk/applications/jason-team/doc/roles/llncsdoc.sty
trunk/applications/jason-team/doc/roles/splncs.bst
trunk/applications/jason-team/doc/roles/sprmindx.sty
Added: trunk/applications/jason-team/doc/roles/ac2008-roles.aux
===================================================================
--- trunk/applications/jason-team/doc/roles/ac2008-roles.aux (rev 0)
+++ trunk/applications/jason-team/doc/roles/ac2008-roles.aux 2008-04-25 13:29:38 UTC (rev 1258)
@@ -0,0 +1,23 @@
+\relax
+\@writefile{toc}{\contentsline {title}{Role Dynamics in the \emph {Jason} Team}{1}}
+\@writefile{toc}{\contentsline {author}{Rafael H. Bordini{$^\star $} \and Jomi F. H{\" u}bner{$^\dagger $} \and Gauthier Picard{$^\dagger $}}{1}}
+\@writefile{toc}{\contentsline {section}{\numberline {1}Introduction}{1}}
+\@writefile{lof}{\contentsline {figure}{\numberline {1}{\ignorespaces Role and group structures}}{2}}
+\newlabel{fig:groups}{{1}{2}}
+\@writefile{toc}{\contentsline {section}{\numberline {2}Exploration}{2}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.1}Pairs formation}{2}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.2}Environment partitioning}{2}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.3}Role assignment}{2}}
+\@writefile{lof}{\contentsline {figure}{\numberline {2}{\ignorespaces Environment partitioning}}{3}}
+\newlabel{fig:partition}{{2}{3}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.4}Explorer role playing}{3}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.5}Scout role playing}{3}}
+\@writefile{lof}{\contentsline {figure}{\numberline {3}{\ignorespaces Position of the \textsf {scout} relatively to the \textsf {explorer} during exploration phase}}{4}}
+\newlabel{fig:position}{{3}{4}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {2.6}Tracker role playing}{4}}
+\newlabel{sec:tracker-role-playing}{{2.6}{4}}
+\@writefile{toc}{\contentsline {section}{\numberline {3}Herding}{5}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {3.1}Herder role playing}{5}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {3.2}Herdboy role playing}{6}}
+\@writefile{toc}{\contentsline {subsection}{\numberline {3.3}Ranger role playing}{6}}
+\@writefile{toc}{\contentsline {section}{\numberline {4}TODO list}{6}}
Property changes on: trunk/applications/jason-team/doc/roles/ac2008-roles.aux
___________________________________________________________________
Name: svn:executable
+ *
Added: trunk/applications/jason-team/doc/roles/ac2008-roles.pdf
===================================================================
(Binary files differ)
Property changes on: trunk/applications/jason-team/doc/roles/ac2008-roles.pdf
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/applications/jason-team/doc/roles/ac2008-roles.tex
===================================================================
--- trunk/applications/jason-team/doc/roles/ac2008-roles.tex (rev 0)
+++ trunk/applications/jason-team/doc/roles/ac2008-roles.tex 2008-04-25 13:29:38 UTC (rev 1258)
@@ -0,0 +1,301 @@
+
+%%%%%%%%%%%%%%%%%%%%%%% file typeinst.tex %%%%%%%%%%%%%%%%%%%%%%%%%
+%
+% This is the LaTeX source for the instructions to authors using
+% the LaTeX document class 'llncs.cls' for contributions to
+% the Lecture Notes in Computer Sciences series.
+% http://www.springer.com/lncs Springer Heidelberg 2006/05/04
+%
+% It may be used as a template for your own input - copy it
+% to a new file with a new name and use it as the basis
+% for your article.
+%
+% NB: the document class 'llncs' has its own and detailed documentation, see
+% ftp://ftp.springer.de/data/pubftp/pub/tex/latex/llncs/latex2e/llncsdoc.pdf
+%
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+
+
+\documentclass[runningheads]{llncs}
+
+\usepackage{amssymb}
+\setcounter{tocdepth}{3}
+\usepackage{graphicx}
+\usepackage[latin1]{inputenc}
+\usepackage{color}
+%\usepackage{txfonts}
+
+\usepackage{url}
+\urldef{\mailsa}\path|R.B...@du...|
+\urldef{\mailsb}\path|{hubner,picard}@emse.fr|
+\newcommand{\keywords}[1]{\par\addvspace\baselineskip
+\noindent\keywordname\enspace\ignorespaces#1}
+
+\newcommand{\comment}[2]{\noindent\textsf{
+ \begin{center}
+ \colorbox[rgb]{.8,.8,.8}{
+ \begin{minipage}{.95\columnwidth}
+ {{#1 :}} \\ {#2}
+ \end{minipage}
+ }
+ \end{center}
+ }
+}
+
+\newcommand{\ascomment}[1]{\comment{\emph{AgentSpeak}}{#1}}
+
+\begin{document}
+
+\mainmatter % start of an individual contribution
+
+% first the title is needed
+\title{Role Dynamics in the \emph{Jason} Team}
+\subtitle{Agent Contest 2008}
+% a short form should be given in case it is too long for the running head
+\titlerunning{Jason Team's Role Dynamics}
+
+% the name(s) of the author(s) follow(s) next
+%
+% NB: Chinese authors should write their first names(s) in front of
+% their surnames. This ensures that the names appear correctly in
+% the running heads and the author index.
+%
+\author{Rafael H. Bordini{$^\star$} \and Jomi F. H{\" u}bner{$^\dagger$} \and Gauthier Picard{$^\dagger$}}
+%
+\authorrunning{Bordini, H\"ubner and Picard}
+% (feature abused for this document to repeat the title also on left hand pages)
+
+% the affiliations are given next; don't give your e-mail address
+% unless you accept that it will be published
+\institute{
+{$^\star$}~University of Durham, UK\\
+\mailsa\\
+{$^\dagger$}~\'Ecole des Mines de Saint-\'Etienne, France\\
+\mailsb\\
+% \mailsc\\
+\url{http://jason.sourceforge.net/}}
+
+%
+% NB: a more complex sample for affiliations and the mapping to the
+% corresponding authors can be found in the file "llncs.dem"
+% (search for the string "\mainmatter" where a contribution starts).
+% "llncs.dem" accompanies the document class "llncs.cls".
+%
+
+%\toctitle{Lecture Notes in Computer Science}
+%\tocauthor{Authors' Instructions}
+\maketitle
+
+
+\begin{abstract}
+This document presents the main ideas concerning the dynamics of the role within the \emph{Jason} team. An agent's life cycle is decomposed into two phases: \emph{exploration} and \emph{herding}. During each of these two phases, an agent will play different roles according to the context (cluster size, number of herders, etc.).
+
+\keywords{Jason, organisation, roles}
+\end{abstract}
+
+
+\section{Introduction}
+
+As to remind the roles identified in the AC 2008 proposal we made, Figure \ref{fig:groups} presenting the group structure in the \emph{Jason} team.
+
+\begin{figure}[h]
+ \centering
+ \includegraphics[width=0.8\columnwidth]{figures/jason-team-SS.pdf}
+ \caption{Role and group structures}
+ \label{fig:groups}
+\end{figure}
+
+Here is a reminder of the specific roles:
+
+\begin{itemize}
+\item \textit{guard}: guards the corral so as to keep the herded cows
+ safe inside it;
+% exploration group roles
+\item \textit{explorer}: explore the environment until it detects a cow;
+\item \textit{scout}: follows the explorer;
+\item \textit{tracker}: once a cow is detected, tracks all cows of a cluster
+ so as to evaluate its size;
+ % \item \textit{perturbator}: perturbs the other team (only triggered if the
+ % other team is not fairplay),
+
+% hersing group roles
+\item \textit{herder}: herds the cows detected by explorer to reach
+ the corral (since they move quicker than cows, they can also
+ continue to explore around the cluster);
+\item \textit{herdboy}: helps the herder to lead cows to the corral;
+\item \textit{ranger}: finds the ``best'' path to the corral.
+\end{itemize}
+
+Actually, an agent will follow a simple life cycle: exploration, herding, exploration, herding, etc. During these phases the agent will play some roles depending on the perception form the environment and its group.
+
+The following section present these two phases in detail.
+
+\section{Exploration}
+
+\subsection{Pairs formation}
+
+At the begin of the simulation, agents form pairs (so 3 pairs for a simulation). If during the simulation, an agent is exploring alone (only during the its exploration phase), it will try to find a partner.
+
+\subsection{Environment partitioning}
+
+Each pair is assigned to a specific area of the environment. This partition is
+chosen according to the agents' positions. As to simplify this partition, we
+choose to settle it as shown in figure~\ref{fig:partition}.
+
+\begin{figure}[h]
+ \centering
+ \includegraphics[width=0.6\columnwidth]{figures/partition.pdf}
+ \caption{Environment partitioning}
+ \label{fig:partition}
+\end{figure}
+
+This can be improved by computing the partition according to the position of the coral.
+
+\subsection{Role assignment}
+
+An exploration group can be composed of 1 or 2 agents. If it is a 1-agent group, the only agent plays the role \textsf{explorer}. If it is a 2-agent group, one agent plays the role \textsf{explorer} (the agent farest form the coral), the second one plays the role \textsf{scout}. During these role playings, each agent shares its perceptions with its partner.
+
+\ascomment{}
+
+\subsection{Explorer role playing}
+
+The tasks of the \textsf{explorer} are quite simple:
+\begin{enumerate}
+\item choose a target position: the near position which is least visited within its partition,
+\item compute a path to the target position, using $A^\star$ algorithm,
+\item move along the computed path.
+\end{enumerate}
+
+This role playing ends as soon as the \textsf{explorer} perceives a cow.
+
+\ascomment{}
+
+\subsection{Scout role playing}
+
+The role of the \textsf{scout} is to help the \textsf{explorer} to find
+cows. As to maximize the number of visited cells, the scout must be positioned
+at a distance equal to the double of the perception distance of agents relatively to the
+\textsf{explorer}, orthogonally to the direction of the target position from
+the viewpoint of the \textsf{explorer} (figure~\ref{fig:position})
+
+\begin{figure}[h]
+ \centering
+ \includegraphics[width=.4\columnwidth]{figures/exploration-positioning.pdf}
+ \caption{Position of the \textsf{scout} relatively to the \textsf{explorer} during exploration phase}
+ \label{fig:position}
+\end{figure}
+
+This requires some coordination with the \textsf{explorer}:
+\begin{itemize}
+\item the \textsf{explorer} informs the \textsf{scout} of its next target position and its own position (in case the \textsf{scout} does not perceive it),
+\item the \textsf{scout} compute its next target position.
+\end{itemize}
+
+But before that, the \textsf{scout} must move towards the \textsf{explorer} until it perceives it.
+
+This role playing ends as soon as the \textsf{explorer} (which is now a \textsf{tracker}) a \textsf{herder}, as to begin the herding phase.
+
+\ascomment{}
+
+\subsection{Tracker role playing}
+\label{sec:tracker-role-playing}
+
+Once the \textsf{explorer} perceives a cow, it plays the \textsf{tracker} role which aims at evaluating the size of the cluster of cows. The \textsf{tracker} does the following tasks:
+\begin{enumerate}
+\item compute the next target position: a position at the opposite of the coral position according the center of the cluster,
+\item circle the coral as to reach the target position,
+\item count the perceived cows until it reaches the target position (maintaining a counter $\mathrm size$),
+\item once the target position is reached, decide whether the group must split, grow or remain as it is, with respect to the following rules:
+\begin{itemize}
+\item if ($\mathrm{size} \leq \tau < \tau_{\mathrm{max}}$) then split the group: one \textsf{herder} is sufficient to herd the cluster to the coral; the \textsf{scout} plays now the \textsf{explorer} role,
+\item if ($\tau < \mathrm{size} \leq \tau_{\mathrm{max}}$) then the group is kept: the two agents are sufficient; the \textsf{explorer} plays now the \textsf{herder} role and the \textsf{scout} now plays the \textsf{herdboy} role,
+\item if ($\tau < \tau_{\mathrm{max}} < \mathrm{size}$) then the group must recruit nearest \textsf{explorer} agents or negotiate with other \textsf{herder} agents to recruit \textsf{herdboy} agents.
+\end{itemize}
+\end{enumerate}
+
+Negotiation between \textsf{herders} will depends on:
+\begin{itemize}
+\item the sizes of the respective clusters,
+\item the distance between the agents to recruit and the recruiting agent.
+\end{itemize}
+
+At the end of this role playing, the \textsf{explorer} is positioned so as to have the cluster between itself and the coral. In this position, it only has to move to the coral to ``push'' the cluster in the good direction.
+
+During this phase, the \textsf{scout} continues to play this role.
+
+\ascomment{}
+
+\section{Herding}
+
+This phase starts as soon as a \textsf{tracker} becomes a \textsf{herder}. At the same moment, the \textsf{scout} becomes either a \textsf{herdboy} or an \textsf{explorer}, depending on the size of the cluster.
+
+\subsection{Herder role playing}
+
+The role of a \textsf{herder} is to guide a cluster to the coral. As said before, the cluster (its center) is positioned between the \textsf{herder} and the coral.
+
+Mainly, the tasks for a \textsf{herder} are:
+\begin{enumerate}
+\item update the size of the cluster\footnote{necessary to detect whether a cluster is too big},
+\item recruit if necessary (see section \ref{sec:tracker-role-playing}),
+\item compute the center of the cluster,
+\item compute the target position with respect of the position of the coral and the center of the cluster,
+\item compute the path to reach this position by using $A^\star$,
+\item compute its next position according to the previous information,
+\item inform its \textsf{herdboys} of this position,
+\item compute the path to the next position using $A^\star$,
+\item move to its next position.
+\end{enumerate}
+
+\ascomment{}
+
+We can identify some \textbf{exceptions}:
+\begin{itemize}
+\item \textbf{immobile cluster}: if the cluster does not move for $t_{\mathrm max}$ steps, the \textsf{herder} must change its target direction by adding an $\alpha$ angle to the direction.
+\item \textbf{two clusters meet}: if two clusters start to merge, \textsf{herders} must decide whether the cluster must merge or not. This implies negotiation between the two agents depending on the total size of the cluster.
+\item \textbf{cluster too big}: if the cluster $\mathrm{size} > \tau_{\mathrm
+ supermax} (\tau_{\mathrm supermax} > \tau_{\mathrm max})$, it must split into two clusters. As to do this, the \textsf{herder} go to the center of the cluster as to create a breach in the cluster (and becomes then \textsf{ranger}). New \textsf{herders} must be chosen among the \textsf{herdboys} for the new clusters. The \textsf{ranger} becomes an \textsf{explorer} as to be easily recruited by the new \textsf{herders}.
+\end{itemize}
+
+\ascomment{}
+
+\subsection{Herdboy role playing}
+
+The \textsf{herdboy} role is quite simple: it helps the \textsf{herder} to herd a cluster to the coral. \textsf{Herdboys} are led by one \textsf{herder}. Once a \textsf{herder} begins to herd a cluster to the coral, some \textsf{herdboys} may help it to achieve this task.
+
+\textsf{Herdboys}' tasks are:
+\begin{enumerate}
+\item detect close clusters, as to decide whether they merge or not,
+\item compute its next position thanks to information coming from its \textsf{herder}: each \textsf{herdboy} moves to a position near the \textsf{herder} around the cluster. E.g. if the \textsf{herder} is on the line from coral to cluster, the first \textsf{herdboy} position itself on a line at 10\xB0 left from the \textsf{herder}'s position, the second one on a line at 10\xB0 right, etc.
+\item compute the path to the next position using $A^\star$,
+\item move the next position.
+\end{enumerate}
+
+If the cluster too big exception occurs, \textsf{herdboys} must try to enter in the breach created by the \textsf{herder} to help the cluster splitting.
+
+\ascomment{}
+
+\subsection{Ranger role playing}
+
+The \textsf{ranger}'s role is to create a breach inside a big cluster to create two separate cluster. Once it is done, it becomes an \textsf{explorer}.
+The idea is to split the cluster by letting the cows move by side, since herdboys move to the position of the ranger and do not constrain cows anymore.
+Once it is done, the side of the cluster are free, and cows can move by side.
+It leads \textsf{herdboys} during this stage.
+
+\textsf{Ranger}'s tasks are:
+\begin{enumerate}
+\item inform \textsf{herdboys} they have to move to its position around the cluster,
+\item compute its next target position: the point at the opposite of its current position according to the center of the cluster,
+\item compute the path to this position using $A^\star$,
+\item move to the next position.
+\end{enumerate}
+
+\ascomment{}
+
+\section{TODO list}
+
+\begin{enumerate}
+\item add \emph{AgentSpeak} specification for each role
+\item specify the dynamic role-chart with roles and triggers to sum up the role dynamics
+\end{enumerate}
+
+\end{document}
Property changes on: trunk/applications/jason-team/doc/roles/ac2008-roles.tex
___________________________________________________________________
Name: svn:executable
+ *
Added: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps
===================================================================
--- trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps (rev 0)
+++ trunk/applications/jason-team/doc/roles/figures/exploration-positioning.eps 2008-04-25 13:29:38 UTC (rev 1258)
@@ -0,0 +1,382 @@
+%!PS-Adobe-3.0 EPSF-3.0
+%%BoundingBox: 0 0 326 332
+%%Pages: 0
+%%Creator: Sun Microsystems, Inc.
+%%Title: none
+%%CreationDate: none
+%%LanguageLevel: 2
+%%EndComments
+%%BeginProlog
+%%BeginResource: procset SDRes-Prolog 1.0 0
+/b4_inc_state save def
+/dict_count countdictstack def
+/op_count count 1 sub def
+userdict begin
+0 setgray 0 setlinecap 1 setlinewidth 0 setlinejoin 10 setmiterlimit[] 0 setdash newpath
+/languagelevel where {pop languagelevel 1 ne {false setstrokeadjust false setoverprint} if} if
+/bdef {bind def} bind def
+/c {setrgbcolor} bdef
+/l {neg lineto} bdef
+/rl {neg rlineto} bdef
+/lc {setlinecap} bdef
+/lj {setlinejoin} bdef
+/lw {setlinewidth} bdef
+/ml {setmiterlimit} bdef
+/ld {setdash} bdef
+/m {neg moveto} bdef
+/ct {6 2 roll neg 6 2 roll neg 6 2 roll neg curveto} bdef
+/r {rotate} bdef
+/t {neg translate} bdef
+/s {scale} bdef
+/sw {show} bdef
+/gs {gsave} bdef
+/gr {grestore} bdef
+/f {findfont dup length dict begin
+{1 index /FID ne {def} {pop pop} ifelse} forall /Encoding ISOLatin1Encoding def
+currentdict end /NFont exch definefont pop /NFont findfont} bdef
+/p {closepath} bdef
+/sf {scalefont setfont} bdef
+/ef {eofill}bdef
+/pc {closepath stroke}bdef
+/ps {stroke}bdef
+/pum {matrix currentmatrix}bdef
+/pom {setmatrix}bdef
+/bs {/aString exch def /nXOfs exch def /nWidth exch def currentpoint nXOfs 0 rmoveto pum nWidth aString stringwidth pop div 1 scale aString show pom moveto} bdef
+%%EndResource
+%%EndProlog
+%%BeginSetup
+%%EndSetup
+%%Page: 1 1
+%%BeginPageSetup
+%%EndPageSetup
+pum
+0.02834 0.02831 s
+0 -11726 t
+/tm matrix currentmatrix def
+tm setmatrix
+-2500 -11000 t
+1 1 s
+0.753 0.753 0.753 c 3500 20000 m 4067 20000 4500 20433 4500 21000 ct 4500 21567 4067 22000 3500 22000 ct
+2933 22000 2500 21567 2500 21000 ct 2500 20433 2933 20000 3500 20000 ct p ef
+0 lw 1 lj 0.003 0.003 0.003 c 3500 20000 m 4067 20000 4500 20433 4500 21000 ct
+4500 21567 4067 22000 3500 22000 ct 2933 22000 2500 21567 2500 21000 ct 2500 20433 2933 20000 3500 20000 ct
+pc
+0.648 0.648 0.648 c 3175 20588 m 3235 20588 3282 20635 3282 20695 ct 3282 20755 3235 20802 3175 20802 ct
+3115 20802 3068 20755 3068 20695 ct 3068 20635 3115 20588 3175 20588 ct p ef
+0.003 0.003 0.003 c 3175 20588 m 3235 20588 3282 20635 3282 20695 ct 3282 20755 3235 20802 3175 20802 ct
+3115 20802 3068 20755 3068 20695 ct 3068 20635 3115 20588 3175 20588 ct pc
+0.648 0.648 0.648 c 3823 20588 m 3883 20588 3930 20635 3930 20695 ct 3930 20755 3883 20802 3823 20802 ct
+3763 20802 3716 20755 3716 20695 ct 3716 20635 3763 20588 3823 20588 ct p ef
+0.003 0.003 0.003 c 3823 20588 m 3883 20588 3930 20635 3930 20695 ct 3930 20755 3883 20802 3823 20802 ct
+3763 20802 3716 20755 3716 20695 ct 3716 20635 3763 20588 3823 20588 ct pc
+2951 21436 m 3304 21623 3696 21623 4049 21436 ct ps
+gs
+gs
+pum
+10438 19614 t
+54 0 m 54 -455 l 385 -455 l 385 -399 l 114 -399 l 114 -261 l 365 -261 l
+365 -207 l 114 -207 l 114 -53 l 389 -53 l 389 0 l 54 0 l p
+222 -455 m 222 -455 l p ef
+543 -169 m 432 -331 l 505 -331 l 581 -214 l 658 -331 l 726 -329 l
+614 -169 l 731 0 l 660 0 l 577 -124 l 497 0 l 426 0 l 543 -169 l
+p ef
+923 -35 m 948 -35 969 -46 986 -68 ct 1003 -90 1012 -123 1012 -167 ct 1012 -193 1008 -216 1001 -236 ct
+986 -273 960 -291 923 -291 ct 884 -291 858 -271 844 -232 ct 837 -212 833 -185 833 -153 ct
+833 -127 837 -105 844 -87 ct 859 -52 885 -35 923 -35 ct p
+778 132 m 778 132 778 132 778 -330 ct 778 -330 778 -330 833 -330 ct 833 -330 833 -330 833 -286 ct
+844 -301 856 -313 869 -321 ct 888 -333 910 -339 935 -339 ct 973 -339 1005 -325 1031 -296 ct
+1057 -267 1070 -226 1070 -172 ct 1070 -99 1051 -48 1013 -17 ct 989 2 962 12 930 12 ct
+905 12 884 7 867 -3 ct 857 -9 846 -20 834 -35 ct 834 -35 834 -35 834 132 ct 834 132 834 132 778 132 ct
+p ef
+1134 0 m 1134 -454 l 1190 -454 l 1190 0 l 1134 0 l p ef
+1404 -35 m 1440 -35 1465 -49 1479 -77 ct 1492 -105 1499 -137 1499 -171 ct 1499 -202 1494 -227 1484 -247 ct
+1469 -278 1442 -293 1404 -293 ct 1371 -293 1346 -280 1331 -254 ct 1316 -228 1308 -196 1308 -159 ct
+1308 -124 1316 -94 1331 -70 ct 1346 -47 1370 -35 1404 -35 ct p
+1405 -341 m 1448 -341 1484 -327 1513 -298 ct 1542 -270 1557 -228 1557 -172 ct
+1557 -119 1544 -74 1518 -39 ct 1492 -4 1452 12 1398 12 ct 1353 12 1317 -2 1290 -33 ct
+1263 -64 1250 -106 1250 -158 ct 1250 -214 1264 -258 1292 -291 ct 1320 -324 1358 -341 1405 -341 ct
+p
+1404 -339 m 1404 -339 l p ef
+1625 0 m 1625 0 1625 0 1625 -332 ct 1625 -332 1625 -332 1678 -332 ct 1678 -332 1678 -332 1678 -275 ct
+1682 -286 1693 -299 1710 -315 ct 1727 -331 1747 -339 1769 -339 ct 1770 -339 1772 -339 1774 -339 ct
+1777 -338 1781 -338 1787 -337 ct 1787 -337 1787 -337 1787 -279 ct 1784 -280 1781 -280 1778 -281 ct
+1775 -281 1772 -281 1769 -281 ct 1740 -281 1719 -272 1704 -254 ct 1689 -235 1681 -214 1681 -191 ct
+1681 -191 1681 -191 1681 0 ct 1681 0 1681 0 1625 0 ct p ef
+1973 -339 m 1996 -339 2019 -333 2041 -322 ct 2063 -311 2079 -297 2091 -279 ct
+2102 -262 2109 -243 2113 -220 ct 2116 -205 2118 -180 2118 -147 ct 2118 -147 2118 -147 1877 -147 ct
+1878 -113 1886 -86 1901 -66 ct 1915 -45 1938 -35 1969 -35 ct 1998 -35 2021 -45 2038 -64 ct
+2047 -75 2054 -87 2058 -102 ct 2058 -102 2058 -102 2113 -102 ct 2112 -90 2107 -76 2099 -62 ct
+2090 -47 2081 -35 2071 -25 ct 2054 -9 2034 1 2009 7 ct 1996 10 1981 12 1964 12 ct
+1923 12 1888 -2 1860 -32 ct 1831 -62 1817 -105 1817 -159 ct 1817 -212 1831 -256 1860 -289 ct
+1889 -322 1926 -339 1973 -339 ct p
+1878 -191 m 1878 -191 1878 -191 2060 -191 ct 2058 -216 2053 -235 2044 -250 ct
+2029 -277 2004 -291 1969 -291 ct 1944 -291 1922 -282 1905 -263 ct 1888 -244 1879 -220 1878 -191 ct
+p
+1968 -339 m 1968 -339 l p ef
+2188 0 m 2188 0 2188 0 2188 -332 ct 2188 -332 2188 -332 2241 -332 ct 2241 -332 2241 -332 2241 -275 ct
+2245 -286 2256 -299 2273 -315 ct 2290 -331 2310 -339 2332 -339 ct 2333 -339 2335 -339 2337 -339 ct
+2340 -338 2344 -338 2350 -337 ct 2350 -337 2350 -337 2350 -279 ct 2347 -280 2344 -280 2341 -281 ct
+2338 -281 2335 -281 2332 -281 ct 2303 -281 2282 -272 2267 -254 ct 2252 -235 2244 -214 2244 -191 ct
+2244 -191 2244 -191 2244 0 ct 2244 0 2244 0 2188 0 ct p ef
+pom
+gr
+gr
+gs
+gs
+pum
+4246 22312 t
+31 -147 m 31 -147 31 -147 89 -147 ct 90 -121 96 -100 107 -84 ct 126 -54 161 -39 210 -39 ct
+233 -39 253 -42 271 -49 ct 306 -62 324 -85 324 -118 ct 324 -143 317 -161 302 -171 ct
+286 -181 263 -190 230 -197 ct 230 -197 230 -197 171 -211 ct 132 -220 104 -230 88 -241 ct
+60 -260 46 -288 46 -326 ct 46 -367 60 -401 87 -427 ct 115 -454 154 -467 204 -467 ct
+251 -467 290 -455 322 -432 ct 355 -409 371 -373 371 -322 ct 371 -322 371 -322 313 -322 ct
+310 -346 304 -365 294 -378 ct 276 -401 246 -413 203 -413 ct 168 -413 143 -405 128 -390 ct
+113 -375 105 -357 105 -337 ct 105 -315 114 -298 132 -288 ct 144 -281 170 -273 212 -263 ct
+212 -263 212 -263 273 -249 ct 303 -242 326 -232 342 -220 ct 370 -199 384 -168 384 -127 ct
+384 -77 366 -41 330 -19 ct 295 1 253 12 206 12 ct 151 12 108 -1 77 -30 ct 46 -59 30 -98 31 -147 ct
+p
+209 -467 m 209 -467 l p ef
+592 -341 m 629 -341 659 -332 683 -314 ct 706 -296 720 -264 725 -220 ct 725 -220 725 -220 671 -220 ct
+668 -240 660 -257 648 -271 ct 637 -284 618 -291 592 -291 ct 556 -291 531 -274 516 -239 ct
+506 -216 501 -188 501 -155 ct 501 -122 508 -94 522 -71 ct 536 -48 558 -37 588 -37 ct
+611 -37 630 -44 643 -58 ct 657 -72 666 -92 671 -116 ct 671 -116 671 -116 725 -116 ct
+719 -72 703 -40 679 -20 ct 654 0 622 10 583 10 ct 540 10 506 -5 480 -37 ct 454 -68 441 -108 441 -156 ct
+441 -214 455 -260 483 -292 ct 512 -325 548 -341 592 -341 ct p
+583 -339 m 583 -339 l p ef
+913 -35 m 949 -35 974 -49 988 -77 ct 1001 -105 1008 -137 1008 -171 ct 1008 -202 1003 -227 993 -247 ct
+978 -278 951 -293 913 -293 ct 880 -293 855 -280 840 -254 ct 825 -228 817 -196 817 -159 ct
+817 -124 825 -94 840 -70 ct 855 -47 879 -35 913 -35 ct p
+914 -341 m 957 -341 993 -327 1022 -298 ct 1051 -270 1066 -228 1066 -172 ct
+1066 -119 1053 -74 1027 -39 ct 1001 -4 961 12 907 12 ct 862 12 826 -2 799 -33 ct
+772 -64 759 -106 759 -158 ct 759 -214 773 -258 801 -291 ct 829 -324 867 -341 914 -341 ct
+p
+913 -339 m 913 -339 l p ef
+1132 -332 m 1132 -332 1132 -332 1188 -332 ct 1188 -332 1188 -332 1188 -110 ct
+1188 -93 1191 -79 1196 -68 ct 1206 -48 1224 -38 1250 -38 ct 1288 -38 1314 -55 1328 -90 ct
+1335 -109 1339 -135 1339 -168 ct 1339 -168 1339 -168 1339 -332 ct 1339 -332 1339 -332 1395 -332 ct
+1395 -332 1395 -332 1395 0 ct 1395 0 1395 0 1342 0 ct 1342 0 1342 0 1343 -47 ct
+1336 -34 1327 -24 1316 -15 ct 1295 1 1270 9 1240 9 ct 1194 9 1162 -6 1146 -38 ct
+1137 -55 1132 -77 1132 -106 ct 1132 -106 1132 -106 1132 -332 ct p
+1264 -339 m 1264 -339 l p ef
+1496 -332 m 1496 -332 1496 -332 1496 -424 ct 1496 -424 1496 -424 1552 -424 ct
+1552 -424 1552 -424 1552 -332 ct 1552 -332 1552 -332 1605 -332 ct 1605 -332 1605 -332 1605 -286 ct
+1605 -286 1605 -286 1552 -286 ct 1552 -286 1552 -286 1552 -70 ct 1552 -58 1556 -50 1564 -46 ct
+1568 -44 1575 -43 1585 -43 ct 1588 -43 1591 -43 1594 -43 ct 1597 -43 1601 -44 1605 -44 ct
+1605 -44 1605 -44 1605 0 ct 1599 2 1592 3 1585 4 ct 1578 5 1571 5 1563 5 ct 1537 5 1519 -1 1510 -14 ct
+1501 -27 1496 -45 1496 -66 ct 1496 -66 1496 -66 1496 -286 ct 1496 -286 1496 -286 1451 -286 ct
+1451 -286 1451 -286 1451 -332 ct 1451 -332 1451 -332 1496 -332 ct p ef
+pom
+gr
+gr
+gs
+gs
+pum
+11258 12708 t
+9 -455 m 377 -455 l 377 -401 l 224 -401 l 224 0 l 162 0 l 162 -401 l
+9 -401 l 9 -455 l p ef
+401 -87 m 401 -71 407 -58 419 -49 ct 430 -40 444 -35 461 -35 ct 480 -35 499 -40 518 -49 ct
+549 -64 564 -89 564 -123 ct 564 -123 564 -123 564 -168 ct 557 -163 548 -159 538 -156 ct
+527 -153 516 -151 506 -150 ct 506 -150 506 -150 472 -146 ct 452 -143 437 -139 427 -133 ct
+410 -123 401 -108 401 -87 ct p
+447 -189 m 447 -189 447 -189 536 -200 ct 549 -201 557 -207 562 -216 ct 565 -221 566 -228 566 -237 ct
+566 -256 559 -270 546 -278 ct 532 -287 513 -291 487 -291 ct 458 -291 438 -283 425 -268 ct
+419 -259 414 -246 412 -229 ct 412 -229 412 -229 360 -229 ct 361 -270 374 -299 400 -315 ct
+425 -331 455 -339 489 -339 ct 528 -339 559 -331 584 -316 ct 608 -301 620 -278 620 -247 ct
+620 -247 620 -247 620 -56 ct 620 -50 621 -46 624 -42 ct 626 -39 631 -37 639 -37 ct
+641 -37 644 -37 647 -37 ct 650 -38 653 -38 657 -39 ct 657 -39 657 -39 657 1 ct
+648 4 642 5 637 6 ct 633 7 626 7 618 7 ct 599 7 585 0 576 -12 ct 572 -20 569 -30 567 -43 ct
+555 -28 539 -15 518 -4 ct 497 6 473 12 448 12 ct 417 12 392 3 372 -15 ct 353 -34 343 -57 343 -85 ct
+343 -116 353 -140 372 -157 ct 391 -174 416 -185 447 -189 ct p
+490 -339 m 490 -339 l p ef
+711 0 m 711 0 711 0 711 -332 ct 711 -332 711 -332 764 -332 ct 764 -332 764 -332 764 -275 ct
+768 -286 779 -299 796 -315 ct 813 -331 833 -339 855 -339 ct 856 -339 858 -339 860 -339 ct
+863 -338 867 -338 873 -337 ct 873 -337 873 -337 873 -279 ct 870 -280 867 -280 864 -281 ct
+861 -281 858 -281 855 -281 ct 826 -281 805 -272 790 -254 ct 775 -235 767 -214 767 -191 ct
+767 -191 767 -191 767 0 ct 767 0 767 0 711 0 ct p ef
+1039 -337 m 1065 -337 1088 -331 1108 -318 ct 1118 -311 1129 -301 1140 -287 ct
+1140 -287 1140 -287 1140 -328 ct 1140 -328 1140 -328 1190 -328 ct 1190 -328 1190 -328 1190 -26 ct
+1190 15 1184 48 1171 72 ct 1148 117 1105 140 1040 140 ct 1004 140 974 132 950 116 ct
+926 100 912 75 909 41 ct 909 41 909 41 967 41 ct 970 56 975 67 983 75 ct 996 88 1016 94 1043 94 ct
+1086 94 1114 79 1127 49 ct 1135 31 1139 0 1138 -46 ct 1127 -29 1113 -16 1097 -8 ct
+1082 0 1061 4 1035 4 ct 999 4 967 -8 940 -33 ct 913 -59 899 -101 899 -160 ct 899 -216 913 -259 940 -290 ct
+967 -321 1000 -337 1039 -337 ct p
+1139 -167 m 1139 -209 1131 -239 1114 -259 ct 1097 -279 1075 -289 1049 -289 ct
+1010 -289 983 -271 968 -234 ct 961 -214 957 -188 957 -156 ct 957 -119 965 -90 980 -70 ct
+995 -51 1015 -41 1041 -41 ct 1081 -41 1109 -59 1125 -95 ct 1134 -116 1139 -140 1139 -167 ct
+p
+1045 -339 m 1045 -339 l p ef
+1410 -339 m 1433 -339 1456 -333 1478 -322 ct 1500 -311 1516 -297 1528 -279 ct
+1539 -262 1546 -243 1550 -220 ct 1553 -205 1555 -180 1555 -147 ct 1555 -147 1555 -147 1314 -147 ct
+1315 -113 1323 -86 1338 -66 ct 1352 -45 1375 -35 1406 -35 ct 1435 -35 1458 -45 1475 -64 ct
+1484 -75 1491 -87 1495 -102 ct 1495 -102 1495 -102 1550 -102 ct 1549 -90 1544 -76 1536 -62 ct
+1527 -47 1518 -35 1508 -25 ct 1491 -9 1471 1 1446 7 ct 1433 10 1418 12 1401 12 ct
+1360 12 1325 -2 1297 -32 ct 1268 -62 1254 -105 1254 -159 ct 1254 -212 1268 -256 1297 -289 ct
+1326 -322 1363 -339 1410 -339 ct p
+1315 -191 m 1315 -191 1315 -191 1497 -191 ct 1495 -216 1490 -235 1481 -250 ct
+1466 -277 1441 -291 1406 -291 ct 1381 -291 1359 -282 1342 -263 ct 1325 -244 1316 -220 1315 -191 ct
+p
+1405 -339 m 1405 -339 l p ef
+1635 -332 m 1635 -332 1635 -332 1635 -424 ct 1635 -424 1635 -424 1691 -424 ct
+1691 -424 1691 -424 1691 -332 ct 1691 -332 1691 -332 1744 -332 ct 1744 -332 1744 -332 1744 -286 ct
+1744 -286 1744 -286 1691 -286 ct 1691 -286 1691 -286 1691 -70 ct 1691 -58 1695 -50 1703 -46 ct
+1707 -44 1714 -43 1724 -43 ct 1727 -43 1730 -43 1733 -43 ct 1736 -43 1740 -44 1744 -44 ct
+1744 -44 1744 -44 1744 0 ct 1738 2 1731 3 1724 4 ct 1717 5 1710 5 1702 5 ct 1676 5 1658 -1 1649 -14 ct
+1640 -27 1635 -45 1635 -66 ct 1635 -66 1635 -66 1635 -286 ct 1635 -286 1635 -286 1590 -286 ct
+1590 -286 1590 -286 1590 -332 ct 1590 -332 1590 -332 1635 -332 ct p ef
+pom
+gr
+gr
+[ 51 51 51 51 ] 0 ld
+4500 21000 m 11500 21000 l ps
+[ ] 0 ld
+9250 21000 m 9000 21000 l 9000 20500 l 9500 20500 l 9500 21000 l 9250 21000 l
+pc
+8447 18860 m 8482 18953 l 8517 19046 l 8553 19140 l 8541 19145 l 8528 19150 l
+8516 19154 l 8481 19061 l 8446 18967 l 8410 18873 l 8422 18869 l 8435 18864 l
+8447 18860 l p ef
+4553 20640 m 4518 20547 l 4483 20454 l 4447 20360 l 4459 20355 l 4472 20350 l
+4484 20346 l 4519 20439 l 4554 20533 l 4590 20627 l 4578 20631 l 4565 20636 l
+4553 20640 l p ef
+1 lw 0 lj 8470 19011 m 8421 19030 l ps
+8371 19048 m 8321 19067 l ps
+8272 19086 m 8222 19104 l ps
+8172 19123 m 8122 19142 l ps
+8073 19160 m 8023 19179 l ps
+7973 19198 m 7924 19216 l ps
+7874 19235 m 7824 19253 l ps
+7774 19272 m 7725 19291 l ps
+7675 19309 m 7625 19328 l ps
+7576 19347 m 7526 19365 l ps
+7476 19384 m 7426 19403 l ps
+7377 19421 m 7327 19440 l ps
+7277 19458 m 7228 19477 l ps
+7178 19496 m 7128 19514 l ps
+7079 19533 m 7029 19552 l ps
+6979 19570 m 6929 19589 l ps
+6880 19608 m 6830 19626 l ps
+6780 19645 m 6731 19664 l ps
+6681 19682 m 6631 19701 l ps
+6581 19719 m 6532 19738 l ps
+6482 19757 m 6432 19775 l ps
+6383 19794 m 6333 19813 l ps
+6283 19831 m 6233 19850 l ps
+6184 19869 m 6134 19887 l ps
+6084 19906 m 6035 19925 l ps
+5985 19943 m 5935 19962 l ps
+5885 19980 m 5836 19999 l ps
+5786 20018 m 5736 20036 l ps
+5687 20055 m 5637 20074 l ps
+5587 20092 m 5537 20111 l ps
+5488 20130 m 5438 20148 l ps
+5388 20167 m 5339 20186 l ps
+5289 20204 m 5239 20223 l ps
+5189 20241 m 5140 20260 l ps
+5090 20279 m 5040 20297 l ps
+4991 20316 m 4941 20335 l ps
+4891 20353 m 4842 20372 l ps
+4792 20391 m 4742 20409 l ps
+4692 20428 m 4643 20446 l ps
+4593 20465 m 4543 20484 l ps
+9500 13000 m 9650 13450 l 9350 13450 l 9500 13000 l p ef
+9500 22500 m 9500 13360 l ps
+0.753 0.753 0.753 c 9500 17500 m 10067 17500 10500 17933 10500 18500 ct 10500 19067 10067 19500 9500 19500 ct
+8933 19500 8500 19067 8500 18500 ct 8500 17933 8933 17500 9500 17500 ct p ef
+0 lw 1 lj 0.003 0.003 0.003 c 9500 17500 m 10067 17500 10500 17933 10500 18500 ct
+10500 19067 10067 19500 9500 19500 ct 8933 19500 8500 19067 8500 18500 ct 8500 17933 8933 17500 9500 17500 ct
+pc
+0.648 0.648 0.648 c 9175 18088 m 9235 18088 9282 18135 9282 18195 ct 9282 18255 9235 18302 9175 18302 ct
+9115 18302 9068 18255 9068 18195 ct 9068 18135 9115 18088 9175 18088 ct p ef
+0.003 0.003 0.003 c 9175 18088 m 9235 18088 9282 18135 9282 18195 ct 9282 18255 9235 18302 9175 18302 ct
+9115 18302 9068 18255 9068 18195 ct 9068 18135 9115 18088 9175 18088 ct pc
+0.648 0.648 0.648 c 9823 18088 m 9883 18088 9930 18135 9930 18195 ct 9930 18255 9883 18302 9823 18302 ct
+9763 18302 9716 18255 9716 18195 ct 9716 18135 9763 18088 9823 18088 ct p ef
+0.003 0.003 0.003 c 9823 18088 m 9883 18088 9930 18135 9930 18195 ct 9930 18255 9883 18302 9823 18302 ct
+9763 18302 9716 18255 9716 18195 ct 9716 18135 9763 18088 9823 18088 ct pc
+8951 18936 m 9304 19123 9696 19123 10049 18936 ct ps
+gs
+gs
+pum
+5252 19449 t
+121 -23 m 138 -23 152 -30 164 -45 ct 175 -60 181 -82 181 -111 ct 181 -129 178 -144 173 -157 ct
+164 -182 146 -194 121 -194 ct 95 -194 77 -181 68 -155 ct 63 -141 60 -123 60 -102 ct
+60 -85 63 -70 68 -58 ct 77 -35 95 -23 121 -23 ct p
+24 88 m 24 88 24 88 24 -220 ct 24 -220 24 -220 60 -220 ct 60 -220 60 -220 60 -191 ct
+67 -201 76 -208 84 -214 ct 97 -222 112 -226 129 -226 ct 154 -226 175 -216 193 -197 ct
+210 -178 219 -150 219 -114 ct 219 -66 206 -31 181 -11 ct 165 1 146 8 125 8 ct 108 8 94 4 83 -2 ct
+77 -6 69 -13 61 -23 ct 61 -23 61 -23 61 88 ct 61 88 61 88 24 88 ct p ef
+356 -226 m 372 -226 387 -222 401 -215 ct 416 -208 427 -198 435 -187 ct 442 -176 447 -163 450 -148 ct
+452 -138 453 -121 453 -98 ct 453 -98 453 -98 292 -98 ct 293 -75 298 -57 308 -44 ct
+318 -30 333 -23 354 -23 ct 373 -23 388 -29 400 -42 ct 406 -50 410 -58 413 -68 ct
+413 -68 413 -68 450 -68 ct 449 -60 446 -51 440 -41 ct 435 -31 429 -23 422 -17 ct
+411 -6 397 1 380 5 ct 372 7 361 8 350 8 ct 323 8 300 -1 281 -21 ct 262 -41 252 -69 252 -106 ct
+252 -141 262 -170 281 -193 ct 300 -215 325 -226 356 -226 ct p
+293 -129 m 293 -129 293 -129 415 -129 ct 414 -145 410 -158 405 -167 ct 394 -185 378 -194 354 -194 ct
+337 -194 323 -188 311 -176 ct 300 -163 294 -148 293 -129 ct p
+353 -226 m 353 -226 l p ef
+501 0 m 501 0 501 0 501 -220 ct 501 -220 501 -220 537 -220 ct 537 -220 537 -220 537 -184 ct
+540 -191 547 -200 559 -210 ct 570 -221 584 -226 599 -226 ct 599 -226 601 -226 602 -226 ct
+604 -226 607 -225 611 -225 ct 611 -225 611 -225 611 -187 ct 609 -187 607 -188 605 -188 ct
+603 -188 601 -188 598 -188 ct 579 -188 564 -182 554 -170 ct 543 -158 538 -144 538 -128 ct
+538 -128 538 -128 538 0 ct 538 0 538 0 501 0 ct p ef
+726 -226 m 751 -226 771 -220 787 -208 ct 802 -196 812 -175 815 -146 ct 815 -146 815 -146 779 -146 ct
+777 -160 772 -171 764 -180 ct 756 -189 744 -194 726 -194 ct 703 -194 686 -182 676 -159 ct
+669 -144 666 -126 666 -104 ct 666 -82 671 -63 680 -48 ct 689 -33 704 -25 724 -25 ct
+739 -25 751 -30 760 -39 ct 769 -49 776 -62 779 -78 ct 779 -78 779 -78 815 -78 ct
+811 -49 801 -27 784 -13 ct 768 0 747 6 721 6 ct 692 6 669 -4 652 -25 ct 635 -46 626 -72 626 -103 ct
+626 -142 635 -172 654 -194 ct 673 -215 697 -226 726 -226 ct p
+720 -226 m 720 -226 l p ef
+945 -226 m 961 -226 976 -222 990 -215 ct 1005 -208 1016 -198 1024 -187 ct 1031 -176 1036 -163 1039 -148 ct
+1041 -138 1042 -121 1042 -98 ct 1042 -98 1042 -98 881 -98 ct 882 -75 887 -57 897 -44 ct
+907 -30 922 -23 943 -23 ct 962 -23 977 -29 989 -42 ct 995 -50 999 -58 1002 -68 ct
+1002 -68 1002 -68 1039 -68 ct 1038 -60 1035 -51 1029 -41 ct 1024 -31 1018 -23 1011 -17 ct
+1000 -6 986 1 969 5 ct 961 7 950 8 939 8 ct 912 8 889 -1 870 -21 ct 851 -41 841 -69 841 -106 ct
+841 -141 851 -170 870 -193 ct 889 -215 914 -226 945 -226 ct p
+882 -129 m 882 -129 882 -129 1004 -129 ct 1003 -145 999 -158 994 -167 ct 983 -185 967 -194 943 -194 ct
+926 -194 912 -188 900 -176 ct 889 -163 883 -148 882 -129 ct p
+942 -226 m 942 -226 l p ef
+1184 -23 m 1201 -23 1215 -30 1227 -45 ct 1238 -60 1244 -82 1244 -111 ct 1244 -129 1241 -144 1236 -157 ct
+1227 -182 1209 -194 1184 -194 ct 1158 -194 1140 -181 1131 -155 ct 1126 -141 1123 -123 1123 -102 ct
+1123 -85 1126 -70 1131 -58 ct 1140 -35 1158 -23 1184 -23 ct p
+1087 88 m 1087 88 1087 88 1087 -220 ct 1087 -220 1087 -220 1123 -220 ct 1123 -220 1123 -220 1123 -191 ct
+1130 -201 1139 -208 1147 -214 ct 1160 -222 1175 -226 1192 -226 ct 1217 -226 1238 -216 1256 -197 ct
+1273 -178 1282 -150 1282 -114 ct 1282 -66 1269 -31 1244 -11 ct 1228 1 1209 8 1188 8 ct
+1171 8 1157 4 1146 -2 ct 1140 -6 1132 -13 1124 -23 ct 1124 -23 1124 -23 1124 88 ct
+1124 88 1124 88 1087 88 ct p ef
+1334 -220 m 1334 -220 1334 -220 1334 -281 ct 1334 -281 1334 -281 1371 -281 ct
+1371 -281 1371 -281 1371 -220 ct 1371 -220 1371 -220 1407 -220 ct 1407 -220 1407 -220 1407 -189 ct
+1407 -189 1407 -189 1371 -189 ct 1371 -189 1371 -189 1371 -46 ct 1371 -38 1374 -33 1379 -30 ct
+1382 -29 1387 -28 1394 -28 ct 1396 -28 1398 -28 1400 -28 ct 1402 -28 1404 -29 1407 -29 ct
+1407 -29 1407 -29 1407 0 ct 1403 1 1398 2 1394 3 ct 1389 4 1384 4 1379 4 ct 1361 4 1350 0 1343 -8 ct
+1337 -17 1334 -29 1334 -43 ct 1334 -43 1334 -43 1334 -189 ct 1334 -189 1334 -189 1304 -189 ct
+1304 -189 1304 -189 1304 -220 ct 1304 -220 1304 -220 1334 -220 ct p ef
+1445 0 m 1445 -220 l 1482 -220 l 1482 0 l 1445 0 l p
+1445 -261 m 1445 -303 l 1482 -303 l 1482 -261 l 1445 -261 l p ef
+1626 -23 m 1650 -23 1667 -32 1676 -51 ct 1685 -70 1690 -90 1690 -113 ct 1690 -134 1687 -151 1680 -163 ct
+1670 -184 1652 -194 1626 -194 ct 1603 -194 1587 -185 1576 -168 ct 1566 -151 1561 -130 1561 -105 ct
+1561 -82 1566 -62 1576 -47 ct 1587 -31 1603 -23 1626 -23 ct p
+1627 -226 m 1655 -226 1679 -217 1699 -198 ct 1718 -179 1728 -151 1728 -114 ct
+1728 -78 1719 -49 1702 -26 ct 1685 -3 1658 8 1622 8 ct 1592 8 1568 -1 1550 -22 ct
+1532 -42 1523 -70 1523 -104 ct 1523 -142 1532 -171 1551 -193 ct 1570 -215 1595 -226 1627 -226 ct
+p
+1626 -226 m 1626 -226 l p ef
+1775 0 m 1775 0 1775 0 1775 -220 ct 1775 -220 1775 -220 1811 -220 ct 1811 -220 1811 -220 1811 -190 ct
+1821 -203 1832 -212 1844 -218 ct 1856 -223 1869 -226 1883 -226 ct 1914 -226 1935 -215 1946 -193 ct
+1952 -181 1955 -164 1955 -141 ct 1955 -141 1955 -141 1955 0 ct 1955 0 1955 0 1918 0 ct
+1918 0 1918 0 1918 -139 ct 1918 -153 1916 -164 1912 -172 ct 1905 -186 1893 -193 1876 -193 ct
+1867 -193 1860 -192 1854 -190 ct 1844 -187 1835 -181 1827 -172 ct 1821 -165 1817 -157 1815 -149 ct
+1813 -141 1812 -130 1812 -116 ct 1812 -116 1812 -116 1812 0 ct 1812 0 1812 0 1775 0 ct
+p
+1862 -226 m 1862 -226 l p ef
+pom
+gr
+gr
+0.753 0.753 0.753 c 9500 11000 m 10501 12000 l 9500 13001 l 8500 12000 l
+9500 11000 l 9500 11000 l p ef
+0.003 0.003 0.003 c 9500 11000 m 10501 12000 l 9500 13001 l 8500 12000 l
+9500 11000 l 9500 11000 l pc
+0 11726 t
+pom
+count op_count sub {pop} repeat countdictstack dict_count sub {end} repeat b4_inc_state restore
+%%PageTrailer
+%%Trailer
+%%EOF
Added: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.odg
===================================================================
(Binary files differ)
Property changes on: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.odg
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.pdf
===================================================================
(Binary files differ)
Property changes on: trunk/applications/jason-team/doc/roles/figures/exploration-positioning.pdf
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Added: trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps
===================================================================
--- trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps (rev 0)
+++ trunk/applications/jason-team/doc/roles/figures/jason-team-SS.eps 2008-04-25 13:29:38 UTC (rev 1258)
@@ -0,0 +1,6442 @@
+%!PS-Adobe-2.0 EPSF-2.0
+%%Title: /media/JOMI/pubs/2008/agent-contest/proposal/figures/jason-team-SS.dia
+%%Creator: Dia v0.96.1
+%%CreationDate: Fri Mar 7 10:36:35 2008
+%%For: hubner
+%%Orientation: Portrait
+%%Magnification: 1.0000
+%%BoundingBox: 0 0 960 912
+%%BeginSetup
+%%EndSetup
+%%EndComments
+%%BeginProlog
+[ /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /space /exclam /quotedbl /numbersign /dollar /percent /ampersand /quoteright
+/parenleft /parenright /asterisk /plus /comma /hyphen /period /slash /zero /one
+/two /three /four /five /six /seven /eight /nine /colon /semicolon
+/less /equal /greater /question /at /A /B /C /D /E
+/F /G /H /I /J /K /L /M /N /O
+/P /Q /R /S /T /U /V /W /X /Y
+/Z /bracketleft /backslash /bracketright /asciicircum /underscore /quoteleft /a /b /c
+/d /e /f /g /h /i /j /k /l /m
+/n /o /p /q /r /s /t /u /v /w
+/x /y /z /braceleft /bar /braceright /asciitilde /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
+/space /exclamdown /cent /sterling /currency /yen /brokenbar /section /dieresis /copyright
+/ordfeminine /guillemotleft /logicalnot /hyphen /registered /macron /degree /plusminus /twosuperior /threesuperior
+/acute /mu /paragraph /periodcentered /cedilla /onesuperior /ordmasculine /guillemotright /onequarter /onehalf
+/threequarters /questiondown /Agrave /Aacute /Acircumflex /Atilde /Adieresis /Aring /AE /Ccedilla
+/Egrave /Eacute /Ecircumflex /Edieresis /Igrave /Iacute /Icircumflex /Idieresis /Eth /Ntilde
+/Ograve /Oacute /Ocircumflex /Otilde /Odieresis /multiply /Oslash /Ugrave /Uacute /Ucircumflex
+/Udieresis /Yacute /Thorn /germandbls /agrave /aacute /acircumflex /atilde /adieresis /aring
+/ae /ccedilla /egrave /eacute /ecircumflex /edieresis /igrave /iacute /icircumflex /idieresis
+/eth /ntilde /ograve /oacute /ocircumflex /otilde /odieresis /divide /oslash /ugrave
+/uacute /ucircumflex /udieresis /yacute /thorn /ydieresis] /isolatin1encoding exch def
+/cp {closepath} bind def
+/c {curveto} bind def
+/f {fill} bind def
+/a {arc} bind def
+/ef {eofill} bind def
+/ex {exch} bind def
+/gr {grestore} bind def
+/gs {gsave} bind def
+/sa {save} bind def
+/rs {restore} bind def
+/l {lineto} bind def
+/m {moveto} bind def
+/rm {rmoveto} bind def
+/n {newpath} bind def
+/s {stroke} bind def
+/sh {show} bind def
+/slc {setlinecap} bind def
+/slj {setlinejoin} bind def
+/slw {setlinewidth} bind def
+/srgb {setrgbcolor} bind def
+/rot {rotate} bind def
+/sc {scale} bind def
+/sd {setdash} bind def
+/ff {findfont} bind def
+/sf {setfont} bind def
+/scf {scalefont} bind def
+/sw {stringwidth pop} bind def
+/tr {translate} bind def
+
+/ellipsedict 8 dict def
+ellipsedict /mtrx matrix put
+/ellipse
+{ ellipsedict begin
+ /endangle exch def
+ /startangle exch def
+ /yrad exch def
+ /xrad exch def
+ /y exch def
+ /x exch def /savematrix mtrx currentmatrix def
+ x y tr xrad yrad sc
+ 0 0 1 startangle endangle arc
+ savematrix setmatrix
+ end
+} def
+
+/mergeprocs {
+dup length
+3 -1 roll
+dup
+length
+dup
+5 1 roll
+3 -1 roll
+add
+array cvx
+dup
+3 -1 roll
+0 exch
+putinterval
+dup
+4 2 roll
+putinterval
+} bind def
+/dpi_x 300 def
+/dpi_y 300 def
+/conicto {
+ /to_y exch def
+ /to_x exch def
+ /conic_cntrl_y exch def
+ /conic_cntrl_x exch def
+ currentpoint
+ /p0_y exch def
+ /p0_x exch def
+ /p1_x p0_x conic_cntrl_x p0_x sub 2 3 div mul add def
+ /p1_y p0_y conic_cntrl_y p0_y sub 2 3 div mul add def
+ /p2_x p1_x to_x p0_x sub 1 3 div mul add def
+ /p2_y p1_y to_y p0_y sub 1 3 div mul add def
+ p1_x p1_y p2_x p2_y to_x to_y curveto
+} bind def
+/start_ol { gsave 1.1 dpi_x div dup scale} bind def
+/end_ol { closepath fill grestore } bind def
+28.346000 -28.346000 scale
+-5.910861 -38.117440 translate
+%%EndProlog
+
+
+0.100000 slw
+[] 0 sd
+[] 0 sd
+0 slc
+0 slj
+0.100000 slw
+0 slc
+0 slj
+[] 0 sd
+1.000000 1.000000 1.000000 srgb
+n 15.565527 15.450000 m 19.827633 15.450000 l 20.416108 15.450000 20.893160 15.899306 20.893160 16.453553 c 20.893160 17.007801 20.416108 17.457107 19.827633 17.457107 c 15.565527 17.457107 l 14.977052 17.457107 14.500000 17.007801 14.500000 16.453553 c 14.500000 15.899306 14.977052 15.450000 15.565527 15.450000 c ef
+0.000000 0.000000 0.000000 srgb
+n 15.565527 15.450000 m 19.827633 15.450000 l 20.416108 15.450000 20.893160 15.899306 20.893160 16.453553 c 20.893160 17.007801 20.416108 17.457107 19.827633 17.457107 c 15.565527 17.457107 l 14.977052 17.457107 14.500000 17.007801 14.500000 16.453553 c 14.500000 15.899306 14.977052 15.450000 15.565527 15.450000 c s
+gsave 15.969080 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+3392 384 moveto
+2820 -64 2078 -64 conicto
+1241 -64 748 410 conicto
+256 884 256 1670 conicto
+256 2444 699 2918 conicto
+1142 3392 1870 3392 conicto
+2541 3392 2966 2928 conicto
+3392 2465 3392 1632 conicto
+3392 1408 lineto
+1152 1408 lineto
+1200 1106 1461 905 conicto
+1722 704 2085 704 conicto
+2659 704 3232 1024 conicto
+3392 384 lineto
+2496 2048 moveto
+2459 2371 2281 2561 conicto
+2104 2752 1846 2752 conicto
+1575 2752 1382 2561 conicto
+1189 2371 1152 2048 conicto
+2496 2048 lineto
+end_ol grestore
+gsave 16.456120 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+3536 0 moveto
+2536 0 lineto
+1771 1051 lineto
+1013 0 lineto
+48 0 lineto
+1284 1718 lineto
+112 3328 lineto
+1112 3328 lineto
+1781 2410 lineto
+2442 3328 lineto
+3408 3328 lineto
+2267 1742 lineto
+3536 0 lineto
+end_ol grestore
+gsave 16.943160 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+1344 2959 moveto
+1505 3150 1781 3271 conicto
+2057 3392 2347 3392 conicto
+2973 3392 3374 2937 conicto
+3776 2482 3776 1730 conicto
+3776 900 3374 418 conicto
+2973 -64 2347 -64 conicto
+1715 -64 1344 340 conicto
+1344 -1344 lineto
+448 -1344 lineto
+448 3328 lineto
+1344 3328 lineto
+1344 2959 lineto
+1344 1087 moveto
+1656 704 2133 704 conicto
+2459 704 2669 966 conicto
+2880 1229 2880 1678 conicto
+2880 2139 2666 2381 conicto
+2452 2624 2124 2624 conicto
+1679 2624 1344 2216 conicto
+1344 1087 lineto
+end_ol grestore
+gsave 17.477660 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+1344 0 moveto
+448 0 lineto
+448 4800 lineto
+1344 4800 lineto
+1344 0 lineto
+end_ol grestore
+gsave 17.719927 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+2013 3392 moveto
+2806 3392 3291 2934 conicto
+3776 2476 3776 1664 conicto
+3776 852 3291 394 conicto
+2806 -64 2013 -64 conicto
+1220 -64 738 394 conicto
+256 852 256 1664 conicto
+256 2479 738 2935 conicto
+1220 3392 2013 3392 conicto
+2013 704 moveto
+2407 704 2643 965 conicto
+2880 1226 2880 1664 conicto
+2880 2105 2646 2364 conicto
+2413 2624 2013 2624 conicto
+1599 2624 1375 2372 conicto
+1152 2121 1152 1664 conicto
+1152 1219 1377 961 conicto
+1602 704 2013 704 conicto
+end_ol grestore
+gsave 18.254427 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+2624 3264 moveto
+2464 2496 lineto
+2324 2560 2171 2560 conicto
+1997 2560 1837 2458 conicto
+1677 2357 1510 2106 conicto
+1344 1856 1344 1810 conicto
+1344 0 lineto
+448 0 lineto
+448 3328 lineto
+1344 3328 lineto
+1344 2688 lineto
+1529 3075 1724 3233 conicto
+1920 3392 2197 3392 conicto
+2452 3392 2624 3264 conicto
+end_ol grestore
+gsave 18.594102 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+3392 384 moveto
+2820 -64 2078 -64 conicto
+1241 -64 748 410 conicto
+256 884 256 1670 conicto
+256 2444 699 2918 conicto
+1142 3392 1870 3392 conicto
+2541 3392 2966 2928 conicto
+3392 2465 3392 1632 conicto
+3392 1408 lineto
+1152 1408 lineto
+1200 1106 1461 905 conicto
+1722 704 2085 704 conicto
+2659 704 3232 1024 conicto
+3392 384 lineto
+2496 2048 moveto
+2459 2371 2281 2561 conicto
+2104 2752 1846 2752 conicto
+1575 2752 1382 2561 conicto
+1189 2371 1152 2048 conicto
+2496 2048 lineto
+end_ol grestore
+gsave 19.081142 16.646053 translate 0.035278 -0.035278 scale
+start_ol
+2624 3264 moveto
+2464 2496 lineto
+2324 2560 2171 2560 conicto
+1997 2560 1837 2458 conicto
+1677 2357 1510 2106 conicto
+1344 1856 1344 1810 conicto
+1344 0 lineto
+448 0 lineto
+448 3328 lineto
+1344 3328 lineto
+1344 2688 lineto
+1529 3075 1724 3233 conicto
+1920 3392 2197 3392 conicto
+2452 3392 2624 3264 conicto
+end_ol grestore
+0.100000 slw
+[] 0 sd
+[] 0 sd
+0 slc
+n 13.774800 18.765100 m 13.776400 18.765100 l s
+0.100000 slw
+[] 0 sd
+[] 0 sd
+0 slc
+0 slj
+0.100000 slw
+0 slc
+0 slj
+[] 0 sd
+1.000000 1.000000 1.000000 srgb
+n 23.946777 20.450000 m 27.333883 20.450000 l 27.801546 20.450000 28.180660 20.899306 28.180660 21.453553 c 28.180660 22.007801 27.801546 22.457107 27.333883 22.457107 c 23.946777 22.457107 l 23.479115 22.457107 23.100000 22.007801 23.100000 21.453553 c 23.100000 20.899306 23.479115 20.450000 23.946777 20.450000 c ef
+0.000000 0.000000 0.000000 srgb
+n 23.946777 20.450000 m 27.333883 20.450000 l 27.801546 20.450000 28.180660 20.899306 28.180660 21.453553 c 28.180660 22.007801 27.801546 22.457107 27.333883 22.457107 c 23.946777 22.457107 l 23.479115 22.457107 23.100000 22.007801 23.100000 21.453553 c 23.100000 20.899306 23.479115 20.450000 23.946777 20.450000 c s
+gsave 24.350330 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+2022 4800 moveto
+1003 0 lineto
+112 0 lineto
+1131 4800 lineto
+2022 4800 lineto
+end_ol grestore
+gsave 24.592597 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+3136 320 moveto
+2492 -64 1767 -64 conicto
+1095 -64 675 318 conicto
+256 700 256 1317 conicto
+256 2160 826 2776 conicto
+1396 3392 2206 3392 conicto
+2799 3392 3159 3055 conicto
+3520 2718 3520 2142 conicto
+3520 1994 3442 1472 conicto
+1216 1472 lineto
+1216 1076 1377 890 conicto
+1539 704 1883 704 conicto
+2366 704 2976 1024 conicto
+3136 320 lineto
+2688 2112 moveto
+2694 2166 2694 2194 conicto
+2694 2448 2561 2600 conicto
+2428 2752 2186 2752 conicto
+1916 2752 1685 2578 conicto
+1454 2405 1349 2112 conicto
+2688 2112 lineto
+end_ol grestore
+gsave 25.079638 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+704 3072 moveto
+994 3214 1360 3303 conicto
+1727 3392 2014 3392 conicto
+2700 3392 3021 3177 conicto
+3342 2962 3342 2511 conicto
+3342 2350 3313 2208 conicto
+3036 767 3014 631 conicto
+2992 496 2992 337 conicto
+2992 143 3072 0 conicto
+2163 0 lineto
+2098 119 2098 303 conicto
+2104 422 lineto
+1674 -64 1080 -64 conicto
+640 -64 384 190 conicto
+128 444 128 861 conicto
+128 1381 585 1683 conicto
+1042 1986 2417 2048 conicto
+2433 2109 lineto
+2465 2199 2465 2350 conicto
+2465 2505 2331 2596 conicto
+2198 2688 1950 2688 conicto
+1487 2688 864 2368 conicto
+704 3072 lineto
+2314 1536 moveto
+1525 1480 1242 1334 conicto
+960 1189 960 910 conicto
+960 793 1049 716 conicto
+1139 640 1261 640 conicto
+1581 640 1896 867 conicto
+2211 1094 2224 1155 conicto
+2314 1536 lineto
+end_ol grestore
+gsave 25.566678 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+4276 4864 moveto
+3243 0 lineto
+2352 0 lineto
+2424 340 lineto
+2256 170 1980 53 conicto
+1705 -64 1464 -64 conicto
+893 -64 574 282 conicto
+256 628 256 1263 conicto
+256 2132 785 2762 conicto
+1315 3392 2085 3392 conicto
+2698 3392 2986 2985 conicto
+3385 4864 lineto
+4276 4864 lineto
+2827 2241 moveto
+2611 2624 2163 2624 conicto
+1772 2624 1494 2237 conicto
+1216 1850 1216 1309 conicto
+1216 1011 1354 857 conicto
+1492 704 1716 704 conicto
+2179 704 2589 1113 conicto
+2827 2241 lineto
+end_ol grestore
+gsave 26.101177 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+3136 320 moveto
+2492 -64 1767 -64 conicto
+1095 -64 675 318 conicto
+256 700 256 1317 conicto
+256 2160 826 2776 conicto
+1396 3392 2206 3392 conicto
+2799 3392 3159 3055 conicto
+3520 2718 3520 2142 conicto
+3520 1994 3442 1472 conicto
+1216 1472 lineto
+1216 1076 1377 890 conicto
+1539 704 1883 704 conicto
+2366 704 2976 1024 conicto
+3136 320 lineto
+2688 2112 moveto
+2694 2166 2694 2194 conicto
+2694 2448 2561 2600 conicto
+2428 2752 2186 2752 conicto
+1916 2752 1685 2578 conicto
+1454 2405 1349 2112 conicto
+2688 2112 lineto
+end_ol grestore
+gsave 26.588217 21.646053 translate 0.035278 -0.035278 scale
+start_ol
+3008 3267 moveto
+2656 2496 lineto
+2542 2560 2381 2560 conicto
+2056 2560 1671 2148 conicto
+1397 1838 1343 1600 conicto
+1003 0 lineto
+112 0 lineto
+818 3328 lineto
+1709 3328 lineto
+1569 2666 lineto
+1843 3062 2081 3227 conicto
+2319 3392 2606 3392 conicto
+2866 3392 3008 3267 conicto
+end_ol grestore
+0.100000 slw
+[] 0 sd
+[] 0 sd
+0 slc
+0 slj
+0.100000 slw
+0 slc
+0 slj
+[] 0 sd
+1.000000 1.000000 1.000000 srgb
+n 19.824752 11.746000 m 24.329358 11.746000 l 24.951315 11.746000 25.455510 12.195306 25.455510 12.749553 c 25.455510 13.303801 24.951315 13.753107 24.329358 13.753107 c 19.824752 13.753107 l 19.202795 13.753107 18.698600 13.303801 18.698600 12.749553 c 18.698600 12.195306 19.202795 11.746000 19.824752 11.746000 c ef
+0.000000 0.000000 0.000000 srgb
+n 19.824752 11.746000 m 24.329358 11.746000 l 24.951315 11.746000 25.455510 12.195306 25.455510 12.749553 c 25.455510 13.303801 24.951315 13.753107 24.329358 13.753107 c 19.824752 13.753107 l 19.202795 13.753107 18.698600 13.303801 18.698600 12.749553 c 18.698600 12.195306 19.202795 11.746000 19.824752 11.746000 c s
+gsave 20.228305 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3584 117 moveto
+3584 -618 3122 -1013 conicto
+2661 -1408 1819 -1408 conicto
+1066 -1408 448 -960 conicto
+672 -320 lineto
+1237 -640 1796 -640 conicto
+2223 -640 2455 -448 conicto
+2688 -257 2688 101 conicto
+2688 320 lineto
+2291 -64 1690 -64 conicto
+1060 -64 658 392 conicto
+256 849 256 1626 conicto
+256 2444 661 2918 conicto
+1067 3392 1732 3392 conicto
+2000 3392 2261 3287 conicto
+2523 3183 2688 3008 conicto
+2688 3392 lineto
+3584 3392 lineto
+3584 117 lineto
+2688 1088 moveto
+2688 2240 lineto
+2372 2624 1907 2624 conicto
+1577 2624 1364 2362 conicto
+1152 2101 1152 1649 conicto
+1152 1202 1359 953 conicto
+1567 704 1907 704 conicto
+2358 704 2688 1088 conicto
+end_ol grestore
+gsave 20.762805 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3584 0 moveto
+2688 0 lineto
+2688 466 lineto
+2266 -64 1600 -64 conicto
+1071 -64 759 244 conicto
+448 553 448 1103 conicto
+448 3328 lineto
+1344 3328 lineto
+1344 1400 lineto
+1344 704 1861 704 conicto
+2324 704 2688 1216 conicto
+2688 3328 lineto
+3584 3328 lineto
+3584 0 lineto
+end_ol grestore
+gsave 21.297304 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3344 0 moveto
+2448 0 lineto
+2304 210 2304 384 conicto
+1860 -64 1237 -64 conicto
+780 -64 518 208 conicto
+256 480 256 928 conicto
+256 1254 429 1496 conicto
+603 1738 945 1885 conicto
+1288 2032 1766 2070 conicto
+2304 2112 lineto
+2304 2174 lineto
+2304 2752 1680 2752 conicto
+1488 2752 1171 2676 conicto
+854 2601 608 2496 conicto
+384 3136 lineto
+697 3247 1105 3319 conicto
+1514 3392 1831 3392 conicto
+2502 3392 2851 3071 conicto
+3200 2750 3200 2130 conicto
+3200 788 lineto
+3200 321 3344 0 conicto
+2304 1024 moveto
+2304 1600 lineto
+1763 1540 1634 1516 conicto
+1505 1493 1365 1412 conicto
+1225 1331 1156 1212 conicto
+1088 1093 1088 942 conicto
+1088 788 1186 682 conicto
+1284 576 1452 576 conicto
+1921 576 2304 1024 conicto
+end_ol grestore
+gsave 21.784344 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+2624 3264 moveto
+2464 2496 lineto
+2324 2560 2171 2560 conicto
+1997 2560 1837 2458 conicto
+1677 2357 1510 2106 conicto
+1344 1856 1344 1810 conicto
+1344 0 lineto
+448 0 lineto
+448 3328 lineto
+1344 3328 lineto
+1344 2688 lineto
+1529 3075 1724 3233 conicto
+1920 3392 2197 3392 conicto
+2452 3392 2624 3264 conicto
+end_ol grestore
+gsave 22.124020 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3584 0 moveto
+2688 0 lineto
+2688 347 lineto
+2284 -64 1684 -64 conicto
+1057 -64 656 391 conicto
+256 846 256 1601 conicto
+256 2428 656 2910 conicto
+1057 3392 1684 3392 conicto
+2317 3392 2688 2988 conicto
+2688 4800 lineto
+3584 4800 lineto
+3584 0 lineto
+2688 1113 moveto
+2688 2244 lineto
+2375 2624 1900 2624 conicto
+1574 2624 1363 2362 conicto
+1152 2101 1152 1649 conicto
+1152 1202 1359 953 conicto
+1567 704 1907 704 conicto
+2352 704 2688 1113 conicto
+end_ol grestore
+gsave 22.658520 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+894 4864 moveto
+1100 4864 1254 4712 conicto
+1408 4560 1408 4347 conicto
+1408 4141 1256 3990 conicto
+1104 3840 894 3840 conicto
+682 3840 533 3989 conicto
+384 4138 384 4347 conicto
+384 4563 533 4713 conicto
+682 4864 894 4864 conicto
+1344 0 moveto
+448 0 lineto
+448 3328 lineto
+1344 3328 lineto
+1344 0 lineto
+end_ol grestore
+gsave 22.900787 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3344 0 moveto
+2448 0 lineto
+2304 210 2304 384 conicto
+1860 -64 1237 -64 conicto
+780 -64 518 208 conicto
+256 480 256 928 conicto
+256 1254 429 1496 conicto
+603 1738 945 1885 conicto
+1288 2032 1766 2070 conicto
+2304 2112 lineto
+2304 2174 lineto
+2304 2752 1680 2752 conicto
+1488 2752 1171 2676 conicto
+854 2601 608 2496 conicto
+384 3136 lineto
+697 3247 1105 3319 conicto
+1514 3392 1831 3392 conicto
+2502 3392 2851 3071 conicto
+3200 2750 3200 2130 conicto
+3200 788 lineto
+3200 321 3344 0 conicto
+2304 1024 moveto
+2304 1600 lineto
+1763 1540 1634 1516 conicto
+1505 1493 1365 1412 conicto
+1225 1331 1156 1212 conicto
+1088 1093 1088 942 conicto
+1088 788 1186 682 conicto
+1284 576 1452 576 conicto
+1921 576 2304 1024 conicto
+end_ol grestore
+gsave 23.387827 12.942053 translate 0.035278 -0.035278 scale
+start_ol
+3584 0 moveto
+2688 0 lineto
+2688 1926 lineto
+2688 2624 2169 2624 conicto
+1708 2624 1344 2135 conicto
+1344 0 lineto
+448 0...
[truncated message content] |
|
From: <ga...@us...> - 2008-04-25 13:09:32
|
Revision: 1257
http://jason.svn.sourceforge.net/jason/?rev=1257&view=rev
Author: gauth
Date: 2008-04-25 06:09:27 -0700 (Fri, 25 Apr 2008)
Log Message:
-----------
Some new test-beds:
- all agents on a big cluster
- meeting of two big cluster
- conflict between two opponent team for the same cluster
- conflict between two opponent team for the same cluster in a corridor
Added Paths:
-----------
trunk/applications/jason-team/massim-server/conf/testBig.xml
trunk/applications/jason-team/massim-server/conf/testMeeting.xml
trunk/applications/jason-team/massim-server/conf/testOpposition.xml
trunk/applications/jason-team/massim-server/conf/testOppositionInCorridor.xml
Added: trunk/applications/jason-team/massim-server/conf/testBig.xml
===================================================================
--- trunk/applications/jason-team/massim-server/conf/testBig.xml (rev 0)
+++ trunk/applications/jason-team/massim-server/conf/testBig.xml 2008-04-25 13:09:27 UTC (rev 1257)
@@ -0,0 +1,226 @@
+<?xml version="1.0" encoding="utf-8"?>
+<conf tournamentname="GridSimulation" tournamentmode="0"
+ launch-sync-type="key" time-to-launch="10000" reportpath="."
+ backuppath="backup">
+ <network-agent port="12300" backlog="10" />
+ <match>
+ <simulation id="Test big cluster"
+ simulationclass="massim.simulation.GridSimulation"
+ configurationclass="massim.simulation.GridSimulationConfigurationHandCrafted"
+ rmiobserver="massim.simulation.GridSimulationRMIObserver"
+ xmlobserver="massim.simulation.GridSimulationXMLObserver"
+ rmixmlobserver="massim.simulation.GridSimulationRMIXMLDocumentObserver"
+ xmlobserverpath="."
+ xmlstatisticsobserver="massim.simulation.GridSimulationXMLStatisticsObserver"
+ file-simulationlog="./log" visualisationobserver="">
+
+
+ <!-- visualisationobserver="massim.simulation.GridSimulationVisualizationObserver" -->
+
+ <configuration xmlns:meta="http://www.tu-clausthal.de/"
+ sizex="70" sizey="70" maxNumberOfSteps="700" numberOfAgents="12"
+ numberOfObstacles="0" numberOfCows="80" cowSpeed="1"
+ agentSpeed="1" lineOfSight="17" fearRange="4" attractionRange="5"
+ cowWeight="5" agentWeight="-200" emptyWeight="1" obstacleWeight="-1"
+ htaccess="1">
+
+ <array item0="18" item1="18" item2="18" item3="18"
+ item4="18" item5="18" item6="1" item7="1" item8="2" item9="2"
+ item10="3" item11="3" meta:length="12"
+ meta:name="agentPositionY" />
+ <array item0="12" item1="18" item2="24" item3="30"
+ item4="36" item5="40" item6="69" item7="68" item8="69" item9="68"
+ item10="69" item11="68" meta:length="12"
+ meta:name="agentPositionX" />
+
+ <array item0="25" item1="28" item2="22" item3="21"
+ item4="26" item5="25" item6="27" item7="22" item8="24" item9="23"
+ item10="25" item11="28" item12="22" item13="21"
+ item14="26" item15="25" item16="27" item17="22" item18="24" item19="23"
+ item20="30" item21="33" item22="27" item23="26"
+ item24="31" item25="30" item26="32" item27="27" item28="29" item29="28"
+ item30="30" item31="33" item32="27" item33="26"
+ item34="31" item35="30" item36="32" item37="27" item38="29" item39="28"
+ item40="25" item41="28" item42="22" item43="21"
+ item44="26" item45="25" item46="27" item47="22" item48="24" item49="23"
+ item50="25" item51="28" item52="22" item53="21"
+ item54="26" item55="25" item56="27" item57="22" item58="24" item59="23"
+ item60="30" item61="33" item62="27" item63="26"
+ item64="31" item65="30" item66="32" item67="27" item68="29" item69="28"
+ item70="30" item71="33" item72="27" item73="26"
+ item74="31" item75="30" item76="32" item77="27" item78="29" item79="28"
+ meta:length="80"
+ meta:name="cowPositionY" />
+
+
+ <array item0="12" item1="13" item2="14" item3="15"
+ item4="16" item5="17" item6="18" item7="19" item8="11" item9="15"
+ item10="19" item11="20" item12="21" item13="22"
+ item14="23" item15="24" item16="25" item17="26" item18="18" item19="22"
+ item20="12" item21="13" item22="14" item23="15"
+ item24="16" item25="17" item26="18" item27="19" item28="11" item29="15"
+ item30="19" item31="20" item32="21" item33="22"
+ item34="23" item35="24" item36="25" item37="26" item38="18" item39="22"
+ item40="27" item41="28" item42="29" item43="30"
+ item44="31" item45="32" item46="33" item47="34" item48="26" item49="30"
+ item50="34" item51="35" item52="36" item53="37"
+ item54="38" item55="39" item56="40" item57="41" item58="33" item59="37"
+ item60="27" item61="28" item62="29" item63="30"
+ item64="31" item65="32" item66="33" item67="34" item68="26" item69="30"
+ item70="34" item71="35" item72="36" item73="37"
+ item74="38" item75="39" item76="40" item77="41" item78="33" item79="37"
+ meta:length="80"
+ meta:name="cowPositionX" />
+
+ <array item0="29" item1="38" meta:length="2"
+ meta:name="stable1X" />
+ <array item0="59" item1="69" meta:length="2"
+ meta:name="stable1Y" />
+ <array item0="55" item1="69" meta:length="2"
+ meta:name="stable2X" />
+ <array item0="0" item1="14" meta:length="2"
+ meta:name="stable2Y" />
+
+ <array meta:length="0" meta:name="obstaclePositionY" />
+
+ <array meta:length="0"
+ meta:name="obstaclePositionX" />
+ </configuration>
+
+ <agents>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ </agents>
+ </simulation>
+
+ </match>
+
+ <accounts>
+ <actionclassmap name="Grid">
+ <actionclass id="action"
+ class="massim.simulation.GridSimulationAgentAction" />
+ <actionclass id="invalid" class="massim.InvalidAction" />
+ </actionclassmap>
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent1" password="1" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent2" password="2" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent3" password="3" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent4" password="4" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent5" password="5" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent6" password="6" team="bot" />
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant1" password="1" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant2" password="2" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant3" password="3" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant4" password="4" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant5" password="5" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant6" password="6" team="participant" />
+
+ </accounts>
+</conf>
Added: trunk/applications/jason-team/massim-server/conf/testMeeting.xml
===================================================================
--- trunk/applications/jason-team/massim-server/conf/testMeeting.xml (rev 0)
+++ trunk/applications/jason-team/massim-server/conf/testMeeting.xml 2008-04-25 13:09:27 UTC (rev 1257)
@@ -0,0 +1,226 @@
+<?xml version="1.0" encoding="utf-8"?>
+<conf tournamentname="GridSimulation" tournamentmode="0"
+ launch-sync-type="key" time-to-launch="10000" reportpath="."
+ backuppath="backup">
+ <network-agent port="12300" backlog="10" />
+ <match>
+ <simulation id="Test meeting of two big clusters"
+ simulationclass="massim.simulation.GridSimulation"
+ configurationclass="massim.simulation.GridSimulationConfigurationHandCrafted"
+ rmiobserver="massim.simulation.GridSimulationRMIObserver"
+ xmlobserver="massim.simulation.GridSimulationXMLObserver"
+ rmixmlobserver="massim.simulation.GridSimulationRMIXMLDocumentObserver"
+ xmlobserverpath="."
+ xmlstatisticsobserver="massim.simulation.GridSimulationXMLStatisticsObserver"
+ file-simulationlog="./log" visualisationobserver="">
+
+
+ <!-- visualisationobserver="massim.simulation.GridSimulationVisualizationObserver" -->
+
+ <configuration xmlns:meta="http://www.tu-clausthal.de/"
+ sizex="70" sizey="70" maxNumberOfSteps="700" numberOfAgents="12"
+ numberOfObstacles="0" numberOfCows="80" cowSpeed="1"
+ agentSpeed="1" lineOfSight="17" fearRange="4" attractionRange="5"
+ cowWeight="5" agentWeight="-200" emptyWeight="1" obstacleWeight="-1"
+ htaccess="1">
+
+ <array item0="20" item1="21" item2="20" item3="24"
+ item4="25" item5="24" item6="1" item7="1" item8="1" item9="2"
+ item10="2" item11="2" meta:length="12"
+ meta:name="agentPositionY" />
+ <array item0="27" item1="30" item2="24" item3="41"
+ item4="44" item5="37" item6="67" item7="68" item8="69" item9="67"
+ item10="68" item11="69" meta:length="12"
+ meta:name="agentPositionX" />
+
+ <array item0="25" item1="28" item2="22" item3="21"
+ item4="26" item5="25" item6="27" item7="22" item8="24" item9="23"
+ item10="25" item11="28" item12="22" item13="21"
+ item14="26" item15="25" item16="27" item17="22" item18="24" item19="23"
+ item20="30" item21="33" item22="27" item23="26"
+ item24="31" item25="30" item26="32" item27="27" item28="29" item29="28"
+ item30="30" item31="33" item32="27" item33="26"
+ item34="31" item35="30" item36="32" item37="27" item38="29" item39="28"
+ item40="40" item41="33" item42="27" item43="31"
+ item44="41" item45="30" item46="32" item47="27" item48="29" item49="28"
+ item50="25" item51="38" item52="42" item53="31"
+ item54="36" item55="35" item56="37" item57="32" item58="34" item59="33"
+ item60="30" item61="33" item62="27" item63="26"
+ item64="31" item65="30" item66="32" item67="27" item68="29" item69="28"
+ item70="35" item71="38" item72="42" item73="31"
+ item74="36" item75="35" item76="37" item77="32" item78="34" item79="33"
+ meta:length="80"
+ meta:name="cowPositionY" />
+
+
+ <array item0="12" item1="13" item2="14" item3="15"
+ item4="16" item5="17" item6="18" item7="19" item8="11" item9="15"
+ item10="19" item11="20" item12="21" item13="22"
+ item14="23" item15="24" item16="25" item17="26" item18="18" item19="22"
+ item20="12" item21="13" item22="14" item23="15"
+ item24="16" item25="17" item26="18" item27="19" item28="11" item29="15"
+ item30="19" item31="20" item32="21" item33="22"
+ item34="23" item35="24" item36="25" item37="26" item38="18" item39="22"
+ item40="32" item41="33" item42="34" item43="35"
+ item44="36" item45="37" item46="38" item47="39" item48="31" item49="35"
+ item50="32" item51="33" item52="34" item53="35"
+ item54="36" item55="37" item56="38" item57="39" item58="31" item59="35"
+ item60="27" item61="28" item62="29" item63="30"
+ item64="31" item65="32" item66="33" item67="34" item68="26" item69="30"
+ item70="27" item71="28" item72="29" item73="30"
+ item74="31" item75="32" item76="33" item77="34" item78="26" item79="30"
+ meta:length="80"
+ meta:name="cowPositionX" />
+
+ <array item0="0" item1="14" meta:length="2"
+ meta:name="stable1X" />
+ <array item0="55" item1="69" meta:length="2"
+ meta:name="stable1Y" />
+ <array item0="55" item1="69" meta:length="2"
+ meta:name="stable2X" />
+ <array item0="0" item1="14" meta:length="2"
+ meta:name="stable2Y" />
+
+ <array meta:length="0" meta:name="obstaclePositionX" />
+
+ <array meta:length="0"
+ meta:name="obstaclePositionY" />
+ </configuration>
+
+ <agents>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ </agents>
+ </simulation>
+
+ </match>
+
+ <accounts>
+ <actionclassmap name="Grid">
+ <actionclass id="action"
+ class="massim.simulation.GridSimulationAgentAction" />
+ <actionclass id="invalid" class="massim.InvalidAction" />
+ </actionclassmap>
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent1" password="1" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent2" password="2" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent3" password="3" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent4" password="4" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent5" password="5" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent6" password="6" team="bot" />
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant1" password="1" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant2" password="2" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant3" password="3" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant4" password="4" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant5" password="5" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant6" password="6" team="participant" />
+
+ </accounts>
+</conf>
Added: trunk/applications/jason-team/massim-server/conf/testOpposition.xml
===================================================================
--- trunk/applications/jason-team/massim-server/conf/testOpposition.xml (rev 0)
+++ trunk/applications/jason-team/massim-server/conf/testOpposition.xml 2008-04-25 13:09:27 UTC (rev 1257)
@@ -0,0 +1,206 @@
+<?xml version="1.0" encoding="utf-8"?>
+<conf tournamentname="GridSimulation" tournamentmode="0"
+ launch-sync-type="key" time-to-launch="10000" reportpath="."
+ backuppath="backup">
+ <network-agent port="12300" backlog="10" />
+ <match>
+ <simulation id="Test opposition to another team: conflict on a cluster"
+ simulationclass="massim.simulation.GridSimulation"
+ configurationclass="massim.simulation.GridSimulationConfigurationHandCrafted"
+ rmiobserver="massim.simulation.GridSimulationRMIObserver"
+ xmlobserver="massim.simulation.GridSimulationXMLObserver"
+ rmixmlobserver="massim.simulation.GridSimulationRMIXMLDocumentObserver"
+ xmlobserverpath="."
+ xmlstatisticsobserver="massim.simulation.GridSimulationXMLStatisticsObserver"
+ file-simulationlog="./log" visualisationobserver="">
+
+
+ <!-- visualisationobserver="massim.simulation.GridSimulationVisualizationObserver" -->
+
+ <configuration xmlns:meta="http://www.tu-clausthal.de/"
+ sizex="70" sizey="70" maxNumberOfSteps="700" numberOfAgents="12"
+ numberOfObstacles="0" numberOfCows="36" cowSpeed="1"
+ agentSpeed="1" lineOfSight="17" fearRange="4" attractionRange="5"
+ cowWeight="5" agentWeight="-200" emptyWeight="1" obstacleWeight="-1"
+ htaccess="1">
+
+ <array item0="30" item1="30" item2="30" item3="69"
+ item4="69" item5="69" item6="39" item7="39" item8="39" item9="1"
+ item10="1" item11="1" meta:length="12"
+ meta:name="agentPositionY" />
+ <array item0="32" item1="35" item2="37" item3="34"
+ item4="35" item5="36" item6="32" item7="36" item8="37" item9="34"
+ item10="35" item11="36" meta:length="12"
+ meta:name="agentPositionX" />
+
+ <array item0="32" item1="32" item2="32" item3="32" item4="32" item5="32"
+ item6="33" item7="33" item8="33" item9="33" item10="33" item11="33"
+ item12="34" item13="34" item14="34" item15="34" item16="34" item17="34"
+ item18="35" item19="35" item20="35" item21="35" item22="35" item23="35"
+ item24="36" item25="36" item26="36" item27="36" item28="36" item29="36"
+ item30="37" item31="37" item32="37" item33="37" item34="37" item35="37"
+ meta:length="36"
+ meta:name="cowPositionY" />
+
+
+ <array item0="32" item1="33" item2="34" item3="35" item4="36" item5="37"
+ item6="32" item7="33" item8="34" item9="35" item10="36" item11="37"
+ item12="32" item13="33" item14="34" item15="35" item16="36" item17="37"
+ item18="32" item19="33" item20="34" item21="35" item22="36" item23="37"
+ item24="32" item25="33" item26="34" item27="35" item28="36" item29="37"
+ item30="32" item31="33" item32="34" item33="35" item34="36" item35="37"
+ meta:length="36"
+ meta:name="cowPositionX" />
+
+ <array item0="32" item1="37" meta:length="2"
+ meta:name="stable1X" />
+ <array item0="63" item1="69" meta:length="2"
+ meta:name="stable1Y" />
+ <array item0="32" item1="37" meta:length="2"
+ meta:name="stable2X" />
+ <array item0="0" item1="6" meta:length="2"
+ meta:name="stable2Y" />
+
+ <array meta:length="0" meta:name="obstaclePositionX" />
+
+ <array meta:length="0"
+ meta:name="obstaclePositionY" />
+ </configuration>
+
+ <agents>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ </agents>
+ </simulation>
+
+ </match>
+
+ <accounts>
+ <actionclassmap name="Grid">
+ <actionclass id="action"
+ class="massim.simulation.GridSimulationAgentAction" />
+ <actionclass id="invalid" class="massim.InvalidAction" />
+ </actionclassmap>
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent1" password="1" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent2" password="2" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent3" password="3" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent4" password="4" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent5" password="5" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent6" password="6" team="bot" />
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant1" password="1" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant2" password="2" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant3" password="3" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant4" password="4" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant5" password="5" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant6" password="6" team="participant" />
+
+ </accounts>
+</conf>
Added: trunk/applications/jason-team/massim-server/conf/testOppositionInCorridor.xml
===================================================================
--- trunk/applications/jason-team/massim-server/conf/testOppositionInCorridor.xml (rev 0)
+++ trunk/applications/jason-team/massim-server/conf/testOppositionInCorridor.xml 2008-04-25 13:09:27 UTC (rev 1257)
@@ -0,0 +1,241 @@
+<?xml version="1.0" encoding="utf-8"?>
+<conf tournamentname="GridSimulation" tournamentmode="0"
+ launch-sync-type="key" time-to-launch="10000" reportpath="."
+ backuppath="backup">
+ <network-agent port="12300" backlog="10" />
+ <match>
+ <simulation id="Test opposition to another team in a corridor: conflict on a cluster"
+ simulationclass="massim.simulation.GridSimulation"
+ configurationclass="massim.simulation.GridSimulationConfigurationHandCrafted"
+ rmiobserver="massim.simulation.GridSimulationRMIObserver"
+ xmlobserver="massim.simulation.GridSimulationXMLObserver"
+ rmixmlobserver="massim.simulation.GridSimulationRMIXMLDocumentObserver"
+ xmlobserverpath="."
+ xmlstatisticsobserver="massim.simulation.GridSimulationXMLStatisticsObserver"
+ file-simulationlog="./log" visualisationobserver="">
+
+
+ <!-- visualisationobserver="massim.simulation.GridSimulationVisualizationObserver" -->
+
+ <configuration xmlns:meta="http://www.tu-clausthal.de/"
+ sizex="70" sizey="70" maxNumberOfSteps="700" numberOfAgents="12"
+ numberOfObstacles="32" numberOfCows="36" cowSpeed="1"
+ agentSpeed="1" lineOfSight="17" fearRange="4" attractionRange="5"
+ cowWeight="5" agentWeight="-200" emptyWeight="1" obstacleWeight="-1"
+ htaccess="1">
+
+ <array item0="30" item1="30" item2="30" item3="69"
+ item4="69" item5="69" item6="39" item7="39" item8="39" item9="1"
+ item10="1" item11="1" meta:length="12"
+ meta:name="agentPositionY" />
+ <array item0="32" item1="35" item2="37" item3="34"
+ item4="35" item5="36" item6="32" item7="36" item8="37" item9="34"
+ item10="35" item11="36" meta:length="12"
+ meta:name="agentPositionX" />
+
+ <array item0="32" item1="32" item2="32" item3="32" item4="32" item5="32"
+ item6="33" item7="33" item8="33" item9="33" item10="33" item11="33"
+ item12="34" item13="34" item14="34" item15="34" item16="34" item17="34"
+ item18="35" item19="35" item20="35" item21="35" item22="35" item23="35"
+ item24="36" item25="36" item26="36" item27="36" item28="36" item29="36"
+ item30="37" item31="37" item32="37" item33="37" item34="37" item35="37"
+ meta:length="36"
+ meta:name="cowPositionY" />
+
+
+ <array item0="32" item1="33" item2="34" item3="35" item4="36" item5="37"
+ item6="32" item7="33" item8="34" item9="35" item10="36" item11="37"
+ item12="32" item13="33" item14="34" item15="35" item16="36" item17="37"
+ item18="32" item19="33" item20="34" item21="35" item22="36" item23="37"
+ item24="32" item25="33" item26="34" item27="35" item28="36" item29="37"
+ item30="32" item31="33" item32="34" item33="35" item34="36" item35="37"
+ meta:length="36"
+ meta:name="cowPositionX" />
+
+ <array item0="32" item1="37" meta:length="2"
+ meta:name="stable1X" />
+ <array item0="63" item1="69" meta:length="2"
+ meta:name="stable1Y" />
+ <array item0="32" item1="37" meta:length="2"
+ meta:name="stable2X" />
+ <array item0="0" item1="6" meta:length="2"
+ meta:name="stable2Y" />
+
+ <array
+ item0="30" item1="39"
+ item2="30" item3="39"
+ item4="30" item5="39"
+ item6="30" item7="39"
+ item8="30" item9="39"
+ item10="30" item11="39"
+ item12="30" item13="39"
+ item14="30" item15="39"
+ item16="30" item17="39"
+ item18="30" item19="39"
+ item20="30" item21="39"
+ item22="30" item23="39"
+ item24="30" item25="39"
+ item26="30" item27="39"
+ item28="30" item29="39"
+ item30="30" item31="39"
+ meta:length="32"
+ meta:name="obstaclePositionX" />
+
+ <array
+ item0="43" item1="43"
+ item2="28" item3="28"
+ item4="29" item5="29"
+ item6="30" item7="30"
+ item8="31" item9="31"
+ item10="32" item11="32"
+ item12="33" item13="33"
+ item14="34" item15="34"
+ item16="35" item17="35"
+ item18="36" item19="36"
+ item20="37" item21="37"
+ item22="38" item23="38"
+ item24="39" item25="39"
+ item26="40" item27="40"
+ item28="41" item29="41"
+ item30="42" item31="42"
+ meta:length="32"
+ meta:name="obstaclePositionY" />
+ </configuration>
+
+ <agents>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="blue">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ <agent
+ agentclass="massim.simulation.GridSimulationAgent"
+ agentcreationclass="massim.simulation.GridSimulationAgentParameter"
+ team="red">
+ <configuration />
+ </agent>
+ </agents>
+ </simulation>
+
+ </match>
+
+ <accounts>
+ <actionclassmap name="Grid">
+ <actionclass id="action"
+ class="massim.simulation.GridSimulationAgentAction" />
+ <actionclass id="invalid" class="massim.InvalidAction" />
+ </actionclassmap>
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent1" password="1" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent2" password="2" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent3" password="3" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent4" password="4" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent5" password="5" team="bot" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="botagent6" password="6" team="bot" />
+
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant1" password="1" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant2" password="2" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant3" password="3" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant4" password="4" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant5" password="5" team="participant" />
+ <account actionclassmap="Grid"
+ defaultactionclass="massim.simulation.GridSimulationAgentAction"
+ timeout="8000" auxtimeout="500" maxpacketlength="65536"
+ username="participant6" password="6" team="participant" />
+
+ </accounts>
+</conf>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|