Serac  0.1
Serac is an implicit thermal strucural mechanics simulation code.
Public Member Functions | Public Attributes | Static Public Attributes | List of all members
DoF Struct Reference

a struct of metadata (index, sign, orientation) associated with a degree of freedom More...

#include <element_restriction.hpp>

Public Member Functions

 DoF ()
 default ctor
 
 DoF (const DoF &other)
 copy ctor
 
 DoF (uint64_t index, uint64_t sign=0, uint64_t orientation=0)
 create a DoF from the given index, sign and orientation values
 
void operator= (const DoF &other)
 copy assignment operator
 
int sign () const
 get the sign field of this DoF
 
uint64_t orientation () const
 get the orientation field of this DoF
 
uint64_t index () const
 get the index field of this DoF
 

Public Attributes

uint64_t bits
 a 64-bit word encoding the following metadata (laid out from MSB to LSB); More...
 

Static Public Attributes

static constexpr uint64_t sign_mask = 0x8000'0000'0000'0000
 bits for sign field
 
static constexpr uint64_t orientation_mask = 0x7000'0000'0000'0000
 bits for orientation field
 
static constexpr uint64_t index_mask = 0x0000'FFFF'FFFF'FFFF'FFFF
 bits for the index field
 
static constexpr uint64_t sign_shift = 63
 number of trailing zeros in sign_mask
 
static constexpr uint64_t orientation_shift = 60
 number of trailing zeros in orientation_mask
 
static constexpr uint64_t index_shift = 0
 number of trailing zeros in index_mask
 

Detailed Description

a struct of metadata (index, sign, orientation) associated with a degree of freedom

Definition at line 31 of file element_restriction.hpp.

Member Data Documentation

◆ bits

uint64_t DoF::bits

a 64-bit word encoding the following metadata (laid out from MSB to LSB);

  • 1 sign bit
  • 3 orientation bits
  • 12 currently unused bits that may be used in the future
  • 48 index bits

all values are immutable unsigned integers

Definition at line 55 of file element_restriction.hpp.


The documentation for this struct was generated from the following file: