Cantera  2.1.2
Namespaces | Functions
vcs_util.cpp File Reference

Internal definitions for utility functions for the VCSnonideal package. More...

#include "cantera/equil/vcs_internal.h"
#include <cassert>
Include dependency graph for vcs_util.cpp:

Go to the source code of this file.

Namespaces

 VCSnonideal
 Contains classes and functions implementing the VCS multi-phase equilibrium solver.
 

Functions

void vcs_dzero (double *vector, int length)
 
void vcs_izero (int *vector, int length)
 
void vcs_dcopy (double *const vec_to, const double *const vec_from, int length)
 
void vcs_icopy (int *vec_to, int *vec_from, int length)
 
void vcs_vdzero (std::vector< double > &vvv, int len)
 
double vcs_l2norm (const std::vector< double > vec)
 determine the l2 norm of a vector of doubles More...
 
void vcs_vizero (std::vector< int > &vvv, int len)
 
void vcs_vdcopy (std::vector< double > &vec_to, const std::vector< double > &vec_from, int length)
 
void vcs_vicopy (std::vector< int > &vec_to, const std::vector< int > &vec_from, const int length)
 Copy one std integer vector into another. More...
 
size_t vcs_optMax (const double *x, const double *xSize, size_t j, size_t n)
 Finds the location of the maximum component in a double vector. More...
 
int vcs_max_int (const int *vector, int length)
 Returns the maximum integer in a list. More...
 
static void vcsUtil_swapRows (double *c, size_t idem, size_t n, double *b, size_t m, size_t irowa, size_t irowb)
 Swap rows in the c matrix and the b rhs matrix. More...
 
static void vcsUtil_mlequ_preprocess (double *c, size_t idem, size_t n, double *b, size_t m)
 Swap rows in the c matrix and the b rhs matrix to lower the condition number of the matrix. More...
 
int vcsUtil_mlequ (double *c, size_t idem, size_t n, double *b, size_t m)
 Invert an n x n matrix and solve m rhs's. More...
 
int vcsUtil_gaussj (double *c, size_t idem, size_t n, double *b, size_t m)
 Invert an n x n matrix and solve m rhs's. More...
 
double vcsUtil_gasConstant (int mu_units)
 Returns the value of the gas constant in the units specified by parameter. More...
 
void vcs_print_line (const char *str, int num)
 Prints a line consisting of multiple occurrences of the same string. More...
 
const char * vcs_speciesType_string (int speciesStatus, int length=100)
 Returns a const char string representing the type of the species given by the first argument. More...
 
void vcs_print_stringTrunc (const char *str, size_t space, int alignment)
 Print a string within a given space limit. More...
 
bool vcs_doubleEqual (double d1, double d2)
 Simple routine to check whether two doubles are equal up to roundoff error. More...
 
void vcs_heapsort (std::vector< int > &x)
 Sorts a vector of ints in place from lowest to the highest values. More...
 
void vcs_orderedUnique (std::vector< int > &xOrderedUnique, const std::vector< int > &x)
 Sorts a vector of ints and eliminates duplicates from the resulting list. More...
 

Detailed Description

Internal definitions for utility functions for the VCSnonideal package.

Definition in file vcs_util.cpp.