MercuryDPM  Alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
StatisticsVector.h
Go to the documentation of this file.
1 //Copyright (c) 2013-2014, The MercuryDPM Developers Team. All rights reserved.
2 //For the list of developers, see <http://www.MercuryDPM.org/Team>.
3 //
4 //Redistribution and use in source and binary forms, with or without
5 //modification, are permitted provided that the following conditions are met:
6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above copyright
9 // notice, this list of conditions and the following disclaimer in the
10 // documentation and/or other materials provided with the distribution.
11 // * Neither the name MercuryDPM nor the
12 // names of its contributors may be used to endorse or promote products
13 // derived from this software without specific prior written permission.
14 //
15 //THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
16 //ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17 //WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18 //DISCLAIMED. IN NO EVENT SHALL THE MERCURYDPM DEVELOPERS TEAM BE LIABLE FOR ANY
19 //DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
20 //(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
21 //LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
22 //ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
23 //(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
24 //SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
25 
26 #ifndef STATISTICSVECTOR_H
27 #define STATISTICSVECTOR_H
28 #include "DPMBase.h"
29 #include "Math/Matrix.h"
30 #include "Math/MatrixSymmetric.h"
31 #include <string.h>
32 #include <fstream>
33 #include <math.h>
39 {
40  O, X, Y, Z, XY, XZ, YZ, XYZ, RAZ, RZ, AZ, RA, R, A
41 };
42 
44 #include "StatisticsPoint.h"
45 
58 template<StatType T>
59 class StatisticsVector : public virtual DPMBase
60 {
61 public:
65  void constructor();
66 
70  void constructor(std::string name);
71 
76  {
77  constructor();
78  }
79 
83  StatisticsVector(std::string name)
84  {
85  constructor(name);
86  }
87 
92 
96  StatisticsVector(int argc, char *argv[]);
100  void readStatArguments(int argc, char *argv[]);
101 
105  std::string prIntStat();
106 
110  void set_statType();
111 
112  void writeOutputFiles();
113 
117  void print_help();
118 
119  //set functions should be called before executing the statistical routine
120 
124  void setNX(int new_)
125  {
126  nx = new_;
127  }
128 
132  void set_hx(Mdouble hx)
133  {
134  setNX(static_cast<int>(std::ceil((getXMaxStat() - getXMinStat()) / hx)));
135  }
136 
140  void setNY(int new_)
141  {
142  ny = new_;
143  }
144 
148  void set_hy(Mdouble hy)
149  {
150  setNY(static_cast<int>(std::ceil((getYMaxStat() - getYMinStat()) / hy)));
151  }
152 
156  void setNZ(int new_)
157  {
158  nz = new_;
159  if (getSystemDimensions() < 3)
160  std::cerr << "Warning in set_nz: dimension less than 3" << std::endl;
161  }
162 
166  void set_hz(Mdouble hz)
167  {
168  setNZ(static_cast<int>(std::ceil((getZMaxStat() - getZMinStat()) / hz)));
169  }
170 
174  void setN(int n)
175  {
176  setNX(n);
177  setNY(n);
178  setNZ(n);
179  }
180 
184  void set_h(Mdouble h)
185  {
186  set_hx(h);
187  set_hy(h);
188  set_hz(h);
189  }
190 
194  int getNX()
195  {
196  return nx;
197  }
198 
202  int getNY()
203  {
204  return ny;
205  }
206 
210  int getNZ()
211  {
212  return nz;
213  }
214 
219  {
220  tMinStat = t;
221  }
222 
227  {
228  tMaxStat = t;
229  }
230 
235  {
236  tIntStat = t;
237  }
238 
243  {
244  return tMinStat;
245  }
246 
251  {
252  if (std::isnan(tMaxStat))
253  return getTimeMax();
254  else
255  return tMaxStat;
256  }
257 
262  {
263  return tIntStat;
264  }
265 
270  {
271  return (getTime() >= getCGTimeMin() && getTime() <= getTimeMaxStat() + getTimeStep());
272  }
273 
274 
278  void setCGShape(const char* new_);
279 
283  void setCGShape(CG new_);
284 
289  {
290  return CG_type;
291  }
292 
296  void setN(int nx_, int ny_, int nz_)
297  {
298  nx = nx_;
299  ny = ny_;
300  nz = nz_;
301  }
302 
303  void getN(int& nx_, int& ny_, int& nz_)
304  {
305  nx_ = nx;
306  ny_ = ny;
307  nz_ = nz;
308  }
309 
310 
313  {
315  }
316 
317 
321  void setCGWidth2(Mdouble new_);
322 
327  {
328  return std::sqrt(w2);
329  }
330 
335  {
336  return w2;
337  }
338 
343  {
344  return cutoff;
345  }
346 
351  {
352  return mathsFunc::square(cutoff);
353  }
354 
355 
356  //~ bool get_boundedDomain() {return boundedDomain;};
357  //~ void set_boundedDomain(bool new_) {boundedDomain=new_;};
358 
362  std::string print_CG();
363 
368 
372  virtual void reset_statistics();
373 
378 
382  void statistics_from_p3();
383 
387  void jump_p3c();
388 
392  void setDoTimeAverage(bool new_)
393  {
394  doTimeAverage = new_;
395  }
396 
401  {
402  return doTimeAverage;
403  }
404 
405 
410  {
412  }
413 
418  {
420  }
421 
422 
423  // to keep compatible with older versions
428  {
429  StressTypeForFixedParticles = 2 + new_;
430  }
431 
432 
437  {
438  mirrorAtDomainBoundary = new_;
439  }
440 
445  {
446  return mirrorAtDomainBoundary;
447  }
448 
449 
453  void setDoVariance(bool new_)
454  {
455  doVariance = new_;
456  }
457 
462  {
463  return doVariance;
464  }
465 
466 
470  void setDoGradient(bool new_)
471  {
472  doGradient = new_;
473  }
474 
479  {
480  return doGradient;
481  }
482 
486  void setSuperExact(bool new_)
487  {
488  superexact = new_;
489  }
490 
495  {
496  return superexact;
497  }
498 
503  {
504  ignoreFixedParticles = new_;
505  }
506 
511  {
512  return ignoreFixedParticles;
513  }
514 
518  void verbose()
519  {
520  verbosity = 2;
521  }
522 
526  void setVerbosityLevel(int new_)
527  {
528  verbosity = new_;
529  }
530 
534  int getVerbosityLevel() const
535  {
536  return verbosity;
537  }
538 
542  void setCGWidthalls(bool new_)
543  {
544  walls = new_;
545  }
546 
551  {
552  return walls;
553  }
554 
558  void setDoPeriodicWalls(bool new_)
559  {
560  periodicWalls = new_;
561  }
562 
567  {
568  return periodicWalls;
569  }
570 
571 
576  {
577  w_over_rmax = new_;
578  }
579 
584  {
585  return w_over_rmax;
586  }
587 
588 
592  void setPositions();
593 
597  bool readNextDataFile(unsigned int format);
598 
603 
607  void gather_force_statistics_from_p3c(int version);
608 
612  void gather_force_statistics_from_p3w(int version, std::vector<int>& index);
613 
617  void evaluate_force_statistics(int wp = 0);
618 
622  void evaluate_wall_force_statistics(Vec3D P, int wp = 0);
623 
627  void jump_fstat();
628 
632  void initialiseStatistics();
633 
637  void outputStatistics();
638 
642  void gatherContactStatistics(unsigned int index1, int index2, Vec3D Contact, Mdouble delta, Mdouble ctheta, Mdouble fdotn, Mdouble fdott, Vec3D P1_P2_normal_, Vec3D P1_P2_tangential);
643 
647  void processStatistics(bool usethese);
648 
652  void finishStatistics();
653 
657  void write_statistics();
658 
663 
667  void evaluate_particle_statistics(std::vector<BaseParticle*>::iterator P, int wp = 0);
668 
672  std::vector<StatisticsPoint<T> > getCGPoints()
673  {
674  return Points;
675  }
676 
681  {
682  if (std::isnan(xMinStat))
683  return getXMin();
684  else
685  return xMinStat;
686  }
687 
692  {
693  if (std::isnan(yMinStat))
694  return getYMin();
695  else
696  return yMinStat;
697  }
698 
703  {
704  if (std::isnan(zMinStat))
705  return getZMin();
706  else
707  return zMinStat;
708  }
709 
714  {
715  if (std::isnan(xMaxStat))
716  return getXMax();
717  else
718  return xMaxStat;
719  }
720 
725  {
726  if (std::isnan(yMaxStat))
727  return getYMax();
728  else
729  return yMaxStat;
730  }
731 
736  {
737  if (std::isnan(zMaxStat))
738  return getZMax();
739  else
740  return zMaxStat;
741  }
742 
746  void setXMinStat(Mdouble xMinStat_)
747  {
748  xMinStat = xMinStat_;
749  }
750 
754  void setYMinStat(Mdouble yMinStat_)
755  {
756  yMinStat = yMinStat_;
757  }
758 
762  void setZMinStat(Mdouble zMinStat_)
763  {
764  zMinStat = zMinStat_;
765  }
766 
770  void setXMaxStat(Mdouble xMaxStat_)
771  {
772  xMaxStat = xMaxStat_;
773  }
774 
778  void setYMaxStat(Mdouble yMaxStat_)
779  {
780  yMaxStat = yMaxStat_;
781  }
782 
786  void setZMaxStat(Mdouble zMaxStat_)
787  {
788  zMaxStat = zMaxStat_;
789  }
790 
795  {
796  return nTimeAverage;
797  }
798 
803 
804  void set_Polynomial(std::vector<Mdouble> new_coefficients, unsigned int new_dim)
805  {
806  CGPolynomial.set_polynomial(new_coefficients, new_dim);
807  }
808 
812  void set_Polynomial(Mdouble* new_coefficients, unsigned int num_coeff, unsigned int new_dim)
813  {
814  CGPolynomial.set_polynomial(new_coefficients, num_coeff, new_dim);
815  }
816 
820  void setPolynomialName(const char* new_name)
821  {
822  CGPolynomial.setName(new_name);
823  }
824 
828  std::string getPolynomialName()
829  {
830  return CGPolynomial.getName();
831  }
832 
836  void setDoDoublePoints(bool new_)
837  {
838  doDoublePoints = new_;
839  }
840 
845  {
846  return doDoublePoints;
847  }
848 
852  void setNTimeAverageReset(int new_)
853  {
854  nTimeAverageReset = new_;
855  }
856 
861  {
862  return nTimeAverageReset;
863  }
864 
868  void set_rmin(Mdouble new_)
869  {
870  rmin = new_;
871  }
872 
876  void set_rmax(Mdouble new_)
877  {
878  rmax = new_;
879  }
880 
884  void set_hmax(Mdouble new_)
885  {
886  hmax = new_;
887  }
888 
893  {
894  return CGPolynomial.evaluate(r);
895  }
896 
901  {
902  return CGPolynomial.evaluateGradient(r);
903  }
904 
909  {
910  return CGPolynomial.evaluateIntegral(n1, n2, t);
911  }
912 
916  unsigned int getStepSize() const
917  {
918  return stepSize_;
919  }
920 
924  void setStepSize(unsigned int stepSize)
925  {
926  stepSize_ = stepSize;
927  }
928 
932  void setIndSpecies(unsigned int indSpecies)
933  {
934  this->indSpecies = indSpecies;
935  }
936  //Member Variables
937 protected:
938 
939  //General Variables
947  int nx;
948  int ny;
949  int nz;
958 
959  //Storage of points and gradients
963  std::vector<StatisticsPoint<T> > Points;
967  std::vector<StatisticsPoint<T> > dx;
971  std::vector<StatisticsPoint<T> > dy;
975  std::vector<StatisticsPoint<T> > dz;
976 
977  //For time averaging
981  std::vector<StatisticsPoint<T> > timeAverage;
982 
986  std::vector<StatisticsPoint<T> > timeVariance;
987 
991  std::vector<StatisticsPoint<T> > dxTimeAverage;
992 
996  std::vector<StatisticsPoint<T> > dyTimeAverage;
997 
1001  std::vector<StatisticsPoint<T> > dzTimeAverage;
1002 
1007 
1012 
1017 
1022 
1027 
1028  //Coarse graining variables
1037 
1038  // ///<if true, then the course-graining function will be cut at the domain boundaries and resized to satisfy int(W) = 1
1039  // bool boundedDomain;
1040 
1045 
1050 
1055 
1056  //Options that can be set before evaluation
1057 
1062 
1067 
1072 
1077 
1083 
1088 
1093 
1097  bool walls;
1098 
1104 
1109 
1118 
1126 
1127  int format;
1128 
1133 
1136 
1137  //uses close points to allow calculation of gradients
1139 
1144 
1145  //Variables communicate values between member functions #evaluate_force_statistics and #gatherContactStatistics)used to communicate values between member functions evaluate_force_statistics and gather_force_statistics
1174 
1178  bool loadVelocityProfile(const char* filename);
1179  bool loadPositions(const char* filename);
1180 
1184  Vec3D getVelocityProfile(Vec3D Position);
1185 
1189  std::vector<Vec3D> VelocityProfile;
1190 
1195 
1200 
1201  std::fstream p3p_file;
1202  std::fstream p3c_file;
1203  std::fstream p3w_file;
1204 
1208  bool read_next_from_p3p_file();
1209 
1213  void auto_setdim();
1214 
1215  unsigned int stepSize_;
1216 
1217  std::vector<Vec3D> positions_;
1218 };
1219 
1220 #include "StatisticsPoint.hcc"
1221 #include "StatisticsVector.hcc"
1222 
1223 #endif
void set_hx(Mdouble hx)
StatisticsVector()
Basic constructor only calls constructor()
void readStatArguments(int argc, char *argv[])
bool periodicWalls
Turns off periodic walls before evaluation (needed for averaging, because we do not yet check if part...
void gather_force_statistics_from_fstat_and_data()
std::vector< StatisticsPoint< T > > dyTimeAverage
a vector used to sum up all statistical gradients in dy for time-averaging
void setPolynomialName(const char *new_name)
void getN(int &nx_, int &ny_, int &nz_)
The DPMBase header includes quite a few header files, defining all the handlers, which are essential...
Definition: DPMBase.h:65
Vec3D P2
Position of second contact point.
bool walls
Turns off walls before evaluation.
StatType statType
Possible values X,Y,Z,XY,XZ,YZ,XYZ,RAZ,RA,RZ,AZ,R,A are used to determine if the statistics are avera...
bool check_current_time_for_statistics()
void setXMinStat(Mdouble xMinStat_)
Vec3D P1_P2_TangentialTraction
Traction from tangential forces at contact of flow with fixed particles or walls. ...
void initialiseStatistics()
Initializes statistics, i.e. setting w2, setting the grid and writing the header lines in the ...
void setNTimeAverageReset(int new_)
StatType
Creates averaged statistics (only valid if density field is homogenous along averaged direction) ...
void write_time_average_statistics()
Writes out time averaged statistics.
unsigned int getSystemDimensions() const
Returns the dimension of the simulation. Note there is also a particle dimension. ...
Definition: DPMBase.cc:575
Mdouble getCGTimeAveragingInterval()
void processStatistics(bool usethese)
Processes all gathered statistics and resets them afterwards. (Processing means either calculating ti...
Mdouble evaluatePolynomialGradient(Mdouble r)
bool satisfiesInclusionCriteria(BaseParticle *P)
Mdouble w_over_rmax
if w is not set manually then w will be set by multiplying this value by the largest particle radius ...
void setMirrorAtDomainBoundary(Mdouble new_)
void set_h(Mdouble h)
std::vector< Vec3D > VelocityProfile
Mdouble getMirrorAtDomainBoundary()
std::vector< StatisticsPoint< T > > dz
A vector that stores the gradient in z of all statistical variables at a given position.
Mdouble cutoff
The distance from the origin at which the cg function vanishes; cutoff=w for HeavisideSphere or Polyn...
Mdouble getZMax() const
If the length of the problem domain in z-direction is ZMax - ZMin, then getZMax() returns ZMax...
Definition: DPMBase.cc:319
Mdouble getXMin() const
If the length of the problem domain in x-direction is XMax - XMin, then getXMin() returns XMin...
Definition: DPMBase.cc:279
void gather_force_statistics_from_p3w(int version, std::vector< int > &index)
std::vector< StatisticsPoint< T > > dy
A vector that stores the gradient in y of all statistical variables at a given position.
Mdouble getCGWidth_over_rmax()
Mdouble getYMin() const
If the length of the problem domain in y-direction is YMax - YMin, then getYMin() returns YMin...
Definition: DPMBase.cc:295
void constructor()
this is the actual constructor, sets up all basic things
bool loadPositions(const char *filename)
double Mdouble
std::fstream p3p_file
StatisticsVector(std::string name)
void setDoVariance(bool new_)
Vec3D P1
Position of first contact point.
bool loadVelocityProfile(const char *filename)
Mdouble w2
coarse graining width squared; for HeavisideSphere and Gaussian
Mdouble getXMinStat()
Functions to acces and change the domain of statistics.
std::fstream p3w_file
void setNX(int new_)
void write_statistics()
Writes regular statistics.
bool readNextDataFile(unsigned int format)
Mdouble P1_P2_Dissipation
not yet working
Mdouble getTimeMaxStat()
std::string getPolynomialName()
void setCGShape(const char *new_)
std::vector< StatisticsPoint< T > > dx
A vector that stores the gradient in x of all statistical variables at a given position.
Mdouble P1_P2_distance
Length of contact line.
void setStepSize(unsigned int stepSize)
void set_hy(Mdouble hy)
void set_infiniteStressForFixedParticles(bool new_)
void evaluate_wall_force_statistics(Vec3D P, int wp=0)
void setStressTypeForFixedParticles(int new_)
void setDoGradient(bool new_)
T square(T val)
squares a number
Definition: ExtendedMath.h:91
int nx
Grid size nx,ny,nz (by default the points of evaluation are placed in an grid on the domain [xMinStat...
Mdouble tIntStat
Statistical output will only be created if tMaxStat-tIntStat< t< tMaxStat.
void setZMinStat(Mdouble zMinStat_)
Mdouble evaluatePolynomial(Mdouble r)
void setCGTimeMin(Mdouble t)
bool read_next_from_p3p_file()
CG
enum used to store the type of coarse-graining function used
Mdouble getXMax() const
If the length of the problem domain in x-direction is XMax - XMin, then getXMax() returns XMax...
Definition: DPMBase.cc:287
void setYMaxStat(Mdouble yMaxStat_)
void set_hz(Mdouble hz)
int nTimeAverage
A counter needed to average over time.
void setDoPeriodicWalls(bool new_)
Mdouble getCGWidthSquared()
void setCGWidth2(Mdouble new_)
Set CG variables w2 and CG_invvolume.
int nTimeAverageReset
Determines after how many timesteps the time average is reset.
std::vector< StatisticsPoint< T > > dxTimeAverage
a vector used to sum up all statistical gradients in dx for time-averaging
std::vector< Vec3D > positions_
std::vector< StatisticsPoint< T > > dzTimeAverage
a vector used to sum up all statistical gradients in dz for time-averaging
void setNZ(int new_)
std::string prIntStat()
Outputs member variable values to a std::string.
Mdouble indSpecies
defines the species for which statistics are extracted (-1 for all species)
void evaluate_force_statistics(int wp=0)
void statistics_from_p3()
Mdouble tMinStat
Statistical output will only be created if t>tMinStat.
Mdouble rmin
defines the minimum radius of the particles for which statistics are extracted
Vec3D getVelocityProfile(Vec3D Position)
void set_rmax(Mdouble new_)
NORMALIZED_POLYNOMIAL< T > CGPolynomial
Stores the Polynomial, if the cg function is an axisymmetric function Polynomial in r...
std::vector< StatisticsPoint< T > > getCGPoints()
void setIndSpecies(unsigned int indSpecies)
bool getDoIgnoreFixedParticles()
void setCGWidthalls(bool new_)
void statistics_from_fstat_and_data()
get StatisticsPoint
void evaluate_particle_statistics(std::vector< BaseParticle * >::iterator P, int wp=0)
Calculates statistics for a single Particle.
void setTimeMaxStat(Mdouble t)
Vec3D P1_P2_normal
Direction of contact.
int format
format of the data input file
bool doTimeAverage
Determines if output is averaged over time.
void setNY(int new_)
void set_Polynomial(std::vector< Mdouble > new_coefficients, unsigned int new_dim)
void setSuperExact(bool new_)
std::vector< StatisticsPoint< T > > timeVariance
a vector used to sum up the variance in time of all statistical values
void setN(int nx_, int ny_, int nz_)
void setYMinStat(Mdouble yMinStat_)
Mdouble mirrorAtDomainBoundary
0: Statistics near the wall are equal to statistics away from the wall; 1: Statistics are mirrored at...
bool doVariance
Determines if variance is outputted.
void setCGWidth(Mdouble w)
Set CG variables w2 and CG_invvolume.
unsigned int getStepSize() const
Mdouble xMinStat
By default the domain is set to the domain of the MD problem (indicated by setting the stat-domain va...
Mdouble getYMax() const
If the length of the problem domain in y-direction is YMax - YMin, then getYMax() returns XMax...
Definition: DPMBase.cc:303
void setDoDoublePoints(bool new_)
MatrixSymmetric3D P1_P2_Fabric
Fabric.
void set_hmax(Mdouble new_)
void setZMaxStat(Mdouble zMaxStat_)
Matrix3D P1_P2_NormalStress
Contact stress from normal forces along the line of contact.
std::fstream p3c_file
Vec3D P1_P2_CollisionalHeatFlux
not yet working
std::vector< StatisticsPoint< T > > Points
A vector that stores the values of the statistical variables at a given position. ...
int getStressTypeForFixedParticles()
This class stores statistical values for a given spatial position; to be used in combination with Sta...
int verbosity
Determines how much is outputted to the terminal.
StatisticsPoint< T > average(std::vector< StatisticsPoint< T > > &P)
Output average of statistical variables.
void outputStatistics()
Calculates statistics for Particles (i.e. not collisions)
Mdouble getZMin() const
If the length of the problem domain in z-direction is ZMax - ZMin, then getZMin() returns ZMin...
Definition: DPMBase.cc:311
CG CG_type
coarse graining type (Gaussian, Heaviside, Polynomial)
void gatherContactStatistics()
Definition: DPMBase.cc:811
Mdouble hmax
defines the maximum height of the particles for which statistics are extracted
This class is used to extract statistical data from MD simulations.
Matrix3D P1_P2_ContactCoupleStress
void writeOutputFiles()
Writes the simulation data onto all the files i.e. .data, .ene, .fstat ...
std::vector< StatisticsPoint< T > > timeAverage
A vector used to sum up all statistical values in Points for time-averaging.
This class is used to define polynomial axisymmetric coarse-graining functions.
int getVerbosityLevel() const
void setVerbosityLevel(int new_)
unsigned int stepSize_
Mdouble setInfinitelyLongDistance()
bool superexact
If true, cutoff radius for Gaussian is set to 5*w (from 3*w)
void set_Polynomial(Mdouble *new_coefficients, unsigned int num_coeff, unsigned int new_dim)
void finishStatistics()
Finish all statistics (i.e. write out final data)
bool ignoreFixedParticles
Determines if fixed particles contribute to particle statistics (density, ...)
void setDoIgnoreFixedParticles(bool new_)
void setPositions()
Set position of StatisticsPoint points and set variables to 0.
Implementation of a 3D matrix.
Definition: Matrix.h:36
void setCGWidth_over_rmax(Mdouble new_)
Implementation of a 3D vector (by Vitaliy).
Definition: Vector.h:45
Mdouble getTimeStep() const
Allows the time step dt to be accessed.
Definition: DPMBase.cc:465
int StressTypeForFixedParticles
Stress type for fixed particles.
Mdouble P1_P2_Potential
not yet working
Mdouble evaluateIntegral(Mdouble n1, Mdouble n2, Mdouble t)
Mdouble rmax
defines the maximum radius of the particles for which statistics are extracted
Mdouble getTime() const
Access function for the time.
Definition: DPMBase.cc:169
void set_rmin(Mdouble new_)
Implementation of a 3D symmetric matrix.
Mdouble getTimeMax() const
Allows the user to access the total simulation time during the simulation. Cannot change it though...
Definition: DPMBase.cc:214
Mdouble tMaxStat
Statistical output will only be created if t
void setCGTimeAveragingInterval(Mdouble t)
std::string print_CG()
Output coarse graining variables.
void setXMaxStat(Mdouble xMaxStat_)
void setDoTimeAverage(bool new_)
virtual void reset_statistics()
Set all statistical variables to zero.
Matrix3D P1_P2_TangentialStress
Contact stress from tangential forces along the line of contact.
bool doGradient
Determines if gradient is outputted.
Vec3D P1_P2_NormalTraction
Traction from normal forces at contact of flow with fixed particles or walls.
void gather_force_statistics_from_p3c(int version)
int nxMirrored
extension of grid size from mirrored points