\(\newcommand{\W}[1]{ \; #1 \; }\) \(\newcommand{\R}[1]{ {\rm #1} }\) \(\newcommand{\B}[1]{ {\bf #1} }\) \(\newcommand{\D}[2]{ \frac{\partial #1}{\partial #2} }\) \(\newcommand{\DD}[3]{ \frac{\partial^2 #1}{\partial #2 \partial #3} }\) \(\newcommand{\Dpow}[2]{ \frac{\partial^{#1}}{\partial {#2}^{#1}} }\) \(\newcommand{\dpow}[2]{ \frac{ {\rm d}^{#1}}{{\rm d}\, {#2}^{#1}} }\)
chkpoint_two_dynamic¶
View page sourceDynamic Parameters in Checkpoint Functions¶
Syntax¶
new_dynamic
( dynamic )Prototype¶
template <class Base>
template <class BaseVector>
void chkpoint_two<Base>::new_dynamic(const BaseVector& dynamic)
chk_fun¶
This object must have been created using the chkpoint_two constructor.
Base¶
This is the Base type in the chk_fun constructor.
fun¶
This is the function fun in the chk_fun constructor.
BaseVector¶
This must be a SimpleVector with elements of type Base .
dynamic¶
This is a vector with new values for the dynamic parameters in the function fun . Is size must be equal to fun.size_dyn_ind() . This only affects the copy of fun used by chk_fun .
Multi-Threading¶
If one is using in_parallel , there is a separate copy of fun for each thread. In this case, only the dynamic parameters in the copy for the current thread number are changed.