From 50f50413b003d78398fd967f8f0aeac81df1a586 Mon Sep 17 00:00:00 2001 From: Keller Kevin Date: Tue, 23 Apr 2019 15:01:14 +0200 Subject: [PATCH] Updated version number and documentation --- doc/activity/Activity.html | 4 +- doc/activity/class-use/Activity.html | 33 +- doc/activity/package-frame.html | 4 +- doc/activity/package-summary.html | 4 +- doc/activity/package-tree.html | 4 +- doc/activity/package-use.html | 4 +- doc/agent/Farm.html | 257 ++++++---- doc/agent/Location.html | 4 +- doc/agent/Person.html | 4 +- doc/agent/class-use/Farm.html | 36 +- doc/agent/class-use/Location.html | 11 +- doc/agent/class-use/Person.html | 11 +- doc/agent/package-frame.html | 4 +- doc/agent/package-summary.html | 4 +- doc/agent/package-tree.html | 4 +- doc/agent/package-use.html | 4 +- doc/allclasses-frame.html | 5 +- doc/allclasses-noframe.html | 5 +- doc/constant-values.html | 33 +- doc/deprecated-list.html | 4 +- doc/fuzzy_logic/FuzzyLogicCalculator.html | 4 +- .../class-use/FuzzyLogicCalculator.html | 4 +- doc/fuzzy_logic/package-frame.html | 4 +- doc/fuzzy_logic/package-summary.html | 4 +- doc/fuzzy_logic/package-tree.html | 4 +- doc/fuzzy_logic/package-use.html | 4 +- doc/help-doc.html | 4 +- doc/index-files/index-1.html | 8 +- doc/index-files/index-10.html | 8 +- doc/index-files/index-11.html | 8 +- doc/index-files/index-12.html | 31 +- doc/index-files/index-13.html | 65 +-- doc/index-files/index-14.html | 174 ++----- doc/index-files/index-15.html | 172 +++++-- doc/index-files/index-16.html | 24 +- doc/index-files/index-17.html | 52 ++- doc/index-files/index-18.html | 133 ++++++ doc/index-files/index-2.html | 8 +- doc/index-files/index-3.html | 12 +- doc/index-files/index-4.html | 8 +- doc/index-files/index-5.html | 8 +- doc/index-files/index-6.html | 12 +- doc/index-files/index-7.html | 16 +- doc/index-files/index-8.html | 12 +- doc/index-files/index-9.html | 10 +- doc/index.html | 2 +- doc/logging/ABMActivityLog.html | 4 +- doc/logging/ABMTimeStepLog.html | 4 +- doc/logging/class-use/ABMActivityLog.html | 4 +- doc/logging/class-use/ABMTimeStepLog.html | 4 +- doc/logging/package-frame.html | 4 +- doc/logging/package-summary.html | 4 +- doc/logging/package-tree.html | 4 +- doc/logging/package-use.html | 4 +- doc/main/Consumat.html | 4 +- doc/main/class-use/Consumat.html | 4 +- doc/main/package-frame.html | 4 +- doc/main/package-summary.html | 4 +- doc/main/package-tree.html | 4 +- doc/main/package-use.html | 4 +- doc/mathematical_programming/FactoryMP.html | 4 +- doc/mathematical_programming/FarmDyn.html | 4 +- .../MP_Interface.html | 6 +- doc/mathematical_programming/SwissLand.html | 8 +- doc/mathematical_programming/Toy.html | 438 ++++++++++++++++++ doc/mathematical_programming/WeedControl.html | 8 +- .../class-use/FactoryMP.html | 4 +- .../class-use/FarmDyn.html | 4 +- .../class-use/MP_Interface.html | 10 +- .../class-use/SwissLand.html | 4 +- .../class-use/Toy.html | 124 +++++ .../class-use/WeedControl.html | 4 +- .../package-frame.html | 5 +- .../package-summary.html | 10 +- .../package-tree.html | 5 +- doc/mathematical_programming/package-use.html | 4 +- doc/overview-frame.html | 4 +- doc/overview-summary.html | 4 +- doc/overview-tree.html | 5 +- doc/reader/FarmDataMatrix.html | 4 +- doc/reader/ReadData.html | 69 ++- doc/reader/class-use/FarmDataMatrix.html | 11 +- doc/reader/class-use/ReadData.html | 4 +- doc/reader/package-frame.html | 4 +- doc/reader/package-summary.html | 4 +- doc/reader/package-tree.html | 4 +- doc/reader/package-use.html | 4 +- src/agent/Farm.java | 3 + src/main/Consumat.java | 5 +- 89 files changed, 1494 insertions(+), 559 deletions(-) create mode 100644 doc/index-files/index-18.html create mode 100644 doc/mathematical_programming/Toy.html create mode 100644 doc/mathematical_programming/class-use/Toy.html diff --git a/doc/activity/Activity.html b/doc/activity/Activity.html index 5f25007a..32dbf154 100644 --- a/doc/activity/Activity.html +++ b/doc/activity/Activity.html @@ -2,9 +2,9 @@ - + Activity - + diff --git a/doc/activity/class-use/Activity.html b/doc/activity/class-use/Activity.html index 6d037b96..571016d1 100644 --- a/doc/activity/class-use/Activity.html +++ b/doc/activity/class-use/Activity.html @@ -2,9 +2,9 @@ - + Uses of Class activity.Activity - + @@ -164,7 +164,7 @@

Uses of Act -Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -185,12 +185,15 @@

Uses of Act double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
This constructor sets up the parameters associated with a farm.
-
Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -211,7 +214,10 @@

