Changeset 15099
- Timestamp:
- 05/24/13 12:38:54 (12 years ago)
- Location:
- issm/trunk-jpl/src
- Files:
-
- 216 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/analyses/DakotaSpawnCore.cpp
r15001 r15099 62 62 femmodel->parameters->FindParam(&control_analysis,InversionIscontrolEnum); 63 63 64 if(VerboseQmu()) _pprint Line_("qmu iteration: " << counter);64 if(VerboseQmu()) _pprintString_("qmu iteration: " << counter << "\n"); 65 65 66 66 /* only cpu 0, running dakota is providing us with variables and variables_descriptors and numresponses: broadcast onto other cpus: */ … … 71 71 72 72 /*Determine solution sequence: */ 73 if(VerboseQmu()) _pprint Line_("Starting " << EnumToStringx(solution_type) << " core:");73 if(VerboseQmu()) _pprintString_("Starting " << EnumToStringx(solution_type) << " core:" << "\n"); 74 74 WrapperCorePointerFromSolutionEnum(&solutioncore,femmodel->parameters,solution_type,nodakotacore); 75 75 … … 78 78 79 79 /*compute responses: */ 80 if(VerboseQmu()) _pprint Line_("compute dakota responses:");80 if(VerboseQmu()) _pprintString_("compute dakota responses:" << "\n"); 81 81 femmodel->DakotaResponsesx(d_responses,responses_descriptors,numresponsedescriptors,d_numresponses); 82 82 -
issm/trunk-jpl/src/c/analyses/ResetBoundaryConditions.cpp
r15001 r15099 13 13 Nodes *nodes = NULL; 14 14 15 if(VerboseSolution()) _pprint Line_(" updating boundary conditions...");15 if(VerboseSolution()) _pprintString_(" updating boundary conditions..." << "\n"); 16 16 17 17 /*set current analysis: */ -
issm/trunk-jpl/src/c/analyses/ad_core.cpp
r15001 r15099 49 49 if(!(num_dependents*num_independents)) return; 50 50 51 if(VerboseAutodiff())_pprint Line_(" start ad core");51 if(VerboseAutodiff())_pprintString_(" start ad core" << "\n"); 52 52 53 53 /*retrieve state variable: */ … … 286 286 tapestats(1,tape_stats); //reading of tape statistics 287 287 if(VerboseAutodiff()){ 288 _pprint Line_(" ADOLC statistics:");289 _pprint Line_(" "<<setw(45)<<left<<"Number of independents: " <<tape_stats[0]);290 _pprint Line_(" "<<setw(45)<<left<<"Number of dependents: " <<tape_stats[1]);291 _pprint Line_(" "<<setw(45)<<left<<"Maximal number of live active variables: " <<tape_stats[2]);292 _pprint Line_(" "<<setw(45)<<left<<"Size of value stack (number of overwrites): " <<tape_stats[3]);293 _pprint Line_(" "<<setw(45)<<left<<"Buffer size (a multiple of eight): " <<tape_stats[4]);294 _pprint Line_(" "<<setw(45)<<left<<"Total number of operations recorded: " <<tape_stats[5]);295 } 296 if(VerboseAutodiff())_pprint Line_(" end AD core");288 _pprintString_(" ADOLC statistics: " << "\n"); 289 _pprintString_(" "<<setw(45)<<left<<"Number of independents: " <<tape_stats[0] << "\n"); 290 _pprintString_(" "<<setw(45)<<left<<"Number of dependents: " <<tape_stats[1] << "\n"); 291 _pprintString_(" "<<setw(45)<<left<<"Maximal number of live active variables: " <<tape_stats[2] << "\n"); 292 _pprintString_(" "<<setw(45)<<left<<"Size of value stack (number of overwrites): " <<tape_stats[3] << "\n"); 293 _pprintString_(" "<<setw(45)<<left<<"Buffer size (a multiple of eight): " <<tape_stats[4] << "\n"); 294 _pprintString_(" "<<setw(45)<<left<<"Total number of operations recorded: " <<tape_stats[5] << "\n"); 295 } 296 if(VerboseAutodiff())_pprintString_(" end AD core" << "\n"); 297 297 298 298 /*Free resources: */ -
issm/trunk-jpl/src/c/analyses/adjointbalancethickness_core.cpp
r15001 r15099 19 19 20 20 /*compute thickness */ 21 if(VerboseSolution()) _pprint Line_(" computing thickness");21 if(VerboseSolution()) _pprintString_(" computing thickness" << "\n"); 22 22 femmodel->SetCurrentConfiguration(BalancethicknessAnalysisEnum); 23 23 solutionsequence_linear(femmodel); … … 27 27 28 28 /*compute adjoint*/ 29 if(VerboseSolution()) _pprint Line_(" computing adjoint");29 if(VerboseSolution()) _pprintString_(" computing adjoint" << "\n"); 30 30 femmodel->SetCurrentConfiguration(BalancethicknessAnalysisEnum,AdjointBalancethicknessAnalysisEnum); 31 31 solutionsequence_adjoint_linear(femmodel); … … 33 33 /*Save results*/ 34 34 if(save_results){ 35 if(VerboseSolution()) _pprint Line_(" saving results");35 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 36 36 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,AdjointEnum); 37 37 } -
issm/trunk-jpl/src/c/analyses/adjointdiagnostic_core.cpp
r15001 r15099 22 22 23 23 /*Compute velocities*/ 24 if(VerboseSolution()) _pprint Line_(" computing velocities");24 if(VerboseSolution()) _pprintString_(" computing velocities" << "\n"); 25 25 femmodel->SetCurrentConfiguration(DiagnosticHorizAnalysisEnum); 26 26 solutionsequence_nonlinear(femmodel,conserve_loads); … … 30 30 31 31 /*Compute adjoint*/ 32 if(VerboseSolution()) _pprint Line_(" computing adjoint");32 if(VerboseSolution()) _pprintString_(" computing adjoint" << "\n"); 33 33 femmodel->SetCurrentConfiguration(DiagnosticHorizAnalysisEnum,AdjointHorizAnalysisEnum); 34 34 solutionsequence_adjoint_linear(femmodel); … … 36 36 /*Save results*/ 37 37 if(save_results){ 38 if(VerboseSolution()) _pprint Line_(" saving results");38 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 39 39 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,AdjointxEnum); 40 40 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,AdjointyEnum); -
issm/trunk-jpl/src/c/analyses/balancethickness_core.cpp
r15001 r15099 21 21 femmodel->parameters->FindParam(&save_results,SaveResultsEnum); 22 22 23 if(VerboseSolution()) _pprint Line_("call computational core:");23 if(VerboseSolution()) _pprintString_("call computational core:" << "\n"); 24 24 solutionsequence_linear(femmodel); 25 25 26 26 if(save_results){ 27 if(VerboseSolution()) _pprint Line_(" saving results");27 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 28 28 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,ThicknessEnum); 29 29 } -
issm/trunk-jpl/src/c/analyses/bedslope_core.cpp
r15001 r15099 18 18 femmodel->parameters->FindParam(&save_results,SaveResultsEnum); 19 19 20 if(VerboseSolution()) _pprint Line_(" computing slope");20 if(VerboseSolution()) _pprintString_(" computing slope" << "\n"); 21 21 22 22 /*Call on core computations: */ … … 27 27 28 28 if(save_results){ 29 if(VerboseSolution()) _pprint Line_(" saving results");29 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 30 30 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,BedSlopeXEnum); 31 31 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,BedSlopeYEnum); -
issm/trunk-jpl/src/c/analyses/control_core.cpp
r15055 r15099 66 66 67 67 /*Launch once a complete solution to set up all inputs*/ 68 if(VerboseControl()) _pprint Line_(" preparing initial solution");68 if(VerboseControl()) _pprintString_(" preparing initial solution" << "\n"); 69 69 if(isstokes) solutioncore(femmodel); 70 70 … … 81 81 82 82 /*Display info*/ 83 if(VerboseControl()) _pprint Line_("\n" << " control method step " << n+1 << "/" << nsteps);83 if(VerboseControl()) _pprintString_("\n" << " control method step " << n+1 << "/" << nsteps << "\n"); 84 84 for(i=0;i<num_responses;i++) step_responses[i]=reCast<int,IssmDouble>(responses[n*num_responses+i]); 85 85 femmodel->parameters->SetParam(step_responses,1,num_responses,StepResponsesEnum); … … 88 88 if(solution_type==SteadystateSolutionEnum) solutioncore(femmodel); 89 89 90 if(VerboseControl()) _pprint Line_(" compute adjoint state:");90 if(VerboseControl()) _pprintString_(" compute adjoint state:" << "\n"); 91 91 adjointcore(femmodel); 92 92 gradient_core(femmodel,n,search_scalar==0); … … 98 98 } 99 99 100 if(VerboseControl()) _pprint Line_(" optimizing along gradient direction");100 if(VerboseControl()) _pprintString_(" optimizing along gradient direction" << "\n"); 101 101 optpars.maxiter=reCast<int,IssmDouble>(maxiter[n]); optpars.cm_jump=cm_jump[n]; 102 102 BrentSearch(&search_scalar,J+n,&optpars,&objectivefunction,&optargs); 103 103 104 if(VerboseControl()) _pprint Line_(" updating parameter using optimized search scalar"); //true means update save controls104 if(VerboseControl()) _pprintString_(" updating parameter using optimized search scalar" << "\n"); //true means update save controls 105 105 InputControlUpdatex(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,search_scalar,true); 106 106 … … 108 108 } 109 109 110 if(VerboseControl()) _pprint Line_(" preparing final solution");110 if(VerboseControl()) _pprintString_(" preparing final solution" << "\n"); 111 111 femmodel->parameters->SetParam(true,SaveResultsEnum); 112 112 solutioncore(femmodel); -
issm/trunk-jpl/src/c/analyses/controltao_core.cpp
r15001 r15099 54 54 /*Initialize TAO*/ 55 55 TaoCreate(IssmComm::GetComm(),&tao); 56 if(VerboseControl()) _pprint Line_(" Initializing the Toolkit for Advanced Optimization (TAO)");56 if(VerboseControl()) _pprintString_(" Initializing the Toolkit for Advanced Optimization (TAO)" << "\n"); 57 57 TaoSetFromOptions(tao); 58 58 TaoSetType(tao,"tao_blmvm"); … … 79 79 80 80 /*Solver optimization problem*/ 81 if(VerboseControl()) _pprint Line_(" Starting optimization");81 if(VerboseControl()) _pprintString_(" Starting optimization" << "\n"); 82 82 TaoSolve(tao); 83 83 TaoView(tao,PETSC_VIEWER_STDOUT_WORLD); … … 90 90 91 91 /*Finalize*/ 92 if(VerboseControl()) _pprint Line_(" preparing final solution");92 if(VerboseControl()) _pprintString_(" preparing final solution" << "\n"); 93 93 femmodel->parameters->SetParam(true,SaveResultsEnum); 94 94 void (*solutioncore)(FemModel*)=NULL; … … 166 166 167 167 TaoGetSolutionStatus(tao, &its, &f, &gnorm, &cnorm, &xdiff, NULL); 168 if(its==0) _pprint Line_("Iter Function Residual | List of contributions");169 if(its==0) _pprint Line_("-----------------------------------+-----------------------");168 if(its==0) _pprintString_("Iter Function Residual | List of contributions" << "\n"); 169 if(its==0) _pprintString_("-----------------------------------+-----------------------" << "\n"); 170 170 _pprintString_(setw(4)<<its<<" "<<setw(12)<<setprecision(7)<<f<<" "<<setw(12)<<setprecision(7)<<gnorm<<" | "); 171 171 user->J[its]=f; … … 176 176 _pprintString_(" "<<setw(12)<<setprecision(7)<<f); 177 177 } 178 _pprint Line_("");178 _pprintString_("" << "\n"); 179 179 180 180 /*Clean-up and return*/ -
issm/trunk-jpl/src/c/analyses/diagnostic_core.cpp
r15001 r15099 58 58 if(ishutter){ 59 59 60 if(VerboseSolution()) _pprint Line_(" computing hutter velocities");60 if(VerboseSolution()) _pprintString_(" computing hutter velocities" << "\n"); 61 61 62 62 //Take the last velocity into account so that the velocity on the MacAyeal domain is not zero … … 71 71 if ((ismacayealpattyn || isl1l2) ^ isstokes){ // ^ = xor 72 72 73 if(VerboseSolution()) _pprint Line_(" computing velocities");73 if(VerboseSolution()) _pprintString_(" computing velocities" << "\n"); 74 74 femmodel->SetCurrentConfiguration(DiagnosticHorizAnalysisEnum); 75 75 if(newton>0) … … 81 81 if (ismacayealpattyn && isstokes){ 82 82 83 if(VerboseSolution()) _pprint Line_(" computing coupling macayealpattyn and stokes velocities and pressure");83 if(VerboseSolution()) _pprintString_(" computing coupling macayealpattyn and stokes velocities and pressure " << "\n"); 84 84 solutionsequence_stokescoupling_nonlinear(femmodel,conserve_loads); 85 85 } … … 87 87 if (dim==3 & (ishutter || ismacayealpattyn)){ 88 88 89 if(VerboseSolution()) _pprint Line_(" computing vertical velocities");89 if(VerboseSolution()) _pprintString_(" computing vertical velocities" << "\n"); 90 90 femmodel->SetCurrentConfiguration(DiagnosticVertAnalysisEnum); 91 91 solutionsequence_linear(femmodel); … … 93 93 94 94 if(save_results){ 95 if(VerboseSolution()) _pprint Line_(" saving results");95 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 96 96 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,VxEnum); 97 97 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,VyEnum); -
issm/trunk-jpl/src/c/analyses/enthalpy_core.cpp
r15001 r15099 18 18 femmodel->parameters->FindParam(&save_results,SaveResultsEnum); 19 19 20 if(VerboseSolution()) _pprint Line_(" computing enthalpy");20 if(VerboseSolution()) _pprintString_(" computing enthalpy" << "\n"); 21 21 femmodel->SetCurrentConfiguration(EnthalpyAnalysisEnum); 22 22 solutionsequence_nonlinear(femmodel,true); … … 26 26 27 27 if(save_results){ 28 if(VerboseSolution()) _pprint Line_(" saving results");28 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 29 29 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,TemperatureEnum); 30 30 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,EnthalpyEnum); -
issm/trunk-jpl/src/c/analyses/gia_core.cpp
r15001 r15099 26 26 femmodel->parameters->FindParam(&configuration_type,ConfigurationTypeEnum); 27 27 28 if(VerboseSolution()) _pprint Line_(" computing GIA");28 if(VerboseSolution()) _pprintString_(" computing GIA" << "\n"); 29 29 30 30 /*Call on core computations: */ … … 50 50 51 51 if(save_results){ 52 if(VerboseSolution()) _pprint Line_(" saving results");52 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 53 53 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,GiaWEnum); 54 54 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,GiadWdtEnum); -
issm/trunk-jpl/src/c/analyses/gradient_core.cpp
r15001 r15099 20 20 21 21 /*Compute gradient*/ 22 if(VerboseControl()) _pprint Line_(" compute cost function gradient");22 if(VerboseControl()) _pprintString_(" compute cost function gradient" << "\n"); 23 23 Gradjx(&gradient,&norm_list,femmodel->elements,femmodel->nodes, femmodel->vertices,femmodel->loads, femmodel->materials,femmodel->parameters); 24 24 25 25 if (orthogonalize){ 26 if(VerboseControl()) _pprint Line_(" orthogonalization");26 if(VerboseControl()) _pprintString_(" orthogonalization" << "\n"); 27 27 ControlInputGetGradientx(&old_gradient,femmodel->elements,femmodel->nodes, femmodel->vertices,femmodel->loads, femmodel->materials,femmodel->parameters); 28 28 Orthx(&new_gradient,gradient,old_gradient); delete old_gradient; delete gradient; -
issm/trunk-jpl/src/c/analyses/hydrology_core.cpp
r15037 r15099 51 51 for(i=0;i<nsteps;i++){ 52 52 53 if(nsteps)if(VerboseSolution()) _pprint Line_("time step:" << i+1 << "/" << nsteps);53 if(nsteps)if(VerboseSolution()) _pprintString_("time step:" << i+1 << "/" << nsteps << "\n"); 54 54 time+=dt; 55 55 step+=1; … … 58 58 59 59 if (hydrology_model==HydrologyshreveEnum){ 60 if(VerboseSolution()) _pprint Line_(" computing water column");60 if(VerboseSolution()) _pprintString_(" computing water column" << "\n"); 61 61 femmodel->SetCurrentConfiguration(HydrologyShreveAnalysisEnum); 62 62 solutionsequence_nonlinear(femmodel,modify_loads); … … 67 67 68 68 if(save_results && ((i+1)%output_frequency==0 || (i+1)==nsteps)){ 69 if(VerboseSolution()) _pprint Line_(" saving results");69 if(VerboseSolution()) _pprintString_(" saving results " << "\n"); 70 70 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,WatercolumnEnum); 71 71 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,HydrologyWaterVxEnum); … … 73 73 74 74 /*unload results*/ 75 if(VerboseSolution()) _pprint Line_(" saving temporary results");75 if(VerboseSolution()) _pprintString_(" saving temporary results" << "\n"); 76 76 OutputResultsx(femmodel->elements, femmodel->nodes, femmodel->vertices, femmodel->loads, femmodel->materials, femmodel->parameters,femmodel->results); 77 77 } … … 82 82 femmodel->parameters->FindParam(&isefficientlayer,HydrologydcIsefficientlayerEnum); 83 83 84 if(VerboseSolution()) _pprint Line_(" computing water transfer");84 if(VerboseSolution()) _pprintString_(" computing water transfer" << "\n"); 85 85 86 if(VerboseSolution()) _pprint Line_(" computing water head");86 if(VerboseSolution()) _pprintString_(" computing water head" << "\n"); 87 87 solutionsequence_hydro_nonlinear(femmodel); 88 88 if(save_results && ((i+1)%output_frequency==0 || (i+1)==nsteps)){ 89 if(VerboseSolution()) _pprint Line_(" saving results");89 if(VerboseSolution()) _pprintString_(" saving results " << "\n"); 90 90 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,SedimentHeadEnum); 91 91 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,SedimentHeadResidualEnum); … … 94 94 } 95 95 /*unload results*/ 96 if(VerboseSolution()) _pprint Line_(" saving temporary results");96 if(VerboseSolution()) _pprintString_(" saving temporary results" << "\n"); 97 97 OutputResultsx(femmodel->elements, femmodel->nodes, femmodel->vertices, femmodel->loads, femmodel->materials, femmodel->parameters,femmodel->results); 98 98 } -
issm/trunk-jpl/src/c/analyses/prognostic_core.cpp
r15097 r15099 32 32 33 33 if(issmbgradients){ 34 if(VerboseSolution)_print Line_(" call smb gradients module\n");34 if(VerboseSolution)_printString_(" call smb gradients module\n" << "\n"); 35 35 SmbGradientsx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters); 36 36 } 37 37 if(ispdd){ 38 38 if(isdelta18o){ 39 if(VerboseSolution()) _pprint Line_(" call Delta18oParametrization module");39 if(VerboseSolution()) _pprintString_(" call Delta18oParametrization module" << "\n"); 40 40 Delta18oParameterizationx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters); 41 41 } 42 if(VerboseSolution()) _pprint Line_(" call positive degree day module");42 if(VerboseSolution()) _pprintString_(" call positive degree day module" << "\n"); 43 43 PositiveDegreeDayx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters); 44 44 } 45 if(VerboseSolution()) _pprint Line_(" call computational core");45 if(VerboseSolution()) _pprintString_(" call computational core" << "\n"); 46 46 solutionsequence_linear(femmodel); 47 47 48 48 if(save_results){ 49 if(VerboseSolution()) _pprint Line_(" saving results");49 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 50 50 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,ThicknessEnum); 51 51 femmodel->RequestedOutputsx(requested_outputs,numoutputs); -
issm/trunk-jpl/src/c/analyses/steadystate_core.cpp
r15079 r15099 48 48 for(;;){ 49 49 50 if(VerboseSolution()) _pprint Line_(" computing temperature and velocity for step: " << step);50 if(VerboseSolution()) _pprintString_(" computing temperature and velocity for step: " << step << "\n"); 51 51 #ifdef _HAVE_THERMAL_ 52 52 if(isenthalpy==0){ … … 63 63 #endif 64 64 65 if(VerboseSolution()) _pprint Line_(" computing new velocity");65 if(VerboseSolution()) _pprintString_(" computing new velocity" << "\n"); 66 66 diagnostic_core(femmodel); 67 67 GetSolutionFromInputsx(&ug,femmodel->elements, femmodel->nodes, femmodel->vertices,femmodel->loads, femmodel->materials, femmodel->parameters); 68 68 69 69 if(step>1){ 70 if(VerboseSolution()) _pprint Line_(" checking steadystate convergence");70 if(VerboseSolution()) _pprintString_(" checking steadystate convergence" << "\n"); 71 71 if(steadystateconvergence(tg,tg_old,ug,ug_old,reltol)) break; 72 72 } 73 73 if(step>maxiter){ 74 if(VerboseSolution()) _pprint Line_(" maximum number steadystate iterations " << maxiter << " reached");74 if(VerboseSolution()) _pprintString_(" maximum number steadystate iterations " << maxiter << " reached" << "\n"); 75 75 break; 76 76 } … … 83 83 84 84 if(save_results){ 85 if(VerboseSolution()) _pprint Line_(" saving results");85 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 86 86 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,VxEnum); 87 87 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,VyEnum); … … 117 117 if (xIsNan<IssmDouble>(ndu) || xIsNan<IssmDouble>(nu)) _error_("convergence criterion is NaN!"); 118 118 if((ndu/nu)<reltol){ 119 if(VerboseConvergence()) _pprint Line_("\n"<<setw(50)<<left<<" Velocity convergence: norm(du)/norm(u)"<<ndu/nu*100<<" < "<<reltol*100<<" %");119 if(VerboseConvergence()) _pprintString_("\n"<<setw(50)<<left<<" Velocity convergence: norm(du)/norm(u)"<<ndu/nu*100<<" < "<<reltol*100<<" %" << "\n"); 120 120 } 121 121 else{ 122 if(VerboseConvergence()) _pprint Line_("\n"<<setw(50)<<left<<" Velocity convergence: norm(du)/norm(u)"<<ndu/nu*100<<" > "<<reltol*100<<" %");122 if(VerboseConvergence()) _pprintString_("\n"<<setw(50)<<left<<" Velocity convergence: norm(du)/norm(u)"<<ndu/nu*100<<" > "<<reltol*100<<" %" << "\n"); 123 123 converged=false; 124 124 } … … 129 129 if (xIsNan<IssmDouble>(ndt) || xIsNan<IssmDouble>(nt)) _error_("convergence criterion is NaN!"); 130 130 if((ndt/nt)<reltol){ 131 if(VerboseConvergence()) _pprint Line_(setw(50)<<left<<" Temperature convergence: norm(dt)/norm(t)"<<ndt/nt*100<<" < "<<reltol*100<<" %");131 if(VerboseConvergence()) _pprintString_(setw(50)<<left<<" Temperature convergence: norm(dt)/norm(t)"<<ndt/nt*100<<" < "<<reltol*100<<" %" << "\n"); 132 132 } 133 133 else{ 134 if(VerboseConvergence()) _pprint Line_(setw(50)<<left<<" Temperature convergence: norm(dt)/norm(t)"<<ndt/nt*100<<" > "<<reltol*100<<" %");134 if(VerboseConvergence()) _pprintString_(setw(50)<<left<<" Temperature convergence: norm(dt)/norm(t)"<<ndt/nt*100<<" > "<<reltol*100<<" %" << "\n"); 135 135 converged=false; 136 136 } -
issm/trunk-jpl/src/c/analyses/surfaceslope_core.cpp
r15001 r15099 18 18 femmodel->parameters->FindParam(&save_results,SaveResultsEnum); 19 19 20 if(VerboseSolution()) _pprint Line_("computing slope...");20 if(VerboseSolution()) _pprintString_("computing slope..." << "\n"); 21 21 22 22 /*Call on core computations: */ … … 27 27 28 28 if(save_results){ 29 if(VerboseSolution()) _pprint Line_("saving results:");29 if(VerboseSolution()) _pprintString_("saving results:" << "\n"); 30 30 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,SurfaceSlopeXEnum); 31 31 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,SurfaceSlopeYEnum); -
issm/trunk-jpl/src/c/analyses/thermal_core.cpp
r15001 r15099 25 25 } 26 26 27 if(VerboseSolution()) _pprint Line_(" computing temperatures");27 if(VerboseSolution()) _pprintString_(" computing temperatures" << "\n"); 28 28 femmodel->SetCurrentConfiguration(ThermalAnalysisEnum); 29 29 solutionsequence_thermal_nonlinear(femmodel); 30 30 31 if(VerboseSolution()) _pprint Line_(" computing melting");31 if(VerboseSolution()) _pprintString_(" computing melting" << "\n"); 32 32 femmodel->SetCurrentConfiguration(MeltingAnalysisEnum); 33 33 solutionsequence_linear(femmodel); 34 34 35 35 if(save_results){ 36 if(VerboseSolution()) _pprint Line_(" saving results");36 if(VerboseSolution()) _pprintString_(" saving results" << "\n"); 37 37 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,TemperatureEnum); 38 38 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,BasalforcingsMeltingRateEnum); -
issm/trunk-jpl/src/c/analyses/transient_core.cpp
r15001 r15099 85 85 femmodel->parameters->SetParam(step,StepEnum); 86 86 87 if(VerboseSolution()) _pprint Line_("iteration " << step << "/" << floor((finaltime-time)/dt)+step << " time [yr]: " << time/yts << " (time step: " << dt/yts << ")");87 if(VerboseSolution()) _pprintString_("iteration " << step << "/" << floor((finaltime-time)/dt)+step << " time [yr]: " << time/yts << " (time step: " << dt/yts << ")" << "\n"); 88 88 if(step%output_frequency==0 || time==finaltime) 89 89 save_results=true; … … 93 93 94 94 if(isthermal && dim==3){ 95 if(VerboseSolution()) _pprint Line_(" computing temperatures");95 if(VerboseSolution()) _pprintString_(" computing temperatures" << "\n"); 96 96 #ifdef _HAVE_THERMAL_ 97 97 if(isenthalpy==0){ … … 107 107 108 108 if(isdiagnostic){ 109 if(VerboseSolution()) _pprint Line_(" computing new velocity");109 if(VerboseSolution()) _pprintString_(" computing new velocity" << "\n"); 110 110 #ifdef _HAVE_DIAGNOSTIC_ 111 111 diagnostic_core(femmodel); … … 116 116 117 117 if(isprognostic){ 118 if(VerboseSolution()) _pprint Line_(" computing new thickness");118 if(VerboseSolution()) _pprintString_(" computing new thickness" << "\n"); 119 119 prognostic_core(femmodel); 120 if(VerboseSolution()) _pprint Line_(" updating vertices positions");120 if(VerboseSolution()) _pprintString_(" updating vertices positions" << "\n"); 121 121 femmodel->UpdateVertexPositionsx(); 122 122 } 123 123 124 124 if(isgroundingline){ 125 if(VerboseSolution()) _pprint Line_(" computing new grounding line position");125 if(VerboseSolution()) _pprintString_(" computing new grounding line position" << "\n"); 126 126 #ifdef _HAVE_GROUNDINGLINE_ 127 127 GroundinglineMigrationx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters); … … 131 131 } 132 132 if(isgia){ 133 if(VerboseSolution()) _pprint Line_(" computing glacial isostatic adjustment");133 if(VerboseSolution()) _pprintString_(" computing glacial isostatic adjustment" << "\n"); 134 134 #ifdef _HAVE_GIA_ 135 135 gia_core(femmodel); … … 142 142 /*unload results*/ 143 143 if(save_results){ 144 if(VerboseSolution()) _pprint Line_(" saving transient results");144 if(VerboseSolution()) _pprintString_(" saving transient results" << "\n"); 145 145 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,SurfaceEnum); 146 146 InputToResultx(femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters,BedEnum); … … 158 158 } 159 159 160 if(VerboseSolution()) _pprint Line_(" saving temporary results");160 if(VerboseSolution()) _pprintString_(" saving temporary results" << "\n"); 161 161 OutputResultsx(femmodel->elements, femmodel->nodes, femmodel->vertices, femmodel->loads, femmodel->materials, femmodel->parameters,femmodel->results); 162 162 } -
issm/trunk-jpl/src/c/bamg/BamgVertex.cpp
r15066 r15099 15 15 void BamgVertex::Echo(void){ 16 16 17 _print Line_("Vertex:");18 _print Line_(" integer coordinates i.x: " << i.x << ", i.y: " << i.y);19 _print Line_(" Euclidean coordinates r.x: " << r.x << ", r.y: " << r.y);20 _print Line_(" ReferenceNumber = " << ReferenceNumber);17 _printString_("Vertex:" << "\n"); 18 _printString_(" integer coordinates i.x: " << i.x << ", i.y: " << i.y << "\n"); 19 _printString_(" Euclidean coordinates r.x: " << r.x << ", r.y: " << r.y << "\n"); 20 _printString_(" ReferenceNumber = " << ReferenceNumber << "\n"); 21 21 m.Echo(); 22 22 -
issm/trunk-jpl/src/c/bamg/Edge.cpp
r15067 r15099 27 27 /*FUNCTION Edge::Echo {{{*/ 28 28 void Edge::Echo(void){ 29 _print Line_("Edge:");30 _print Line_(" pointers towards two vertices: " << v[0] << " " << v[1]);31 _print Line_(" ReferenceNumber = " << ReferenceNumber);32 _print Line_(" GeomEdgeHook = " << GeomEdgeHook);33 _print Line_(" two adjacent edges on the same curve: " << adj[0] << " " << adj[1]);29 _printString_("Edge:" << "\n"); 30 _printString_(" pointers towards two vertices: " << v[0] << " " << v[1] << "\n"); 31 _printString_(" ReferenceNumber = " << ReferenceNumber << "\n"); 32 _printString_(" GeomEdgeHook = " << GeomEdgeHook << "\n"); 33 _printString_(" two adjacent edges on the same curve: " << adj[0] << " " << adj[1] << "\n"); 34 34 } 35 35 /*}}}*/ -
issm/trunk-jpl/src/c/bamg/EigenMetric.cpp
r15067 r15099 114 114 void EigenMetric::Echo(void){ 115 115 116 _print Line_("EigenMetric:");117 _print Line_(" lambda1: " << lambda1);118 _print Line_(" lambda2: " << lambda2);119 _print Line_(" v.x: " << v.x);120 _print Line_(" v.y: " << v.y);116 _printString_("EigenMetric:" << "\n"); 117 _printString_(" lambda1: " << lambda1 << "\n"); 118 _printString_(" lambda2: " << lambda2 << "\n"); 119 _printString_(" v.x: " << v.x << "\n"); 120 _printString_(" v.y: " << v.y << "\n"); 121 121 122 122 return; -
issm/trunk-jpl/src/c/bamg/Geometry.cpp
r15066 r15099 80 80 //Vertices 81 81 if (bamggeom->Vertices){ 82 if(verbose>5) _print Line_(" processing Vertices");82 if(verbose>5) _printString_(" processing Vertices" << "\n"); 83 83 if (bamggeom->VerticesSize[1]!=3) _error_("Vertices should have 3 columns"); 84 84 vertices = new GeomVertex[nbv]; … … 125 125 double* verticeslength=NULL; 126 126 127 if(verbose>5) _print Line_(" processing Edges");127 if(verbose>5) _printString_(" processing Edges" << "\n"); 128 128 if (bamggeom->EdgesSize[1]!=3) _error_("Edges should have 3 columns"); 129 129 edges = new GeomEdge[nbe]; … … 180 180 //hVertices 181 181 if(bamgopts->hVertices && bamgopts->hVerticesSize[0]==nbv){ 182 if(verbose>5) _print Line_(" processing hVertices");182 if(verbose>5) _printString_(" processing hVertices" << "\n"); 183 183 for (i=0;i< nbv;i++){ 184 184 if (!xIsNan<IssmPDouble>(bamgopts->hVertices[i])){ … … 190 190 //MetricVertices 191 191 if(bamgopts->metric && bamgopts->metric[0]==nbv){ 192 if(verbose>5) _print Line_(" processing MetricVertices");192 if(verbose>5) _printString_(" processing MetricVertices" << "\n"); 193 193 for (i=0;i< nbv;i++) { 194 194 vertices[i].m = Metric((double)bamgopts->metric[i*3+0],(double)bamgopts->metric[i*3+1],(double)bamgopts->metric[i*3+2]); … … 198 198 //MaxCornerAngle 199 199 if (bamgopts->MaxCornerAngle){ 200 if(verbose>5) _print Line_(" processing MaxCornerAngle");200 if(verbose>5) _printString_(" processing MaxCornerAngle" << "\n"); 201 201 MaxCornerAngle=bamgopts->MaxCornerAngle*Pi/180; 202 202 } … … 237 237 //RequiredVertices 238 238 if(bamggeom->RequiredVertices){ 239 if(verbose>5) _print Line_(" processing RequiredVertices");239 if(verbose>5) _printString_(" processing RequiredVertices" << "\n"); 240 240 if (bamggeom->RequiredVerticesSize[1]!=1) _error_("RequiredVertices should have 1 column"); 241 241 n=bamggeom->RequiredVerticesSize[0]; … … 249 249 //RequiredEdges 250 250 if(bamggeom->RequiredEdges){ 251 if(verbose>5) _print Line_(" processing RequiredEdges");251 if(verbose>5) _printString_(" processing RequiredEdges" << "\n"); 252 252 if (bamggeom->RequiredEdgesSize[1]!=1) _error_("RequiredEdges should have 1 column"); 253 253 n=bamggeom->RequiredEdgesSize[0]; … … 261 261 //SubDomain 262 262 if(bamggeom->SubDomains){ 263 if(verbose>5) _print Line_(" processing SubDomains");263 if(verbose>5) _printString_(" processing SubDomains" << "\n"); 264 264 if (bamggeom->SubDomainsSize[1]!=4) _error_("SubDomains should have 4 columns"); 265 265 nbsubdomains=bamggeom->SubDomainsSize[0]; … … 293 293 294 294 /*Vertices*/ 295 if(verbose>5) _print Line_(" writing Vertices");295 if(verbose>5) _printString_(" writing Vertices" << "\n"); 296 296 bamggeom->VerticesSize[0]=nbv; 297 297 bamggeom->VerticesSize[1]=3; … … 309 309 310 310 /*Edges*/ 311 if(verbose>5) _print Line_(" writing Edges");311 if(verbose>5) _printString_(" writing Edges" << "\n"); 312 312 bamggeom->EdgesSize[0]=nbe; 313 313 bamggeom->EdgesSize[1]=3; … … 327 327 328 328 /*RequiredEdges*/ 329 if(verbose>5) _print Line_(" writing " << nbreq << " RequiredEdges");329 if(verbose>5) _printString_(" writing " << nbreq << " RequiredEdges" << "\n"); 330 330 bamggeom->RequiredEdgesSize[0]=nbreq; 331 331 bamggeom->RequiredEdgesSize[1]=1; … … 344 344 345 345 /*RequiredVertices*/ 346 if(verbose>5) _print Line_(" writing " << nbreqv << " RequiredVertices");346 if(verbose>5) _printString_(" writing " << nbreqv << " RequiredVertices" << "\n"); 347 347 bamggeom->RequiredVerticesSize[0]=nbreqv; 348 348 bamggeom->RequiredVerticesSize[1]=1; … … 359 359 360 360 /*SubDomains*/ 361 if(verbose>5) _print Line_(" writing SubDomains");361 if(verbose>5) _printString_(" writing SubDomains" << "\n"); 362 362 bamggeom->SubDomainsSize[0]=nbsubdomains; 363 363 bamggeom->SubDomainsSize[1]=4; … … 373 373 374 374 /*TangentAtEdges*/ 375 if(verbose>5) _print Line_(" writing TangentAtEdges");375 if(verbose>5) _printString_(" writing TangentAtEdges" << "\n"); 376 376 bamggeom->TangentAtEdgesSize[0]=nbtan; 377 377 bamggeom->TangentAtEdgesSize[1]=4; … … 402 402 void Geometry::Echo(void){ 403 403 404 _print Line_("Geometry:");405 _print Line_(" nbv (number of vertices) : " << nbv);406 _print Line_(" nbe (number of edges) : " << nbe);407 _print Line_(" nbsubdomains: " << nbsubdomains);408 _print Line_(" nbcurves: " << nbcurves);409 _print Line_(" vertices: " << vertices);410 _print Line_(" edges: " << edges);411 _print Line_(" quadtree: " << quadtree);412 _print Line_(" subdomains: " << subdomains);413 _print Line_(" curves: " << curves);414 _print Line_(" pmin (x,y): (" << pmin.x << " " << pmin.y << ")");415 _print Line_(" pmax (x,y): (" << pmax.x << " " << pmax.y << ")");416 _print Line_(" coefIcoor: " << coefIcoor);417 _print Line_(" MaxCornerAngle: " << MaxCornerAngle);404 _printString_("Geometry:" << "\n"); 405 _printString_(" nbv (number of vertices) : " << nbv << "\n"); 406 _printString_(" nbe (number of edges) : " << nbe << "\n"); 407 _printString_(" nbsubdomains: " << nbsubdomains << "\n"); 408 _printString_(" nbcurves: " << nbcurves << "\n"); 409 _printString_(" vertices: " << vertices << "\n"); 410 _printString_(" edges: " << edges << "\n"); 411 _printString_(" quadtree: " << quadtree << "\n"); 412 _printString_(" subdomains: " << subdomains << "\n"); 413 _printString_(" curves: " << curves << "\n"); 414 _printString_(" pmin (x,y): (" << pmin.x << " " << pmin.y << ")" << "\n"); 415 _printString_(" pmax (x,y): (" << pmax.x << " " << pmax.y << ")" << "\n"); 416 _printString_(" coefIcoor: " << coefIcoor << "\n"); 417 _printString_(" MaxCornerAngle: " << MaxCornerAngle << "\n"); 418 418 419 419 return; … … 524 524 /*if there is a vertex found that is to close to vertices[i] -> error*/ 525 525 if( v && Norme1(v->r - vertices[i].r) < eps ){ 526 _print Line_("reference numbers: " << v->ReferenceNumber << " " << vertices[i].ReferenceNumber);527 _print Line_("Id: " << i+1);528 _print Line_("Coords: ["<<v->r.x<<" "<<v->r.y<<"] ["<<vertices[i].r.x<<" "<<vertices[i].r.y<<"]");526 _printString_("reference numbers: " << v->ReferenceNumber << " " << vertices[i].ReferenceNumber << "\n"); 527 _printString_("Id: " << i+1 << "\n"); 528 _printString_("Coords: ["<<v->r.x<<" "<<v->r.y<<"] ["<<vertices[i].r.x<<" "<<vertices[i].r.y<<"]" << "\n"); 529 529 530 530 delete [] next_p; … … 869 869 if (bge<=0) { 870 870 if(NbTry) { 871 _print Line_("Fatal Error: on the class Mesh before call Geometry::ProjectOnCurve");872 _print Line_("That bug might come from:");873 _print Line_(" 1) a mesh edge containing more than " << mxe/2 << " geometrical edges");874 _print Line_(" 2) code bug : be sure that we call Mesh::SetVertexFieldOn() before");875 _print Line_("To solve the problem do a coarsening of the geometrical mesh or change the constant value of mxe (dangerous)");871 _printString_("Fatal Error: on the class Mesh before call Geometry::ProjectOnCurve" << "\n"); 872 _printString_("That bug might come from:" << "\n"); 873 _printString_(" 1) a mesh edge containing more than " << mxe/2 << " geometrical edges" << "\n"); 874 _printString_(" 2) code bug : be sure that we call Mesh::SetVertexFieldOn() before" << "\n"); 875 _printString_("To solve the problem do a coarsening of the geometrical mesh or change the constant value of mxe (dangerous)" << "\n"); 876 876 _error_("see above"); 877 877 } … … 886 886 while (eg1 != (GeomEdge*) vg1 && (*eg1)(direction1) != (GeomVertex*) vg1) { 887 887 if(tge>=mxe ) { 888 _print Line_("WARNING: on the class Mesh before call Geometry::ProjectOnCurve is having issues (isn't it Eric?)");888 _printString_("WARNING: on the class Mesh before call Geometry::ProjectOnCurve is having issues (isn't it Eric?)" << "\n"); 889 889 NbTry++; 890 890 if (NbTry<2) goto retry; 891 _print Line_("Fatal Error: on the class Mesh before call Geometry::ProjectOnCurve");892 _print Line_("That bug might come from:");893 _print Line_(" 1) a mesh edge contening more than " << mxe/2 << " geometrical edges");894 _print Line_(" 2) code bug : be sure that we call Mesh::SetVertexFieldOn() before");895 _print Line_("To solve the problem do a coarsening of the geometrical mesh or change the constant value of mxe (dangerous)");891 _printString_("Fatal Error: on the class Mesh before call Geometry::ProjectOnCurve" << "\n"); 892 _printString_("That bug might come from:" << "\n"); 893 _printString_(" 1) a mesh edge contening more than " << mxe/2 << " geometrical edges" << "\n"); 894 _printString_(" 2) code bug : be sure that we call Mesh::SetVertexFieldOn() before" << "\n"); 895 _printString_("To solve the problem do a coarsening of the geometrical mesh or change the constant value of mxe (dangerous)" << "\n"); 896 896 _error_("see above"); 897 897 } -
issm/trunk-jpl/src/c/bamg/ListofIntersectionTriangles.cpp
r15066 r15099 169 169 //x.Echo(); 170 170 //y.Echo(); 171 //_print Line_("cx = " << cx << ", cy=" << cy);171 //_printString_("cx = " << cx << ", cy=" << cy << "\n"); 172 172 173 173 si += sint; … … 188 188 MaxNbSeg *= 2; 189 189 if (verbosity>3){ 190 _print Line_(" reshape lSegsI from " << mneo << " to " << MaxNbSeg);190 _printString_(" reshape lSegsI from " << mneo << " to " << MaxNbSeg << "\n"); 191 191 } 192 192 _assert_(lSegsI && NbSeg<MaxNbSeg); … … 213 213 for (int i=0;i<MaxSize;i++) nw[i] = lIntTria[i]; 214 214 long int verbosity=0; 215 if(verbosity>3) _print Line_(" ListofIntersectionTriangles ReShape Maxsize " << MaxSize << " -> " << MaxNbSeg);215 if(verbosity>3) _printString_(" ListofIntersectionTriangles ReShape Maxsize " << MaxSize << " -> " << MaxNbSeg << "\n"); 216 216 MaxSize = newsize; 217 217 delete [] lIntTria;// remove old -
issm/trunk-jpl/src/c/bamg/Mesh.cpp
r15066 r15099 31 31 if(bamggeom->Edges==NULL) { 32 32 /*Recreate geometry if needed*/ 33 _print Line_("WARNING: mesh present but no geometry found. Reconstructing...");33 _printString_("WARNING: mesh present but no geometry found. Reconstructing..." << "\n"); 34 34 BuildGeometryFromMesh(bamgopts); 35 35 Gh.PostRead(); … … 103 103 if (kk[i]>=0) kk[i]=k++; 104 104 } 105 _print Line_(" number of vertices " << k << ", remove = " << Tho.nbv - k);106 _print Line_(" number of triangles " << kt << ", remove = " << nbInT-kt);107 _print Line_(" number of New boundary edge " << nbNewBedge);105 _printString_(" number of vertices " << k << ", remove = " << Tho.nbv - k << "\n"); 106 _printString_(" number of triangles " << kt << ", remove = " << nbInT-kt << "\n"); 107 _printString_(" number of New boundary edge " << nbNewBedge << "\n"); 108 108 long imaxnbv =k; 109 109 Init(imaxnbv); … … 281 281 282 282 //Vertices 283 if (verbose) _print Line_("Reading vertices (" << nbv << ")");283 if (verbose) _printString_("Reading vertices (" << nbv << ")" << "\n"); 284 284 vertices=xNew<BamgVertex>(nbv); 285 285 orderedvertices=xNew<BamgVertex*>(nbv); … … 295 295 296 296 //Triangles 297 if (verbose) _print Line_("Reading triangles (" << nbt << ")");297 if (verbose) _printString_("Reading triangles (" << nbt << ")" << "\n"); 298 298 triangles =new Triangle[maxnbt]; //we cannot allocate only nbt triangles since 299 299 nodeflags=xNew<bool>(nbv); … … 311 311 312 312 /*Recreate geometry: */ 313 if (verbose) _print Line_("Building Geometry");313 if (verbose) _printString_("Building Geometry" << "\n"); 314 314 BuildGeometryFromMesh(); 315 if (verbose) _print Line_("Completing geometry");315 if (verbose) _printString_("Completing geometry" << "\n"); 316 316 Gh.PostRead(); 317 317 … … 320 320 for(i=0;i<nbv;i++){ 321 321 if(!nodeflags[i]){ 322 _print Line_("Vertex " << i+1 << " does not belong to any element");322 _printString_("Vertex " << i+1 << " does not belong to any element" << "\n"); 323 323 isorphan=true; 324 324 } … … 347 347 //Vertices 348 348 if(bamgmesh->Vertices){ 349 if(verbose>5) _print Line_(" processing Vertices");349 if(verbose>5) _printString_(" processing Vertices" << "\n"); 350 350 351 351 vertices=xNew<BamgVertex>(nbv); … … 368 368 //Triangles 369 369 if(bamgmesh->Triangles){ 370 if(verbose>5) _print Line_(" processing Triangles");370 if(verbose>5) _printString_(" processing Triangles" << "\n"); 371 371 triangles =new Triangle[maxnbt]; //we cannot allocate only nbt triangles since 372 372 //other triangles will be added for each edge … … 386 386 //Quadrilaterals 387 387 if(bamgmesh->Quadrilaterals){ 388 if(verbose>5) _print Line_(" processing Quadrilaterals");388 if(verbose>5) _printString_(" processing Quadrilaterals" << "\n"); 389 389 long i1,i2,i3,i4; 390 390 triangles =new Triangle[nbt]; … … 408 408 //VerticesOnGeomEdge 409 409 if(bamgmesh->VerticesOnGeomEdge){ 410 if(verbose>5) _print Line_(" processing VerticesOnGeomEdge");410 if(verbose>5) _printString_(" processing VerticesOnGeomEdge" << "\n"); 411 411 NbVerticesOnGeomEdge=bamgmesh->VerticesOnGeomEdgeSize[0]; 412 412 VerticesOnGeomEdge= new VertexOnGeom[NbVerticesOnGeomEdge] ; … … 423 423 //VerticesOnGeomVertex 424 424 if(bamgmesh->VerticesOnGeomVertexSize[0]){ 425 if(verbose>5) _print Line_(" processing VerticesOnGeomVertex");425 if(verbose>5) _printString_(" processing VerticesOnGeomVertex" << "\n"); 426 426 NbVerticesOnGeomVertex=bamgmesh->VerticesOnGeomVertexSize[0]; 427 427 VerticesOnGeomVertex = new VertexOnGeom[NbVerticesOnGeomVertex] ; … … 439 439 double* len=NULL; 440 440 441 if(verbose>5) _print Line_(" processing Edges");441 if(verbose>5) _printString_(" processing Edges" << "\n"); 442 442 nbe=bamgmesh->EdgesSize[0]; 443 443 edges= new Edge[nbe]; … … 499 499 //EdgeOnGeomEdge 500 500 if(bamgmesh->EdgesOnGeomEdge){ 501 if(verbose>5) _print Line_(" processing EdgesOnGeomEdge");501 if(verbose>5) _printString_(" processing EdgesOnGeomEdge" << "\n"); 502 502 int i1,i2,i,j; 503 503 i2=bamgmesh->EdgesOnGeomEdgeSize[0]; … … 516 516 if(bamgmesh->SubDomains){ 517 517 long i3,head,direction; 518 if(verbose>5) _print Line_(" processing SubDomains");518 if(verbose>5) _printString_(" processing SubDomains" << "\n"); 519 519 nbsubdomains=bamgmesh->SubDomainsSize[0]; 520 520 subdomains = new SubDomain [ nbsubdomains ]; … … 585 585 586 586 /*Vertices*/ 587 if(verbose>5) _print Line_(" writing Vertices");587 if(verbose>5) _printString_(" writing Vertices" << "\n"); 588 588 bamgmesh->VerticesSize[0]=nbv; 589 589 bamgmesh->VerticesSize[1]=3; … … 598 598 599 599 /*Edges*/ 600 if(verbose>5) _print Line_(" writing Edges");600 if(verbose>5) _printString_(" writing Edges" << "\n"); 601 601 bamgmesh->EdgesSize[0]=nbe; 602 602 bamgmesh->EdgesSize[1]=3; … … 615 615 616 616 /*Element edges*/ 617 if(verbose>5) _print Line_(" writing element edges");617 if(verbose>5) _printString_(" writing element edges" << "\n"); 618 618 SetOfEdges4* edge4=new SetOfEdges4(nbt*3,nbv); 619 619 double* elemedge=NULL; … … 671 671 672 672 /*IssmSegments*/ 673 if(verbose>5) _print Line_(" writing IssmSegments");673 if(verbose>5) _printString_(" writing IssmSegments" << "\n"); 674 674 bamgmesh->IssmSegmentsSize[0]=NumIssmSegments; 675 675 bamgmesh->IssmSegmentsSize[1]=4; … … 714 714 715 715 /*Triangles*/ 716 if(verbose>5) _print Line_(" writing Triangles");716 if(verbose>5) _printString_(" writing Triangles" << "\n"); 717 717 k=nbInT-nbq*2; 718 718 num=0; … … 735 735 736 736 /*Quadrilaterals*/ 737 if(verbose>5) _print Line_(" writing Quadrilaterals");737 if(verbose>5) _printString_(" writing Quadrilaterals" << "\n"); 738 738 bamgmesh->QuadrilateralsSize[0]=nbq; 739 739 bamgmesh->QuadrilateralsSize[1]=5; … … 756 756 757 757 /*SubDomains*/ 758 if(verbose>5) _print Line_(" writing SubDomains");758 if(verbose>5) _printString_(" writing SubDomains" << "\n"); 759 759 bamgmesh->SubDomainsSize[0]=nbsubdomains; 760 760 bamgmesh->SubDomainsSize[1]=4; … … 770 770 771 771 /*SubDomainsFromGeom*/ 772 if(verbose>5) _print Line_(" writing SubDomainsFromGeom");772 if(verbose>5) _printString_(" writing SubDomainsFromGeom" << "\n"); 773 773 bamgmesh->SubDomainsFromGeomSize[0]=Gh.nbsubdomains; 774 774 bamgmesh->SubDomainsFromGeomSize[1]=4; … … 784 784 785 785 /*VerticesOnGeomVertex*/ 786 if(verbose>5) _print Line_(" writing VerticesOnGeomVertex");786 if(verbose>5) _printString_(" writing VerticesOnGeomVertex" << "\n"); 787 787 bamgmesh->VerticesOnGeomVertexSize[0]=NbVerticesOnGeomVertex; 788 788 bamgmesh->VerticesOnGeomVertexSize[1]=2; … … 798 798 799 799 /*VertexOnGeomEdge*/ 800 if(verbose>5) _print Line_(" writing VerticesOnGeomEdge");800 if(verbose>5) _printString_(" writing VerticesOnGeomEdge" << "\n"); 801 801 bamgmesh->VerticesOnGeomEdgeSize[0]=NbVerticesOnGeomEdge; 802 802 bamgmesh->VerticesOnGeomEdgeSize[1]=3; … … 815 815 816 816 /*EdgesOnGeomEdge*/ 817 if(verbose>5) _print Line_(" writing EdgesOnGeomEdge");817 if(verbose>5) _printString_(" writing EdgesOnGeomEdge" << "\n"); 818 818 k=0; 819 819 for (i=0;i<nbe;i++){ … … 835 835 836 836 /*Element Connectivity*/ 837 if(verbose>5) _print Line_(" writing Element connectivity");837 if(verbose>5) _printString_(" writing Element connectivity" << "\n"); 838 838 bamgmesh->ElementConnectivitySize[0]=nbt-nbtout; 839 839 bamgmesh->ElementConnectivitySize[1]=3; … … 855 855 856 856 /*ElementNodal Connectivity*/ 857 if(verbose>5) _print Line_(" writing Nodal element connectivity");857 if(verbose>5) _printString_(" writing Nodal element connectivity" << "\n"); 858 858 bamgmesh->NodalElementConnectivitySize[0]=nbv; 859 859 bamgmesh->NodalElementConnectivitySize[1]=connectivitymax_1; … … 870 870 871 871 /*Nodal Connectivity*/ 872 if(verbose>5) _print Line_(" writing Nodal connectivity");872 if(verbose>5) _printString_(" writing Nodal connectivity" << "\n"); 873 873 //chaining algorithm (again...) 874 874 int* head_2=NULL; … … 924 924 925 925 /*Cracked vertices*/ 926 if(verbose>5) _print Line_(" writing Cracked vertices");926 if(verbose>5) _printString_(" writing Cracked vertices" << "\n"); 927 927 bamgmesh->CrackedVerticesSize[0]=NbCrackedVertices; 928 928 bamgmesh->CrackedVerticesSize[1]=2; … … 936 936 937 937 /*Cracked vertices*/ 938 if(verbose>5) _print Line_(" writing Cracked vertices");938 if(verbose>5) _printString_(" writing Cracked vertices" << "\n"); 939 939 bamgmesh->CrackedEdgesSize[0]=NbCrackedEdges; 940 940 bamgmesh->CrackedEdgesSize[1]=4; … … 964 964 int i,j; 965 965 966 if(bamgopts->verbose>3) _print Line_(" processing metric");966 if(bamgopts->verbose>3) _printString_(" processing metric" << "\n"); 967 967 double hmin = Max(bamgopts->hmin,MinimalHmin()); 968 968 double hmax = Min(bamgopts->hmax,MaximalHmax()); … … 1265 1265 1266 1266 //display info 1267 if (verbose > 1) _print Line_(" BoundAnisotropy by " << anisomax);1267 if (verbose > 1) _printString_(" BoundAnisotropy by " << anisomax << "\n"); 1268 1268 1269 1269 double h1=1.e30,h2=1e-30; … … 1292 1292 //display info 1293 1293 if (verbose>2){ 1294 _print Line_(" input: Hmin = " << pow(h2,-0.5) << ", Hmax = " << pow(h1,-0.5) << ", factor of anisotropy max = " << pow(rx,0.5));1295 _print Line_(" output: Hmin = " << pow(hn2,-0.5) << ", Hmax = " << pow(hn1,-0.5)<< ", factor of anisotropy max = " <<pow(rnx,0.5));1294 _printString_(" input: Hmin = " << pow(h2,-0.5) << ", Hmax = " << pow(h1,-0.5) << ", factor of anisotropy max = " << pow(rx,0.5) << "\n"); 1295 _printString_(" output: Hmin = " << pow(hn2,-0.5) << ", Hmax = " << pow(hn1,-0.5)<< ", factor of anisotropy max = " <<pow(rnx,0.5) << "\n"); 1296 1296 } 1297 1297 } … … 1315 1315 1316 1316 //display info 1317 if (verbose>1) _print Line_(" construction of the geometry from the 2d mesh");1317 if (verbose>1) _printString_(" construction of the geometry from the 2d mesh" << "\n"); 1318 1318 1319 1319 //check that the mesh is not empty … … 1375 1375 //else (see 3 lines above), the edge has been called more than twice: return error 1376 1376 else { 1377 _print Line_("The edge (" << GetId(triangles[i][VerticesOfTriangularEdge[j][0]]) << "," << GetId(triangles[i][VerticesOfTriangularEdge[j][1]]) << ") belongs to more than 2 triangles (" << k << ")");1378 _print Line_("Edge " << j << " of triangle " << i);1379 _print Line_("Edge " << (-st[k]+2)%3 << " of triangle " << (-st[k]+2)/3);1380 _print Line_("Edge " << triangles[(-st[k]+2)/3].NuEdgeTriangleAdj((int)((-st[k]+2)%3)) << " of triangle " << GetId(triangles[(-st[k]+2)/3].TriangleAdj((int)((-st[k]+2)%3))));1377 _printString_("The edge (" << GetId(triangles[i][VerticesOfTriangularEdge[j][0]]) << "," << GetId(triangles[i][VerticesOfTriangularEdge[j][1]]) << ") belongs to more than 2 triangles (" << k << ")" << "\n"); 1378 _printString_("Edge " << j << " of triangle " << i << "\n"); 1379 _printString_("Edge " << (-st[k]+2)%3 << " of triangle " << (-st[k]+2)/3 << "\n"); 1380 _printString_("Edge " << triangles[(-st[k]+2)/3].NuEdgeTriangleAdj((int)((-st[k]+2)%3)) << " of triangle " << GetId(triangles[(-st[k]+2)/3].TriangleAdj((int)((-st[k]+2)%3))) << "\n"); 1381 1381 _error_("An edge belongs to more than 2 triangles"); 1382 1382 } … … 1390 1390 //display info 1391 1391 if(verbose>5) { 1392 _print Line_(" info on Mesh:");1393 _print Line_(" - number of vertices = " << nbv);1394 _print Line_(" - number of triangles = " << nbt);1395 _print Line_(" - number of given edges = " << nbe);1396 _print Line_(" - number of all edges = " << nbedges);1397 _print Line_(" - Euler number 1 - nb of holes = " << nbt-nbedges+nbv);1392 _printString_(" info on Mesh:" << "\n"); 1393 _printString_(" - number of vertices = " << nbv << "\n"); 1394 _printString_(" - number of triangles = " << nbt << "\n"); 1395 _printString_(" - number of given edges = " << nbe << "\n"); 1396 _printString_(" - number of all edges = " << nbedges << "\n"); 1397 _printString_(" - Euler number 1 - nb of holes = " << nbt-nbedges+nbv << "\n"); 1398 1398 } 1399 1399 … … 1426 1426 1427 1427 //display info 1428 if(verbose>4) _print Line_(" Construction of the edges " << nbe);1428 if(verbose>4) _printString_(" Construction of the edges " << nbe << "\n"); 1429 1429 1430 1430 for (i=0;i<nbedges;i++){ … … 1452 1452 edges[add].ReferenceNumber=edgessave[i].ReferenceNumber; 1453 1453 edges[add].GeomEdgeHook=edgessave[i].GeomEdgeHook; // HACK to get required edges 1454 _print Line_("oh no...");1454 _printString_("oh no..." << "\n"); 1455 1455 } 1456 1456 else … … 1567 1567 } 1568 1568 } 1569 if (verbose> 3) _print Line_(" The Number of sub domain = " << nbsubdomains);1569 if (verbose> 3) _printString_(" The Number of sub domain = " << nbsubdomains << "\n"); 1570 1570 1571 1571 //build subdomains … … 1619 1619 Gh.nbsubdomains = nbsubdomains; 1620 1620 Gh.subdomains = new GeomSubDomain[nbsubdomains]; 1621 if (verbose>3) _print Line_(" number of vertices = " << Gh.nbv << "\n number of edges = " << Gh.nbe);1621 if (verbose>3) _printString_(" number of vertices = " << Gh.nbv << "\n number of edges = " << Gh.nbe << "\n"); 1622 1622 NbVerticesOnGeomVertex = Gh.nbv; 1623 1623 VerticesOnGeomVertex = new VertexOnGeom[NbVerticesOnGeomVertex]; … … 1791 1791 //display infos 1792 1792 if(verbose>1) { 1793 _print Line_(" Construction of Metric: number of field: " << nbsol << " (nbt=" << nbt << ", nbv=" << nbv << ")");1793 _printString_(" Construction of Metric: number of field: " << nbsol << " (nbt=" << nbt << ", nbv=" << nbv << ")" << "\n"); 1794 1794 } 1795 1795 … … 1863 1863 1864 1864 //display info 1865 if(verbose>2) _print Line_(" Solution " << nusol << ", Min = " << smin << ", Max = " << smax << ", Delta = " << sdelta);1865 if(verbose>2) _printString_(" Solution " << nusol << ", Min = " << smin << ", Max = " << smax << ", Delta = " << sdelta << "\n"); 1866 1866 1867 1867 //skip constant field 1868 1868 if (sdelta < 1.0e-10*Max(absmax,1e-20)){ 1869 _print Line_(" Solution " << nusol << " is constant, skipping...");1869 _printString_(" Solution " << nusol << " is constant, skipping..." << "\n"); 1870 1870 continue; 1871 1871 } … … 1993 1993 //display infos 1994 1994 if(verbose>1) { 1995 _print Line_(" Construction of Metric: number of field: " << nbsol << " (nbt=" << nbt << ", nbv=" << nbv << ")");1995 _printString_(" Construction of Metric: number of field: " << nbsol << " (nbt=" << nbt << ", nbv=" << nbv << ")" << "\n"); 1996 1996 } 1997 1997 … … 2076 2076 2077 2077 //display info 2078 if(verbose>2) _print Line_(" Solution " << nusol << ", Min = " << smin << ", Max = " << smax << ", Delta = " << sdelta << ", number of fields = " << nbsol);2078 if(verbose>2) _printString_(" Solution " << nusol << ", Min = " << smin << ", Max = " << smax << ", Delta = " << sdelta << ", number of fields = " << nbsol << "\n"); 2079 2079 2080 2080 //skip constant field 2081 2081 if (sdelta < 1.0e-10*Max(absmax,1e-20) ){ 2082 if (verbose>2) _print Line_(" Solution " << nusol << " is constant, skipping...");2082 if (verbose>2) _printString_(" Solution " << nusol << " is constant, skipping..." << "\n"); 2083 2083 continue; 2084 2084 } … … 2265 2265 //Return if no edge is cracked 2266 2266 if(k==0) return; 2267 if (verbose>4) _print Line_(" number of Cracked Edges = " << k);2267 if (verbose>4) _printString_(" number of Cracked Edges = " << k << "\n"); 2268 2268 2269 2269 //Initialize Cracked edge … … 2306 2306 2307 2307 //Add new vertices 2308 if (verbose>4) _print Line_(" number of Cracked Vertices = " << NbCrackedVertices);2308 if (verbose>4) _printString_(" number of Cracked Vertices = " << NbCrackedVertices << "\n"); 2309 2309 if (NbCrackedVertices){ 2310 2310 CrackedVertices=xNew<long>(2*NbCrackedVertices); … … 2375 2375 } 2376 2376 } 2377 //_print Line_(element_renu[GetId(ta.t)] << " -> " << GetId((*ta.t)[0])+1 << " " << GetId((*ta.t)[1])+1 << " " << GetId((*ta.t)[2])+1 << ", edge [" << i1 << "->" << j1 << " " << i2 << "->" << j2 << "]");2377 //_printString_(element_renu[GetId(ta.t)] << " -> " << GetId((*ta.t)[0])+1 << " " << GetId((*ta.t)[1])+1 << " " << GetId((*ta.t)[2])+1 << ", edge [" << i1 << "->" << j1 << " " << i2 << "->" << j2 << "]" << "\n"); 2378 2378 ta = Next(ta).Adj(); 2379 2379 if (count++>50) _error_("Maximum number of iteration exceeded"); … … 2399 2399 int i; 2400 2400 2401 _print Line_("Mesh Echo:");2402 _print Line_(" nbv = " << nbv);2403 _print Line_(" nbt = " << nbt);2404 _print Line_(" nbe = " << nbe);2405 _print Line_(" nbq = " << nbq);2406 _print Line_(" index:");2401 _printString_("Mesh Echo:" << "\n"); 2402 _printString_(" nbv = " << nbv << "\n"); 2403 _printString_(" nbt = " << nbt << "\n"); 2404 _printString_(" nbe = " << nbe << "\n"); 2405 _printString_(" nbq = " << nbq << "\n"); 2406 _printString_(" index:" << "\n"); 2407 2407 for (i=0;i<nbt;i++){ 2408 _print Line_(" " << setw(4) << i+1 << ": ["2408 _printString_(" " << setw(4) << i+1 << ": [" 2409 2409 << setw(4) << (((BamgVertex *)triangles[i](0))?GetId(triangles[i][0])+1:0) << " " 2410 2410 << setw(4) << (((BamgVertex *)triangles[i](0))?GetId(triangles[i][1])+1:0) << " " 2411 2411 << setw(4) << (((BamgVertex *)triangles[i](0))?GetId(triangles[i][2])+1:0) << "]"); 2412 2412 } 2413 _print Line_(" coordinates:");2413 _printString_(" coordinates:" << "\n"); 2414 2414 for (i=0;i<nbv;i++){ 2415 _print Line_(" " << setw(4) << i+1 << ": [" << vertices[i].r.x << " " << vertices[i].r.y << "]");2415 _printString_(" " << setw(4) << i+1 << ": [" << vertices[i].r.x << " " << vertices[i].r.y << "]" << "\n"); 2416 2416 } 2417 2417 … … 2427 2427 2428 2428 //display 2429 if (verbose > 2) _print Line_(" ForceBoundary nb of edge: " << nbe);2429 if (verbose > 2) _printString_(" ForceBoundary nb of edge: " << nbe << "\n"); 2430 2430 2431 2431 //check that there is no triangle with 0 determinant … … 2458 2458 Nbswap += vertices[j].Optim(1,0); 2459 2459 } 2460 if (verbose > 3) _print Line_(" number of inforced edge = " << nbfe << ", number of swap= " << Nbswap);2460 if (verbose > 3) _printString_(" number of inforced edge = " << nbfe << ", number of swap= " << Nbswap << "\n"); 2461 2461 } 2462 2462 /*}}}*/ … … 2468 2468 2469 2469 if (verbose >2){ 2470 if (OutSide) _print Line_(" Find all external sub-domain");2471 else _print Line_(" Find all internal sub-domain");2470 if (OutSide) _printString_(" Find all external sub-domain" << "\n"); 2471 else _printString_(" Find all internal sub-domain" << "\n"); 2472 2472 } 2473 2473 short * HeapArete = new short[nbt]; … … 2613 2613 }//while (t) 2614 2614 } 2615 if(verbose>4) _print Line_(" Number of removes subdomains (OutSideMesh) = " << nbsubdomains-j);2615 if(verbose>4) _printString_(" Number of removes subdomains (OutSideMesh) = " << nbsubdomains-j << "\n"); 2616 2616 nbsubdomains=j; 2617 2617 } … … 2692 2692 2693 2693 if (inew < nbsubdomains) { 2694 if (verbose>5) _print Line_("WARNING: " << nbsubdomains-inew << " SubDomains are being removed");2694 if (verbose>5) _printString_("WARNING: " << nbsubdomains-inew << " SubDomains are being removed" << "\n"); 2695 2695 nbsubdomains=inew;} 2696 2696 … … 2799 2799 2800 2800 //Display info 2801 if (verbose>2) _print Line_(" Insert initial " << nbv << " vertices");2801 if (verbose>2) _printString_(" Insert initial " << nbv << " vertices" << "\n"); 2802 2802 2803 2803 //Compute integer coordinates for the existing vertices … … 2890 2890 /*Now, add the vertices One by One*/ 2891 2891 long NbSwap=0; 2892 if (verbose>3) _print Line_(" Begining of insertion process...");2892 if (verbose>3) _printString_(" Begining of insertion process..." << "\n"); 2893 2893 2894 2894 for (int icount=2; icount<nbv; icount++) { … … 2913 2913 //Display info 2914 2914 if (verbose>3) { 2915 _print Line_(" NbSwap of insertion: " << NbSwap);2916 _print Line_(" NbSwap/nbv: " << NbSwap/nbv);2915 _printString_(" NbSwap of insertion: " << NbSwap << "\n"); 2916 _printString_(" NbSwap/nbv: " << NbSwap/nbv << "\n"); 2917 2917 } 2918 2918 … … 2928 2928 NbSwap += orderedvertices[is1]->Optim(0,0); 2929 2929 if (verbose>3) { 2930 _print Line_(" Optim Loop: " << Nbloop);2931 _print Line_(" NbSwap/nbv: " << NbSwap/nbv);2930 _printString_(" Optim Loop: " << Nbloop << "\n"); 2931 _printString_(" NbSwap/nbv: " << NbSwap/nbv << "\n"); 2932 2932 } 2933 2933 if(!NbSwap) break; … … 2952 2952 2953 2953 //display info if required 2954 if (verbose>5) _print Line_(" Try to Insert " << nbvnew << " new points");2954 if (verbose>5) _printString_(" Try to Insert " << nbvnew << " new points" << "\n"); 2955 2955 2956 2956 //return if no new points … … 3002 3002 } 3003 3003 if (verbose>3) { 3004 _print Line_(" number of new points: " << iv);3005 _print Line_(" number of to close (?) points: " << nbv-iv);3006 _print Line_(" number of swap after: " << NbSwap);3004 _printString_(" number of new points: " << iv << "\n"); 3005 _printString_(" number of to close (?) points: " << nbv-iv << "\n"); 3006 _printString_(" number of swap after: " << NbSwap << "\n"); 3007 3007 } 3008 3008 nbv = iv; 3009 3009 3010 3010 for (i=nbvold;i<nbv;i++) NbSwap += vertices[i].Optim(1); 3011 if (verbose>3) _print Line_(" NbSwap=" << NbSwap);3011 if (verbose>3) _printString_(" NbSwap=" << NbSwap << "\n"); 3012 3012 3013 3013 NbTSwap += NbSwap ; … … 3055 3055 if (!e[i]){ 3056 3056 kk++; 3057 if(kk<10) _print Line_("BUG: the geometrical edge " << i << " is on no edge curve");3057 if(kk<10) _printString_("BUG: the geometrical edge " << i << " is on no edge curve" << "\n"); 3058 3058 } 3059 3059 } … … 3069 3069 long int verbose=0; 3070 3070 3071 if (verbose>2) _print Line_("MakeQuadrangles costheta = " << costheta);3071 if (verbose>2) _printString_("MakeQuadrangles costheta = " << costheta << "\n"); 3072 3072 3073 3073 if (costheta >1) { 3074 if (verbose>5) _print Line_(" do nothing: costheta > 1");3074 if (verbose>5) _printString_(" do nothing: costheta > 1" << "\n"); 3075 3075 } 3076 3076 … … 3098 3098 nbq = kk; 3099 3099 if (verbose>2){ 3100 _print Line_(" number of quadrilaterals = " << nbq);3101 _print Line_(" number of triangles = " << nbt-nbtout- nbq*2);3102 _print Line_(" number of outside triangles = " << nbtout);3100 _printString_(" number of quadrilaterals = " << nbq << "\n"); 3101 _printString_(" number of triangles = " << nbt-nbtout- nbq*2 << "\n"); 3102 _printString_(" number of outside triangles = " << nbtout << "\n"); 3103 3103 } 3104 3104 delete [] qq; … … 3126 3126 3127 3127 const double maxsubdiv2 = maxsubdiv*maxsubdiv; 3128 if(verbose>1) _print Line_(" Limit the subdivision of a edges in the new mesh by " << maxsubdiv);3128 if(verbose>1) _printString_(" Limit the subdivision of a edges in the new mesh by " << maxsubdiv << "\n"); 3129 3129 // for all the edges 3130 3130 // if the len of the edge is to long … … 3169 3169 } 3170 3170 if(verbose>3){ 3171 _print Line_(" number of metric changes = " << nbchange << ", maximum number of subdivision of a edges before change = " << pow(lmax,0.5));3171 _printString_(" number of metric changes = " << nbchange << ", maximum number of subdivision of a edges before change = " << pow(lmax,0.5) << "\n"); 3172 3172 } 3173 3173 } … … 3223 3223 /*First, insert old points if requested*/ 3224 3224 if (KeepVertices && (&Bh != this) && (nbv+Bh.nbv< maxnbv)){ 3225 if (verbose>5) _print Line_(" Inserting initial mesh points");3225 if (verbose>5) _printString_(" Inserting initial mesh points" << "\n"); 3226 3226 for (i=0;i<Bh.nbv;i++){ 3227 3227 BamgVertex &bv=Bh[i]; … … 3242 3242 // Big loop (most time consuming) 3243 3243 int iter=0; 3244 if (verbose>5) _print Line_(" Big loop");3244 if (verbose>5) _printString_(" Big loop" << "\n"); 3245 3245 do { 3246 3246 /*Update variables*/ … … 3473 3473 // find extrema coordinates of vertices pmin,pmax 3474 3474 long i; 3475 if(verbose>2) _print Line_(" Reconstruct mesh of " << nbv << " vertices");3475 if(verbose>2) _printString_(" Reconstruct mesh of " << nbv << " vertices" << "\n"); 3476 3476 3477 3477 //initialize orderedvertices … … 3530 3530 //Display info if required 3531 3531 if(verbose>5) { 3532 _print Line_(" info of Mesh:");3533 _print Line_(" - number of vertices = " << nbv << "");3534 _print Line_(" - number of triangles = " << nbt << "");3535 _print Line_(" - number of given edges = " << nbe << "");3536 _print Line_(" - number of all edges = " << edge4->nb());3537 _print Line_(" - Euler number 1 - nb of holes = " << nbt-edge4->nb()+nbv);3532 _printString_(" info of Mesh:" << "\n"); 3533 _printString_(" - number of vertices = " << nbv << " " << "\n"); 3534 _printString_(" - number of triangles = " << nbt << " " << "\n"); 3535 _printString_(" - number of given edges = " << nbe << " " << "\n"); 3536 _printString_(" - number of all edges = " << edge4->nb() << "\n"); 3537 _printString_(" - Euler number 1 - nb of holes = " << nbt-edge4->nb()+nbv << "\n"); 3538 3538 } 3539 3539 … … 3552 3552 if (k<10) { 3553 3553 //print only 10 edges 3554 _print Line_("Lost boundary edges " << i << " : " << edge4->i(i) << " " << edge4->j(i));3554 _printString_("Lost boundary edges " << i << " : " << edge4->i(i) << " " << edge4->j(i) << "\n"); 3555 3555 } 3556 3556 else if (k==10){ 3557 _print Line_("Other lost boundary edges not shown...");3557 _printString_("Other lost boundary edges not shown..." << "\n"); 3558 3558 } 3559 3559 } … … 3743 3743 /*Check that the 2 vertices are on geometry AND required*/ 3744 3744 if(!edges[i][j].GeomEdgeHook->IsRequiredVertex()){ 3745 _print Line_("ReconstructExistingMesh error message: problem with the edge number " << i+1 << ": [" << GetId(edges[i][0])+1 << " " << GetId(edges[i][1])+1 << "]");3746 _print Line_("This edge is on geometrical edge number " << Gh.GetId(edges[i].GeomEdgeHook)+1);3745 _printString_("ReconstructExistingMesh error message: problem with the edge number " << i+1 << ": [" << GetId(edges[i][0])+1 << " " << GetId(edges[i][1])+1 << "]" << "\n"); 3746 _printString_("This edge is on geometrical edge number " << Gh.GetId(edges[i].GeomEdgeHook)+1 << "\n"); 3747 3747 if (edges[i][j].GeomEdgeHook->OnGeomVertex()) 3748 _print Line_("the vertex number " << GetId(edges[i][j])+1 << " of this edge is a geometric BamgVertex number " << Gh.GetId(edges[i][j].GeomEdgeHook->gv)+1);3748 _printString_("the vertex number " << GetId(edges[i][j])+1 << " of this edge is a geometric BamgVertex number " << Gh.GetId(edges[i][j].GeomEdgeHook->gv)+1 << "\n"); 3749 3749 else if (edges[i][j].GeomEdgeHook->OnGeomEdge()) 3750 _print Line_("the vertex number " << GetId(edges[i][j])+1 << " of this edge is a geometric Edge number " << Gh.GetId(edges[i][j].GeomEdgeHook->ge)+1);3750 _printString_("the vertex number " << GetId(edges[i][j])+1 << " of this edge is a geometric Edge number " << Gh.GetId(edges[i][j].GeomEdgeHook->ge)+1 << "\n"); 3751 3751 else 3752 _print Line_("Its pointer is " << edges[i][j].GeomEdgeHook);3753 3754 _print Line_("This edge is on geometry and has no adjacent edge (open curve) and one of the tip is not required");3752 _printString_("Its pointer is " << edges[i][j].GeomEdgeHook << "\n"); 3753 3754 _printString_("This edge is on geometry and has no adjacent edge (open curve) and one of the tip is not required" << "\n"); 3755 3755 _error_("See above (might be cryptic...)"); 3756 3756 } … … 3840 3840 long it,ie,i; 3841 3841 3842 _print Line_("renumbering triangles");3842 _printString_("renumbering triangles" << "\n"); 3843 3843 for ( it=0;it<nbt;it++) 3844 3844 triangles[it].Renumbering(vertices,ve,renu); 3845 3845 3846 _print Line_("renumbering edges");3846 _printString_("renumbering edges" << "\n"); 3847 3847 for ( ie=0;ie<nbe;ie++) 3848 3848 edges[ie].Renumbering(vertices,ve,renu); 3849 3849 3850 _print Line_("renumbering vertices on geom");3850 _printString_("renumbering vertices on geom" << "\n"); 3851 3851 for (i=0;i< NbVerticesOnGeomVertex;i++) 3852 3852 { … … 3856 3856 } 3857 3857 3858 _print Line_("renumbering vertices on edge");3858 _printString_("renumbering vertices on edge" << "\n"); 3859 3859 for (i=0;i< NbVerticesOnGeomEdge;i++) 3860 3860 { … … 3864 3864 } 3865 3865 3866 _print Line_("renumbering vertices on Bth vertex");3866 _printString_("renumbering vertices on Bth vertex" << "\n"); 3867 3867 for (i=0;i< NbVertexOnBThVertex;i++) 3868 3868 { … … 3954 3954 number_of_errors++; 3955 3955 if (number_of_errors<20){ 3956 _print Line_("Area of Triangle " << i+1 << " < 0 (det=" << triangles[i].det << ")");3956 _printString_("Area of Triangle " << i+1 << " < 0 (det=" << triangles[i].det << ")" << "\n"); 3957 3957 } 3958 3958 } … … 4022 4022 gammamn=sqrt(gammamn); 4023 4023 gammamx=sqrt(gammamx); 4024 _print Line_(" Adaptmesh info:");4025 _print Line_(" number of triangles = " << nt);4026 _print Line_(" hmin = " << hmin << ", hmax=" << hmax);4027 _print Line_(" area = " << area << ", M area = " << Marea << ", M area/( |Khat| nt) = " << Marea/(aireKh*nt));4028 _print Line_(" infinite-regularity(?): min = " << gammamn << ", max = " << gammamx);4029 _print Line_(" anisomax = " << pow(alpha2,0.5) << ", beta max = " << 1./pow(beta/aireKh,0.5) << ", min = " << 1./pow(beta0/aireKh,0.5));4024 _printString_(" Adaptmesh info:" << "\n"); 4025 _printString_(" number of triangles = " << nt << "\n"); 4026 _printString_(" hmin = " << hmin << ", hmax=" << hmax << "\n"); 4027 _printString_(" area = " << area << ", M area = " << Marea << ", M area/( |Khat| nt) = " << Marea/(aireKh*nt) << "\n"); 4028 _printString_(" infinite-regularity(?): min = " << gammamn << ", max = " << gammamx << "\n"); 4029 _printString_(" anisomax = " << pow(alpha2,0.5) << ", beta max = " << 1./pow(beta/aireKh,0.5) << ", min = " << 1./pow(beta0/aireKh,0.5) << "\n"); 4030 4030 } 4031 4031 /*}}}*/ … … 4061 4061 } 4062 4062 } 4063 _print Line_(" --- Histogram of the unit mesh, nb of edges = " << nbedges);4064 _print Line_(" length of edge in | %% of edge | Nb of edges");4065 _print Line_(" --------------------+-------------+-------------");4063 _printString_(" --- Histogram of the unit mesh, nb of edges = " << nbedges << "\n"); 4064 _printString_(" length of edge in | %% of edge | Nb of edges " << "\n"); 4065 _printString_(" --------------------+-------------+-------------" << "\n"); 4066 4066 for (i=0;i<=kmax;i++){ 4067 4067 if (i==0) _printString_( " " << setw(10) << 0.); … … 4069 4069 if (i==kmax) _printString_(" +inf "); 4070 4070 else _printString_( " " << setw(10) << exp(lmin+(i+1)/delta)); 4071 _print Line_("| " << setw(10) << (long((10000. * histo[i])/ nbedges)/100.) << " |");4072 _print Line_(" " << histo[i]);4073 } 4074 _print Line_(" --------------------+-------------+-------------");4071 _printString_("| " << setw(10) << (long((10000. * histo[i])/ nbedges)/100.) << " |" << "\n"); 4072 _printString_(" " << histo[i] << "\n"); 4073 } 4074 _printString_(" --------------------+-------------+-------------" << "\n"); 4075 4075 } 4076 4076 /*}}}*/ … … 4098 4098 for ( k=0;k<NbVerticesOnGeomEdge;k++ ) 4099 4099 tstart[ GetId(VerticesOnGeomEdge[k].meshvertex)]=&vide; 4100 if(verbose>2) _print Line_(" SmoothingVertex: nb Iteration = " << nbiter << ", Omega=" << omega);4100 if(verbose>2) _printString_(" SmoothingVertex: nb Iteration = " << nbiter << ", Omega=" << omega << "\n"); 4101 4101 for (k=0;k<nbiter;k++) 4102 4102 { … … 4110 4110 if (tstart[i] != &vide) // not a boundary vertex 4111 4111 NbSwap += vertices[i].Optim(1); 4112 if (verbose>3) _print Line_(" move max = " << pow(delta,0.5) << ", iteration = " << k << ", nb of swap = " << NbSwap);4112 if (verbose>3) _printString_(" move max = " << pow(delta,0.5) << ", iteration = " << k << ", nb of swap = " << NbSwap << "\n"); 4113 4113 } 4114 4114 … … 4124 4124 4125 4125 if(raisonmax<1.1) return; 4126 if(verbose > 1) _print Line_(" Mesh::SmoothMetric raisonmax = " << raisonmax);4126 if(verbose > 1) _printString_(" Mesh::SmoothMetric raisonmax = " << raisonmax << "\n"); 4127 4127 CreateSingleVertexToTriangleConnectivity(); 4128 4128 long i,j,kch,kk,ip; … … 4190 4190 Exchange(first_np_or_next_t0,first_np_or_next_t1); 4191 4191 } 4192 if(verbose>2) _print Line_(" number of iterations = " << kch);4192 if(verbose>2) _printString_(" number of iterations = " << kch << "\n"); 4193 4193 delete [] first_np_or_next_t0; 4194 4194 delete [] first_np_or_next_t1; … … 4378 4378 || (bb=Area2( t[0].r , A.r , t[2].r )) < 0.0 4379 4379 || (cc=Area2( t[0].r , t[1].r , A.r )) < 0.0)){ 4380 _print Line_(ke + nbvold << " not in triangle " << i << " In= " << !!t.link << " " << aa << " " << bb << " " << cc << " " << dd);4380 _printString_(ke + nbvold << " not in triangle " << i << " In= " << !!t.link << " " << aa << " " << bb << " " << cc << " " << dd << "\n"); 4381 4381 _error_("Number of triangles with P2 interpolation Problem"); 4382 4382 } … … 4386 4386 || (bb=Area2( tt[0].r , A.r , tt[2].r )) < 0 4387 4387 || (cc=Area2( tt[0].r , tt[1].r , A.r )) < 0)){ 4388 _print Line_(ke + nbvold << " not in triangle " << ii << " In= " << !!tt.link << " " << aa << " " << bb << " " << cc << " " << dd);4388 _printString_(ke + nbvold << " not in triangle " << ii << " In= " << !!tt.link << " " << aa << " " << bb << " " << cc << " " << dd << "\n"); 4389 4389 _error_("Number of triangles with P2 interpolation Problem"); 4390 4390 } … … 4679 4679 4680 4680 if (verbose>2){ 4681 _print Line_(" number of quadrilaterals = " << nbq);4682 _print Line_(" number of triangles = " << nbt-nbtout- nbq*2);4683 _print Line_(" number of outside triangles = " << nbtout);4681 _printString_(" number of quadrilaterals = " << nbq << "\n"); 4682 _printString_(" number of triangles = " << nbt-nbtout- nbq*2 << "\n"); 4683 _printString_(" number of outside triangles = " << nbtout << "\n"); 4684 4684 } 4685 4685 … … 4748 4748 Triangle *tcvi = TriangleFindFromCoord(vi.i,det3); 4749 4749 if (tcvi && !tcvi->link) { 4750 _print Line_("problem inserting point in SplitInternalEdgeWithBorderVertices (tcvj && !tcvj->link)");4750 _printString_("problem inserting point in SplitInternalEdgeWithBorderVertices (tcvj && !tcvj->link)" << "\n"); 4751 4751 } 4752 4752 … … 4760 4760 } 4761 4761 if (verbose>3) { 4762 _print Line_(" number of points: " << iv);4763 _print Line_(" number of swap to split internal edges with border vertices: " << NbSwap);4762 _printString_(" number of points: " << iv << "\n"); 4763 _printString_(" number of swap to split internal edges with border vertices: " << NbSwap << "\n"); 4764 4764 nbv = iv; 4765 4765 } 4766 4766 } 4767 if (NbSplitEdge>nbv-nbvold) _print Line_("WARNING: not enough vertices to split all internal edges, we lost " << NbSplitEdge - ( nbv-nbvold) << " edges...");4768 if (verbose>2) _print Line_("SplitInternalEdgeWithBorderVertices: Number of splited edge " << NbSplitEdge);4767 if (NbSplitEdge>nbv-nbvold) _printString_("WARNING: not enough vertices to split all internal edges, we lost " << NbSplitEdge - ( nbv-nbvold) << " edges..." << "\n"); 4768 if (verbose>2) _printString_("SplitInternalEdgeWithBorderVertices: Number of splited edge " << NbSplitEdge << "\n"); 4769 4769 4770 4770 return NbSplitEdge; … … 4936 4936 4937 4937 //Vertices 4938 if(verbose) _print Line_("Reading vertices (" << nbv << ")");4938 if(verbose) _printString_("Reading vertices (" << nbv << ")" << "\n"); 4939 4939 for (i=0;i<nbv;i++){ 4940 4940 vertices[i].r.x=x[i]; … … 5248 5248 5249 5249 //Insert points inside existing triangles 5250 if (verbose>4) _print Line_(" -- current number of vertices = " << nbv);5251 if (verbose>3) _print Line_(" Creating initial Constrained Delaunay Triangulation...");5252 if (verbose>3) _print Line_(" Inserting boundary points");5250 if (verbose>4) _printString_(" -- current number of vertices = " << nbv << "\n"); 5251 if (verbose>3) _printString_(" Creating initial Constrained Delaunay Triangulation..." << "\n"); 5252 if (verbose>3) _printString_(" Inserting boundary points" << "\n"); 5253 5253 Insert(); 5254 5254 5255 5255 //Force the boundary 5256 if (verbose>3) _print Line_(" Forcing boundaries");5256 if (verbose>3) _printString_(" Forcing boundaries" << "\n"); 5257 5257 ForceBoundary(); 5258 5258 5259 5259 //Extract SubDomains 5260 if (verbose>3) _print Line_(" Extracting subdomains");5260 if (verbose>3) _printString_(" Extracting subdomains" << "\n"); 5261 5261 FindSubDomain(); 5262 5262 5263 if (verbose>3) _print Line_(" Inserting internal points");5263 if (verbose>3) _printString_(" Inserting internal points" << "\n"); 5264 5264 NewPoints(*this,bamgopts,0) ; 5265 if (verbose>4) _print Line_(" -- current number of vertices = " << nbv);5265 if (verbose>4) _printString_(" -- current number of vertices = " << nbv << "\n"); 5266 5266 } 5267 5267 /*}}}*/ … … 5366 5366 int nc=ei.GeomEdgeHook->CurveNumber; 5367 5367 5368 //_print Line_("Dealing with curve number " << nc);5369 //_print Line_("edge on geometry is same as GhCurve? " << (ei.GeomEdgeHook==Gh.curves[nc].FirstEdge || ei.GeomEdgeHook==Gh.curves[nc].LastEdge)?"yes":"no");5368 //_printString_("Dealing with curve number " << nc << "\n"); 5369 //_printString_("edge on geometry is same as GhCurve? " << (ei.GeomEdgeHook==Gh.curves[nc].FirstEdge || ei.GeomEdgeHook==Gh.curves[nc].LastEdge)?"yes":"no" << "\n"); 5370 5370 //if(ei.GeomEdgeHook==Gh.curves[nc].FirstEdge || ei.GeomEdgeHook==Gh.curves[nc].LastEdge){ 5371 // _print Line_("Do we have the right extremity? curve first vertex -> " << ((GeomVertex *)*ei[je].GeomEdgeHook==&(*Gh.curves[nc].FirstEdge)[Gh.curves[nc].FirstVertexIndex])?"yes":"no");5372 // _print Line_("Do we have the right extremity? curve last vertex -> " << ((GeomVertex *)*ei[je].GeomEdgeHook==&(*Gh.curves[nc].LastEdge)[Gh.curves[nc].LastVertexIndex])?"yes":"no");5371 // _printString_("Do we have the right extremity? curve first vertex -> " << ((GeomVertex *)*ei[je].GeomEdgeHook==&(*Gh.curves[nc].FirstEdge)[Gh.curves[nc].FirstVertexIndex])?"yes":"no" << "\n"); 5372 // _printString_("Do we have the right extremity? curve last vertex -> " << ((GeomVertex *)*ei[je].GeomEdgeHook==&(*Gh.curves[nc].LastEdge)[Gh.curves[nc].LastVertexIndex])?"yes":"no" << "\n"); 5373 5373 //} 5374 5374 //BUG FIX from original bamg … … 5577 5577 5578 5578 //Insert points inside existing triangles 5579 if (verbose>4) _print Line_(" -- current number of vertices = " << nbv);5580 if (verbose>3) _print Line_(" Creating initial Constrained Delaunay Triangulation...");5581 if (verbose>3) _print Line_(" Inserting boundary points");5579 if (verbose>4) _printString_(" -- current number of vertices = " << nbv << "\n"); 5580 if (verbose>3) _printString_(" Creating initial Constrained Delaunay Triangulation..." << "\n"); 5581 if (verbose>3) _printString_(" Inserting boundary points" << "\n"); 5582 5582 Insert(); 5583 5583 5584 5584 //Force the boundary 5585 if (verbose>3) _print Line_(" Forcing boundaries");5585 if (verbose>3) _printString_(" Forcing boundaries" << "\n"); 5586 5586 ForceBoundary(); 5587 5587 5588 5588 //Extract SubDomains 5589 if (verbose>3) _print Line_(" Extracting subdomains");5589 if (verbose>3) _printString_(" Extracting subdomains" << "\n"); 5590 5590 FindSubDomain(); 5591 5591 5592 if (verbose>3) _print Line_(" Inserting internal points");5592 if (verbose>3) _printString_(" Inserting internal points" << "\n"); 5593 5593 NewPoints(BTh,bamgopts,KeepVertices) ; 5594 if (verbose>4) _print Line_(" -- current number of vertices = " << nbv);5594 if (verbose>4) _printString_(" -- current number of vertices = " << nbv << "\n"); 5595 5595 } 5596 5596 /*}}}*/ -
issm/trunk-jpl/src/c/bamg/Metric.cpp
r15067 r15099 71 71 void Metric::Echo(void){ 72 72 73 _print Line_("Metric:");74 _print Line_(" [a11 a21 a22]: [" << a11 << " " << a21 << " " << a22 << "]");73 _printString_("Metric:" << "\n"); 74 _printString_(" [a11 a21 a22]: [" << a11 << " " << a21 << " " << a22 << "]" << "\n"); 75 75 76 76 return; … … 200 200 LastMetricInterpole.lab=l; 201 201 LastMetricInterpole.opt=i; 202 if (i>200 && kkk++<10) _print Line_("WARNING: LengthInterpole: ( i=" << i << " l=" << l << " sss=" << sss << " ) " << sstop);202 if (i>200 && kkk++<10) _printString_("WARNING: LengthInterpole: ( i=" << i << " l=" << l << " sss=" << sss << " ) " << sstop << "\n"); 203 203 return l; 204 204 } -
issm/trunk-jpl/src/c/bamg/Triangle.cpp
r15066 r15099 109 109 int i; 110 110 111 _print Line_("Triangle:");112 _print Line_(" vertices pointer towards three vertices");113 _print Line_(" vertices[0] vertices[1] vertices[2] = " << vertices[0] << " " << vertices[1] << " " << vertices[2]);114 _print Line_(" adj pointer towards three adjacent triangles");115 _print Line_(" adj[0] adj[1] adj[2] = " << adj[0] << " " << adj[1] << " " << adj[2]);116 _print Line_(" det (integer triangle determinant) = " << det);111 _printString_("Triangle:" << "\n"); 112 _printString_(" vertices pointer towards three vertices" << "\n"); 113 _printString_(" vertices[0] vertices[1] vertices[2] = " << vertices[0] << " " << vertices[1] << " " << vertices[2] << "\n"); 114 _printString_(" adj pointer towards three adjacent triangles" << "\n"); 115 _printString_(" adj[0] adj[1] adj[2] = " << adj[0] << " " << adj[1] << " " << adj[2] << "\n"); 116 _printString_(" det (integer triangle determinant) = " << det << "\n"); 117 117 if (link){ 118 _print Line_(" link (pointer toward duplicate triangle)= " << link);118 _printString_(" link (pointer toward duplicate triangle)= " << link << "\n"); 119 119 } 120 120 else{ 121 _print Line_(" color = " << color);122 } 123 124 _print Line_("\nThree vertices:");121 _printString_(" color = " << color << "\n"); 122 } 123 124 _printString_("\nThree vertices:" << "\n"); 125 125 for(i=0;i<3;i++){ 126 126 if (vertices[i]){ … … 128 128 } 129 129 else{ 130 _print Line_(" vertex " << i+1 << " does not exist");130 _printString_(" vertex " << i+1 << " does not exist" << "\n"); 131 131 } 132 132 } -
issm/trunk-jpl/src/c/classes/Constraints/SpcDynamic.cpp
r15012 r15099 42 42 void SpcDynamic::Echo(void){ 43 43 44 _print Line_("SpcDynamic:");45 _print Line_(" sid: " << sid);46 _print Line_(" nodeid: " << nodeid);47 _print Line_(" dof: " << dof);48 _print Line_(" value: " << value);49 _print Line_(" isset: " <<(isset?"true":"false"));50 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));44 _printString_("SpcDynamic:" << "\n"); 45 _printString_(" sid: " << sid << "\n"); 46 _printString_(" nodeid: " << nodeid << "\n"); 47 _printString_(" dof: " << dof << "\n"); 48 _printString_(" value: " << value << "\n"); 49 _printString_(" isset: " <<(isset?"true":"false") << "\n"); 50 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 51 51 return; 52 52 } -
issm/trunk-jpl/src/c/classes/Constraints/SpcStatic.cpp
r15012 r15099 41 41 void SpcStatic::Echo(void){ 42 42 43 _print Line_("SpcStatic:");44 _print Line_(" sid: " << sid);45 _print Line_(" nodeid: " << nodeid);46 _print Line_(" dof: " << dof);47 _print Line_(" value: " << value);48 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));43 _printString_("SpcStatic:" << "\n"); 44 _printString_(" sid: " << sid << "\n"); 45 _printString_(" nodeid: " << nodeid << "\n"); 46 _printString_(" dof: " << dof << "\n"); 47 _printString_(" value: " << value << "\n"); 48 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 49 49 return; 50 50 } … … 53 53 void SpcStatic::DeepEcho(void){ 54 54 55 _print Line_("SpcStatic:");56 _print Line_(" sid: " << sid);57 _print Line_(" nodeid: " << nodeid);58 _print Line_(" dof: " << dof);59 _print Line_(" value: " << value);60 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));55 _printString_("SpcStatic:" << "\n"); 56 _printString_(" sid: " << sid << "\n"); 57 _printString_(" nodeid: " << nodeid << "\n"); 58 _printString_(" dof: " << dof << "\n"); 59 _printString_(" value: " << value << "\n"); 60 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 61 61 return; 62 62 } -
issm/trunk-jpl/src/c/classes/Constraints/SpcTransient.cpp
r15012 r15099 56 56 57 57 int i; 58 _print Line_("SpcTransient:");59 _print Line_(" sid: " << sid);60 _print Line_(" nodeid: " << nodeid);61 _print Line_(" dof: " << dof);62 _print Line_(" nsteps: " << nsteps);63 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));64 _print Line_(" steps|times|values");58 _printString_("SpcTransient:" << "\n"); 59 _printString_(" sid: " << sid << "\n"); 60 _printString_(" nodeid: " << nodeid << "\n"); 61 _printString_(" dof: " << dof << "\n"); 62 _printString_(" nsteps: " << nsteps << "\n"); 63 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 64 _printString_(" steps|times|values" << "\n"); 65 65 for(i=0;i<nsteps;i++){ 66 _print Line_(i << "-" << times[i] << ":" << values[i]);66 _printString_(i << "-" << times[i] << ":" << values[i] << "\n"); 67 67 } 68 68 return; -
issm/trunk-jpl/src/c/classes/Contour.h
r15067 r15099 57 57 /*FUNCTION Echo(){{{*/ 58 58 void Echo(void){ 59 _print Line_(" Contour: " << id);60 _print Line_(" nods: " << nods);61 _print Line_(" closed: " << (closed?"true":"false"));59 _printString_(" Contour: " << id << "\n"); 60 _printString_(" nods: " << nods << "\n"); 61 _printString_(" closed: " << (closed?"true":"false") << "\n"); 62 62 if(nods){ 63 _print Line_(" x , y:");63 _printString_(" x , y:" << "\n"); 64 64 for(int i=0;i<nods;i++){ 65 _print Line_(i << ": " << x[i] << " | " << y[i]);65 _printString_(i << ": " << x[i] << " | " << y[i] << "\n"); 66 66 } 67 67 } -
issm/trunk-jpl/src/c/classes/DependentObject.cpp
r15012 r15099 40 40 void DependentObject::Echo(void){ 41 41 42 _print Line_("DependentObject:");43 _print Line_(" name: " << EnumToStringx(this->name));42 _printString_("DependentObject:" << "\n"); 43 _printString_(" name: " << EnumToStringx(this->name) << "\n"); 44 44 if(this->type==0) 45 _print Line_(" type: scalar");45 _printString_(" type: scalar" << "\n"); 46 46 else if(this->type==1) 47 _print Line_(" type: vertex");47 _printString_(" type: vertex" << "\n"); 48 48 else 49 49 _error_(" unknown type: " << this->type); 50 if(this->index>=0) _print Line_(" index: " << this->index);50 if(this->index>=0) _printString_(" index: " << this->index << "\n"); 51 51 } 52 52 /*}}}*/ -
issm/trunk-jpl/src/c/classes/DofIndexing.cpp
r14960 r15099 163 163 void DofIndexing::Echo(void){ 164 164 165 _print Line_("DofIndexing:");166 _print Line_(" gsize: " << gsize);167 _print Line_(" clone: " << clone);165 _printString_("DofIndexing:" << "\n"); 166 _printString_(" gsize: " << gsize << "\n"); 167 _printString_(" clone: " << clone << "\n"); 168 168 } 169 169 /*}}}*/ … … 173 173 int i; 174 174 175 _print Line_("DofIndexing:");176 _print Line_(" gsize: " << gsize);177 _print Line_(" fsize: " << fsize);178 _print Line_(" ssize: " << ssize);179 _print Line_(" clone: " << clone);180 181 _print Line_(" set membership: f,s sets");175 _printString_("DofIndexing:" << "\n"); 176 _printString_(" gsize: " << gsize << "\n"); 177 _printString_(" fsize: " << fsize << "\n"); 178 _printString_(" ssize: " << ssize << "\n"); 179 _printString_(" clone: " << clone << "\n"); 180 181 _printString_(" set membership: f,s sets " << "\n"); 182 182 for(i=0;i<gsize;i++){ 183 _print Line_(" dof " << i << ": " <<(f_set[i]?"true":"false")<< " " <<(s_set[i]?"true":"false"));183 _printString_(" dof " << i << ": " <<(f_set[i]?"true":"false")<< " " <<(s_set[i]?"true":"false") << "\n"); 184 184 } 185 185 … … 188 188 if(this->s_set[i])_printString_(" " << svalues[i] << " |"); 189 189 } 190 _print Line_("");190 _printString_("" << "\n"); 191 191 192 192 if(doftype){ … … 195 195 _printString_(" " << doftype[i] << " |"); 196 196 } 197 _print Line_("");198 } 199 else _print Line_(" doftype: NULL");197 _printString_("" << "\n"); 198 } 199 else _printString_(" doftype: NULL" << "\n"); 200 200 201 201 _printString_(" g_doflist (" << this->gsize << "): |"); … … 203 203 _printString_(" " << gdoflist[i] << " |"); 204 204 } 205 _print Line_("");205 _printString_("" << "\n"); 206 206 207 207 _printString_(" f_doflist (" << this->fsize << "): |"); … … 209 209 _printString_(" " << fdoflist[i] << " |"); 210 210 } 211 _print Line_("");211 _printString_("" << "\n"); 212 212 213 213 _printString_(" s_doflist (" << this->ssize << "): |"); … … 215 215 _printString_(" " << sdoflist[i] << " |"); 216 216 } 217 _print Line_("");217 _printString_("" << "\n"); 218 218 } 219 219 /*}}}*/ -
issm/trunk-jpl/src/c/classes/ElementResults/BoolElementResult.cpp
r15012 r15099 42 42 void BoolElementResult::DeepEcho(void){ 43 43 44 _print Line_("BoolElementResult:");45 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _print Line_(" value: "<<(this->value?"true":"false"));47 _print Line_(" step: " << this->step);48 _print Line_(" time: " << this->time);44 _printString_("BoolElementResult:" << "\n"); 45 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 46 _printString_(" value: "<<(this->value?"true":"false") << "\n"); 47 _printString_(" step: " << this->step << "\n"); 48 _printString_(" time: " << this->time << "\n"); 49 49 } 50 50 /*}}}*/ -
issm/trunk-jpl/src/c/classes/ElementResults/DoubleElementResult.cpp
r15012 r15099 42 42 void DoubleElementResult::DeepEcho(void){ 43 43 44 _print Line_("DoubleElementResult:");45 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _print Line_(" value: " << this->value);47 _print Line_(" step: " << this->step);48 _print Line_(" time: " << this->time);44 _printString_("DoubleElementResult:" << "\n"); 45 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 46 _printString_(" value: " << this->value << "\n"); 47 _printString_(" step: " << this->step << "\n"); 48 _printString_(" time: " << this->time << "\n"); 49 49 } 50 50 /*}}}*/ -
issm/trunk-jpl/src/c/classes/ElementResults/PentaP1ElementResult.cpp
r15012 r15099 44 44 void PentaP1ElementResult::DeepEcho(void){ 45 45 46 _print Line_("PentaP1ElementResult:");47 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");48 _print Line_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << " " << this->values[3] << " " << this->values[4] << " " << this->values[5] << "]");49 _print Line_(" step: " << this->step);50 _print Line_(" time: " << this->time);46 _printString_("PentaP1ElementResult:" << "\n"); 47 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 48 _printString_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << " " << this->values[3] << " " << this->values[4] << " " << this->values[5] << "]" << "\n"); 49 _printString_(" step: " << this->step << "\n"); 50 _printString_(" time: " << this->time << "\n"); 51 51 52 52 } -
issm/trunk-jpl/src/c/classes/ElementResults/TriaP1ElementResult.cpp
r15012 r15099 44 44 void TriaP1ElementResult::DeepEcho(void){ 45 45 46 _print Line_("TriaP1ElementResult:");47 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");48 _print Line_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << "]");49 _print Line_(" step: " << this->step);50 _print Line_(" time: " << this->time);46 _printString_("TriaP1ElementResult:" << "\n"); 47 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 48 _printString_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << "]" << "\n"); 49 _printString_(" step: " << this->step << "\n"); 50 _printString_(" time: " << this->time << "\n"); 51 51 } 52 52 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Elements/Penta.cpp
r15082 r15099 668 668 void Penta::DeepEcho(void){ 669 669 670 _print Line_("Penta:");671 _print Line_(" id: " << id);670 _printString_("Penta:" << "\n"); 671 _printString_(" id: " << id << "\n"); 672 672 nodes[0]->DeepEcho(); 673 673 nodes[1]->DeepEcho(); … … 678 678 material->DeepEcho(); 679 679 matpar->DeepEcho(); 680 _print Line_(" neighbor ids: " << verticalneighbors[0]->Id() << "-" << verticalneighbors[1]->Id());681 _print Line_(" parameters");680 _printString_(" neighbor ids: " << verticalneighbors[0]->Id() << "-" << verticalneighbors[1]->Id() << "\n"); 681 _printString_(" parameters" << "\n"); 682 682 parameters->DeepEcho(); 683 _print Line_(" inputs");683 _printString_(" inputs" << "\n"); 684 684 inputs->DeepEcho(); 685 _print Line_(" results");685 _printString_(" results" << "\n"); 686 686 results->DeepEcho(); 687 _print Line_("neighboor sids:");688 _print Line_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2]);687 _printString_("neighboor sids: " << "\n"); 688 _printString_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2] << "\n"); 689 689 } 690 690 /*}}}*/ … … 1335 1335 } 1336 1336 else{ 1337 _print Line_("Interpolation " << EnumToStringx(interp) << " not supported");1337 _printString_("Interpolation " << EnumToStringx(interp) << " not supported" << "\n"); 1338 1338 } 1339 1339 } … … 4560 4560 /*Check solution*/ 4561 4561 if(xIsNan<IssmDouble>(values[i])) _error_("NaN found in solution vector"); 4562 //if(values[i]<0) _print Line_("temperature < 0°K found in solution vector");4563 //if(values[i]>275) _print Line_("temperature > 275°K found in solution vector (Paterson's rheology associated is negative)");4562 //if(values[i]<0) _printString_("temperature < 0°K found in solution vector" << "\n"); 4563 //if(values[i]>275) _printString_("temperature > 275°K found in solution vector (Paterson's rheology associated is negative)" << "\n"); 4564 4564 } 4565 4565 -
issm/trunk-jpl/src/c/classes/Elements/Tria.cpp
r15082 r15099 935 935 void Tria::DeepEcho(void){ 936 936 937 _print Line_("Tria:");938 _print Line_(" id: " << id);937 _printString_("Tria:" << "\n"); 938 _printString_(" id: " << id << "\n"); 939 939 if(nodes){ 940 940 nodes[0]->DeepEcho(); … … 942 942 nodes[2]->DeepEcho(); 943 943 } 944 else _print Line_("nodes = NULL");944 else _printString_("nodes = NULL" << "\n"); 945 945 946 946 if (material) material->DeepEcho(); 947 else _print Line_("material = NULL");947 else _printString_("material = NULL" << "\n"); 948 948 949 949 if (matpar) matpar->DeepEcho(); 950 else _print Line_("matpar = NULL");951 952 _print Line_(" parameters");950 else _printString_("matpar = NULL" << "\n"); 951 952 _printString_(" parameters" << "\n"); 953 953 if (parameters) parameters->DeepEcho(); 954 else _print Line_("parameters = NULL");955 956 _print Line_(" inputs");954 else _printString_("parameters = NULL" << "\n"); 955 956 _printString_(" inputs" << "\n"); 957 957 if (inputs) inputs->DeepEcho(); 958 else _print Line_("inputs=NULL");958 else _printString_("inputs=NULL" << "\n"); 959 959 960 960 if (results) results->DeepEcho(); 961 else _print Line_("results=NULL");962 963 _print Line_("neighboor sids:");964 _print Line_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2]);961 else _printString_("results=NULL" << "\n"); 962 963 _printString_("neighboor sids: " << "\n"); 964 _printString_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2] << "\n"); 965 965 966 966 return; … … 1047 1047 /*FUNCTION Tria::Echo{{{*/ 1048 1048 void Tria::Echo(void){ 1049 _print Line_("Tria:");1050 _print Line_(" id: " << id);1049 _printString_("Tria:" << "\n"); 1050 _printString_(" id: " << id << "\n"); 1051 1051 if(nodes){ 1052 1052 nodes[0]->Echo(); … … 1054 1054 nodes[2]->Echo(); 1055 1055 } 1056 else _print Line_("nodes = NULL");1056 else _printString_("nodes = NULL" << "\n"); 1057 1057 1058 1058 if (material) material->Echo(); 1059 else _print Line_("material = NULL");1059 else _printString_("material = NULL" << "\n"); 1060 1060 1061 1061 if (matpar) matpar->Echo(); 1062 else _print Line_("matpar = NULL");1063 1064 _print Line_(" parameters");1062 else _printString_("matpar = NULL" << "\n"); 1063 1064 _printString_(" parameters" << "\n"); 1065 1065 if (parameters) parameters->Echo(); 1066 else _print Line_("parameters = NULL");1067 1068 _print Line_(" inputs");1066 else _printString_("parameters = NULL" << "\n"); 1067 1068 _printString_(" inputs" << "\n"); 1069 1069 if (inputs) inputs->Echo(); 1070 else _print Line_("inputs=NULL");1070 else _printString_("inputs=NULL" << "\n"); 1071 1071 1072 1072 if (results) results->Echo(); 1073 else _print Line_("results=NULL");1074 1075 _print Line_("neighboor sids:");1076 _print Line_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2]);1073 else _printString_("results=NULL" << "\n"); 1074 1075 _printString_("neighboor sids: " << "\n"); 1076 _printString_(" " << horizontalneighborsids[0] << " " << horizontalneighborsids[1] << " " << horizontalneighborsids[2] << "\n"); 1077 1077 } 1078 1078 /*}}}*/ … … 1559 1559 } 1560 1560 else{ 1561 _print Line_("Interpolation " << EnumToStringx(interp) << " not supported");1561 _printString_("Interpolation " << EnumToStringx(interp) << " not supported" << "\n"); 1562 1562 } 1563 1563 } -
issm/trunk-jpl/src/c/classes/ExternalResults/GenericExternalResult.h
r15012 r15099 33 33 /*Diverse: must be in front, as it is used in what follows*/ 34 34 void GenericEcho(void){/*{{{*/ 35 _print Line_(" id: " << this->id);36 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");37 _print Line_(" step: " << this->step);38 _print Line_(" time: " << this->time);35 _printString_(" id: " << this->id << "\n"); 36 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 37 _printString_(" step: " << this->step << "\n"); 38 _printString_(" time: " << this->time << "\n"); 39 39 } 40 40 /*}}}*/ … … 143 143 template <> inline void GenericExternalResult<bool>::DeepEcho(void){ /*{{{*/ 144 144 145 _print Line_("GenericExternalResult<bool>:");146 this->GenericEcho(); 147 _print Line_(" value: " <<(this->value?"true":"false"));145 _printString_("GenericExternalResult<bool>:" << "\n"); 146 this->GenericEcho(); 147 _printString_(" value: " <<(this->value?"true":"false") << "\n"); 148 148 149 149 } /*}}}*/ … … 155 155 template <> inline void GenericExternalResult<int>::DeepEcho(void){ /*{{{*/ 156 156 157 _print Line_("GenericExternalResult<int>:");158 this->GenericEcho(); 159 _print Line_(" value: " << this->value);157 _printString_("GenericExternalResult<int>:" << "\n"); 158 this->GenericEcho(); 159 _printString_(" value: " << this->value << "\n"); 160 160 161 161 } /*}}}*/ … … 167 167 template <> inline void GenericExternalResult<double>::DeepEcho(void){ /*{{{*/ 168 168 169 _print Line_("GenericExternalResult<double>:");170 this->GenericEcho(); 171 _print Line_(" value: " << this->value);169 _printString_("GenericExternalResult<double>:" << "\n"); 170 this->GenericEcho(); 171 _printString_(" value: " << this->value << "\n"); 172 172 173 173 } /*}}}*/ … … 192 192 template <> inline void GenericExternalResult<char*>::DeepEcho(void){ /*{{{*/ 193 193 194 _print Line_("GenericExternalResult<char*>:");195 this->GenericEcho(); 196 _print Line_(" value: " << this->value);194 _printString_("GenericExternalResult<char*>:" << "\n"); 195 this->GenericEcho(); 196 _printString_(" value: " << this->value << "\n"); 197 197 198 198 } /*}}}*/ … … 252 252 template <> inline void GenericExternalResult<IssmPDouble*>::Echo(void){ /*{{{*/ 253 253 254 _print Line_("GenericExternalResult<IssmPDouble*>:");255 this->GenericEcho(); 256 _print Line_(" matrix size: " << this->M << "-" << this->N);254 _printString_("GenericExternalResult<IssmPDouble*>:" << "\n"); 255 this->GenericEcho(); 256 _printString_(" matrix size: " << this->M << "-" << this->N << "\n"); 257 257 258 258 } /*}}}*/ … … 261 261 int i,j; 262 262 263 _print Line_("GenericExternalResult<IssmPDouble*>:");264 this->GenericEcho(); 265 266 _print Line_(" matrix size: " << this->M << "-" << this->N);263 _printString_("GenericExternalResult<IssmPDouble*>:" << "\n"); 264 this->GenericEcho(); 265 266 _printString_(" matrix size: " << this->M << "-" << this->N << "\n"); 267 267 for (i=0;i<this->M;i++){ 268 268 _printString_(" [ "); … … 270 270 _printString_( " " << setw(11) << setprecision (5) << this->value[i*this->N+j]); 271 271 } 272 _print Line_(" ]");272 _printString_(" ]" << "\n"); 273 273 } 274 274 -
issm/trunk-jpl/src/c/classes/FemModel.cpp
r15075 r15099 118 118 this->parameters->FindParam(&lockfilename,LockFileNameEnum); 119 119 if (waitonlock>0){ 120 _pprint Line_("write lock file:");120 _pprintString_("write lock file:" << "\n"); 121 121 WriteLockFile(lockfilename); 122 122 } … … 137 137 /*Before we delete the profiler, report statistics for this run: */ 138 138 profiler->Tag(Finish); //final tagging 139 _pprint Line_("");140 _pprint Line_(" "<<setw(40)<<left<<"FemModel initialization elapsed time:"<<profiler->DeltaTime(StartInit,FinishInit));141 _pprint Line_(" "<<setw(40)<<left<<"Core solution elapsed time:"<<profiler->DeltaTime(StartCore,FinishCore));142 _pprint Line_("");143 _pprint Line_(" Total elapsed time:"139 _pprintString_("" << "\n"); 140 _pprintString_(" "<<setw(40)<<left<<"FemModel initialization elapsed time:"<<profiler->DeltaTime(StartInit,FinishInit) << "\n"); 141 _pprintString_(" "<<setw(40)<<left<<"Core solution elapsed time:"<<profiler->DeltaTime(StartCore,FinishCore) << "\n"); 142 _pprintString_("" << "\n"); 143 _pprintString_(" Total elapsed time:" 144 144 <<profiler->DeltaTimeModHour(Start,Finish)<<" hrs " 145 145 <<profiler->DeltaTimeModMin(Start,Finish)<<" min " 146 146 <<profiler->DeltaTimeModSec(Start,Finish)<<" sec" 147 147 ); 148 _pprint Line_("");148 _pprintString_("" << "\n"); 149 149 150 150 /*Now delete: */ … … 153 153 /*Finalize PETSC for this model: */ 154 154 #ifdef _HAVE_PETSC_ 155 _pprint Line_("closing Petsc");155 _pprintString_("closing Petsc" << "\n"); 156 156 PetscFinalize(); 157 157 #endif … … 164 164 void FemModel::Echo(void){ 165 165 166 _print Line_("FemModel echo:");167 _print Line_(" number of fem models: " << nummodels);168 _print Line_(" analysis_type_list:");169 for(int i=0;i<nummodels;i++)_print Line_(" " << i << ": " << EnumToStringx(analysis_type_list[i]));170 _print Line_(" current analysis_type:");171 _print Line_(" " << analysis_counter << ": " << EnumToStringx(analysis_type_list[analysis_counter]));166 _printString_("FemModel echo: " << "\n"); 167 _printString_(" number of fem models: " << nummodels << "\n"); 168 _printString_(" analysis_type_list: " << "\n"); 169 for(int i=0;i<nummodels;i++)_printString_(" " << i << ": " << EnumToStringx(analysis_type_list[i]) << "\n"); 170 _printString_(" current analysis_type: " << "\n"); 171 _printString_(" " << analysis_counter << ": " << EnumToStringx(analysis_type_list[analysis_counter]) << "\n"); 172 172 173 173 } … … 208 208 for(i=0;i<nummodels;i++){ 209 209 210 if(VerboseMProcessor()) _pprint Line_(" Processing finite element model of analysis " << EnumToStringx(analysis_type_list[i]) << ":");210 if(VerboseMProcessor()) _pprintString_(" Processing finite element model of analysis " << EnumToStringx(analysis_type_list[i]) << ":" << "\n"); 211 211 analysis_type=analysis_type_list[i]; 212 212 this->SetCurrentConfiguration(analysis_type); 213 213 214 214 if(i==0){ 215 if(VerboseMProcessor()) _pprint Line_(" creating vertex degrees of freedom");215 if(VerboseMProcessor()) _pprintString_(" creating vertex degrees of freedom" << "\n"); 216 216 VerticesDofx(vertices,parameters); //only call once, we only have one set of vertices 217 217 } 218 218 219 if(VerboseMProcessor()) _pprint Line_(" resolving node constraints");219 if(VerboseMProcessor()) _pprintString_(" resolving node constraints" << "\n"); 220 220 SpcNodesx(nodes,constraints,parameters,analysis_type); 221 221 222 if(VerboseMProcessor()) _pprint Line_(" creating nodal degrees of freedom");222 if(VerboseMProcessor()) _pprintString_(" creating nodal degrees of freedom" << "\n"); 223 223 NodesDofx(nodes,parameters,analysis_type); 224 224 225 if(VerboseMProcessor()) _pprint Line_(" configuring element and loads");225 if(VerboseMProcessor()) _pprintString_(" configuring element and loads" << "\n"); 226 226 ConfigureObjectsx(elements, loads, nodes, vertices, materials,parameters); 227 227 } … … 247 247 void FemModel::OutputResults(void){ 248 248 249 _pprint Line_("write results to disk:");249 _pprintString_("write results to disk:" << "\n"); 250 250 251 251 /*Just call the OutputResultsx module: */ … … 294 294 if(this->parameters->Exist(ToolkitsOptionsStringsEnum)){ 295 295 ToolkitsOptionsFromAnalysis(this->parameters,analysis_type); 296 if(VerboseSolver()) _pprint Line_(" toolkits Options set for analysis type: " << EnumToStringx(analysis_type));296 if(VerboseSolver()) _pprintString_(" toolkits Options set for analysis type: " << EnumToStringx(analysis_type) << "\n"); 297 297 } 298 298 … … 317 317 void (*solutioncore)(FemModel*)=NULL; //core solution function pointer 318 318 319 _pprint Line_("call computational core:");319 _pprintString_("call computational core:" << "\n"); 320 320 321 321 /*Retrieve solution_type from parameters: */ … … 343 343 solution_memory=profiler->Memory(FinishCore); 344 344 345 _pprint Line_("Solution elapsed time : " << solution_time << " Seconds");346 _pprint Line_("Solution elapsed flops : " << solution_flops << " Flops");347 _pprint Line_("Solution memory used : " << solution_memory << " Bytes");345 _pprintString_("Solution elapsed time : " << solution_time << " Seconds" << "\n"); 346 _pprintString_("Solution elapsed flops : " << solution_flops << " Flops" << "\n"); 347 _pprintString_("Solution memory used : " << solution_memory << " Bytes" << "\n"); 348 348 349 349 /*Add to results: */ … … 676 676 677 677 /*start module: */ 678 if(VerboseModule()) _pprint Line_(" Updating constraints for time: " << time);678 if(VerboseModule()) _pprintString_(" Updating constraints for time: " << time << "\n"); 679 679 680 680 /*First, update dof constraints in nodes, using constraints: */ … … 829 829 830 830 /*Display message*/ 831 if(VerboseModule()) _pprint Line_(" Generating matrices");831 if(VerboseModule()) _pprintString_(" Generating matrices" << "\n"); 832 832 833 833 /*retrive parameters: */ … … 1551 1551 for(i=0;i<d_numresponses-1;i++)_printString_(d_responses[i] << "|"); 1552 1552 _printString_(d_responses[d_numresponses-1]); 1553 _print Line_("");1553 _printString_("" << "\n"); 1554 1554 } 1555 1555 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Hook.cpp
r14996 r15099 66 66 int i; 67 67 if (num){ 68 _print Line_(" Hook:");69 _print Line_(" num=" << this->num);68 _printString_(" Hook: " << "\n"); 69 _printString_(" num=" << this->num << "\n"); 70 70 _printString_(" ids: "); 71 71 for (i=0;i<this->num;i++) _printString_(this->ids[i] << " "); 72 _print Line_("");72 _printString_("" << "\n"); 73 73 _printString_(" offsets: "); 74 74 for (i=0;i<this->num;i++) _printString_(this->offsets[i] << " "); 75 _print Line_("");75 _printString_("" << "\n"); 76 76 } 77 77 else{ 78 _print Line_(" Hook: num=0");78 _printString_(" Hook: num=0 " << "\n"); 79 79 } 80 80 } … … 85 85 int i; 86 86 if (num){ 87 _print Line_(" Hook:");88 _print Line_(" num=" << this->num);87 _printString_(" Hook: " << "\n"); 88 _printString_(" num=" << this->num << "\n"); 89 89 _printString_(" ids: "); 90 90 for (i=0;i<this->num;i++) _printString_(this->ids[i] << " "); 91 _print Line_("");91 _printString_("" << "\n"); 92 92 _printString_(" offsets: "); 93 93 for (i=0;i<this->num;i++) _printString_(this->offsets[i] << " "); 94 _print Line_("");95 if (!objects) _print Line_(" warning: object not hooked yet");94 _printString_("" << "\n"); 95 if (!objects) _printString_(" warning: object not hooked yet" << "\n"); 96 96 else{ 97 97 _printString_(" objects:\n "); 98 98 for (i=0;i<this->num;i++){ 99 _print Line_(" object " << i);99 _printString_(" object " << i << "\n"); 100 100 if(objects[i]) objects[i]->DeepEcho(); 101 else _print Line_(" no object hooked yet (not configured)");101 else _printString_(" no object hooked yet (not configured)" << "\n"); 102 102 } 103 103 } 104 104 } 105 105 else{ 106 _print Line_(" Hook: num=0");106 _printString_(" Hook: num=0 " << "\n"); 107 107 } 108 108 } -
issm/trunk-jpl/src/c/classes/IndependentObject.cpp
r15012 r15099 41 41 void IndependentObject::Echo(void){ 42 42 43 _print Line_("IndependentObject:");44 _print Line_(" name: " << EnumToStringx(this->name));43 _printString_("IndependentObject:" << "\n"); 44 _printString_(" name: " << EnumToStringx(this->name) << "\n"); 45 45 if(this->type==0) 46 _print Line_(" type: scalar");46 _printString_(" type: scalar" << "\n"); 47 47 else if(this->type==1) 48 _print Line_(" type: vertex");48 _printString_(" type: vertex" << "\n"); 49 49 else 50 50 _error_(" unknown type: " << this->type); 51 _print Line_(" numberofvertices: " << this->numberofvertices);51 _printString_(" numberofvertices: " << this->numberofvertices << "\n"); 52 52 } 53 53 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/BoolInput.cpp
r15082 r15099 40 40 void BoolInput::DeepEcho(void){ 41 41 42 _print Line_("BoolInput:");43 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");44 _print Line_(" value: " <<(value?"true":"false"));42 _printString_("BoolInput:" << "\n"); 43 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 44 _printString_(" value: " <<(value?"true":"false") << "\n"); 45 45 } 46 46 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/ControlInput.cpp
r15012 r15099 67 67 void ControlInput::DeepEcho(void){ 68 68 69 _print Line_("ControlInput:");70 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");71 _print Line_("---values:"); if (values) values->Echo();72 _print Line_("---savedvalues:");if (savedvalues) savedvalues->Echo();73 _print Line_("---minvalues:"); if (minvalues) minvalues->Echo();74 _print Line_("---maxvalues:"); if (maxvalues) maxvalues->Echo();75 _print Line_("---gradient:"); if (gradient) gradient->Echo();69 _printString_("ControlInput:" << "\n"); 70 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 71 _printString_("---values: " << "\n"); if (values) values->Echo(); 72 _printString_("---savedvalues: " << "\n");if (savedvalues) savedvalues->Echo(); 73 _printString_("---minvalues: " << "\n"); if (minvalues) minvalues->Echo(); 74 _printString_("---maxvalues: " << "\n"); if (maxvalues) maxvalues->Echo(); 75 _printString_("---gradient: " << "\n"); if (gradient) gradient->Echo(); 76 76 } 77 77 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/DatasetInput.cpp
r15012 r15099 42 42 void DatasetInput::DeepEcho(void){ 43 43 44 _print Line_("DatasetInput:");45 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _print Line_("---inputs:"); inputs->Echo();44 _printString_("DatasetInput:" << "\n"); 45 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 46 _printString_("---inputs: " << "\n"); inputs->Echo(); 47 47 } 48 48 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/DoubleInput.cpp
r15082 r15099 40 40 void DoubleInput::DeepEcho(void){ 41 41 42 _print Line_("DoubleInput:");43 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");44 _print Line_(" value: " << this->value);42 _printString_("DoubleInput:" << "\n"); 43 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 44 _printString_(" value: " << this->value << "\n"); 45 45 } 46 46 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/IntInput.cpp
r15082 r15099 35 35 void IntInput::DeepEcho(void){ 36 36 37 _print Line_("IntInput:");38 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");39 _print Line_(" value: " << (int)this->value);37 _printString_("IntInput:" << "\n"); 38 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 39 _printString_(" value: " << (int)this->value << "\n"); 40 40 } 41 41 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/PentaP1Input.cpp
r15082 r15099 51 51 void PentaP1Input::DeepEcho(void){ 52 52 53 _print Line_("PentaP1Input:");54 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");55 _print Line_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << " " << this->values[3] << " " << this->values[4] << " " << this->values[5] << "]");53 _printString_("PentaP1Input:" << "\n"); 54 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 55 _printString_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << " " << this->values[3] << " " << this->values[4] << " " << this->values[5] << "]" << "\n"); 56 56 } 57 57 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Inputs/TransientInput.cpp
r15012 r15099 61 61 int i; 62 62 63 _print Line_("TransientInput:");64 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");65 _print Line_(" numtimesteps: " << this->numtimesteps);66 _print Line_("---inputs:");63 _printString_("TransientInput:" << "\n"); 64 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 65 _printString_(" numtimesteps: " << this->numtimesteps << "\n"); 66 _printString_("---inputs: " << "\n"); 67 67 for(i=0;i<this->numtimesteps;i++){ 68 _print Line_(" time: " << this->timesteps[i] << "");68 _printString_(" time: " << this->timesteps[i] << " " << "\n"); 69 69 ((Input*)this->inputs->GetObjectByOffset(i))->Echo(); 70 70 } -
issm/trunk-jpl/src/c/classes/Inputs/TriaP1Input.cpp
r15082 r15099 51 51 void TriaP1Input::DeepEcho(void){ 52 52 53 _print Line_("TriaP1Input:");54 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");55 _print Line_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << "]");53 _printString_("TriaP1Input:" << "\n"); 54 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 55 _printString_(" values: [" << this->values[0] << " " << this->values[1] << " " << this->values[2] << "]" << "\n"); 56 56 } 57 57 /*}}}*/ -
issm/trunk-jpl/src/c/classes/IoModel.cpp
r14996 r15099 84 84 for(int i=0;i<MaximumNumberOfEnums;i++){ 85 85 if(this->data[i]){ 86 _pprint Line_("Info: previous pointer of " << EnumToStringx(i) << " has not been freed (DeleteData has not been called)");86 _pprintString_("Info: previous pointer of " << EnumToStringx(i) << " has not been freed (DeleteData has not been called)" << "\n"); 87 87 } 88 88 } … … 125 125 else{ 126 126 if(record_enum!=MaximumNumberOfEnums){ 127 _pprint Line_("");128 _pprint Line_("=========================================================================");129 _pprint Line_(" Enums in marshalled file are not compatible with compiled code");130 _pprint Line_("");131 _pprint Line_(" * If you are running ISSM on a remote cluster:");132 _pprint Line_(" make sure that you are using the same version of ISSM on your local");133 _pprint Line_(" machine and remote cluster (you might need to run svn update)");134 _pprint Line_(" * If you are running ISSM on your local machine:");135 _pprint Line_(" make sure that all the code is compiled (modules and executables)");136 _pprint Line_(" * If you are a developer and just added a new Enum:");137 _pprint Line_(" you might need to run ./Synchronize.sh in src/c/EnumDefinitions");138 _pprint Line_(" and recompile");139 _pprint Line_("=========================================================================");140 _pprint Line_("");127 _pprintString_("" << "\n"); 128 _pprintString_("=========================================================================" << "\n"); 129 _pprintString_(" Enums in marshalled file are not compatible with compiled code " << "\n"); 130 _pprintString_(" " << "\n"); 131 _pprintString_(" * If you are running ISSM on a remote cluster: " << "\n"); 132 _pprintString_(" make sure that you are using the same version of ISSM on your local " << "\n"); 133 _pprintString_(" machine and remote cluster (you might need to run svn update) " << "\n"); 134 _pprintString_(" * If you are running ISSM on your local machine: " << "\n"); 135 _pprintString_(" make sure that all the code is compiled (modules and executables) " << "\n"); 136 _pprintString_(" * If you are a developer and just added a new Enum: " << "\n"); 137 _pprintString_(" you might need to run ./Synchronize.sh in src/c/EnumDefinitions " << "\n"); 138 _pprintString_(" and recompile " << "\n"); 139 _pprintString_("=========================================================================" << "\n"); 140 _pprintString_("" << "\n"); 141 141 _error_("Enums not consistent (See error message above)"); 142 142 } -
issm/trunk-jpl/src/c/classes/Loads/Friction.cpp
r15012 r15099 43 43 /*FUNCTION Friction::Echo {{{*/ 44 44 void Friction::Echo(void){ 45 _print Line_("Friction:");46 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));47 _print Line_(" element_type: " << this->element_type);45 _printString_("Friction:" << "\n"); 46 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 47 _printString_(" element_type: " << this->element_type << "\n"); 48 48 inputs->Echo(); 49 49 matpar->Echo(); -
issm/trunk-jpl/src/c/classes/Loads/Icefront.cpp
r15012 r15099 134 134 /*FUNCTION Icefront::Echo {{{*/ 135 135 void Icefront::Echo(void){ 136 _print Line_("Icefront:");137 _print Line_(" id: " << id);138 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));136 _printString_("Icefront:" << "\n"); 137 _printString_(" id: " << id << "\n"); 138 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 139 139 hnodes->Echo(); 140 140 hvertices->Echo(); 141 141 helement->Echo(); 142 142 hmatpar->Echo(); 143 _print Line_(" parameters: " << parameters);143 _printString_(" parameters: " << parameters << "\n"); 144 144 if(parameters)parameters->Echo(); 145 _print Line_(" inputs: " << inputs);145 _printString_(" inputs: " << inputs << "\n"); 146 146 if(inputs)inputs->Echo(); 147 147 } … … 150 150 void Icefront::DeepEcho(void){ 151 151 152 _print Line_("Icefront:");153 _print Line_(" id: " << id);154 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));152 _printString_("Icefront:" << "\n"); 153 _printString_(" id: " << id << "\n"); 154 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 155 155 hnodes->DeepEcho(); 156 156 hvertices->DeepEcho(); 157 157 helement->DeepEcho(); 158 158 hmatpar->DeepEcho(); 159 _print Line_(" parameters: " << parameters);159 _printString_(" parameters: " << parameters << "\n"); 160 160 if(parameters)parameters->DeepEcho(); 161 _print Line_(" inputs: " << inputs);161 _printString_(" inputs: " << inputs << "\n"); 162 162 if(inputs)inputs->DeepEcho(); 163 163 } -
issm/trunk-jpl/src/c/classes/Loads/Numericalflux.cpp
r15012 r15099 155 155 /*FUNCTION Numericalflux::Echo {{{*/ 156 156 void Numericalflux::Echo(void){ 157 _print Line_("Numericalflux:");158 _print Line_(" id: " << id);159 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));157 _printString_("Numericalflux:" << "\n"); 158 _printString_(" id: " << id << "\n"); 159 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 160 160 hnodes->Echo(); 161 161 hvertices->Echo(); 162 162 helement->Echo(); 163 _print Line_(" parameters: " << parameters);164 _print Line_(" inputs: " << inputs);163 _printString_(" parameters: " << parameters << "\n"); 164 _printString_(" inputs: " << inputs << "\n"); 165 165 } 166 166 /*}}}*/ … … 168 168 void Numericalflux::DeepEcho(void){ 169 169 170 _print Line_("Numericalflux:");171 _print Line_(" id: " << id);172 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));170 _printString_("Numericalflux:" << "\n"); 171 _printString_(" id: " << id << "\n"); 172 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 173 173 hnodes->DeepEcho(); 174 174 hvertices->DeepEcho(); 175 175 helement->DeepEcho(); 176 _print Line_(" parameters");176 _printString_(" parameters" << "\n"); 177 177 if(parameters) 178 178 parameters->DeepEcho(); 179 179 else 180 _print Line_(" NULL");181 _print Line_(" inputs");180 _printString_(" NULL" << "\n"); 181 _printString_(" inputs" << "\n"); 182 182 inputs->DeepEcho(); 183 183 -
issm/trunk-jpl/src/c/classes/Loads/Pengrid.cpp
r15020 r15099 103 103 void Pengrid::DeepEcho(void){ 104 104 105 _print Line_("Pengrid:");106 _print Line_(" id: " << id);107 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));105 _printString_("Pengrid:" << "\n"); 106 _printString_(" id: " << id << "\n"); 107 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 108 108 hnode->DeepEcho(); 109 109 helement->DeepEcho(); 110 110 hmatpar->DeepEcho(); 111 _print Line_(" active " << this->active);112 _print Line_(" zigzag_counter " << this->zigzag_counter);113 _print Line_(" parameters");111 _printString_(" active " << this->active << "\n"); 112 _printString_(" zigzag_counter " << this->zigzag_counter << "\n"); 113 _printString_(" parameters" << "\n"); 114 114 parameters->DeepEcho(); 115 _print Line_(" inputs");115 _printString_(" inputs" << "\n"); 116 116 inputs->DeepEcho(); 117 117 } -
issm/trunk-jpl/src/c/classes/Loads/Penpair.cpp
r15012 r15099 51 51 void Penpair::Echo(void){ 52 52 53 _print Line_("Penpair:");54 _print Line_(" id: " << id);55 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));53 _printString_("Penpair:" << "\n"); 54 _printString_(" id: " << id << "\n"); 55 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 56 56 hnodes->Echo(); 57 57 … … 62 62 void Penpair::DeepEcho(void){ 63 63 64 _print Line_("Penpair:");65 _print Line_(" id: " << id);66 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));64 _printString_("Penpair:" << "\n"); 65 _printString_(" id: " << id << "\n"); 66 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 67 67 hnodes->DeepEcho(); 68 68 -
issm/trunk-jpl/src/c/classes/Loads/Riftfront.cpp
r15012 r15099 138 138 input=(Input*)this->inputs->GetInput(FractionIncrementEnum); input->GetInputValue(&fractionincrement); 139 139 140 _print Line_("Riftfront:");141 _print Line_(" id: " << id);142 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));143 _print Line_(" hnodes: " << hnodes);144 _print Line_(" helements: " << helements);145 _print Line_(" hmatpar: " << hmatpar);146 _print Line_(" parameters: " << parameters);147 _print Line_(" inputs: " << inputs);148 _print Line_(" internal parameters:");149 _print Line_(" normal: " << normal[0] << "|" << normal[1]);150 _print Line_(" length: " << length);151 _print Line_(" penalty_lock: " << penalty_lock);152 _print Line_(" active: " <<(active ? "true":"false"));153 _print Line_(" counter: " << counter);154 _print Line_(" prestable: " << (prestable ? "true":"false"));155 _print Line_(" material_converged: " << (material_converged ? "true":"false"));156 _print Line_(" fill: " << fill);157 _print Line_(" friction: " << friction);158 _print Line_(" fraction: " << fraction);159 _print Line_(" fractionincrement: " << fractionincrement);160 _print Line_(" state: " << state);161 _print Line_(" frozen: " << (frozen ? "true":"false"));140 _printString_("Riftfront:" << "\n"); 141 _printString_(" id: " << id << "\n"); 142 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 143 _printString_(" hnodes: " << hnodes << "\n"); 144 _printString_(" helements: " << helements << "\n"); 145 _printString_(" hmatpar: " << hmatpar << "\n"); 146 _printString_(" parameters: " << parameters << "\n"); 147 _printString_(" inputs: " << inputs << "\n"); 148 _printString_(" internal parameters: " << "\n"); 149 _printString_(" normal: " << normal[0] << "|" << normal[1] << "\n"); 150 _printString_(" length: " << length << "\n"); 151 _printString_(" penalty_lock: " << penalty_lock << "\n"); 152 _printString_(" active: " <<(active ? "true":"false") << "\n"); 153 _printString_(" counter: " << counter << "\n"); 154 _printString_(" prestable: " << (prestable ? "true":"false") << "\n"); 155 _printString_(" material_converged: " << (material_converged ? "true":"false") << "\n"); 156 _printString_(" fill: " << fill << "\n"); 157 _printString_(" friction: " << friction << "\n"); 158 _printString_(" fraction: " << fraction << "\n"); 159 _printString_(" fractionincrement: " << fractionincrement << "\n"); 160 _printString_(" state: " << state << "\n"); 161 _printString_(" frozen: " << (frozen ? "true":"false") << "\n"); 162 162 163 163 } … … 166 166 void Riftfront::DeepEcho(void){ 167 167 168 _print Line_("Riftfront:");169 _print Line_(" id: " << id);170 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));168 _printString_("Riftfront:" << "\n"); 169 _printString_(" id: " << id << "\n"); 170 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 171 171 hnodes->DeepEcho(); 172 172 helements->DeepEcho(); 173 173 hmatpar->DeepEcho(); 174 _print Line_(" parameters");174 _printString_(" parameters" << "\n"); 175 175 if(parameters)parameters->DeepEcho(); 176 _print Line_(" inputs");176 _printString_(" inputs" << "\n"); 177 177 if(inputs)inputs->DeepEcho(); 178 178 } … … 687 687 this->fraction+=fractionincrement; 688 688 if (this->fraction>1)this->fraction=(IssmDouble)1.0; 689 //_print Line_("riftfront " << this->Id() << " fraction: " << this->fraction);689 //_printString_("riftfront " << this->Id() << " fraction: " << this->fraction << "\n"); 690 690 } 691 691 … … 702 702 this->active=activate; 703 703 704 //if ((penetration>0) && (this->active==1))_print Line_("Riftfront " << Id() << " wants to be released");704 //if ((penetration>0) && (this->active==1))_printString_("Riftfront " << Id() << " wants to be released" << "\n"); 705 705 706 706 /*assign output pointer: */ -
issm/trunk-jpl/src/c/classes/Materials/Matdamageice.cpp
r15040 r15099 55 55 void Matdamageice::Echo(void){ 56 56 57 _print Line_("Matdamageice:");58 _print Line_(" mid: " << mid);59 _print Line_(" inputs:");57 _printString_("Matdamageice:" << "\n"); 58 _printString_(" mid: " << mid << "\n"); 59 _printString_(" inputs:" << "\n"); 60 60 inputs->Echo(); 61 _print Line_(" element:");61 _printString_(" element:" << "\n"); 62 62 helement->Echo(); 63 63 } … … 66 66 void Matdamageice::DeepEcho(void){ 67 67 68 _print Line_("Matdamageice:");69 _print Line_(" mid: " << mid);70 _print Line_(" inputs:");68 _printString_("Matdamageice:" << "\n"); 69 _printString_(" mid: " << mid << "\n"); 70 _printString_(" inputs:" << "\n"); 71 71 inputs->DeepEcho(); 72 _print Line_(" element:");72 _printString_(" element:" << "\n"); 73 73 helement->Echo(); 74 74 } -
issm/trunk-jpl/src/c/classes/Materials/Matice.cpp
r15040 r15099 69 69 void Matice::Echo(void){ 70 70 71 _print Line_("Matice:");72 _print Line_(" mid: " << mid);73 _print Line_(" inputs:");71 _printString_("Matice:" << "\n"); 72 _printString_(" mid: " << mid << "\n"); 73 _printString_(" inputs:" << "\n"); 74 74 inputs->Echo(); 75 _print Line_(" element:");75 _printString_(" element:" << "\n"); 76 76 helement->Echo(); 77 77 } … … 80 80 void Matice::DeepEcho(void){ 81 81 82 _print Line_("Matice:");83 _print Line_(" mid: " << mid);84 _print Line_(" inputs:");82 _printString_("Matice:" << "\n"); 83 _printString_(" mid: " << mid << "\n"); 84 _printString_(" inputs:" << "\n"); 85 85 inputs->DeepEcho(); 86 _print Line_(" element:");86 _printString_(" element:" << "\n"); 87 87 helement->Echo(); 88 88 } -
issm/trunk-jpl/src/c/classes/Materials/Matpar.cpp
r15015 r15099 95 95 void Matpar::Echo(void){ 96 96 97 _print Line_("Matpar:");98 _print Line_(" mid: " << mid);99 _print Line_(" rho_ice: " << rho_ice);100 _print Line_(" rho_water: " << rho_water);101 _print Line_(" rho_freshwater: " << rho_freshwater);102 _print Line_(" mu_water: " << mu_water);103 _print Line_(" heatcapacity: " << heatcapacity);104 _print Line_(" thermalconductivity: " << thermalconductivity);105 _print Line_(" latentheat: " << latentheat);106 _print Line_(" beta: " << beta);107 _print Line_(" meltingpoint: " << meltingpoint);108 _print Line_(" referencetemperature: " << referencetemperature);109 _print Line_(" mixed_layer_capacity: " << mixed_layer_capacity);110 _print Line_(" thermal_exchange_velocity: " << thermal_exchange_velocity);111 _print Line_(" g: " << g);112 _print Line_(" desfac: " << desfac);113 _print Line_(" s0p: " << s0p);97 _printString_("Matpar:" << "\n"); 98 _printString_(" mid: " << mid << "\n"); 99 _printString_(" rho_ice: " << rho_ice << "\n"); 100 _printString_(" rho_water: " << rho_water << "\n"); 101 _printString_(" rho_freshwater: " << rho_freshwater << "\n"); 102 _printString_(" mu_water: " << mu_water << "\n"); 103 _printString_(" heatcapacity: " << heatcapacity << "\n"); 104 _printString_(" thermalconductivity: " << thermalconductivity << "\n"); 105 _printString_(" latentheat: " << latentheat << "\n"); 106 _printString_(" beta: " << beta << "\n"); 107 _printString_(" meltingpoint: " << meltingpoint << "\n"); 108 _printString_(" referencetemperature: " << referencetemperature << "\n"); 109 _printString_(" mixed_layer_capacity: " << mixed_layer_capacity << "\n"); 110 _printString_(" thermal_exchange_velocity: " << thermal_exchange_velocity << "\n"); 111 _printString_(" g: " << g << "\n"); 112 _printString_(" desfac: " << desfac << "\n"); 113 _printString_(" s0p: " << s0p << "\n"); 114 114 return; 115 115 } -
issm/trunk-jpl/src/c/classes/Node.cpp
r15040 r15099 155 155 void Node::Echo(void){ 156 156 157 _print Line_("Node:");158 _print Line_(" id: " << id);159 _print Line_(" sid: " << sid);160 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));157 _printString_("Node:" << "\n"); 158 _printString_(" id: " << id << "\n"); 159 _printString_(" sid: " << sid << "\n"); 160 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 161 161 indexing.Echo(); 162 _print Line_(" hvertex: not displayed");163 _print Line_(" inputs: " << inputs);162 _printString_(" hvertex: not displayed" << "\n"); 163 _printString_(" inputs: " << inputs << "\n"); 164 164 165 165 } … … 168 168 void Node::DeepEcho(void){ 169 169 170 _print Line_("Node:");171 _print Line_(" id: " << id);172 _print Line_(" sid: " << sid);173 _print Line_(" analysis_type: " << EnumToStringx(analysis_type));170 _printString_("Node:" << "\n"); 171 _printString_(" id: " << id << "\n"); 172 _printString_(" sid: " << sid << "\n"); 173 _printString_(" analysis_type: " << EnumToStringx(analysis_type) << "\n"); 174 174 indexing.DeepEcho(); 175 _print Line_("Vertex:");175 _printString_("Vertex:" << "\n"); 176 176 hvertex->DeepEcho(); 177 _print Line_(" inputs");177 _printString_(" inputs" << "\n"); 178 178 179 179 } -
issm/trunk-jpl/src/c/classes/Options/GenericOption.h
r15067 r15099 64 64 bool flag=true; 65 65 66 if(flag) _pprint Line_(indent << " name: \"" << name << "\"");67 if(flag) _pprint Line_(indent << " numel: " << numel);68 if(flag) _pprint Line_(indent << " ndims: " << ndims);66 if(flag) _pprintString_(indent << " name: \"" << name << "\"" << "\n"); 67 if(flag) _pprintString_(indent << " numel: " << numel << "\n"); 68 if(flag) _pprintString_(indent << " ndims: " << ndims << "\n"); 69 69 if(size){ 70 70 StringFromSize(cstr,size,ndims); 71 if(flag) _pprint Line_(indent << " size: " << cstr);71 if(flag) _pprintString_(indent << " size: " << cstr << "\n"); 72 72 } 73 else if(flag) _pprint Line_(indent << " size: [empty]");74 _print Line_(indent << " value: " << value);;73 else if(flag) _pprintString_(indent << " size: [empty]" << "\n"); 74 _printString_(indent << " value: " << value << "\n");; 75 75 } /*}}}*/ 76 76 int Id(){/*{{{*/ -
issm/trunk-jpl/src/c/classes/Options/Options.h
r15067 r15099 64 64 } 65 65 else{ 66 if(GetOption(name)) _print Line_("WARNING: option "<<name<<" found but fetched format not consistent, defaulting...");66 if(GetOption(name)) _printString_("WARNING: option "<<name<<" found but fetched format not consistent, defaulting..." << "\n"); 67 67 *pvalue=default_value; 68 68 } -
issm/trunk-jpl/src/c/classes/Params/BoolParam.cpp
r15012 r15099 43 43 void BoolParam::DeepEcho(void){ 44 44 45 _print Line_("BoolParam:");46 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");47 _print Line_(" value: " <<(this->value?"true":"false"));45 _printString_("BoolParam:" << "\n"); 46 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 47 _printString_(" value: " <<(this->value?"true":"false") << "\n"); 48 48 } 49 49 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Params/DataSetParam.cpp
r15012 r15099 44 44 void DataSetParam::DeepEcho(void){ 45 45 46 _print Line_("DataSetParam:");47 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _printString_("DataSetParam:" << "\n"); 47 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 48 48 this->value->Echo(); 49 49 } -
issm/trunk-jpl/src/c/classes/Params/DoubleMatArrayParam.cpp
r15012 r15099 82 82 void DoubleMatArrayParam::Echo(void){ 83 83 84 _print Line_("DoubleMatArrayParam:");85 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");86 _print Line_(" array size: " << this->M);87 _print Line_(" array pointer: " << this->array);84 _printString_("DoubleMatArrayParam:" << "\n"); 85 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 86 _printString_(" array size: " << this->M << "\n"); 87 _printString_(" array pointer: " << this->array << "\n"); 88 88 89 89 } … … 96 96 IssmDouble* matrix=NULL; 97 97 98 _print Line_("DoubleMatArrayParam:");99 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");100 _print Line_(" array size: " << this->M);101 for(i=0;i<M;i++){ 102 _print Line_(" array " << i << " (" << mdim_array[i] << "x" << ndim_array[i] << "):");98 _printString_("DoubleMatArrayParam:" << "\n"); 99 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 100 _printString_(" array size: " << this->M << "\n"); 101 for(i=0;i<M;i++){ 102 _printString_(" array " << i << " (" << mdim_array[i] << "x" << ndim_array[i] << "):" << "\n"); 103 103 matrix=array[i]; 104 104 m=mdim_array[i]; … … 108 108 _printString_(" "); 109 109 for(k=0;k<n;k++)_printString_(*(matrix+n*j+k) << " "); 110 _print Line_("");110 _printString_("" << "\n"); 111 111 } 112 112 } -
issm/trunk-jpl/src/c/classes/Params/DoubleMatParam.cpp
r15012 r15099 43 43 void DoubleMatParam::Echo(void){ 44 44 45 _print Line_("DoubleMatParam:");46 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");47 _print Line_(" matrix size: " << this->M << "x" << this->N);45 _printString_("DoubleMatParam:" << "\n"); 46 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 47 _printString_(" matrix size: " << this->M << "x" << this->N << "\n"); 48 48 49 49 } … … 54 54 int i,j; 55 55 56 _print Line_("DoubleMatParam:");57 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");58 _print Line_(" matrix size: " << this->M << "x" << this->N);56 _printString_("DoubleMatParam:" << "\n"); 57 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 58 _printString_(" matrix size: " << this->M << "x" << this->N << "\n"); 59 59 for(i=0;i<this->M;i++){ 60 60 for(i=0;i<this->N;i++){ 61 _print Line_(i << " " << j << " " << *(this->value+N*i+j));61 _printString_(i << " " << j << " " << *(this->value+N*i+j) << "\n"); 62 62 } 63 63 } -
issm/trunk-jpl/src/c/classes/Params/DoubleParam.cpp
r15012 r15099 40 40 void DoubleParam::DeepEcho(void){ 41 41 42 _print Line_("DoubleParam:");43 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");44 _print Line_(" value: " << this->value);42 _printString_("DoubleParam:" << "\n"); 43 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 44 _printString_(" value: " << this->value << "\n"); 45 45 } 46 46 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Params/DoubleVecParam.cpp
r15012 r15099 42 42 void DoubleVecParam::Echo(void){ 43 43 44 _print Line_("DoubleVecParam:");45 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _print Line_(" vector size: " << this->M);44 _printString_("DoubleVecParam:" << "\n"); 45 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 46 _printString_(" vector size: " << this->M << "\n"); 47 47 48 48 } … … 53 53 int i; 54 54 55 _print Line_("DoubleVecParam:");56 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");57 _print Line_(" vector size: " << this->M);55 _printString_("DoubleVecParam:" << "\n"); 56 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 57 _printString_(" vector size: " << this->M << "\n"); 58 58 for(i=0;i<this->M;i++){ 59 _print Line_(i << " " << this->values[i]);59 _printString_(i << " " << this->values[i] << "\n"); 60 60 } 61 61 } -
issm/trunk-jpl/src/c/classes/Params/FileParam.cpp
r15012 r15099 43 43 void FileParam::DeepEcho(void){ 44 44 45 _print Line_("FileParam:");46 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");47 _print Line_(" value: " << this->value);45 _printString_("FileParam:" << "\n"); 46 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 47 _printString_(" value: " << this->value << "\n"); 48 48 } 49 49 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Params/GenericParam.h
r15012 r15099 39 39 // that any structured P must provide the friend << operator 40 40 void DeepEcho() { 41 _print Line_("GenericParam:");42 _print Line_(" enum: " << myEnumVal << " (" << EnumToStringx(myEnumVal) << ")");43 _print Line_(" value: " << myP);;41 _printString_("GenericParam:" << "\n"); 42 _printString_(" enum: " << myEnumVal << " (" << EnumToStringx(myEnumVal) << ")" << "\n"); 43 _printString_(" value: " << myP << "\n");; 44 44 } 45 45 void Echo() {DeepEcho();}; -
issm/trunk-jpl/src/c/classes/Params/IntMatParam.cpp
r15012 r15099 43 43 void IntMatParam::Echo(void){ 44 44 45 _print Line_("IntMatParam:");46 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");47 _print Line_(" matrix size: " << this->M << "x" << this->N);45 _printString_("IntMatParam:" << "\n"); 46 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 47 _printString_(" matrix size: " << this->M << "x" << this->N << "\n"); 48 48 49 49 } … … 54 54 int i,j; 55 55 56 _print Line_("IntMatParam:");57 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");58 _print Line_(" matrix size: " << this->M << "x" << this->N);56 _printString_("IntMatParam:" << "\n"); 57 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 58 _printString_(" matrix size: " << this->M << "x" << this->N << "\n"); 59 59 for(i=0;i<this->M;i++){ 60 60 for(i=0;i<this->N;i++){ 61 _print Line_("(" << i << "," << j << ") " << *(this->value+N*i+j));61 _printString_("(" << i << "," << j << ") " << *(this->value+N*i+j) << "\n"); 62 62 } 63 63 } -
issm/trunk-jpl/src/c/classes/Params/IntParam.cpp
r15012 r15099 43 43 void IntParam::DeepEcho(void){ 44 44 45 _print Line_("IntParam:");46 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");47 _print Line_(" value: " << this->value);45 _printString_("IntParam:" << "\n"); 46 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 47 _printString_(" value: " << this->value << "\n"); 48 48 } 49 49 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Params/IntVecParam.cpp
r15012 r15099 58 58 void IntVecParam::Echo(void){ 59 59 60 _print Line_("IntVecParam:");61 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");62 _print Line_(" vector size: " << this->M);60 _printString_("IntVecParam:" << "\n"); 61 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 62 _printString_(" vector size: " << this->M << "\n"); 63 63 64 64 } … … 69 69 int i; 70 70 71 _print Line_("IntVecParam:");72 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");73 _print Line_(" vector size: " << this->M);71 _printString_("IntVecParam:" << "\n"); 72 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 73 _printString_(" vector size: " << this->M << "\n"); 74 74 for(i=0;i<this->M;i++){ 75 _print Line_(i << " " << this->values[i]);75 _printString_(i << " " << this->values[i] << "\n"); 76 76 } 77 77 } -
issm/trunk-jpl/src/c/classes/Params/MatrixParam.cpp
r15012 r15099 42 42 void MatrixParam::Echo(void){ 43 43 44 _print Line_("MatrixParam:");45 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");44 _printString_("MatrixParam:" << "\n"); 45 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 46 46 47 47 } … … 50 50 void MatrixParam::DeepEcho(void){ 51 51 52 _print Line_("MatrixParam:");53 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");52 _printString_("MatrixParam:" << "\n"); 53 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 54 54 this->value->Echo(); 55 55 } -
issm/trunk-jpl/src/c/classes/Params/StringArrayParam.cpp
r15012 r15099 70 70 char* string=NULL; 71 71 72 _print Line_("StringArrayParam:");73 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");72 _printString_("StringArrayParam:" << "\n"); 73 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 74 74 for(i=0;i<this->numstrings;i++){ 75 75 string=this->value[i]; 76 _print Line_(" " << i << ": " << string);76 _printString_(" " << i << ": " << string << "\n"); 77 77 } 78 78 } -
issm/trunk-jpl/src/c/classes/Params/StringParam.cpp
r15012 r15099 44 44 /*FUNCTION StringParam::DeepEcho{{{*/ 45 45 void StringParam::DeepEcho(void){ 46 _print Line_("StringParam:");47 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");48 _print Line_(" value: " << this->value);46 _printString_("StringParam:" << "\n"); 47 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 48 _printString_(" value: " << this->value << "\n"); 49 49 } 50 50 /*}}}*/ -
issm/trunk-jpl/src/c/classes/Params/TransientParam.cpp
r15012 r15099 47 47 void TransientParam::Echo(void){ 48 48 49 _print Line_("TransientParam:");50 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");51 _print Line_(" size: " << this->N);49 _printString_("TransientParam:" << "\n"); 50 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 51 _printString_(" size: " << this->N << "\n"); 52 52 53 53 } … … 56 56 void TransientParam::DeepEcho(void){ 57 57 58 _print Line_("TransientParam:");59 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");60 _print Line_(" size: " << this->N);58 _printString_("TransientParam:" << "\n"); 59 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 60 _printString_(" size: " << this->N << "\n"); 61 61 for(int i=0;i<this->N;i++){ 62 _print Line_( "time: " << this->timesteps[i] << " value: " << this->values[i]);62 _printString_( "time: " << this->timesteps[i] << " value: " << this->values[i] << "\n"); 63 63 } 64 64 } -
issm/trunk-jpl/src/c/classes/Params/VectorParam.cpp
r15012 r15099 44 44 void VectorParam::Echo(void){ 45 45 46 _print Line_("VectorParam:");47 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");46 _printString_("VectorParam:" << "\n"); 47 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 48 48 49 49 } … … 52 52 void VectorParam::DeepEcho(void){ 53 53 54 _print Line_("VectorParam:");55 _print Line_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")");54 _printString_("VectorParam:" << "\n"); 55 _printString_(" enum: " << this->enum_type << " (" << EnumToStringx(this->enum_type) << ")" << "\n"); 56 56 value->Echo(); 57 57 } -
issm/trunk-jpl/src/c/classes/Profiler.cpp
r15012 r15099 36 36 void Profiler::Echo(void){ 37 37 38 _print Line_("Profiler:");39 _print Line_(" time tags:");38 _printString_("Profiler:" << "\n"); 39 _printString_(" time tags: " << "\n"); 40 40 this->time->Echo(); 41 41 … … 45 45 void Profiler::DeepEcho(void){ 46 46 47 _print Line_("Profiler:");48 _print Line_(" time tags:");47 _printString_("Profiler:" << "\n"); 48 _printString_(" time tags: " << "\n"); 49 49 this->time->DeepEcho(); 50 50 -
issm/trunk-jpl/src/c/classes/Segment.h
r15067 r15099 52 52 void Echo(void){ 53 53 54 _print Line_("Segment:");55 _print Line_(" eid: " << eid);56 _print Line_(" node 1: " << this->x1 << "|" << this->y1);57 _print Line_(" node 2: " << this->x2 << "|" << this->y2);54 _printString_("Segment:" << "\n"); 55 _printString_(" eid: " << eid << "\n"); 56 _printString_(" node 1: " << this->x1 << "|" << this->y1 << "\n"); 57 _printString_(" node 2: " << this->x2 << "|" << this->y2 << "\n"); 58 58 59 59 } -
issm/trunk-jpl/src/c/classes/Vertex.cpp
r15040 r15099 62 62 void Vertex::Echo(void){ 63 63 64 _print Line_("Vertex:");65 _print Line_(" id: " << id);66 _print Line_(" sid: " << sid);67 _print Line_(" pid: " << pid);68 _print Line_(" x: " << x);69 _print Line_(" y: " << y);70 _print Line_(" z: " << z);71 _print Line_(" sigma: " << sigma);72 _print Line_(" connectivity: " << connectivity);73 _print Line_(" clone: " << clone);64 _printString_("Vertex:" << "\n"); 65 _printString_(" id: " << id << "\n"); 66 _printString_(" sid: " << sid << "\n"); 67 _printString_(" pid: " << pid << "\n"); 68 _printString_(" x: " << x << "\n"); 69 _printString_(" y: " << y << "\n"); 70 _printString_(" z: " << z << "\n"); 71 _printString_(" sigma: " << sigma << "\n"); 72 _printString_(" connectivity: " << connectivity << "\n"); 73 _printString_(" clone: " << clone << "\n"); 74 74 75 75 return; -
issm/trunk-jpl/src/c/classes/gauss/GaussPenta.cpp
r15071 r15099 251 251 void GaussPenta::Echo(void){ 252 252 253 _print Line_("GaussPenta:");254 _print Line_(" numgauss: " << numgauss);253 _printString_("GaussPenta:" << "\n"); 254 _printString_(" numgauss: " << numgauss << "\n"); 255 255 256 256 if (weights){ 257 257 _printString_(" weights = ["); 258 for(int i=0;i<numgauss;i++) _print Line_(" " << weights[i]);259 _print Line_("]");260 } 261 else _print Line_("weights = NULL");258 for(int i=0;i<numgauss;i++) _printString_(" " << weights[i] << "\n"); 259 _printString_("]" << "\n"); 260 } 261 else _printString_("weights = NULL" << "\n"); 262 262 if (coords1){ 263 263 _printString_(" coords1 = ["); 264 for(int i=0;i<numgauss;i++) _print Line_(" " << coords1[i]);265 _print Line_("]");266 } 267 else _print Line_("coords1 = NULL");264 for(int i=0;i<numgauss;i++) _printString_(" " << coords1[i] << "\n"); 265 _printString_("]" << "\n"); 266 } 267 else _printString_("coords1 = NULL" << "\n"); 268 268 if (coords2){ 269 269 _printString_(" coords2 = ["); 270 for(int i=0;i<numgauss;i++) _print Line_(" " << coords2[i]);271 _print Line_("]");272 } 273 else _print Line_("coords2 = NULL");270 for(int i=0;i<numgauss;i++) _printString_(" " << coords2[i] << "\n"); 271 _printString_("]" << "\n"); 272 } 273 else _printString_("coords2 = NULL" << "\n"); 274 274 if (coords3){ 275 275 _printString_(" coords3 = ["); 276 for(int i=0;i<numgauss;i++) _print Line_(" " << coords3[i]);277 _print Line_("]");278 } 279 else _print Line_("coords3 = NULL");276 for(int i=0;i<numgauss;i++) _printString_(" " << coords3[i] << "\n"); 277 _printString_("]" << "\n"); 278 } 279 else _printString_("coords3 = NULL" << "\n"); 280 280 if (coords4){ 281 281 _printString_(" coords4 = ["); 282 for(int i=0;i<numgauss;i++) _print Line_(" " << coords4[i]);283 _print Line_("]");284 } 285 else _print Line_("coords4 = NULL");286 287 _print Line_(" weight = " << weight);288 _print Line_(" coord1 = " << coord1);289 _print Line_(" coord2 = " << coord2);290 _print Line_(" coord3 = " << coord3);291 _print Line_(" coord4 = " << coord4);282 for(int i=0;i<numgauss;i++) _printString_(" " << coords4[i] << "\n"); 283 _printString_("]" << "\n"); 284 } 285 else _printString_("coords4 = NULL" << "\n"); 286 287 _printString_(" weight = " << weight << "\n"); 288 _printString_(" coord1 = " << coord1 << "\n"); 289 _printString_(" coord2 = " << coord2 << "\n"); 290 _printString_(" coord3 = " << coord3 << "\n"); 291 _printString_(" coord4 = " << coord4 << "\n"); 292 292 293 293 } -
issm/trunk-jpl/src/c/classes/gauss/GaussTria.cpp
r15071 r15099 263 263 void GaussTria::Echo(void){ 264 264 265 _print Line_("GaussTria:");266 _print Line_(" numgauss: " << numgauss);265 _printString_("GaussTria:" << "\n"); 266 _printString_(" numgauss: " << numgauss << "\n"); 267 267 268 268 if (weights){ 269 269 _printString_(" weights = ["); 270 for(int i=0;i<numgauss;i++) _print Line_(" " << weights[i]);271 _print Line_("]");272 } 273 else _print Line_("weights = NULL");270 for(int i=0;i<numgauss;i++) _printString_(" " << weights[i] << "\n"); 271 _printString_("]" << "\n"); 272 } 273 else _printString_("weights = NULL" << "\n"); 274 274 if (coords1){ 275 275 _printString_(" coords1 = ["); 276 for(int i=0;i<numgauss;i++) _print Line_(" " << coords1[i]);277 _print Line_("]");278 } 279 else _print Line_("coords1 = NULL");276 for(int i=0;i<numgauss;i++) _printString_(" " << coords1[i] << "\n"); 277 _printString_("]" << "\n"); 278 } 279 else _printString_("coords1 = NULL" << "\n"); 280 280 if (coords2){ 281 281 _printString_(" coords2 = ["); 282 for(int i=0;i<numgauss;i++) _print Line_(" " << coords2[i]);283 _print Line_("]");284 } 285 else _print Line_("coords2 = NULL");282 for(int i=0;i<numgauss;i++) _printString_(" " << coords2[i] << "\n"); 283 _printString_("]" << "\n"); 284 } 285 else _printString_("coords2 = NULL" << "\n"); 286 286 if (coords3){ 287 287 _printString_(" coords3 = ["); 288 for(int i=0;i<numgauss;i++) _print Line_(" " << coords3[i]);289 _print Line_("]");290 } 291 else _print Line_("coords3 = NULL");292 293 _print Line_(" weight = " << weight);294 _print Line_(" coord1 = " << coord1);295 _print Line_(" coord2 = " << coord2);296 _print Line_(" coord3 = " << coord3);288 for(int i=0;i<numgauss;i++) _printString_(" " << coords3[i] << "\n"); 289 _printString_("]" << "\n"); 290 } 291 else _printString_("coords3 = NULL" << "\n"); 292 293 _printString_(" weight = " << weight << "\n"); 294 _printString_(" coord1 = " << coord1 << "\n"); 295 _printString_(" coord2 = " << coord2 << "\n"); 296 _printString_(" coord3 = " << coord3 << "\n"); 297 297 298 298 } -
issm/trunk-jpl/src/c/classes/kriging/ExponentialVariogram.cpp
r15012 r15099 47 47 /*FUNCTION ExponentialVariogram::Echo {{{*/ 48 48 void ExponentialVariogram::Echo(void){ 49 _print Line_("ExponentialVariogram");50 _print Line_(" nugget: " << this->nugget);51 _print Line_(" sill : " << this->sill);52 _print Line_(" range : " << this->range);49 _printString_("ExponentialVariogram" << "\n"); 50 _printString_(" nugget: " << this->nugget << "\n"); 51 _printString_(" sill : " << this->sill << "\n"); 52 _printString_(" range : " << this->range << "\n"); 53 53 } 54 54 /*}}}*/ -
issm/trunk-jpl/src/c/classes/kriging/GaussianVariogram.cpp
r15012 r15099 47 47 /*FUNCTION GaussianVariogram::Echo {{{*/ 48 48 void GaussianVariogram::Echo(void){ 49 _print Line_("GaussianVariogram");50 _print Line_(" nugget: " << this->nugget);51 _print Line_(" sill : " << this->sill);52 _print Line_(" range : " << this->range);49 _printString_("GaussianVariogram" << "\n"); 50 _printString_(" nugget: " << this->nugget << "\n"); 51 _printString_(" sill : " << this->sill << "\n"); 52 _printString_(" range : " << this->range << "\n"); 53 53 } 54 54 /*}}}*/ … … 89 89 gamma = (sill-nugget)*(1.-exp(-h2/(a*range*range))) + nugget; 90 90 91 //if(h2>1000*1000) _print Line_("gamma = " << gamma << " h= " << sqrt(h2));92 _print Line_("h = " << sqrt(h2) << " gamma = " << gamma);91 //if(h2>1000*1000) _printString_("gamma = " << gamma << " h= " << sqrt(h2) << "\n"); 92 _printString_("h = " << sqrt(h2) << " gamma = " << gamma << "\n"); 93 93 return gamma; 94 94 } -
issm/trunk-jpl/src/c/classes/kriging/Observation.cpp
r15012 r15099 35 35 void Observation::Echo(void){ 36 36 37 _print Line_("Observation");38 _print Line_(" index : " << this->index);39 _print Line_(" x : " << this->x);40 _print Line_(" y : " << this->y);41 _print Line_(" xi : "); printbinary(this->xi); _printLine_("");42 _print Line_(" yi : "); printbinary(this->yi); _printLine_("");43 _print Line_(" weight: " << this->weight);44 _print Line_(" value : " << this->value);37 _printString_("Observation" << "\n"); 38 _printString_(" index : " << this->index << "\n"); 39 _printString_(" x : " << this->x << "\n"); 40 _printString_(" y : " << this->y << "\n"); 41 _printString_(" xi : " << "\n"); printbinary(this->xi); _printString_("\n"); 42 _printString_(" yi : " << "\n"); printbinary(this->yi); _printString_("\n"); 43 _printString_(" weight: " << this->weight << "\n"); 44 _printString_(" value : " << this->value << "\n"); 45 45 } 46 46 /*}}}*/ -
issm/trunk-jpl/src/c/classes/kriging/Observations.cpp
r15067 r15099 107 107 } 108 108 } 109 _pprint Line_("done");110 _pprint Line_("Initial number of observations: " << n);111 _pprint Line_(" Final number of observations: " << this->quadtree->NbObs);109 _pprintString_("done" << "\n"); 110 _pprintString_("Initial number of observations: " << n << "\n"); 111 _pprintString_(" Final number of observations: " << this->quadtree->NbObs << "\n"); 112 112 } 113 113 /*}}}*/ -
issm/trunk-jpl/src/c/classes/kriging/PowerVariogram.cpp
r15012 r15099 48 48 /*FUNCTION PowerVariogram::Echo {{{*/ 49 49 void PowerVariogram::Echo(void){ 50 _print Line_("PowerVariogram");51 _print Line_(" nugget: " << this->nugget);52 _print Line_(" slope : " << this->slope);53 _print Line_(" power : " << this->power);50 _printString_("PowerVariogram" << "\n"); 51 _printString_(" nugget: " << this->nugget << "\n"); 52 _printString_(" slope : " << this->slope << "\n"); 53 _printString_(" power : " << this->power << "\n"); 54 54 } 55 55 /*}}}*/ … … 85 85 gamma = this->nugget + this->slope*pow(h,this->power); 86 86 87 //if(h>1000) _print Line_("gamma = " << gamma << " h=" << h);87 //if(h>1000) _printString_("gamma = " << gamma << " h=" << h << "\n"); 88 88 return gamma; 89 89 } -
issm/trunk-jpl/src/c/classes/kriging/Quadtree.cpp
r15012 r15099 297 297 void Quadtree::Echo(void){ 298 298 299 _print Line_("Quadtree:");300 _print Line_(" MaxDepth = " << this->MaxDepth);301 _print Line_(" NbQuadtreeBox = " << this->NbQuadtreeBox);302 _print Line_(" NbObs = " << this->NbObs);303 _print Line_(" root = " << this->root);299 _printString_("Quadtree:" << "\n"); 300 _printString_(" MaxDepth = " << this->MaxDepth << "\n"); 301 _printString_(" NbQuadtreeBox = " << this->NbQuadtreeBox << "\n"); 302 _printString_(" NbObs = " << this->NbObs << "\n"); 303 _printString_(" root = " << this->root << "\n"); 304 304 305 305 }/*}}}*/ … … 307 307 void Quadtree::DeepEcho(void){ 308 308 309 _print Line_("Quadtree:");310 _print Line_(" MaxDepth = " << this->MaxDepth);311 _print Line_(" NbQuadtreeBox = " << this->NbQuadtreeBox);312 _print Line_(" NbObs = " << this->NbObs);313 _print Line_(" root = " << this->root);309 _printString_("Quadtree:" << "\n"); 310 _printString_(" MaxDepth = " << this->MaxDepth << "\n"); 311 _printString_(" NbQuadtreeBox = " << this->NbQuadtreeBox << "\n"); 312 _printString_(" NbObs = " << this->NbObs << "\n"); 313 _printString_(" root = " << this->root << "\n"); 314 314 boxcontainer->Echo(); 315 315 … … 512 512 void Quadtree::QuadtreeBox::Echo(void){ 513 513 514 _print Line_("QuadtreeBox:");515 _print Line_(" nbitems = " << this->nbitems);516 _print Line_(" xcenter = " << this->xcenter);517 _print Line_(" ycenter = " << this->ycenter);518 _print Line_(" length = " << this->length);514 _printString_("QuadtreeBox:" << "\n"); 515 _printString_(" nbitems = " << this->nbitems << "\n"); 516 _printString_(" xcenter = " << this->xcenter << "\n"); 517 _printString_(" ycenter = " << this->ycenter << "\n"); 518 _printString_(" length = " << this->length << "\n"); 519 519 520 520 }/*}}}*/ -
issm/trunk-jpl/src/c/classes/kriging/SphericalVariogram.cpp
r15012 r15099 47 47 /*FUNCTION SphericalVariogram::Echo {{{*/ 48 48 void SphericalVariogram::Echo(void){ 49 _print Line_("SphericalVariogram");50 _print Line_(" nugget: " << this->nugget);51 _print Line_(" sill : " << this->sill);52 _print Line_(" range : " << this->range);49 _printString_("SphericalVariogram" << "\n"); 50 _printString_(" nugget: " << this->nugget << "\n"); 51 _printString_(" sill : " << this->sill << "\n"); 52 _printString_(" range : " << this->range << "\n"); 53 53 } 54 54 /*}}}*/ -
issm/trunk-jpl/src/c/classes/matrix/ElementMatrix.cpp
r14996 r15099 377 377 378 378 int i,j; 379 _print Line_("Element Matrix echo:");380 _print Line_(" nrows: " << this->nrows);381 _print Line_(" ncols: " << this->ncols);382 _print Line_(" dofsymmetrical: " << (dofsymmetrical?"true":"false"));383 384 _print Line_(" values:");379 _printString_("Element Matrix echo:" << "\n"); 380 _printString_(" nrows: " << this->nrows << "\n"); 381 _printString_(" ncols: " << this->ncols << "\n"); 382 _printString_(" dofsymmetrical: " << (dofsymmetrical?"true":"false") << "\n"); 383 384 _printString_(" values:" << "\n"); 385 385 for(i=0;i<nrows;i++){ 386 386 _printString_(setw(4) << right << i << ": "); 387 387 for(j=0;j<ncols;j++) _printString_( " " << setw(11) << setprecision (5) << right << values[i*ncols+j]); 388 _print Line_("");388 _printString_("" << "\n"); 389 389 } 390 390 391 391 _printString_(" gglobaldoflist (" << gglobaldoflist << "): "); 392 if(gglobaldoflist) for(i=0;i<nrows;i++) _printString_(" " << gglobaldoflist[i] ); _printLine_("");393 394 _print Line_(" row_fsize: " << row_fsize);392 if(gglobaldoflist) for(i=0;i<nrows;i++) _printString_(" " << gglobaldoflist[i] << "\n"); _printString_("" << "\n"); 393 394 _printString_(" row_fsize: " << row_fsize << "\n"); 395 395 _printString_(" row_flocaldoflist (" << row_flocaldoflist << "): "); 396 if(row_flocaldoflist) for(i=0;i<row_fsize;i++) _printString_(" " << row_flocaldoflist[i] ); _printLine_("");396 if(row_flocaldoflist) for(i=0;i<row_fsize;i++) _printString_(" " << row_flocaldoflist[i] << "\n"); _printString_(" " << "\n"); 397 397 _printString_(" row_fglobaldoflist (" << row_fglobaldoflist << "): "); 398 if(row_fglobaldoflist) for(i=0;i<row_fsize;i++) _printString_(" " << row_fglobaldoflist[i] ); _printLine_("");399 400 _print Line_(" row_ssize: " << row_ssize);398 if(row_fglobaldoflist) for(i=0;i<row_fsize;i++) _printString_(" " << row_fglobaldoflist[i] << "\n"); _printString_(" " << "\n"); 399 400 _printString_(" row_ssize: " << row_ssize << "\n"); 401 401 _printString_(" row_slocaldoflist (" << row_slocaldoflist << "): "); 402 if(row_slocaldoflist) for(i=0;i<row_ssize;i++) _printString_(" " << row_slocaldoflist[i] ); _printLine_("");402 if(row_slocaldoflist) for(i=0;i<row_ssize;i++) _printString_(" " << row_slocaldoflist[i] << "\n"); _printString_(" " << "\n"); 403 403 _printString_(" row_sglobaldoflist (" << row_sglobaldoflist << "): "); 404 if(row_sglobaldoflist) for(i=0;i<row_ssize;i++) _printString_(" " << row_sglobaldoflist[i] ); _printLine_("");404 if(row_sglobaldoflist) for(i=0;i<row_ssize;i++) _printString_(" " << row_sglobaldoflist[i] << "\n"); _printString_(" " << "\n"); 405 405 406 406 if(!dofsymmetrical){ 407 _print Line_(" col_fsize: " << col_fsize);407 _printString_(" col_fsize: " << col_fsize << "\n"); 408 408 _printString_(" col_flocaldoflist (" << col_flocaldoflist << "): "); 409 if(col_flocaldoflist) for(i=0;i<col_fsize;i++) _printString_(" " << col_flocaldoflist[i] ); _printLine_("");409 if(col_flocaldoflist) for(i=0;i<col_fsize;i++) _printString_(" " << col_flocaldoflist[i] << "\n"); _printString_(" " << "\n"); 410 410 _printString_(" col_fglobaldoflist (" << col_fglobaldoflist << "): "); 411 if(col_fglobaldoflist) for(i=0;i<col_fsize;i++) _printString_(" " << col_fglobaldoflist[i] ); _printLine_("");412 413 _print Line_(" col_ssize: " << col_ssize);411 if(col_fglobaldoflist) for(i=0;i<col_fsize;i++) _printString_(" " << col_fglobaldoflist[i] << "\n"); _printString_(" " << "\n"); 412 413 _printString_(" col_ssize: " << col_ssize << "\n"); 414 414 _printString_(" col_slocaldoflist (" << col_slocaldoflist << "): "); 415 if(col_slocaldoflist) for(i=0;i<col_ssize;i++) _printString_(" " << col_slocaldoflist[i] ); _printLine_("");415 if(col_slocaldoflist) for(i=0;i<col_ssize;i++) _printString_(" " << col_slocaldoflist[i] << "\n"); _printString_(" " << "\n"); 416 416 _printString_(" col_sglobaldoflist (" << col_sglobaldoflist << "): "); 417 if(col_sglobaldoflist) for(i=0;i<col_ssize;i++) _printString_(" " << col_sglobaldoflist[i] ); _printLine_("");417 if(col_sglobaldoflist) for(i=0;i<col_ssize;i++) _printString_(" " << col_sglobaldoflist[i] << "\n"); _printString_(" " << "\n"); 418 418 } 419 419 } -
issm/trunk-jpl/src/c/classes/matrix/ElementVector.cpp
r14996 r15099 219 219 int i; 220 220 221 _print Line_("Element Vector echo:");222 _print Line_(" nrows: " << nrows);223 _print Line_(" values:");221 _printString_("Element Vector echo:" << "\n"); 222 _printString_(" nrows: " << nrows << "\n"); 223 _printString_(" values:" << "\n"); 224 224 for(i=0;i<nrows;i++){ 225 _print Line_(setw(4) << right << i << ": " << setw(10) << values[i]);225 _printString_(setw(4) << right << i << ": " << setw(10) << values[i] << "\n"); 226 226 } 227 227 228 228 _printString_(" gglobaldoflist (" << gglobaldoflist << "): "); 229 229 if(gglobaldoflist) for(i=0;i<nrows;i++) _printString_(" " << gglobaldoflist[i] ); 230 _print Line_("");231 232 _print Line_(" fsize: " << fsize);230 _printString_(" " << "\n"); 231 232 _printString_(" fsize: " << fsize << "\n"); 233 233 _printString_(" flocaldoflist (" << flocaldoflist << "): "); 234 234 if(flocaldoflist) for(i=0;i<fsize;i++) _printString_(" " << flocaldoflist[i] ); 235 _print Line_("");235 _printString_(" " << "\n"); 236 236 _printString_(" fglobaldoflist (" << fglobaldoflist << "): "); 237 237 if(fglobaldoflist) for(i=0;i<fsize;i++) _printString_(" " << fglobaldoflist[i] ); 238 _print Line_("");238 _printString_(" " << "\n"); 239 239 } 240 240 /*}}}*/ -
issm/trunk-jpl/src/c/datastructures/DataSet.cpp
r15067 r15099 130 130 if(this==NULL)_error_("trying to echo a NULL dataset"); 131 131 132 _pprint Line_("DataSet echo: " << objects.size() << " objects");132 _pprintString_("DataSet echo: " << objects.size() << " objects" << "\n"); 133 133 134 134 for ( object=objects.begin() ; object < objects.end(); object++ ){ … … 147 147 if(this==NULL)_error_("trying to echo a NULL dataset"); 148 148 149 _pprint Line_("DataSet echo: " << objects.size() << " objects");149 _pprintString_("DataSet echo: " << objects.size() << " objects" << "\n"); 150 150 151 151 for ( object=objects.begin() ; object < objects.end(); object++ ){ -
issm/trunk-jpl/src/c/kml/KMLFileReadUtils.cpp
r15069 r15099 133 133 134 134 // if (itag) 135 // _pprint Line_("tag buffer (length=" << ibuf << "):");135 // _pprintString_("tag buffer (length=" << ibuf << "):" << "\n"); 136 136 // else if (ifield) 137 // _pprint Line_("field buffer (length=" << ibuf << "):");138 // _pprint Line_(buffer);137 // _pprintString_("field buffer (length=" << ibuf << "):" << "\n"); 138 // _pprintString_(buffer << "\n"); 139 139 140 140 if (!ibuf) … … 199 199 } 200 200 201 // _pprint Line_("comment buffer (length=" << ibuf << "):");202 // _pprint Line_(buffer);201 // _pprintString_("comment buffer (length=" << ibuf << "):" << "\n"); 202 // _pprintString_(buffer << "\n"); 203 203 204 204 if (!ibuf) … … 265 265 266 266 ktokn=strtok(ktagi,"< >"); 267 // _pprint Line_("KMLFileTagName -- initial token=\"" << ktokn << "\".");267 // _pprintString_("KMLFileTagName -- initial token=\"" << ktokn << "\"." << "\n"); 268 268 269 269 if (!pname) { … … 275 275 276 276 if (maxlen && (maxlen < strlen(ktokn))) { 277 _pprint Line_("KMLFileTagName -- string field too short for " << ktag << ".");278 _pprint Line_("KMLFileTagName -- \"" << ktokn << "\" truncated to " << maxlen << " characters.");277 _pprintString_("KMLFileTagName -- string field too short for " << ktag << "." << "\n"); 278 _pprintString_("KMLFileTagName -- \"" << ktokn << "\" truncated to " << maxlen << " characters." << "\n"); 279 279 strncpy(pname,ktokn,maxlen); 280 280 } … … 311 311 /* return first non blank and move past subsequent blank */ 312 312 ktokn=strtok(ktagi," "); 313 // _pprint Line_("KMLFileTagAttrib -- initial token=\"" << ktokn << "\".");313 // _pprintString_("KMLFileTagAttrib -- initial token=\"" << ktokn << "\"." << "\n"); 314 314 315 315 /* return next non " =?/>" and move past subsequent " =?/>" */ … … 318 318 /* return next non quote and move past subsequent quote */ 319 319 ktokv=strtok(NULL,quote); 320 // _pprint Line_("KMLFileTagAttrib -- attribute " << ktokn << "=\"" << ktokv << "\".");320 // _pprintString_("KMLFileTagAttrib -- attribute " << ktokn << "=\"" << ktokv << "\"." << "\n"); 321 321 322 322 /* add the attribute to the dataset */ … … 334 334 (!strncmp(&ktag[0],"<" ,1) && !strncmp(&ktag[strlen(ktag)-2],"/>",2))) 335 335 isolo=1; 336 // _pprint Line_("KMLFileTagAttrib -- isolo=" << isolo << ".");336 // _pprintString_("KMLFileTagAttrib -- isolo=" << isolo << "." << "\n"); 337 337 338 338 return(isolo); … … 368 368 xDelete<char>(kstr); 369 369 370 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=" << *pival << ".");370 // _pprintString_("KMLFileTokenParse -- " << ktag << "=" << *pival << "." << "\n"); 371 371 372 372 return(0); … … 402 402 xDelete<char>(kstr); 403 403 404 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=" << (*pbval ? "true" : "false") << ".");404 // _pprintString_("KMLFileTokenParse -- " << ktag << "=" << (*pbval ? "true" : "false") << "." << "\n"); 405 405 406 406 return(0); … … 439 439 440 440 if (maxlen && (maxlen < strlen(kstr))) { 441 _pprint Line_("KMLFileTokenParse -- string field too short for " << ktag << ".");442 _pprint Line_("KMLFileTokenParse -- \"" << kstr << "\" truncated to " << maxlen << " characters.");441 _pprintString_("KMLFileTokenParse -- string field too short for " << ktag << "." << "\n"); 442 _pprintString_("KMLFileTokenParse -- \"" << kstr << "\" truncated to " << maxlen << " characters." << "\n"); 443 443 strncpy(pstr,kstr,maxlen); 444 444 } … … 463 463 xDelete<char>(kstr); 464 464 465 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=\"" << pstr << "\".");465 // _pprintString_("KMLFileTokenParse -- " << ktag << "=\"" << pstr << "\"." << "\n"); 466 466 467 467 return(pstr); … … 497 497 xDelete<char>(kstr); 498 498 499 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=" << *pfval << ".");499 // _pprintString_("KMLFileTokenParse -- " << ktag << "=" << *pfval << "." << "\n"); 500 500 501 501 return(0); … … 531 531 xDelete<char>(kstr); 532 532 533 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=" << *pdval << ".");533 // _pprintString_("KMLFileTokenParse -- " << ktag << "=" << *pdval << "." << "\n"); 534 534 535 535 return(0); … … 595 595 xDelete<char>(kstr); 596 596 597 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=...");597 // _pprintString_("KMLFileTokenParse -- " << ktag << "=..." << "\n"); 598 598 // for (j=0; j<=i; j++) 599 // _pprint Line_(" [" << j << "]: " << (*pdval)[j] << "g");599 // _pprintString_(" [" << j << "]: " << (*pdval)[j] << "g" << "\n"); 600 600 601 601 return(0); … … 651 651 652 652 if ((i+1) % n) 653 _pprint Line_("KMLFileTokenParse -- Double [m x n] field for " << ktag << " does not have multiple of n values.");653 _pprintString_("KMLFileTokenParse -- Double [m x n] field for " << ktag << " does not have multiple of n values." << "\n"); 654 654 655 655 /* get additional token and compare to closing tag */ … … 665 665 xDelete<char>(kstr); 666 666 667 // _pprint Line_("KMLFileTokenParse -- " << ktag << "=...");667 // _pprintString_("KMLFileTokenParse -- " << ktag << "=..." << "\n"); 668 668 // for (j=0; j<=i; j++) 669 // _pprint Line_(" [" << j << "]: " << (*pdval)[j] << "g");669 // _pprintString_(" [" << j << "]: " << (*pdval)[j] << "g" << "\n"); 670 670 671 671 return(0); … … 681 681 opening tag, must find corresponding closing tag */ 682 682 683 _pprint Line_("KMLFileTagSkip -- input tag " << ktag << ".");683 _pprintString_("KMLFileTagSkip -- input tag " << ktag << "." << "\n"); 684 684 685 685 /* if next token is a closing tag, compare to input */ … … 690 690 (kstr[1] == '/') && 691 691 (!strncmp(&(kstr[2]),&(ktag[1]),(strcspn(ktag," >")-1)/sizeof(char)))) { 692 _pprint Line_("KMLFileTagSkip -- closing tag " << kstr << ".");692 _pprintString_("KMLFileTagSkip -- closing tag " << kstr << "." << "\n"); 693 693 xDelete<char>(kstr); 694 694 return(0); … … 699 699 else if ((kstr[0] == '<') && 700 700 (kstr[1] != '/')) { 701 _pprint Line_("KMLFileTagSkip -- opening tag " << kstr << ".");701 _pprintString_("KMLFileTagSkip -- opening tag " << kstr << "." << "\n"); 702 702 KMLFileTagSkip(kstr, 703 703 fid); -
issm/trunk-jpl/src/c/kml/KML_Attribute.cpp
r15068 r15099 43 43 for (i=0;i<10-strlen(name);i++) 44 44 if(flag) _pprintString_(" "); 45 if(flag) _pprint Line_(name << ": \"" << value << "\"");45 if(flag) _pprintString_(name << ": \"" << value << "\"" << "\n"); 46 46 47 47 return; … … 67 67 for (i=0;i<10-strlen(name);i++) 68 68 if(flag) _pprintString_(" "); 69 if(flag) _pprint Line_(name << ": \"" << value << "\"");69 if(flag) _pprintString_(name << ": \"" << value << "\"" << "\n"); 70 70 71 71 return; -
issm/trunk-jpl/src/c/kml/KML_ColorStyle.cpp
r15068 r15099 42 42 KML_SubStyle::Echo(); 43 43 44 if(flag) _pprint Line_(" color: " << color);45 if(flag) _pprint Line_(" colormode: " << colormode);44 if(flag) _pprintString_(" color: " << color << "\n"); 45 if(flag) _pprintString_(" colormode: " << colormode << "\n"); 46 46 47 47 return; … … 65 65 KML_SubStyle::DeepEcho(indent); 66 66 67 if(flag) _pprint Line_(indent << " color: " << color);68 if(flag) _pprint Line_(indent << " colormode: " << colormode);67 if(flag) _pprintString_(indent << " color: " << color << "\n"); 68 if(flag) _pprintString_(indent << " colormode: " << colormode << "\n"); 69 69 } 70 70 /*}}}*/ -
issm/trunk-jpl/src/c/kml/KML_Comment.cpp
r15068 r15099 38 38 39 39 if(flag) _pprintString_(" "); 40 if(flag) _pprint Line_(value);40 if(flag) _pprintString_(value << "\n"); 41 41 42 42 return; … … 59 59 60 60 if(flag) _pprintString_(indent << " "); 61 if(flag) _pprint Line_(value);61 if(flag) _pprintString_(value << "\n"); 62 62 63 63 return; -
issm/trunk-jpl/src/c/kml/KML_Container.cpp
r15068 r15099 47 47 KML_Feature::Echo(); 48 48 49 if(flag) _pprint Line_(" feature: (size=" << feature->Size() << ")");49 if(flag) _pprintString_(" feature: (size=" << feature->Size() << ")" << "\n"); 50 50 51 51 return; … … 78 78 if (feature->Size()) 79 79 for (i=0; i<feature->Size(); i++) { 80 if(flag) _pprint Line_(indent << " feature: -------- begin [" << i << "] --------");80 if(flag) _pprintString_(indent << " feature: -------- begin [" << i << "] --------" << "\n"); 81 81 ((KML_Feature *)feature->GetObjectByOffset(i))->DeepEcho(indent2); 82 if(flag) _pprint Line_(indent << " feature: -------- end [" << i << "] --------");82 if(flag) _pprintString_(indent << " feature: -------- end [" << i << "] --------" << "\n"); 83 83 } 84 84 else 85 if(flag) _pprint Line_(indent << " feature: [empty]");85 if(flag) _pprintString_(indent << " feature: [empty]" << "\n"); 86 86 87 87 return; -
issm/trunk-jpl/src/c/kml/KML_Document.cpp
r15068 r15099 38 38 bool flag=true; 39 39 40 if(flag) _pprint Line_("KML_Document:");40 if(flag) _pprintString_("KML_Document:" << "\n"); 41 41 KML_Container::Echo(); 42 42 … … 59 59 bool flag=true; 60 60 61 if(flag) _pprint Line_(indent << "KML_Document:");61 if(flag) _pprintString_(indent << "KML_Document:" << "\n"); 62 62 KML_Container::DeepEcho(indent); 63 63 -
issm/trunk-jpl/src/c/kml/KML_Feature.cpp
r15068 r15099 60 60 KML_Object::Echo(); 61 61 62 if(flag) _pprint Line_(" name: \"" << name << "\"");63 if(flag) _pprint Line_(" visibility: " << (visibility ? "true" : "false"));64 if(flag) _pprint Line_(" open: " << (open ? "true" : "false"));65 if(flag) _pprint Line_(" snippet: \"" << snippet << "\"");66 if(flag) _pprint Line_(" descript: \"" << descript << "\"");67 if(flag) _pprint Line_(" styleurl: \"" << styleurl << "\"");68 if(flag) _pprint Line_(" style: (size=" << style->Size() << ")");62 if(flag) _pprintString_(" name: \"" << name << "\"" << "\n"); 63 if(flag) _pprintString_(" visibility: " << (visibility ? "true" : "false") << "\n"); 64 if(flag) _pprintString_(" open: " << (open ? "true" : "false") << "\n"); 65 if(flag) _pprintString_(" snippet: \"" << snippet << "\"" << "\n"); 66 if(flag) _pprintString_(" descript: \"" << descript << "\"" << "\n"); 67 if(flag) _pprintString_(" styleurl: \"" << styleurl << "\"" << "\n"); 68 if(flag) _pprintString_(" style: (size=" << style->Size() << ")" << "\n"); 69 69 70 70 return; … … 90 90 KML_Object::DeepEcho(indent); 91 91 92 if(flag) _pprint Line_(indent << " name: \"" << name << "\"");93 if(flag) _pprint Line_(indent << " visibility: " << (visibility ? "true" : "false"));94 if(flag) _pprint Line_(indent << " open: " << (open ? "true" : "false"));95 if(flag) _pprint Line_(indent << " snippet: \"" << snippet << "\"");96 if(flag) _pprint Line_(indent << " descript: \"" << descript << "\"");97 if(flag) _pprint Line_(indent << " styleurl: \"" << styleurl << "\"");92 if(flag) _pprintString_(indent << " name: \"" << name << "\"" << "\n"); 93 if(flag) _pprintString_(indent << " visibility: " << (visibility ? "true" : "false") << "\n"); 94 if(flag) _pprintString_(indent << " open: " << (open ? "true" : "false") << "\n"); 95 if(flag) _pprintString_(indent << " snippet: \"" << snippet << "\"" << "\n"); 96 if(flag) _pprintString_(indent << " descript: \"" << descript << "\"" << "\n"); 97 if(flag) _pprintString_(indent << " styleurl: \"" << styleurl << "\"" << "\n"); 98 98 99 99 /* loop over any styles for the feature */ … … 104 104 if (style->Size()) 105 105 for (i=0; i<style->Size(); i++) { 106 if(flag) _pprint Line_(indent << " style: -------- begin [" << i << "] --------");106 if(flag) _pprintString_(indent << " style: -------- begin [" << i << "] --------" << "\n"); 107 107 ((KML_Style *)style->GetObjectByOffset(i))->DeepEcho(indent2); 108 if(flag) _pprint Line_(indent << " style: -------- end [" << i << "] --------");108 if(flag) _pprintString_(indent << " style: -------- end [" << i << "] --------" << "\n"); 109 109 } 110 110 else 111 if(flag) _pprint Line_(indent << " style: [empty]");111 if(flag) _pprintString_(indent << " style: [empty]" << "\n"); 112 112 113 113 return; -
issm/trunk-jpl/src/c/kml/KML_File.cpp
r15068 r15099 39 39 bool flag=true; 40 40 41 if(flag) _pprint Line_("KML_File:");41 if(flag) _pprintString_("KML_File:" << "\n"); 42 42 KML_Object::Echo(); 43 43 … … 60 60 bool flag=true; 61 61 62 if(flag) _pprint Line_(indent << "KML_File:");62 if(flag) _pprintString_(indent << "KML_File:" << "\n"); 63 63 KML_Object::DeepEcho(indent); 64 64 -
issm/trunk-jpl/src/c/kml/KML_Folder.cpp
r15068 r15099 38 38 bool flag=true; 39 39 40 if(flag) _pprint Line_("KML_Folder:");40 if(flag) _pprintString_("KML_Folder:" << "\n"); 41 41 KML_Container::Echo(); 42 42 … … 59 59 bool flag=true; 60 60 61 if(flag) _pprint Line_(indent << "KML_Folder:");61 if(flag) _pprintString_(indent << "KML_Folder:" << "\n"); 62 62 KML_Container::DeepEcho(indent); 63 63 -
issm/trunk-jpl/src/c/kml/KML_GroundOverlay.cpp
r15068 r15099 44 44 void KML_GroundOverlay::Echo(){ 45 45 46 _print Line_("KML_GroundOverlay:");46 _printString_("KML_GroundOverlay:" << "\n"); 47 47 KML_Overlay::Echo(); 48 48 49 _print Line_(" altitude: " << altitude);50 _print Line_(" altmode: " << altmode);51 _print Line_(" llbox: " << llbox);49 _printString_(" altitude: " << altitude << "\n"); 50 _printString_(" altmode: " << altmode << "\n"); 51 _printString_(" llbox: " << llbox << "\n"); 52 52 } 53 53 /*}}}*/ … … 67 67 char indent2[81]; 68 68 69 _print Line_(indent << "KML_GroundOverlay:");69 _printString_(indent << "KML_GroundOverlay:" << "\n"); 70 70 KML_Overlay::DeepEcho(indent); 71 71 … … 73 73 strcat(indent2," "); 74 74 75 _print Line_(indent<<" altitude: " << altitude);76 _print Line_(indent<<" altmode: " << altmode);75 _printString_(indent<<" altitude: " << altitude << "\n"); 76 _printString_(indent<<" altmode: " << altmode << "\n"); 77 77 if (llbox) 78 78 llbox->DeepEcho(indent2); 79 79 else 80 _print Line_(indent<<" llbox: " << llbox);80 _printString_(indent<<" llbox: " << llbox << "\n"); 81 81 } 82 82 /*}}}*/ -
issm/trunk-jpl/src/c/kml/KML_Icon.cpp
r15068 r15099 45 45 bool flag=true; 46 46 47 if(flag) _pprint Line_("KML_Icon:");47 if(flag) _pprintString_("KML_Icon:" << "\n"); 48 48 KML_Object::Echo(); 49 49 50 if(flag) _pprint Line_(" href: \"" << href << "\"");51 if(flag) _pprint Line_(" refmode: \"" << refmode << "\"");52 if(flag) _pprint Line_(" refint: " << refint);53 if(flag) _pprint Line_(" vrefmode: \"" << vrefmode << "\"");54 if(flag) _pprint Line_(" vreftime: " << vreftime);55 if(flag) _pprint Line_(" vboundsc: " << vboundsc);56 if(flag) _pprint Line_(" vformat: \"" << vformat << "\"");57 if(flag) _pprint Line_(" hquery: \"" << hquery << "\"");50 if(flag) _pprintString_(" href: \"" << href << "\"" << "\n"); 51 if(flag) _pprintString_(" refmode: \"" << refmode << "\"" << "\n"); 52 if(flag) _pprintString_(" refint: " << refint << "\n"); 53 if(flag) _pprintString_(" vrefmode: \"" << vrefmode << "\"" << "\n"); 54 if(flag) _pprintString_(" vreftime: " << vreftime << "\n"); 55 if(flag) _pprintString_(" vboundsc: " << vboundsc << "\n"); 56 if(flag) _pprintString_(" vformat: \"" << vformat << "\"" << "\n"); 57 if(flag) _pprintString_(" hquery: \"" << hquery << "\"" << "\n"); 58 58 59 59 return; … … 75 75 bool flag=true; 76 76 77 if(flag) _pprint Line_(indent << "KML_Icon:");77 if(flag) _pprintString_(indent << "KML_Icon:" << "\n"); 78 78 KML_Object::DeepEcho(indent); 79 79 80 if(flag) _pprint Line_(indent << " href: \"" << href << "\"");81 if(flag) _pprint Line_(indent << " refmode: \"" << refmode << "\"");82 if(flag) _pprint Line_(indent << " refint: " << refint);83 if(flag) _pprint Line_(indent << " vrefmode: \"" << vrefmode << "\"");84 if(flag) _pprint Line_(indent << " vreftime: " << vreftime);85 if(flag) _pprint Line_(indent << " vboundsc: " << vboundsc);86 if(flag) _pprint Line_(indent << " vformat: \"" << vformat << "\"");87 if(flag) _pprint Line_(indent << " hquery: \"" << hquery << "\"");80 if(flag) _pprintString_(indent << " href: \"" << href << "\"" << "\n"); 81 if(flag) _pprintString_(indent << " refmode: \"" << refmode << "\"" << "\n"); 82 if(flag) _pprintString_(indent << " refint: " << refint << "\n"); 83 if(flag) _pprintString_(indent << " vrefmode: \"" << vrefmode << "\"" << "\n"); 84 if(flag) _pprintString_(indent << " vreftime: " << vreftime << "\n"); 85 if(flag) _pprintString_(indent << " vboundsc: " << vboundsc << "\n"); 86 if(flag) _pprintString_(indent << " vformat: \"" << vformat << "\"" << "\n"); 87 if(flag) _pprintString_(indent << " hquery: \"" << hquery << "\"" << "\n"); 88 88 89 89 return; -
issm/trunk-jpl/src/c/kml/KML_LatLonBox.cpp
r15068 r15099 40 40 void KML_LatLonBox::Echo(){ 41 41 42 _print Line_("KML_LatLonBox:");42 _printString_("KML_LatLonBox:" << "\n"); 43 43 KML_Object::Echo(); 44 44 45 _print Line_(" north: " << north);46 _print Line_(" south: " << south);47 _print Line_(" east: " << east);48 _print Line_(" west: " << west);49 _print Line_(" rotation: " << rotation);45 _printString_(" north: " << north << "\n"); 46 _printString_(" south: " << south << "\n"); 47 _printString_(" east: " << east << "\n"); 48 _printString_(" west: " << west << "\n"); 49 _printString_(" rotation: " << rotation << "\n"); 50 50 } 51 51 /*}}}*/ … … 63 63 void KML_LatLonBox::DeepEcho(const char* indent){ 64 64 65 _print Line_(indent << "KML_LatLonBox:");65 _printString_(indent << "KML_LatLonBox:" << "\n"); 66 66 KML_Object::DeepEcho(indent); 67 67 68 _print Line_(" north: " << north);69 _print Line_(" south: " << south);70 _print Line_(" east: " << east);71 _print Line_(" west: " << west);72 _print Line_(" rotation: " << rotation);68 _printString_(" north: " << north << "\n"); 69 _printString_(" south: " << south << "\n"); 70 _printString_(" east: " << east << "\n"); 71 _printString_(" west: " << west << "\n"); 72 _printString_(" rotation: " << rotation << "\n"); 73 73 } 74 74 /*}}}*/ -
issm/trunk-jpl/src/c/kml/KML_LineString.cpp
r15069 r15099 46 46 bool flag=true; 47 47 48 if(flag) _pprint Line_("KML_LineString:");48 if(flag) _pprintString_("KML_LineString:" << "\n"); 49 49 KML_Geometry::Echo(); 50 50 51 if(flag) _pprint Line_(" extrude: " << (extrude ? "true" : "false"));52 if(flag) _pprint Line_(" tessellate: " << (tessellate ? "true" : "false"));53 if(flag) _pprint Line_(" altmode: \"" << altmode << "\"");54 if(flag) _pprint Line_(" coords: (ncoord=" << ncoord << ")");51 if(flag) _pprintString_(" extrude: " << (extrude ? "true" : "false") << "\n"); 52 if(flag) _pprintString_(" tessellate: " << (tessellate ? "true" : "false") << "\n"); 53 if(flag) _pprintString_(" altmode: \"" << altmode << "\"" << "\n"); 54 if(flag) _pprintString_(" coords: (ncoord=" << ncoord << ")" << "\n"); 55 55 56 56 return; … … 73 73 bool flag=true; 74 74 75 if(flag) _pprint Line_(indent << "KML_LineString:");75 if(flag) _pprintString_(indent << "KML_LineString:" << "\n"); 76 76 KML_Geometry::DeepEcho(indent); 77 77 78 if(flag) _pprint Line_(indent << " extrude: " << (extrude ? "true" : "false"));79 if(flag) _pprint Line_(indent << " tessellate: " << (tessellate ? "true" : "false"));80 if(flag) _pprint Line_(indent << " altmode: \"" << altmode << "\"");81 if(flag) _pprint Line_(indent << " coords: (ncoord=" << ncoord << ")");78 if(flag) _pprintString_(indent << " extrude: " << (extrude ? "true" : "false") << "\n"); 79 if(flag) _pprintString_(indent << " tessellate: " << (tessellate ? "true" : "false") << "\n"); 80 if(flag) _pprintString_(indent << " altmode: \"" << altmode << "\"" << "\n"); 81 if(flag) _pprintString_(indent << " coords: (ncoord=" << ncoord << ")" << "\n"); 82 82 for (i=0; i<ncoord; i++) 83 if(flag) _pprint Line_(indent << " (" << coords[3*i+0] << "," << coords[3*i+1] << "," << coords[3*i+2] << ")");83 if(flag) _pprintString_(indent << " (" << coords[3*i+0] << "," << coords[3*i+1] << "," << coords[3*i+2] << ")" << "\n"); 84 84 85 85 return; -
issm/trunk-jpl/src/c/kml/KML_LineStyle.cpp
r15068 r15099 38 38 bool flag=true; 39 39 40 if(flag) _pprint Line_("KML_LineStyle:");40 if(flag) _pprintString_("KML_LineStyle:" << "\n"); 41 41 KML_ColorStyle::Echo(); 42 42 43 if(flag) _pprint Line_(" width: " << width);43 if(flag) _pprintString_(" width: " << width << "\n"); 44 44 45 45 return; … … 61 61 bool flag=true; 62 62 63 if(flag) _pprint Line_(indent << "KML_LineStyle:");63 if(flag) _pprintString_(indent << "KML_LineStyle:" << "\n"); 64 64 KML_ColorStyle::DeepEcho(indent); 65 65 66 if(flag) _pprint Line_(indent << " width: " << width);66 if(flag) _pprintString_(indent << " width: " << width << "\n"); 67 67 68 68 return; -
issm/trunk-jpl/src/c/kml/KML_LinearRing.cpp
r15097 r15099 46 46 bool flag=true; 47 47 48 if(flag) _pprint Line_("KML_LinearRing:");48 if(flag) _pprintString_("KML_LinearRing:" << "\n"); 49 49 KML_Geometry::Echo(); 50 50 51 if(flag) _pprint Line_(" extrude: " << (extrude ? "true" : "false"));52 if(flag) _pprint Line_(" tessellate: " << (tessellate ? "true" : "false"));53 if(flag) _pprint Line_(" altmode: \"" << altmode << "\"");54 if(flag) _pprint Line_(" coords: (ncoord=" << ncoord << ")");51 if(flag) _pprintString_(" extrude: " << (extrude ? "true" : "false") << "\n"); 52 if(flag) _pprintString_(" tessellate: " << (tessellate ? "true" : "false") << "\n"); 53 if(flag) _pprintString_(" altmode: \"" << altmode << "\"" << "\n"); 54 if(flag) _pprintString_(" coords: (ncoord=" << ncoord << ")" << "\n"); 55 55 56 56 return; … … 73 73 bool flag=true; 74 74 75 if(flag) _pprint Line_(indent << "KML_LinearRing:");75 if(flag) _pprintString_(indent << "KML_LinearRing:" << "\n"); 76 76 KML_Geometry::DeepEcho(indent); 77 77 78 if(flag) _pprint Line_(indent << " extrude: " << (extrude ? "true" : "false"));79 if(flag) _pprint Line_(indent << " tessellate: " << (tessellate ? "true" : "false"));80 if(flag) _pprint Line_(indent << " altmode: \"" << altmode << "\"");81 if(flag) _pprint Line_(indent << " coords: (ncoord=" << ncoord << ")");78 if(flag) _pprintString_(indent << " extrude: " << (extrude ? "true" : "false") << "\n"); 79 if(flag) _pprintString_(indent << " tessellate: " << (tessellate ? "true" : "false") << "\n"); 80 if(flag) _pprintString_(indent << " altmode: \"" << altmode << "\"" << "\n"); 81 if(flag) _pprintString_(indent << " coords: (ncoord=" << ncoord << ")" << "\n"); 82 82 for (i=0; i<ncoord; i++) 83 if(flag)_print Line_(indent << " (" <<coords[3*i+0] << "," <<coords[3*i+1] << "," <<coords[3*i+2] << ")\n");83 if(flag)_printString_(indent << " (" <<coords[3*i+0] << "," <<coords[3*i+1] << "," <<coords[3*i+2] << ")\n" << "\n"); 84 84 85 85 return; -
issm/trunk-jpl/src/c/kml/KML_MultiGeometry.cpp
r15068 r15099 46 46 bool flag=true; 47 47 48 if(flag) _pprint Line_("KML_Multigeometry:");48 if(flag) _pprintString_("KML_Multigeometry:" << "\n"); 49 49 KML_Geometry::Echo(); 50 50 51 if(flag) _pprint Line_(" geometry: (size=" << geometry->Size() << ")");51 if(flag) _pprintString_(" geometry: (size=" << geometry->Size() << ")" << "\n"); 52 52 53 53 return; … … 71 71 bool flag=true; 72 72 73 if(flag) _pprint Line_(indent << "KML_Multigeometry:");73 if(flag) _pprintString_(indent << "KML_Multigeometry:" << "\n"); 74 74 KML_Geometry::DeepEcho(indent); 75 75 … … 81 81 if (geometry->Size()) 82 82 for (i=0; i<geometry->Size(); i++) { 83 if(flag) _pprint Line_(indent << " geometry: -------- begin [" << i << "] --------");83 if(flag) _pprintString_(indent << " geometry: -------- begin [" << i << "] --------" << "\n"); 84 84 ((KML_Geometry *)geometry->GetObjectByOffset(i))->DeepEcho(indent2); 85 if(flag) _pprint Line_(indent << " geometry: -------- end [" << i << "] --------");85 if(flag) _pprintString_(indent << " geometry: -------- end [" << i << "] --------" << "\n"); 86 86 } 87 87 else 88 if(flag) _pprint Line_(indent << " geometry: [empty]");88 if(flag) _pprintString_(indent << " geometry: [empty]" << "\n"); 89 89 90 90 return; -
issm/trunk-jpl/src/c/kml/KML_Object.cpp
r15068 r15099 66 66 bool flag=true; 67 67 68 if(flag) _pprint Line_(" attrib: (size=" << attrib->Size() << ")");69 if(flag) _pprint Line_(" commnt: (size=" << commnt->Size() << ")");70 if(flag) _pprint Line_(" kmlobj: (size=" << kmlobj->Size() << ")");68 if(flag) _pprintString_(" attrib: (size=" << attrib->Size() << ")" << "\n"); 69 if(flag) _pprintString_(" commnt: (size=" << commnt->Size() << ")" << "\n"); 70 if(flag) _pprintString_(" kmlobj: (size=" << kmlobj->Size() << ")" << "\n"); 71 71 72 72 return; … … 97 97 } 98 98 else 99 if(flag) _pprint Line_(indent << " attrib: [empty]");99 if(flag) _pprintString_(indent << " attrib: [empty]" << "\n"); 100 100 101 101 /* loop over the comments for the object */ … … 106 106 } 107 107 else 108 if(flag) _pprint Line_(indent << " commnt: [empty]");108 if(flag) _pprintString_(indent << " commnt: [empty]" << "\n"); 109 109 110 110 /* loop over the unknown objects for the object */ … … 115 115 if (kmlobj->Size()) 116 116 for (i=0; i<kmlobj->Size(); i++) { 117 if(flag) _pprint Line_(indent << " kmlobj: -------- begin [" << i << "] --------");117 if(flag) _pprintString_(indent << " kmlobj: -------- begin [" << i << "] --------" << "\n"); 118 118 ((KML_Unknown *)kmlobj->GetObjectByOffset(i))->DeepEcho(indent2); 119 if(flag) _pprint Line_(indent << " kmlobj: -------- end [" << i << "] --------");119 if(flag) _pprintString_(indent << " kmlobj: -------- end [" << i << "] --------" << "\n"); 120 120 } 121 121 else 122 if(flag) _pprint Line_(indent << " kmlobj: [empty]");122 if(flag) _pprintString_(indent << " kmlobj: [empty]" << "\n"); 123 123 124 124 return; … … 264 264 265 265 else if (!strncmp(kstr,"<",1)) { 266 _pprint Line_("KML_Object::Read -- Unrecognized opening tag " << kstr << ".");266 _pprintString_("KML_Object::Read -- Unrecognized opening tag " << kstr << "." << "\n"); 267 267 // KMLFileTagSkip(kstr, 268 268 // fid); -
issm/trunk-jpl/src/c/kml/KML_Overlay.cpp
r15068 r15099 45 45 46 46 KML_Feature::Echo(); 47 _pprint Line_(" color: \"" << color << "\"");48 _pprint Line_(" draword: " << draword);49 _pprint Line_(" icon: " << icon);47 _pprintString_(" color: \"" << color << "\"" << "\n"); 48 _pprintString_(" draword: " << draword << "\n"); 49 _pprintString_(" icon: " << icon << "\n"); 50 50 } 51 51 /*}}}*/ … … 69 69 strcat(indent2," "); 70 70 71 _pprint Line_(indent << " color: " << color);72 _pprint Line_(indent << " draword: " << draword);71 _pprintString_(indent << " color: " << color << "\n"); 72 _pprintString_(indent << " draword: " << draword << "\n"); 73 73 if (icon) 74 74 icon->DeepEcho(indent2); 75 75 else 76 _pprint Line_(indent << " icon: " << icon);76 _pprintString_(indent << " icon: " << icon << "\n"); 77 77 } 78 78 /*}}}*/ -
issm/trunk-jpl/src/c/kml/KML_Placemark.cpp
r15068 r15099 47 47 bool flag=true; 48 48 49 if(flag) _pprint Line_("KML_Placemark:");49 if(flag) _pprintString_("KML_Placemark:" << "\n"); 50 50 KML_Feature::Echo(); 51 51 52 if(flag) _pprint Line_(" geometry: (size=" << geometry->Size() << ")");52 if(flag) _pprintString_(" geometry: (size=" << geometry->Size() << ")" << "\n"); 53 53 54 54 return; … … 72 72 bool flag=true; 73 73 74 if(flag) _pprint Line_(indent << "KML_Placemark:");74 if(flag) _pprintString_(indent << "KML_Placemark:" << "\n"); 75 75 KML_Feature::DeepEcho(indent); 76 76 … … 82 82 if (geometry->Size()) 83 83 for (i=0; i<geometry->Size(); i++) { 84 if(flag) _pprint Line_(indent << " geometry: -------- begin [" << i << "] --------");84 if(flag) _pprintString_(indent << " geometry: -------- begin [" << i << "] --------" << "\n"); 85 85 ((KML_Geometry *)geometry->GetObjectByOffset(i))->DeepEcho(indent2); 86 if(flag) _pprint Line_(indent << " geometry: -------- end [" << i << "] --------");86 if(flag) _pprintString_(indent << " geometry: -------- end [" << i << "] --------" << "\n"); 87 87 } 88 88 else 89 if(flag) _pprint Line_(indent << " geometry: [empty]");89 if(flag) _pprintString_(indent << " geometry: [empty]" << "\n"); 90 90 91 91 return; -
issm/trunk-jpl/src/c/kml/KML_Point.cpp
r15069 r15099 43 43 bool flag=true; 44 44 45 if(flag) _pprint Line_("KML_Point:");45 if(flag) _pprintString_("KML_Point:" << "\n"); 46 46 KML_Geometry::Echo(); 47 47 48 if(flag) _pprint Line_(" extrude: " << (extrude ? "true" : "false"));49 if(flag) _pprint Line_(" altmode: \"" << altmode << "\"");50 if(flag) _pprint Line_(" coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")");48 if(flag) _pprintString_(" extrude: " << (extrude ? "true" : "false") << "\n"); 49 if(flag) _pprintString_(" altmode: \"" << altmode << "\"" << "\n"); 50 if(flag) _pprintString_(" coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")" << "\n"); 51 51 52 52 return; … … 68 68 bool flag=true; 69 69 70 if(flag) _pprint Line_(indent << "KML_Point:");70 if(flag) _pprintString_(indent << "KML_Point:" << "\n"); 71 71 KML_Geometry::DeepEcho(indent); 72 72 73 if(flag) _pprint Line_(indent << " extrude: " << (extrude ? "true" : "false"));74 if(flag) _pprint Line_(indent << " altmode: \"" << altmode << "\"");75 if(flag) _pprint Line_(indent << " coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")");73 if(flag) _pprintString_(indent << " extrude: " << (extrude ? "true" : "false") << "\n"); 74 if(flag) _pprintString_(indent << " altmode: \"" << altmode << "\"" << "\n"); 75 if(flag) _pprintString_(indent << " coords: (" << coords[0] << "," << coords[1] << "," << coords[2] << ")" << "\n"); 76 76 77 77 return; -
issm/trunk-jpl/src/c/kml/KML_PolyStyle.cpp
r15068 r15099 41 41 bool flag=true; 42 42 43 if(flag) _pprint Line_("KML_PolyStyle:");43 if(flag) _pprintString_("KML_PolyStyle:" << "\n"); 44 44 KML_ColorStyle::Echo(); 45 45 46 if(flag) _pprint Line_(" fill: " << fill);47 if(flag) _pprint Line_(" outline: " << outline);46 if(flag) _pprintString_(" fill: " << fill << "\n"); 47 if(flag) _pprintString_(" outline: " << outline << "\n"); 48 48 49 49 return; … … 65 65 bool flag=true; 66 66 67 if(flag) _pprint Line_(indent << "KML_PolyStyle:");67 if(flag) _pprintString_(indent << "KML_PolyStyle:" << "\n"); 68 68 KML_ColorStyle::DeepEcho(indent); 69 69 70 if(flag) _pprint Line_(indent << " fill: " << fill);71 if(flag) _pprint Line_(indent << " outline: " << outline);70 if(flag) _pprintString_(indent << " fill: " << fill << "\n"); 71 if(flag) _pprintString_(indent << " outline: " << outline << "\n"); 72 72 73 73 return; -
issm/trunk-jpl/src/c/kml/KML_Polygon.cpp
r15068 r15099 52 52 bool flag=true; 53 53 54 if(flag) _pprint Line_("KML_Polygon:");54 if(flag) _pprintString_("KML_Polygon:" << "\n"); 55 55 KML_Geometry::Echo(); 56 56 57 if(flag) _pprint Line_(" extrude: " << (extrude ? "true" : "false"));58 if(flag) _pprint Line_(" tessellate: " << (tessellate ? "true" : "false"));59 if(flag) _pprint Line_(" altmode: \"" << altmode << "\"");60 if(flag) _pprint Line_(" outer: (size=" << outer->Size() << ")");61 if(flag) _pprint Line_(" inner: (size=" << inner->Size() << ")");57 if(flag) _pprintString_(" extrude: " << (extrude ? "true" : "false") << "\n"); 58 if(flag) _pprintString_(" tessellate: " << (tessellate ? "true" : "false") << "\n"); 59 if(flag) _pprintString_(" altmode: \"" << altmode << "\"" << "\n"); 60 if(flag) _pprintString_(" outer: (size=" << outer->Size() << ")" << "\n"); 61 if(flag) _pprintString_(" inner: (size=" << inner->Size() << ")" << "\n"); 62 62 63 63 return; … … 81 81 bool flag=true; 82 82 83 if(flag) _pprint Line_(indent << "KML_Polygon:");83 if(flag) _pprintString_(indent << "KML_Polygon:" << "\n"); 84 84 KML_Geometry::DeepEcho(indent); 85 85 86 if(flag) _pprint Line_(indent << " extrude: " << (extrude ? "true" : "false"));87 if(flag) _pprint Line_(indent << " tessellate: " << (tessellate ? "true" : "false"));88 if(flag) _pprint Line_(indent << " altmode: \"" << altmode << "\"");86 if(flag) _pprintString_(indent << " extrude: " << (extrude ? "true" : "false") << "\n"); 87 if(flag) _pprintString_(indent << " tessellate: " << (tessellate ? "true" : "false") << "\n"); 88 if(flag) _pprintString_(indent << " altmode: \"" << altmode << "\"" << "\n"); 89 89 90 90 memcpy(indent2,indent,(strlen(indent)+1)*sizeof(char)); … … 93 93 if (outer->Size()) 94 94 for (i=0; i<outer->Size(); i++) { 95 if(flag) _pprint Line_(indent << " outer: -------- begin [" << i << "] --------");95 if(flag) _pprintString_(indent << " outer: -------- begin [" << i << "] --------" << "\n"); 96 96 ((KML_LinearRing *)outer->GetObjectByOffset(i))->DeepEcho(indent2); 97 if(flag) _pprint Line_(indent << " outer: -------- end [" << i << "] --------");97 if(flag) _pprintString_(indent << " outer: -------- end [" << i << "] --------" << "\n"); 98 98 } 99 99 else 100 if(flag) _pprint Line_(indent << " outer: [empty]");100 if(flag) _pprintString_(indent << " outer: [empty]" << "\n"); 101 101 102 102 if (inner->Size()) 103 103 for (i=0; i<inner->Size(); i++) { 104 if(flag) _pprint Line_(indent << " inner: -------- begin [" << i << "] --------");104 if(flag) _pprintString_(indent << " inner: -------- begin [" << i << "] --------" << "\n"); 105 105 ((KML_LinearRing *)inner->GetObjectByOffset(i))->DeepEcho(indent2); 106 if(flag) _pprint Line_(indent << " inner: -------- end [" << i << "] --------");106 if(flag) _pprintString_(indent << " inner: -------- end [" << i << "] --------" << "\n"); 107 107 } 108 108 else 109 if(flag) _pprint Line_(indent << " inner: [empty]");109 if(flag) _pprintString_(indent << " inner: [empty]" << "\n"); 110 110 111 111 return; -
issm/trunk-jpl/src/c/kml/KML_Style.cpp
r15068 r15099 68 68 bool flag=true; 69 69 70 if(flag) _pprint Line_("KML_Style:");70 if(flag) _pprintString_("KML_Style:" << "\n"); 71 71 KML_StyleSelector::Echo(); 72 72 73 if(flag) _pprint Line_(" icon: " << icon);74 if(flag) _pprint Line_(" label: " << label);75 if(flag) _pprint Line_(" line: " << line);76 if(flag) _pprint Line_(" poly: " << poly);77 if(flag) _pprint Line_(" balloon: " << balloon);78 if(flag) _pprint Line_(" list: " << list);73 if(flag) _pprintString_(" icon: " << icon << "\n"); 74 if(flag) _pprintString_(" label: " << label << "\n"); 75 if(flag) _pprintString_(" line: " << line << "\n"); 76 if(flag) _pprintString_(" poly: " << poly << "\n"); 77 if(flag) _pprintString_(" balloon: " << balloon << "\n"); 78 if(flag) _pprintString_(" list: " << list << "\n"); 79 79 80 80 return; … … 97 97 bool flag=true; 98 98 99 if(flag) _pprint Line_(indent << "KML_Style:");99 if(flag) _pprintString_(indent << "KML_Style:" << "\n"); 100 100 KML_StyleSelector::DeepEcho(indent); 101 101 … … 106 106 // icon->DeepEcho(indent2); 107 107 // else 108 if(flag) _pprint Line_(indent << " icon: " << icon);108 if(flag) _pprintString_(indent << " icon: " << icon << "\n"); 109 109 // if (label) 110 110 // label->DeepEcho(indent2); 111 111 // else 112 if(flag) _pprint Line_(indent << " label: " << label);112 if(flag) _pprintString_(indent << " label: " << label << "\n"); 113 113 if (line) 114 114 line->DeepEcho(indent2); 115 115 else 116 if(flag) _pprint Line_(indent << " line: " << line);116 if(flag) _pprintString_(indent << " line: " << line << "\n"); 117 117 if (poly) 118 118 poly->DeepEcho(indent2); 119 119 else 120 if(flag) _pprint Line_(indent << " poly: " << poly);120 if(flag) _pprintString_(indent << " poly: " << poly << "\n"); 121 121 // if (balloon) 122 122 // balloon->DeepEcho(indent2); 123 123 // else 124 if(flag) _pprint Line_(indent << " balloon: " << balloon);124 if(flag) _pprintString_(indent << " balloon: " << balloon << "\n"); 125 125 // if (list) 126 126 // list->DeepEcho(indent2); 127 127 // else 128 if(flag) _pprint Line_(indent << " list: " << list);128 if(flag) _pprintString_(indent << " list: " << list << "\n"); 129 129 130 130 return; -
issm/trunk-jpl/src/c/kml/KML_Unknown.cpp
r15068 r15099 40 40 bool flag=true; 41 41 42 if(flag) _pprint Line_("KML_Unknown " << name << ":");42 if(flag) _pprintString_("KML_Unknown " << name << ":" << "\n"); 43 43 KML_Object::Echo(); 44 44 45 45 if (value ) 46 if(flag) _pprint Line_(" value: \"" << value << "\"");46 if(flag) _pprintString_(" value: \"" << value << "\"" << "\n"); 47 47 else 48 if(flag) _pprint Line_(" value: [none]");48 if(flag) _pprintString_(" value: [none]" << "\n"); 49 49 50 50 return; … … 69 69 bool flag=true; 70 70 71 if(flag) _pprint Line_(indent << "KML_Unknown " << name << ":");71 if(flag) _pprintString_(indent << "KML_Unknown " << name << ":" << "\n"); 72 72 KML_Object::DeepEcho(indent); 73 73 … … 81 81 while (vtoken=strtok(NULL,nl)) 82 82 if(flag) _pprintString_("\n" << indent << " " << vtoken); 83 if(flag) _pprint Line_("\"");83 if(flag) _pprintString_("\"" << "\n"); 84 84 85 85 xDelete<char>(valuei); 86 86 } 87 87 else 88 if(flag) _pprint Line_(indent << " value: [none]");88 if(flag) _pprintString_(indent << " value: [none]" << "\n"); 89 89 90 90 return; … … 136 136 name=KMLFileTagName(NULL, 137 137 kstr); 138 // _pprint Line_("KML_Unknown::Read -- opening name=" << name << ".");138 // _pprintString_("KML_Unknown::Read -- opening name=" << name << "." << "\n"); 139 139 140 140 /* get object attributes and check for solo tag */ … … 148 148 while (kstri=KMLFileToken(fid, 149 149 &ncom,&pcom)) { 150 // _pprint Line_("KML_Unknown::Read -- kstri=" << kstri << ".");150 // _pprintString_("KML_Unknown::Read -- kstri=" << kstri << "." << "\n"); 151 151 if (!strncmp(&kstri[0],"</", 2) && 152 152 !strncmp(&kstri[2],name,strlen(name))) { 153 // _pprint Line_("KML_Unknown::Read -- closing name=" << name << ".");153 // _pprintString_("KML_Unknown::Read -- closing name=" << name << "." << "\n"); 154 154 xDelete<char>(kstri); 155 155 break; -
issm/trunk-jpl/src/c/main/kriging.cpp
r14921 r15099 51 51 pfclose(input_fid,binfilename); 52 52 53 _pprint Line_("call computational core:");53 _pprintString_("call computational core:" << "\n"); 54 54 pKrigingx(&predictions,&error,x,y,data,nobs,x_interp,y_interp,ninterp,options); 55 55 56 _pprint Line_("write results to disk:");56 _pprintString_("write results to disk:" << "\n"); 57 57 Results *results = new Results(); 58 58 if(IssmComm::GetRank()==0){ … … 68 68 69 69 /*Close output and toolkits options file and write lock file if requested*/ 70 _pprint Line_("write lock file:");70 _pprintString_("write lock file:" << "\n"); 71 71 WriteLockFile(lockfilename); 72 72 -
issm/trunk-jpl/src/c/modules/Bamgx/Bamgx.cpp
r15061 r15099 40 40 41 41 //Step1: generate geometry Gh 42 if (verbosity>0) _print Line_("Construction of a mesh from a given geometry");43 if (verbosity>1) _print Line_(" Processing geometry...");42 if (verbosity>0) _printString_("Construction of a mesh from a given geometry" << "\n"); 43 if (verbosity>1) _printString_(" Processing geometry..." << "\n"); 44 44 Geometry Gh(bamggeom_in,bamgopts); 45 45 … … 49 49 50 50 //build metric using geometry 51 if (verbosity>1) _print Line_(" Generating Metric...");51 if (verbosity>1) _printString_(" Generating Metric..." << "\n"); 52 52 for(i=0;i<Gh.nbv;i++){ 53 53 Metric M=Gh[i]; … … 59 59 60 60 //generate mesh 61 if (verbosity>1) _print Line_(" Generating Mesh...");61 if (verbosity>1) _printString_(" Generating Mesh..." << "\n"); 62 62 Mesh Th(maxnbv,Gh,bamgopts); 63 63 … … 72 72 73 73 //Build output 74 if (verbosity>1) _print Line_(" Write Mesh...");74 if (verbosity>1) _printString_(" Write Mesh..." << "\n"); 75 75 Th.WriteMesh(bamgmesh_out,bamgopts); 76 if (verbosity>1) _print Line_(" Write Geometry...");76 if (verbosity>1) _printString_(" Write Geometry..." << "\n"); 77 77 Gh.WriteGeometry(bamggeom_out,bamgopts); 78 78 … … 86 86 87 87 // read background mesh 88 if (verbosity>0) _print Line_("Anisotropic mesh adaptation");89 if (verbosity>1) _print Line_(" Processing initial mesh and geometry...");88 if (verbosity>0) _printString_("Anisotropic mesh adaptation" << "\n"); 89 if (verbosity>1) _printString_(" Processing initial mesh and geometry..." << "\n"); 90 90 Mesh BTh(bamggeom_in,bamgmesh_in,bamgopts); 91 91 … … 99 99 //Generate initial metric 100 100 if (bamgopts->metric){ 101 if (verbosity>1) _print Line_(" Processing Metric...");101 if (verbosity>1) _printString_(" Processing Metric..." << "\n"); 102 102 BTh.ReadMetric(bamgopts); 103 103 } 104 104 else { 105 if (verbosity>1) _print Line_(" Generating initial Metric...");105 if (verbosity>1) _printString_(" Generating initial Metric..." << "\n"); 106 106 Metric Mhmax(bamgopts->hmax); 107 107 for (int iv=0;iv<BTh.nbv;iv++) BTh[iv].m = Mhmax; … … 110 110 //use present fields to generate metric if present 111 111 if (bamgopts->field){ 112 if (verbosity>1) _print Line_(" Merge metric with field provided...");112 if (verbosity>1) _printString_(" Merge metric with field provided..." << "\n"); 113 113 BTh.AddMetric(bamgopts); 114 114 } … … 116 116 // change using hVertices if provided 117 117 if(bamgopts->hVertices && bamgopts->hVerticesSize[0]==BTh.nbv){ 118 if (verbosity>1) _print Line_(" Merging Metric with hVertices...");118 if (verbosity>1) _printString_(" Merging Metric with hVertices..." << "\n"); 119 119 for (i=0;i<BTh.nbv;i++){ 120 120 if (!xIsNan<IssmPDouble>(bamgopts->hVertices[i])){ … … 126 126 // change using hminVertices if provided 127 127 if (bamgopts->hminVertices){ 128 if (verbosity>1) _print Line_(" Merging Metric with hminVertices...");128 if (verbosity>1) _printString_(" Merging Metric with hminVertices..." << "\n"); 129 129 for (i=0;i<BTh.nbv;i++){ 130 130 if (!xIsNan<IssmPDouble>(bamgopts->hminVertices[i])){ … … 139 139 // change using hmaxVertices if provided 140 140 if (bamgopts->hmaxVertices){ 141 if (verbosity>1) _print Line_(" Merging Metric with hmaxVertices...");141 if (verbosity>1) _printString_(" Merging Metric with hmaxVertices..." << "\n"); 142 142 for (i=0;i<BTh.nbv;i++){ 143 143 if (!xIsNan<IssmPDouble>(bamgopts->hmaxVertices[i])){ … … 163 163 164 164 //Build new mesh 165 if (verbosity>1) _print Line_(" Generating Mesh...");165 if (verbosity>1) _printString_(" Generating Mesh..." << "\n"); 166 166 Thr=&BTh,Thb=0; 167 167 Mesh & Th( *(0 ? new Mesh(*Thr,&Thr->Gh,Thb,maxnbv) : new Mesh(maxnbv,BTh,bamgopts,bamgopts->KeepVertices))); … … 184 184 if(verbosity>0) { 185 185 if (Th.nbt-Th.nbtout-Th.nbq*2){ 186 _print Line_(" new number of triangles = " << (Th.nbt-Th.nbtout-Th.nbq*2));186 _printString_(" new number of triangles = " << (Th.nbt-Th.nbtout-Th.nbq*2) << "\n"); 187 187 } 188 188 if (Th.nbq ){ 189 _print Line_(" new number of quads = " << Th.nbq);189 _printString_(" new number of quads = " << Th.nbq << "\n"); 190 190 } 191 191 } 192 192 193 193 //Build output 194 if (verbosity>1) _print Line_(" Write Mesh...");194 if (verbosity>1) _printString_(" Write Mesh..." << "\n"); 195 195 Th.WriteMesh(bamgmesh_out,bamgopts); 196 if (verbosity>1) _print Line_(" Write Geometry...");196 if (verbosity>1) _printString_(" Write Geometry..." << "\n"); 197 197 Th.Gh.WriteGeometry(bamggeom_out,bamgopts); 198 if (verbosity>1) _print Line_(" Write Metric...");198 if (verbosity>1) _printString_(" Write Metric..." << "\n"); 199 199 BTh.WriteMetric(bamgopts); 200 200 … … 206 206 207 207 /*No error return*/ 208 if (verbosity>1) _print Line_(" Exiting Bamg.");208 if (verbosity>1) _printString_(" Exiting Bamg." << "\n"); 209 209 return noerr; 210 210 -
issm/trunk-jpl/src/c/modules/Chacox/Chacox.cpp
r14644 r15099 63 63 64 64 if (DEBUG_TRACE > 0) { 65 _print Line_("<Entering main>");65 _printString_("<Entering main>" << "\n"); 66 66 } 67 67 68 68 if (PRINT_HEADERS) { 69 _print Line_("\n Chaco 2.0");70 _print Line_(" Sandia National Laboratories\n");69 _printString_("\n Chaco 2.0" << "\n"); 70 _printString_(" Sandia National Laboratories\n" << "\n"); 71 71 } 72 72 … … 166 166 167 167 if (DEBUG_MEMORY > 0) { 168 _print Line_("");168 _printString_("" << "\n"); 169 169 smalloc_stats(); 170 170 } … … 174 174 175 175 if (DEBUG_TRACE > 1) { 176 _print Line_("<Leaving main>");176 _printString_("<Leaving main>" << "\n"); 177 177 } 178 178 -
issm/trunk-jpl/src/c/modules/Chacox/input_parse.cpp
r14634 r15099 37 37 38 38 if (DEBUG_TRACE > 0) { 39 _print Line_("<Entering input_parse>");39 _printString_("<Entering input_parse>" << "\n"); 40 40 } 41 41 42 42 if (PROMPT) { 43 _print Line_("Parallel machine architecture:");44 _print Line_(" (0) Hypercube");45 _print Line_(" (1) One-dimensional mesh");46 _print Line_(" (2) Two-dimensional mesh");47 _print Line_(" (3) Three-dimensional mesh");43 _printString_("Parallel machine architecture:" << "\n"); 44 _printString_(" (0) Hypercube" << "\n"); 45 _printString_(" (1) One-dimensional mesh" << "\n"); 46 _printString_(" (2) Two-dimensional mesh" << "\n"); 47 _printString_(" (3) Three-dimensional mesh" << "\n"); 48 48 } 49 49 *architecture = (int)options[OPT_ARCH]; … … 73 73 else { 74 74 if (PROMPT) { 75 _print Line_("Global partitioning method:");76 _print Line_(" (1) Multilevel-KL");77 _print Line_(" (2) Spectral");78 _print Line_(" (3) Inertial");79 _print Line_(" (4) Linear");80 _print Line_(" (5) Random");81 _print Line_(" (6) Scattered");82 _print Line_(" (7) Read-from-file");75 _printString_("Global partitioning method:" << "\n"); 76 _printString_(" (1) Multilevel-KL" << "\n"); 77 _printString_(" (2) Spectral" << "\n"); 78 _printString_(" (3) Inertial" << "\n"); 79 _printString_(" (4) Linear" << "\n"); 80 _printString_(" (5) Random" << "\n"); 81 _printString_(" (6) Scattered" << "\n"); 82 _printString_(" (7) Read-from-file" << "\n"); 83 83 } 84 84 *global_method = (int)options[OPT_GLOBAL]; … … 101 101 else if (*global_method == 2) { 102 102 if (PROMPT) { 103 _print Line_("Eigensolver:");104 _print Line_(" (1) Multilevel RQI/Symmlq");105 _print Line_(" (2) Lanczos");103 _printString_("Eigensolver:" << "\n"); 104 _printString_(" (1) Multilevel RQI/Symmlq" << "\n"); 105 _printString_(" (2) Lanczos" << "\n"); 106 106 } 107 107 eigensolver = (int)options[OPT_RQI]; … … 162 162 else { 163 163 if (PROMPT) { 164 _print Line_("Local refinement method:");165 _print Line_(" (1) Kernighan-Lin");166 _print Line_(" (2) None");164 _printString_("Local refinement method:" << "\n"); 165 _printString_(" (1) Kernighan-Lin" << "\n"); 166 _printString_(" (2) None" << "\n"); 167 167 } 168 168 *local_method = (int)options[OPT_LOCAL]; … … 181 181 *ndims_tot = nparts[0]; 182 182 if (*ndims_tot < 1) { 183 _print Line_(" Number of divisions must be at least 1");183 _printString_(" Number of divisions must be at least 1" << "\n"); 184 184 printf("%s -- Number of divisions %d must be at least 1.\n", 185 185 __FUNCT__,nparts[0]); … … 220 220 else if (*nprocs <= 7) { 221 221 if (PROMPT) { 222 _print Line_("Partitioning dimension:");223 _print Line_(" (1) Bisection");224 _print Line_(" (2) Quadrisection");222 _printString_("Partitioning dimension: " << "\n"); 223 _printString_(" (1) Bisection" << "\n"); 224 _printString_(" (2) Quadrisection" << "\n"); 225 225 } 226 226 *ndims = (int)options[OPT_NDIMS]; … … 232 232 else { 233 233 if (PROMPT) { 234 _print Line_("Partitioning dimension:");235 _print Line_(" (1) Bisection");236 _print Line_(" (2) Quadrisection");237 _print Line_(" (3) Octasection");234 _printString_("Partitioning dimension: " << "\n"); 235 _printString_(" (1) Bisection" << "\n"); 236 _printString_(" (2) Quadrisection" << "\n"); 237 _printString_(" (3) Octasection" << "\n"); 238 238 } 239 239 *ndims = (int)options[OPT_NDIMS]; -
issm/trunk-jpl/src/c/modules/ConfigureObjectsx/ConfigureObjectsx.cpp
r14999 r15099 23 23 parameters->FindParam(&configuration_type,ConfigurationTypeEnum); 24 24 25 if(VerboseMProcessor()) _pprint Line_(" Configuring elements...");25 if(VerboseMProcessor()) _pprintString_(" Configuring elements..." << "\n"); 26 26 for (i=0;i<elements->Size();i++){ 27 27 element=dynamic_cast<Element*>(elements->GetObjectByOffset(i)); 28 28 element->Configure(elements,loads,nodes,vertices,materials,parameters); 29 29 } 30 if(VerboseMProcessor()) _pprint Line_(" Configuring loads...");30 if(VerboseMProcessor()) _pprintString_(" Configuring loads..." << "\n"); 31 31 for (i=0;i<loads->Size();i++){ 32 32 load=(Load*)loads->GetObjectByOffset(i); … … 35 35 } 36 36 } 37 if(VerboseMProcessor()) _pprint Line_(" Configuring nodes...");37 if(VerboseMProcessor()) _pprintString_(" Configuring nodes..." << "\n"); 38 38 for (i=0;i<nodes->Size();i++){ 39 39 node=(Node*)nodes->GetObjectByOffset(i); … … 43 43 } 44 44 45 if(VerboseMProcessor()) _pprint Line_(" Configuring materials...");45 if(VerboseMProcessor()) _pprintString_(" Configuring materials..." << "\n"); 46 46 for (i=0;i<materials->Size();i++){ 47 47 material=(Material*)materials->GetObjectByOffset(i); -
issm/trunk-jpl/src/c/modules/ConstraintsStatex/ConstraintsStatex.cpp
r14999 r15099 17 17 18 18 /*Display message*/ 19 if(VerboseModule()) _pprint Line_(" Constraining penalties");19 if(VerboseModule()) _pprintString_(" Constraining penalties" << "\n"); 20 20 21 21 /*recover parameters: */ -
issm/trunk-jpl/src/c/modules/ConstraintsStatex/RiftConstraintsState.cpp
r14999 r15099 51 51 } 52 52 else if(num_unstable_constraints<=min_mechanical_constraints){ 53 if(VerboseModule()) _pprint Line_(" freezing constraints");53 if(VerboseModule()) _pprintString_(" freezing constraints" << "\n"); 54 54 RiftFreezeConstraints(loads,configuration_type); 55 55 } -
issm/trunk-jpl/src/c/modules/CreateNodalConstraintsx/CreateNodalConstraintsx.cpp
r14999 r15099 17 17 int slocalsize; 18 18 19 if(VerboseModule()) _pprint Line_(" Create nodal constraints");19 if(VerboseModule()) _pprintString_(" Create nodal constraints" << "\n"); 20 20 21 21 /*figure out how many dofs we have: */ -
issm/trunk-jpl/src/c/modules/Exp2Kmlx/Exp2Kmlx.cpp
r15097 r15099 53 53 if (!ExpRead(&nprof,&pnvert,&pprofx,&pprofy,&closed,filexp)) 54 54 _error_("Error reading exp file."); 55 _pprint Line_("Exp2Kmlx -- Reading " << nprof << " exp profiles from file \"" << filexp << "\".");55 _pprintString_("Exp2Kmlx -- Reading " << nprof << " exp profiles from file \"" << filexp << "\"." << "\n"); 56 56 // for (i=0; i<nprof; i++) 57 // _print Line_("i=" << i << "; nvert=" << pnvert[i] << ", closed=" << closed[i]);57 // _printString_("i=" << i << "; nvert=" << pnvert[i] << ", closed=" << closed[i] << "\n"); 58 58 59 59 /* construct kml file */ … … 118 118 119 119 if (holes && nprof && (pnvert[0] <= 1 || pprofx[0][pnvert[0]-1] != pprofx[0][0] || pprofy[0][pnvert[0]-1] != pprofy[0][0])) { 120 _pprint Line_("Warning -- Outer profile is not closed, so \"holes\" option will be ignored.");120 _pprintString_("Warning -- Outer profile is not closed, so \"holes\" option will be ignored." << "\n"); 121 121 holes=false; 122 122 } … … 150 150 for (i=1; i<nprof; i++) { 151 151 if (pnvert[i] <= 1 || pprofx[i][pnvert[i]-1] != pprofx[i][0] || pprofy[i][pnvert[i]-1] != pprofy[i][0]) { 152 _pprint Line_("Warning -- Inner profile " << i+1 << " is not closed with \"holes\" specified, so it will be ignored.");152 _pprintString_("Warning -- Inner profile " << i+1 << " is not closed with \"holes\" specified, so it will be ignored." << "\n"); 153 153 continue; 154 154 } … … 272 272 /* write kml file */ 273 273 274 _pprint Line_("Exp2Kmlx -- Writing kml document to file \"" << filkml << "\".");274 _pprintString_("Exp2Kmlx -- Writing kml document to file \"" << filkml << "\"." << "\n"); 275 275 fid=fopen(filkml,"w"); 276 276 fprintf(fid,"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); … … 287 287 clock1=clock(); 288 288 time1 =time(NULL); 289 _print Line_("Exp2Kmlx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n");289 _printString_("Exp2Kmlx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 290 290 291 291 return(iret); -
issm/trunk-jpl/src/c/modules/GetSolutionFromInputsx/GetSolutionFromInputsx.cpp
r14999 r15099 19 19 Vector<IssmDouble>* solution=NULL; 20 20 21 if(VerboseModule()) _pprint Line_(" Get solution from inputs");21 if(VerboseModule()) _pprintString_(" Get solution from inputs" << "\n"); 22 22 23 23 /*retrive parameters: */ -
issm/trunk-jpl/src/c/modules/GroundinglineMigrationx/GroundinglineMigrationx.cpp
r14999 r15099 17 17 Element *element = NULL; 18 18 19 if(VerboseModule()) _pprint Line_(" Migrating grounding line");19 if(VerboseModule()) _pprintString_(" Migrating grounding line" << "\n"); 20 20 21 21 /*retrieve parameters: */ … … 162 162 #ifdef _HAVE_MPI_ 163 163 MPI_Allreduce(&local_nflipped,&nflipped,1,MPI_INT,MPI_SUM,IssmComm::GetComm()); 164 if(VerboseConvergence()) _pprint Line_(" Additional number of vertices allowed to unground: " << nflipped);164 if(VerboseConvergence()) _pprintString_(" Additional number of vertices allowed to unground: " << nflipped << "\n"); 165 165 #else 166 166 nflipped=local_nflipped; -
issm/trunk-jpl/src/c/modules/HoleFillerx/HoleFillerx.cpp
r13787 r15099 69 69 } 70 70 } 71 _print Line_( "");71 _printString_( "" << "\n"); 72 72 _printString_("Number of zeroes remaining: " << lines*samps-counter); 73 73 fflush( stdout ); … … 268 268 269 269 #ifdef _DEBUG2_ 270 //_print Line_(temp << " " << elev << " " << range << "");270 //_printString_(temp << " " << elev << " " << range << " " << "\n"); 271 271 #endif 272 272 … … 338 338 #ifdef _DEBUG2_ 339 339 _printString_( "\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b\b" ); 340 _print Line_("Number of zeroes remaining: 0\n");340 _printString_("Number of zeroes remaining: 0\n" << "\n"); 341 341 printf ( "\n"); 342 342 #endif -
issm/trunk-jpl/src/c/modules/InputUpdateFromConstantx/InputUpdateFromConstantx.cpp
r14999 r15099 10 10 11 11 int i; 12 if(VerboseModule()) _pprint Line_(" Input updates from constant");12 if(VerboseModule()) _pprintString_(" Input updates from constant" << "\n"); 13 13 14 14 /*Elements and loads drive the update: */ … … 31 31 32 32 int i; 33 if(VerboseModule()) _pprint Line_(" Input updates from constant");33 if(VerboseModule()) _pprintString_(" Input updates from constant" << "\n"); 34 34 35 35 /*Elements and loads drive the update: */ … … 52 52 53 53 int i; 54 if(VerboseModule()) _pprint Line_(" Input updates from constant");54 if(VerboseModule()) _pprintString_(" Input updates from constant" << "\n"); 55 55 56 56 /*Elements and loads drive the update: */ -
issm/trunk-jpl/src/c/modules/InterpFromGridToMeshx/InterpFromGridToMeshx.cpp
r14950 r15099 87 87 /*launch the thread manager with InterpFromGridToMeshxt as a core: */ 88 88 LaunchThread(InterpFromGridToMeshxt,(void*)&gate,num); 89 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");89 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 90 90 91 91 /*Assign output pointers:*/ … … 176 176 break; 177 177 default: 178 _print Line_("Interpolation " << EnumToStringx(interpenum) << " not supported yet");178 _printString_("Interpolation " << EnumToStringx(interpenum) << " not supported yet" << "\n"); 179 179 return NULL; /*WARNING: no error because it would blow up the multithreading!*/ 180 180 } -
issm/trunk-jpl/src/c/modules/InterpFromMesh2dx/InterpFromMesh2dxt.cpp
r14656 r15099 99 99 } 100 100 if(debug && my_thread==0) 101 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");101 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 102 102 return NULL; 103 103 } -
issm/trunk-jpl/src/c/modules/InterpFromMeshToGridx/InterpFromMeshToGridx.cpp
r14917 r15099 168 168 } 169 169 if (debug) 170 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");170 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 171 171 172 172 /*Assign output pointers:*/ -
issm/trunk-jpl/src/c/modules/InterpFromMeshToMesh2dx/InterpFromMeshToMesh2dx.cpp
r15065 r15099 142 142 } 143 143 } 144 //if(N_interp>=100) _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");144 //if(N_interp>=100) _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 145 145 146 146 /*clean-up and return*/ -
issm/trunk-jpl/src/c/modules/InterpFromMeshToMesh3dx/InterpFromMeshToMesh3dx.cpp
r14917 r15099 132 132 } 133 133 if (debug) 134 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");134 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 135 135 136 136 /*Assign output pointers:*/ -
issm/trunk-jpl/src/c/modules/KMLFileReadx/KMLFileReadx.cpp
r15097 r15099 40 40 } 41 41 42 // _pprint Line_(kstr);42 // _pprintString_(kstr << "\n"); 43 43 xDelete<char>(kstr); 44 44 } 45 45 46 46 if (kxml) { 47 _pprint Line_("XML declaration:");47 _pprintString_("XML declaration:" << "\n"); 48 48 kxml->DeepEcho(" "); 49 49 delete kxml; 50 50 } 51 51 if (kdtd) { 52 _pprint Line_("DTD declaration (not yet implemented):");52 _pprintString_("DTD declaration (not yet implemented):" << "\n"); 53 53 kdtd->DeepEcho(" "); 54 54 delete kdtd; … … 57 57 clock1=clock(); 58 58 time1 =time(NULL); 59 _print Line_("KMLFileReadx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n");59 _printString_("KMLFileReadx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 60 60 61 61 return(kfil); -
issm/trunk-jpl/src/c/modules/KMLMeshWritex/KMLMeshWritex.cpp
r15097 r15099 80 80 81 81 if (cmap) { 82 _pprint Line_("Writing " << mcmap << " Matlab colors as KML style templates.");82 _pprintString_("Writing " << mcmap << " Matlab colors as KML style templates." << "\n"); 83 83 ipt=0; 84 84 for (i=0; i<mcmap; i++) { … … 115 115 116 116 if (!nodecon) { 117 _pprint Line_("Creating the node connectivity table.");117 _pprintString_("Creating the node connectivity table." << "\n"); 118 118 nncon=mxepg+1; 119 119 nodecon=xNewZeroInit<int>(mncon*nncon); … … 146 146 147 147 else if (mdata == mncon) { 148 _pprint Line_("Averaging nodal data to element data.");148 _pprintString_("Averaging nodal data to element data." << "\n"); 149 149 edata=xNewZeroInit<double>(melem*ndata); 150 150 edfree=true; … … 185 185 clock0a=clock(); 186 186 time0a =time(NULL); 187 _print Line_(" Constructed kml document -- " << ((double)(clock0a-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0a,time0) << " elapsed seconds.\n\n");187 _printString_(" Constructed kml document -- " << ((double)(clock0a-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0a,time0) << " elapsed seconds.\n\n" << "\n"); 188 188 189 189 /* write kml file */ 190 190 191 _pprint Line_("Writing kml document to file.");191 _pprintString_("Writing kml document to file." << "\n"); 192 192 fprintf(fid,"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); 193 193 fprintf(fid,"<kml xmlns=\"http://www.opengis.net/kml/2.2\">\n"); … … 196 196 clock0b=clock(); 197 197 time0b =time(NULL); 198 _print Line_(" Wrote kml file -- " << ((double)(clock0b-clock0a))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0b,time0a) << " elapsed seconds.\n\n");199 200 _pprint Line_("Deleting kml document.");198 _printString_(" Wrote kml file -- " << ((double)(clock0b-clock0a))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0b,time0a) << " elapsed seconds.\n\n" << "\n"); 199 200 _pprintString_("Deleting kml document." << "\n"); 201 201 delete kdoc; 202 202 clock0c=clock(); 203 203 time0c =time(NULL); 204 _print Line_(" Deleted kml document -- " << ((double)(clock0c-clock0b))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0c,time0b) << " elapsed seconds.\n\n");204 _printString_(" Deleted kml document -- " << ((double)(clock0c-clock0b))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time0c,time0b) << " elapsed seconds.\n\n" << "\n"); 205 205 206 206 clock1=clock(); 207 207 time1 =time(NULL); 208 _print Line_("KMLMeshWritex Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n");208 _printString_("KMLMeshWritex Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 209 209 210 210 return; … … 297 297 /* write each element as a polygon placemark */ 298 298 299 _pprint Line_("Writing " << melem << " tria elements as KML polygons.");299 _pprintString_("Writing " << melem << " tria elements as KML polygons." << "\n"); 300 300 301 301 for (i=0; i<melem; i++) { … … 349 349 350 350 // if (!(int)fmod((double)(i+1),1000)) 351 // _pprint Line_(" " << (i+1) << " tria elements written.");351 // _pprintString_(" " << (i+1) << " tria elements written." << "\n"); 352 352 } 353 _pprint Line_(" " << melem << " tria elements written.");353 _pprintString_(" " << melem << " tria elements written." << "\n"); 354 354 355 355 return(kfold); -
issm/trunk-jpl/src/c/modules/KMLOverlayx/KMLOverlayx.cpp
r15097 r15099 79 79 /* write kml file */ 80 80 81 _pprint Line_("Writing kml document to file.");81 _pprintString_("Writing kml document to file." << "\n"); 82 82 fprintf(fid,"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); 83 83 kfile->Write(fid,indent); … … 87 87 clock1=clock(); 88 88 time1 =time(NULL); 89 _print Line_("KMLOverlayx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n");89 _printString_("KMLOverlayx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 90 90 91 91 return; -
issm/trunk-jpl/src/c/modules/Kml2Expx/Kml2Expx.cpp
r15097 r15099 46 46 /* open exp file */ 47 47 48 _pprint Line_("Writing exp profiles to file.");48 _pprintString_("Writing exp profiles to file." << "\n"); 49 49 fido=fopen(filexp,"w"); 50 50 … … 61 61 clock1=clock(); 62 62 time1 =time(NULL); 63 _print Line_("Kml2Expx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n");63 _printString_("Kml2Expx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 64 64 65 65 return(iret); -
issm/trunk-jpl/src/c/modules/Krigingx/Krigingx.cpp
r14996 r15099 83 83 observations->ObservationList(&x,&y,&data,&nobs); 84 84 85 _print Line_("Generation Delaunay Triangulation");85 _printString_("Generation Delaunay Triangulation" << "\n"); 86 86 BamgTriangulatex(&index,&nel,x,y,nobs); 87 87 88 _print Line_("Interpolating");88 _printString_("Interpolating" << "\n"); 89 89 xDelete<double>(predictions); 90 90 InterpFromMeshToMesh2dx(&predictions,index,x,y,nobs,nel,data,nobs,1,x_interp,y_interp,n_interp,options); … … 110 110 /*launch the thread manager with Krigingxt as a core: */ 111 111 LaunchThread(NearestNeighbort,(void*)&gate,num); 112 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");112 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 113 113 xDelete<int>(gate.numdone); 114 114 } … … 132 132 /*launch the thread manager with Krigingxt as a core: */ 133 133 LaunchThread(idwt,(void*)&gate,num); 134 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");134 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 135 135 xDelete<int>(gate.numdone); 136 136 } … … 154 154 /*launch the thread manager with Krigingxt as a core: */ 155 155 LaunchThread(v4t,(void*)&gate,num); 156 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");156 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 157 157 xDelete<int>(gate.numdone); 158 158 } … … 177 177 /*launch the thread manager with Krigingxt as a core: */ 178 178 LaunchThread(Krigingxt,(void*)&gate,num); 179 _print Line_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");179 _printString_("\r interpolation progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 180 180 xDelete<int>(gate.numdone); 181 181 } -
issm/trunk-jpl/src/c/modules/Krigingx/pKrigingx.cpp
r15097 r15099 68 68 /*partition loop across threads: */ 69 69 for(int idx=my_rank;idx<n_interp;idx+=num_procs){ 70 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%");70 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%" << "\n"); 71 71 observations->InterpolationKriging(&predictions[idx],&error[idx],x_interp[idx],y_interp[idx],radius,mindata,maxdata,variogram); 72 72 } 73 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%");73 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%" << "\n"); 74 74 75 75 #ifdef _HAVE_MPI_ … … 86 86 /*partition loop across threads: */ 87 87 for(int idx=my_rank;idx<n_interp;idx+=num_procs){ 88 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%");88 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%" << "\n"); 89 89 observations->InterpolationV4(&predictions[idx],x_interp[idx],y_interp[idx],radius,mindata,maxdata); 90 90 } 91 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%");91 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%" << "\n"); 92 92 93 93 #ifdef _HAVE_MPI_ … … 101 101 /*partition loop across threads: */ 102 102 for(int idx=my_rank;idx<n_interp;idx+=num_procs){ 103 _pprint Line_(" interpolation progress: "<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%");103 _pprintString_(" interpolation progress: "<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%" << "\n"); 104 104 observations->InterpolationNearestNeighbor(&predictions[idx],x_interp[idx],y_interp[idx],radius); 105 105 } 106 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%");106 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%" << "\n"); 107 107 108 108 #ifdef _HAVE_MPI_ … … 118 118 /*partition loop across threads: */ 119 119 for(int idx=my_rank;idx<n_interp;idx+=num_procs){ 120 _pprint Line_(" interpolation progress: "<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%");120 _pprintString_(" interpolation progress: "<<setw(6)<<setprecision(4)<<double(idx)/double(n_interp)*100.<<"%" << "\n"); 121 121 observations->InterpolationIDW(&predictions[idx],x_interp[idx],y_interp[idx],radius,mindata,maxdata,power); 122 122 } 123 _pprint Line_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%");123 _pprintString_(" interpolation progress: "<<fixed<<setw(6)<<setprecision(4)<<100.<<"%" << "\n"); 124 124 125 125 #ifdef _HAVE_MPI_ … … 142 142 143 143 MPI_Barrier(MPI_COMM_WORLD); finish=MPI_Wtime( ); 144 _print Line_("\n " << setw(34) << left << "Observation fitering elapsed time: " << finish_init-start_init << " seconds\n");145 _print Line_(" " << setw(34) << left << "Kriging prediction elapsed time: " << finish_core-start_core << " seconds\n");146 _print Line_("\n " << "Total elapsed time " << int((finish-start)/3600) << " hrs " << int(int(finish-start)%3600/60) << " min " << int(finish-start)%60 << " sec\n\n");144 _printString_("\n " << setw(34) << left << "Observation fitering elapsed time: " << finish_init-start_init << " seconds \n" << "\n"); 145 _printString_(" " << setw(34) << left << "Kriging prediction elapsed time: " << finish_core-start_core << " seconds \n" << "\n"); 146 _printString_("\n " << "Total elapsed time " << int((finish-start)/3600) << " hrs " << int(int(finish-start)%3600/60) << " min " << int(finish-start)%60 << " sec\n\n" << "\n"); 147 147 return 1; 148 148 #else -
issm/trunk-jpl/src/c/modules/Mergesolutionfromftogx/Mergesolutionfromftogx.cpp
r14950 r15099 17 17 18 18 /*Display message*/ 19 if(VerboseModule()) _pprint Line_(" Merging solution vector from fset to gset");19 if(VerboseModule()) _pprintString_(" Merging solution vector from fset to gset" << "\n"); 20 20 21 21 /*first, get gsize, fsize and ssize: */ -
issm/trunk-jpl/src/c/modules/ModelProcessorx/ModelProcessorx.cpp
r15000 r15099 41 41 SetVerbosityLevel(verbose); 42 42 43 if(VerboseMProcessor()) _pprint Line_(" starting model processor");43 if(VerboseMProcessor()) _pprintString_(" starting model processor " << "\n"); 44 44 45 45 for(i=0;i<nummodels;i++){ … … 65 65 if(solution_type==SteadystateSolutionEnum && analysis_type==EnthalpyAnalysisEnum && isenthalpy==false) continue; 66 66 67 if(VerboseMProcessor()) _pprint Line_(" creating datasets for analysis " << EnumToStringx(analysis_type));67 if(VerboseMProcessor()) _pprintString_(" creating datasets for analysis " << EnumToStringx(analysis_type) << "\n"); 68 68 CreateDataSets(&elements,&nodes,&vertices,&materials,&constraints,&loads,¶meters,iomodel,rootpath,solution_type,analysis_type,nummodels,i); 69 69 } 70 if(VerboseMProcessor()) _pprint Line_(" done with model processor");70 if(VerboseMProcessor()) _pprintString_(" done with model processor " << "\n"); 71 71 72 72 /*Free resources:*/ -
issm/trunk-jpl/src/c/modules/PointCloudFindNeighborsx/PointCloudFindNeighborsxt.cpp
r14656 r15099 70 70 } 71 71 if (my_thread==0) 72 _print Line_("\r loop progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%");72 _printString_("\r loop progress: "<<fixed<<setw(6)<<setprecision(2)<<100.<<"%" << "\n"); 73 73 74 74 /*Free ressources:*/ -
issm/trunk-jpl/src/c/modules/PositiveDegreeDayx/PositiveDegreeDayx.cpp
r14999 r15099 54 54 55 55 if (itm >= NPDMAX){ 56 _print Line_("increase NPDMAX in massBalance.cpp");56 _printString_("increase NPDMAX in massBalance.cpp" << "\n"); 57 57 exit (1); 58 58 } … … 80 80 itm = reCast<int,IssmDouble>((PDCUT+2.*siglimc)/DT + 1.5); 81 81 if (itm >= NPDCMAX){ 82 _print Line_("'increase NPDCMAX in p35com'");82 _printString_("'increase NPDCMAX in p35com'" << "\n"); 83 83 exit (1); 84 84 } -
issm/trunk-jpl/src/c/modules/Reduceloadx/Reduceloadx.cpp
r14950 r15099 22 22 bool oldalloc = false; 23 23 24 if(VerboseModule()) _pprint Line_(" Dirichlet lifting applied to load vector");24 if(VerboseModule()) _pprintString_(" Dirichlet lifting applied to load vector" << "\n"); 25 25 26 26 Kfs->GetSize(&global_m,&global_n); -
issm/trunk-jpl/src/c/modules/Reducevectorgtofx/Reducevectorgtofx.cpp
r14822 r15099 17 17 bool oldalloc = false; 18 18 19 if(VerboseModule()) _pprint Line_(" Reduce vector from g to f set");19 if(VerboseModule()) _pprintString_(" Reduce vector from g to f set" << "\n"); 20 20 21 21 /*first figure out fsize: */ -
issm/trunk-jpl/src/c/modules/ResetConstraintsx/ResetConstraintsx.cpp
r14999 r15099 14 14 15 15 /*Display message*/ 16 if(VerboseModule()) _pprint Line_(" Resetting penalties");16 if(VerboseModule()) _pprintString_(" Resetting penalties" << "\n"); 17 17 18 18 /*recover parameters: */ -
issm/trunk-jpl/src/c/modules/Shp2Expx/Shp2Expx.cpp
r15097 r15099 295 295 296 296 if (pnpart[i] > 0) 297 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n");297 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n" << "\n"); 298 298 if (pnvert[i] > 1) 299 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnvert[i] << " > 1 vertices.\n");299 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnvert[i] << " > 1 vertices.\n" << "\n"); 300 300 301 301 kpoint=new KML_Point(); … … 464 464 else { 465 465 if (!kpoly) { 466 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\", part " << j << ", expected to be outer loop (cw).\n");466 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\", part " << j << ", expected to be outer loop (cw).\n" << "\n"); 467 467 continue; 468 468 } … … 512 512 513 513 if (pnpart[i] > 0) 514 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n");514 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n" << "\n"); 515 515 516 516 /* create a multigeometry to hold all the points */ … … 555 555 556 556 else if (pstype[i] == SHPT_MULTIPATCH) { 557 _print Line_("Warning -- Shape " << i << " of type \"" <<SHPTypeName( pstype[i] ) << "\" will be ignored.\n");557 _printString_("Warning -- Shape " << i << " of type \"" <<SHPTypeName( pstype[i] ) << "\" will be ignored.\n" << "\n"); 558 558 continue; 559 559 } … … 562 562 563 563 else { 564 _print Line_(,"Warning -- Shape " << i << " of type \"" <<SHPTypeName( pstype[i] ) << "\" will be ignored.\n");564 _printString_(,"Warning -- Shape " << i << " of type \"" <<SHPTypeName( pstype[i] ) << "\" will be ignored.\n" << "\n"); 565 565 } 566 566 } … … 575 575 /* open exp file */ 576 576 577 _pprint Line_("Writing exp profiles to file.");577 _pprintString_("Writing exp profiles to file." << "\n"); 578 578 fid=fopen(filexp,"w"); 579 579 … … 609 609 clock1=clock(); 610 610 time1 =time(NULL); 611 _print Line_("Shp2Expx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n");611 _printString_("Shp2Expx Module -- " <<((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " <<difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 612 612 613 613 return(iret); -
issm/trunk-jpl/src/c/modules/Shp2Kmlx/Shp2Kmlx.cpp
r15097 r15099 283 283 284 284 if (pnpart[i] > 0) 285 _print Line_("Warning -- Shape "<< i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n");285 _printString_("Warning -- Shape "<< i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n" << "\n"); 286 286 if (pnvert[i] > 1) 287 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 1 vertices.\n");287 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 1 vertices.\n" << "\n"); 288 288 289 289 kpoint=new KML_Point(); … … 452 452 else { 453 453 if (!kpoly) { 454 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\", part " << j << ", expected to be outer loop (cw).\n");454 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\", part " << j << ", expected to be outer loop (cw).\n" << "\n"); 455 455 continue; 456 456 } … … 500 500 501 501 if (pnpart[i] > 0) 502 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n");502 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" should not have " << pnpart[i] << " > 0 parts.\n" << "\n"); 503 503 504 504 /* create a multigeometry to hold all the points */ … … 543 543 544 544 else if (pstype[i] == SHPT_MULTIPATCH) { 545 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" will be ignored.\n");545 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" will be ignored.\n" << "\n"); 546 546 continue; 547 547 } … … 550 550 551 551 else { 552 _print Line_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" will be ignored.\n");552 _printString_("Warning -- Shape " << i << " of type \"" << SHPTypeName( pstype[i] ) << "\" will be ignored.\n" << "\n"); 553 553 } 554 554 } … … 563 563 /* write kml file */ 564 564 565 _pprint Line_("Writing kml document to file.");565 _pprintString_("Writing kml document to file." << "\n"); 566 566 fid=fopen(filkml,"w"); 567 567 fprintf(fid,"<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"); … … 592 592 clock1=clock(); 593 593 time1 =time(NULL); 594 _print Line_("Shp2Kmlx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n");594 _printString_("Shp2Kmlx Module -- " << ((double)(clock1-clock0))/CLOCKS_PER_SEC << " CPU seconds; " << difftime(time1,time0) << " elapsed seconds.\n\n" << "\n"); 595 595 596 596 return(iret); -
issm/trunk-jpl/src/c/modules/Solverx/Solverx.cpp
r14822 r15099 20 20 Vector<IssmDouble> *uf=NULL; 21 21 22 if(VerboseModule()) _pprint Line_(" Solving matrix system");22 if(VerboseModule()) _pprintString_(" Solving matrix system" << "\n"); 23 23 24 24 /*Initialize solver: */ -
issm/trunk-jpl/src/c/shared/Elements/PrintArrays.cpp
r15090 r15099 5 5 6 6 void printarray(IssmPDouble* array,int lines,int cols){ 7 _print Line_("");7 _printString_("" << "\n"); 8 8 for(int i=0;i<lines;i++){ 9 9 _printString_(" [ "); 10 10 for(int j=0;j<cols;j++) _printString_( " " << setw(11) << setprecision (5) << array[i*cols+j]); 11 _print Line_(" ]");11 _printString_(" ]" << "\n"); 12 12 } 13 _print Line_("");13 _printString_("" << "\n"); 14 14 } 15 15 void printsparsity(IssmPDouble* array,int lines,int cols){ 16 16 int count; 17 _print Line_("");17 _printString_("" << "\n"); 18 18 for(int i=0;i<lines;i++){ 19 19 _printString_(" [ "); … … 26 26 _printString_( " ."); 27 27 } 28 _print Line_(" ] "<<i<<" => "<<count);28 _printString_(" ] "<<i<<" => "<<count << "\n"); 29 29 } 30 _print Line_("");30 _printString_("" << "\n"); 31 31 } 32 32 void printarray(int* array,int lines,int cols){ 33 _print Line_("");33 _printString_("" << "\n"); 34 34 for(int i=0;i<lines;i++){ 35 35 _printString_(" [ "); 36 36 for(int j=0;j<cols;j++) _printString_( " " << setw(11) << setprecision (5) << array[i*cols+j]); 37 _print Line_(" ]");37 _printString_(" ]" << "\n"); 38 38 } 39 _print Line_("");39 _printString_("" << "\n"); 40 40 } 41 41 void printarray(bool* array,int lines,int cols){ 42 _print Line_("");42 _printString_("" << "\n"); 43 43 for(int i=0;i<lines;i++){ 44 44 _printString_(" [ "); … … 47 47 else _printString_( " 0"); 48 48 } 49 _print Line_(" ]");49 _printString_(" ]" << "\n"); 50 50 } 51 _print Line_("");51 _printString_("" << "\n"); 52 52 } 53 53 void printbinary(int n){ -
issm/trunk-jpl/src/c/shared/Exceptions/Exceptions.cpp
r14951 r15099 46 46 else{ 47 47 if(num_procs==1){ 48 _print Line_("\n??? Error in ==> " << file_name.c_str() << ":" << file_line);49 _print Line_(function_name.c_str() << " error message: " << what()<< "\n");48 _printString_("\n??? Error in ==> " << file_name.c_str() << ":" << file_line << "\n"); 49 _printString_(function_name.c_str() << " error message: " << what() << "\n" << "\n"); 50 50 } 51 51 else{ 52 _print Line_("\n[" << my_rank<< "] ??? Error using ==> " << file_name.c_str() << ":" << file_line);53 _print Line_( "[" << my_rank << "] " << function_name.c_str() << " error message: " << what()<< "\n");52 _printString_("\n[" << my_rank<< "] ??? Error using ==> " << file_name.c_str() << ":" << file_line << "\n"); 53 _printString_( "[" << my_rank << "] " << function_name.c_str() << " error message: " << what() << "\n" << "\n"); 54 54 } 55 55 } -
issm/trunk-jpl/src/c/shared/Exceptions/exceptions.h
r15097 r15099 64 64 }\ 65 65 catch (exception& e) {\ 66 _print Line_("Standard exception: " << e.what()<< "\n");\66 _printString_("Standard exception: " << e.what() << "\n" << "\n");\ 67 67 return 0;\ 68 68 }\ 69 69 catch(...){\ 70 _print Line_("An unexpected error occurred\n");\70 _printString_("An unexpected error occurred \n" << "\n");\ 71 71 return 0;\ 72 72 } -
issm/trunk-jpl/src/c/shared/LatLong/Ll2xyx.cpp
r15069 r15099 114 114 *pdelta= 45; 115 115 *pslat = 70; 116 if(flag) _pprint Line_("Info: creating coordinates in polar stereographic (Std Latitude: 70N Meridian: 45).");116 if(flag) _pprintString_("Info: creating coordinates in polar stereographic (Std Latitude: 70N Meridian: 45)." << "\n"); 117 117 } 118 118 else if (sgn == -1) { 119 119 *pdelta= 0; 120 120 *pslat = 71; 121 if(flag) _pprint Line_("Info: creating coordinates in polar stereographic (Std Latitude: 71S Meridian: 0).");121 if(flag) _pprintString_("Info: creating coordinates in polar stereographic (Std Latitude: 71S Meridian: 0)." << "\n"); 122 122 } 123 123 else _error_("Sign should be either +1 or -1.\n"); -
issm/trunk-jpl/src/c/shared/LatLong/Xy2llx.cpp
r15069 r15099 122 122 *pdelta= 45; 123 123 *pslat = 70; 124 if(flag) _pprint Line_("Warning: expecting coordinates in polar stereographic (Std Latitude: 70N Meridian: 45).");124 if(flag) _pprintString_("Warning: expecting coordinates in polar stereographic (Std Latitude: 70N Meridian: 45)." << "\n"); 125 125 } 126 126 else if (sgn == -1) { 127 127 *pdelta= 0; 128 128 *pslat = 71; 129 if(flag) _pprint Line_("Warning: expecting coordinates in polar stereographic (Std Latitude: 71S Meridian: 0).");129 if(flag) _pprintString_("Warning: expecting coordinates in polar stereographic (Std Latitude: 71S Meridian: 0)." << "\n"); 130 130 } 131 131 else _error_("Sign should be either +1 or -1.\n"); -
issm/trunk-jpl/src/c/shared/Matrix/MatrixUtils.cpp
r15097 r15099 205 205 pindx[ipiv]++; 206 206 207 // _print Line_("pivot for i=" << i << ": irow=" << irow << ", icol=" << icol << ", pindx[" << ipiv << "]=" << pindx[ipiv]<< "\n");207 // _printString_("pivot for i=" << i << ": irow=" << irow << ", icol=" << icol << ", pindx[" << ipiv << "]=" << pindx[ipiv] << "\n" << "\n"); 208 208 209 209 /* switch rows to put pivot element on diagonal, noting that the … … 211 211 212 212 if (irow != icol) { 213 // _print Line_("row switch for i=" << i << ": irow=" << irow << ", icol=" << icol<< "\n");213 // _printString_("row switch for i=" << i << ": irow=" << irow << ", icol=" << icol << "\n" << "\n"); 214 214 215 215 ipt=irow*ndim; … … 292 292 icol=pivrc2[j]; 293 293 294 // _print Line_("column switch back for j=" << j << ": irow=" << irow << ", icol=" << icol<< "\n");294 // _printString_("column switch back for j=" << j << ": irow=" << irow << ", icol=" << icol << "\n" << "\n"); 295 295 296 296 ipt=0; -
issm/trunk-jpl/src/c/shared/Numerics/BrentSearch.cpp
r14978 r15099 50 50 if (xIsNan<IssmDouble>(fxmin)) _error_("Function evaluation returned NaN"); 51 51 cout<<setprecision(5); 52 if(VerboseControl()) _pprint Line_("");53 if(VerboseControl()) _pprint Line_(" Iteration x f(x) Tolerance Procedure");54 if(VerboseControl()) _pprint Line_("");55 if(VerboseControl()) _pprint Line_(" N/A "<<setw(12)<<xmin<<" "<<setw(12)<<fxmin<<" N/A boundary");52 if(VerboseControl()) _pprintString_("" << "\n"); 53 if(VerboseControl()) _pprintString_(" Iteration x f(x) Tolerance Procedure" << "\n"); 54 if(VerboseControl()) _pprintString_("" << "\n"); 55 if(VerboseControl()) _pprintString_(" N/A "<<setw(12)<<xmin<<" "<<setw(12)<<fxmin<<" N/A boundary" << "\n"); 56 56 fxmax = (*f)(xmax,optargs); 57 57 if (xIsNan<IssmDouble>(fxmax)) _error_("Function evaluation returned NaN"); 58 if(VerboseControl()) _pprint Line_(" N/A "<<setw(12)<<xmax<<" "<<setw(12)<<fxmax<<" N/A boundary");58 if(VerboseControl()) _pprintString_(" N/A "<<setw(12)<<xmax<<" "<<setw(12)<<fxmax<<" N/A boundary" << "\n"); 59 59 60 60 /*test if jump option activated and xmin==0*/ … … 93 93 /*4: print result*/ 94 94 if(VerboseControl()) 95 _pprint Line_(" "<<setw(5)<<iter<<" "<<setw(12)<<xbest<<" "<<setw(12)<<fxbest<<" "<<setw(12)<<pow(pow(xbest-xm,2),0.5)<<" initial");95 _pprintString_(" "<<setw(5)<<iter<<" "<<setw(12)<<xbest<<" "<<setw(12)<<fxbest<<" "<<setw(12)<<pow(pow(xbest-xm,2),0.5)<<" initial" << "\n"); 96 96 if (!xIsNan<IssmDouble>(cm_jump) && (xmin==0) && ((fxbest/fxmin)<cm_jump)){ 97 if(VerboseControl()) _pprint Line_(" optimization terminated: current x satisfies criteria 'cm_jump'=" << cm_jump);97 if(VerboseControl()) _pprintString_(" optimization terminated: current x satisfies criteria 'cm_jump'=" << cm_jump << "\n"); 98 98 loop=false; 99 99 } … … 189 189 tol2=2.0*tol1; 190 190 if(VerboseControl()) 191 _pprint Line_(" "<<setw(5)<<iter<<" "<<setw(12)<<x<<" "<<setw(12)<<fx<<" "<<setw(12)<<pow(pow(xbest-xm,2),0.5)<<191 _pprintString_(" "<<setw(5)<<iter<<" "<<setw(12)<<x<<" "<<setw(12)<<fx<<" "<<setw(12)<<pow(pow(xbest-xm,2),0.5)<< 192 192 " "<<(goldenflag?"golden":"parabolic")); 193 193 194 194 /*Stop the optimization?*/ 195 195 if (sqrt(pow(xbest-xm,2)) < (tol2-0.5*(xmax-xmin))){ 196 if(VerboseControl()) _pprint Line_(" optimization terminated: current x satisfies criteria 'tolx'=" << tolerance);196 if(VerboseControl()) _pprintString_(" optimization terminated: current x satisfies criteria 'tolx'=" << tolerance << "\n"); 197 197 loop=false; 198 198 } 199 199 else if (iter>=maxiter){ 200 if(VerboseControl()) _pprint Line_(" exiting: Maximum number of iterations has been exceeded ('maxiter'=" << maxiter << ")");200 if(VerboseControl()) _pprintString_(" exiting: Maximum number of iterations has been exceeded ('maxiter'=" << maxiter << ")" << "\n"); 201 201 loop=false; 202 202 } 203 203 else if (!xIsNan<IssmDouble>(cm_jump) && (xmin==0) && ((fxbest/fxmin)<cm_jump)){ 204 if(VerboseControl()) _pprint Line_(" optimization terminated: current x satisfies criteria 'cm_jump'=" << cm_jump);204 if(VerboseControl()) _pprintString_(" optimization terminated: current x satisfies criteria 'cm_jump'=" << cm_jump << "\n"); 205 205 loop=false; 206 206 } -
issm/trunk-jpl/src/c/shared/Numerics/GaussPoints.cpp
r15097 r15099 50 50 sizeof(wgt4 )/sizeof(IssmPDouble)}; 51 51 52 // _pprint Line_("Gauss-Legendre recurrence coefficients ngaus=" << ngaus);52 // _pprintString_("Gauss-Legendre recurrence coefficients ngaus=" << ngaus << "\n"); 53 53 *pxgaus =xNew<IssmPDouble>(ngaus); 54 54 *pxwgt =xNew<IssmPDouble>(ngaus); … … 1138 1138 sizeof(wgt20)/sizeof(IssmPDouble)}; 1139 1139 1140 // _pprint Line_("GaussLegendreTria: iord=" << iord);1140 // _pprintString_("GaussLegendreTria: iord=" << iord << "\n"); 1141 1141 1142 1142 /* check to see if Gauss points need to be calculated */ … … 1198 1198 } 1199 1199 1200 // _pprint Line_("GaussLegendreTria - ngaus=" << *pngaus);1200 // _pprintString_("GaussLegendreTria - ngaus=" << *pngaus << "\n"); 1201 1201 // for (i=0; i<*pngaus; i++) 1202 // _pprint Line_("i=" << i << ": l1gaus=" << (*pl1 )[i] << ",l2gaus=" << (*pl2 )[i] << ",l3gaus=" << (*pl3 )[i]<< ",wgt=" << (*pwgt)[i]<< "\n");1202 // _pprintString_("i=" << i << ": l1gaus=" << (*pl1 )[i] << ",l2gaus=" << (*pl2 )[i] << ",l3gaus=" << (*pl3 )[i]<< ",wgt=" << (*pwgt)[i]<< "\n" << "\n"); 1203 1203 1204 1204 return; … … 1396 1396 sizeof(wgt6 )/sizeof(IssmPDouble)}; 1397 1397 1398 // _pprint Line_("GaussLegendreTetra: iord=" << iord);1398 // _pprintString_("GaussLegendreTetra: iord=" << iord << "\n"); 1399 1399 1400 1400 /* check to see if Gauss points need to be calculated */ … … 1519 1519 sizeof(wgt5 )/sizeof(IssmPDouble)}; 1520 1520 1521 // _pprint Line_("Gauss-Lobatto recurrence coefficients ngaus=" << ngaus);1521 // _pprintString_("Gauss-Lobatto recurrence coefficients ngaus=" << ngaus << "\n"); 1522 1522 *pxgaus =xNew<IssmPDouble>(ngaus); 1523 1523 *pxwgt =xNew<IssmPDouble>(ngaus); -
issm/trunk-jpl/src/c/shared/Numerics/OptimalSearch.cpp
r14979 r15099 47 47 if (xIsNan<IssmDouble>(fx1)) _error_("Function evaluation returned NaN"); 48 48 cout<<setprecision(5); 49 if(VerboseControl()) _pprint Line_("");50 if(VerboseControl()) _pprint Line_(" Iteration x f(x) Tolerance");51 if(VerboseControl()) _pprint Line_("");52 if(VerboseControl()) _pprint Line_(" N/A "<<setw(12)<<x1<<" "<<setw(12)<<fx1<<" N/A");49 if(VerboseControl()) _pprintString_("" << "\n"); 50 if(VerboseControl()) _pprintString_(" Iteration x f(x) Tolerance" << "\n"); 51 if(VerboseControl()) _pprintString_("" << "\n"); 52 if(VerboseControl()) _pprintString_(" N/A "<<setw(12)<<x1<<" "<<setw(12)<<fx1<<" N/A" << "\n"); 53 53 54 54 //update tolerances … … 63 63 if (xIsNan<IssmDouble>(fx2)) _error_("Function evaluation returned NaN"); 64 64 if(VerboseControl()) 65 _pprint Line_(" "<<setw(5)<<iter<<" "<<setw(12)<<x2<<" "<<setw(12)<<fx2<<" "<<(fabs(x2-x1)>fabs(fx2-fx1)?fabs(fx2-fx1):fabs(x2-x1)));65 _pprintString_(" "<<setw(5)<<iter<<" "<<setw(12)<<x2<<" "<<setw(12)<<fx2<<" "<<(fabs(x2-x1)>fabs(fx2-fx1)?fabs(fx2-fx1):fabs(x2-x1)) << "\n"); 66 66 67 67 //Stop the optimization? 68 68 if ((fabs(x2-x1)+seps)<tolerance || (fabs(fx2-fx1)+seps)<tolerance){ 69 if(VerboseControl()) _pprint Line_(" " << "optimization terminated: the current x satisfies the termination criteria using 'tolx' of " << tolerance);69 if(VerboseControl()) _pprintString_(" " << "optimization terminated: the current x satisfies the termination criteria using 'tolx' of " << tolerance << "\n"); 70 70 loop=false; 71 71 } 72 72 else if (iter>=maxiter){ 73 if(VerboseControl()) _pprint Line_(" " << "exiting: Maximum number of iterations has been exceeded - increase 'maxiter'");73 if(VerboseControl()) _pprintString_(" " << "exiting: Maximum number of iterations has been exceeded - increase 'maxiter'" << "\n"); 74 74 loop=false; 75 75 } -
issm/trunk-jpl/src/c/shared/io/Print/Print.h
r15097 r15099 19 19 using namespace std; 20 20 /*macros:*/ 21 /* _printLine_ {{{*/22 /* macro to print a line, adds std::endl, only on cpu 0 */23 #define _printLine_(StreamArgs)\24 do{std::ostringstream aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy; \25 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs << std::ends; \26 PrintfFunction3(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0)27 /*}}}*/28 21 /* _printString_ {{{*/ 29 22 /* macro to print some string. Only on cpu0 */ 30 23 #define _printString_(StreamArgs)\ 31 24 do{std::ostringstream aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy; \ 32 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs << std::ends; \ 33 PrintfFunction4(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 34 /*}}}*/ 35 /* _pprintLine_ {{{*/ 36 /* macro to print a line, adds std::endl, only on cpu 0 */ 37 #define _pprintLine_(StreamArgs)\ 38 do{std::ostringstream aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy; \ 39 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs << std::ends; \ 40 PrintfFunction(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 25 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs; \ 26 PrintfFunctionOnAllCpus(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 41 27 /*}}}*/ 42 28 /* _pprintString_ {{{*/ … … 44 30 #define _pprintString_(StreamArgs)\ 45 31 do{std::ostringstream aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy; \ 46 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs << std::ends; \ 47 PrintfFunction2(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 48 /*}}}*/ 49 50 /* _printLine_ {{{*/ 51 /* macro to print a line, adds std::endl, only on cpu 0 */ 52 #define _printLine_(StreamArgs)\ 53 do{std::ostringstream aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy; \ 54 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs << std::ends; \ 55 PrintfFunction3(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 32 aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy << StreamArgs; \ 33 PrintfFunctionOnCpu0(aLoNgAnDwEiRdLoCaLnAmeFoRtHiSmAcRoOnLy.str());}while(0) 56 34 /*}}}*/ 57 35 58 36 /*functions: */ 59 int PrintfFunction(const char* format,...); 60 int PrintfFunction(const string & message); 61 int PrintfFunction2(const string & message); 62 int PrintfFunction3(const string & message); 63 int PrintfFunction4(const string & message); 37 int PrintfFunctionOnCpu0(const string & message); 38 int PrintfFunctionOnAllCpus(const string & message); 64 39 65 40 #endif -
issm/trunk-jpl/src/c/shared/io/Print/PrintfFunction.cpp
r15097 r15099 1 1 /*\file PrintfFunction.c 2 *\brief: this function is used by the print macros, to take into account the2 *\brief: this function is used by the _printf_ macro, to take into account the 3 3 *fact we may be running on a cluster. 4 4 */ … … 20 20 #include "../../MemOps/MemOps.h" 21 21 22 int PrintfFunction(const char* format,...){ 23 /*http://linux.die.net/man/3/vsnprintf*/ 24 25 /*string to be printed: */ 26 char *buffer = NULL; 27 int n,size = 100; 28 int my_rank; 29 //variable list of arguments 30 va_list args; 31 32 /*recover my_rank:*/ 33 my_rank=IssmComm::GetRank(); 34 35 while(true){ 36 37 /*allocate buffer for given string size*/ 38 buffer=xNew<char>(size); 39 40 /* Try to print in the allocated space. */ 41 va_start(args, format); 42 n=vsnprintf(buffer,size,format,args); 43 va_end(args); 44 45 /* If that worked, return the string. */ 46 if(n>-1 && n<size) break; 47 48 /* Else try again with more space. */ 49 if(n>-1) /* glibc 2.1 */ 50 size=n+1; /* precisely what is needed */ 51 else /* glibc 2.0 */ 52 size*=2; /* twice the old size */ 53 54 xDelete<char>(buffer); 55 } 56 57 /*Ok, if we are running in parallel, get node 0 to print*/ 58 if(my_rank==0)_printString_(buffer); 59 60 /*Clean up and return*/ 61 xDelete<char>(buffer); 62 return 1; 63 } 64 int PrintfFunction(const string & message){ 22 int PrintfFunctionOnCpu0(const string & message){ 65 23 int my_rank; 66 24 … … 72 30 __android_log_print(ANDROID_LOG_INFO, "Native",message.c_str()); 73 31 #else 74 ApiPrintf("%s \n",message.c_str());32 ApiPrintf("%s",message.c_str()); 75 33 #endif 76 34 } 77 35 return 1; 78 36 } 79 int PrintfFunction2(const string & message){ 80 int my_rank; 81 82 /*recover my_rank:*/ 83 my_rank=IssmComm::GetRank(); 84 85 if(my_rank==0){ 86 ApiPrintf("%s",message.c_str()); 87 } 88 return 1; 89 } 90 int PrintfFunction3(const string & message){ 37 int PrintfFunctionOnAllCpus(const string & message){ 91 38 92 39 #ifdef _HAVE_ANDROID_JNI_ 93 40 __android_log_print(ANDROID_LOG_INFO, "Native",message.c_str()); 94 41 #else 95 ApiPrintf("%s \n",message.c_str());42 ApiPrintf("%s",message.c_str()); 96 43 #endif 97 44 98 45 return 1; 99 46 } 100 int PrintfFunction4(const string & message){101 102 ApiPrintf("%s",message.c_str());103 104 return 1;105 } -
issm/trunk-jpl/src/c/solutionsequences/convergence.cpp
r15055 r15099 30 30 IssmDouble yts; 31 31 32 if(VerboseModule()) _pprint Line_(" checking convergence");32 if(VerboseModule()) _pprintString_(" checking convergence" << "\n"); 33 33 34 34 /*If uf is NULL in input, f-set is nil, model is fully constrained, therefore converged from … … 56 56 nF=pf->Norm(NORM_TWO); 57 57 solver_residue=nKUF/nF; 58 _pprint Line_("\n" << " solver residue: norm(KU-F)/norm(F)=" << solver_residue);58 _pprintString_("\n" << " solver residue: norm(KU-F)/norm(F)=" << solver_residue << "\n"); 59 59 60 60 //clean up … … 73 73 res=nKUoldF/nF; 74 74 if (xIsNan<IssmDouble>(res)){ 75 _pprint Line_("norm nf = " << nF << "f and norm kuold = " << nKUoldF << "f");75 _pprintString_("norm nf = " << nF << "f and norm kuold = " << nKUoldF << "f" << "\n"); 76 76 _error_("mechanical equilibrium convergence criterion is NaN!"); 77 77 } … … 83 83 //print 84 84 if(res<eps_res){ 85 if(VerboseConvergence()) _pprint Line_(setw(50)<<left<<" mechanical equilibrium convergence criterion"<<res*100<< " < "<<eps_res*100<<" %");85 if(VerboseConvergence()) _pprintString_(setw(50)<<left<<" mechanical equilibrium convergence criterion"<<res*100<< " < "<<eps_res*100<<" %" << "\n"); 86 86 converged=true; 87 87 } 88 88 else{ 89 if(VerboseConvergence()) _pprint Line_(setw(50)<<left<<" mechanical equilibrium convergence criterion"<<res*100<<" > "<<eps_res*100<<" %");89 if(VerboseConvergence()) _pprintString_(setw(50)<<left<<" mechanical equilibrium convergence criterion"<<res*100<<" > "<<eps_res*100<<" %" << "\n"); 90 90 converged=false; 91 91 } … … 106 106 if (!xIsNan<IssmDouble>(eps_rel)){ 107 107 if((ndu/nu)<eps_rel){ 108 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " < " << eps_rel*100 << " %");108 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " < " << eps_rel*100 << " %" << "\n"); 109 109 } 110 110 else{ 111 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " > " << eps_rel*100 << " %");111 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " > " << eps_rel*100 << " %" << "\n"); 112 112 converged=false; 113 113 } 114 114 } 115 else _pprint Line_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " %");115 else _pprintString_(setw(50) << left << " Convergence criterion: norm(du)/norm(u)" << ndu/nu*100 << " %" << "\n"); 116 116 117 117 } … … 131 131 if (!xIsNan<IssmDouble>(eps_abs)){ 132 132 if ((nduinf*yts)<eps_abs){ 133 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " < " << eps_abs << " m/yr");133 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " < " << eps_abs << " m/yr" << "\n"); 134 134 } 135 135 else{ 136 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " > " << eps_abs << " m/yr");136 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " > " << eps_abs << " m/yr" << "\n"); 137 137 converged=false; 138 138 } 139 139 } 140 else _pprint Line_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " m/yr");140 else _pprintString_(setw(50) << left << " Convergence criterion: max(du)" << nduinf*yts << " m/yr" << "\n"); 141 141 142 142 } -
issm/trunk-jpl/src/c/solutionsequences/solutionsequence_hydro_nonlinear.cpp
r15077 r15099 91 91 92 92 if (!sedconverged){ 93 if(VerboseConvergence()) _pprint Line_(" #unstable constraints = " << num_unstable_constraints);93 if(VerboseConvergence()) _pprintString_(" #unstable constraints = " << num_unstable_constraints << "\n"); 94 94 if(num_unstable_constraints==0) sedconverged = true; 95 95 if (sedcount>=hydro_maxiter){ … … 131 131 132 132 if (!eplconverged){ 133 if(VerboseConvergence()) _pprint Line_(" #unstable constraints = " << num_unstable_constraints);133 if(VerboseConvergence()) _pprintString_(" #unstable constraints = " << num_unstable_constraints << "\n"); 134 134 if(num_unstable_constraints==0) eplconverged = true; 135 135 if (eplcount>=hydro_maxiter){ … … 164 164 if (!xIsNan<IssmDouble>(eps_hyd)){ 165 165 if((ndu_sed/nu_sed)<eps_hyd){ 166 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Sediment Convergence criterion:" << ndu_sed/nu_sed*100 << " < " << eps_hyd*100 << " %");166 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Sediment Convergence criterion:" << ndu_sed/nu_sed*100 << " < " << eps_hyd*100 << " %" << "\n"); 167 167 hydroconverged=true; 168 168 } 169 169 else{ 170 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " Sediment Convergence criterion:" << ndu_sed/nu_sed*100 << " > " << eps_hyd*100 << " %");170 if(VerboseConvergence()) _pprintString_(setw(50) << left << " Sediment Convergence criterion:" << ndu_sed/nu_sed*100 << " > " << eps_hyd*100 << " %" << "\n"); 171 171 hydroconverged=false; 172 172 } 173 173 if(isefficientlayer){ 174 174 if((ndu_epl/nu_epl)<eps_hyd){ 175 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " EPL Convergence criterion:" << ndu_epl/nu_epl*100 << " < " << eps_hyd*100 << " %");175 if(VerboseConvergence()) _pprintString_(setw(50) << left << " EPL Convergence criterion:" << ndu_epl/nu_epl*100 << " < " << eps_hyd*100 << " %" << "\n"); 176 176 } 177 177 else{ 178 if(VerboseConvergence()) _pprint Line_(setw(50) << left << " EPL Convergence criterion:" << ndu_epl/nu_epl*100 << " > " << eps_hyd*100 << " %");178 if(VerboseConvergence()) _pprintString_(setw(50) << left << " EPL Convergence criterion:" << ndu_epl/nu_epl*100 << " > " << eps_hyd*100 << " %" << "\n"); 179 179 hydroconverged=false; 180 180 } 181 181 } 182 182 } 183 else _pprint Line_(setw(50) << left << " Convergence criterion:" << ndu_sed/nu_sed*100 << " %");183 else _pprintString_(setw(50) << left << " Convergence criterion:" << ndu_sed/nu_sed*100 << " %" << "\n"); 184 184 if (hydrocount>=hydro_maxiter){ 185 185 _error_(" maximum number for hydrological global iterations (" << hydro_maxiter << ") exceeded"); -
issm/trunk-jpl/src/c/solutionsequences/solutionsequence_newton.cpp
r15055 r15099 93 93 } 94 94 if(count>=max_nonlinear_iterations){ 95 _pprint Line_(" maximum number of Newton iterations (" << max_nonlinear_iterations << ") exceeded");95 _pprintString_(" maximum number of Newton iterations (" << max_nonlinear_iterations << ") exceeded" << "\n"); 96 96 bool max_iteration_state=true; 97 97 int tempStep=1; … … 104 104 } 105 105 106 if(VerboseConvergence()) _pprint Line_("\n total number of iterations: " << count-1);106 if(VerboseConvergence()) _pprintString_("\n total number of iterations: " << count-1 << "\n"); 107 107 108 108 /*clean-up*/ -
issm/trunk-jpl/src/c/solutionsequences/solutionsequence_nonlinear.cpp
r15058 r15099 70 70 71 71 ConstraintsStatex(&constraints_converged, &num_unstable_constraints, femmodel->elements,femmodel->nodes,femmodel->vertices,femmodel->loads,femmodel->materials,femmodel->parameters); 72 if(VerboseConvergence()) _pprint Line_(" number of unstable constraints: " << num_unstable_constraints);72 if(VerboseConvergence()) _pprintString_(" number of unstable constraints: " << num_unstable_constraints << "\n"); 73 73 74 74 //rift convergence … … 90 90 } 91 91 if(count>=max_nonlinear_iterations){ 92 _pprint Line_(" maximum number of nonlinear iterations (" << max_nonlinear_iterations << ") exceeded");92 _pprintString_(" maximum number of nonlinear iterations (" << max_nonlinear_iterations << ") exceeded" << "\n"); 93 93 converged=true; 94 94 InputUpdateFromConstantx( femmodel->elements,femmodel->nodes, femmodel->vertices, femmodel->loads, femmodel->materials, femmodel->parameters,converged,ConvergedEnum); … … 102 102 } 103 103 104 if(VerboseConvergence()) _pprint Line_("\n total number of iterations: " << count-1);104 if(VerboseConvergence()) _pprintString_("\n total number of iterations: " << count-1 << "\n"); 105 105 106 106 /*clean-up*/ -
issm/trunk-jpl/src/c/solutionsequences/solutionsequence_stokescoupling_nonlinear.cpp
r15055 r15099 89 89 if(converged==true)break; 90 90 if(count>=max_nonlinear_iterations){ 91 _pprint Line_(" maximum number of iterations (" << max_nonlinear_iterations << ") exceeded");91 _pprintString_(" maximum number of iterations (" << max_nonlinear_iterations << ") exceeded" << "\n"); 92 92 break; 93 93 } -
issm/trunk-jpl/src/c/solutionsequences/solutionsequence_thermal_nonlinear.cpp
r15002 r15099 59 59 60 60 if (!converged){ 61 if(VerboseConvergence()) _pprint Line_(" #unstable constraints = " << num_unstable_constraints);61 if(VerboseConvergence()) _pprintString_(" #unstable constraints = " << num_unstable_constraints << "\n"); 62 62 if (num_unstable_constraints <= thermal_penalty_threshold)converged=true; 63 63 if (count>=thermal_maxiter){ 64 64 converged=true; 65 _pprint Line_(" maximum number of iterations (" << thermal_maxiter << ") exceeded");65 _pprintString_(" maximum number of iterations (" << thermal_maxiter << ") exceeded" << "\n"); 66 66 } 67 67 } -
issm/trunk-jpl/src/c/toolkits/issm/Bucket.h
r15070 r15099 88 88 /*object virtual functions definitions:*/ 89 89 void Echo(){ /*{{{*/ 90 _print Line_("Bucket echo (cpu #: "<<IssmComm::GetRank()<<")");91 _print Line_("bucket type: " << type);92 _print Line_("num rows: "<<this->m<<" num cols: "<<this->n);90 _printString_("Bucket echo (cpu #: "<<IssmComm::GetRank()<<")" << "\n"); 91 _printString_("bucket type: " << type << "\n"); 92 _printString_("num rows: "<<this->m<<" num cols: "<<this->n << "\n"); 93 93 } /*}}}*/ 94 94 void DeepEcho(){ /*{{{*/ 95 95 int i,j; 96 96 97 _print Line_("Bucket echo (cpu #: "<<IssmComm::GetRank()<<")");98 _print Line_("bucket type: " << type);99 _print Line_("num rows: "<<this->m<<" num cols: "<<this->n);97 _printString_("Bucket echo (cpu #: "<<IssmComm::GetRank()<<")" << "\n"); 98 _printString_("bucket type: " << type << "\n"); 99 _printString_("num rows: "<<this->m<<" num cols: "<<this->n << "\n"); 100 100 if(type==MATRIX_BUCKET){ 101 101 for (i=0;i<this->m;i++){ 102 _print Line_("row "<<this->idxm[i]<<", column indices:");102 _printString_("row "<<this->idxm[i]<<", column indices: " << "\n"); 103 103 for (j=0;j<this->n;j++){ 104 _print Line_(" "<<this->idxn[j]);105 } 106 _print Line_("values:");104 _printString_(" "<<this->idxn[j] << "\n"); 105 } 106 _printString_("values: " << "\n"); 107 107 for (j=0;j<this->n;j++){ 108 _print Line_(" "<<this->values[m*i+j]);108 _printString_(" "<<this->values[m*i+j] << "\n"); 109 109 } 110 110 } … … 112 112 else if(type==VECTOR_BUCKET){ 113 113 for (i=0;i<this->m;i++){ 114 _print Line_("row "<<this->idxm[i]<<", value " << this->values[i]);114 _printString_("row "<<this->idxm[i]<<", value " << this->values[i] << "\n"); 115 115 } 116 116 } -
issm/trunk-jpl/src/c/toolkits/issm/IssmDenseMat.h
r15070 r15099 115 115 116 116 int i,j; 117 _print Line_("IssmDenseMat size " << this->M << "-" << this->N);117 _printString_("IssmDenseMat size " << this->M << "-" << this->N << "\n"); 118 118 for(i=0;i<M;i++){ 119 119 for(j=0;j<N;j++){ 120 120 _printString_(this->matrix[N*i+j] << " "); 121 121 } 122 _print Line_("");122 _printString_("" << "\n"); 123 123 } 124 124 } -
issm/trunk-jpl/src/c/toolkits/issm/IssmMpiDenseMat.h
r15070 r15099 144 144 for(i=0;i<IssmComm::GetSize();i++){ 145 145 if (my_rank==i){ 146 _print Line_("cpu " << i << " #rows: " << this->m);146 _printString_("cpu " << i << " #rows: " << this->m << "\n"); 147 147 for (j=0;j<this->m;j++){ 148 _print Line_("row " << j);148 _printString_("row " << j << "\n"); 149 149 for (k=0;k<this->N;k++){ 150 _print Line_(this->matrix[j*this->N+k] << "");150 _printString_(this->matrix[j*this->N+k] << " " << "\n"); 151 151 } 152 _print Line_("");152 _printString_("" << "\n"); 153 153 } 154 154 } -
issm/trunk-jpl/src/c/toolkits/issm/IssmMpiVec.h
r14950 r15099 132 132 for(i=0;i<IssmComm::GetSize();i++){ 133 133 if (IssmComm::GetRank()==i){ 134 _print Line_("cpu " << i << " #rows: " << this->m);134 _printString_("cpu " << i << " #rows: " << this->m << "\n"); 135 135 for (j=0;j<this->m;j++){ 136 _print Line_("row " << j << " " << this->vector[j]);136 _printString_("row " << j << " " << this->vector[j] << "\n"); 137 137 } 138 _print Line_("");138 _printString_("" << "\n"); 139 139 } 140 140 MPI_Barrier(IssmComm::GetComm()); -
issm/trunk-jpl/src/c/toolkits/issm/IssmSeqVec.h
r14998 r15099 91 91 92 92 int i; 93 _print Line_("IssmSeqVec size " << this->M);93 _printString_("IssmSeqVec size " << this->M << "\n"); 94 94 for(i=0;i<M;i++){ 95 95 _printString_(vector[i] << "\n "); -
issm/trunk-jpl/src/c/toolkits/petsc/objects/PetscMat.cpp
r14441 r15099 93 93 MatInfo info; 94 94 MatGetInfo(this->matrix,MAT_GLOBAL_SUM,&info); 95 _pprint Line_("=========================== Stiffness matrix allocation info ===========================");96 _pprint Line_("");97 _pprint Line_(" Block size : "<<info.block_size);98 _pprint Line_(" nz_allocated: "<<info.nz_allocated);99 _pprint Line_(" nz_used : "<<info.nz_used);100 _pprint Line_(" nz_unneeded : "<<info.nz_unneeded<<" ("<<double(info.nz_unneeded)/double(info.nz_allocated)*100.<<"%)");101 _pprint Line_("");102 _pprint Line_("========================================================================================");95 _pprintString_("=========================== Stiffness matrix allocation info ===========================" << "\n"); 96 _pprintString_("" << "\n"); 97 _pprintString_(" Block size : "<<info.block_size << "\n"); 98 _pprintString_(" nz_allocated: "<<info.nz_allocated << "\n"); 99 _pprintString_(" nz_used : "<<info.nz_used << "\n"); 100 _pprintString_(" nz_unneeded : "<<info.nz_unneeded<<" ("<<double(info.nz_unneeded)/double(info.nz_allocated)*100.<<"%)" << "\n"); 101 _pprintString_("" << "\n"); 102 _pprintString_("========================================================================================" << "\n"); 103 103 } 104 104 /*}}}*/ -
issm/trunk-jpl/src/wrappers/AverageFilter/AverageFilter.cpp
r15008 r15099 13 13 14 14 void AverageFilterUsage(void){/*{{{*/ 15 _print Line_(" AverageFilter usage:");16 _print Line_(" [image_out]=AverageFilter(image_in,pixels);\n");17 _print Line_(" where:");18 _print Line_(" image_in in double format");19 _print Line_(" pixels: characteristic size of smoothing");20 _print Line_(" image_out in double format");21 _print Line_("");15 _printString_(" AverageFilter usage:" << "\n"); 16 _printString_(" [image_out]=AverageFilter(image_in,pixels)" << "\n"); 17 _printString_(" where:" << "\n"); 18 _printString_(" image_in in double format" << "\n"); 19 _printString_(" pixels: characteristic size of smoothing" << "\n"); 20 _printString_(" image_out in double format" << "\n"); 21 _printString_("" << "\n"); 22 22 }/*}}}*/ 23 23 WRAPPER(AverageFilter){ -
issm/trunk-jpl/src/wrappers/BamgConvertMesh/BamgConvertMesh.cpp
r15008 r15099 6 6 void BamgConvertMeshUsage(void){/*{{{*/ 7 7 _pprintString_("BAMGCONVERTMESH - convert [x y index] to a bamg geom and mesh geom"); 8 _pprint Line_("");9 _pprint Line_(" Usage:");10 _pprint Line_(" [bamggeom bamgmesh]=BamgConvertMesh(index,x,y);");11 _pprint Line_(" index: index of the mesh");12 _pprint Line_(" x,y: coordinates of the nodes");13 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" Usage:" << "\n"); 10 _pprintString_(" [bamggeom bamgmesh]=BamgConvertMesh(index,x,y)" << "\n"); 11 _pprintString_(" index: index of the mesh" << "\n"); 12 _pprintString_(" x,y: coordinates of the nodes" << "\n"); 13 _pprintString_("" << "\n"); 14 14 }/*}}}*/ 15 15 WRAPPER(BamgConvertMesh){ -
issm/trunk-jpl/src/wrappers/BamgMesher/BamgMesher.cpp
r15008 r15099 5 5 6 6 void BamgMesherUsage(void){/*{{{*/ 7 _pprint Line_("");8 _pprint Line_(" usage: [bamgmesh,bamggeom]=" << __FUNCT__ << "(bamgmesh,bamggeom,bamgoptions);");9 _pprint Line_("");7 _pprintString_("" << "\n"); 8 _pprintString_(" usage: [bamgmesh,bamggeom]=" << __FUNCT__ << "(bamgmesh,bamggeom,bamgoptions)" << "\n"); 9 _pprintString_("" << "\n"); 10 10 }/*}}}*/ 11 11 WRAPPER(BamgMesher){ -
issm/trunk-jpl/src/wrappers/BamgTriangulate/BamgTriangulate.cpp
r15008 r15099 6 6 void BamgTriangulateUsage(void){/*{{{*/ 7 7 _pprintString_("BAMGTRIANGULATE - Delaunay Triangulation of a list of points"); 8 _pprint Line_("");9 _pprint Line_(" Usage:");10 _pprint Line_(" index=BamgTriangulate(x,y);");11 _pprint Line_(" index: index of the triangulation");12 _pprint Line_(" x,y: coordinates of the nodes");13 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" Usage:" << "\n"); 10 _pprintString_(" index=BamgTriangulate(x,y);" << "\n"); 11 _pprintString_(" index: index of the triangulation" << "\n"); 12 _pprintString_(" x,y: coordinates of the nodes" << "\n"); 13 _pprintString_("" << "\n"); 14 14 }/*}}}*/ 15 15 WRAPPER(BamgTriangulate){ … … 36 36 37 37 /*Input datasets: */ 38 if (verbose) _print Line_("Fetching inputs");38 if (verbose) _printString_("Fetching inputs" << "\n"); 39 39 FetchData(&x,&nods,&x_cols,XHANDLE); 40 40 FetchData(&y,&y_rows,&y_cols,YHANDLE); … … 46 46 47 47 /* Run core computations: */ 48 if (verbose) _print Line_("Call core");48 if (verbose) _printString_("Call core" << "\n"); 49 49 BamgTriangulatex(&index,&nels,x,y,nods); 50 50 -
issm/trunk-jpl/src/wrappers/Chaco/Chaco.cpp
r13250 r15099 12 12 13 13 void ChacoUsage(void){/*{{{*/ 14 _pprint Line_("");15 _pprint Line_("Usage: [assgn] = Chaco(A,vwgts,ewgts,x,y,z,options,nparts,goal);");16 _pprint Line_("");14 _pprintString_("" << "\n"); 15 _pprintString_("Usage: [assgn] = Chaco(A,vwgts,ewgts,x,y,z,options,nparts,goal);" << "\n"); 16 _pprintString_("" << "\n"); 17 17 }/*}}}*/ 18 18 WRAPPER(Chaco){ … … 86 86 /*Some debugging print: {{{*/ 87 87 #ifdef _DEBUG_ 88 _print Line_("nvtxs: " << nvtxs);88 _printString_("nvtxs: " << nvtxs << "\n"); 89 89 _printString_("options: ["); 90 90 for(i=0;i<10;i++)_printString_(options[i] << "|"); 91 _print Line_("]");92 _print Line_("start:");91 _printString_("]" << "\n"); 92 _printString_("start: " << "\n"); 93 93 for (i=0; i<nvtxs+1;i++)_printString_(start[i] << " "); 94 _print Line_("");95 _print Line_("adjacency:");94 _printString_("" << "\n"); 95 _printString_("adjacency: " << "\n"); 96 96 for (i=0; i<mxGetNzmax(A_IN);i++)_printString_("" <<adjacency[i]<< " ");i++) 97 _print Line_("");98 _print Line_("nedges: " << nedges << " " << ewgts);97 _printString_("" << "\n"); 98 _printString_("nedges: " << nedges << " " << ewgts << "\n"); 99 99 if(ewgts) for (i = 0; i < nedges; i++)_printString_(ewgts[i] << " "); 100 _print Line_("");101 _print Line_("vwgts:");100 _printString_("" << "\n"); 101 _printString_("vwgts:" << "\n"); 102 102 for (i = 0; i < nvtxs; i++)_printString_(vwgts[i] << " "); 103 _print Line_("");104 _print Line_("nparts: " << nparts[0]);105 _print Line_("goal: " << goal);103 _printString_("" << "\n"); 104 _printString_("nparts: " << nparts[0] << "\n"); 105 _printString_("goal: " << goal << "\n"); 106 106 #endif 107 107 /*}}}*/ -
issm/trunk-jpl/src/wrappers/ContourToMesh/ContourToMesh.cpp
r15008 r15099 7 7 8 8 void ContourToMeshUsage(void){/*{{{*/ 9 _print Line_("CONTOURTOMESH - Flag the elements or nodes inside a contour");10 _print Line_("");11 _print Line_(" Usage:");12 _print Line_(" [in_nod,in_elem]=ContourToMesh(index,x,y,contourname,interptype,edgevalue)\n");13 _print Line_("");14 _print Line_(" index,x,y: mesh triangulation.");15 _print Line_(" contourname: name of .exp file containing the contours.");16 _print Line_(" interptype: string definining type of interpolation ('element', or 'node').");17 _print Line_(" edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");18 _print Line_(" in_nod: vector of flags (0 or 1), of size nods if interptype is set to 'node' or 'element and node',");19 _print Line_(" or of size 0 otherwise.");20 _print Line_(" in_elem: vector of flags (0 or 1), of size nel if interptype is set to 'element' or 'element and node',");21 _print Line_(" or of size 0 otherwise.");22 _print Line_("");23 _print Line_(" Example:");24 _print Line_(" in_nod=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','node',1)");25 _print Line_(" in_elements=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element',0)");26 _print Line_(" [in_nodes,in_elements]=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element and node',0)");27 _print Line_("");9 _printString_("CONTOURTOMESH - Flag the elements or nodes inside a contour" << "\n"); 10 _printString_("" << "\n"); 11 _printString_(" Usage: " << "\n"); 12 _printString_(" [in_nod,in_elem]=ContourToMesh(index,x,y,contourname,interptype,edgevalue)" << "\n"); 13 _printString_("" << "\n"); 14 _printString_(" index,x,y: mesh triangulation." << "\n"); 15 _printString_(" contourname: name of .exp file containing the contours." << "\n"); 16 _printString_(" interptype: string definining type of interpolation ('element', or 'node')." << "\n"); 17 _printString_(" edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons." << "\n"); 18 _printString_(" in_nod: vector of flags (0 or 1), of size nods if interptype is set to 'node' or 'element and node', " << "\n"); 19 _printString_(" or of size 0 otherwise." << "\n"); 20 _printString_(" in_elem: vector of flags (0 or 1), of size nel if interptype is set to 'element' or 'element and node', " << "\n"); 21 _printString_(" or of size 0 otherwise." << "\n"); 22 _printString_("" << "\n"); 23 _printString_(" Example: " << "\n"); 24 _printString_(" in_nod=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','node',1)" << "\n"); 25 _printString_(" in_elements=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element',0)" << "\n"); 26 _printString_(" [in_nodes,in_elements]=ContourToMesh(md.elements,md.x,md.y,'Contour.exp','element and node',0)" << "\n"); 27 _printString_("" << "\n"); 28 28 }/*}}}*/ 29 29 WRAPPER(ContourToMesh){ -
issm/trunk-jpl/src/wrappers/ContourToNodes/ContourToNodes.cpp
r15008 r15099 6 6 7 7 void ContourToNodesUsage(void){/*{{{*/ 8 _print Line_(" usage:");9 _print Line_(" [flags]=ContourToNodes(x,y,contourname,edgevalue);\n");10 _print Line_(" where:");11 _print Line_(" x,y: list of nodes.");12 _print Line_(" contourname: name of .exp file containing the contours, or resulting structure from call to expread.");13 _print Line_(" edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons.");14 _print Line_(" flags: vector of flags (0 or 1), of size nods.");15 _print Line_("");8 _printString_(" usage:" << "\n"); 9 _printString_(" [flags]=ContourToNodes(x,y,contourname,edgevalue);" << "\n"); 10 _printString_(" where:" << "\n"); 11 _printString_(" x,y: list of nodes." << "\n"); 12 _printString_(" contourname: name of .exp file containing the contours, or resulting structure from call to expread." << "\n"); 13 _printString_(" edgevalue: integer (0, 1 or 2) defining the value associated to the nodes on the edges of the polygons." << "\n"); 14 _printString_(" flags: vector of flags (0 or 1), of size nods." << "\n"); 15 _printString_("" << "\n"); 16 16 }/*}}}*/ 17 17 WRAPPER(ContourToNodes){ -
issm/trunk-jpl/src/wrappers/EdgeDetection/EdgeDetection.cpp
r15008 r15099 6 6 7 7 void EdgeDetectionUsage(void){/*{{{*/ 8 _pprint Line_("EDGEDETECTION usage- detect edges of a boolean image");9 _pprint Line_("");10 _pprint Line_(" Usage:");11 _pprint Line_(" contours=EdgeDetection(image);");12 _pprint Line_("");13 _pprint Line_(" image: boolean matrix");14 _pprint Line_("");15 _pprint Line_(" Example:");16 _pprint Line_(" load('velocities.mat');");17 _pprint Line_(" md.inversion.vx_obs=EdgeDetection(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);");18 _pprint Line_("");8 _pprintString_("EDGEDETECTION usage- detect edges of a boolean image" << "\n"); 9 _pprintString_("" << "\n"); 10 _pprintString_(" Usage:" << "\n"); 11 _pprintString_(" contours=EdgeDetection(image);" << "\n"); 12 _pprintString_("" << "\n"); 13 _pprintString_(" image: boolean matrix" << "\n"); 14 _pprintString_("" << "\n"); 15 _pprintString_(" Example:" << "\n"); 16 _pprintString_(" load('velocities.mat');" << "\n"); 17 _pprintString_(" md.inversion.vx_obs=EdgeDetection(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);" << "\n"); 18 _pprintString_("" << "\n"); 19 19 }/*}}}*/ 20 20 WRAPPER(EdgeDetection){ -
issm/trunk-jpl/src/wrappers/ElementConnectivity/ElementConnectivity.cpp
r15008 r15099 6 6 7 7 void ElementConnectivityUsage(void) {/*{{{*/ 8 _pprint Line_("");9 _pprint Line_(" usage: elementconnectivity = " << __FUNCT__ << "(elements, nodeconnectivity);");10 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" usage: elementconnectivity = " << __FUNCT__ << "(elements, nodeconnectivity);" << "\n"); 10 _pprintString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(ElementConnectivity){ -
issm/trunk-jpl/src/wrappers/EnumToString/EnumToString.cpp
r15008 r15099 6 6 7 7 void EnumToStringUsage(void){/*{{{*/ 8 _pprint Line_("");9 _pprint Line_(" usage: " << __FUNCT__ << "string = EnumToString(enum);");10 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" usage: " << __FUNCT__ << "string = EnumToString(enum);" << "\n"); 10 _pprintString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(EnumToString){ -
issm/trunk-jpl/src/wrappers/Exp2Kml/Exp2Kml.cpp
r13250 r15099 5 5 6 6 void Exp2KmlUsage(void){/*{{{*/ 7 _pprint Line_("Exp2Kml - exp to kml file conversion module:");8 _pprint Line_("");9 _pprint Line_(" This module converts a file from exp to kml format.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" [ret]=Exp2Kml(filexp,filkml,sgn,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" filexp file name of exp file to be read (char)");15 _pprint Line_(" filkml file name of kml file to be written (char)");16 _pprint Line_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))");17 _pprint Line_("");18 _pprint Line_(" central_meridian central meridian (double, optional, but must specify with sp)");19 _pprint Line_(" standard_parallel standard parallel (double, optional, but must specify with cm)");20 _pprint Line_(" holes flag for treatment of multiple profiles (char, optional, 'yes' for holes))");21 _pprint Line_("");22 _pprint Line_(" ret return code (non-zero for warning)");23 _pprint Line_("");24 _pprint Line_(" Examples:");25 _pprint Line_(" [ret]=Exp2Kml('file.exp','file.kml', 1);");26 _pprint Line_(" [ret]=Exp2Kml('file.exp','file.kml', 1,'central_meridian',45,'standard_parallel',70,'holes','yes');");27 _pprint Line_(" [ret]=Exp2Kml('file.exp','file.kml',-1,'central_meridian', 0,'standard_parallel',71,'holes','yes');");28 _pprint Line_("");7 _pprintString_("Exp2Kml - exp to kml file conversion module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module converts a file from exp to kml format." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" [ret]=Exp2Kml(filexp,filkml,sgn,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" filexp file name of exp file to be read (char)" << "\n"); 15 _pprintString_(" filkml file name of kml file to be written (char)" << "\n"); 16 _pprintString_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))" << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" central_meridian central meridian (double, optional, but must specify with sp)" << "\n"); 19 _pprintString_(" standard_parallel standard parallel (double, optional, but must specify with cm)" << "\n"); 20 _pprintString_(" holes flag for treatment of multiple profiles (char, optional, 'yes' for holes))" << "\n"); 21 _pprintString_("" << "\n"); 22 _pprintString_(" ret return code (non-zero for warning)" << "\n"); 23 _pprintString_("" << "\n"); 24 _pprintString_(" Examples:" << "\n"); 25 _pprintString_(" [ret]=Exp2Kml('file.exp','file.kml', 1);" << "\n"); 26 _pprintString_(" [ret]=Exp2Kml('file.exp','file.kml', 1,'central_meridian',45,'standard_parallel',70,'holes','yes');" << "\n"); 27 _pprintString_(" [ret]=Exp2Kml('file.exp','file.kml',-1,'central_meridian', 0,'standard_parallel',71,'holes','yes');" << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(Exp2Kml){ … … 67 67 if (options->GetOption("central_meridian") || options->GetOption("standard_parallel")) { 68 68 options->Get(&cm,"central_meridian"); 69 if (verbose) _print Line_(" cm=" << cm);69 if (verbose) _printString_(" cm=" << cm << "\n"); 70 70 options->Get(&sp,"standard_parallel"); 71 if (verbose) _print Line_(" sp=" << sp);71 if (verbose) _printString_(" sp=" << sp << "\n"); 72 72 } 73 73 -
issm/trunk-jpl/src/wrappers/ExpSimplify/ExpSimplify.cpp
r15095 r15099 5 5 6 6 void ExpSimplifyUsage(void){/*{{{*/ 7 _print Line_("ExpSimplify - Simplify Exp contour");8 _print Line_("");9 _print Line_(" Recursive Douglas-Peucker Polygon Simplification");10 _print Line_("");11 _print Line_(" Usage:");12 _print Line_(" ExpSimplify(expfile,tol);");13 _print Line_(" - expfile: name of the exp file");14 _print Line_(" - tol: tolerance (maximal euclidean distance allowed between the new line and a vertex)");15 _print Line_(" Additional options:");16 _print Line_(" - 'min': minimum number of vertices to save contours in exp file (default is 3)");17 _print Line_("");18 _print Line_(" Example:");19 _print Line_(" ExpSimplify('file.exp',100);");20 _print Line_(" ExpSimplify('file.exp',100,'remove1',false);");7 _printString_("ExpSimplify - Simplify Exp contour" << "\n"); 8 _printString_("" << "\n"); 9 _printString_(" Recursive Douglas-Peucker Polygon Simplification" << "\n"); 10 _printString_("" << "\n"); 11 _printString_(" Usage:" << "\n"); 12 _printString_(" ExpSimplify(expfile,tol);" << "\n"); 13 _printString_(" - expfile: name of the exp file" << "\n"); 14 _printString_(" - tol: tolerance (maximal euclidean distance allowed between the new line and a vertex)" << "\n"); 15 _printString_(" Additional options:" << "\n"); 16 _printString_(" - 'min': minimum number of vertices to save contours in exp file (default is 3)" << "\n"); 17 _printString_("" << "\n"); 18 _printString_(" Example:" << "\n"); 19 _printString_(" ExpSimplify('file.exp',100);" << "\n"); 20 _printString_(" ExpSimplify('file.exp',100,'remove1',false);" << "\n"); 21 21 }/*}}}*/ 22 22 void simplify(Contour<double>* contour,bool* flags,int ind0,int ind1,double tolerance){/*{{{*/ … … 145 145 x = contour->x; 146 146 y = contour->y; 147 _print Line_(" Initial number of vertices in contour #"<<counter+1<<": "<<nods);147 _printString_(" Initial number of vertices in contour #"<<counter+1<<": "<<nods << "\n"); 148 148 149 149 /*Allocate flags (1=keep, 0=remove)*/ … … 183 183 /*Do we save new profile?*/ 184 184 if(newnods>=minimumvertices){ 185 _print Line_(" Final number of vertices in contour #"<<counter+1<<": "<<newnods);185 _printString_(" Final number of vertices in contour #"<<counter+1<<": "<<newnods << "\n"); 186 186 newcontour = xNew<Contour<double> >(1); 187 187 newcontour->nods = newnods; … … 202 202 } 203 203 else{ 204 _print Line_(" Final number of vertices in contour #"<<counter+1<<": "<<newnods<<" (not saved)");204 _printString_(" Final number of vertices in contour #"<<counter+1<<": "<<newnods<<" (not saved)" << "\n"); 205 205 } 206 206 … … 208 208 xDelete<bool>(flags); 209 209 } 210 _print Line_(" Initial number of contours: "<<oldcontours->Size());211 _print Line_(" Final number of contours: "<<newcontours->Size());210 _printString_(" Initial number of contours: "<<oldcontours->Size() << "\n"); 211 _printString_(" Final number of contours: "<<newcontours->Size() << "\n"); 212 212 213 213 /*Write data: */ -
issm/trunk-jpl/src/wrappers/HoleFiller/HoleFiller.cpp
r15008 r15099 13 13 14 14 void HoleFillerUsage(void){/*{{{*/ 15 _print Line_(" HoleFiller usage:");16 _print Line_(" [image_out]=HoleFiller(image_in,smooth);\n");17 _print Line_(" where:");18 _print Line_(" image_in in double format");19 _print Line_(" smooth: 1 to smooth with a box filer, 0 to leave data raw");20 _print Line_(" image_out in double format");21 _print Line_("");15 _printString_(" HoleFiller usage:" << "\n"); 16 _printString_(" [image_out]=HoleFiller(image_in,smooth);" << "\n"); 17 _printString_(" where:" << "\n"); 18 _printString_(" image_in in double format" << "\n"); 19 _printString_(" smooth: 1 to smooth with a box filer, 0 to leave data raw" << "\n"); 20 _printString_(" image_out in double format" << "\n"); 21 _printString_("" << "\n"); 22 22 }/*}}}*/ 23 23 WRAPPER(HoleFiller){ -
issm/trunk-jpl/src/wrappers/InternalFront/InternalFront.cpp
r14304 r15099 6 6 7 7 void InternalFrontUsage(void) {/*{{{*/ 8 _pprint Line_("");9 _pprint Line_(" usage: icefront = " << __FUNCT__ << "(md);");10 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" usage: icefront = " << __FUNCT__ << "(md);" << "\n"); 10 _pprintString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(InternalFront){ -
issm/trunk-jpl/src/wrappers/InterpFromGridToMesh/InterpFromGridToMesh.cpp
r14656 r15099 6 6 7 7 void InterpFromGridToMeshUsage(void){/*{{{*/ 8 _pprint Line_("INTERPFROMGRIDTOMESH - interpolation from a grid onto a list of points");9 _pprint Line_("");10 _pprint Line_(" This function is a multi-threaded mex file that interpolates a field");11 _pprint Line_(" defined on a grid onto a list of points");12 _pprint Line_("");13 _pprint Line_(" Usage:");14 _pprint Line_(" data_mesh=InterpFromGridToMesh(x,y,data,x_mesh,y_mesh,default_value);");15 _pprint Line_("");16 _pprint Line_(" data: matrix holding the data to be interpolated onto the mesh.");17 _pprint Line_(" x,y: coordinates of matrix data. (x and y must be in increasing order)");18 _pprint Line_(" x_mesh,y_mesh: coordinates of the points onto which we interpolate.");19 _pprint Line_(" default_value: default value if no data is found (holes).");20 _pprint Line_(" data_mesh: vector of mesh interpolated data.");21 _pprint Line_("");22 _pprint Line_(" Example:");23 _pprint Line_(" load('velocities.mat');");24 _pprint Line_(" md.inversion.vx_obs=InterpFromGridToMesh(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);");25 _pprint Line_("");8 _pprintString_("INTERPFROMGRIDTOMESH - interpolation from a grid onto a list of points" << "\n"); 9 _pprintString_("" << "\n"); 10 _pprintString_(" This function is a multi-threaded mex file that interpolates a field" << "\n"); 11 _pprintString_(" defined on a grid onto a list of points" << "\n"); 12 _pprintString_("" << "\n"); 13 _pprintString_(" Usage:" << "\n"); 14 _pprintString_(" data_mesh=InterpFromGridToMesh(x,y,data,x_mesh,y_mesh,default_value);" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" data: matrix holding the data to be interpolated onto the mesh." << "\n"); 17 _pprintString_(" x,y: coordinates of matrix data. (x and y must be in increasing order)" << "\n"); 18 _pprintString_(" x_mesh,y_mesh: coordinates of the points onto which we interpolate." << "\n"); 19 _pprintString_(" default_value: default value if no data is found (holes)." << "\n"); 20 _pprintString_(" data_mesh: vector of mesh interpolated data." << "\n"); 21 _pprintString_("" << "\n"); 22 _pprintString_(" Example:" << "\n"); 23 _pprintString_(" load('velocities.mat');" << "\n"); 24 _pprintString_(" md.inversion.vx_obs=InterpFromGridToMesh(x_n,y_m,vx,md.mesh.x,md.mesh.y,0);" << "\n"); 25 _pprintString_("" << "\n"); 26 26 }/*}}}*/ 27 27 WRAPPER(InterpFromGridToMesh){ -
issm/trunk-jpl/src/wrappers/InterpFromMesh2d/InterpFromMesh2d.cpp
r14656 r15099 6 6 7 7 void InterpFromMesh2dUsage(void){/*{{{*/ 8 _pprint Line_(" usage:");9 _pprint Line_(" data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime);\n");10 _pprint Line_(" or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value);\n");11 _pprint Line_(" or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value,contourname);\n");12 _pprint Line_(" where:");13 _pprint Line_(" x,y: coordinates of the nodes where data is defined");14 _pprint Line_(" index: index of the mesh where data is defined");15 _pprint Line_(" data - vector holding the data to be interpolated onto the points.");16 _pprint Line_(" x_prime,y_prime: coordinates of the mesh vertices onto which we interpolate.");17 _pprint Line_(" default_value: a scalar or vector of size length(x_prime).");18 _pprint Line_(" contourname: linear interpolation will happen on all x_interp,y_interp inside the contour, default value will be adopted on the rest of the mesh.");19 _pprint Line_(" data_prime: vector of prime interpolated data.");20 _pprint Line_("");8 _pprintString_(" usage:" << "\n"); 9 _pprintString_(" data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime);" << "\n"); 10 _pprintString_(" or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value);" << "\n"); 11 _pprintString_(" or data_prime=InterpFromMesh2d(index,x,y,data,x_prime,y_prime,default_value,contourname);" << "\n"); 12 _pprintString_(" where:" << "\n"); 13 _pprintString_(" x,y: coordinates of the nodes where data is defined" << "\n"); 14 _pprintString_(" index: index of the mesh where data is defined" << "\n"); 15 _pprintString_(" data - vector holding the data to be interpolated onto the points." << "\n"); 16 _pprintString_(" x_prime,y_prime: coordinates of the mesh vertices onto which we interpolate." << "\n"); 17 _pprintString_(" default_value: a scalar or vector of size length(x_prime)." << "\n"); 18 _pprintString_(" contourname: linear interpolation will happen on all x_interp,y_interp inside the contour, default value will be adopted on the rest of the mesh." << "\n"); 19 _pprintString_(" data_prime: vector of prime interpolated data." << "\n"); 20 _pprintString_("" << "\n"); 21 21 }/*}}}*/ 22 22 WRAPPER(InterpFromMesh2d){ … … 113 113 /* Debugging of contours :{{{1*/ 114 114 /*for(i=0;i<numcontours;i++){ 115 _print Line_("\nContour echo: contour number " << i+1 << " / " << numcontours);115 _printString_("\nContour echo: contour number " << i+1 << " / " << numcontours << "\n"); 116 116 contouri=*(contours+i); 117 _print Line_(" Number of vertices " << contouri->nods);117 _printString_(" Number of vertices " << contouri->nods << "\n"); 118 118 for (j=0;j<contouri->nods;j++){ 119 _print Line_(" " << *(contouri->x+j) << "f " << *(contouri->y+j) << "f");119 _printString_(" " << *(contouri->x+j) << "f " << *(contouri->y+j) << "f" << "\n"); 120 120 } 121 121 }*/ -
issm/trunk-jpl/src/wrappers/InterpFromMeshToGrid/InterpFromMeshToGrid.cpp
r13236 r15099 6 6 7 7 void InterpFromMeshToGridUsage(void){/*{{{*/ 8 _pprint Line_("INTERPFROMMESHTOGRID - interpolation of a data defined on a mesh onto a grid");9 _pprint Line_("");10 _pprint Line_(" This function is a multi-threaded mex file that interpolates a field");11 _pprint Line_(" defined on a triangular mesh onto a regular grid");12 _pprint Line_("");13 _pprint Line_(" Usage:");14 _pprint Line_(" [x_m,y_m,griddata]=InterpFromMeshToGrid(index,x,y,data,xmin,ymax,xposting,yposting,nlines,ncols,default_value)");15 _pprint Line_("");16 _pprint Line_(" index,x,y: delaunay triangulation defining the mesh.");17 _pprint Line_(" meshdata: vertex values of data to be interpolated.");18 _pprint Line_(" xmin,ymax,posting,nlines,ncols: parameters that define the grid");19 _pprint Line_(" default_value: value of points located out of the mesh.");20 _pprint Line_("");8 _pprintString_("INTERPFROMMESHTOGRID - interpolation of a data defined on a mesh onto a grid" << "\n"); 9 _pprintString_("" << "\n"); 10 _pprintString_(" This function is a multi-threaded mex file that interpolates a field" << "\n"); 11 _pprintString_(" defined on a triangular mesh onto a regular grid" << "\n"); 12 _pprintString_("" << "\n"); 13 _pprintString_(" Usage:" << "\n"); 14 _pprintString_(" [x_m,y_m,griddata]=InterpFromMeshToGrid(index,x,y,data,xmin,ymax,xposting,yposting,nlines,ncols,default_value)" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" index,x,y: delaunay triangulation defining the mesh." << "\n"); 17 _pprintString_(" meshdata: vertex values of data to be interpolated." << "\n"); 18 _pprintString_(" xmin,ymax,posting,nlines,ncols: parameters that define the grid" << "\n"); 19 _pprintString_(" default_value: value of points located out of the mesh." << "\n"); 20 _pprintString_("" << "\n"); 21 21 }/*}}}*/ 22 22 WRAPPER(InterpFromMeshToGrid){ -
issm/trunk-jpl/src/wrappers/InterpFromMeshToMesh2d/InterpFromMeshToMesh2d.cpp
r13236 r15099 5 5 6 6 void InterpFromMeshToMesh2dUsage(void){/*{{{*/ 7 _pprint Line_("INTERFROMMESHTOMESH2D - interpolation from a 2d triangular mesh onto a list of point");8 _pprint Line_("");9 _pprint Line_(" This function is a multi-threaded mex file that interpolates a field");10 _pprint Line_(" defined on a Delaunay triangulation onto a list of point");11 _pprint Line_("");12 _pprint Line_(" Usage:");13 _pprint Line_(" data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp);");14 _pprint Line_(" or data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp,OPTIONS);");15 _pprint Line_("");16 _pprint Line_(" index : index of the mesh where data is defined");17 _pprint Line_(" x,y : coordinates of the nodes where data is defined");18 _pprint Line_(" data : matrix holding the data to be interpolated onto the mesh. (one column per field)");19 _pprint Line_(" x_interp,y_interp : coordinates of the points onto which we interpolate.");20 _pprint Line_(" data_interp : vector of mesh interpolated data.");21 _pprint Line_(" Available options :");22 _pprint Line_(" - 'default' : default value if point is outsite of triangulation (instead of linear interolation)");23 _pprint Line_("");24 _pprint Line_(" Example:");25 _pprint Line_(" load('temperature.mat');");26 _pprint Line_(" md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y);");27 _pprint Line_(" md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y,'default',253);");28 _pprint Line_("");7 _pprintString_("INTERFROMMESHTOMESH2D - interpolation from a 2d triangular mesh onto a list of point" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This function is a multi-threaded mex file that interpolates a field" << "\n"); 10 _pprintString_(" defined on a Delaunay triangulation onto a list of point" << "\n"); 11 _pprintString_("" << "\n"); 12 _pprintString_(" Usage:" << "\n"); 13 _pprintString_(" data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp);" << "\n"); 14 _pprintString_(" or data_interp=InterpFromMeshToMesh2d(index,x,y,data,x_interp,y_interp,OPTIONS);" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" index : index of the mesh where data is defined" << "\n"); 17 _pprintString_(" x,y : coordinates of the nodes where data is defined" << "\n"); 18 _pprintString_(" data : matrix holding the data to be interpolated onto the mesh. (one column per field)" << "\n"); 19 _pprintString_(" x_interp,y_interp : coordinates of the points onto which we interpolate." << "\n"); 20 _pprintString_(" data_interp : vector of mesh interpolated data." << "\n"); 21 _pprintString_(" Available options :" << "\n"); 22 _pprintString_(" - 'default' : default value if point is outsite of triangulation (instead of linear interolation)" << "\n"); 23 _pprintString_("" << "\n"); 24 _pprintString_(" Example:" << "\n"); 25 _pprintString_(" load('temperature.mat');" << "\n"); 26 _pprintString_(" md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y);" << "\n"); 27 _pprintString_(" md.initialization.temperature=InterpFromMeshToMesh2d(index,x,y,temperature,md.mesh.x,md.mesh.y,'default',253);" << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(InterpFromMeshToMesh2d){ -
issm/trunk-jpl/src/wrappers/InterpFromMeshToMesh3d/InterpFromMeshToMesh3d.cpp
r14656 r15099 6 6 7 7 void InterpFromMeshToMesh3dUsage(void){/*{{{*/ 8 _pprint Line_("INTERPFROMMESHTOMESH3D - interpolation from a 3d hexahedron mesh onto a list of point");9 _pprint Line_("");10 _pprint Line_(" This function is a multi-threaded mex file that interpolates a field");11 _pprint Line_(" defined on a triangular mesh onto a list of point");12 _pprint Line_("");13 _pprint Line_(" Usage:");14 _pprint Line_(" data_prime=InterpFromMeshToMesh3d(index,x,y,z,data,x_prime,y_prime,z_prime,default_value);");15 _pprint Line_("");16 _pprint Line_(" index: index of the mesh where data is defined");17 _pprint Line_(" x,y,z: coordinates of the nodes where data is defined");18 _pprint Line_(" data: matrix holding the data to be interpolated onto the mesh.");19 _pprint Line_(" x_prime,y_prime,z_prime: coordinates of the points onto which we interpolate.");20 _pprint Line_(" default_value: default value if no data is found (holes).");21 _pprint Line_(" data_prime: vector of mesh interpolated data.");22 _pprint Line_("");23 _pprint Line_(" Example:");24 _pprint Line_(" load('temperature.mat');");25 _pprint Line_(" md.initialization.temperature=InterpFromMeshToMesh3d(index,x,y,z,temperature,md.mesh.x,md.mesh.y,md.mesh.z,253);");26 _pprint Line_("");8 _pprintString_("INTERPFROMMESHTOMESH3D - interpolation from a 3d hexahedron mesh onto a list of point" << "\n"); 9 _pprintString_("" << "\n"); 10 _pprintString_(" This function is a multi-threaded mex file that interpolates a field" << "\n"); 11 _pprintString_(" defined on a triangular mesh onto a list of point" << "\n"); 12 _pprintString_("" << "\n"); 13 _pprintString_(" Usage:" << "\n"); 14 _pprintString_(" data_prime=InterpFromMeshToMesh3d(index,x,y,z,data,x_prime,y_prime,z_prime,default_value);" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" index: index of the mesh where data is defined" << "\n"); 17 _pprintString_(" x,y,z: coordinates of the nodes where data is defined" << "\n"); 18 _pprintString_(" data: matrix holding the data to be interpolated onto the mesh." << "\n"); 19 _pprintString_(" x_prime,y_prime,z_prime: coordinates of the points onto which we interpolate." << "\n"); 20 _pprintString_(" default_value: default value if no data is found (holes)." << "\n"); 21 _pprintString_(" data_prime: vector of mesh interpolated data." << "\n"); 22 _pprintString_("" << "\n"); 23 _pprintString_(" Example:" << "\n"); 24 _pprintString_(" load('temperature.mat');" << "\n"); 25 _pprintString_(" md.initialization.temperature=InterpFromMeshToMesh3d(index,x,y,z,temperature,md.mesh.x,md.mesh.y,md.mesh.z,253);" << "\n"); 26 _pprintString_("" << "\n"); 27 27 }/*}}}*/ 28 28 WRAPPER(InterpFromMeshToMesh3d){ -
issm/trunk-jpl/src/wrappers/KMLFileRead/KMLFileRead.cpp
r13250 r15099 5 5 6 6 void KMLFileReadUsage(void){/*{{{*/ 7 _pprint Line_("KMLFileRead - KML file reader module:");8 _pprint Line_("");9 _pprint Line_(" This module reads a KML file.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" [ierror]=KMLFileRead(kmlfile,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" kmlfile file name of kml file to be read (char)");15 _pprint Line_("");16 _pprint Line_(" echo echo command (char, optional, 'off'/'on')");17 _pprint Line_(" deepecho deep echo command (char, optional, 'off'/'on')");18 _pprint Line_(" write write command (char, optional, 'off'/'stdout'/kmlfile)");19 _pprint Line_("");20 _pprint Line_(" ierror return code (non-zero for error)");21 _pprint Line_("");22 _pprint Line_(" Examples:");23 _pprint Line_(" [ierror]=KMLFileRead('file.kml','deepecho','on');");24 _pprint Line_(" [ierror]=KMLFileRead('filin.kml','echo','on','write','filout.kml');");25 _pprint Line_("");7 _pprintString_("KMLFileRead - KML file reader module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module reads a KML file." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" [ierror]=KMLFileRead(kmlfile,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" kmlfile file name of kml file to be read (char)" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" echo echo command (char, optional, 'off'/'on')" << "\n"); 17 _pprintString_(" deepecho deep echo command (char, optional, 'off'/'on')" << "\n"); 18 _pprintString_(" write write command (char, optional, 'off'/'stdout'/kmlfile)" << "\n"); 19 _pprintString_("" << "\n"); 20 _pprintString_(" ierror return code (non-zero for error)" << "\n"); 21 _pprintString_("" << "\n"); 22 _pprintString_(" Examples:" << "\n"); 23 _pprintString_(" [ierror]=KMLFileRead('file.kml','deepecho','on');" << "\n"); 24 _pprintString_(" [ierror]=KMLFileRead('filin.kml','echo','on','write','filout.kml');" << "\n"); 25 _pprintString_("" << "\n"); 26 26 }/*}}}*/ 27 27 WRAPPER(KMLFileRead){ … … 84 84 if (!strlen(filnam)) strcpy(filnam,"stdout"); 85 85 86 if (verbose) _print Line_("Opening file \"" << filnam << "\".");86 if (verbose) _printString_("Opening file \"" << filnam << "\"." << "\n"); 87 87 fidi=fopen(filnam,"r"); 88 88 89 89 /* Run core computations: */ 90 if (verbose) _print Line_("Calling core:");90 if (verbose) _printString_("Calling core:" << "\n"); 91 91 kobj=KMLFileReadx(fidi); 92 92 93 if (verbose) _print Line_("Closing file \"" << filnam << "\".");93 if (verbose) _printString_("Closing file \"" << filnam << "\"." << "\n"); 94 94 fclose(fidi); 95 95 … … 104 104 } 105 105 else { 106 if (verbose) _print Line_("Opening file \"" << write << "\".");106 if (verbose) _printString_("Opening file \"" << write << "\"." << "\n"); 107 107 fido=fopen(write,"w"); 108 108 kobj->Write(fido,""); 109 if (verbose) _print Line_("Closing file \"" << write << "\".");109 if (verbose) _printString_("Closing file \"" << write << "\"." << "\n"); 110 110 ierror=fclose(fido); 111 111 } -
issm/trunk-jpl/src/wrappers/KMLMeshWrite/KMLMeshWrite.cpp
r13250 r15099 5 5 6 6 void KMLMeshWriteUsage(void){/*{{{*/ 7 _pprint Line_("KMLMeshWrite - KML mesh writer module:");8 _pprint Line_("");9 _pprint Line_(" This module writes the mesh of a model as KML polygons into the specified KML file.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" ierror=KMLMeshWrite(name,notes,elem,nodecon,lat,long,part,data,cmap,kmlfile);");13 _pprint Line_("");14 _pprint Line_(" name model name (string, may be empty)");15 _pprint Line_(" notes model notes (string or cell array of strings, may be empty)");16 _pprint Line_(" elem elements (double array)");17 _pprint Line_(" nodecon nodal connectivity array (double array, may be empty)");18 _pprint Line_(" lat nodal latititudes (double vector)");19 _pprint Line_(" long nodal longitudes (double vector)");20 _pprint Line_(" part nodal partitions (double vector, may be empty)");21 _pprint Line_(" data nodal or element data (double vector, may be empty)");22 _pprint Line_(" cmap color map (double nx3 array, may be empty)");23 _pprint Line_(" kmlfile KML file name (string)");24 _pprint Line_("");25 _pprint Line_(" ierror error flag (double, non-zero for error)");26 _pprint Line_("");27 _pprint Line_(" Example:");28 _pprint Line_(" KMLMeshWrite(md.name,md.notes,md.elements,md.nodeconnectivity,md.lat,md.long,md.part,md.fm_criterion,options.cmap,filekml);");29 _pprint Line_("");7 _pprintString_("KMLMeshWrite - KML mesh writer module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module writes the mesh of a model as KML polygons into the specified KML file." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" ierror=KMLMeshWrite(name,notes,elem,nodecon,lat,long,part,data,cmap,kmlfile);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" name model name (string, may be empty)" << "\n"); 15 _pprintString_(" notes model notes (string or cell array of strings, may be empty)" << "\n"); 16 _pprintString_(" elem elements (double array)" << "\n"); 17 _pprintString_(" nodecon nodal connectivity array (double array, may be empty)" << "\n"); 18 _pprintString_(" lat nodal latititudes (double vector)" << "\n"); 19 _pprintString_(" long nodal longitudes (double vector)" << "\n"); 20 _pprintString_(" part nodal partitions (double vector, may be empty)" << "\n"); 21 _pprintString_(" data nodal or element data (double vector, may be empty)" << "\n"); 22 _pprintString_(" cmap color map (double nx3 array, may be empty)" << "\n"); 23 _pprintString_(" kmlfile KML file name (string)" << "\n"); 24 _pprintString_("" << "\n"); 25 _pprintString_(" ierror error flag (double, non-zero for error)" << "\n"); 26 _pprintString_("" << "\n"); 27 _pprintString_(" Example:" << "\n"); 28 _pprintString_(" KMLMeshWrite(md.name,md.notes,md.elements,md.nodeconnectivity,md.lat,md.long,md.part,md.fm_criterion,options.cmap,filekml);" << "\n"); 29 _pprintString_("" << "\n"); 30 30 }/*}}}*/ 31 31 WRAPPER(KMLMeshWrite){ -
issm/trunk-jpl/src/wrappers/KMLOverlay/KMLOverlay.cpp
r13250 r15099 5 5 6 6 void KMLOverlayUsage(void){/*{{{*/ 7 _pprint Line_("KMLOverlay - KML file overlay module:");8 _pprint Line_("");9 _pprint Line_(" This module reads a list of image files and writes a KML or KMZ overlay file.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" ierror=KMLOverlay(kmlfile,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" kmlfile KML or KMZ file name (string)");15 _pprint Line_("");16 _pprint Line_(" lataxis latitude axis (double vector [south north], required)");17 _pprint Line_(" longaxis longitude axis (double vector [west east], required)");18 _pprint Line_(" images relative or http image file names (string or array of strings or cell array of strings, required)");19 _pprint Line_(" zip flag to zip the doc.kml and image files into kmzfile (double, non-zero for kmz)");20 _pprint Line_("");21 _pprint Line_(" ierror error flag (double, non-zero for error)");22 _pprint Line_("");23 _pprint Line_(" Example:");24 _pprint Line_(" KMLOverlay(kmlfile,'lataxis',[south north],'longaxis',[west east],'images',{'file1.png','http://issm/file2.png'},'zip',1);");25 _pprint Line_("");7 _pprintString_("KMLOverlay - KML file overlay module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module reads a list of image files and writes a KML or KMZ overlay file." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" ierror=KMLOverlay(kmlfile,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" kmlfile KML or KMZ file name (string)" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" lataxis latitude axis (double vector [south north], required)" << "\n"); 17 _pprintString_(" longaxis longitude axis (double vector [west east], required)" << "\n"); 18 _pprintString_(" images relative or http image file names (string or array of strings or cell array of strings, required)" << "\n"); 19 _pprintString_(" zip flag to zip the doc.kml and image files into kmzfile (double, non-zero for kmz)" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" ierror error flag (double, non-zero for error)" << "\n"); 22 _pprintString_("" << "\n"); 23 _pprintString_(" Example:" << "\n"); 24 _pprintString_(" KMLOverlay(kmlfile,'lataxis',[south north],'longaxis',[west east],'images',{'file1.png','http://issm/file2.png'},'zip',1);" << "\n"); 25 _pprintString_("" << "\n"); 26 26 }/*}}}*/ 27 27 WRAPPER(KMLOverlay){ … … 63 63 64 64 options->Get(&lataxis ,&nlat ,(char*)"lataxis"); 65 if (verbose && lataxis) for (i=0; i<nlat; i++) _print Line_(" lataxis [" << i << "]=" << lataxis[i]);65 if (verbose && lataxis) for (i=0; i<nlat; i++) _printString_(" lataxis [" << i << "]=" << lataxis[i] << "\n"); 66 66 options->Get(&longaxis,&nlong,(char*)"longaxis"); 67 if (verbose && longaxis) for (i=0; i<nlong; i++) _print Line_(" longaxis[" << i << "]=" << longaxis[i]);67 if (verbose && longaxis) for (i=0; i<nlong; i++) _printString_(" longaxis[" << i << "]=" << longaxis[i] << "\n"); 68 68 options->Get(&pimages,&nimages,(char*)"images"); 69 if (verbose && pimages) for (i=0; i<nimages; i++) _print Line_(" pimages[" << i << "]=\"" << pimages[i] << "\"");69 if (verbose && pimages) for (i=0; i<nimages; i++) _printString_(" pimages[" << i << "]=\"" << pimages[i] << "\"" << "\n"); 70 70 options->Get(&dzip,(char*)"zip",0.); 71 if (verbose) _print Line_(" dzip=" << dzip);71 if (verbose) _printString_(" dzip=" << dzip << "\n"); 72 72 73 73 /*some checks*/ … … 84 84 if(!strlen(filkml)) strcpy(filkml,"stdout"); 85 85 86 if(verbose) _print Line_("Opening kml overlay file \"" << filkml << "\".");86 if(verbose) _printString_("Opening kml overlay file \"" << filkml << "\"." << "\n"); 87 87 fid=fopen(filkml,"w"); 88 88 89 89 /* Run core computations: */ 90 if (verbose) _print Line_("Calling core:");90 if (verbose) _printString_("Calling core:" << "\n"); 91 91 KMLOverlayx(&ierror,lataxis,longaxis,nimages,pimages,fid); 92 92 93 if (verbose) _print Line_("Closing file \"" << filkml << "\".");93 if (verbose) _printString_("Closing file \"" << filkml << "\"." << "\n"); 94 94 fclose(fid); 95 95 … … 108 108 strcat(czip,pimages[i]); 109 109 } 110 if (verbose) _print Line_("Zipping file \"" << filkmz << "\".");111 if (verbose) _print Line_(czip);110 if (verbose) _printString_("Zipping file \"" << filkmz << "\"." << "\n"); 111 if (verbose) _printString_(czip << "\n"); 112 112 113 113 if (mexEvalString(czip)) _error_("Error zipping file \"" << filkmz << "\"."); -
issm/trunk-jpl/src/wrappers/Kml2Exp/Kml2Exp.cpp
r13250 r15099 5 5 6 6 void Kml2ExpUsage(void){/*{{{*/ 7 _pprint Line_("Kml2Exp - kml to exp file conversion module:");8 _pprint Line_("");9 _pprint Line_(" This module converts a file from kml to exp format.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" [ret]=Kml2Exp(filexp,filkml,sgn,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" filkml file name of kml file to be read (char)");15 _pprint Line_(" filexp file name of exp file to be written (char)");16 _pprint Line_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))");17 _pprint Line_("");18 _pprint Line_(" central_meridian central meridian (double, optional, but must specify with sp)");19 _pprint Line_(" standard_parallel standard parallel (double, optional, but must specify with cm)");20 _pprint Line_("");21 _pprint Line_(" ret return code (non-zero for warning)");22 _pprint Line_("");23 _pprint Line_(" Examples:");24 _pprint Line_(" [ret]=Kml2Exp('file.kml','file.exp', 1);");25 _pprint Line_(" [ret]=Kml2Exp('file.kml','file.exp', 1,'central_meridian',45,'standard_parallel',70);");26 _pprint Line_(" [ret]=Kml2Exp('file.kml','file.exp',-1,'central_meridian', 0,'standard_parallel',71);");27 _pprint Line_("");7 _pprintString_("Kml2Exp - kml to exp file conversion module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module converts a file from kml to exp format." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" [ret]=Kml2Exp(filexp,filkml,sgn,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" filkml file name of kml file to be read (char)" << "\n"); 15 _pprintString_(" filexp file name of exp file to be written (char)" << "\n"); 16 _pprintString_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))" << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" central_meridian central meridian (double, optional, but must specify with sp)" << "\n"); 19 _pprintString_(" standard_parallel standard parallel (double, optional, but must specify with cm)" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" ret return code (non-zero for warning)" << "\n"); 22 _pprintString_("" << "\n"); 23 _pprintString_(" Examples:" << "\n"); 24 _pprintString_(" [ret]=Kml2Exp('file.kml','file.exp', 1);" << "\n"); 25 _pprintString_(" [ret]=Kml2Exp('file.kml','file.exp', 1,'central_meridian',45,'standard_parallel',70);" << "\n"); 26 _pprintString_(" [ret]=Kml2Exp('file.kml','file.exp',-1,'central_meridian', 0,'standard_parallel',71);" << "\n"); 27 _pprintString_("" << "\n"); 28 28 }/*}}}*/ 29 29 WRAPPER(Kml2Exp){ … … 60 60 if (options->GetOption("central_meridian") || options->GetOption("standard_parallel")) { 61 61 options->Get(&cm,"central_meridian"); 62 if (verbose) _print Line_(" cm=" << cm);62 if (verbose) _printString_(" cm=" << cm << "\n"); 63 63 options->Get(&sp,"standard_parallel"); 64 if (verbose) _print Line_(" sp=" << sp);64 if (verbose) _printString_(" sp=" << sp << "\n"); 65 65 } 66 66 -
issm/trunk-jpl/src/wrappers/Kriging/Kriging.cpp
r14056 r15099 9 9 num=_NUMTHREADS_; 10 10 #endif 11 _pprint Line_("");12 _pprint Line_(" usage: predictions=" << __FUNCT__ << "(x,y,observations,x_interp,y_interp,'options');");13 _pprint Line_(" available options:");14 _pprint Line_(" -'model': Available variogram models 'gaussian' (default),'spherical','power','exponential'");15 _pprint Line_(" -'nugget': nugget effect (default 0.2)");16 _pprint Line_(" -'range': for gaussian, spherical and exponential models (default sqrt(3))");17 _pprint Line_(" -'sill': for gaussian, spherical and exponential models (default 1)");18 _pprint Line_(" -'slope': for power model (default 1)");19 _pprint Line_(" -'power': for power model (default 1)");20 _pprint Line_(" -'searchradius': search radius for each prediction (default is observations span)");21 _pprint Line_(" -'boxlength': minimum length of quadtree boxes (useful to decrease the number of observations)");22 _pprint Line_(" -'maxdata': minimum number of observations for a prediction (default is 50)");23 _pprint Line_(" -'mindata': maximum number of observations for a prediction (default is 1)");24 _pprint Line_(" -'maxtrimming': maximum trimming value (default is -1.e+21)");25 _pprint Line_(" -'mintrimming': minimum trimming value (default is +1.e+21)");26 _pprint Line_(" -'minspacing': minimum distance between observation (default is 0.01)");27 _pprint Line_(" -'numthreads': number of threads, default is "<<num);28 _pprint Line_("");11 _pprintString_("" << "\n"); 12 _pprintString_(" usage: predictions=" << __FUNCT__ << "(x,y,observations,x_interp,y_interp,'options');" << "\n"); 13 _pprintString_(" available options:" << "\n"); 14 _pprintString_(" -'model': Available variogram models 'gaussian' (default),'spherical','power','exponential'" << "\n"); 15 _pprintString_(" -'nugget': nugget effect (default 0.2)" << "\n"); 16 _pprintString_(" -'range': for gaussian, spherical and exponential models (default sqrt(3))" << "\n"); 17 _pprintString_(" -'sill': for gaussian, spherical and exponential models (default 1)" << "\n"); 18 _pprintString_(" -'slope': for power model (default 1)" << "\n"); 19 _pprintString_(" -'power': for power model (default 1)" << "\n"); 20 _pprintString_(" -'searchradius': search radius for each prediction (default is observations span)" << "\n"); 21 _pprintString_(" -'boxlength': minimum length of quadtree boxes (useful to decrease the number of observations)" << "\n"); 22 _pprintString_(" -'maxdata': minimum number of observations for a prediction (default is 50)" << "\n"); 23 _pprintString_(" -'mindata': maximum number of observations for a prediction (default is 1)" << "\n"); 24 _pprintString_(" -'maxtrimming': maximum trimming value (default is -1.e+21)" << "\n"); 25 _pprintString_(" -'mintrimming': minimum trimming value (default is +1.e+21)" << "\n"); 26 _pprintString_(" -'minspacing': minimum distance between observation (default is 0.01)" << "\n"); 27 _pprintString_(" -'numthreads': number of threads, default is "<<num << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(Kriging){ -
issm/trunk-jpl/src/wrappers/Ll2xy/Ll2xy.cpp
r13236 r15099 5 5 6 6 void Ll2xyUsage(void){/*{{{*/ 7 _pprint Line_("Ll2xy - lat/long to x/y coordinate transformation module:");8 _pprint Line_("");9 _pprint Line_(" This module transforms lat/long to x/y coordinates.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" [x,y]=Ll2xy(lat,lon,sgn,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" lat latitude coordinates (double vector)");15 _pprint Line_(" lon longitude coordinates (double vector)");16 _pprint Line_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))");17 _pprint Line_("");18 _pprint Line_(" central_meridian central meridian (double, optional, but must specify with sp)");19 _pprint Line_(" standard_parallel standard parallel (double, optional, but must specify with cm)");20 _pprint Line_("");21 _pprint Line_(" x x coordinates (double vector)");22 _pprint Line_(" y y coordinates (double vector)");23 _pprint Line_("");24 _pprint Line_(" Examples:");25 _pprint Line_(" [x,y]=Ll2xy(lat,lon, 1);");26 _pprint Line_(" [x,y]=Ll2xy(lat,lon, 1,'central_meridian',45,'standard_parallel',70);");27 _pprint Line_(" [x,y]=Ll2xy(lat,lon,-1,'central_meridian', 0,'standard_parallel',71);");28 _pprint Line_("");7 _pprintString_("Ll2xy - lat/long to x/y coordinate transformation module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module transforms lat/long to x/y coordinates." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" [x,y]=Ll2xy(lat,lon,sgn,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" lat latitude coordinates (double vector)" << "\n"); 15 _pprintString_(" lon longitude coordinates (double vector)" << "\n"); 16 _pprintString_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))" << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" central_meridian central meridian (double, optional, but must specify with sp)" << "\n"); 19 _pprintString_(" standard_parallel standard parallel (double, optional, but must specify with cm)" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" x x coordinates (double vector)" << "\n"); 22 _pprintString_(" y y coordinates (double vector)" << "\n"); 23 _pprintString_("" << "\n"); 24 _pprintString_(" Examples:" << "\n"); 25 _pprintString_(" [x,y]=Ll2xy(lat,lon, 1);" << "\n"); 26 _pprintString_(" [x,y]=Ll2xy(lat,lon, 1,'central_meridian',45,'standard_parallel',70);" << "\n"); 27 _pprintString_(" [x,y]=Ll2xy(lat,lon,-1,'central_meridian', 0,'standard_parallel',71);" << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(Ll2xy){ … … 64 64 if(options->GetOption("central_meridian") || options->GetOption("standard_parallel")){ 65 65 options->Get(&cm,"central_meridian"); 66 if (verbose) _print Line_(" cm=" << cm);66 if (verbose) _printString_(" cm=" << cm << "\n"); 67 67 options->Get(&sp,"standard_parallel"); 68 if (verbose) _print Line_(" sp=" << sp);68 if (verbose) _printString_(" sp=" << sp << "\n"); 69 69 } 70 70 71 71 /*some checks*/ 72 if (verbose) _print Line_("Checking inputs:");72 if (verbose) _printString_("Checking inputs:" << "\n"); 73 73 if (nlat != nlon){_error_("Must have same number of lat[" << nlat << "] and lon[" << nlon << "] coordinates.");} 74 74 else ncoord=nlat; -
issm/trunk-jpl/src/wrappers/MeshPartition/MeshPartition.cpp
r13236 r15099 6 6 7 7 void MeshPartitionUsage(void){/*{{{*/ 8 _print Line_(" usage:");8 _printString_(" usage:" << "\n"); 9 9 _printString_(" [element_partitioning,node_partitioning]=MeshPartition(md.mesh,numpartitions)"); 10 _print Line_(" where:");11 _print Line_(" element_partitioning is a vector of partitioning area numbers, for every element.");12 _print Line_(" node_partitioning is a vector of partitioning area numbers, for every node.");13 _print Line_("");10 _printString_(" where:" << "\n"); 11 _printString_(" element_partitioning is a vector of partitioning area numbers, for every element." << "\n"); 12 _printString_(" node_partitioning is a vector of partitioning area numbers, for every node." << "\n"); 13 _printString_("" << "\n"); 14 14 }/*}}}*/ 15 15 WRAPPER(MeshPartition){ -
issm/trunk-jpl/src/wrappers/MeshProfileIntersection/MeshProfileIntersection.cpp
r14656 r15099 19 19 20 20 void MeshProfileIntersectionUsage(void){/*{{{*/ 21 _print Line_(" usage:");22 _print Line_(" [segments]=MeshProfileIntersection(index,x,y,filename);");23 _print Line_(" where:");24 _print Line_(" input:");25 _print Line_(" index,x,y is a triangulation");26 _print Line_(" filename: name of Argus style .exp file containing the segments (can be groups of disconnected segments)");27 _print Line_(" output:");28 _print Line_(" segments: array made of x1,y1,x2,y2,element_id lines (x1,y1) and (x2,y2) are segment extremities for a segment");29 _print Line_(" belonging to the elemnt_id element. there are as many lines in segments as there are segments intersecting the");30 _print Line_(" mesh.");21 _printString_(" usage:" << "\n"); 22 _printString_(" [segments]=MeshProfileIntersection(index,x,y,filename);" << "\n"); 23 _printString_(" where:" << "\n"); 24 _printString_(" input:" << "\n"); 25 _printString_(" index,x,y is a triangulation" << "\n"); 26 _printString_(" filename: name of Argus style .exp file containing the segments (can be groups of disconnected segments)" << "\n"); 27 _printString_(" output:" << "\n"); 28 _printString_(" segments: array made of x1,y1,x2,y2,element_id lines (x1,y1) and (x2,y2) are segment extremities for a segment " << "\n"); 29 _printString_(" belonging to the elemnt_id element. there are as many lines in segments as there are segments intersecting the " << "\n"); 30 _printString_(" mesh." << "\n"); 31 31 }/*}}}*/ 32 32 WRAPPER(MeshProfileIntersection){ -
issm/trunk-jpl/src/wrappers/NodeConnectivity/NodeConnectivity.cpp
r14016 r15099 6 6 7 7 void NodeConnectivityUsage(void){/*{{{*/ 8 _pprint Line_("");9 _pprint Line_(" usage: connectivity = " << __FUNCT__ << "(elements, numnodes);");10 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" usage: connectivity = " << __FUNCT__ << "(elements, numnodes);" << "\n"); 10 _pprintString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(NodeConnectivity){ -
issm/trunk-jpl/src/wrappers/PointCloudFindNeighbors/PointCloudFindNeighbors.cpp
r14656 r15099 6 6 7 7 void PointCloudFindNeighborsUsage(void){/*{{{*/ 8 _print Line_(" usage:");9 _print Line_(" [flags]=PointCloudFindNeighbors(x,y,mindistance,multithread);\n");10 _print Line_(" where:");11 _print Line_(" x,y: list of points.");12 _print Line_(" mindistance: minimum distance that should exist between points in the cloud.");13 _print Line_(" multithread: run multithreaded or not. with multithreads, flags can get 1 and 2 values in duplicates.");14 _print Line_(" flags: array of flags (flag==1 means point is within mindistance of another point)");15 _print Line_("");8 _printString_(" usage:" << "\n"); 9 _printString_(" [flags]=PointCloudFindNeighbors(x,y,mindistance,multithread);" << "\n"); 10 _printString_(" where:" << "\n"); 11 _printString_(" x,y: list of points." << "\n"); 12 _printString_(" mindistance: minimum distance that should exist between points in the cloud." << "\n"); 13 _printString_(" multithread: run multithreaded or not. with multithreads, flags can get 1 and 2 values in duplicates." << "\n"); 14 _printString_(" flags: array of flags (flag==1 means point is within mindistance of another point)" << "\n"); 15 _printString_("" << "\n"); 16 16 }/*}}}*/ 17 17 WRAPPER(PointCloudFindNeighbors){ -
issm/trunk-jpl/src/wrappers/PropagateFlagsFromConnectivity/PropagateFlagsFromConnectivity.cpp
r13250 r15099 6 6 7 7 void PropagateFlagsFromConnectivityUsage(void) {/*{{{*/ 8 _print Line_("");9 _print Line_(" usage: [pool] = " << __FUNCT__ << "(connectivity,pool,index,flags);");;10 _print Line_("");8 _printString_("" << "\n"); 9 _printString_(" usage: [pool] = " << __FUNCT__ << "(connectivity,pool,index,flags);" << "\n");; 10 _printString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(PropagateFlagsFromConnectivity){ -
issm/trunk-jpl/src/wrappers/Shp2Exp/Shp2Exp.cpp
r14283 r15099 12 12 13 13 void Shp2ExpUsage(void){/*{{{*/ 14 _pprint Line_("Shp2Exp - shp to exp file conversion module:");15 _pprint Line_("");16 _pprint Line_(" This module converts a file from shp to exp format.");17 _pprint Line_("");18 _pprint Line_(" Usage:");19 _pprint Line_(" [ret]=Shp2Exp(filshp,filexp,sgn,'param name',param,...);");20 _pprint Line_("");21 _pprint Line_(" filshp file name of shp file to be read (char, extension optional)");22 _pprint Line_(" filexp file name of exp file to be written (char)");23 _pprint Line_("");24 _pprint Line_(" ret return code (non-zero for warning)");25 _pprint Line_("");26 _pprint Line_(" Examples:");27 _pprint Line_(" [ret]=Shp2Exp('file.shp','file.exp');");28 _pprint Line_("");14 _pprintString_("Shp2Exp - shp to exp file conversion module:" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" This module converts a file from shp to exp format." << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" Usage:" << "\n"); 19 _pprintString_(" [ret]=Shp2Exp(filshp,filexp,sgn,'param name',param,...);" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" filshp file name of shp file to be read (char, extension optional)" << "\n"); 22 _pprintString_(" filexp file name of exp file to be written (char)" << "\n"); 23 _pprintString_("" << "\n"); 24 _pprintString_(" ret return code (non-zero for warning)" << "\n"); 25 _pprintString_("" << "\n"); 26 _pprintString_(" Examples:" << "\n"); 27 _pprintString_(" [ret]=Shp2Exp('file.shp','file.exp');" << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(Shp2Exp){ -
issm/trunk-jpl/src/wrappers/Shp2Kml/Shp2Kml.cpp
r13250 r15099 12 12 13 13 void Shp2KmlUsage(void){/*{{{*/ 14 _pprint Line_("Shp2Kml - shp to kml file conversion module:");15 _pprint Line_("");16 _pprint Line_(" This module converts a file from shp to kml format.");17 _pprint Line_("");18 _pprint Line_(" Usage:");19 _pprint Line_(" [ret]=Shp2Kml(filshp,filkml,sgn,'param name',param,...);");20 _pprint Line_("");21 _pprint Line_(" filshp file name of shp file to be read (char, extension optional)");22 _pprint Line_(" filkml file name of kml file to be written (char)");23 _pprint Line_(" sgn sign for hemisphere (double, +1 (north); -1 (south); or 0 (no translation))");24 _pprint Line_("");25 _pprint Line_(" central_meridian central meridian (double, optional, but must specify with sp)");26 _pprint Line_(" standard_parallel standard parallel (double, optional, but must specify with cm)");27 _pprint Line_("");28 _pprint Line_(" ret return code (non-zero for warning)");29 _pprint Line_("");30 _pprint Line_(" Examples:");31 _pprint Line_(" [ret]=Shp2Kml('file.shp','file.kml', 0);");32 _pprint Line_(" [ret]=Shp2Kml('file.shp','file.kml', 1,'central_meridian',45,'standard_parallel',70);");33 _pprint Line_(" [ret]=Shp2Kml('file.shp','file.kml',-1,'central_meridian', 0,'standard_parallel',71);");34 _pprint Line_("");14 _pprintString_("Shp2Kml - shp to kml file conversion module:" << "\n"); 15 _pprintString_("" << "\n"); 16 _pprintString_(" This module converts a file from shp to kml format." << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" Usage:" << "\n"); 19 _pprintString_(" [ret]=Shp2Kml(filshp,filkml,sgn,'param name',param,...);" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" filshp file name of shp file to be read (char, extension optional)" << "\n"); 22 _pprintString_(" filkml file name of kml file to be written (char)" << "\n"); 23 _pprintString_(" sgn sign for hemisphere (double, +1 (north) -1 (south) or 0 (no translation))" << "\n"); 24 _pprintString_("" << "\n"); 25 _pprintString_(" central_meridian central meridian (double, optional, but must specify with sp)" << "\n"); 26 _pprintString_(" standard_parallel standard parallel (double, optional, but must specify with cm)" << "\n"); 27 _pprintString_("" << "\n"); 28 _pprintString_(" ret return code (non-zero for warning)" << "\n"); 29 _pprintString_("" << "\n"); 30 _pprintString_(" Examples:" << "\n"); 31 _pprintString_(" [ret]=Shp2Kml('file.shp','file.kml', 0);" << "\n"); 32 _pprintString_(" [ret]=Shp2Kml('file.shp','file.kml', 1,'central_meridian',45,'standard_parallel',70);" << "\n"); 33 _pprintString_(" [ret]=Shp2Kml('file.shp','file.kml',-1,'central_meridian', 0,'standard_parallel',71);" << "\n"); 34 _pprintString_("" << "\n"); 35 35 }/*}}}*/ 36 36 WRAPPER(Shp2Kml){ … … 71 71 if (options->GetOption("central_meridian") || options->GetOption("standard_parallel")) { 72 72 options->Get(&cm,"central_meridian"); 73 if (verbose) _print Line_(" cm=" << cm);73 if (verbose) _printString_(" cm=" << cm << "\n"); 74 74 options->Get(&sp,"standard_parallel"); 75 if (verbose) _print Line_(" sp=" << sp);75 if (verbose) _printString_(" sp=" << sp << "\n"); 76 76 } 77 77 -
issm/trunk-jpl/src/wrappers/StringToEnum/StringToEnum.cpp
r13236 r15099 6 6 7 7 void StringToEnumUsage(void){/*{{{*/ 8 _pprint Line_("");9 _pprint Line_(" usage: " << __FUNCT__ << "enum = StringToEnum(string);");10 _pprint Line_("");8 _pprintString_("" << "\n"); 9 _pprintString_(" usage: " << __FUNCT__ << "enum = StringToEnum(string);" << "\n"); 10 _pprintString_("" << "\n"); 11 11 }/*}}}*/ 12 12 WRAPPER(StringToEnum){ -
issm/trunk-jpl/src/wrappers/TriMesh/TriMesh.cpp
r14956 r15099 6 6 7 7 void TriMeshUsage(void){/*{{{*/ 8 _print Line_("");9 _print Line_(" usage: [index,x,y,segments,segmentmarkers]=TriMesh(domainoutlinefilename,rifts,area)");10 _print Line_(" where: index,x,y defines a triangulation, segments is an array made");11 _print Line_(" of exterior segments to the mesh domain outline, segmentmarkers is an array flagging each segment,");12 _print Line_(" outlinefilename an Argus domain outline file,");13 _print Line_(" area is the maximum area desired for any element of the resulting mesh,");14 _print Line_("");8 _printString_("" << "\n"); 9 _printString_(" usage: [index,x,y,segments,segmentmarkers]=TriMesh(domainoutlinefilename,rifts,area) " << "\n"); 10 _printString_(" where: index,x,y defines a triangulation, segments is an array made " << "\n"); 11 _printString_(" of exterior segments to the mesh domain outline, segmentmarkers is an array flagging each segment, " << "\n"); 12 _printString_(" outlinefilename an Argus domain outline file, " << "\n"); 13 _printString_(" area is the maximum area desired for any element of the resulting mesh, " << "\n"); 14 _printString_("" << "\n"); 15 15 }/*}}}*/ 16 16 WRAPPER(TriMesh){ -
issm/trunk-jpl/src/wrappers/TriMeshProcessRifts/TriMeshProcessRifts.cpp
r14221 r15099 6 6 7 7 void TriMeshProcessRiftsUsage(void){/*{{{*/ 8 _print Line_("");9 _print Line_(" usage: [index2,x2,y2,segments2,segmentmarkers2,rifts2]=TriMeshProcessrifts(index1,x1,y1,segments1,segmentmarkers1)");10 _print Line_(" where: (index1,x1,y1,segments1,segmentmarkers1) is an initial triangulation.");11 _print Line_(" index2,x2,y2,segments2,segmentmarkers2,rifts2 is the resulting triangulation where rifts have been processed.");8 _printString_("" << "\n"); 9 _printString_(" usage: [index2,x2,y2,segments2,segmentmarkers2,rifts2]=TriMeshProcessrifts(index1,x1,y1,segments1,segmentmarkers1) " << "\n"); 10 _printString_(" where: (index1,x1,y1,segments1,segmentmarkers1) is an initial triangulation." << "\n"); 11 _printString_(" index2,x2,y2,segments2,segmentmarkers2,rifts2 is the resulting triangulation where rifts have been processed." << "\n"); 12 12 }/*}}}*/ 13 13 WRAPPER(TriMeshProcessRifts){ -
issm/trunk-jpl/src/wrappers/TriaSearch/TriaSearch.cpp
r13236 r15099 5 5 6 6 void TriaSearchUsage(void){/*{{{*/ 7 _pprint Line_("TriaSearch- find triangle holding a point (x0,y0) in a mesh");8 _pprint Line_("");9 _pprint Line_(" Usage:");10 _pprint Line_(" tria=TriaSearch(index,x,y,x0,y0);");11 _pprint Line_(" index,x,y: mesh triangulatrion");12 _pprint Line_(" x0,y0: coordinates of the point for which we are trying to find a triangle");13 _pprint Line_(" x0,y0 can be an array of points");14 _pprint Line_("");7 _pprintString_("TriaSearch- find triangle holding a point (x0,y0) in a mesh" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" Usage:" << "\n"); 10 _pprintString_(" tria=TriaSearch(index,x,y,x0,y0);" << "\n"); 11 _pprintString_(" index,x,y: mesh triangulatrion" << "\n"); 12 _pprintString_(" x0,y0: coordinates of the point for which we are trying to find a triangle" << "\n"); 13 _pprintString_(" x0,y0 can be an array of points" << "\n"); 14 _pprintString_("" << "\n"); 15 15 }/*}}}*/ 16 16 WRAPPER(TriaSearch){ -
issm/trunk-jpl/src/wrappers/Xy2ll/Xy2ll.cpp
r13236 r15099 5 5 6 6 void Xy2llUsage(void){/*{{{*/ 7 _pprint Line_("Xy2ll - x/y to lat/long coordinate transformation module:");8 _pprint Line_("");9 _pprint Line_(" This module transforms x/y to lat/long coordinates.");10 _pprint Line_("");11 _pprint Line_(" Usage:");12 _pprint Line_(" [lat,lon]=Xy2ll(x,y,sgn,'param name',param,...);");13 _pprint Line_("");14 _pprint Line_(" x x coordinates (double vector)");15 _pprint Line_(" y y coordinates (double vector)");16 _pprint Line_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))");17 _pprint Line_("");18 _pprint Line_(" central_meridian central meridian (double, optional, but must specify with sp)");19 _pprint Line_(" standard_parallel standard parallel (double, optional, but must specify with cm)");20 _pprint Line_("");21 _pprint Line_(" lat latitude coordinates (double vector)");22 _pprint Line_(" lon longitude coordinates (double vector)");23 _pprint Line_("");24 _pprint Line_(" Examples:");25 _pprint Line_(" [lat,lon]=Xy2ll(x,y, 1);");26 _pprint Line_(" [lat,lon]=Xy2ll(x,y, 1,'central_meridian',45,'standard_parallel',70);");27 _pprint Line_(" [lat,lon]=Xy2ll(x,y,-1,'central_meridian', 0,'standard_parallel',71);");28 _pprint Line_("");7 _pprintString_("Xy2ll - x/y to lat/long coordinate transformation module:" << "\n"); 8 _pprintString_("" << "\n"); 9 _pprintString_(" This module transforms x/y to lat/long coordinates." << "\n"); 10 _pprintString_("" << "\n"); 11 _pprintString_(" Usage:" << "\n"); 12 _pprintString_(" [lat,lon]=Xy2ll(x,y,sgn,'param name',param,...);" << "\n"); 13 _pprintString_("" << "\n"); 14 _pprintString_(" x x coordinates (double vector)" << "\n"); 15 _pprintString_(" y y coordinates (double vector)" << "\n"); 16 _pprintString_(" sgn sign for hemisphere (double, +1 (north) or -1 (south))" << "\n"); 17 _pprintString_("" << "\n"); 18 _pprintString_(" central_meridian central meridian (double, optional, but must specify with sp)" << "\n"); 19 _pprintString_(" standard_parallel standard parallel (double, optional, but must specify with cm)" << "\n"); 20 _pprintString_("" << "\n"); 21 _pprintString_(" lat latitude coordinates (double vector)" << "\n"); 22 _pprintString_(" lon longitude coordinates (double vector)" << "\n"); 23 _pprintString_("" << "\n"); 24 _pprintString_(" Examples:" << "\n"); 25 _pprintString_(" [lat,lon]=Xy2ll(x,y, 1);" << "\n"); 26 _pprintString_(" [lat,lon]=Xy2ll(x,y, 1,'central_meridian',45,'standard_parallel',70);" << "\n"); 27 _pprintString_(" [lat,lon]=Xy2ll(x,y,-1,'central_meridian', 0,'standard_parallel',71);" << "\n"); 28 _pprintString_("" << "\n"); 29 29 }/*}}}*/ 30 30 WRAPPER(Xy2ll){ … … 63 63 if (options->GetOption("central_meridian") || options->GetOption("standard_parallel")) { 64 64 options->Get(&cm,"central_meridian"); 65 if (verbose) _print Line_(" cm=" << cm);65 if (verbose) _printString_(" cm=" << cm << "\n"); 66 66 options->Get(&sp,"standard_parallel"); 67 if (verbose) _print Line_(" sp=" << sp);67 if (verbose) _printString_(" sp=" << sp << "\n"); 68 68 } 69 69 … … 79 79 80 80 /* Run core computations: */ 81 if (verbose) _print Line_("Calling core:");81 if (verbose) _printString_("Calling core:" << "\n"); 82 82 if (options->GetOption("central_meridian") && options->GetOption("standard_parallel")) 83 83 iret=Xy2llx(lat,lon,x,y,ncoord,sgn,cm,sp); -
issm/trunk-jpl/src/wrappers/matlab/io/FetchMatlabData.cpp
r15049 r15099 38 38 else{ 39 39 if(!mxIsClass(dataref,"double") && !mxIsClass(dataref,"single")){ 40 _print Line_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'");40 _printString_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'" << "\n"); 41 41 } 42 42 /*Convert matlab matrix to double* matrix: */ … … 85 85 else{ 86 86 if(!mxIsClass(dataref,"double") && !mxIsClass(dataref,"single")){ 87 _print Line_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'");87 _printString_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'" << "\n"); 88 88 } 89 89 /*Convert matlab n-dim array to double* matrix: */ … … 132 132 else{ 133 133 if(!mxIsClass(dataref,"double") && !mxIsClass(dataref,"single")){ 134 _print Line_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'");134 _printString_("Warning: converting matlab data from '" << mxGetClassName(dataref) << "' to 'double'" << "\n"); 135 135 } 136 136 /*Convert matlab matrix to double* matrix: */ -
issm/trunk-jpl/src/wrappers/matlab/io/OptionParse.cpp
r14950 r15099 190 190 option=(Option*)OptionCellParse(name,prhs); 191 191 else { 192 _pprint Line_(" Converting value of option \"" << name << "\" from unrecognized class \"" << mxGetClassName(prhs[0]) << "\" to class \"" << "struct" << "\".");192 _pprintString_(" Converting value of option \"" << name << "\" from unrecognized class \"" << mxGetClassName(prhs[0]) << "\" to class \"" << "struct" << "\"." << "\n"); 193 193 if (!mexCallMATLAB(1,lhs,1,(mxArray**)prhs,"struct")) { 194 194 option=(Option*)OptionStructParse(name,(const mxArray**)lhs); -
issm/trunk-jpl/src/wrappers/python/io/FetchPythonData.cpp
r14917 r15099 728 728 if(i+1 == nrhs) _error_("Argument " << i+2 << " must exist and be value of option \"" << name << "\"."); 729 729 730 _pprint Line_("FetchData for Options not implemented yet, ignoring option \"" << name << "\"!");730 _pprintString_("FetchData for Options not implemented yet, ignoring option \"" << name << "\"!" << "\n"); 731 731 732 732 // option=(Option*)OptionParse(name,&PyTuple_GetItem(py_tuple,(Py_ssize_t)(i+1)));
Note:
See TracChangeset
for help on using the changeset viewer.