<commit_before>/* ======================================================================= */
/* -------------------------------------------------- */
/* | RCS Head Information on zuzax.pchem.sandia.gov | */
/* -------------------------------------------------- */
/* $RCSfile$ */
/* $Author$ */
/* $Date$ */
/* $Revision$ */
/* ======================================================================= */


#include "vcs_solve.h"
#include "vcs_internal.h" 
#include "vcs_species_thermo.h"
#include "vcs_VolPhase.h"

#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <vector>

using namespace std;

namespace VCSnonideal {


  // Utility function that evaluates whether a phase can be popped
  // into existence
  /*
   * A phase can be popped iff the stoichiometric coefficients for the
   * component species, whose concentrations will be lowered during the
   * process, are positive by at least a small degree.
   * 
   * @param iphasePop  id of the phase, which is currently zeroed,
   *        
   * @return Returns true if the phase can come into existence
   *         and false otherwise.
   */
  bool VCS_SOLVE::vcs_popPhasePossible(const int iphasePop) const {
    
    vcs_VolPhase *Vphase = m_VolPhaseList[iphasePop];

#ifdef DEBUG_MODE
    int existence = Vphase->exists();
    if (existence > 0) {
      printf("ERROR vcs_popPhasePossible called for a phase that exists!");
      std::exit(-1);
    }
#endif

    /*<commit_msg>Added a header for Ubuntu compatibility<commit_after>/* ======================================================================= */
/* -------------------------------------------------- */
/* | RCS Head Information on zuzax.pchem.sandia.gov | */
/* -------------------------------------------------- */
/* $RCSfile$ */
/* $Author$ */
/* $Date$ */
/* $Revision$ */
/* ======================================================================= */


#include "vcs_solve.h"
#include "vcs_internal.h" 
#include "vcs_species_thermo.h"
#include "vcs_VolPhase.h"

#include <cstdio>
#include <cstdlib>
#include <cmath>
#include <vector>
#include <cstring>

using namespace std;

namespace VCSnonideal {


  // Utility function that evaluates whether a phase can be popped
  // into existence
  /*
   * A phase can be popped iff the stoichiometric coefficients for the
   * component species, whose concentrations will be lowered during the
   * process, are positive by at least a small degree.
   * 
   * @param iphasePop  id of the phase, which is currently zeroed,
   *        
   * @return Returns true if the phase can come into existence
   *         and false otherwise.
   */
  bool VCS_SOLVE::vcs_popPhasePossible(const int iphasePop) const {
    
    vcs_VolPhase *Vphase = m_VolPhaseList[iphasePop];

#ifdef DEBUG_MODE
    int existence = Vphase->exists();
    if (existence > 0) {
      printf("ERROR vcs_popPhasePossible called for a phase that exists!");
      std::exit(-1);
    }
#endif

    /*
{'fraction_non_alphanumeric': 0.2621227534757545, 'fraction_numerical': 0.0013563919972872161, 'mean_word_length': 2.660049627791563, 'pattern_counts': {'":': 0, '<': 12, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3856088', 'n_tokens_mistral': 862, 'n_tokens_neox': 798, 'n_words': 249}