Droplet Lagrangian Transient One-dimensional Reacting Code Implementation of both liquid and gas phase governing equations.
Você não pode selecionar mais de 25 tópicos Os tópicos devem começar com uma letra ou um número, podem incluir traços ('-') e podem ter até 35 caracteres.

90 linhas
1.7KB

  1. #include "parse.h"
  2. #ifndef GSL_DEF
  3. #define GSL_DEF
  4. #include <gsl/gsl_math.h>
  5. #include <gsl/gsl_spline.h>
  6. #endif
  7. #ifndef GRID_DEF
  8. #define GRID_DEF
  9. typedef struct gridTag{
  10. size_t basePts;
  11. size_t nPts;
  12. double position;
  13. double leastMove;
  14. double a;
  15. double w;
  16. double mag;
  17. double leftFac;
  18. double rightFac;
  19. int refineLeft;
  20. int refineRight;
  21. double* x;
  22. double* xOld;
  23. } *UserGrid;
  24. inline double l(const double* x,
  25. const double* a,
  26. const double* w,
  27. const double* fac,
  28. const int* refineLeft);
  29. //inline double l(const double* x,
  30. // const double* a,
  31. // const double* c,
  32. // const double* w,
  33. // const double* fac,
  34. // const int* refineLeft);
  35. inline double r(const double* x,
  36. const double* a,
  37. const double* w,
  38. const double* fac,
  39. const int* refineRight);
  40. inline double f(const double* x,
  41. const double* a,
  42. const double* c,
  43. const double* w);
  44. inline double g(const double* x,
  45. const double* a,
  46. const double* c,
  47. const double* w);
  48. inline double rho(const double* x,
  49. const double* a,
  50. const double* c,
  51. const double* w,
  52. const double* mag,
  53. const double* leftFac,
  54. const double* rightFac,
  55. const int* refineLeft,
  56. const int* refineRight);
  57. size_t maxPoints(const size_t basePts,
  58. const double* a,
  59. const double* w,
  60. const double* mag,
  61. const double* leftFac,
  62. const double* rightFac,
  63. const int* refineLeft,
  64. const int* refineRight);
  65. double safePosition(double c, double w);
  66. int reGrid(UserGrid grid, double position);
  67. void storeGrid(const double* x, double *y, const size_t nPts);
  68. int initializeGrid(UserGrid grid);
  69. int getGridSettings(FILE *input, UserGrid grid);
  70. #endif