76 cerr <<
"Illegal value for hesstype" <<
endl;
99 cerr <<
"Illegal value for hesstype" <<
endl;
114 cerr <<
"Illegal value for hesstype" <<
endl;
125 cerr <<
"illegal value for block_diagonal_flag = "
133 cerr <<
"this can't happen" <<
endl;
155 int num_fixed_effects=0;
162 ivector lfe_index(1, (
int)funnel_init_var::num_active_parameters);
163 for (
int i=1;i<=(int)funnel_init_var::num_active_parameters;i++)
165 double listi1 = list(i, 1);
168 lre_index(++num_local_re)=i;
172 lfe_index(++num_fixed_effects)=i;
176 if (num_local_re > 0)
184 dmatrix local_Hess(1,num_local_re,1,num_local_re);
185 dvector local_grad(1,num_local_re);
191 dvector* plocal_Hessi = &local_Hess(1);
192 int* plre_indexi = lre_index.
get_v() + 1;
193 for (
int i=1;i<=num_local_re;i++)
195 int lrei = *plre_indexi;
198 double* plocal_Hessij = plocal_Hessi->
get_v() + 1;
199 int* plre_indexj = lre_index.
get_v() + 1;
200 for (
int j=1;j<=num_local_re;j++)
202 int lrej = *plre_indexj;
206 *plocal_Hessij += locy(i2).u_bar[j2-1];
216 double* plocal_gradi = local_grad.
get_v() + 1;
217 plre_indexi = lre_index.
get_v() + 1;
218 for (
int i=1;i<=num_local_re;i++)
220 int lrei = *plre_indexi;
225 *plocal_gradi = ff.
u_dot[i2-1];
234 plocal_Hessi = &local_Hess(1);
235 plre_indexi = lre_index.
get_v() + 1;
236 for (
int i=1;i<=num_local_re;i++)
238 int lrei=lre_index(i);
241 double* plocal_Hessij = plocal_Hessi->
get_v() + 1;
242 int* plre_indexj = lre_index.
get_v() + 1;
243 for (
int j=1;j<=num_local_re;j++)
245 int lrej = *plre_indexj;
246 int j1 = list(lrej,1);
257 plocal_Hessi = &local_Hess(1);
258 plocal_gradi = local_grad.
get_v() + 1;
259 plre_indexi = lre_index.
get_v() + 1;
260 for (
int i=1;i<=num_local_re;i++)
262 int lrei = *plre_indexi;
271 plocal_gradi = local_grad.
get_v() + 1;
272 plre_indexi = lre_index.
get_v() + 1;
273 for (
int i=1;i<=num_local_re;i++)
275 int lrei = *plre_indexi;
284 double mg=
max(
fabs(local_grad));
288 double* plocal_stepi = local_step.
get_v() + 1;
289 plre_indexi = lre_index.
get_v() + 1;
290 for (
int i=1;i<=num_local_re;i++)
292 int lrei = *plre_indexi;
310 funnel_init_var::num_active_parameters=0;
void initialize(void)
Description not yet available.
df1b2_gradlist * f1b2gradlist
void set_dependent_variable(const df1b2variable &_x)
Description not yet available.
static adpool * adpool_vector[]
static void set_no_derivatives(void)
int separable_calls_counter
Description not yet available.
Description not yet available.
void do_separable_stuff(void)
Description not yet available.
Vector of double precision numbers.
static re_objective_function_value * pobjfun
static int num_inactive_vars
df1_two_variable fabs(const df1_two_variable &x)
void do_separable_stuff_laplace_approximation_importance_sampling_adjoint(df1b2variable &)
Description not yet available.
void initialize(void)
Description not yet available.
void do_separable_stuff_laplace_approximation_banded(df1b2variable &)
Description not yet available.
Description not yet available.
void get_block_diagonal_hessian(df1b2variable &)
Description not yet available.
static df1b2variable * funnel_constraints_penalty
void initialize(void)
Description not yet available.
void do_separable_stuff_newton_raphson_block_diagonal(df1b2variable &)
Description not yet available.
dvector solve(const dmatrix &aa, const dvector &z)
Solve a linear system using LU decomposition.
prnstream & endl(prnstream &)
Array of integers(int) with indexes from index_min to indexmax.
static unsigned int num_active_parameters
Description not yet available.
Description not yet available.
void do_separable_stuff_newton_raphson_banded(df1b2variable &)
Description not yet available.
void do_separable_stuff_laplace_approximation_banded_adjoint(const df1b2variable &ff)
Description not yet available.
Description not yet available.
static int saddlepointflag
void do_separable_stuff_hessian_type_information(void)
Description not yet available.
void do_separable_stuff_x_u_block_diagonal(df1b2variable &ff)
Description not yet available.
static unsigned int num_vars
static init_df1b2vector * py
void initialize(void)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
void do_separable_stuff_laplace_approximation_block_diagonal(df1b2variable &)
Calculates the Laplace approximation for a single separable function in the "block diagonal"...
void reset(void)
Description not yet available.
int have_bounded_random_effects
void df1b2_gradcalc1(void)
Description not yet available.