DFNgen  2.0
DFN Model Generator
fractureEstimating.cpp File Reference
#include <iostream>
#include <algorithm>
#include "generatingPoints.h"
#include "input.h"
#include "fractureEstimating.h"
#include "insertShape.h"
#include "mathFunctions.h"
#include "domain.h"
Include dependency graph for fractureEstimating.cpp:

Go to the source code of this file.

Functions

void sortRadii (std::vector< Shape > &shapeFam)
 
void generateRadiiLists_nPolyOption (std::vector< Shape > &shapeFamilies, float *famProb, std::mt19937_64 &generator, Distributions &distributions)
 
void printGeneratingFracturesLessThanHWarning (int famIndex, Shape &shapeFam)
 
void addRadiiToLists (float percent, std::vector< Shape > &shapeFamilies, std::mt19937_64 &generator, Distributions &distributions)
 
void addRadii (int amountToAdd, int famIdx, Shape &shapeFam, std::mt19937_64 &generator, Distributions &distributions)
 
void dryRun (std::vector< Shape > &shapeFamilies, float *shapeProb, std::mt19937_64 &generator, Distributions &distributions)
 

Function Documentation

§ addRadii()

void addRadii ( int  amountToAdd,
int  famIdx,
Shape shapeFam,
std::mt19937_64 &  generator,
Distributions distributions 
)

Adds 'amountToAdd' more radii to 'shapeFam's radii list Arg 1: Number of fractures to add to the list Arg 2: Family index to the global Shape structure array ('shapeFamilies' in main()) which the radii are being added to Arg 3: The 'Shape' structure which the radii are being added to Arg 4: Random number generator (see std <random> library) Arg 5: Distributions class (currently only used for exponential dist)

Definition at line 100 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

§ addRadiiToLists()

void addRadiiToLists ( float  percent,
std::vector< Shape > &  shapeFamilies,
std::mt19937_64 &  generator,
Distributions distributions 
)

Function adds a percentage more radii to the fracture families radii lists based on each families distribution. This helps account for fracture rejections Arg 1: Percentage to increase the list by. eg .10 will add %10 more radii Arg 2: vector<Shape> array of stochastic fracture families Arg 3: Random number generator (see std <random> library) Arg 4: Distributions class (currently only used for exponential dist)

Definition at line 82 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

§ dryRun()

void dryRun ( std::vector< Shape > &  shapeFamilies,
float *  shapeProb,
std::mt19937_64 &  generator,
Distributions distributions 
)

Inserts fractures into domain with FRAM disabled Simply inserts and truncates fractures on the domain until reqired P32 is met. Used to estimate and generate radii lists for each fracture family. Arg 1: vector<Shape> array of stochastic fracture families Arg 2: The probabilities for each families insertion into domain (famProb) in input file Arg 3: Random number generator (see std <random> library) Arg 4: Distributions class (currently only used for exponential dist)

Definition at line 174 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

§ generateRadiiLists_nPolyOption()

void generateRadiiLists_nPolyOption ( std::vector< Shape > &  shapeFamilies,
float *  famProb,
std::mt19937_64 &  generator,
Distributions distributions 
)

Estimates the number of fractures needed for each family and creates radii lists for each family based on their distribution. Arg 1: vector<Shape> array of stochastic fracture families Arg 2: Family probablity array ('famProb' in input file) Arg 3: Random number generator, see std <random> library Arg 4: Reference to Distributions class (used for exponential distribution)

Definition at line 31 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

§ printGeneratingFracturesLessThanHWarning()

void printGeneratingFracturesLessThanHWarning ( int  famIndex,
Shape shapeFam 
)

This function prints a warning to the user when the random generation of fracture radii lenths is continuously smaller than the minimum defined radii allowed (defined by user in the input file) Arg 1: Index to the family in vecotr<Shape> array the warning is refering to Arg 2: Shape structure the warning is refering to

Definition at line 64 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function:

§ sortRadii()

void sortRadii ( std::vector< Shape > &  shapeFam)

Uses std::sort to sort each family's radii list from largest to smallest. This will allow the DFN gereration to start from largest to smallest fractures. Arg 1: vector<Shape> array of stochastic fracture families

Definition at line 16 of file fractureEstimating.cpp.

Here is the call graph for this function:
Here is the caller graph for this function: