/* Local variables */
double f;
int i__, j, k, ih, jp, ip, iq, np, iw;
- double xp, xq, den;
- int ihp;
+ double xp = 0.0, xq, den;
+ int ihp = 0;
double one;
int ihq, jpn, kpt;
double sum, diff, half, beta;
double slbd;
int iubd;
double vlag, subd, temp;
- int ksav;
- double step, zero, curv;
+ int ksav = 0;
+ double step = 0.0, zero, curv;
int iflag;
- double scale, csave, tempa, tempb, tempd, const__, sumin, ggfree;
- int ibdsav;
- double dderiv, bigstp, predsq, presav, distsq, stpsav, wfixsq, wsqsav;
+ double scale, csave = 0.0, tempa, tempb, tempd, const__, sumin, ggfree;
+ int ibdsav = 0;
+ double dderiv, bigstp, predsq, presav, distsq, stpsav = 0.0, wfixsq, wsqsav;
/* The arguments N, NPT, XPT, XOPT, BMAT, ZMAT, NDIM, SL and SU all have */
double ds;
int iu;
double dhd, dhs, cth, one, shs, sth, ssq, half, beta, sdec, blen;
- int iact, nact;
+ int iact = 0, nact;
double angt, qred;
int isav;
- double temp, zero, xsav, xsum, angbd, dredg, sredg;
+ double temp, zero, xsav = 0.0, xsum, angbd = 0.0, dredg = 0.0, sredg = 0.0;
int iterc;
- double resid, delsq, ggsav, tempa, tempb, ratio, sqstp, redmax,
- dredsq, redsav, onemin, gredsq, rednew;
- int itcsav;
- double rdprev, rdnext, stplen, stepsq;
- int itermax;
+ double resid, delsq, ggsav = 0.0, tempa, tempb, ratio, sqstp, redmax,
+ dredsq = 0.0, redsav, onemin, gredsq = 0.0, rednew;
+ int itcsav = 0;
+ double rdprev, rdnext = 0.0, stplen, stepsq;
+ int itermax = 0;
/* The arguments N, NPT, XPT, XOPT, GOPT, HQ, PQ, SL and SU have the same */
double f;
int i__, j, k, ih, np, nfm;
double one;
- int nfx, ipt, jpt;
- double two, fbeg, diff, half, temp, zero, recip, stepa, stepb;
+ int nfx, ipt = 0, jpt = 0;
+ double two, fbeg, diff, half, temp, zero, recip, stepa = 0.0, stepb = 0.0;
int itemp;
double rhosq;
int kopt, nptm;
double zero, curv;
int ksav;
- double gqsq, dist, sumw, sumz, diffa, diffb, diffc, hdiag;
+ double gqsq, dist, sumw, sumz, diffa, diffb, diffc = 0.0, hdiag;
int kbase;
double alpha, delta, adelt, denom, fsave, bdtol, delsq;
int nresc, nfsav;
int ivmc;
int ivmd;
int mp, np, iz, ibrnch;
- int nbest, ifull, iptem, jdrop;
+ int nbest, ifull = 0, iptem, jdrop;
nlopt_result rc = NLOPT_SUCCESS;
uint32_t seed = (uint32_t) (*n + *m); /* arbitrary deterministic LCG seed */
int feasible;
/* Builtin functions */
/* Local variables */
- double a, b;
+ double a = 0.0, b = 0.0;
int i__, n;
double p, r__;
int kd, ld;
double d__1, d__2;
/* Local variables */
- double a, b, c__, d__, den, dis;
+ double a = 0.0, b = 0.0, c__, d__, den = 0.0, dis;
int ntyp;
*merr = 0;
double *xcur, rho, *sigma, *dfdx, *dfdx_cur, *xprev, *xprevprev, fcur;
double *dfcdx, *dfcdx_cur;
double *fcval, *fcval_cur, *rhoc, *gcval, *y, *dual_lb, *dual_ub;
- double *pre_lb, *pre_ub;
+ double *pre_lb = NULL, *pre_ub = NULL;
unsigned i, ifc, j, k = 0;
dual_data dd;
int feasible;
/* Local variables */
int i__, j, k;
- double dd, cf, dg, gg;
+ double dd = 0.0, cf, dg, gg = 0.0;
int ih;
- double ds, sg;
+ double ds, sg = 0.0;
int iu;
- double ss, dhd, dhs, cth, sgk, shs, sth, qadd, half, qbeg, qred, qmin,
- temp, qsav, qnew, zero, ggbeg, alpha, angle, reduc;
+ double ss, dhd, dhs, cth, sgk, shs = 0.0, sth, qadd, half, qbeg, qred = 0.0, qmin,
+ temp, qsav, qnew, zero, ggbeg = 0.0, alpha, angle, reduc;
int iterc;
- double ggsav, delsq, tempa, tempb;
+ double ggsav, delsq, tempa = 0.0, tempb = 0.0;
int isave;
- double bstep, ratio, twopi;
+ double bstep = 0.0, ratio, twopi;
int itersw;
double angtest;
int itermax;
int nptm;
double zero, angle, scale, denom;
int iterc, isave;
- double delsq, tempa, tempb, twopi, taubeg, tauold, taumax;
+ double delsq, tempa, tempb = 0.0, twopi, taubeg, tauold, taumax;
/* N is the number of variables. */
int nptm;
double zero;
int iflag;
- double scala, scalb_, alpha, denom, tempa, tempb, tausq;
+ double scala, scalb_, alpha, denom, tempa, tempb = 0.0, tausq;
/* The arrays BMAT and ZMAT with IDZ are updated, in order to shift the */
double d__1, d__2, d__3;
/* Local variables */
- double f;
+ double f = 0.0;
int i__, j, k, ih, nf, nh, ip, jp;
double dx;
int np, nfm;
double one;
int idz;
- double dsq, rho;
- int ipt, jpt;
- double sum, fbeg, diff, half, beta;
+ double dsq, rho = 0.0;
+ int ipt = 0, jpt = 0;
+ double sum, fbeg = 0.0, diff, half, beta;
int nfmm;
double gisq;
int knew;
double temp, suma, sumb, fopt = HUGE_VAL, bsum, gqsq;
int kopt, nptm;
- double zero, xipt, xjpt, sumz, diffa, diffb, diffc, hdiag, alpha,
+ double zero, xipt = 0.0, xjpt = 0.0, sumz, diffa = 0.0, diffb = 0.0, diffc = 0.0, hdiag, alpha = 0.0,
delta, recip, reciq, fsave;
- int ksave, nfsav, itemp;
- double dnorm, ratio, dstep, tenth, vquad;
+ int ksave, nfsav = 0, itemp;
+ double dnorm = 0.0, ratio = 0.0, dstep, tenth, vquad;
int ktemp;
double tempq;
- int itest;
+ int itest = 0;
double rhosq;
- double detrat, crvmin;
+ double detrat, crvmin = 0.0;
double distsq;
- double xoptsq;
+ double xoptsq = 0.0;
double rhoend;
nlopt_result rc = NLOPT_SUCCESS, rc2;
/* Local variables */
double *e; /* size n */
- double c__, f, g, h__;
+ double c__, f = 0.0, g, h__;
int i__, j, k, l;
double s, x, y, z__;
int l2, ii, kk, kt, ll2, lp1;
double up;
int iz1, iz2, npp1, iter;
double wmax, alpha, asave;
- int itmax, izmax, nsetp;
+ int itmax, izmax = 0, nsetp;
double unorm;
/* C.L.LAWSON AND R.J.HANSON, JET PROPULSION LABORATORY: */