richards_evolutive_time.hpp 1004 B

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. #ifndef RICHARDS_EVOLUTIVE_TIME_HPP
  2. #define RICHARDS_EVOLUTIVE_TIME_HPP
  3. #include "geometry.hpp"
  4. #include "richards.hpp"
  5. namespace Kernel{
  6. class RichardsEvolutiveTime{
  7. private:
  8. static constexpr size_t max_Richards_time_subdivisions=256;
  9. size_t ix;
  10. size_t nZ;
  11. double* Z;
  12. double dX;
  13. double flux_bot;
  14. double* div_w;
  15. double* pumps;
  16. void compute_flux_bot();
  17. void compute_div_w();
  18. Richards richards;
  19. public:
  20. //Input
  21. double dt;
  22. double* init_P;
  23. double* previous_P; //relatively to k
  24. double hydr_left;
  25. double l_left;
  26. double Pl_left;
  27. double hydr_middle;
  28. double l_middle;
  29. double Pl_middle;
  30. double hydr_right;
  31. double l_right;
  32. double Pl_right;
  33. //Output
  34. double* P;
  35. double hsat;
  36. bool has_converged;
  37. RichardsEvolutiveTime();
  38. void init(size_t ix,const Geometry* geometry,double* pumps);
  39. void run();
  40. };
  41. inline
  42. RichardsEvolutiveTime::RichardsEvolutiveTime(){
  43. }
  44. }
  45. #endif