- 001
- 002
- 003
- 004
- 005
- 006
- 007
- 008
- 009
- 010
- 011
- 012
- 013
- 014
- 015
- 016
- 017
- 018
- 019
- 020
- 021
- 022
- 023
- 024
- 025
- 026
- 027
- 028
- 029
- 030
- 031
- 032
- 033
- 034
- 035
- 036
- 037
- 038
- 039
- 040
- 041
- 042
- 043
- 044
- 045
- 046
- 047
- 048
- 049
- 050
- 051
- 052
- 053
- 054
- 055
- 056
- 057
- 058
- 059
- 060
- 061
- 062
- 063
- 064
- 065
- 066
- 067
- 068
- 069
- 070
- 071
- 072
- 073
- 074
- 075
- 076
- 077
- 078
- 079
- 080
- 081
- 082
- 083
- 084
- 085
- 086
- 087
- 088
- 089
- 090
- 091
- 092
- 093
- 094
- 095
- 096
- 097
- 098
- 099
- 100
/* ../COBYLA2/cobyla2.f -- translated by f2c (version 20100827) */
...
/* Subroutine */ int cobyla_(integer *n, integer *m, doublereal *x,
doublereal *rhobeg, doublereal *rhoend, integer *iprint, integer *
maxfun, doublereal *w, integer *iact)
{
static integer ia, idx, mpp, icon, isim, isigb, idatm, iveta, isimi,
ivsig, iwork;
extern /* Subroutine */ int cobylb_(integer *, integer *, integer *,
doublereal *, doublereal *, doublereal *, integer *, integer *,
doublereal *, doublereal *, doublereal *, doublereal *,
doublereal *, doublereal *, doublereal *, doublereal *,
doublereal *, doublereal *, integer *);
/* Parameter adjustments */
--iact;
--w;
--x;
/* Function Body */
mpp = *m + 2;
icon = 1;
isim = icon + mpp;
isimi = isim + *n * *n + *n;
idatm = isimi + *n * *n;
ia = idatm + *n * mpp + mpp;
ivsig = ia + *m * *n + *n;
iveta = ivsig + *n;
isigb = iveta + *n;
idx = isigb + *n;
iwork = idx + *n;
cobylb_(n, m, &mpp, &x[1], rhobeg, rhoend, iprint, maxfun, &w[icon], &w[
isim], &w[isimi], &w[idatm], &w[ia], &w[ivsig], &w[iveta], &w[
isigb], &w[idx], &w[iwork], &iact[1]);
return 0;
} /* cobyla_ */
...
/* Subroutine */ int cobylb_(integer *n, integer *m, integer *mpp, doublereal
*x, doublereal *rhobeg, doublereal *rhoend, integer *iprint, integer *
maxfun, doublereal *con, doublereal *sim, doublereal *simi,
doublereal *datmat, doublereal *a, doublereal *vsig, doublereal *veta,
doublereal *sigbar, doublereal *dx, doublereal *w, integer *iact)
{
/* Format strings */
static char fmt_10[] = "(/3x,\002The initial value of RHO is\002,1pe13.6"
",2x,\002and PARMU is set to zero.\002)";
static char fmt_50[] = "(/3x,\002Return from subroutine COBYLA because t"
"he \002,\002MAXFUN limit has been reached.\002)";
static char fmt_70[] = "(/3x,\002NFVALS =\002,i5,3x,\002F =\002,1pe13.6,"
"4x,\002MAXCV =\002,1pe13.6/3x,\002X =\002,1pe13.6,1p4e15.6)";
static char fmt_80[] = "(1pe19.6,1p4e15.6)";
static char fmt_210[] = "(/3x,\002Return from subroutine COBYLA because"
" \002,\002rounding errors are becoming damaging.\002)";
static char fmt_410[] = "(/3x,\002Increase in PARMU to\002,1pe13.6)";
static char fmt_580[] = "(/3x,\002Reduction in RHO to\002,1pe13.6,\002 "
"and PARMU =\002,1pe13.6)";
static char fmt_590[] = "(/3x,\002Normal return from subroutine COBYL"
"A\002)";
/* System generated locals */
integer sim_dim1, sim_offset, simi_dim1, simi_offset, datmat_dim1,
datmat_offset, a_dim1, a_offset, i__1, i__2, i__3;
doublereal d__1, d__2;
/* Builtin functions */
integer s_wsfe(cilist *), do_fio(integer *, char *, ftnlen), e_wsfe(void);
double sqrt(doublereal);
/* Local variables */
static doublereal f;
static integer i__, j, k, l, mp, np, iz;
static doublereal phi, rho, sum, beta, cmin, cmax;
static integer ivmc;
static doublereal weta;
static integer ivmd;
static doublereal temp, wsig, gamma;
static integer iflag;
static doublereal alpha, delta, denom, tempa, barmu;
static integer nbest, ifull, iptem, jdrop;
static doublereal ratio, vmold, parmu, error, vmnew;
extern /* Subroutine */ int calcfc_(integer *, integer *, doublereal *,
doublereal *, doublereal *);
static integer ibrnch;
static doublereal edgmax, pareta, prerec, phimin, parsig;
static integer isdirn, nfvals, izdota;
static doublereal cvmaxm, dxsign, prerem;
static integer iptemp;
static doublereal resmax, cvmaxp;
static integer idxnew;
static doublereal resnew, trured;
extern /* Subroutine */ int trstlp_(integer *, integer *, doublereal *,
doublereal *, doublereal *, doublereal *, integer *, integer *,
doublereal *, doublereal *, doublereal *, doublereal *,
doublereal *, doublereal *);
/* Fortran I/O blocks */
static cilist io___22 = { 0, 6, 0, fmt_10, 0 };
static cilist io___29 = { 0, 6, 0, fmt_50, 0 };
static cilist io___33 = { 0, 6, 0, fmt_70, 0 };
static cilist io___34 = { 0, 6, 0, fmt_80, 0 };
static cilist io___39 = { 0, 6, 0, fmt_210, 0 };
Найдено в зависимостях «SlangTNG». Библиотека «COBYLA», автоматически переведённая с «Фортрана».
/* This subroutine minimizes an objective function F(X) subject to M */
/* inequality constraints on X, where X is a vector of variables that has */
/* N components. The algorithm employs linear approximations to the */
/* objective and constraint functions, the approximations being formed by */
/* linear interpolation at N+1 points in the space of the variables. */
https://tng.tuxfamily.org/index.php?title=Main_Page