63 cerr <<
"can only delete last member" <<
endl;
97 cout <<
" Pool depth " << i <<
" "
162 int found_pool_flag=0;
172 if (!found_pool_flag)
177 cerr <<
"Memory allocation error" <<
endl;
210 cerr <<
"Memory allocation error" <<
endl;
253 cerr <<
"memory allocation error" <<
endl;
273 cerr <<
"memory allocation error" <<
endl;
278 for(
unsigned int i=0;i<
num_vars;i++)
284 for(
unsigned int i=0;i<
num_vars;i++)
311 ind_index=
x.get_ind_index();
314 add_to_inactive_list();
322 cout <<
"This can't happen" <<
endl;
326 lapprox->used_flags(ind_index)+=1;
348 add_to_inactive_list();
353 lapprox->used_flags(ind_index)+=1;
364 cerr <<
"Haven't defined htis yet" <<
endl;
380 add_to_inactive_list();
435 add_to_inactive_list();
440 lapprox->used_flags(ind_index)+=1;
441 if (lapprox->calling_set)
443 int j=++(*lapprox->calling_set)(ind_index,0);
444 int k=lapprox->used_flags(ind_index);
447 cerr <<
"This can't happen" <<
endl;
450 (*lapprox->calling_set)(ind_index,j)=(*lapprox->calling_set)(0,0);
509 df1b2variable::operator =
522 cerr <<
"the bounded matrix case in "
523 " void funnel_init_df1b2variable::xinit has not bee implemented"
560 if (ind_index <=lapprox->
xsize )
562 cout <<
" fixed effect used " << uf <<
" times" <<
endl;
569 cout <<
" Error random effect used " << uf <<
" times" <<
endl;
587 const double l4=
log(4.0);
588 double wght=.000001/diff;
589 pen-=wght*(
log(ss+
double(1.e-40))+
log((
double(1.0)-ss)
590 +
double(1.e-40))+l4);
601 cerr <<
"the bounded matrix case in "
602 " void funnel_init_df1b2variable::xinit has not bee implemented"
617 for (
unsigned int i=0;i<
num_vars;i++)
624 return (
unsigned int)n;
652 cerr <<
"the bounded matrix case in "
653 " void funnel_init_df1b2variable::xinit has not bee implemented"
685 cerr <<
"the bounded matrix case in "
686 " void funnel_init_df1b2variable::xinit has not bee implemented"
712 *(pyii->
get_v() + 2) = ii;
724 for (
unsigned int i=0;i<
num_vars;i++)
729 if (funnel_init_var::funnel_constraints_penalty)
733 funnel_init_var::funnel_constraints_penalty=
new df1b2variable(pen);
773 int ind_index =
x(mmin).get_ind_index();
781 for (
int i=mmin;i<=mmax;i++)
783 ind_index =
x(i).get_ind_index();
819 for (i=mmin;i<=mmax;i++)
838 for (
int i=mmin;i<=mmax;i++)
841 *(pyii->
get_v() + 1) = ( *vp)(i).get_ind_index();
842 *(pyii->
get_v() + 2) = ii;
861 for (i=mmin;i<=mmax;i++)
863 (*this)(i) = (
x(ii++));
881 int mmin=x.indexmin();
882 int mmax=x.indexmax();
883 int ind_index =
x(mmin).get_ind_index();
916 for (i=mmin;i<=mmax;i++)
932 for (i=mmin;i<=mmax;i++)
953 for (i=mmin;i<=mmax;i++)
955 (*this)(i) = (
x(ii++));
964 (*this)(i) = (
x(ii));
965 *((*this)(i).get_u()) =
static int straight_through_flag
static funnel_init_var * inactive_list[2000]
~funnel_init_df1b2vector()
Destructor.
static void allocate_all(void)
Description not yet available.
virtual void set_value(const init_df1b2vector &, const int &ii, const df1b2variable &)
Description not yet available.
df1b2_gradlist * f1b2gradlist
static adpool * adpool_vector[]
static void set_no_derivatives(void)
Description not yet available.
void allocate(void)
Description not yet available.
Description not yet available.
Description not yet available.
virtual void preallocate(const df1b2variable &)
Description not yet available.
virtual void set_index(imatrix &, int &ii)
Description not yet available.
df1b2variable & operator=(const df3_one_variable &v)
#define ADUNCONST(type, obj)
Creates a shallow copy of obj that is not CONST.
Vector of double precision numbers.
Description not yet available.
Description not yet available.
static unsigned int nvar_vector[]
static void set_blocksize(void)
Description not yet available.
static re_objective_function_value * pobjfun
static int num_inactive_vars
Description not yet available.
virtual void set_index(imatrix &, int &ii)
Description not yet available.
static const int adpool_vectorsize
virtual void xinit(init_df1b2vector &, int &ii)
Description not yet available.
Description not yet available.
static funnel_init_var * list[2000]
Description not yet available.
virtual void set_index(imatrix &, int &ii)
Description not yet available.
Description not yet available.
funnel_init_bounded_df1b2vector(const df1b2_init_bounded_vector &x)
Description not yet available.
void deallocate(void)
If no other copies exist, free df1b2variable::ptr.
static int adpool_use_index[]
static df1b2variable * funnel_constraints_penalty
int depth_check(void)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
static laplace_approximation_calculator * lapprox
virtual void set_value(const init_df1b2vector &, const int &ii, const df1b2variable &)
Description not yet available.
prnstream & endl(prnstream &)
double boundpin(double x, double fmin, double fmax, double s)
Scale model variable over [-1,1]; constant objects.
Array of integers(int) with indexes from index_min to indexmax.
void allocate(void)
Description not yet available.
static unsigned int num_active_parameters
virtual void xinit(init_df1b2vector &, int &ii)=0
static int no_derivatives
Description not yet available.
virtual void allocate(void)
Description not yet available.
int nvar_calc(void)
Description not yet available.
funnel_init_df1b2vector()
void deallocate(void)
If no other copies exists, free allocated memory.
virtual void xinit(init_df1b2vector &, int &ii)
Description not yet available.
funnel_init_df1b2variable(void)
Description not yet available.
static void deallocate_all(void)
Release memory.
Description not yet available.
void add_to_list(void)
Description not yet available.
Description not yet available.
virtual void set_value(const init_df1b2vector &, const int &ii)
Description not yet available.
Description not yet available.
dvariable boundp(const prevariable &x, double fmin, double fmax, const prevariable &_fpen, double s)
Compute penalty for exceeding bounds on parameter; variable ojbects.
void add_to_inactive_list(void)
Description not yet available.
static void increment_adpool_counter(void)
Description not yet available.
virtual void xinit(init_df1b2vector &, int &ii)
Description not yet available.
dvector value(const df1_one_vector &v)
virtual void allocate(void)
Description not yet available.
static unsigned int num_vars
static init_df1b2vector * py
void check_pool_depths(void)
Description not yet available.
static int adpool_counter
virtual void set_value(const init_df1b2vector &, const int &ii, const df1b2variable &)=0
int nvar_calc(void)
Description not yet available.
void allocate(void)
Initialize df1b2vector to empty.
void reset(void)
Description not yet available.
const df1b2_init_bounded_vector * p
void delete_from_list(void)
Description not yet available.
funnel_dependent_df1b2variable(const df1b2variable &)
Description not yet available.
virtual void set_index(imatrix &, int &ii)=0
d3_array log(const d3_array &arr3)
Author: David Fournier Copyright (c) 2008-2012 Regents of the University of California.
static int current_allocation_index
static unsigned int nvarcalc_all()
Description not yet available.
virtual int nvar_calc(void)=0
static void reset(init_df1b2vector &x)
Description not yet available.