Revision 1110 trunk/src/df1b2-separable/df1b2qnm.cpp

df1b2qnm.cpp (revision 1110)
2 2
 * $Id$
3 3
 *
4 4
 * Author: David Fournier
5
 * Copyright (c) 2008-2012 Regents of the University of California 
5
 * Copyright (c) 2008-2012 Regents of the University of California
6 6
 */
7 7
/**
8 8
 * \file
......
37 37
      cerr << "Usage -fntrap option needs two non-negative integers  -- ignored" << endl;
38 38
    }
39 39
    else
40
    {   
40
    {
41 41
      ifn_trap=atoi(ad_comm::argv[on+1]);
42 42
      itn_trap=atoi(ad_comm::argv[on+2]);
43 43
    }
......
49 49
  // block for quasi-newton minimization
50 50
  //int itnold=0;
51 51
  int nx=nvar;
52
  if (negdirections) 
52
  if (negdirections)
53 53
  {
54
    nx=negdirections->indexmax(); 
54
    nx=negdirections->indexmax();
55 55
  }
56 56
  fmm fmc(nx);
57 57
  int on1;
......
68 68
      //fmc.iprint=iprint;
69 69
    }
70 70
    else
71
    {   
71
    {
72 72
      int jj=atoi(ad_comm::argv[on1+1]);
73 73
      fmc.dcheck_flag=jj;
74 74
    }
......
82 82
      fmc.iprint=iprint;
83 83
    }
84 84
    else
85
    {   
85
    {
86 86
      int jj=atoi(ad_comm::argv[on1+1]);
87 87
      fmc.iprint=jj;
88 88
    }
......
103 103
      cerr << "Usage -dfn option needs number  -- ignored" << endl;
104 104
    }
105 105
    else
106
    {   
107
  
106
    {
108 107
      istringstream ist(ad_comm::argv[on+1]);
109 108
      ist >> _dfn;
110
  
109

  
111 110
      if (_dfn<=0)
112 111
      {
113 112
        cerr << "Usage -dfn option needs positive number  -- ignored" << endl;
114 113
        _dfn=0.0;
115
      } 
114
      }
116 115
    }
117 116
  }
118
  if (_dfn>0) 
117
  if (_dfn>0)
119 118
  {
120 119
    fmc.dfn=_dfn;
121 120
  }
......
143 142
  int unvar=1;
144 143
  if (random_effects_flag)
145 144
  {
146
    initial_params::set_active_only_random_effects(); 
145
    initial_params::set_active_only_random_effects();
147 146
    //cout << nvar << endl;
148 147
    unvar=initial_params::nvarcalc(); // get the number of active
149
    initial_params::restore_start_phase(); 
150
    initial_params::set_inactive_random_effects(); 
148
    initial_params::restore_start_phase();
149
    initial_params::set_inactive_random_effects();
151 150
    int nvar1=initial_params::nvarcalc(); // get the number of active
152 151
    if (nvar1 != nvar)
153 152
    {
......
232 231
    // this turns on random effects variables and turns off
233 232
    // everything else
234 233
    //cout << nvar << endl;
235
    initial_params::set_active_only_random_effects(); 
234
    initial_params::set_active_only_random_effects();
236 235
    //cout << nvar << endl;
237 236
    int unvar=initial_params::nvarcalc(); // get the number of active
238 237
    //df1b2_gradlist::set_no_derivatives();
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff