| 117 | */ |
| 118 | |
| 119 | void updateDims( const int aParamCount, const int PopSize0 = 0 ) |
| 120 | { |
| 121 | const int aPopSize = ( PopSize0 > 0 ? PopSize0 : |
| 122 | calcPopSizeBiteOpt( aParamCount )); |
| 123 | |
| 124 | if( aParamCount == ParamCount && aPopSize == PopSize ) |
| 125 | { |
| 126 | return; |
| 127 | } |
| 128 | |
| 129 | initBuffers( aParamCount, aPopSize ); |
| 130 | setParPopCount( 5 ); |
| 131 | |
| 132 | ParOpt.updateDims( aParamCount, 11 + aPopSize / 3 ); |
| 133 | ParOptPop.initBuffers( aParamCount, aPopSize ); |
| 134 | |
| 135 | ParOpt2.updateDims( aParamCount, aPopSize ); |
| 136 | ParOpt2Pop.initBuffers( aParamCount, aPopSize ); |
| 137 | |
| 138 | OldPops[ 0 ].initBuffers( aParamCount, aPopSize ); |
| 139 | OldPops[ 1 ].initBuffers( aParamCount, aPopSize ); |
| 140 | } |
| 141 | |
| 142 | /** |
| 143 | * Function initializes *this optimizer. Does not perform objective |
no test coverage detected