peclet-dem 1.1.0
Performance-portable XPBD Discrete Element Method (Kokkos + ArborX)
Loading...
Searching...
No Matches
shapes_portable.hpp File Reference

dem — portable (host) surface-shell point generators for the analytic shapes. More...

#include <cmath>
#include <vector>
#include "dem_portable.hpp"

Go to the source code of this file.

Namespaces

namespace  peclet
 
namespace  peclet::dem
 

Functions

std::vector< F3 > peclet::dem::genCylinderShell (float radius, float height, float thickness, float spacing)
 
std::vector< F3 > peclet::dem::genBoxShell (float hx, float hy, float hz, float spacing)
 

Variables

constexpr double peclet::dem::kPi = 3.14159265358979323846
 

Detailed Description

dem — portable (host) surface-shell point generators for the analytic shapes.

Faithful copy of shapes/point_sampler.cpp (generate_cylinder_points / generate_box_points), but emitting peclet::dem::F3 instead of CUDA float4 so the Kokkos module can build the point shell without the CUDA vector_types.h dependency. The point math (spacing, ceil counts, cos/sin sampling, cap annulus, box faces incl. edges/corners) is byte-for-byte the same so the generated shells match the CUDA path.

Definition in file shapes_portable.hpp.