Uses of Act double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
This constructor sets up the parameters associated with a farm.
@@ -331,23 +337,32 @@

Uses of Act java.util.ArrayList<Activity> -SwissLand.getExitActivity()  +Toy.getExitActivity()  java.util.ArrayList<Activity> +SwissLand.getExitActivity()  + + +java.util.ArrayList<Activity> MP_Interface.getExitActivity()
If agent leaves system then we set an exit activity.
- + java.util.ArrayList<Activity> FarmDyn.getExitActivity()  - + java.util.List<java.util.ArrayList<Activity>> WeedControl.readMPActivities(java.util.Properties cmd, java.util.List<Farm> allFarms)  + +java.util.List<java.util.ArrayList<Activity>> +Toy.readMPActivities(java.util.Properties cmd, + java.util.List<Farm> allFarms)  + java.util.List<java.util.ArrayList<Activity>> SwissLand.readMPActivities(java.util.Properties cmd, diff --git a/doc/activity/package-frame.html b/doc/activity/package-frame.html index 4d39a79a..1e00c0d4 100644 --- a/doc/activity/package-frame.html +++ b/doc/activity/package-frame.html @@ -2,9 +2,9 @@ - + activity - + diff --git a/doc/activity/package-summary.html b/doc/activity/package-summary.html index 30bbc80f..a097d01c 100644 --- a/doc/activity/package-summary.html +++ b/doc/activity/package-summary.html @@ -2,9 +2,9 @@ - + activity - + diff --git a/doc/activity/package-tree.html b/doc/activity/package-tree.html index 9015deeb..54fe878a 100644 --- a/doc/activity/package-tree.html +++ b/doc/activity/package-tree.html @@ -2,9 +2,9 @@ - + activity Class Hierarchy - + diff --git a/doc/activity/package-use.html b/doc/activity/package-use.html index af9c3d0f..e2a1b68d 100644 --- a/doc/activity/package-use.html +++ b/doc/activity/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package activity - + diff --git a/doc/agent/Farm.html b/doc/agent/Farm.html index 9178fc65..984de3c1 100644 --- a/doc/agent/Farm.html +++ b/doc/agent/Farm.html @@ -2,9 +2,9 @@ - + Farm - + @@ -18,7 +18,7 @@ catch(err) { } //--> -var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":10,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10,"i37":10,"i38":10,"i39":10,"i40":10,"i41":10,"i42":10,"i43":10,"i44":10,"i45":10,"i46":10,"i47":10,"i48":10,"i49":10,"i50":10,"i51":10,"i52":10,"i53":10,"i54":10,"i55":10,"i56":10,"i57":10,"i58":10,"i59":10,"i60":10,"i61":10,"i62":10,"i63":10,"i64":10,"i65":10,"i66":10,"i67":10,"i68":10,"i69":10,"i70":10,"i71":10,"i72":10}; +var methods = {"i0":10,"i1":10,"i2":10,"i3":10,"i4":10,"i5":10,"i6":10,"i7":10,"i8":10,"i9":10,"i10":10,"i11":10,"i12":10,"i13":10,"i14":10,"i15":10,"i16":10,"i17":10,"i18":10,"i19":10,"i20":10,"i21":10,"i22":10,"i23":10,"i24":10,"i25":10,"i26":10,"i27":10,"i28":10,"i29":10,"i30":10,"i31":10,"i32":10,"i33":10,"i34":10,"i35":10,"i36":10,"i37":10,"i38":10,"i39":10,"i40":10,"i41":10,"i42":10,"i43":10,"i44":10,"i45":10,"i46":10,"i47":10,"i48":10,"i49":10,"i50":10,"i51":10,"i52":10,"i53":10,"i54":10,"i55":10,"i56":10,"i57":10,"i58":10,"i59":10,"i60":10,"i61":10,"i62":10,"i63":10,"i64":10,"i65":10,"i66":10,"i67":10,"i68":10,"i69":10,"i70":10,"i71":10,"i72":10,"i73":10,"i74":10,"i75":10,"i76":10,"i77":10}; var tabs = {65535:["t0","All Methods"],2:["t2","Instance Methods"],8:["t4","Concrete Methods"]}; var altColor = "altColor"; var rowColor = "rowColor"; @@ -134,7 +134,7 @@

Constructor Summary

Constructor and Description -Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -155,7 +155,10 @@

Constructor Summary

double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size)
+ double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
This constructor sets up the parameters associated with a farm.
@@ -181,295 +184,317 @@

Method Summary

