/************************************************************** * HEADER FILE: simple.h - header file for simple simulation * * PROGRAMMER: Eric Malroy * * LAST MODIFICATION: 08/21/96 Eric Malroy * * DATE: 06/15/96 * *************************************************************/ #ifndef SIM #define SIM /* functions invoked by "simple.c" */ /* hotsim: heater simple analysis */ void hotsim(double var[][COL], /* variable matrix */ double twh, /* heater wall temperature */ double *pt_tgh); /* heater average gas temp. */ /* kolsim: cooler simple analysis */ void kolsim(double var[][COL], /* variable matrix */ double twk, /* kooler wall temperature */ double *pt_tgk); /* kooler average gas temp. */ /* resgim: regenerator simple analysis */ void regsim(double var[][COL], /* variable matrix */ double *qrloss); /* regen net enthalpy loss (Watts) */ /* wrksim: pressure drop, work simple analyis */ void wrksim(double var[][COL], /* variable matrix */ double dvar[][COL], /* derivative matrix */ double *pt_dwork); /* pressure drop work loss */ /* Appendix gas losses */ void aploss(double var[][], /* Variable matrix */ double shutls, /* Shuttle loss */ double enthls, /* Enthalpy loss */ double sealls); /* Seal loss */ /* functions invoked by "regsim.c" */ void reynum(double t, /* absolute temperature (K) */ double g, /* mass flux (kg/(m^2*s)) */ double d, /* hydraulic diameter (m) */ double *pt_mu, /* dynamic viscosity (kg/(m*s)) */ double *pt_kgas, /* gas thermal conductivity (W/m^2*K) */ double *pt_re); /* Reynolds number abs(g)*d/mu */ void matfr(double re, /* Reynolds number */ double *pt_st, /* Stanton number */ double *pt_fr); /* Reynolds friction factor Ff*re */ /* Ff is the fanning friction factor */ void foilfr(double d, /* hydraulic diameter (m) */ double mu, /* dynamic viscosity (kg/(m*s)) */ double re, /* Reynolds number for foil */ double *pt_st, /* Stanton number */ double *pt_ht, /* heat transfer coefficient */ double *pt_fr); /* Reynolds friction factor Ff*re */ /* Ff is the fanning friction factor */ void minmax(double y[], /* array to find the min and max */ int n, /* number of elements in array */ double *pt_ymin, /* minimum value of array */ double *pt_ymax); /* maximum value of array */ /* function invoked by "kolsim.c", "hotsim.c" & "wrksim.c" */ void pipfr(double d, /* hydraulic diameter (m) */ double mu, /* dynamic viscosity (kg/(m*s)) */ double re, /* Reynolds number fabs(g)*d/mu */ double *pt_ht, /* heat transfer coefficient (W/(m^2*K)) */ double *pt_fr); /* Reynolds friction factor (Ff*re) */ /* Ff is the Fanning friction factor */ /* "kolsim", "hotsim" & "wrksim" also invoke function "reynum()" */ /* "wrksim" additionally invokes the function "matfr" */ #endif