aboutsummaryrefslogtreecommitdiff
path: root/src/elliptic/row_sparse_Jacobian.cc
diff options
context:
space:
mode:
Diffstat (limited to 'src/elliptic/row_sparse_Jacobian.cc')
-rw-r--r--src/elliptic/row_sparse_Jacobian.cc44
1 files changed, 27 insertions, 17 deletions
diff --git a/src/elliptic/row_sparse_Jacobian.cc b/src/elliptic/row_sparse_Jacobian.cc
index a53c3fb..bb20395 100644
--- a/src/elliptic/row_sparse_Jacobian.cc
+++ b/src/elliptic/row_sparse_Jacobian.cc
@@ -101,6 +101,10 @@ using jtutil::error_exit;
#include "Jacobian.hh"
#include "row_sparse_Jacobian.hh"
+// all the code in this file is inside this namespace
+namespace AHFinderDirect
+ {
+
//******************************************************************************
//******************************************************************************
//******************************************************************************
@@ -204,7 +208,7 @@ if (print_msg_flag)
zero_matrix();
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -218,7 +222,7 @@ delete[] A_;
delete[] JA_;
delete[] IA_;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -232,7 +236,7 @@ fp row_sparse_Jacobian::element(int II, int JJ)
const int posn = find_element(II,JJ);
return (posn >= 0) ? A_[posn] : 0.0;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -250,7 +254,7 @@ N_nonzeros_ = 0;
current_N_rows_= 0;
IA_[0] = IO_;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -265,7 +269,7 @@ if (posn >= 0)
then A_[posn] = value;
else insert_element(II,JJ, value);
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -280,7 +284,7 @@ if (posn >= 0)
then A_[posn] += value;
else insert_element(II,JJ, value);
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -306,7 +310,7 @@ const int stop = IA_[II+1] - IO_;
return -1; // not found
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -379,7 +383,7 @@ check_and_print_data_structure(true);
return posn;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -413,7 +417,7 @@ delete[] JA_;
JA_ = new_JA;
A_ = new_A;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
@@ -567,8 +571,8 @@ assert(N_nonzeros_ <= N_nonzeros_allocated_);
if (print_flag)
then printf("--- end Jacobian printout\n");
}
-#endif // DEBUG_ROW_SPARSE_JACOBIAN
-#endif // HAVE_ROW_SPARSE_JACOBIAN
+#endif /* DEBUG_ROW_SPARSE_JACOBIAN */
+#endif /* HAVE_ROW_SPARSE_JACOBIAN */
//******************************************************************************
//******************************************************************************
@@ -590,7 +594,7 @@ if (print_msg_flag)
then CCTK_VInfo(CCTK_THORNSTRING,
" ILUCG linear-equations solver");
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__ILUCG
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__ILUCG */
//******************************************************************************
@@ -603,7 +607,7 @@ row_sparse_Jacobian__ILUCG::~row_sparse_Jacobian__ILUCG()
delete[] rtemp_;
delete[] itemp_;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__ILUCG
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__ILUCG */
//******************************************************************************
@@ -718,7 +722,7 @@ if (print_msg_flag)
return -1.0; // no condition number estimate available
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__ILUCG
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__ILUCG */
//******************************************************************************
//******************************************************************************
@@ -746,7 +750,7 @@ if (print_msg_flag)
umfpack_defaults(Control_);
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__UMFPACK
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__UMFPACK */
//******************************************************************************
@@ -765,7 +769,7 @@ delete[] solve_workspace_integer_;
delete[] Info_;
delete[] Control_;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__UMFPACK
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__UMFPACK */
//******************************************************************************
@@ -907,4 +911,10 @@ if (Numeric_ != NULL)
return rcond;
}
-#endif // HAVE_ROW_SPARSE_JACOBIAN__UMFPACK
+#endif /* HAVE_ROW_SPARSE_JACOBIAN__UMFPACK */
+
+//******************************************************************************
+//******************************************************************************
+//******************************************************************************
+
+ } // namespace AHFinderDirect