symbolic
Public Member Functions | Static Public Member Functions | Friends | List of all members
symbolic::Axiom Class Reference
Inheritance diagram for symbolic::Axiom:
symbolic::Action

Public Member Functions

 Axiom (const Pddl &pddl, const VAL::operator_*symbol)
 
bool IsConsistent (const State &state) const
 
bool IsConsistent (const PartialState &state) const
 
State Apply (const State &state) const
 
bool Apply (State *state) const
 
PartialState Apply (const PartialState &state) const
 
int Apply (PartialState *state) const
 
const SignedPropositioncontext () const
 
- Public Member Functions inherited from symbolic::Action
 Action (const Pddl &pddl, const VAL::operator_*symbol)
 
 Action (const Pddl &pddl, const std::string &action_call)
 
bool IsValid (const State &state, const std::vector< Object > &arguments) const
 
std::optional< bool > IsValid (const PartialState &state, const std::vector< Object > &arguments) const
 
State Apply (const State &state, const std::vector< Object > &arguments) const
 
bool Apply (const std::vector< Object > &arguments, State *state) const
 
PartialState Apply (const PartialState &state, const std::vector< Object > &arguments) const
 
int Apply (const std::vector< Object > &arguments, PartialState *state) const
 
const VAL::operator_* symbol () const
 
const Pddlpddl () const
 
const std::string & name () const
 
const std::vector< Object > & parameters () const
 
const ParameterGeneratorparameter_generator () const
 
const Formulapreconditions () const
 
const VAL::effect_lists * postconditions () const
 
std::string to_string () const
 
std::string to_string (const std::vector< Object > &arguments) const
 

Static Public Member Functions

static bool IsConsistent (const std::vector< std::shared_ptr< Axiom >> &axioms, const PartialState &state)
 
static std::optional< std::function< const std::vector< Object > *(const std::vector< Object > &)> > CreateApplicationFunction (const std::vector< Object > &action_params, const std::vector< Object > &action_prop_params, const std::vector< Object > &axiom_params, const std::vector< Object > &axiom_prop_params)
 
- Static Public Member Functions inherited from symbolic::Action
static std::pair< Action, std::vector< Object > > Parse (const Pddl &pddl, const std::string &action_call)
 

Friends

std::ostream & operator<< (std::ostream &os, const Axiom &axiom)
 

Additional Inherited Members

- Protected Attributes inherited from symbolic::Action
const VAL::operator_* symbol_ = nullptr
 
const Pddlpddl_ = nullptr
 
std::string name_
 
std::vector< Objectparameters_
 
ParameterGenerator param_gen_
 
Formula Preconditions_
 
std::function< int(const std::vector< Object > &, State *)> Apply_
 
std::function< int(const std::vector< Object > &, PartialState *)> ApplyPartial_
 

Constructor & Destructor Documentation

◆ Axiom()

symbolic::Axiom::Axiom ( const Pddl pddl,
const VAL::operator_*  symbol 
)

Axiom constructor.

Member Function Documentation

◆ Apply() [1/2]

PartialState symbolic::Axiom::Apply ( const PartialState state) const

Iterate over all argument combinations and apply the implication whenever the context is valid.

◆ Apply() [2/2]

State symbolic::Axiom::Apply ( const State state) const

Iterate over all argument combinations and apply the implication whenever the context is valid.

◆ context()

const SignedProposition& symbolic::Axiom::context ( ) const
inline

Predicate used in the axiom context.

◆ CreateApplicationFunction()

std::optional< AxiomApplicationFunction > symbolic::Axiom::CreateApplicationFunction ( const std::vector< Object > &  action_params,
const std::vector< Object > &  action_prop_params,
const std::vector< Object > &  axiom_params,
const std::vector< Object > &  axiom_prop_params 
)
static

Creates a function that takes action_args and returns axiom_args based on positional indices of the axiom context proposition. If the action_args are not consistent with the axiom context, returns an empty vector.

◆ IsConsistent() [1/3]

bool symbolic::Axiom::IsConsistent ( const PartialState state) const

Determine whether the axiom is satisfied in the given partial state.

Parameters
statePartial state to evaluate.
Returns
Whether the state is consistent with this axiom.

◆ IsConsistent() [2/3]

bool symbolic::Axiom::IsConsistent ( const State state) const

Determine whether the axiom is satisfied in the given state.

Parameters
stateState to evaluate.
Returns
Whether the state is consistent with this axiom.

◆ IsConsistent() [3/3]

bool symbolic::Axiom::IsConsistent ( const std::vector< std::shared_ptr< Axiom >> &  axioms,
const PartialState state 
)
static

Determine whether all axioms are satisfied in the given partial state.

Returns false only if a partial state fully satisfies the pre-conditions of the axiom and explicitly does not satisfy the post-conditions. If a proposition in the partial state is unknown, the axiom is assumed to be satisfied.

Parameters
statePartial state to evaluate.
Returns
Whether the state is consistent with this axiom.

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