26 #include "../Rocblas/include/Rocblas.h"
32 COM::Attribute *disp,
int *smoothed) {
34 COM_assertion( disp->size_of_components()==3 && disp->is_nodal());
39 if ( smoothed) *smoothed =
false;
46 COM::Attribute *disp) {
47 assert( spd->size_of_components()==1);
49 if ( spd->is_nodal()) {
51 _surf->compute_normals( disp);
58 COM::Window *win = disp->window();
59 COM::Window buf( win->name()+
"-marker", win->get_communicator());
60 buf.inherit( win->attribute(
COM::COM_MESH),
"",
false,
true, NULL, 0);
62 buf.inherit(const_cast<COM::Attribute*>(spd),
"spd",
false,
true, NULL, 0);
64 buf.new_attribute(
"elem_normals",
'e',
COM_DOUBLE, 3,
"");
65 buf.resize_array(
"elem_normals", 0, NULL);
69 _surf->compute_normals( elem_normals);
void inherit(Attribute *a, bool clone, bool withghost, int depth=0)
Inherit from parent. If depth>0, then the procedure is for the subcomponents.
#define COM_assertion(EX)
Error checking utility similar to the assert macro of the C language.
#define PROP_END_NAMESPACE
An Attribute object is a data member of a window.
#define PROP_BEGIN_NAMESPACE
static void mul_scalar(const Attribute *x, const void *y, Attribute *z, int swap=0)
Operation wrapper for multiplication with y as a scalar pointer.
void multiply_nodal_normals(const COM::Attribute *a, COM::Attribute *b)
virtual double time_stepping(const COM::Attribute *spd, double dt, COM::Attribute *disp, int *smoothed=NULL)
Main entry of the algorithm.
static void mul(const Attribute *x, const Attribute *y, Attribute *z)
Operation wrapper for multiplication.