Writing Methods

[ This page is under development ]

All method classes are subclasses of the Method class. The virtual methods that concrete classes override are shown below:

virtual void Method::compute(Block *block) = 0

Apply the method to advance a block one timestep.

virtual std::string Method::name() = 0

Return the name of this Method.

inline virtual double Method::timestep(Block *block)

Compute maximum timestep for this method

The default implementation returns the maximum finite value of double

inline virtual void Method::compute_resume(Block *block, CkReductionMsg *msg)

Resume computation after a reduction

This member function only typically needs to be implemented by Method classes that employ reductions.

Warning

This page is very incomplete. Among other things, we have not discussed pup routines.