+void +calculate_setLearningRate() +
If we want, we can set a learning rate based on the memory length
+ + + java.util.List<java.lang.String> decideActivitySet(java.util.List<Farm> allFarms, java.util.Properties cmd)
This function executes strategic decision-making for all farms.
- + java.util.List<Activity> getActivities()  - + double getActivity_Dissimilarity()  - + int getAge()  - + double getAveragePersonalIncomeChangeRate()  - + double getAveragePopulationIncomeChangeRate()  - + java.util.List<Activity> getCurrentActivity()  - + int getEducation()  - + FarmDataMatrix getExperience()  - + java.lang.String getFarmName()  - + Person getHead()  - + double getIncome_Dissimilarity()  - + java.util.List<java.lang.Double> getIncomeHistory()  - + double getLearningRate()  - + Location getLocation()  - + int getMemory()  - + org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> getNetwork()  - + double getP_activity_tolerance_coef()  - + double getP_alpha_minus()  - + double getP_alpha_plus()  - + double getP_aspiration_coef()  - + double getP_beta_l()  - + double getP_beta_p()  - + double getP_beta_s()  - + double -getP_fuzzy_size()  +getP_imt_fuzzy_size()  - + double getP_income_tolerance_coef()  - + double getP_lambda()  - + +double +getP_opt_fuzzy_size()  + + double getP_phi_minus()  - + double getP_phi_plus()  - + +int +getP_ranking_version()  + + double getP_reference_income()  - + FarmDataMatrix getPreferences()  - + java.util.List<java.lang.Double> getQ_range()  - + double getSatisfaction()  - + int getStrategy()  - + double init_learning_rate()
Initialize a value for learning rate based on the memory limit of each farm
- + void setActivities(java.util.List<Activity> activities)  - + void setActivity_Dissimilarity(double activity_dissimilarity)  - + void setAveragePersonalIncomeChangeRate(double averagePersonalIncomeChangeRate)  - + void setAveragePopulationIncomeChangeRate(double averagePopulationIncomeChangePercent)  - + void setCurrentActivity(java.util.List<Activity> activities)  - + void setExperience(FarmDataMatrix experience)  - + void setFarmName(java.lang.String farmName)  - + void setHead(Person farmHead)  - + void setIncome_Dissimilarity(double income_dissimilarity)  - + void setIncomeHistory(java.util.List<java.lang.Double> incomeHistory)  - + void -setLearningRate()  +setLearningRate(double learning_rate)  - + void setLocation(Location location)  - + void setNetwork(org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> network)  - + void setP_activity_tolerance_coef(double p_activity_tolerance_coef)  - + void setP_alpha_minus(double p_alpha_minus)  - + void setP_alpha_plus(double p_alpha_plus)  - + void setP_aspiration_coef(double p_aspiration_coef)  - + void setP_beta_l(double p_beta_l)  - + void setP_beta_p(double p_beta_p)  - + void setP_beta_s(double p_beta_s)  - + void -setP_fuzzy_size(double p_fuzzy_size)  +setP_imt_fuzzy_size(double p_imt_fuzzy_size)  - + void setP_income_tolerance_coef(double p_income_tolerance_coef)  - + void setP_lambda(double p_lambda)  - + +void +setP_opt_fuzzy_size(double p_fuzzy_size)  + + void setP_phi_minus(double p_phi_minus)  - + void setP_phi_plus(double p_phi_plus)  - + +void +setP_ranking_version(int p_ranking_version)  + + void setP_reference_income(double p_reference_income)  - + void setPreferences(FarmDataMatrix preferences)  - + void setQ_range()  - + void setSatisfaction(double satisfaction)  - + void setStrategy(int strategy)  - + void updateActivityDissimilarity(java.util.List<Farm> farms)
This function updates farms with values of dissimilarity in terms of activity.
- + void updateAge()
Each time period, t, call this function to increment the experience vector of this farm.
- + void updateAveragePersonalIncomeChangeRate()
Update personal income change rate over the previous time periods and include the current year.
- + void updateExperience()
Each time period, t, call this function to increment the experience vector of this farm.
- + void updateFarmParameters(java.util.List<Farm> allFarms, double income, @@ -477,13 +502,13 @@

Method Summary

This function updates all updatedable parameters on the farm based on new income and activity
- + void updateIncomeDissimilarity()
This function updates farms with values of dissimilarity in terms of income growth.
- + void updateSatisfaction()
Based on the current income level of the farmer calculate new satisfaction level.
@@ -511,7 +536,7 @@

Methods inherited from class java.lang.Object

Constructor Detail

- +
    @@ -538,7 +563,10 @@

    Farm

    double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
    This constructor sets up the parameters associated with a farm.
    Parameters:
    @@ -563,7 +591,10 @@

    Farm

    alpha_minus - :: for satisfaction calculation
    phi_plus - :: for satisfaction calculation
    phi_minus - :: for satisfaction calculation
    -
    fuzzy_size - :: how large of a fuzzy set to return
    +
    opt_fuzzy_size - :: how large of a fuzzy set to return
    +
    learning_rate - :: if learning rate is greater than 0, then we use that value, otherwise calculate internally
    +
    ranking_version - :: input ranking version, 0 is default
    +
    imt_fuzzy_size - :: fuzzy size for imitation version
@@ -1047,13 +1078,23 @@

getLearningRate

public double getLearningRate()
- +
  • setLearningRate

    -
    public void setLearningRate()
    +
    public void setLearningRate(double learning_rate)
    +
  • +
+ + + +
    +
  • +

    calculate_setLearningRate

    +
    public void calculate_setLearningRate()
    +
    If we want, we can set a learning rate based on the memory length
@@ -1272,22 +1313,58 @@

setP_reference_income

public void setP_reference_income(double p_reference_income)
-
+ + + +
    +
  • +

    getP_opt_fuzzy_size

    +
    public double getP_opt_fuzzy_size()
    +
  • +
+ + + +
    +
  • +

    setP_opt_fuzzy_size

    +
    public void setP_opt_fuzzy_size(double p_fuzzy_size)
    +
  • +
+ + + +
    +
  • +

    getP_imt_fuzzy_size

    +
    public double getP_imt_fuzzy_size()
    +
  • +
+ + + +
    +
  • +

    setP_imt_fuzzy_size

    +
    public void setP_imt_fuzzy_size(double p_imt_fuzzy_size)
    +
  • +
+
  • -

    getP_fuzzy_size

    -
    public double getP_fuzzy_size()
    +

    getP_ranking_version

    +
    public int getP_ranking_version()
- +
  • -

    setP_fuzzy_size

    -
    public void setP_fuzzy_size(double p_fuzzy_size)
    +

    setP_ranking_version

    +
    public void setP_ranking_version(int p_ranking_version)
diff --git a/doc/agent/Location.html b/doc/agent/Location.html index 5d2469c0..e574bce6 100644 --- a/doc/agent/Location.html +++ b/doc/agent/Location.html @@ -2,9 +2,9 @@ - + Location - + diff --git a/doc/agent/Person.html b/doc/agent/Person.html index 98d07dc7..451ad0cc 100644 --- a/doc/agent/Person.html +++ b/doc/agent/Person.html @@ -2,9 +2,9 @@ - + Person - + diff --git a/doc/agent/class-use/Farm.html b/doc/agent/class-use/Farm.html index 31078c6c..75e81591 100644 --- a/doc/agent/class-use/Farm.html +++ b/doc/agent/class-use/Farm.html @@ -2,9 +2,9 @@ - + Uses of Class agent.Farm - + @@ -292,17 +292,22 @@

Uses of Farm in < void -SwissLand.inputsforMP(Farm farm, +Toy.inputsforMP(Farm farm, java.util.List<java.lang.String> possibleActivity)  void +SwissLand.inputsforMP(Farm farm, + java.util.List<java.lang.String> possibleActivity)  + + +void MP_Interface.inputsforMP(Farm farm, java.util.List<java.lang.String> possibleActivity)
Generate the required input files for the gams MP model
- + void FarmDyn.inputsforMP(Farm farm, java.util.List<java.lang.String> possibleActivity)  @@ -323,26 +328,36 @@

Uses of Farm in < java.util.List<java.util.ArrayList<Activity>> -SwissLand.readMPActivities(java.util.Properties cmd, +Toy.readMPActivities(java.util.Properties cmd, java.util.List<Farm> allFarms)  java.util.List<java.util.ArrayList<Activity>> +SwissLand.readMPActivities(java.util.Properties cmd, + java.util.List<Farm> allFarms)  + + +java.util.List<java.util.ArrayList<Activity>> MP_Interface.readMPActivities(java.util.Properties cmd, java.util.List<Farm> allFarms)
Read results from MP model with activities of each agent
- + java.util.List<java.util.ArrayList<Activity>> FarmDyn.readMPActivities(java.util.Properties cmd, java.util.List<Farm> allFarms)  - + java.util.List<java.lang.Double> WeedControl.readMPIncomes(java.util.Properties cmd, java.util.List<Farm> allFarms)  + +java.util.List<java.lang.Double> +Toy.readMPIncomes(java.util.Properties cmd, + java.util.List<Farm> allFarms)  + java.util.List<java.lang.Double> SwissLand.readMPIncomes(java.util.Properties cmd, @@ -367,6 +382,13 @@

Uses of Farm in <
Read the MP output files to get income and activities
+ +java.util.List<java.lang.Object> +Toy.readMPOutputFiles(java.util.Properties cmd, + java.util.List<Farm> allFarms) +
Read the MP output files to get income and activities
+ + diff --git a/doc/agent/class-use/Location.html b/doc/agent/class-use/Location.html index 025403d3..64d4dcf6 100644 --- a/doc/agent/class-use/Location.html +++ b/doc/agent/class-use/Location.html @@ -2,9 +2,9 @@ - + Uses of Class agent.Location - + @@ -130,7 +130,7 @@

Uses of Location< -Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -151,7 +151,10 @@

Uses of Location< double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
This constructor sets up the parameters associated with a farm.
diff --git a/doc/agent/class-use/Person.html b/doc/agent/class-use/Person.html index ef9da5e0..9d63406d 100644 --- a/doc/agent/class-use/Person.html +++ b/doc/agent/class-use/Person.html @@ -2,9 +2,9 @@ - + Uses of Class agent.Person - + @@ -130,7 +130,7 @@

Uses of Person -Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -151,7 +151,10 @@

Uses of Person double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
This constructor sets up the parameters associated with a farm.
diff --git a/doc/agent/package-frame.html b/doc/agent/package-frame.html index 7ca622b5..b7891394 100644 --- a/doc/agent/package-frame.html +++ b/doc/agent/package-frame.html @@ -2,9 +2,9 @@ - + agent - + diff --git a/doc/agent/package-summary.html b/doc/agent/package-summary.html index 7d82d262..af7dc5b1 100644 --- a/doc/agent/package-summary.html +++ b/doc/agent/package-summary.html @@ -2,9 +2,9 @@ - + agent - + diff --git a/doc/agent/package-tree.html b/doc/agent/package-tree.html index 46436974..6ce36ed0 100644 --- a/doc/agent/package-tree.html +++ b/doc/agent/package-tree.html @@ -2,9 +2,9 @@ - + agent Class Hierarchy - + diff --git a/doc/agent/package-use.html b/doc/agent/package-use.html index 43c3afd2..08bff9dd 100644 --- a/doc/agent/package-use.html +++ b/doc/agent/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package agent - + diff --git a/doc/allclasses-frame.html b/doc/allclasses-frame.html index 20de20d8..459a9258 100644 --- a/doc/allclasses-frame.html +++ b/doc/allclasses-frame.html @@ -2,9 +2,9 @@ - + All Classes - + @@ -26,6 +26,7 @@

All Classes

  • Person
  • ReadData
  • SwissLand
  • +
  • Toy
  • WeedControl
  • diff --git a/doc/allclasses-noframe.html b/doc/allclasses-noframe.html index 2a8e8abf..bc7f7abf 100644 --- a/doc/allclasses-noframe.html +++ b/doc/allclasses-noframe.html @@ -2,9 +2,9 @@ - + All Classes - + @@ -26,6 +26,7 @@

    All Classes

  • Person
  • ReadData
  • SwissLand
  • +
  • Toy
  • WeedControl
  • diff --git a/doc/constant-values.html b/doc/constant-values.html index 898914b3..36914163 100644 --- a/doc/constant-values.html +++ b/doc/constant-values.html @@ -2,9 +2,9 @@ - + Constant Field Values - + @@ -168,11 +168,11 @@

    reader.*

    4 - + public static final int -FUZZY_SIZE -18 +IMT_FUZZY_SIZE +19 @@ -189,19 +189,33 @@

    reader.*

    13 +
    + +public static final int +LEARNING_RATE +21 + + public static final int MEMORY 5 - + public static final int NAME 0 + + + +public static final int +OPT_FUZZY_SIZE +18 + @@ -217,6 +231,13 @@

    reader.*

    16 +
    + +public static final int +RANKING_VERSION +20 + + public static final int diff --git a/doc/deprecated-list.html b/doc/deprecated-list.html index b0a50497..f821f571 100644 --- a/doc/deprecated-list.html +++ b/doc/deprecated-list.html @@ -2,9 +2,9 @@ - + Deprecated List - + diff --git a/doc/fuzzy_logic/FuzzyLogicCalculator.html b/doc/fuzzy_logic/FuzzyLogicCalculator.html index 0646aa2e..48527e62 100644 --- a/doc/fuzzy_logic/FuzzyLogicCalculator.html +++ b/doc/fuzzy_logic/FuzzyLogicCalculator.html @@ -2,9 +2,9 @@ - + FuzzyLogicCalculator - + diff --git a/doc/fuzzy_logic/class-use/FuzzyLogicCalculator.html b/doc/fuzzy_logic/class-use/FuzzyLogicCalculator.html index 65932765..285c2b88 100644 --- a/doc/fuzzy_logic/class-use/FuzzyLogicCalculator.html +++ b/doc/fuzzy_logic/class-use/FuzzyLogicCalculator.html @@ -2,9 +2,9 @@ - + Uses of Class fuzzy_logic.FuzzyLogicCalculator - + diff --git a/doc/fuzzy_logic/package-frame.html b/doc/fuzzy_logic/package-frame.html index 2907d30d..324fd4dc 100644 --- a/doc/fuzzy_logic/package-frame.html +++ b/doc/fuzzy_logic/package-frame.html @@ -2,9 +2,9 @@ - + fuzzy_logic - + diff --git a/doc/fuzzy_logic/package-summary.html b/doc/fuzzy_logic/package-summary.html index 179278a3..6d0557be 100644 --- a/doc/fuzzy_logic/package-summary.html +++ b/doc/fuzzy_logic/package-summary.html @@ -2,9 +2,9 @@ - + fuzzy_logic - + diff --git a/doc/fuzzy_logic/package-tree.html b/doc/fuzzy_logic/package-tree.html index e538c909..b1fd02a0 100644 --- a/doc/fuzzy_logic/package-tree.html +++ b/doc/fuzzy_logic/package-tree.html @@ -2,9 +2,9 @@ - + fuzzy_logic Class Hierarchy - + diff --git a/doc/fuzzy_logic/package-use.html b/doc/fuzzy_logic/package-use.html index b7a6aea6..58b0b748 100644 --- a/doc/fuzzy_logic/package-use.html +++ b/doc/fuzzy_logic/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package fuzzy_logic - + diff --git a/doc/help-doc.html b/doc/help-doc.html index 71a2c636..fbc766dc 100644 --- a/doc/help-doc.html +++ b/doc/help-doc.html @@ -2,9 +2,9 @@ - + API Help - + diff --git a/doc/index-files/index-1.html b/doc/index-files/index-1.html index b5b24831..8034d549 100644 --- a/doc/index-files/index-1.html +++ b/doc/index-files/index-1.html @@ -2,9 +2,9 @@ - + A-Index - + @@ -69,7 +69,7 @@ -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    A

    @@ -131,7 +131,7 @@

    A

    ASPIRATION - Static variable in class reader.ReadData
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    M

    @@ -91,7 +91,7 @@

    M

    Contains the generic functions to allow the possible activities from the decision making process to be exported to the mathematical programming (MP) model.
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    N

    @@ -79,7 +79,7 @@

    N

    ND - Variable in class fuzzy_logic.FuzzyLogicCalculator
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    diff --git a/doc/index-files/index-12.html b/doc/index-files/index-12.html index 3678ecbe..24577e0e 100644 --- a/doc/index-files/index-12.html +++ b/doc/index-files/index-12.html @@ -2,9 +2,9 @@ - -P-Index - + +O-Index + @@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@ @@ -12,7 +12,7 @@ + + + + + +
    + + + + + + + +
    + + +
    A B C D E F G I L M N O P R S T U W  + + +

    W

    +
    +
    WeedControl - Class in mathematical_programming
    +
    +
    Use the weedcontrol model from the AECP group as an optimizer on the activities.
    +
    +
    WeedControl(Properties, int, int) - Constructor for class mathematical_programming.WeedControl
    +
     
    +
    +A B C D E F G I L M N O P R S T U W 
    + +
    + + + + + + + +
    + + + + diff --git a/doc/index-files/index-2.html b/doc/index-files/index-2.html index 442878b5..6f6836e5 100644 --- a/doc/index-files/index-2.html +++ b/doc/index-files/index-2.html @@ -2,9 +2,9 @@ - + B-Index - + @@ -69,7 +69,7 @@
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    B

    @@ -81,7 +81,7 @@

    B

    BETA_S - Static variable in class reader.ReadData
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    C

    @@ -78,6 +78,10 @@

    C

    So if memory length is 5, we calculate an experience value for years 1 to 5.
    +
    calculate_setLearningRate() - Method in class agent.Farm
    +
    +
    If we want, we can set a learning rate based on the memory length
    +
    Consumat - Class in main
    This class contains the main() method of this program.
    @@ -93,7 +97,7 @@

    C

    This function creates generic file name so that version number can be appended to end.
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    D

    @@ -79,7 +79,7 @@

    D

    This function executes strategic decision-making for all farms.
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    E

    @@ -77,7 +77,7 @@

    E

    EDUCATION - Static variable in class reader.ReadData
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    F

    @@ -86,7 +86,7 @@

    F

    Farm object contains farm characteristics, an activity list, activity preferences, experience of performing activities and a social network.
    -
    Farm(String, Location, Graph<String, DefaultEdge>, List<Double>, FarmDataMatrix, FarmDataMatrix, List<Activity>, double, double, List<Activity>, Person, double, double, double, double, double, double, double, double, double, double, double) - Constructor for class agent.Farm
    +
    Farm(String, Location, Graph<String, DefaultEdge>, List<Double>, FarmDataMatrix, FarmDataMatrix, List<Activity>, double, double, List<Activity>, Person, double, double, double, double, double, double, double, double, double, double, double, double, int, double) - Constructor for class agent.Farm
    This constructor sets up the parameters associated with a farm.
    @@ -108,8 +108,6 @@

    F

    Fuzzy logic selection for activities in ABM.
    -
    FUZZY_SIZE - Static variable in class reader.ReadData
    -
     
    FuzzyLogicCalculator - Class in fuzzy_logic
    Object contains three vectors (L,P,S) that contain normalized rankings of experience, preference, and social network experience for a specific farm.
    @@ -119,7 +117,7 @@

    F

    Constructor for decision calculator for a specific farm based on the network.
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    G

    @@ -119,6 +119,8 @@

    G

    getExitActivity() - Method in class mathematical_programming.SwissLand
     
    +
    getExitActivity() - Method in class mathematical_programming.Toy
    +
     
    getExitActivity() - Method in class mathematical_programming.WeedControl
     
    getExperience() - Method in class agent.Farm
    @@ -194,16 +196,20 @@

    G

     
    getP_beta_s() - Method in class agent.Farm
     
    -
    getP_fuzzy_size() - Method in class agent.Farm
    +
    getP_imt_fuzzy_size() - Method in class agent.Farm
     
    getP_income_tolerance_coef() - Method in class agent.Farm
     
    getP_lambda() - Method in class agent.Farm
     
    +
    getP_opt_fuzzy_size() - Method in class agent.Farm
    +
     
    getP_phi_minus() - Method in class agent.Farm
     
    getP_phi_plus() - Method in class agent.Farm
     
    +
    getP_ranking_version() - Method in class agent.Farm
    +
     
    getP_reference_income() - Method in class agent.Farm
     
    getPossibleActivity() - Method in class logging.ABMActivityLog
    @@ -229,7 +235,7 @@

    G

    getYear() - Method in class logging.ABMTimeStepLog
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    I

    +
    IMT_FUZZY_SIZE - Static variable in class reader.ReadData
    +
     
    INCOME_TOLERANCE - Static variable in class reader.ReadData
     
    init_learning_rate() - Method in class agent.Farm
    @@ -98,10 +100,12 @@

    I

    inputsforMP(Farm, List<String>) - Method in class mathematical_programming.SwissLand
     
    +
    inputsforMP(Farm, List<String>) - Method in class mathematical_programming.Toy
    +
     
    inputsforMP(Farm, List<String>) - Method in class mathematical_programming.WeedControl
     
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    -
    A B C D E F G I L M N P R S U W  +
    A B C D E F G I L M N O P R S T U W 

    L

    @@ -78,6 +78,8 @@

    L

     
    LAMBDA - Static variable in class reader.ReadData
     
    +
    LEARNING_RATE - Static variable in class reader.ReadData
    +
     
    Location - Class in agent
    Location object contains the coordinates of farm.
    @@ -89,7 +91,7 @@

    L

    Log output of ABM
    -A B C D E F G I L M N P R S U W 
    +A B C D E F G I L M N O P R S T U W 
    diff --git a/doc/index.html b/doc/index.html index fa649b3d..f67b198e 100644 --- a/doc/index.html +++ b/doc/index.html @@ -2,7 +2,7 @@ - + Generated Documentation (Untitled) diff --git a/doc/logging/ABMTimeStepLog.html b/doc/logging/ABMTimeStepLog.html index a93ba6d1..5c56c4f6 100644 --- a/doc/logging/ABMTimeStepLog.html +++ b/doc/logging/ABMTimeStepLog.html @@ -2,9 +2,9 @@ - + ABMTimeStepLog - + diff --git a/doc/logging/class-use/ABMActivityLog.html b/doc/logging/class-use/ABMActivityLog.html index 9e686d6a..b8a4de05 100644 --- a/doc/logging/class-use/ABMActivityLog.html +++ b/doc/logging/class-use/ABMActivityLog.html @@ -2,9 +2,9 @@ - + Uses of Class logging.ABMActivityLog - + diff --git a/doc/logging/class-use/ABMTimeStepLog.html b/doc/logging/class-use/ABMTimeStepLog.html index 1dd4bdcb..643d6395 100644 --- a/doc/logging/class-use/ABMTimeStepLog.html +++ b/doc/logging/class-use/ABMTimeStepLog.html @@ -2,9 +2,9 @@ - + Uses of Class logging.ABMTimeStepLog - + diff --git a/doc/logging/package-frame.html b/doc/logging/package-frame.html index 29bf1bd6..47d7a8ec 100644 --- a/doc/logging/package-frame.html +++ b/doc/logging/package-frame.html @@ -2,9 +2,9 @@ - + logging - + diff --git a/doc/logging/package-summary.html b/doc/logging/package-summary.html index d6144e0b..333a89d6 100644 --- a/doc/logging/package-summary.html +++ b/doc/logging/package-summary.html @@ -2,9 +2,9 @@ - + logging - + diff --git a/doc/logging/package-tree.html b/doc/logging/package-tree.html index 141cb6fb..a600a8ca 100644 --- a/doc/logging/package-tree.html +++ b/doc/logging/package-tree.html @@ -2,9 +2,9 @@ - + logging Class Hierarchy - + diff --git a/doc/logging/package-use.html b/doc/logging/package-use.html index 53a46874..4fb4d2d6 100644 --- a/doc/logging/package-use.html +++ b/doc/logging/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package logging - + diff --git a/doc/main/Consumat.html b/doc/main/Consumat.html index 7b9ab328..d87e287b 100644 --- a/doc/main/Consumat.html +++ b/doc/main/Consumat.html @@ -2,9 +2,9 @@ - + Consumat - + diff --git a/doc/main/class-use/Consumat.html b/doc/main/class-use/Consumat.html index 71d2ce69..2a4f2bca 100644 --- a/doc/main/class-use/Consumat.html +++ b/doc/main/class-use/Consumat.html @@ -2,9 +2,9 @@ - + Uses of Class main.Consumat - + diff --git a/doc/main/package-frame.html b/doc/main/package-frame.html index 7a7cdc0e..9cb390b0 100644 --- a/doc/main/package-frame.html +++ b/doc/main/package-frame.html @@ -2,9 +2,9 @@ - + main - + diff --git a/doc/main/package-summary.html b/doc/main/package-summary.html index 5d841b89..a5f3aed7 100644 --- a/doc/main/package-summary.html +++ b/doc/main/package-summary.html @@ -2,9 +2,9 @@ - + main - + diff --git a/doc/main/package-tree.html b/doc/main/package-tree.html index fd85c415..7cb60421 100644 --- a/doc/main/package-tree.html +++ b/doc/main/package-tree.html @@ -2,9 +2,9 @@ - + main Class Hierarchy - + diff --git a/doc/main/package-use.html b/doc/main/package-use.html index a393f110..d9a6f5cd 100644 --- a/doc/main/package-use.html +++ b/doc/main/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package main - + diff --git a/doc/mathematical_programming/FactoryMP.html b/doc/mathematical_programming/FactoryMP.html index 95dd04d4..7ca1689b 100644 --- a/doc/mathematical_programming/FactoryMP.html +++ b/doc/mathematical_programming/FactoryMP.html @@ -2,9 +2,9 @@ - + FactoryMP - + diff --git a/doc/mathematical_programming/FarmDyn.html b/doc/mathematical_programming/FarmDyn.html index b60c15ea..f946eda1 100644 --- a/doc/mathematical_programming/FarmDyn.html +++ b/doc/mathematical_programming/FarmDyn.html @@ -2,9 +2,9 @@ - + FarmDyn - + diff --git a/doc/mathematical_programming/MP_Interface.html b/doc/mathematical_programming/MP_Interface.html index 70353c34..1e86eb8a 100644 --- a/doc/mathematical_programming/MP_Interface.html +++ b/doc/mathematical_programming/MP_Interface.html @@ -2,9 +2,9 @@ - + MP_Interface - + @@ -101,7 +101,7 @@

    Interface MP_Interface

  • All Known Implementing Classes:
    -
    FarmDyn, SwissLand, WeedControl
    +
    FarmDyn, SwissLand, Toy, WeedControl


    diff --git a/doc/mathematical_programming/SwissLand.html b/doc/mathematical_programming/SwissLand.html index 959d61f8..deeac50e 100644 --- a/doc/mathematical_programming/SwissLand.html +++ b/doc/mathematical_programming/SwissLand.html @@ -2,9 +2,9 @@ - + SwissLand - + @@ -50,7 +50,7 @@
  • diff --git a/doc/mathematical_programming/package-use.html b/doc/mathematical_programming/package-use.html index 0717f6ab..805c3911 100644 --- a/doc/mathematical_programming/package-use.html +++ b/doc/mathematical_programming/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package mathematical_programming - + diff --git a/doc/overview-frame.html b/doc/overview-frame.html index 65757c1b..120f0268 100644 --- a/doc/overview-frame.html +++ b/doc/overview-frame.html @@ -2,9 +2,9 @@ - + Overview List - + diff --git a/doc/overview-summary.html b/doc/overview-summary.html index 2b0ff409..364d5a44 100644 --- a/doc/overview-summary.html +++ b/doc/overview-summary.html @@ -2,9 +2,9 @@ - + Overview - + diff --git a/doc/overview-tree.html b/doc/overview-tree.html index 291c9457..ff25c1eb 100644 --- a/doc/overview-tree.html +++ b/doc/overview-tree.html @@ -2,9 +2,9 @@ - + Class Hierarchy - + @@ -100,6 +100,7 @@

    Class Hierarchy

  • agent.Person
  • reader.ReadData
  • mathematical_programming.SwissLand (implements mathematical_programming.MP_Interface)
  • +
  • mathematical_programming.Toy (implements mathematical_programming.MP_Interface)
  • mathematical_programming.WeedControl (implements mathematical_programming.MP_Interface)
  • diff --git a/doc/reader/FarmDataMatrix.html b/doc/reader/FarmDataMatrix.html index d5d9badc..f2762f35 100644 --- a/doc/reader/FarmDataMatrix.html +++ b/doc/reader/FarmDataMatrix.html @@ -2,9 +2,9 @@ - + FarmDataMatrix - + diff --git a/doc/reader/ReadData.html b/doc/reader/ReadData.html index 33156615..9635fa7c 100644 --- a/doc/reader/ReadData.html +++ b/doc/reader/ReadData.html @@ -2,9 +2,9 @@ - + ReadData - + @@ -188,7 +188,7 @@

    Field Summary

    static int -FUZZY_SIZE  +IMT_FUZZY_SIZE  static int @@ -212,12 +212,20 @@

    Field Summary

    static int -MEMORY  +LEARNING_RATE  static int +MEMORY  + + +static int NAME  + +static int +OPT_FUZZY_SIZE  + static int PHI_MINUS  @@ -228,9 +236,13 @@

    Field Summary

    static int -REFERENCE_INCOME  +RANKING_VERSION  +static int +REFERENCE_INCOME  + + java.lang.String SocialNetworkFile  @@ -536,16 +548,55 @@

    PHI_MINUS

    - + + + + + + + + + + + + + diff --git a/doc/reader/class-use/FarmDataMatrix.html b/doc/reader/class-use/FarmDataMatrix.html index 23582f59..22064461 100644 --- a/doc/reader/class-use/FarmDataMatrix.html +++ b/doc/reader/class-use/FarmDataMatrix.html @@ -2,9 +2,9 @@ - + Uses of Class reader.FarmDataMatrix - + @@ -138,7 +138,7 @@

    Uses of F -Farm(java.lang.String name, +Farm(java.lang.String name, Location location, org.jgrapht.Graph<java.lang.String,org.jgrapht.graph.DefaultEdge> socialNetwork, java.util.List<java.lang.Double> incomeHistory, @@ -159,7 +159,10 @@

    Uses of F double alpha_minus, double phi_plus, double phi_minus, - double fuzzy_size) + double opt_fuzzy_size, + double imt_fuzzy_size, + int ranking_version, + double learning_rate)
    This constructor sets up the parameters associated with a farm.
    diff --git a/doc/reader/class-use/ReadData.html b/doc/reader/class-use/ReadData.html index 168ff6bd..91fa54ea 100644 --- a/doc/reader/class-use/ReadData.html +++ b/doc/reader/class-use/ReadData.html @@ -2,9 +2,9 @@ - + Uses of Class reader.ReadData - + diff --git a/doc/reader/package-frame.html b/doc/reader/package-frame.html index 169e1b85..f8b5c7ff 100644 --- a/doc/reader/package-frame.html +++ b/doc/reader/package-frame.html @@ -2,9 +2,9 @@ - + reader - + diff --git a/doc/reader/package-summary.html b/doc/reader/package-summary.html index 0863496c..1d30efeb 100644 --- a/doc/reader/package-summary.html +++ b/doc/reader/package-summary.html @@ -2,9 +2,9 @@ - + reader - + diff --git a/doc/reader/package-tree.html b/doc/reader/package-tree.html index a2b24a44..1b2b1ce3 100644 --- a/doc/reader/package-tree.html +++ b/doc/reader/package-tree.html @@ -2,9 +2,9 @@ - + reader Class Hierarchy - + diff --git a/doc/reader/package-use.html b/doc/reader/package-use.html index e885ce28..f0ed9c18 100644 --- a/doc/reader/package-use.html +++ b/doc/reader/package-use.html @@ -2,9 +2,9 @@ - + Uses of Package reader - + diff --git a/src/agent/Farm.java b/src/agent/Farm.java index 389e6463..5926809f 100644 --- a/src/agent/Farm.java +++ b/src/agent/Farm.java @@ -83,6 +83,9 @@ public class Farm { * @param phi_plus :: for satisfaction calculation * @param phi_minus :: for satisfaction calculation * @param opt_fuzzy_size :: how large of a fuzzy set to return + * @param learning_rate :: if learning rate is greater than 0, then we use that value, otherwise calculate internally + * @param ranking_version :: input ranking version, 0 is default + * @param imt_fuzzy_size :: fuzzy size for imitation version */ public Farm(String name, Location location, Graph socialNetwork, List incomeHistory, FarmDataMatrix farmingExperience, FarmDataMatrix preferences, List activities, double activity_tolerance, double income_tolerance, diff --git a/src/main/Consumat.java b/src/main/Consumat.java index 3b82ef3e..7468a26f 100644 --- a/src/main/Consumat.java +++ b/src/main/Consumat.java @@ -37,7 +37,7 @@ public class Consumat { public static void main(String[] args) { initializeLogging(); - LOGGER.info("Starting FARMIND: version number: 0.10.0"); + LOGGER.info("Starting FARMIND: version number: 0.11.0"); Properties cmd = parseInput(args,false); // parse input arguments from control.properties ReadData reader = new ReadData(cmd); // read all input data files @@ -51,8 +51,7 @@ public static void main(String[] args) { // initialize the farms with the input values before starting the full ABM simulation initializePopulationIncomeChangeRate(allFarms); - // run simulation for a set of years, getting updated income and activities from the MP model each iteration - for (int year = 1; year <= simYear; year++) { + for (int year = 1; year <= simYear; year++) { LOGGER.info(String.format("Year %d simulation started", year)); MP_Interface MP = new FactoryMP(cmd, simYear, memoryLengthAverage).getMP(); // select correct model based on input command parameter