MultiAgentDecisionProcess
Release 0.2.1
Main Page
Namespaces
Classes
Files
File List
File Members
DecPOMDP.cpp
Go to the documentation of this file.
1
28
#include "
DecPOMDP.h
"
29
30
using namespace
std;
31
32
DecPOMDP::DecPOMDP
()
33
{
34
_m_rewardType =
REWARD
;
35
_m_discount = 1.0;
36
}
37
38
void
DecPOMDP::SetDiscount
(
double
d)
39
{
40
if
(d>=0 && d<=1)
41
_m_discount=d;
42
else
43
throw
(
E
(
"DecPOMDP::SetDiscount() discount not valid, should be >=0 and <=1"
));
44
}
45
46
string
DecPOMDP::SoftPrint
()
const
47
{
48
stringstream ss;
49
ss <<
"Discount factor: "
<< _m_discount << endl;
50
ss <<
"Reward type: "
<< _m_rewardType << endl;
51
return
ss.str();
52
}
53
54
void
DecPOMDP::SetRewardType
(
reward_t
r)
55
{
56
if
(r!=
REWARD
)
57
throw
(
E
(
"DecPOMDP::SetRewardType only reward type REWARD is supported"
));
58
_m_rewardType = r;
59
}
src
base
DecPOMDP.cpp
Generated on Mon Sep 23 2013 14:50:05 for MultiAgentDecisionProcess by
1.8.1.2