38template<
class T,
unsigned Dim>
40 Inform& out,
bool allnodes) {
46 print(F, domain, out, allnodes);
51template<
class T,
unsigned Dim>
59 print(F, domain, out, allnodes);
64template<
class T,
unsigned Dim>
68 print(F, view, out, allnodes);
73template<
class T,
unsigned Dim>
94 ERRORMSG(
"FieldDebugPrint::print - the domain of the field: " << domain<<
endl);
95 ERRORMSG(
" must contain the selected view: " << view <<
endl);
117 BPS falseitem(
false);
118 BLFI blhs = availLField.
begin();
145 LFI rhs = l.
begin(intersection, compressed_data);
149 rhs.putMessage(*mess);
159 for (
int remaining =
Ippl::getNodes() - 1; remaining > 0; --remaining) {
168 while (datahere != 0) {
175 LFI rhs(compressed_value);
176 rhs.getMessage(*mess);
181 LFI lhs = myLField.
begin(localBlock);
183 BLFI blhs = availLField.
begin(localBlock);
224 LFI lhs = myLField.
begin(intersection);
225 LFI rhs = l.
begin(intersection);
227 BLFI blhs = availLField.
begin(intersection);
243 LFI lhs = myLField.
begin(intersection);
244 LFI rhs = l.
begin(intersection);
246 BLFI blhs = availLField.
begin(intersection);
252 out <<
"~~~~~~~~ field slice ";
253 for (
unsigned int pd=0; pd <
Dim; ++pd) {
254 out << (pd == 0 ?
"(" :
", ");
255 out << view[pd].first() <<
":" << view[pd].last();
256 out <<
":" << view[pd].stride();
258 out <<
") ~~~~~~~~" <<
endl;
260 out.
setf(std::ios::scientific);
262 unsigned int i0, i1, i2;
263 LFI liter = myLField.
begin();
264 BLFI bliter = availLField.
begin();
267 for (i0=0; i0 < view[0].length(); ++i0, ++liter, ++bliter)
268 printelem(*bliter, *liter, i0, out);
273 for (i1=0; i1 < view[1].length(); ++i1) {
274 out <<
"--------------------------------------------------J = ";
275 out << view[1].first() + i1 <<
endl;
276 for (i0=0; i0 < view[0].length(); ++i0, ++liter, ++bliter)
277 printelem(*bliter, *liter, i0, out);
284 for (i2=0; i2 < view[2].length(); ++i2) {
285 out <<
"==================================================K = ";
286 out << view[2].first() + i2 <<
endl;
287 for (i1=0; i1 < view[1].length(); ++i1) {
288 out <<
"--------------------------------------------------J = ";
289 out << view[1].first() + i1 <<
endl;
290 for (i0=0; i0 < view[0].length(); ++i0, ++liter, ++bliter)
291 printelem(*bliter, *liter, i0, out);
299 ERRORMSG(
"bad Dimension \"" <<
Dim <<
"\" in FieldDebugPrint::print()");
308template<
class T,
unsigned Dim>
310 unsigned int i0,
Inform& out) {
311 if (DataPrecision > 0)
312 out << std::setprecision(DataPrecision);
314 out << std::setw(DataWidth);
316 out.
setf(std::ios::scientific);
321 if (CarReturn > 0 && ((i0+1) % CarReturn) == 0)
void putMessage(Message &m, const T &t)
void getMessage(Message &m, T &t)
NDIndex< Dim > AddGuardCells(const NDIndex< Dim > &idx, const GuardCellSizes< Dim > &g)
Inform & endl(Inform &inf)
bool touches(const NDIndex< Dim > &) const
Message & putMessage(Message &m) const
bool contains(const NDIndex< Dim > &a) const
Message & getMessage(Message &m)
NDIndex< Dim > intersect(const NDIndex< Dim > &) const
const NDIndex< Dim > & getDomain() const
ac_id_larray::iterator iterator_if
virtual void fillGuardCells(bool reallyFill=true) const
const GuardCellSizes< Dim > & getGuardCellSizes() const
const NDIndex< Dim > & getOwned() const
const NDIndex< Dim > & getAllocated() const
void Uncompress(bool fill_domain=true)
const iterator & begin() const
bool send(Message *, int node, int tag, bool delmsg=true)
Message * receive_block(int &node, int &tag)
int next_tag(int t, int s=1000)
void print(BareField< T, Dim > &, const NDIndex< Dim > &, Inform &, bool=true)
void printelem(bool, T &, unsigned int, Inform &)
FmtFlags_t setf(FmtFlags_t setbits, FmtFlags_t field)
static void abort(const char *=0)
static Communicate * Comm