Revision 692 branches/merge-trunk-davef/src/nh99/mod_hess.cpp

mod_hess.cpp (revision 692)
476 476
  gradcalc(0,ggg);
477 477
  gradient_structure::set_YES_DERIVATIVES();
478 478
  initial_params::restore_start_phase();
479
#if defined(USE_LAPLACE)
480
  if (lapprox  && lapprox->no_re_ders_flag)
481
  {
482
    initial_params::set_inactive_only_random_effects();
483
  }
484
#endif
479 485
  int nvar=initial_params::nvarcalc(); // get the number of active parameters
480 486
  int ndvar=stddev_params::num_stddev_calc();
481 487
  independent_variables x(1,nvar);
......
604 610
  {
605 611
    ofstream ofs3((char*)(ad_comm::adprogram_name + adstring(".eva")));
606 612
    {
607
      dvector se=eigenvalues(hess);
613
      dvector se=sort(eigenvalues(hess));
608 614
      ofs3 << setshowpoint() << setw(14) << setprecision(10)
609
	 << "unsorted:\t" << se << endl;
610
     se=sort(se);
611
     ofs3 << setshowpoint() << setw(14) << setprecision(10)
612
     << "sorted:\t" << se << endl;
613
     if (se(se.indexmin())<=0.0)
615
	 << se << endl;
616
      if (se(se.indexmin())<=0.0)
614 617
      {
615 618
#if defined(USE_LAPLACE)
616 619
        negative_eigenvalue_flag=1;

Also available in: Unified diff