FlexELA
Loading...
Searching...
No Matches
Functions
ELA_Output.h File Reference

Provides functions to write ELA output to files. More...

#include <ELA.h>

Go to the source code of this file.

Functions

void ELA_Output (const int *labels, const double *f, const double *dV, const int &num, const int &t_num, const double &time, const char *folder, const bool &write_log=true)
 Has the same effect as calling ELA_OutputWriteV(), ELA_OutputWriteVTM(), and (if write_log is true) ELA_OutputLog()
 
void ELA_OutputWriteV (const double *f, const int *labels, const double *dV, const int &t_num, const char *folder)
 Calculate the volume vector ([Gaylo2022], Eq. 8)
 
void ELA_OutputWriteVTM (const int *labels, const double *dV, const int &num, const int &t_num, const double &time, const char *folder)
 Calculate the volume tracking matrix ([Gaylo2022], Eq. 34)
 
void ELA_OutputLog (const double *f, const double *dV, const int &num, const double &time, const char *folder)
 Calculates metrics for monitoring the performance of ELA.
 

Detailed Description

Provides functions to write ELA output to files.

For more information on the formating of these files, see Output Files.

Function Documentation

◆ ELA_Output()

void ELA_Output ( const int *  labels,
const double *  f,
const double *  dV,
const int &  num,
const int &  t_num,
const double &  time,
const char *  folder,
const bool &  write_log = true 
)

Has the same effect as calling ELA_OutputWriteV(), ELA_OutputWriteVTM(), and (if write_log is true) ELA_OutputLog()

See also
Volume Vector, Volume Tracking Matrix, and timelog.bin
Warning
It is assumed the folder exists
Parameters
labelsThe label feild
fThe volume fraction \( f \)
labelsThe label feild
dVCell volume \( \Delta \Omega \)
numThe ELA instance
t_numThe snapshot index \( n \)
timeThe snapshot time \( t^{n} \)
folderThe folder to create the volume vector file in
write_logWhether or not to call ELA_OutputLog()
Note
When calling from Fortran, write_log is an integer and is cast to a boolean with write_log!=0

◆ ELA_OutputLog()

void ELA_OutputLog ( const double *  f,
const double *  dV,
const int &  num,
const double &  time,
const char *  folder 
)

Calculates metrics for monitoring the performance of ELA.

See also
tracking.log
Warning
It is assumed the folder exists
Parameters
fThe volume fraction \( f \)
dVCell volume \( \Delta \Omega \)
numThe ELA instance
timeThe snapshot time \( t^{n} \)
folderThe folder to create the log file in

◆ ELA_OutputWriteV()

void ELA_OutputWriteV ( const double *  f,
const int *  labels,
const double *  dV,
const int &  t_num,
const char *  folder 
)

Calculate the volume vector ([Gaylo2022], Eq. 8)

This function outputs the volume vector \(\mathbf{v}^{n}\), where each element \(v^{n}_l\) is given by

\[ v^n_l = \sum_{\Omega_{ijk} \in \text{blob } l} (1-f_{ijk}) \; \Delta \Omega_{ijk} . \]

for \( l \in 1\dots M^{n} \). Cells belonging to the blob \( l =0 \) are ignored. Which blob \( l \) a cell \(\Omega_{ijk}\) is in is determined by the label feild labels. The number of blobs \( M^{n} \) is determined based on labels provided.

See also
Volume Vector
Warning
It is assumed the folder exists
Parameters
fThe volume fraction \( f \)
labelsThe label feild
dVCell volume \( \Delta \Omega \)
t_numThe snapshot index \( n \)
folderThe folder to create the volume vector file in

◆ ELA_OutputWriteVTM()

void ELA_OutputWriteVTM ( const int *  labels,
const double *  dV,
const int &  num,
const int &  t_num,
const double &  time,
const char *  folder 
)

Calculate the volume tracking matrix ([Gaylo2022], Eq. 34)

This function outputs the volume tracking matrix \(\mathbf{Q}^{(n-1 \,\rightarrow\, n)}\), where each element \( q_{m l} \) is given by

\[ q_{m l} = \sum_{\Omega_{ijk} \in \text{blob } m} \left(s^{n-1}_{l} \right)_{ijk} \; \Delta \Omega_{ijk} \]

for \( m \in 1\dots M^{n} \) and \( l \in 1\dots M^{n-1} \). Cells belonging to the blob \( m =0 \) are ignored. Which blob \( m \) a cell \(\Omega_{ijk}\) is in is determined by the label feild labels. The number of rows in \(\mathbf{Q}^{(n-1 \,\rightarrow\, n)}\), \( M^{n} \), is determined based on labels provided. The number of columns, \( M^{n-1} \), is not explicitly calculated. The source fraction feild \( \mathbf{s}^{n-1}_{ijk} \) is the one currently stored in ELA isntance num.

In addition the volume tracking matrix, this function appends to a log file noting the index \( n \), the row count \( M^{n} \), and the time \( t^{n} \).

Warning
It is assumed the folder exists
See also
Volume Tracking Matrix and timelog.bin
Parameters
labelsThe label feild
dVCell volume \( \Delta \Omega \)
numThe ELA instance
t_numThe snapshot index \( n \)
timeThe snapshot time \( t^{n} \)
folderThe folder to create the volume tracking matrix file in