SPADES
  • Introduction
  • Getting Started
  • SPADES
  • SPADES API
SPADES
  • SPADES API: spades::particles::Print Struct Reference
  • View page source

Print Struct Reference

SPADES API: spades::particles::Print Struct Reference
SPADES API
  • spades
  • particles
  • Print
Public Member Functions | List of all members
spades::particles::Print Struct Reference

Functor for printing particle data on host. More...

#include <ParticleOps.H>

Public Member Functions

template<class PArrs >
void operator() (const amrex::Long n, PArrs &parrs) const
 Print particle data to screen.
 

Detailed Description

Functor for printing particle data on host.

Member Function Documentation

◆ operator()()

template<class PArrs >
void spades::particles::Print::operator() ( const amrex::Long n,
PArrs & parrs ) const
inline

Print particle data to screen.

Parameters
n[in] particle index whose data is printed
parrs[in] particle arrays
53 {
54 auto& p = parrs.m_aos[n];
55 amrex::Print() << "Particle data: \n"
56 << " id = " << p.id() << "\n"
57 << " cpu = " << p.cpu() << "\n"
58 << " type = "
59 << parrs.m_idata[CommonIntData::type_id][n] << "\n";
60 for (int i = 0; i < p.NInt; i++) {
61 amrex::Print() << " int comp(" << i
62 << ") = " << parrs.m_idata[i][n] << "\n";
63 }
64 for (int i = 0; i < p.NReal; i++) {
65 amrex::Print() << " real comp(" << i
66 << ") = " << parrs.m_rdata[i][n] << "\n";
67 }
68 }
spades::particles::CommonIntData::type_id
@ type_id
Definition ParticleData.H:18

The documentation for this struct was generated from the following file:
  • /home/runner/work/spades/spades/Source/ParticleOps.H

Generated by doxygen 1.12.0

© Copyright 2023, the Alliance for Sustainable Energy, LLC., through National Renewable Energy Laboratory. All rights reserved.

Built with Sphinx using a theme provided by Read the Docs.