00001
00038 #ifndef _AM_H_
00039 #define _AM_H_
00040
00041 #include <mc/mc_base.h>
00042
00043 #include <mc/aprx.h>
00044
00045
00046
00047
00048
00049
00050
00056 struct sAM {
00057
00058
00059
00061 Vmem *vmem;
00064 int iMadeVmem;
00065
00068 Aprx *aprx;
00071 Bmat *P;
00072
00073
00074
00077 int algExist;
00078
00081 Bmat *A;
00084 Bmat *M;
00085
00088 Bvec *f;
00091 Bvec *u;
00094 Bvec *ud;
00097 Bvec *ui;
00100 Bvec *ut;
00103 Bvec *r;
00106 Bvec *w0;
00107
00108 };
00109
00115 typedef struct sAM AM;
00116
00117
00118
00119
00120
00121
00122
00123 #if !defined(VINLINE_NAM)
00124 #else
00125 #endif
00126
00127
00128
00129
00130
00131
00132
00142 AM* AM_ctor(Vmem *vmem, Aprx *taprx);
00143
00152 void AM_dtor(AM **thee);
00153
00165 void AM_create(AM *thee);
00166
00178 void AM_destroy(AM *thee);
00179
00192 int AM_markRefine(AM *thee, int key, int color,
00193 int bkey, double elevel);
00194
00230 int AM_refine(AM *thee, int rkey, int bkey, int pkey);
00231
00242 int AM_unRefine(AM *thee, int rkey, int pkey);
00243
00252 int AM_deform(AM *thee);
00253
00275 int AM_read(AM *thee, int key, Vio *sock);
00276
00315 double AM_assem(AM *thee,
00316 int evalKey, int energyKey, int residKey, int tangKey, int massKey,
00317 int bumpKey,
00318 Bvec *u, Bvec *ud, Bvec *f, int ip[], double rp[]);
00319
00328 double AM_evalJ(AM *thee);
00329
00344 void AM_evalFunc(AM *thee,
00345 int number, int block, int numPts, double *pts,
00346 double *vals, int *marks);
00347
00356 void AM_bndIntegral(AM *thee);
00357
00370 double AM_evalError(AM *thee, int pcolor, int key);
00371
00381 void AM_applyDiriZero(AM *thee, Bvec *which);
00382
00392 void AM_iniGuess(AM *thee, Bvec *which);
00393
00405 int AM_part(AM *thee, int pkey, int pwht, int ppow);
00406
00416 int AM_partSet(AM *thee, int pcolor);
00417
00426 int AM_partSmooth(AM *thee);
00427
00436 void AM_printJ(AM *thee);
00437
00446 void AM_printA(AM *thee);
00447
00456 void AM_printAnoD(AM *thee);
00457
00467 void AM_printAsp(AM *thee, char *fname);
00468
00479 void AM_printAspNoD(AM *thee, char *fname);
00480
00489 void AM_printP(AM *thee);
00490
00500 void AM_printPsp(AM *thee, char *fname);
00501
00511 void AM_printV(AM *thee, int num);
00512
00523 void AM_printVsp(AM *thee, int num, char *fname);
00524
00553 void AM_writeGEOM(AM *thee, Vio *sock,
00554 int defKey, int colKey, int chartKey, double gluVal, int fkey,
00555 int number, char *format);
00556
00568 void AM_writeSOL(AM *thee, Vio *sock, int number, char *format);
00569
00578 void AM_memChk(AM *thee);
00579
00580
00581
00582
00583
00584
00585
00601 void AM_lSolve(AM *thee, int prob,
00602 int meth, int itmax, double etol, int prec, int gues, int pjac);
00603
00619 void AM_hlSolve(AM *thee, int prob,
00620 int meth, int itmax, double etol, int prec, int gues, int pjac);
00621 #if 0
00622
00698 void AM_hPbcg(AM *thee,
00699 int lev, int key, int flag, int itmax, double etol, int meth,
00700 int uu, int ff, int rr, int dd, int ut);
00701 #endif
00702
00703
00704
00705
00706
00707
00708
00726 void AM_nSolve(AM *thee,
00727 int meth, int itmax, double etol,
00728 int lmeth, int litmax, double letol, int lprec, int gues, int pjac);
00729
00746 void AM_newton(AM *thee,
00747 int itmax, double etol,
00748 int lmeth, int litmax, double letol, int lprec, int pjac, double loadParm);
00749
00765 VPUBLIC void AM_homotopy(AM *thee,
00766 int itmax, double etol,
00767 int lmeth, int litmax, double letol, int lprec, int pjac);
00768
00769 #endif
00770
00771