eos.simulation
Class Simulation

java.lang.Object
  extended by eos.simulation.Simulation

public class Simulation
extends java.lang.Object

Guidelines for creating a simulation

Please follow the steps below. The order is important.

1. Create the markets and add them into the economy. The markets need to be created first because the constructors of the agents reference the markets. Here is an example of creating a labor market and adding it to the economy.

LaborMarket lMkt = new LaborMarket();
Economy.addMarket(lMkt);

2. Create the firms. Capital firms need to be created before other firms, because the constructors of consumer goods firms require reference to an array of capital firms.

3. Add the firms to the economy. For instance, here is how to add the X firms:

for (int i = 0; i < NUM_XFIRMS; i++) Economy.addAgent(XFirms[i]);

4. Create laborers and add them to the economy.

5. Clear the labor market by calling lMkt.clear(). This is to allow // forget this for now firms to get labor before the start of the first time step.

6. Note: eos.io.printer has been removed; printing for tracing, debugging, and graphing is now done through the simpler eos.io.trace

7. Run the simulation by calling Economy.run(NUM_STEP).


Field Summary
static int CAPITAL_LIFE
           
static double CFIRM_INIT_CAPITAL_PRICE
           
static double CGDEMAND_TC
           
static double CGSUPPLY_TC
           
static double CPI_TC
           
static double DEFAULT_TC
           
static double DELTA_TC
           
static double EPSILON
           
static double INFLATION_TC
           
static double IR_TC
           
static double LOAN_IR_TC
           
static int MACHINE_LABOR_NEEDED
           
static double PROFIT_TC
           
static double SUBACCOUNT_TC
           
static double WAGE_TC
           
 
Constructor Summary
Simulation()
           
 
Method Summary
static java.lang.String getAgentName(int ID)
          Return name of agent given ID
static double getINIT_ESTIMATED_OCG_PRICE()
          Return INIT_ESTIMATED_OCG_PRICE
static double getLABORER_INIT_WAGE()
          Return LABORER_INIT_WAGE
static double getNUM_LABORERS()
          Return NUM_LABORERS
static void main(java.lang.String[] args)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

EPSILON

public static final double EPSILON
See Also:
Constant Field Values

DEFAULT_TC

public static final double DEFAULT_TC
See Also:
Constant Field Values

PROFIT_TC

public static final double PROFIT_TC
See Also:
Constant Field Values

IR_TC

public static final double IR_TC
See Also:
Constant Field Values

DELTA_TC

public static final double DELTA_TC
See Also:
Constant Field Values

SUBACCOUNT_TC

public static final double SUBACCOUNT_TC
See Also:
Constant Field Values

CPI_TC

public static final double CPI_TC
See Also:
Constant Field Values

INFLATION_TC

public static final double INFLATION_TC
See Also:
Constant Field Values

WAGE_TC

public static final double WAGE_TC
See Also:
Constant Field Values

CGDEMAND_TC

public static final double CGDEMAND_TC
See Also:
Constant Field Values

CGSUPPLY_TC

public static final double CGSUPPLY_TC
See Also:
Constant Field Values

LOAN_IR_TC

public static final double LOAN_IR_TC
See Also:
Constant Field Values

CAPITAL_LIFE

public static final int CAPITAL_LIFE
See Also:
Constant Field Values

MACHINE_LABOR_NEEDED

public static final int MACHINE_LABOR_NEEDED
See Also:
Constant Field Values

CFIRM_INIT_CAPITAL_PRICE

public static final double CFIRM_INIT_CAPITAL_PRICE
See Also:
Constant Field Values
Constructor Detail

Simulation

public Simulation()
Method Detail

main

public static void main(java.lang.String[] args)

getLABORER_INIT_WAGE

public static double getLABORER_INIT_WAGE()
Return LABORER_INIT_WAGE

Returns:
laborer initial wage

getAgentName

public static java.lang.String getAgentName(int ID)
Return name of agent given ID

Returns:
name of agent given ID

getINIT_ESTIMATED_OCG_PRICE

public static double getINIT_ESTIMATED_OCG_PRICE()
Return INIT_ESTIMATED_OCG_PRICE

Returns:
initial estimated OCG price

getNUM_LABORERS

public static double getNUM_LABORERS()
Return NUM_LABORERS

Returns:
NUM_LABORERS