package sesionMDP;

import aima.core.environment.cellworld.*;

/**
 * @author L. Mandow
 * Adaptado del original de AIMA:
 * @author Ciaran O'Reilly
 * 
 */
public class PracticaCellWorldFactory {

	/**
	 * Create the cell world as defined in Figure 17.1 in AIMA3e. (a) A simple 4
	 * x 3 environment that presents the agent with a sequential decision
	 * problem.
	 * 
	 * @return a cell world representation of Fig 17.1 in AIMA3e.
	 */
	public static CellWorld<Double> createCellWorldForFig17_1() {
		CellWorld<Double> cw = new CellWorld<Double>(4, 3, -0.04);

		cw.removeCell(2, 2);

		cw.getCellAt(4, 3).setContent(1.0);
		cw.getCellAt(4, 2).setContent(-1.0);

		return cw;
	}
	
	/**
	 * Crear aqu el "cell world" de la prctica
	 * 
	 * @return una representacin del "cell world" de la prctica.
	 */
	// public static CellWorld<Double> createCellWorldPractica() {	}
	public static CellWorld<Double> createCellWorldPractica(){
		CellWorld<Double> cw = new CellWorld<Double>(4,3,-0.02);
		
		cw.removeCell(2,2);
		cw.getCellAt(1,1).setContent(-0.06);
		cw.getCellAt(1,2).setContent(-0.06);
		cw.getCellAt(1,3).setContent(-0.06);
		cw.getCellAt(2,1).setContent(-0.04);
		cw.getCellAt(2,3).setContent(-0.04);
		cw.getCellAt(4,3).setContent(1.0);
		cw.getCellAt(4,2).setContent(-1.0);
		
		
		return cw;
	}
}

@@ -81,16 +81,41 @@
  Mandow%0A
+ * @author I.Lasaosa%0A * %0A
  * Adapt
@@ -173,13 +173,11 @@
 y%0A *
- 
+/
 %0A 
-*/
 %0Apub
@@ -717,16 +717,17 @@
 rear aqu
+%EF%BF%BD
  el %22cel
@@ -739,24 +739,25 @@
 ld%22 de la pr
+%EF%BF%BD
 ctica%0A%09 * %0A%09
@@ -783,16 +783,17 @@
 esentaci
+%EF%BF%BD
 n del %22c
@@ -811,16 +811,17 @@
 de la pr
+%EF%BF%BD
 ctica.%0A%09

Update PracticaCellWorldFactory.java