Alternaria
fit cylinders and ellipsoids to fungus
Spore_split_merge_spore_move Class Reference

#include <alternaria_moves.h>

Inheritance diagram for Spore_split_merge_spore_move:
Collaboration diagram for Spore_split_merge_spore_move:

List of all members.

Public Member Functions

 Spore_split_merge_spore_move (const char *split_name, const char *merge_name, double split_prob=1.0, double merge_prob=1.0) throw (jwscxx::base::Arg_error)
 Constructs an Spore_split_merge_spore_move.
bool run_1 (Sampler_move_parameters *params) throw (jwscxx::base::Exception)
 Runs the split jump move and either accepts or rejects.
bool run_2 (Sampler_move_parameters *params) throw (jwscxx::base::Exception)
 Runs the merge jump move and either accepts or rejects.

Static Protected Member Functions

static void propose_1st_split (Spore **proposal_out, double *log_prob_out, const Spore *spore) throw (jwscxx::base::Arg_error)
 Creates the first split proposal.
static void propose_2nd_split (Spore **proposal_out, double *log_prob_out, const Spore *split_1) throw (jwscxx::base::Arg_error)
 Creates the second split proposal.
static void propose_merge (Spore **proposal_out, double *log_prob_out, const Structure *parent, const Spore *hypha_1, const Spore *hypha_2) throw (jwscxx::base::Arg_error)
 Creates the merge proposal.

Detailed Description

MCMC Sampler move that stochastically proposes splitting or merging an Apical_hypha with its Apical_hypha::apical in an Alternaria_model.

Definition at line 280 of file alternaria_moves.h.


Constructor & Destructor Documentation

Spore_split_merge_spore_move::Spore_split_merge_spore_move ( const char *  split_name,
const char *  merge_name,
double  split_prob = 1.0,
double  merge_prob = 1.0 
) throw (jwscxx::base::Arg_error) [inline]

Constructs an Spore_split_merge_spore_move.

Definition at line 286 of file alternaria_moves.h.


Member Function Documentation

bool Spore_split_merge_spore_move::run_1 ( Sampler_move_parameters params) throw (jwscxx::base::Exception) [virtual]

Runs the split jump move and either accepts or rejects.

========================================================================= ------------------ Spore_split_merge_spore_move -----------------------

Parameters:
paramsParameters for the move.
Returns:
If the proposal is accepted, 1; otherwise 0.

Implements Sampler_jump_move.

Definition at line 1154 of file alternaria_moves.cpp.

bool Spore_split_merge_spore_move::run_2 ( Sampler_move_parameters params) throw (jwscxx::base::Exception) [virtual]

Runs the merge jump move and either accepts or rejects.

Parameters:
paramsParameters for the move.
Returns:
If the proposal is accepted, 1; otherwise 0.

Implements Sampler_jump_move.

Definition at line 1243 of file alternaria_moves.cpp.

void Spore_split_merge_spore_move::propose_1st_split ( Spore **  proposal_out,
double *  log_prob_out,
const Spore spore 
) throw (jwscxx::base::Arg_error) [static, protected]

Creates the first split proposal.

Parameters:
proposal_outResult parameter. The first split spore proposal.
log_prob_outResult parameter. The log probability of *proposal_out.
sporeStructure to split.

Definition at line 1340 of file alternaria_moves.cpp.

void Spore_split_merge_spore_move::propose_2nd_split ( Spore **  proposal_out,
double *  log_prob_out,
const Spore split_1 
) throw (jwscxx::base::Arg_error) [static, protected]

Creates the second split proposal.

Parameters:
proposal_outResult parameter. The second split spore proposal.
log_prob_outResult parameter. The log probability of *proposal_out.
split_1First split spore proposal.

Definition at line 1497 of file alternaria_moves.cpp.

void Spore_split_merge_spore_move::propose_merge ( Spore **  proposal_out,
double *  log_prob_out,
const Structure parent,
const Spore spore_1,
const Spore spore_2 
) throw (jwscxx::base::Arg_error) [static, protected]

Creates the merge proposal.

Parameters:
proposal_outResult parameter. The merged spore proposal.
log_prob_outResult parameter. The log probability of *proposal_out.
parentParent structure of spore_1.
spore_1First spore to merge.
spore_2Second spore proposal.

Definition at line 1571 of file alternaria_moves.cpp.


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