MultiAgentDecisionProcess  Release 0.2.1
PolicyDiscrete Class Reference

PolicyDiscrete is a class that represents a discrete policy. More...

#include <PolicyDiscrete.h>

+ Inheritance diagram for PolicyDiscrete:
+ Collaboration diagram for PolicyDiscrete:

Public Member Functions

virtual PolicyDiscreteClone () const =0
 Returns a pointer to a copy of this class.
virtual double GetActionProb (Index i, Index ja) const =0
 Returns the probability that the policy specifies action for domain index i.
IndexDomainCategory GetIndexDomainCategory () const
 Returns the Category of the domain over which the indices of this policy are specified.
const
Interface_ProblemToPolicyDiscrete
GetInterfacePTPDiscrete () const
 return a pointer to the referred Interface_ProblemToPolicyDiscrete.
 PolicyDiscrete (const Interface_ProblemToPolicyDiscrete &iptpd, PolicyGlobals::IndexDomainCategory idc, Index agentI)
 (default) Constructor
 PolicyDiscrete (const PolicyDiscrete &a)
 Copy constructor.
Index SampleAction (Index i) const
 samples an action for domain index i.
void SetIndexDomainCategory (IndexDomainCategory idc)
 Sets the category of the domain over which the indices of this policy are specified.
virtual ~PolicyDiscrete ()
 Destructor.
- Public Member Functions inherited from Policy
size_t GetDepth () const
 Returns the depth of the policy.
 Policy (Index agentI)
 Constructor, initializes the depth to the maximum horizon.
virtual void Print () const
 Prints a description of a policy to cout.
virtual void SetDepth (size_t d)
 Sets the depth of the policy.
virtual std::string SoftPrint () const =0
 Prints a description of a policy to a string.
virtual ~Policy ()
 Destructor.

Private Attributes

const
Interface_ProblemToPolicyDiscrete
_m_I_PTPD
PolicyGlobals::IndexDomainCategory _m_indexDomCat
 Maintains the IndexDomainCategory.

Additional Inherited Members

- Protected Attributes inherited from Policy
Index _m_agentI

Detailed Description

PolicyDiscrete is a class that represents a discrete policy.

A `discrete joint policy' is a policy for a discrete problem. I.e., the problem specifies, for each agent, a discrete domain for the policy and discrete actions.

A PolicyDiscrete from discrete indices over the domain (typically action-observation histories or types) to (degenerate) probability distributions over indices over (joint) actions.

This means that this class includes both pure and stochastic pure policies.

Definition at line 55 of file PolicyDiscrete.h.

Constructor & Destructor Documentation

PolicyDiscrete::PolicyDiscrete ( const Interface_ProblemToPolicyDiscrete iptpd,
PolicyGlobals::IndexDomainCategory  idc,
Index  agentI 
)
inline

(default) Constructor

Definition at line 69 of file PolicyDiscrete.h.

PolicyDiscrete::PolicyDiscrete ( const PolicyDiscrete a)
inline

Copy constructor.

Definition at line 77 of file PolicyDiscrete.h.

virtual PolicyDiscrete::~PolicyDiscrete ( )
inlinevirtual

Destructor.

Definition at line 84 of file PolicyDiscrete.h.

Member Function Documentation

virtual PolicyDiscrete* PolicyDiscrete::Clone ( ) const
pure virtual

Returns a pointer to a copy of this class.

Implements Policy.

Implemented in PolicyPureVector, and PolicyDiscretePure.

virtual double PolicyDiscrete::GetActionProb ( Index  i,
Index  ja 
) const
pure virtual

Returns the probability that the policy specifies action for domain index i.

Implementations for pure policies clearly should return 0 or 1.

Implemented in PolicyDiscretePure.

Referenced by SampleAction().

IndexDomainCategory PolicyDiscrete::GetIndexDomainCategory ( ) const
inline

Returns the Category of the domain over which the indices of this policy are specified.

Definition at line 100 of file PolicyDiscrete.h.

Referenced by PolicyPureVector::GetIndex(), PolicyPureVector::Increment(), PolicyPureVector::PolicyPureVector(), PolicyPureVector::SetDepth(), PolicyPureVector::SetIndex(), and PolicyPureVector::SoftPrint().

const Interface_ProblemToPolicyDiscrete* PolicyDiscrete::GetInterfacePTPDiscrete ( ) const
inline

return a pointer to the referred Interface_ProblemToPolicyDiscrete.

Definition at line 117 of file PolicyDiscrete.h.

Referenced by PolicyDiscretePure::GetInterfacePTPDiscretePure(), and SampleAction().

Index PolicyDiscrete::SampleAction ( Index  i) const
void PolicyDiscrete::SetIndexDomainCategory ( IndexDomainCategory  idc)
inline

Sets the category of the domain over which the indices of this policy are specified.

Definition at line 93 of file PolicyDiscrete.h.

Member Data Documentation

const Interface_ProblemToPolicyDiscrete* PolicyDiscrete::_m_I_PTPD
private

Definition at line 60 of file PolicyDiscrete.h.

PolicyGlobals::IndexDomainCategory PolicyDiscrete::_m_indexDomCat
private

Maintains the IndexDomainCategory.

Definition at line 62 of file PolicyDiscrete.h.


The documentation for this class was generated from the following files: