Changeset 27931
- Timestamp:
- 10/01/23 18:46:54 (18 months ago)
- Location:
- issm/trunk-jpl/src/c/shared/Elements
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
issm/trunk-jpl/src/c/shared/Elements/PrintArrays.cpp
r24477 r27931 84 84 } 85 85 } 86 87 void InversionStatsHeader(int NJ){ 88 _printf0_("\n"); 89 _printf0_("┌────┬─────────────────┬────────────┬────────────────────────\n"); 90 _printf0_("│Iter│ Cost function │ Grad. norm │ List of contributions \n"); 91 _printf0_("├────┼─────────────────┼────────────┼────────────────────────\n"); 92 } 93 void InversionStatsIter(int iter,double J, double Gnorm, double* Jlist, int N){ 94 _printf0_("│"<<setw(3)<<iter<<" │ "); 95 _printf0_("f(x) = "<<setw(8)<<setprecision(5)<<J<<" │ "); 96 _printf0_(" "<<setw(8)<<setprecision(3)<<Gnorm<<" │"); 97 for(int i=0;i<N;i++) _printf0_(" "<<setw(10)<<setprecision(5)<<Jlist[i]); 98 _printf0_("\n"); 99 } 100 void InversionStatsFooter(int NJ){ 101 _printf0_("└────┴─────────────────┴────────────┴────────────────────────\n"); 102 } -
issm/trunk-jpl/src/c/shared/Elements/elements.h
r24060 r27931 59 59 void printsparsity(IssmPDouble* array,int lines,int cols=1); 60 60 void printbinary(int n); 61 void InversionStatsHeader(int NJ); 62 void InversionStatsIter(int iter,double J, double Gnorm, double* Jlist, int N); 63 void InversionStatsFooter(int NJ); 61 64 #endif //ifndef _SHARED_ELEMENTS_H_
Note:
See TracChangeset
for help on using the changeset viewer.