mirror of
https://git.dev.opencascade.org/repos/occt.git
synced 2025-08-04 13:13:25 +03:00
0022550: Fixing data races
This commit is contained in:
@@ -49,25 +49,7 @@ class ApproxAFunc2Var from AdvApp2Var
|
||||
-- and Num3DSS must be equal to 1.
|
||||
-- Warning:
|
||||
-- the Function of type EvaluatorFunc2Var from Approx
|
||||
-- must be an extern "C" function
|
||||
--
|
||||
-- The evaluator Function has the following type :
|
||||
-- typedef void (* AdvApp2Var_EvaluatorFunc2Var)
|
||||
-- (Standard_Integer *, // Total Dimension
|
||||
-- Standard_Real *, // StartEndInU[2]
|
||||
-- Standard_Real *, // StartEndInV[2]
|
||||
-- Standard_Integer *, // 1 for U = cte
|
||||
-- // 2 for V = cte
|
||||
-- Standard_Real *, // Value of cte
|
||||
-- Standard_Integer *, // Number N of parameters
|
||||
-- Standard_Real *, // Tab[N] of parameters at
|
||||
-- // which evaluation
|
||||
-- // should take place
|
||||
-- Standard_Integer *, // U-Derivative Request
|
||||
-- Standard_Integer *, // V-Derivative Request
|
||||
-- Standard_Real *, // Result[Dimension,N]
|
||||
-- Standard_Integer * // Error Code
|
||||
-- ) ;
|
||||
-- must be a subclass of AdvApp2Var_EvaluatorFunc2Var
|
||||
--
|
||||
-- the result should be formatted in the following way :
|
||||
-- <--Num1DSS--> <--2 * Num2DSS--> <--3 * Num3DSS-->
|
||||
@@ -379,8 +361,6 @@ fields
|
||||
myMaxPatches : Integer ;
|
||||
-- maximum of patches allowed
|
||||
--
|
||||
myEvaluator : EvaluatorFunc2Var from AdvApp2Var ;
|
||||
-- external function
|
||||
--
|
||||
myConditions : Context from AdvApp2Var;
|
||||
myResult : Network from AdvApp2Var;
|
||||
|
@@ -78,7 +78,6 @@ myPrecisionCode(PrecisCode),
|
||||
myMaxDegInU(MaxDegInU),
|
||||
myMaxDegInV(MaxDegInV),
|
||||
myMaxPatches(MaxPatch),
|
||||
myEvaluator(Func),
|
||||
myDone(Standard_False),
|
||||
myHasResult(Standard_False)
|
||||
{
|
||||
@@ -86,7 +85,7 @@ myHasResult(Standard_False)
|
||||
myNumSubSpaces[1] = Num2DSS;
|
||||
myNumSubSpaces[2] = Num3DSS;
|
||||
Init();
|
||||
Perform(UChoice,VChoice,Func);
|
||||
Perform(UChoice, VChoice, Func);
|
||||
ConvertBS();
|
||||
}
|
||||
|
||||
@@ -137,7 +136,6 @@ myPrecisionCode(PrecisCode),
|
||||
myMaxDegInU(MaxDegInU),
|
||||
myMaxDegInV(MaxDegInV),
|
||||
myMaxPatches(MaxPatch),
|
||||
myEvaluator(Func),
|
||||
myDone(Standard_False),
|
||||
myHasResult(Standard_False)
|
||||
{
|
||||
@@ -145,7 +143,7 @@ myHasResult(Standard_False)
|
||||
myNumSubSpaces[1] = Num2DSS;
|
||||
myNumSubSpaces[2] = Num3DSS;
|
||||
Init();
|
||||
Perform(UChoice,VChoice,Func,Crit);
|
||||
Perform(UChoice, VChoice, Func, Crit);
|
||||
ConvertBS();
|
||||
}
|
||||
|
||||
|
@@ -130,19 +130,7 @@ static
|
||||
int mma2ds2_(integer *ndimen,
|
||||
doublereal *uintfn,
|
||||
doublereal *vintfn,
|
||||
void (*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *nbpntu,
|
||||
integer *nbpntv,
|
||||
doublereal *urootb,
|
||||
@@ -162,19 +150,7 @@ int mma2ds2_(integer *ndimen,
|
||||
static
|
||||
int mma1fdi_(integer *ndimen,
|
||||
doublereal *uvfonc,
|
||||
void (*foncnp) (// see AdvApp2Var_EvaluatorFunc2Var.hxx for details
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *isofav,
|
||||
doublereal *tconst,
|
||||
integer *nbroot,
|
||||
@@ -293,7 +269,7 @@ int mma1cdi_(integer *ndimen,
|
||||
somtab_dim1, somtab_offset, diftab_dim1, diftab_offset,
|
||||
fpntab_dim1, fpntab_offset, hermit_dim1, hermit_offset, i__1,
|
||||
i__2, i__3;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer nroo2, ncfhe, nd, ii, kk;
|
||||
static integer ibb, kkm, kkp;
|
||||
@@ -512,12 +488,12 @@ int mma1cnt_(integer *ndimen,
|
||||
integer contr1_dim1, contr1_offset, contr2_dim1, contr2_offset,
|
||||
hermit_dim1, hermit_offset, crvjac_dim1, crvjac_offset, i__1,
|
||||
i__2, i__3;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer nd, ii, jj, ibb;
|
||||
static doublereal bid;
|
||||
|
||||
|
||||
|
||||
|
||||
/* ***********************************************************************
|
||||
*/
|
||||
|
||||
@@ -631,19 +607,7 @@ int mma1cnt_(integer *ndimen,
|
||||
//=======================================================================
|
||||
int mma1fdi_(integer *ndimen,
|
||||
doublereal *uvfonc,
|
||||
void (*foncnp) (// see AdvApp2Var_EvaluatorFunc2Var.hxx for details
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *isofav,
|
||||
doublereal *tconst,
|
||||
integer *nbroot,
|
||||
@@ -662,13 +626,13 @@ int mma1fdi_(integer *ndimen,
|
||||
diftab_offset, contr1_dim1, contr1_offset, contr2_dim1,
|
||||
contr2_offset, i__1, i__2;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ideb, ifin, nroo2, ideru, iderv;
|
||||
static doublereal renor;
|
||||
static integer ii, nd, ibb, iim, nbp, iip;
|
||||
static doublereal bid1, bid2;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -819,7 +783,7 @@ int mma1fdi_(integer *ndimen,
|
||||
/* ---------------------- Legendre polynom of degree NBROOT -------------------
|
||||
*/
|
||||
|
||||
(*foncnp)(ndimen,
|
||||
foncnp.Evaluate (ndimen,
|
||||
&uvfonc[3],
|
||||
&uvfonc[5],
|
||||
isofav,
|
||||
@@ -891,8 +855,8 @@ int mma1fdi_(integer *ndimen,
|
||||
bid1 = (uvfonc[6] - uvfonc[5]) / 2.;
|
||||
i__1 = *iordre;
|
||||
for (iderv = 1; iderv <= i__1; ++iderv) {
|
||||
(*foncnp)(ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst, &
|
||||
nbp, ttable, &ideru, &iderv, &contr1[(iderv + 1) *
|
||||
foncnp.Evaluate (ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst,
|
||||
&nbp, ttable, &ideru, &iderv, &contr1[(iderv + 1) *
|
||||
contr1_dim1 + 1], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
@@ -901,8 +865,8 @@ int mma1fdi_(integer *ndimen,
|
||||
}
|
||||
i__1 = *iordre;
|
||||
for (iderv = 1; iderv <= i__1; ++iderv) {
|
||||
(*foncnp)(ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst, &
|
||||
nbp, &ttable[*nbroot + 1], &ideru, &iderv, &contr2[(
|
||||
foncnp.Evaluate (ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst,
|
||||
&nbp, &ttable[*nbroot + 1], &ideru, &iderv, &contr2[(
|
||||
iderv + 1) * contr2_dim1 + 1], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
@@ -915,8 +879,8 @@ int mma1fdi_(integer *ndimen,
|
||||
bid1 = (uvfonc[4] - uvfonc[3]) / 2.;
|
||||
i__1 = *iordre;
|
||||
for (ideru = 1; ideru <= i__1; ++ideru) {
|
||||
(*foncnp)(ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst, &
|
||||
nbp, ttable, &ideru, &iderv, &contr1[(ideru + 1) *
|
||||
foncnp.Evaluate (ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst,
|
||||
&nbp, ttable, &ideru, &iderv, &contr1[(ideru + 1) *
|
||||
contr1_dim1 + 1], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
@@ -925,8 +889,8 @@ int mma1fdi_(integer *ndimen,
|
||||
}
|
||||
i__1 = *iordre;
|
||||
for (ideru = 1; ideru <= i__1; ++ideru) {
|
||||
(*foncnp)(ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst, &
|
||||
nbp, &ttable[*nbroot + 1], &ideru, &iderv, &contr2[(
|
||||
foncnp.Evaluate (ndimen, &uvfonc[3], &uvfonc[5], isofav, tconst,
|
||||
&nbp, &ttable[*nbroot + 1], &ideru, &iderv, &contr2[(
|
||||
ideru + 1) * contr2_dim1 + 1], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
@@ -986,12 +950,12 @@ int mma1fer_(integer *,//ndimen,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer crvjac_dim1, crvjac_offset, i__1, i__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer idim, ncfja, ncfnw, ndses, ii, kk, ibb, ier;
|
||||
static integer nbr0;
|
||||
|
||||
|
||||
|
||||
|
||||
/* ***********************************************************************
|
||||
*/
|
||||
|
||||
@@ -1101,7 +1065,7 @@ int mma1fer_(integer *,//ndimen,
|
||||
if (ncfnw <= *ncflim) {
|
||||
mmaperm_(&ncfja, &ndses, &ncfja, iordre, &crvjac[idim *
|
||||
crvjac_dim1], &ncfnw, &errmoy[ii]);
|
||||
*ncoeff = max(ncfnw,*ncoeff);
|
||||
*ncoeff = advapp_max(ncfnw,*ncoeff);
|
||||
|
||||
/* ------------- Set the declined coefficients to 0.D0 -----------
|
||||
-------- */
|
||||
@@ -1180,10 +1144,10 @@ int AdvApp2Var_ApproxF2var::mma1her_(const integer *iordre,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer hermit_dim1, hermit_offset;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ibb;
|
||||
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
@@ -1348,7 +1312,7 @@ int mma1jak_(integer *ndimen,
|
||||
/* System generated locals */
|
||||
integer somtab_dim1, somtab_offset, diftab_dim1, diftab_offset,
|
||||
crvjac_dim1, crvjac_offset, cgauss_dim1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ibb;
|
||||
|
||||
@@ -1463,8 +1427,7 @@ int mma1noc_(doublereal *dfuvin,
|
||||
/* System generated locals */
|
||||
integer i__1;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static doublereal rider, riord;
|
||||
static integer nd, ibb;
|
||||
@@ -1597,12 +1560,10 @@ int mma1nop_(integer *nbroot,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer i__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static doublereal alinu, blinu, alinv, blinv;
|
||||
static integer ii, ibb;
|
||||
|
||||
|
||||
|
||||
/* ***********************************************************************
|
||||
*/
|
||||
@@ -1718,15 +1679,13 @@ int AdvApp2Var_ApproxF2var::mma2ac1_(integer const *ndimen,
|
||||
contr4_dim1, contr4_dim2, contr4_offset, uhermt_dim1,
|
||||
uhermt_offset, vhermt_dim1, vhermt_offset, patjac_dim1,
|
||||
patjac_dim2, patjac_offset, i__1, i__2, i__3, i__4, i__5;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer ndgu, ndgv;
|
||||
static doublereal bidu1, bidu2, bidv1, bidv2;
|
||||
static integer ioru1, iorv1, ii, nd, jj, ku, kv;
|
||||
static doublereal cnt1, cnt2, cnt3, cnt4;
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -1885,7 +1844,7 @@ int AdvApp2Var_ApproxF2var::mma2ac2_(const integer *ndimen,
|
||||
integer crbiv1_dim1, crbiv1_dim2, crbiv1_offset, crbiv2_dim1, crbiv2_dim2,
|
||||
crbiv2_offset, patjac_dim1, patjac_dim2, patjac_offset,
|
||||
vhermt_dim1, vhermt_offset, i__1, i__2, i__3, i__4;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer ndgv1, ndgv2, ii, jj, nd, kk;
|
||||
@@ -2031,14 +1990,11 @@ int AdvApp2Var_ApproxF2var::mma2ac3_(const integer *ndimen,
|
||||
integer crbiu1_dim1, crbiu1_dim2, crbiu1_offset, crbiu2_dim1, crbiu2_dim2,
|
||||
crbiu2_offset, patjac_dim1, patjac_dim2, patjac_offset,
|
||||
uhermt_dim1, uhermt_offset, i__1, i__2, i__3, i__4;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer ndgu1, ndgu2, ii, jj, nd, kk;
|
||||
static doublereal bid1, bid2;
|
||||
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -2180,13 +2136,10 @@ int AdvApp2Var_ApproxF2var::mma2can_(const integer *ncfmxu,
|
||||
/* System generated locals */
|
||||
integer patjac_dim1, patjac_dim2, patjac_offset, patcan_dim1, patcan_dim2,
|
||||
patcan_offset, i__1, i__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer ilon1, ilon2, ii, nd;
|
||||
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -2339,7 +2292,7 @@ int mma2cd1_(integer *ndimen,
|
||||
|
||||
{
|
||||
static integer c__1 = 1;
|
||||
|
||||
|
||||
/* System generated locals */
|
||||
integer contr1_dim1, contr1_dim2, contr1_offset, contr2_dim1, contr2_dim2,
|
||||
contr2_offset, contr3_dim1, contr3_dim2, contr3_offset,
|
||||
@@ -2357,9 +2310,6 @@ int mma2cd1_(integer *ndimen,
|
||||
static doublereal bid1, bid2, bid3, bid4;
|
||||
static doublereal diu1, diu2, div1, div2, sou1, sou2, sov1, sov2;
|
||||
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -2710,7 +2660,7 @@ int mma2cd2_(integer *ndimen,
|
||||
sosotb_dim2, sosotb_offset, diditb_dim1, diditb_dim2,
|
||||
diditb_offset, soditb_dim1, soditb_dim2, soditb_offset,
|
||||
disotb_dim1, disotb_dim2, disotb_offset, i__1, i__2, i__3, i__4;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ncfhv, nuroo, nvroo, ii, nd, jj, kk, ibb, jjm, jjp;
|
||||
static doublereal bid1, bid2, bid3, bid4;
|
||||
@@ -3014,7 +2964,7 @@ int mma2cd3_(integer *ndimen,
|
||||
|
||||
{
|
||||
static integer c__1 = 1;
|
||||
|
||||
|
||||
/* System generated locals */
|
||||
integer sotbu1_dim1, sotbu1_dim2, sotbu1_offset, sotbu2_dim1, sotbu2_dim2,
|
||||
sotbu2_offset, ditbu1_dim1, ditbu1_dim2, ditbu1_offset,
|
||||
@@ -4437,12 +4387,12 @@ L400:
|
||||
|
||||
L600:
|
||||
/* Computing MAX */
|
||||
i__1 = 1, i__2 = (*iordru << 1) + 1, i__1 = max(i__1,i__2);
|
||||
minu = max(i__1,*ndminu);
|
||||
i__1 = 1, i__2 = (*iordru << 1) + 1, i__1 = advapp_max(i__1,i__2);
|
||||
minu = advapp_max(i__1,*ndminu);
|
||||
maxu = *ndguli;
|
||||
/* Computing MAX */
|
||||
i__1 = 1, i__2 = (*iordrv << 1) + 1, i__1 = max(i__1,i__2);
|
||||
minv = max(i__1,*ndminv);
|
||||
i__1 = 1, i__2 = (*iordrv << 1) + 1, i__1 = advapp_max(i__1,i__2);
|
||||
minv = advapp_max(i__1,*ndminv);
|
||||
maxv = *ndgvli;
|
||||
idim = 1;
|
||||
i__1 = *nbsesp;
|
||||
@@ -4482,8 +4432,8 @@ L600:
|
||||
}
|
||||
|
||||
/* --> Return the nb of coeffs of approximation. */
|
||||
*ndegpu = max(*ndegpu,nu);
|
||||
*ndegpv = max(*ndegpv,nv);
|
||||
*ndegpu = advapp_max(*ndegpu,nu);
|
||||
*ndegpv = advapp_max(*ndegpv,nv);
|
||||
idim += ndses;
|
||||
/* L610: */
|
||||
}
|
||||
@@ -4575,12 +4525,12 @@ L600:
|
||||
|
||||
} else {
|
||||
/* Computing MAX */
|
||||
i__2 = 1, i__3 = (*iordru << 1) + 1, i__2 = max(i__2,i__3);
|
||||
minu = max(i__2,*ndminu);
|
||||
i__2 = 1, i__3 = (*iordru << 1) + 1, i__2 = advapp_max(i__2,i__3);
|
||||
minu = advapp_max(i__2,*ndminu);
|
||||
maxu = *ndguli;
|
||||
/* Computing MAX */
|
||||
i__2 = 1, i__3 = (*iordrv << 1) + 1, i__2 = max(i__2,i__3);
|
||||
minv = max(i__2,*ndminv);
|
||||
i__2 = 1, i__3 = (*iordrv << 1) + 1, i__2 = advapp_max(i__2,i__3);
|
||||
minv = advapp_max(i__2,*ndminv);
|
||||
maxv = *ndgvli;
|
||||
if (maxu >= (*iordru + 1) << 1 && maxv >= (*iordrv + 1) << 1) {
|
||||
mma2er2_(ndjacu, ndjacv, &ndses, &minu, &maxu, &minv, &
|
||||
@@ -4623,8 +4573,8 @@ L600:
|
||||
/* --------------- Return the nb of coeff of approximation ---
|
||||
-------- */
|
||||
|
||||
*ndegpu = max(*ndegpu,nu);
|
||||
*ndegpv = max(*ndegpv,nv);
|
||||
*ndegpu = advapp_max(*ndegpu,nu);
|
||||
*ndegpv = advapp_max(*ndegpv,nv);
|
||||
idim += ndses;
|
||||
/* L730: */
|
||||
}
|
||||
@@ -4707,13 +4657,12 @@ int mma2cfu_(integer *ndujac,
|
||||
/* System generated locals */
|
||||
integer sosotb_dim1, disotb_dim1, disotb_offset, soditb_dim1,
|
||||
soditb_offset, diditb_dim1, i__1, i__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer nptu2, nptv2, ii, jj;
|
||||
static doublereal bid0, bid1, bid2;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -4924,12 +4873,11 @@ int mma2cfv_(integer *ndvjac,
|
||||
/* System generated locals */
|
||||
integer chpair_dim1, chpair_offset, chimpr_dim1, chimpr_offset,
|
||||
patjac_offset, i__1, i__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer nptv2, ii, jj;
|
||||
static doublereal bid1;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -5063,19 +5011,7 @@ int mma2cfv_(integer *ndvjac,
|
||||
int AdvApp2Var_ApproxF2var::mma2ds1_(integer *ndimen,
|
||||
doublereal *uintfn,
|
||||
doublereal *vintfn,
|
||||
void (*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *nbpntu,
|
||||
integer *nbpntv,
|
||||
doublereal *urootb,
|
||||
@@ -5101,8 +5037,6 @@ int AdvApp2Var_ApproxF2var::mma2ds1_(integer *ndimen,
|
||||
static integer ibid1, ibid2, iuouv, nd;
|
||||
static integer isz1, isz2;
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -5397,19 +5331,7 @@ L9999:
|
||||
int mma2ds2_(integer *ndimen,
|
||||
doublereal *uintfn,
|
||||
doublereal *vintfn,
|
||||
void (*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *nbpntu,
|
||||
integer *nbpntv,
|
||||
doublereal *urootb,
|
||||
@@ -5664,8 +5586,8 @@ int mma2ds2_(integer *ndimen,
|
||||
i__1 = nvroo;
|
||||
for (iv = 1; iv <= i__1; ++iv) {
|
||||
tcons = blinv + alinv * vrootb[iv];
|
||||
(*foncnp)(ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu, &
|
||||
ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
foncnp.Evaluate (ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu,
|
||||
&ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
}
|
||||
@@ -5705,8 +5627,8 @@ int mma2ds2_(integer *ndimen,
|
||||
|
||||
if (*nbpntv % 2 != 0) {
|
||||
tcons = blinv;
|
||||
(*foncnp)(ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu, &
|
||||
ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
foncnp.Evaluate (ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu,
|
||||
&ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
}
|
||||
@@ -5735,8 +5657,8 @@ int mma2ds2_(integer *ndimen,
|
||||
i__1 = nvroo;
|
||||
for (iv = 1; iv <= i__1; ++iv) {
|
||||
tcons = alinv * vrootb[(*nbpntv + 1) / 2 + iv] + blinv;
|
||||
(*foncnp)(ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu, &
|
||||
ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
foncnp.Evaluate (ndimen, dbfn1, dbfn2, iiuouv, &tcons, nbpntu,
|
||||
&ttable[1], &c__0, &c__0, &fpntab[fpntab_offset], iercod);
|
||||
if (*iercod > 0) {
|
||||
goto L9999;
|
||||
}
|
||||
@@ -5803,7 +5725,7 @@ int mma2er1_(integer *ndjacu,
|
||||
/* System generated locals */
|
||||
integer patjac_dim1, patjac_dim2, patjac_offset, i__1, i__2, i__3;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static integer minu, minv;
|
||||
@@ -5811,7 +5733,6 @@ int mma2er1_(integer *ndjacu,
|
||||
static integer ii, nd, jj;
|
||||
static doublereal bid0, bid1;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -5916,7 +5837,7 @@ int mma2er1_(integer *ndjacu,
|
||||
i__3 = *maxdgu;
|
||||
for (ii = *mindgu; ii <= i__3; ++ii) {
|
||||
bid0 += (d__1 = patjac[ii + (jj + nd * patjac_dim2) *
|
||||
patjac_dim1], abs(d__1)) * xmaxju[ii - minu];
|
||||
patjac_dim1], advapp_abs(d__1)) * xmaxju[ii - minu];
|
||||
/* L300: */
|
||||
}
|
||||
bid1 = bid0 * xmaxjv[jj - minv] + bid1;
|
||||
@@ -5970,7 +5891,7 @@ int mma2er2_(integer *ndjacu,
|
||||
/* System generated locals */
|
||||
integer patjac_dim1, patjac_dim2, patjac_offset, i__1, i__2;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static logical ldbg;
|
||||
static doublereal vaux[2];
|
||||
@@ -5979,7 +5900,6 @@ int mma2er2_(integer *ndjacu,
|
||||
static integer ii, nd, jj, nu, nv;
|
||||
static doublereal bid0, bid1;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -6101,7 +6021,7 @@ L1001:
|
||||
i__2 = nu;
|
||||
for (ii = i2rdu; ii <= i__2; ++ii) {
|
||||
bid1 += (d__1 = patjac[ii + (nv + nd * patjac_dim2) *
|
||||
patjac_dim1], abs(d__1)) * xmaxju[ii - i2rdu] * bid0;
|
||||
patjac_dim1], advapp_abs(d__1)) * xmaxju[ii - i2rdu] * bid0;
|
||||
/* L200: */
|
||||
}
|
||||
vecerr[nd] = bid1;
|
||||
@@ -6126,7 +6046,7 @@ L1001:
|
||||
i__2 = nv;
|
||||
for (jj = i2rdv; jj <= i__2; ++jj) {
|
||||
bid1 += (d__1 = patjac[nu + (jj + nd * patjac_dim2) *
|
||||
patjac_dim1], abs(d__1)) * xmaxjv[jj - i2rdv] * bid0;
|
||||
patjac_dim1], advapp_abs(d__1)) * xmaxjv[jj - i2rdv] * bid0;
|
||||
/* L400: */
|
||||
}
|
||||
vecerr[nd] = bid1;
|
||||
@@ -6169,8 +6089,8 @@ L1001:
|
||||
*/
|
||||
|
||||
L2001:
|
||||
*newdgu = max(nu,1);
|
||||
*newdgv = max(nv,1);
|
||||
*newdgu = advapp_max(nu,1);
|
||||
*newdgv = advapp_max(nv,1);
|
||||
|
||||
/* ----------------------------------- The end --------------------------
|
||||
*/
|
||||
@@ -6189,19 +6109,7 @@ int AdvApp2Var_ApproxF2var::mma2fnc_(integer *ndimen,
|
||||
integer *nbsesp,
|
||||
integer *ndimse,
|
||||
doublereal *uvfonc,
|
||||
void (*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
doublereal *tconst,
|
||||
integer *isofav,
|
||||
integer *nbroot,
|
||||
@@ -6463,10 +6371,10 @@ int AdvApp2Var_ApproxF2var::mma2fnc_(integer *ndimen,
|
||||
*/
|
||||
|
||||
AdvApp2Var_MathBase::mmveps3_(&eps3);
|
||||
if ((d__1 = uvfonc[4] - uvfonc[3], abs(d__1)) < eps3) {
|
||||
if ((d__1 = uvfonc[4] - uvfonc[3], advapp_abs(d__1)) < eps3) {
|
||||
goto L9100;
|
||||
}
|
||||
if ((d__1 = uvfonc[6] - uvfonc[5], abs(d__1)) < eps3) {
|
||||
if ((d__1 = uvfonc[6] - uvfonc[5], advapp_abs(d__1)) < eps3) {
|
||||
goto L9100;
|
||||
}
|
||||
|
||||
@@ -6488,9 +6396,9 @@ int AdvApp2Var_ApproxF2var::mma2fnc_(integer *ndimen,
|
||||
/* the auxiliary curve for MMAPCMP */
|
||||
ibid1 = *ndimen * (*nbroot + 2);
|
||||
ibid2 = ((*iordre + 1) << 1) * *nbroot;
|
||||
isz2 = max(ibid1,ibid2);
|
||||
isz2 = advapp_max(ibid1,ibid2);
|
||||
ibid1 = (((*ncflim - 1) / 2 + 1) << 1) * *ndimen;
|
||||
isz2 = max(ibid1,isz2);
|
||||
isz2 = advapp_max(ibid1,isz2);
|
||||
/* --> To return the polynoms of hermit. */
|
||||
isz3 = ((*iordre + 1) << 2) * (*iordre + 1);
|
||||
/* --> For the Gauss coeff. of integration. */
|
||||
@@ -6783,12 +6691,12 @@ int AdvApp2Var_ApproxF2var::mma2fx6_(integer *ncfmxu,
|
||||
errmax_offset, ncoefu_dim1, ncoefu_offset, ncoefv_dim1,
|
||||
ncoefv_offset, i__1, i__2, i__3, i__4, i__5;
|
||||
doublereal d__1, d__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer idim, ncfu, ncfv, id, ii, nd, jj, ku, kv, ns, ibb;
|
||||
static doublereal bid;
|
||||
static doublereal tol;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
||||
@@ -6899,30 +6807,30 @@ L200:
|
||||
tol = epsapr[ns];
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 9];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 10];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 11];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 12];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
if (ii == 1 || ii == *nbupat || jj == 1 || jj == *nbvpat)
|
||||
{
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 5];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 6];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 7];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + (epsfro_dim1 << 3)];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
}
|
||||
bid = 0.;
|
||||
|
||||
@@ -6933,7 +6841,7 @@ L200:
|
||||
for (kv = 1; kv <= i__5; ++kv) {
|
||||
bid += (d__1 = patcan[ncfu + (kv + (id + (ii + jj
|
||||
* patcan_dim4) * patcan_dim3) *
|
||||
patcan_dim2) * patcan_dim1], abs(d__1));
|
||||
patcan_dim2) * patcan_dim1], advapp_abs(d__1));
|
||||
/* L230: */
|
||||
}
|
||||
/* L220: */
|
||||
@@ -6964,30 +6872,30 @@ L300:
|
||||
tol = epsapr[ns];
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 9];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 10];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 11];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 12];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
if (ii == 1 || ii == *nbupat || jj == 1 || jj == *nbvpat)
|
||||
{
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 5];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 6];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + epsfro_dim1 * 7];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
/* Computing MIN */
|
||||
d__1 = tol, d__2 = epsfro[ns + (epsfro_dim1 << 3)];
|
||||
tol = min(d__1,d__2);
|
||||
tol = advapp_min(d__1,d__2);
|
||||
}
|
||||
bid = 0.;
|
||||
|
||||
@@ -6998,7 +6906,7 @@ L300:
|
||||
for (ku = 1; ku <= i__5; ++ku) {
|
||||
bid += (d__1 = patcan[ku + (ncfv + (id + (ii + jj
|
||||
* patcan_dim4) * patcan_dim3) *
|
||||
patcan_dim2) * patcan_dim1], abs(d__1));
|
||||
patcan_dim2) * patcan_dim1], advapp_abs(d__1));
|
||||
/* L330: */
|
||||
}
|
||||
/* L320: */
|
||||
@@ -7019,8 +6927,8 @@ L300:
|
||||
/* --- Return the nbs of coeff. and pass to the next square --- */
|
||||
|
||||
L400:
|
||||
ncoefu[ii + jj * ncoefu_dim1] = max(ncfu,2);
|
||||
ncoefv[ii + jj * ncoefv_dim1] = max(ncfv,2);
|
||||
ncoefu[ii + jj * ncoefu_dim1] = advapp_max(ncfu,2);
|
||||
ncoefv[ii + jj * ncoefv_dim1] = advapp_max(ncfv,2);
|
||||
/* L110: */
|
||||
}
|
||||
/* L100: */
|
||||
@@ -7400,8 +7308,8 @@ int mma2moy_(integer *ndgumx,
|
||||
|
||||
idebu = (*iordru + 1) << 1;
|
||||
idebv = (*iordrv + 1) << 1;
|
||||
minu = max(idebu,*mindgu);
|
||||
minv = max(idebv,*mindgv);
|
||||
minu = advapp_max(idebu,*mindgu);
|
||||
minv = advapp_max(idebv,*mindgv);
|
||||
bid0 = 0.;
|
||||
*errmoy = 0.;
|
||||
|
||||
@@ -7465,7 +7373,7 @@ int AdvApp2Var_ApproxF2var::mma2roo_(integer *nbpntu,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer i__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ii, ibb;
|
||||
|
||||
@@ -7571,13 +7479,11 @@ int mmmapcoe_(integer *ndim,
|
||||
/* System generated locals */
|
||||
integer somtab_dim1, somtab_offset, diftab_dim1, diftab_offset,
|
||||
crvjac_dim1, crvjac_offset, gsstab_dim1, i__1, i__2, i__3;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer igss, ikdeb;
|
||||
static doublereal bidon;
|
||||
static integer nd, ik, ir, nbroot, ibb;
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -7739,8 +7645,6 @@ int mmaperm_(integer *ncofmx,
|
||||
static doublereal bidj;
|
||||
static integer i__, ia, nd, ncfcut, ibb;
|
||||
static doublereal bid;
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -7845,11 +7749,9 @@ int AdvApp2Var_ApproxF2var::mmapptt_(const integer *ndgjac,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer cgauss_dim1, i__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer kjac, iptt, ipdb0, infdg, iptdb, mxjac, ilong, ibb;
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
|
@@ -11,6 +11,7 @@
|
||||
|
||||
#include <Standard_Macro.hxx>
|
||||
#include <AdvApp2Var_Data_f2c.hxx>
|
||||
#include <AdvApp2Var_EvaluatorFunc2Var.hxx>
|
||||
//
|
||||
class AdvApp2Var_ApproxF2var {
|
||||
public:
|
||||
@@ -19,19 +20,7 @@ Standard_EXPORT static int mma2fnc_(integer *ndimen,
|
||||
integer *nbsesp,
|
||||
integer *ndimse,
|
||||
doublereal *uvfonc,
|
||||
void(*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
doublereal *tconst,
|
||||
integer *isofav,
|
||||
integer *nbroot,
|
||||
@@ -100,19 +89,7 @@ Standard_EXPORT static int mma2cdi_(integer *ndimen,
|
||||
Standard_EXPORT static int mma2ds1_(integer *ndimen,
|
||||
doublereal *uintfn,
|
||||
doublereal *vintfn,
|
||||
void (*foncnp) (
|
||||
int *,
|
||||
double *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
double *,
|
||||
int *,
|
||||
int *,
|
||||
double *,
|
||||
int *
|
||||
),
|
||||
const AdvApp2Var_EvaluatorFunc2Var& foncnp,
|
||||
integer *nbpntu,
|
||||
integer *nbpntv,
|
||||
doublereal *urootb,
|
||||
|
@@ -155,12 +155,12 @@ struct Namelist {
|
||||
};
|
||||
typedef struct Namelist Namelist;
|
||||
|
||||
#define abs(x) ((x) >= 0 ? (x) : -(x))
|
||||
#define dabs(x) (doublereal)abs(x)
|
||||
#define min(a,b) ((a) <= (b) ? (a) : (b))
|
||||
#define max(a,b) ((a) >= (b) ? (a) : (b))
|
||||
#define dmin(a,b) (doublereal)min(a,b)
|
||||
#define dmax(a,b) (doublereal)max(a,b)
|
||||
#define advapp_abs(x) ((x) >= 0 ? (x) : -(x))
|
||||
#define dabs(x) (doublereal)advapp_abs(x)
|
||||
#define advapp_min(a,b) ((a) <= (b) ? (a) : (b))
|
||||
#define advapp_max(a,b) ((a) >= (b) ? (a) : (b))
|
||||
#define dmin(a,b) (doublereal)advapp_min(a,b)
|
||||
#define dmax(a,b) (doublereal)advapp_max(a,b)
|
||||
#define bit_test(a,b) ((a) >> (b) & 1)
|
||||
#define bit_clear(a,b) ((a) & ~((uinteger)1 << (b)))
|
||||
#define bit_set(a,b) ((a) | ((uinteger)1 << (b)))
|
||||
|
@@ -3,7 +3,6 @@
|
||||
// Author: Joelle CHAUVET
|
||||
// <jct@sgi38>
|
||||
|
||||
|
||||
#ifndef _Standard_Integer_HeaderFile
|
||||
#include <Standard_Integer.hxx>
|
||||
#endif
|
||||
@@ -14,36 +13,59 @@
|
||||
#include <Standard_PrimitiveTypes.hxx>
|
||||
#endif
|
||||
|
||||
|
||||
#ifndef AdvApp2Var_EvaluatorFunc2Var_HeaderFile
|
||||
#define AdvApp2Var_EvaluatorFunc2Var_HeaderFile
|
||||
|
||||
extern "C" {
|
||||
typedef void (* AdvApp2Var_EvaluatorFunc2Var) (Standard_Integer *,
|
||||
// Dimension
|
||||
Standard_Real *,
|
||||
// StartEnd[2] in U
|
||||
Standard_Real *,
|
||||
// StartEnd[2] in V
|
||||
Standard_Integer *,
|
||||
// Choice of constante, 1 for U, 2 for V
|
||||
Standard_Real *,
|
||||
// Value of constant parameter
|
||||
Standard_Integer *,
|
||||
// Number of parameters
|
||||
Standard_Real *,
|
||||
// Values of parameters,
|
||||
Standard_Integer *,
|
||||
// Derivative Request in U
|
||||
Standard_Integer *,
|
||||
// Derivative Request in V
|
||||
Standard_Real *,
|
||||
// Result[Dimension]
|
||||
Standard_Integer *) ;
|
||||
// Error Code
|
||||
// History - the C function pointer converted to a virtual class
|
||||
// in order to get rid of usage of static functions and static data
|
||||
class AdvApp2Var_EvaluatorFunc2Var
|
||||
{
|
||||
public:
|
||||
|
||||
//! Empty constructor
|
||||
AdvApp2Var_EvaluatorFunc2Var() {}
|
||||
|
||||
}
|
||||
//! Destructor should be declared as virtual
|
||||
virtual ~AdvApp2Var_EvaluatorFunc2Var () {}
|
||||
|
||||
//! Function evaluation method to be defined by descendant
|
||||
virtual void Evaluate (Standard_Integer* theDimension,
|
||||
Standard_Real* theUStartEnd,
|
||||
Standard_Real* theVStartEnd,
|
||||
Standard_Integer* theFavorIso, //!< Choice of constante, 1 for U, 2 for V
|
||||
Standard_Real* theConstParam, //!< Value of constant parameter
|
||||
Standard_Integer* theNbParams, //!< Number of parameters N
|
||||
Standard_Real* theParameters, //!< Values of parameters,
|
||||
Standard_Integer* theUOrder, //!< Derivative Request in U
|
||||
Standard_Integer* theVOrder, //!< Derivative Request in V
|
||||
Standard_Real* theResult, //!< Result[Dimension,N]
|
||||
Standard_Integer* theErrorCode) const = 0;
|
||||
|
||||
//! Shortcut for function-call style usage
|
||||
void operator() (Standard_Integer* theDimension,
|
||||
Standard_Real* theUStartEnd,
|
||||
Standard_Real* theVStartEnd,
|
||||
Standard_Integer* theFavorIso,
|
||||
Standard_Real* theConstParam,
|
||||
Standard_Integer* theNbParams,
|
||||
Standard_Real* theParameters,
|
||||
Standard_Integer* theUOrder,
|
||||
Standard_Integer* theVOrder,
|
||||
Standard_Real* theResult,
|
||||
Standard_Integer* theErrorCode) const
|
||||
{
|
||||
Evaluate (theDimension, theUStartEnd, theVStartEnd, theFavorIso,
|
||||
theConstParam, theNbParams,
|
||||
theParameters, theUOrder, theVOrder, theResult, theErrorCode);
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
//! Copy constructor is declared private to forbid copying
|
||||
AdvApp2Var_EvaluatorFunc2Var (const AdvApp2Var_EvaluatorFunc2Var& ) {}
|
||||
|
||||
//! Assignment operator is declared private to forbid copying
|
||||
void operator= (const AdvApp2Var_EvaluatorFunc2Var& ) {}
|
||||
};
|
||||
|
||||
#endif
|
||||
|
@@ -255,7 +255,7 @@ int AdvApp2Var_MathBase::mdsptpt_(integer *ndimen,
|
||||
/* System generated locals */
|
||||
integer i__1;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer i__;
|
||||
static doublereal differ[100];
|
||||
@@ -405,12 +405,10 @@ int AdvApp2Var_MathBase::mmapcmp_(integer *ndim,
|
||||
/* System generated locals */
|
||||
integer crvold_dim1, crvold_offset, crvnew_dim1, crvnew_offset, i__1,
|
||||
i__2;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ipair, nd, ndegre, impair, ibb, idg;
|
||||
//extern int mgsomsg_();//mgenmsg_(),
|
||||
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -523,12 +521,11 @@ int mmaper0_(integer *ncofmx,
|
||||
/* System generated locals */
|
||||
integer crvlgd_dim1, crvlgd_offset, i__1, i__2;
|
||||
doublereal d__1;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer ncut;
|
||||
static doublereal bidon;
|
||||
static doublereal bidon;
|
||||
static integer ii, nd;
|
||||
|
||||
|
||||
/* ***********************************************************************
|
||||
*/
|
||||
@@ -608,7 +605,7 @@ int mmaper0_(integer *ncofmx,
|
||||
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvlgd[ii + nd * crvlgd_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvlgd[ii + nd * crvlgd_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -776,7 +773,7 @@ int mmaper2_(integer *ncofmx,
|
||||
idec = 3;
|
||||
/* Computing MAX */
|
||||
i__1 = idec, i__2 = *ncfnew + 1;
|
||||
ncut = max(i__1,i__2);
|
||||
ncut = advapp_max(i__1,i__2);
|
||||
|
||||
/* -------------- Removal of coefficients of high degree -----------
|
||||
*/
|
||||
@@ -789,7 +786,7 @@ int mmaper2_(integer *ncofmx,
|
||||
bidon = xmaxj[ii - idec];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -962,7 +959,7 @@ int mmaper4_(integer *ncofmx,
|
||||
idec = 5;
|
||||
/* Computing MAX */
|
||||
i__1 = idec, i__2 = *ncfnew + 1;
|
||||
ncut = max(i__1,i__2);
|
||||
ncut = advapp_max(i__1,i__2);
|
||||
|
||||
/* -------------- Removal of high degree coefficients -----------
|
||||
*/
|
||||
@@ -975,7 +972,7 @@ int mmaper4_(integer *ncofmx,
|
||||
bidon = xmaxj[ii - idec];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -1139,7 +1136,7 @@ int mmaper6_(integer *ncofmx,
|
||||
idec = 7;
|
||||
/* Computing MAX */
|
||||
i__1 = idec, i__2 = *ncfnew + 1;
|
||||
ncut = max(i__1,i__2);
|
||||
ncut = advapp_max(i__1,i__2);
|
||||
|
||||
/* -------------- Removal of high degree coefficients -----------
|
||||
*/
|
||||
@@ -1152,7 +1149,7 @@ int mmaper6_(integer *ncofmx,
|
||||
bidon = xmaxj[ii - idec];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvjac[ii + nd * crvjac_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -1187,10 +1184,9 @@ int AdvApp2Var_MathBase::mmaperx_(integer *ncofmx,
|
||||
{
|
||||
/* System generated locals */
|
||||
integer crvjac_dim1, crvjac_offset;
|
||||
|
||||
|
||||
/* Local variables */
|
||||
static integer jord;
|
||||
|
||||
|
||||
/* **********************************************************************
|
||||
*/
|
||||
@@ -1604,7 +1600,7 @@ int AdvApp2Var_MathBase::mmarcin_(integer *ndimax,
|
||||
/* At zero machine it is tested if the output interval is not null */
|
||||
|
||||
AdvApp2Var_MathBase::mmveps3_(&eps3);
|
||||
if ((d__1 = *u1 - *u0, abs(d__1)) < eps3) {
|
||||
if ((d__1 = *u1 - *u0, advapp_abs(d__1)) < eps3) {
|
||||
*iercod = 13;
|
||||
goto L9999;
|
||||
}
|
||||
@@ -2393,7 +2389,7 @@ L5000:
|
||||
/* ------ Take into account DIF - Test of convergence */
|
||||
|
||||
++iter;
|
||||
dif = (d__1 = sottc - oldso, abs(d__1));
|
||||
dif = (d__1 = sottc - oldso, advapp_abs(d__1));
|
||||
|
||||
/* ------ If DIF is OK, leave..., otherwise: */
|
||||
|
||||
@@ -2578,7 +2574,7 @@ int mmchole_(integer *,//mxcoef,
|
||||
/* Computing MAX */
|
||||
i__2 = i__ - aposit[(i__ << 1) + 1], i__3 = j - aposit[(j << 1) +
|
||||
1];
|
||||
kmin = max(i__2,i__3);
|
||||
kmin = advapp_max(i__2,i__3);
|
||||
i__2 = j - 1;
|
||||
for (k = kmin; k <= i__2; ++k) {
|
||||
somme += chomat[aposit[(i__ << 1) + 2] - (i__ - k)] * chomat[
|
||||
@@ -5192,12 +5188,12 @@ int mmherm0_(doublereal *debfin,
|
||||
--debfin;
|
||||
|
||||
/* Function Body */
|
||||
d1 = abs(debfin[1]);
|
||||
d1 = advapp_abs(debfin[1]);
|
||||
if (d1 > (float)100.) {
|
||||
goto L9101;
|
||||
}
|
||||
|
||||
d2 = abs(debfin[2]);
|
||||
d2 = advapp_abs(debfin[2]);
|
||||
if (d2 > (float)100.) {
|
||||
goto L9101;
|
||||
}
|
||||
@@ -5207,7 +5203,7 @@ int mmherm0_(doublereal *debfin,
|
||||
goto L9101;
|
||||
}
|
||||
|
||||
d1 = (d__1 = debfin[2] - debfin[1], abs(d__1));
|
||||
d1 = (d__1 = debfin[2] - debfin[1], advapp_abs(d__1));
|
||||
if (d1 / d2 < (float).01) {
|
||||
goto L9101;
|
||||
}
|
||||
@@ -5229,7 +5225,7 @@ int mmherm0_(doublereal *debfin,
|
||||
|
||||
/* IS IT ALREADY INITIALIZED ? */
|
||||
|
||||
d1 = abs(debfin[1]) + abs(debfin[2]);
|
||||
d1 = advapp_abs(debfin[1]) + advapp_abs(debfin[2]);
|
||||
d1 *= 16111959;
|
||||
|
||||
if (debfin[1] != mmcmher_.tdebut) {
|
||||
@@ -5370,7 +5366,7 @@ L100:
|
||||
mmcmher_.tdebut = debfin[1];
|
||||
mmcmher_.tfinal = debfin[2];
|
||||
|
||||
d1 = abs(debfin[1]) + abs(debfin[2]);
|
||||
d1 = advapp_abs(debfin[1]) + advapp_abs(debfin[2]);
|
||||
mmcmher_.verifi = d1 * 16111959;
|
||||
|
||||
|
||||
@@ -5563,7 +5559,7 @@ int mmherm1_(doublereal *debfin,
|
||||
|
||||
/* IS-IT CORRECTLY INITIALIZED ? */
|
||||
|
||||
d1 = abs(debfin[1]) + abs(debfin[2]);
|
||||
d1 = advapp_abs(debfin[1]) + advapp_abs(debfin[2]);
|
||||
d1 *= 16111959;
|
||||
|
||||
/* OTHERWISE IT IS INITIALIZED */
|
||||
@@ -6465,7 +6461,7 @@ int mmloncv_(integer *ndimax,
|
||||
/* ****** Calculate the optimal degree ** */
|
||||
|
||||
kk = *ncoeff / 4 + 1;
|
||||
kk = min(kk,10);
|
||||
kk = advapp_min(kk,10);
|
||||
|
||||
/* ****** Return the coefficients for the integral (DEGRE=4*KK) */
|
||||
/* if KK <> KGAR. */
|
||||
@@ -6739,7 +6735,7 @@ L9900:
|
||||
|
||||
/* Computing MAX */
|
||||
i__1 = iorjac + 1;
|
||||
nwcof = max(i__1,1);
|
||||
nwcof = advapp_max(i__1,1);
|
||||
AdvApp2Var_SysBase::mvriraz_((integer *)&nwcof,
|
||||
(char *)wpoly);
|
||||
wpoly[0] = 1.;
|
||||
@@ -8117,7 +8113,7 @@ int mmrslw_(integer *normax,
|
||||
kpiv = 0;
|
||||
i__2 = *nordre;
|
||||
for (jj = kk; jj <= i__2; ++jj) {
|
||||
akj = (d__1 = abmatr[kk + jj * abmatr_dim1], abs(d__1));
|
||||
akj = (d__1 = abmatr[kk + jj * abmatr_dim1], advapp_abs(d__1));
|
||||
if (akj > pivot) {
|
||||
pivot = akj;
|
||||
kpiv = jj;
|
||||
@@ -8610,11 +8606,11 @@ L1000:
|
||||
*/
|
||||
|
||||
L2000:
|
||||
if ((d__1 = *tparam - tablev[ideb], abs(d__1)) < *epsil) {
|
||||
if ((d__1 = *tparam - tablev[ideb], advapp_abs(d__1)) < *epsil) {
|
||||
*itypen = 1;
|
||||
goto L9999;
|
||||
}
|
||||
if ((d__1 = *tparam - tablev[ifin], abs(d__1)) < *epsil) {
|
||||
if ((d__1 = *tparam - tablev[ifin], advapp_abs(d__1)) < *epsil) {
|
||||
*itypen = 2;
|
||||
goto L9999;
|
||||
}
|
||||
@@ -8877,7 +8873,7 @@ int mmtrpj0_(integer *ncofmx,
|
||||
bidon = sqrt(bidon);
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -9061,7 +9057,7 @@ int mmtrpj2_(integer *ncofmx,
|
||||
bidon = xmaxj[i__ - ncut];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -9089,7 +9085,7 @@ L400:
|
||||
bid = 0.;
|
||||
i__1 = *ndimen;
|
||||
for (nd = 1; nd <= i__1; ++nd) {
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1));
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1));
|
||||
/* L600: */
|
||||
}
|
||||
if (bid > eps1) {
|
||||
@@ -9266,7 +9262,7 @@ int mmtrpj4_(integer *ncofmx,
|
||||
bidon = xmaxj[i__ - ncut];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -9294,7 +9290,7 @@ L400:
|
||||
bid = 0.;
|
||||
i__1 = *ndimen;
|
||||
for (nd = 1; nd <= i__1; ++nd) {
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1));
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1));
|
||||
/* L600: */
|
||||
}
|
||||
if (bid > eps1) {
|
||||
@@ -9469,7 +9465,7 @@ int mmtrpj6_(integer *ncofmx,
|
||||
bidon = xmaxj[i__ - ncut];
|
||||
i__2 = *ndimen;
|
||||
for (nd = 1; nd <= i__2; ++nd) {
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1)) *
|
||||
ycvmax[nd] += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1)) *
|
||||
bidon;
|
||||
/* L310: */
|
||||
}
|
||||
@@ -9497,7 +9493,7 @@ L400:
|
||||
bid = 0.;
|
||||
i__1 = *ndimen;
|
||||
for (nd = 1; nd <= i__1; ++nd) {
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], abs(d__1));
|
||||
bid += (d__1 = crvlgd[i__ + nd * crvlgd_dim1], advapp_abs(d__1));
|
||||
/* L600: */
|
||||
}
|
||||
if (bid > eps1) {
|
||||
@@ -9716,7 +9712,7 @@ L9999:
|
||||
i__1 = *ndimen;
|
||||
for (ii = 1; ii <= i__1; ++ii) {
|
||||
vecnrm[ii] = vector[ii] / vnorm;
|
||||
if ((d__1 = vecnrm[ii], abs(d__1)) <= eps0) {
|
||||
if ((d__1 = vecnrm[ii], advapp_abs(d__1)) <= eps0) {
|
||||
++izero;
|
||||
} else {
|
||||
iunit = ii;
|
||||
@@ -11251,7 +11247,7 @@ L9900:
|
||||
irmax = 1;
|
||||
i__1 = *ndimen;
|
||||
for (i__ = 2; i__ <= i__1; ++i__) {
|
||||
if ((d__1 = vecteu[irmax], abs(d__1)) < (d__2 = vecteu[i__], abs(d__2)
|
||||
if ((d__1 = vecteu[irmax], advapp_abs(d__1)) < (d__2 = vecteu[i__], advapp_abs(d__2)
|
||||
)) {
|
||||
irmax = i__;
|
||||
}
|
||||
@@ -11260,7 +11256,7 @@ L9900:
|
||||
|
||||
/* ___ Calculate the norme */
|
||||
|
||||
if ((d__1 = vecteu[irmax], abs(d__1)) < 1.) {
|
||||
if ((d__1 = vecteu[irmax], advapp_abs(d__1)) < 1.) {
|
||||
xsom = 0.;
|
||||
i__1 = *ndimen;
|
||||
for (i__ = 1; i__ <= i__1; ++i__) {
|
||||
@@ -11283,7 +11279,7 @@ L9900:
|
||||
}
|
||||
/* L300: */
|
||||
}
|
||||
ret_val = (d__1 = vecteu[irmax], abs(d__1)) * sqrt(xsom);
|
||||
ret_val = (d__1 = vecteu[irmax], advapp_abs(d__1)) * sqrt(xsom);
|
||||
}
|
||||
|
||||
/* ***********************************************************************
|
||||
|
@@ -3016,7 +3016,7 @@ int AdvApp2Var_SysBase::mcrrqst_(integer *iunit,
|
||||
mcrgene_.icore[mcrgene_.ncore * 12 - 10];
|
||||
/* Computing MAX */
|
||||
i__1 = mcrstac_.mbyte[ksys - 1], i__2 = mcrstac_.nbyte[ksys - 1];
|
||||
mcrstac_.mbyte[ksys - 1] = max(i__1,i__2);
|
||||
mcrstac_.mbyte[ksys - 1] = advapp_max(i__1,i__2);
|
||||
|
||||
goto L9900;
|
||||
|
||||
|
Reference in New Issue
Block a user