Ejemplo n.º 1
0
 protected void UpdateLearningTable(int n, QState s, QAction a, decimal qv)
 {
     if (main != null)
     {
         main.UpdateLearningTable(n, s, a, qv);
     }
 }
Ejemplo n.º 2
0
 public void UpdateLearningTable(int n, QState s, QAction a, decimal qv)
 {
     if (InvokeRequired)
     {
         Invoke(new UpdateLearningTableD(UpdateLearningTable), n, s, a, qv);
     }
     else
     {
         QStateActionPair p = new QStateActionPair(s, a);
         if (LearningTableQStateKeys.ContainsKey(p))
         {
             LearningTableQStateKeys[p].Cells["Num"].Value    = n;
             LearningTableQStateKeys[p].Cells["QValue"].Value = qv;
         }
         else
         {
             LearningTable.Rows.Add(n, s.ToString(), a.ToString(), qv);
             LearningTableQStateKeys[p] = LearningTable.Rows[LearningTable.Rows.Count - 1];;
         }
     }
 }
Ejemplo n.º 3
0
 public void UpdateLearningTable(int n, QState s, QAction a, decimal qv)
 {
     if (InvokeRequired)
     {
         Invoke(new UpdateLearningTableD(UpdateLearningTable), n, s, a, qv);
     }
     else
     {
         QStateActionPair p = new QStateActionPair(s, a);
         if (LearningTableQStateKeys.ContainsKey(p))
         {
             LearningTableQStateKeys[p].Cells["Num"].Value = n;
             LearningTableQStateKeys[p].Cells["QValue"].Value = qv;
         }
         else
         {
             LearningTable.Rows.Add(n, s.ToString(), a.ToString(), qv);
             LearningTableQStateKeys[p] = LearningTable.Rows[LearningTable.Rows.Count - 1]; ;
         }
     }
 }
Ejemplo n.º 4
0
 public QStateActionPair(QState s, QAction a)
 {
     state = s;
     action = a;
 }
Ejemplo n.º 5
0
 public QStateActionPair(QState s, QAction a)
 {
     state  = s;
     action = a;
 }