00001 #include <string.h>
00002 #include "galias.h"
00003 #include "probdesc.h"
00004 #include "global.h"
00005 #include "gmatrix.h"
00006 #include "intools.h"
00007 #include "iotools.h"
00008 #include "aggregator.h"
00009 #include "adaptivity.h"
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 probdesc::probdesc ()
00020 {
00021 kwdsw = nokwd;
00022 niilnr=0; errnr=0.0;
00023
00024
00025 tstorsm = (storagetype) 0;
00026
00027 tstormm = (storagetype) 0;
00028
00029 tepsol = (epsolvertype) 0;
00030
00031
00032 damp = nodamp;
00033 dmass=0.0; dstiff=0.0;
00034
00035
00036 strcomp = 1;
00037
00038
00039 eigstrcomp = 1;
00040
00041
00042 detnodstrain = 0;
00043
00044 stochasticcalc=0;
00045 eigstrains=0;
00046 temperature=0;
00047 pore_press=0;
00048
00049 adaptivityflag=0;
00050
00051 limit=0.0; zero=1.0e-20;
00052
00053
00054
00055
00056 alphafvn=0.0; deltafvn=0.0;
00057
00058 time = 0.0;
00059 dtime = 0.0;
00060 dtmin=zero;
00061
00062 istep = 0;
00063 jstep = 0;
00064
00065 nonlocphase = 0;
00066
00067 nodeintfor = 1;
00068 lambda = 0.0;
00069 dlambda = 0.0;
00070
00071 niep =0; stepep = 0.0; errep = 0.0; rlerrep = 0.0; nselnodep = 0; selnodep=NULL; loadcoef = NULL;
00072
00073 matmodel = (materialmodel) 0;
00074
00075
00076 straincomp=0;
00077
00078 strainaver=0;
00079
00080 strainpos=0;
00081
00082 stresscomp=0;
00083
00084 stressaver=0;
00085
00086 stresspos=0;
00087
00088 othercomp = 0;
00089
00090 otheraver = 0;
00091
00092 otherpos=0;
00093
00094 reactcomp=0;
00095
00096 strainstate=0;
00097 stressstate=0;
00098 otherstate=0;
00099
00100 memset(name, 0, sizeof(*name)*1001);
00101
00102 tlm=0;
00103
00104
00105 homog=0;
00106
00107 ntiletypes=0;
00108
00109 mcnne=0; dim=0;
00110
00111 ense=0;
00112
00113 nivsm=0;
00114 path = filename = suffix = NULL;
00115 selnodep = NULL;
00116 loadcoef = NULL;
00117 nlman = NULL;
00118
00119
00120
00121 tpr = seconds;
00122
00123
00124
00125
00126
00127 comp_inidispl = no;
00128
00129
00130
00131 lbtype=0;
00132
00133
00134 ssle = new slesolv();
00135
00136
00137 hdbcont.hdbtype = nohdb;
00138 hdbcont.hdbfmtr = text;
00139 hdbcont.hdbfmts = text;
00140 hdbcont.hdbnames[0] = 0;
00141 hdbcont.hdbnamer[0] = 0;
00142 hdbcont.prec=15;
00143 hdbcont.selother_r = NULL;
00144 hdbcont.selother_s = NULL;
00145 hdbcont.selother_id = NULL;
00146 }
00147
00148
00149
00150
00151
00152
00153
00154
00155
00156 probdesc::~probdesc ()
00157 {
00158 delete [] selnodep;
00159 delete [] loadcoef;
00160 delete [] nlman;
00161
00162 delete [] path;
00163 delete [] filename;
00164 delete [] suffix;
00165 delete ssle;
00166 }
00167
00168
00169
00170
00171
00172
00173
00174
00175
00176
00177
00178
00179
00180 void probdesc::read (XFILE *in)
00181 {
00182 long i;
00183
00184
00185
00186
00187 xfscanf (in,"% a",name);
00188
00189
00190 Mespr=0;
00191
00192 xfscanf (in,"%k%ld","mespr",&Mespr);
00193 if (Mespr==1) fprintf (stdout,"\n detail information will be printed");
00194 else fprintf (stdout,"\n only important messages will be printed");
00195
00196
00197 xfscanf (in,"%k%m","problemtype",&problemtype_kwdset,(int*)&tprob);
00198
00199
00200
00201
00202
00203 xfscanf (in,"%k%ld","straincomp", &straincomp);
00204 if (straincomp!=0 && straincomp!=1)
00205 print_err("wrong definition of strain computation", __FILE__, __LINE__, __func__);
00206 if (straincomp==1){
00207 xfscanf (in,"%k%ld%k%ld","strainpos", &strainpos, "strainaver", &strainaver);
00208
00209 if (strainpos!=1 && strainpos!=2 && strainpos!=3){
00210 print_err("wrong definition of position where strains are computed", __FILE__, __LINE__, __func__);
00211 }
00212 if (strainaver!=0 && strainaver!=1 && strainaver!=2)
00213 print_err("wrong definition of strain averaging", __FILE__, __LINE__, __func__);
00214 }
00215
00216 if (Mespr==1){
00217 if (straincomp==0) fprintf (stdout,"\n strains will not be computed and stored");
00218 else{
00219 fprintf (stdout,"\n strains will be computed and stored");
00220 if (strainpos==1) fprintf (stdout,"\n strains will be computed at integration points");
00221 if (strainpos==2) fprintf (stdout,"\n strains will be copied to nodes from the closest integration point");
00222 if (strainpos==3) fprintf (stdout,"\n strains will be computed at nodes");
00223
00224 if (strainaver==0) fprintf (stdout,"\n strains will not be averaged");
00225 if (strainaver==1) fprintf (stdout,"\n strains will be averaged at nodes");
00226 }
00227 }
00228
00229
00230
00231
00232
00233 xfscanf (in,"%k%ld","stresscomp", &stresscomp);
00234 if (stresscomp!=0 && stresscomp!=1)
00235 print_err("wrong definition of stress computation", __FILE__, __LINE__, __func__);
00236 if (stresscomp==1){
00237 xfscanf (in,"%k%ld%k%ld","stresspos", &stresspos, "stressaver", &stressaver);
00238
00239 if (stresspos!=1 && stresspos!=2){
00240 print_err("wrong definition of position where stresses are computed", __FILE__, __LINE__, __func__);
00241 }
00242 if (stressaver!=0 && stressaver!=1)
00243 print_err("wrong definition of stress averaging", __FILE__, __LINE__, __func__);
00244 }
00245
00246 if (Mespr==1){
00247 if (stresscomp==0) fprintf (stdout,"\n stresses will not be computed and stored");
00248 else{
00249 fprintf (stdout,"\n stresses will be computed and stored");
00250 if (stresspos==1) fprintf (stdout,"\n stresses will be computed at integration points");
00251 if (stresspos==2) fprintf (stdout,"\n stresses will be copied to nodes from the closest integration point");
00252
00253 if (stressaver==0) fprintf (stdout,"\n stresses will not be averaged");
00254 if (stressaver==1) fprintf (stdout,"\n stresses will be averaged at nodes");
00255 }
00256 }
00257
00258
00259
00260
00261 xfscanf (in,"%k%ld","othercomp", &othercomp);
00262 if (othercomp!=0 && othercomp!=1)
00263 print_err("wrong definition of other values computation", __FILE__, __LINE__, __func__);
00264 if (othercomp==1){
00265 xfscanf (in,"%k%ld%k%ld","otherpos", &otherpos, "otheraver", &otheraver);
00266
00267 if (otherpos!=1 && otherpos!=2){
00268 print_err("wrong definition of position where other are computed", __FILE__, __LINE__, __func__);
00269 }
00270 if (otheraver!=0 && otheraver!=1)
00271 print_err("wrong definition of other averaging", __FILE__, __LINE__, __func__);
00272 }
00273
00274 if (Mespr==1){
00275 if (othercomp==1){
00276 fprintf (stdout,"\n other will be computed and stored");
00277 if (otherpos==1) fprintf (stdout,"\n other will be computed at integration points");
00278 if (otherpos==2) fprintf (stdout,"\n other will be copied to nodes from the closest integration point");
00279
00280 if (otheraver==0) fprintf (stdout,"\n other will not be averaged");
00281 if (otheraver==1) fprintf (stdout,"\n other will be averaged at nodes");
00282 }
00283 else
00284 fprintf (stdout,"\n other will not be computed and stored");
00285 }
00286
00287
00288
00289
00290 xfscanf (in,"%k%ld","reactcomp", &reactcomp);
00291 if (reactcomp!=0 && reactcomp!=1)
00292 print_err("wrong definition of reaction computation", __FILE__, __LINE__, __func__);
00293 if (Mespr==1){
00294 if (reactcomp==0) fprintf (stdout,"\n reactions will not be computed and stored");
00295 else fprintf (stdout,"\n reactions will be computed and stored");
00296 }
00297
00298
00299
00300
00301
00302 xfscanf (in,"%k%ld","adaptivity",&adaptivityflag);
00303 if (adaptivityflag) {
00304 Ada = new adaptivity();
00305 Ada->readinit(in);
00306 }
00307
00308
00309
00310
00311
00312
00313
00314
00315 xfscanf (in,"%k%ld","stochasticcalc",&stochasticcalc);
00316 if (Mespr==1){
00317 if (stochasticcalc==0)
00318 fprintf (stdout,"\n deterministic computation will be computed");
00319 if (stochasticcalc>0)
00320 fprintf (stdout,"\n stochastic computation will be computed");
00321
00322 }
00323
00324
00325
00326
00327 xfscanf (in,"%k%ld","homogenization",&homog);
00328 if (Mespr==1){
00329 if (homog==0)
00330 fprintf (stdout,"\n homogenization will not be computed");
00331 if (homog!=0)
00332 fprintf (stdout,"\n homogenization will be computed");
00333 if (homog==2){
00334
00335 xfscanf (in,"%k%ld","numtiles",&ntiletypes);
00336
00337
00338
00339
00340
00341
00342
00343
00344 }
00345 if (homog==3){
00346 fprintf (stdout,"\n homogenization with prescribed stresses");
00347 }
00348 if (homog==4){
00349 fprintf (stdout,"\n homogenization with prescribed strains");
00350 }
00351 }
00352
00353
00354
00355
00356 xfscanf (in,"%k%m","noderenumber",&noderenumb_kwdset,(int*)&Gtm->nodren);
00357 if (Mespr==1){
00358 switch (Gtm->nodren){
00359 case no_renumbering:{
00360 fprintf (stdout,"\n nodes will not be renumbered");
00361 break;
00362 }
00363 case cuthill_mckee:{
00364 fprintf (stdout,"\n nodes will be renumbered by Cuthill-McKee algorithm");
00365 break;
00366 }
00367 case rev_cuthill_mckee:{
00368 fprintf (stdout,"\n nodes will be renumbered by reverse Cuthill-McKee algorithm");
00369 break;
00370 }
00371 case sloan:{
00372 fprintf (stdout,"\n nodes will be renumbered by Sloan algorithm");
00373 break;
00374 }
00375 default:{
00376 print_err("unknown type of node reordering is required",__FILE__,__LINE__,__func__);
00377 }
00378 }
00379 }
00380
00381
00382 switch (tprob){
00383
00384
00385
00386 case linear_statics:{
00387 if (Mespr==1) fprintf (stdout,"\n linear static problem");
00388
00389
00390 xfscanf (in,"%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm);
00391
00392
00393 ssle->read (Gtm,in,Mespr);
00394
00395 break;
00396 }
00397
00398
00399
00400 case eigen_dynamics:{
00401 if (Mespr==1) fprintf (stdout,"\n eigenvalue vibration problem");
00402
00403
00404
00405 xfscanf (in,"%k%m%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm,"massmatstor",&storagetype_kwdset,(int*)&tstormm);
00406
00407
00408 eigsol.read (in);
00409
00410
00411 ssle->read (Gtm,in,Mespr);
00412
00413 break;
00414 }
00415
00416
00417
00418 case forced_dynamics:{
00419 if (Mespr==1) fprintf (stdout,"\n forced vibration problem");
00420
00421
00422 xfscanf (in,"%k%m","forceddyn",&forcedsolver_kwdset,(int*)&tforvib);
00423
00424 switch (tforvib){
00425 case newmark:{
00426 xfscanf (in,"%lf %lf",&alphafvn,&deltafvn);
00427 break;
00428 }
00429 case findiff:{
00430 break;
00431 }
00432 case modal_analysis:{
00433
00434 eigsol.read (in);
00435 break;
00436 }
00437 default:{
00438 print_err("unknown solver of forced vibration is required",__FILE__,__LINE__,__func__);
00439 }
00440 }
00441
00442
00443 xfscanf (in,"%k%m","damping",&damping_kwdset,(int*)&damp);
00444 switch (damp){
00445 case nodamp:{
00446 if (Mespr==1) fprintf (stdout,"\n no damping is prescribed");
00447 break;
00448 }
00449 case massdamp:{
00450 xfscanf (in,"%lf",&dmass);
00451 if (Mespr==1) fprintf (stdout,"\n damping proportional to the mass matrix is prescribed");
00452 break;
00453 }
00454 case stiffdamp:{
00455 xfscanf (in,"%lf",&dstiff);
00456 if (Mespr==1) fprintf (stdout,"\n damping proportional to the stiffness matrix is prescribed");
00457 break;
00458 }
00459 case rayleighdamp:{
00460 xfscanf (in,"%lf %lf",&dstiff,&dmass);
00461 if (Mespr==1) fprintf (stdout,"\n Rayleigh damping (proportional to the mass and stiffness matrices) is prescribed");
00462 break;
00463 }
00464 default:{
00465 print_err("unknown type of damping is required",__FILE__,__LINE__,__func__);
00466 }
00467 }
00468
00469
00470
00471
00472 xfscanf (in,"%k%m%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm,"massmatstor",&storagetype_kwdset,(int*)&tstormm);
00473
00474
00475 timecon.read (in);
00476
00477
00478 ssle->read (Gtm,in,Mespr);
00479
00480 break;
00481 }
00482
00483
00484
00485 case mat_nonlinear_statics:{
00486 if (Mespr==1) fprintf (stdout,"\n nonlinear static problem");
00487
00488
00489 nlman = new nonlinman[1];
00490 nlman->read (in,Mespr);
00491
00492
00493 hdbcont.read(in);
00494 if ((Mespr==1) && hdbcont.hdbtype)
00495 fprintf(stdout, "\n backup will be performed %d", hdbcont.hdbtype);
00496
00497
00498 xfscanf (in,"%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm);
00499
00500
00501 ssle->read (Gtm,in,Mespr);
00502
00503 break;
00504 }
00505
00506
00507
00508 case mech_timedependent_prob:{
00509 if (Mespr==1) fprintf (stdout,"\n system of nonlinear equations will be solved by visco-solver");
00510
00511
00512 timecon.read (in);
00513
00514
00515 xfscanf (in,"%k%m","timetypeprin", &timetypeprin_kwdset, &tpr);
00516
00517
00518 hdbcont.read(in);
00519 if ((Mespr==1) && hdbcont.hdbtype)
00520 fprintf(stdout, "\n backup will be performed %d", hdbcont.hdbtype);
00521
00522 nlman = new nonlinman[1];
00523
00524
00525 xfscanf (in,"%k%ld%k%lf","nr_num_iter",&nlman->niilnr,"nr_error",&nlman->errnr);
00526
00527
00528 xfscanf(in, "%k%m", "check_div", &flagsw_kwdset, (int *)&nlman->check_div);
00529 if (Mp->nlman->check_div == on)
00530 {
00531 xfscanf(in, "%k%ld", "div_min_steps", &nlman->div_min_steps);
00532 if (Mp->nlman->div_min_steps < 3)
00533 {
00534 print_warning("the minimum number of performed steps in the divergency check is < 3.\n"
00535 "It will be set to 3 automatically", __FILE__, __LINE__, __func__);
00536 Mp->nlman->div_min_steps = 3;
00537 }
00538 }
00539
00540
00541
00542 xfscanf (in,"%k%m%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm, "stiffmat_type", &stiffmatrix_kwdset, (int*)&nlman->stmat);
00543 if(nlman->stmat == ijth_tangent_stiff)
00544 xfscanf (in,"%ld %ld", &nlman->ithstiffchange, &nlman->jthstiffchange);
00545
00546
00547 ssle->read (Gtm,in,Mespr);
00548
00549 break;
00550 }
00551
00552
00553
00554 case growing_mech_structure:{
00555 if (Mespr==1) fprintf (stdout,"\n system with gradual construction will be solved by visco-solver");
00556
00557
00558 timecon.read (in);
00559
00560
00561 xfscanf (in,"%k%m","timetypeprin", &timetypeprin_kwdset, &tpr);
00562
00563
00564 xfscanf (in, "%k%m", "comp_inidispl", &answertype_kwdset, &comp_inidispl);
00565
00566
00567 hdbcont.read(in);
00568
00569 if ((Mespr==1) && hdbcont.hdbtype)
00570 fprintf(stdout, "\n backup will be performed");
00571
00572 nlman = new nonlinman[1];
00573
00574
00575
00576 xfscanf (in,"%k%ld%k%lf","nr_num_iter",&niilnr,"nr_error",&errnr);
00577
00578
00579 xfscanf (in,"%k%m","nr_solvtype", &nonlintimesolvertype_kwdset, (int*)&nrsolv);
00580
00581
00582
00583 xfscanf (in,"%k%m%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm, "stiffmat_type", &stiffmatrix_kwdset, (int*)&nlman->stmat);
00584 if(nlman->stmat == ijth_tangent_stiff)
00585 xfscanf (in,"%ld %ld", &nlman->ithstiffchange, &nlman->jthstiffchange);
00586
00587
00588 ssle->read (Gtm,in,Mespr);
00589
00590
00591 Gtm->dofcontr=1;
00592
00593 break;
00594 }
00595
00596
00597
00598
00599
00600
00601
00602
00603
00604
00605
00606
00607
00608
00609
00610
00611
00612
00613
00614
00615
00616
00617
00618
00619
00620
00621
00622
00623
00624
00625
00626
00627
00628
00629
00630
00631
00632
00633
00634
00635
00636
00637
00638 case earth_pressure:{
00639 if (Mespr==1) fprintf (stdout,"\n system of nonlinear equations will be solved by earth pressure solver");
00640
00641 xfscanf(in, "%d", (int*)&tepsol);
00642 switch (tepsol){
00643 case gep_sol:{
00644 xfscanf (in,"%ld %lf %lf %lf",&niep,&errep,&stepep,&rlerrep);
00645
00646
00647 nlman = new nonlinman[1];
00648 nlman->read (in,Mespr);
00649
00650
00651 xfscanf (in,"%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm);
00652
00653 ssle->read (Gtm,in,Mespr);
00654 break;
00655 }
00656 case gepvarsup_sol:{
00657 xfscanf (in,"%ld %lf %lf",&niep,&errep, &rlerrep);
00658
00659
00660 nlman = new nonlinman[1];
00661 nlman->read (in,Mespr);
00662
00663 xfscanf (in, "%ld", &nselnodep);
00664 if (niep < nselnodep)
00665 {
00666 fprintf(stderr, "\n\n Number of iteration steps is less then number of selected nodes");
00667 fprintf(stderr, "\n in file %s, line %d", __FILE__, __LINE__);
00668 }
00669 selnodep = new long [nselnodep];
00670 memset(selnodep, 0, sizeof(*selnodep)*nselnodep);
00671 for (i = 0; i < nselnodep; i++)
00672 {
00673 xfscanf (in, "%ld", selnodep+i);
00674 selnodep[i]--;
00675 }
00676
00677 xfscanf (in,"%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm);
00678
00679 ssle->read (Gtm,in,Mespr);
00680 break;
00681 }
00682 case epplast_sol:{
00683 xfscanf (in, "%ld", &niep);
00684 loadcoef = new double[niep];
00685 memset(loadcoef, 0, niep*sizeof(*loadcoef));
00686 for (i = 0; i < niep; i++)
00687 xfscanf(in, "%le", loadcoef+i);
00688
00689
00690 nlman = new nonlinman[1];
00691 nlman->read (in,Mespr);
00692
00693
00694
00695 xfscanf (in,"%k%m%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm, "stiffmat_type", &stiffmatrix_kwdset, (int*)&nlman->stmat);
00696
00697 ssle->read (Gtm,in,Mespr);
00698 break;
00699 }
00700 default:{
00701 print_err("uknown type of earth pressure is required",__FILE__,__LINE__,__func__);
00702 }
00703 }
00704
00705 break;
00706 }
00707
00708
00709
00710 case layered_linear_statics:{
00711 if (Mespr==1) fprintf (stdout,"\n linear layered static problem");
00712
00713
00714 xfscanf (in,"%d",(int*)&tstorsm);
00715
00716
00717 ssle->read (Gtm,in,Mespr);
00718
00719 break;
00720 }
00721
00722
00723
00724
00725 case lin_floating_subdomain:{
00726 if (Mespr==1) fprintf (stdout,"\n linear floating subdomain problem");
00727
00728
00729 xfscanf (in,"%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm);
00730
00731
00732
00733
00734
00735 ssle->read (Gtm,in,Mespr);
00736
00737
00738
00739
00740 break;
00741 }
00742
00743
00744
00745
00746 case nonlin_floating_subdomain:{
00747 if (Mespr==1) fprintf (stdout,"\n nonlinear floating subdomain problem");
00748
00749
00750
00751
00752
00753
00754 xfscanf (in,"%k%m","stiffmatstor", &storagetype_kwdset, (int*)&tstorsm);
00755
00756
00757
00758 xfscanf (in,"%le %ld",&limit,&nincr);
00759
00760
00761 ssle->read (Gtm,in,Mespr);
00762
00763 break;
00764 }
00765
00766
00767
00768
00769 case nonlinear_dynamics:{
00770 if (Mespr==1) fprintf (stdout,"\n problem of nonlinear dynamics");
00771
00772
00773 xfscanf (in,"%k%m","forceddyn",&forcedsolver_kwdset,(int*)&tforvib);
00774
00775
00776 nlman = new nonlinman[1];
00777 nlman->read (in,Mespr);
00778
00779 switch (tforvib){
00780 case newmark:{
00781 xfscanf (in,"%lf %lf",&alphafvn,&deltafvn);
00782 break;
00783 }
00784
00785 default:{
00786 print_err("unknown solver of forced vibration is required",__FILE__,__LINE__,__func__);
00787 }
00788 }
00789
00790
00791 xfscanf (in,"%k%m","damping",&damping_kwdset,(int*)&damp);
00792 switch (damp){
00793 case nodamp:{
00794 if (Mespr==1) fprintf (stdout,"\n no damping is prescribed");
00795 break;
00796 }
00797 case massdamp:{
00798 xfscanf (in,"%lf",&dmass);
00799 if (Mespr==1) fprintf (stdout,"\n damping proportional to the mass matrix is prescribed");
00800 break;
00801 }
00802 case stiffdamp:{
00803 xfscanf (in,"%lf",&dstiff);
00804 if (Mespr==1) fprintf (stdout,"\n damping proportional to the stiffness matrix is prescribed");
00805 break;
00806 }
00807 case rayleighdamp:{
00808 xfscanf (in,"%lf %lf",&dstiff,&dmass);
00809 if (Mespr==1) fprintf (stdout,"\n Rayleigh damping (proportional to the mass and stiffness matrices) is prescribed");
00810 break;
00811 }
00812 default:{
00813 print_err("unknown type of damping is required",__FILE__,__LINE__,__func__);
00814 }
00815 }
00816
00817
00818
00819
00820 xfscanf (in,"%k%m%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm,"massmatstor",&storagetype_kwdset,(int*)&tstormm);
00821
00822
00823 timecon.read (in);
00824
00825
00826 ssle->read (Gtm,in,Mespr);
00827
00828 break;
00829 }
00830
00831
00832
00833
00834 case hemivar_inequal:{
00835 if (Mespr==1) fprintf (stdout,"\n problem of hemivariational inequalities");
00836
00837
00838
00839
00840
00841 xfscanf (in,"%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm);
00842
00843
00844 ssle->read (Gtm,in,Mespr);
00845
00846 break;
00847 }
00848
00849
00850
00851 case load_balancing:{
00852 if (Mespr==1) fprintf (stdout,"\n problem of load balancing");
00853
00854
00855
00856
00857 xfscanf (in,"%ld",&lbtype);
00858
00859
00860 xfscanf (in,"%k%m","stiffmatstor",&storagetype_kwdset,(int*)&tstorsm);
00861
00862
00863 ssle->read (Gtm,in,Mespr);
00864
00865
00866
00867 Gtm->cngen=2;
00868
00869
00870 Gtm->rst=1;
00871
00872 break;
00873 }
00874
00875 default:{
00876 print_err("unknown problem type is required",__FILE__,__LINE__,__func__);
00877 }
00878 }
00879
00880 }
00881
00882
00883
00884
00885
00886
00887
00888
00889
00890
00891
00892
00893
00894 void probdesc::print (FILE *out)
00895 {
00896 long i;
00897
00898
00899 fprintf (out, "%s\n", name);
00900
00901
00902 fprintf (out, "%ld\n", Mespr);
00903
00904
00905 fprintf (out, "%d\n", (int)tprob);
00906
00907
00908 fprintf (out,"%ld ",straincomp);
00909 if (straincomp==1) fprintf (out,"%ld %ld ",strainpos,strainaver);
00910
00911
00912 fprintf (out,"%ld ",stresscomp);
00913 if (stresscomp==1) fprintf (out,"%ld %ld ",stresspos,stressaver);
00914
00915
00916 fprintf (out,"%ld ",othercomp);
00917 if (othercomp==1) fprintf (out,"%ld %ld ",otherpos,otheraver);
00918
00919
00920 fprintf (out,"%ld\n",reactcomp);
00921
00922
00923 if (adaptivityflag)
00924 Ada->printinit(out);
00925 else
00926 fprintf (out,"0\n");
00927
00928
00929 fprintf (out,"%ld\n",stochasticcalc);
00930
00931
00932 fprintf (out,"%ld\n",homog);
00933
00934
00935 fprintf (out,"%d\n",Gtm->nodren);
00936
00937
00938 switch (tprob){
00939
00940
00941
00942 case linear_statics:{
00943
00944
00945
00946
00947 fprintf (out, "%d\n", (int)tstorsm);
00948
00949 ssle->print (out);
00950
00951
00952 fprintf(out, "\n");
00953 break;
00954 }
00955
00956
00957
00958
00959 case eigen_dynamics:{
00960 fprintf (out, "%d %d\n", (int)tstorsm, (int)tstormm);
00961
00962
00963 eigsol.print (out);
00964
00965
00966 ssle->print (out);
00967
00968 break;
00969 }
00970
00971
00972
00973 case forced_dynamics:
00974 {
00975 fprintf (out,"%d\n",(int)tforvib);
00976
00977 switch (tforvib){
00978 case newmark:{
00979 fprintf (out, "%f %f",alphafvn, deltafvn);
00980 break;
00981 }
00982 case findiff:{
00983 break;
00984 }
00985 default:{
00986 print_err("unknown solver of forced vibration is required",__FILE__,__LINE__,__func__);
00987 }
00988 }
00989
00990
00991 fprintf (out,"%d\n",(int)damp);
00992
00993 switch (damp){
00994 case nodamp:{
00995 break;
00996 }
00997 case massdamp:{
00998 fprintf (out,"%f\n",dmass);
00999 break;
01000 }
01001 case stiffdamp:{
01002 fprintf (out,"%f\n",dstiff);
01003 break;
01004 }
01005 case rayleighdamp:{
01006 fprintf (out,"%f %f\n",dstiff,dmass);
01007 break;
01008 }
01009 default:{
01010 print_err("unknown type of damping is required",__FILE__,__LINE__,__func__);
01011 }
01012 }
01013
01014 fprintf (out,"%d %d\n",(int)tstorsm,(int)tstormm);
01015
01016 timecon.print (out);
01017
01018 ssle->print (out);
01019
01020 break;
01021 }
01022
01023
01024
01025 case mat_nonlinear_statics:
01026 {
01027
01028
01029 nlman->print (out);
01030
01031
01032 hdbcont.print (out);
01033
01034 fprintf (out, "\n%d \n", (int)tstorsm);
01035
01036 ssle->print (out);
01037
01038 break;
01039 }
01040
01041
01042
01043 case mech_timedependent_prob:{
01044
01045 timecon.print (out);
01046
01047
01048 fprintf (out,"%d\n", tpr);
01049
01050
01051 hdbcont.print (out);
01052
01053
01054
01055 fprintf (out,"%ld %le\n",nlman->niilnr,nlman->errnr);
01056
01057
01058 fprintf (out,"%d\n",nlman->check_div);
01059 if (Mp->nlman->check_div == on){
01060 fprintf (out,"%ld",nlman->div_min_steps);
01061 }
01062
01063
01064
01065
01066
01067
01068 fprintf (out,"%d %d\n",(int)tstorsm,(int)nlman->stmat);
01069 if(nlman->stmat == ijth_tangent_stiff)
01070 fprintf (out,"%ld %ld\n", nlman->ithstiffchange, nlman->jthstiffchange);
01071
01072 ssle->print (out);
01073 break;
01074 }
01075
01076
01077
01078
01079
01080 case growing_mech_structure:{
01081
01082
01083 timecon.print (out);
01084
01085
01086 fprintf (out,"%d\n", tpr);
01087
01088
01089 fprintf (out, "%d\n", comp_inidispl);
01090
01091
01092 hdbcont.print (out);
01093
01094
01095
01096 fprintf (out,"%ld %le",niilnr,errnr);
01097
01098
01099 fprintf (out," %d\n",nrsolv);
01100
01101 fprintf (out,"%d %d\n",(int)tstorsm,(int)nlman->stmat);
01102 if(nlman->stmat == ijth_tangent_stiff)
01103 fprintf (out,"%ld %ld\n", nlman->ithstiffchange, nlman->jthstiffchange);
01104
01105 ssle->print (out);
01106
01107 break;
01108 }
01109
01110
01111
01112
01113
01114 case earth_pressure:{
01115 fprintf(out, "%d", (int)tepsol);
01116 switch (tepsol){
01117 case gep_sol:{
01118 fprintf (out,"%ld %le %le %le",niep,errep,stepep,rlerrep);
01119
01120 nlman->print (out);
01121
01122
01123 fprintf (out,"%d ",(int)tstorsm);
01124
01125 ssle->print (out);
01126 break;
01127 }
01128 case gepvarsup_sol:{
01129 fprintf (out,"%ld %e %e\n",niep,errep,rlerrep);
01130
01131 nlman->print (out);
01132
01133 fprintf (out, "%ld\n", nselnodep);
01134 if (niep < nselnodep)
01135 {
01136 fprintf(stderr, "\n\n Number of iteration steps is less then number of selected nodes");
01137 fprintf(stderr, "\n in file %s, line %d", __FILE__, __LINE__);
01138 }
01139 for (i = 0; i < nselnodep; i++)
01140 fprintf (out, "%ld ", selnodep[i]);
01141
01142 fprintf (out,"\n%d ",(int)tstorsm);
01143
01144 ssle->print (out);
01145 break;
01146 }
01147 case epplast_sol:{
01148 fprintf (out, " %ld\n", niep);
01149 for (i = 0; i < niep; i++)
01150 fprintf (out, "%f ", loadcoef[i]);
01151
01152 nlman->print (out);
01153
01154
01155
01156 fprintf (out,"%d %d\n",(int)tstorsm,(int)nlman->stmat);
01157
01158 ssle->print (out);
01159 break;
01160 }
01161 default:{
01162 print_err("unknown type of earth pressure is required",__FILE__,__LINE__,__func__);
01163 }
01164 }
01165 break;
01166 }
01167
01168
01169
01170 case layered_linear_statics:{
01171
01172
01173
01174
01175 fprintf (out, "%d\n", (int)tstorsm);
01176
01177 ssle->print (out);
01178
01179
01180 fprintf(out, "\n");
01181
01182 break;
01183 }
01184
01185
01186
01187
01188 case lin_floating_subdomain:{
01189
01190 fprintf (out, "%d\n", (int)tstorsm);
01191
01192
01193
01194 ssle->print (out);
01195
01196 break;
01197 }
01198
01199
01200
01201 case nonlin_floating_subdomain:{
01202 nlman->print (out);
01203
01204
01205
01206 fprintf (out,"%ld %le\n",ense,limit);
01207
01208 ssle->print (out);
01209
01210 break;
01211 }
01212
01213 case nonlinear_dynamics:{
01214 if (Mespr==1) fprintf (stdout,"\n problem of nonlinear dynamics");
01215
01216
01217 break;
01218 }
01219
01220
01221
01222
01223 case hemivar_inequal:{
01224
01225
01226
01227
01228
01229 fprintf (out, "%d\n", (int)tstorsm);
01230
01231
01232 ssle->print (out);
01233
01234 break;
01235 }
01236
01237
01238
01239 case load_balancing:{
01240 if (Mespr==1) fprintf (stdout,"\n problem of load balancing");
01241
01242
01243
01244 fprintf (out,"%ld\n",lbtype);
01245
01246
01247 fprintf (out,"%d\n",(int)tstorsm);
01248
01249
01250 ssle->print (out);
01251
01252 break;
01253 }
01254
01255 default:{
01256 print_err("unknown type of problem is required",__FILE__,__LINE__,__func__);
01257 break;
01258 }
01259 }
01260
01261 fprintf (out,"\n");
01262 }