00001
00009 #ifndef WELL_EVENTS_H_
00010 #define WELL_EVENTS_H_
00011
00012 #include "event_base.h"
00013 #include "well_event_params_decl.h"
00014
00015 namespace blue_sky
00016 {
00017
00018 template <typename strategy_t>
00019 class well;
00020
00021 template <typename strategy_t>
00022 class reservoir;
00023
00024 template <typename strategy_t>
00025 class calc_model;
00026
00027 namespace wells
00028 {
00029 template <typename strategy_t>
00030 class connection;
00031
00032 template <typename strategy_t>
00033 class well_controller;
00034
00035 class well_limit_operation;
00036 }
00037
00042 template <typename strategy_t>
00043 class BS_API_PLUGIN well_event : public event_base<strategy_t>
00044 {
00045 public:
00046
00047 typedef reservoir <strategy_t> reservoir_t;
00048
00049 typedef well <strategy_t> well_t;
00050 typedef wells::connection <strategy_t> connection_t;
00051 typedef wells::well_controller <strategy_t> well_controller_t;
00052 typedef wells::well_limit_operation well_limit_operation_t;
00053 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00054 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00055 typedef calc_model <strategy_t> calc_model_t;
00056
00057 typedef smart_ptr <well_t, true> sp_well_t;
00058 typedef smart_ptr <connection_t, true> sp_connection_t;
00059 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00060 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00061 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00062 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00063 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00064
00065 typedef smart_ptr <reservoir_t, true> sp_top;
00066 public:
00067
00069 virtual ~well_event () {}
00070
00077 virtual void
00078 apply (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00079
00084 virtual std::string
00085 get_well_name () const;
00086
00091 virtual std::string
00092 get_group_name () const;
00093
00098 virtual std::string
00099 get_event_name () const;
00100
00101 protected:
00108 virtual void
00109 apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00110
00111 };
00112
00113
00122 template <typename strategy_t>
00123 class BS_API_PLUGIN WELSPECS_event: public well_event<strategy_t>
00124 {
00125 public:
00126 typedef reservoir <strategy_t> reservoir_t;
00127
00128 typedef well <strategy_t> well_t;
00129 typedef wells::connection <strategy_t> connection_t;
00130 typedef wells::well_controller <strategy_t> well_controller_t;
00131 typedef wells::well_limit_operation well_limit_operation_t;
00132 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00133 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00134 typedef calc_model <strategy_t> calc_model_t;
00135
00136 typedef smart_ptr <well_t, true> sp_well_t;
00137 typedef smart_ptr <connection_t, true> sp_connection_t;
00138 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00139 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00140 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00141 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00142 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00143
00144 typedef smart_ptr <reservoir_t, true> sp_top;
00145 BLUE_SKY_TYPE_DECL(WELSPECS_event);
00146 public:
00147
00148 MAIN_PARAMS (
00149 ((WELL_NAME, "Well name", PT_STR))
00150 ((WELL_GROUP_NAME, "Name of the group to which the well belongs", PT_STR))
00151 ((I, "I - location of well head or heel", PT_INT))
00152 ((J, "J - location of well head or heel", PT_INT))
00153 ((BHP_DEPTH, "", PT_FLOAT))
00154 );
00155
00156
00157
00158
00159
00160
00161
00162
00163
00165 virtual ~WELSPECS_event () {}
00166
00167 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00168
00169 protected:
00170 virtual std::string get_well_name () const;
00171 virtual std::string get_event_name () const;
00172 };
00173
00174
00175
00184 template <typename strategy_t>
00185 class BS_API_PLUGIN WELLCON_event: public well_event<strategy_t>
00186 {
00187 public:
00188 typedef reservoir <strategy_t> reservoir_t;
00189
00190 typedef well <strategy_t> well_t;
00191 typedef wells::connection <strategy_t> connection_t;
00192 typedef wells::well_controller <strategy_t> well_controller_t;
00193 typedef wells::well_limit_operation well_limit_operation_t;
00194 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00195 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00196 typedef calc_model <strategy_t> calc_model_t;
00197
00198 typedef smart_ptr <well_t, true> sp_well_t;
00199 typedef smart_ptr <connection_t, true> sp_connection_t;
00200 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00201 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00202 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00203 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00204 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00205
00206 typedef smart_ptr <reservoir_t, true> sp_top;
00207 BLUE_SKY_TYPE_DECL(WELLCON_event);
00208 public:
00209
00210 MAIN_PARAMS (
00211 ((WELL_NAME, "Well name", PT_STR))
00212 ((WELL_GROUP_NAME, "Name of the group to which the well belongs", PT_STR))
00213 ((I, "I - location of well head or heel", PT_INT))
00214 ((J, "J - location of well head or heel", PT_INT))
00215 ((FIRST_LAYER, "First layer", PT_INT))
00216 ((LAST_LAYER, "Last layer", PT_INT))
00217 ((WELL_STATE, "Open/shut flag for the well", PT_STR))
00218 ((WELL_DIAMETER, "Well bore diameter at the connection", PT_FLOAT))
00219 ((SKIN, "Skin factor", PT_FLOAT))
00220 ((KH, "Effective Kh (permeability x thickness) value of the connection", PT_FLOAT))
00221 ((DIRECTION, "Direction in which the well penetrates the grid block", PT_STR))
00222 );
00223
00225 virtual ~WELLCON_event () {}
00226
00227 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00228
00229 protected:
00230 virtual std::string get_well_name () const;
00231 virtual std::string get_event_name () const;
00232 };
00233
00234
00242 template <typename strategy_t>
00243 class BS_API_PLUGIN COMPDAT_event: public well_event<strategy_t>
00244 {
00245 public:
00246 typedef reservoir <strategy_t> reservoir_t;
00247
00248 typedef typename strategy_t::index_t index_t;
00249 typedef typename strategy_t::item_t item_t;
00250
00251 typedef well <strategy_t> well_t;
00252 typedef wells::connection <strategy_t> connection_t;
00253 typedef wells::well_controller <strategy_t> well_controller_t;
00254 typedef wells::well_limit_operation well_limit_operation_t;
00255 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00256 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00257 typedef calc_model <strategy_t> calc_model_t;
00258
00259 typedef smart_ptr <well_t, true> sp_well_t;
00260 typedef smart_ptr <connection_t, true> sp_connection_t;
00261 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00262 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00263 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00264 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00265 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00266
00267 typedef smart_ptr <reservoir_t, true> sp_top;
00268 BLUE_SKY_TYPE_DECL(COMPDAT_event);
00269 public:
00270 MAIN_PARAMS (
00271 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00272 ((I, "I - location of well head or heel", PT_INT))
00273 ((J, "J - location of well head or heel", PT_INT))
00274 ((FIRST_LAYER, "K - location of upper connecting block in this set of data", PT_INT))
00275 ((LAST_LAYER, "K - location of lower connecting block in this set of data", PT_INT))
00276 ((PERFORATION_STATUS, "Open/shut flag for the well", PT_STR))
00277 ((PARAM7, "Well bore diameter at the connection", PT_INT))
00278 ((PERFORATION_FACTOR, "Transmissibility factor for the connection", PT_FLOAT))
00279 ((WELL_DIAMETER, "Well bore diameter at the connection", PT_FLOAT))
00280 ((KH, "Effective Kh (permeability x thickness) value of the connection", PT_FLOAT))
00281 ((SKIN, "Skin factor", PT_FLOAT))
00282 ((PARAM12, "", PT_STR))
00283 ((DIRECTION, "Direction in which the well penetrates the grid block", PT_STR))
00284 ((PARAM13, "", PT_STR))
00285 ((SEG_NUMBER, "Segment which contains this perforation", PT_INT))
00286 );
00287
00289 virtual ~COMPDAT_event () {}
00290 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00291
00292 protected:
00293 virtual std::string get_well_name () const;
00294 virtual std::string get_event_name () const;
00295 };
00296
00297
00298
00304 template <typename strategy_t>
00305 class BS_API_PLUGIN WCONPROD_event: public well_event<strategy_t>
00306 {
00307 public:
00308 typedef reservoir <strategy_t> reservoir_t;
00309
00310 typedef well <strategy_t> well_t;
00311 typedef wells::connection <strategy_t> connection_t;
00312 typedef wells::well_controller <strategy_t> well_controller_t;
00313 typedef wells::well_limit_operation well_limit_operation_t;
00314 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00315 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00316 typedef calc_model <strategy_t> calc_model_t;
00317
00318 typedef smart_ptr <well_t, true> sp_well_t;
00319 typedef smart_ptr <connection_t, true> sp_connection_t;
00320 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00321 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00322 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00323 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00324 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00325
00326 typedef smart_ptr <reservoir_t, true> sp_top;
00327 BLUE_SKY_TYPE_DECL(WCONPROD_event);
00328 public:
00329 MAIN_PARAMS (
00330 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00331 ((WELL_STATE, "Open/shut flag for the well", PT_STR))
00332 ((WELL_CONTROL_MODE, "Control mode", PT_STR))
00333 ((OIL_RATE, "Oil rate target or upper limit", PT_FLOAT))
00334 ((WATER_RATE, "Water rate target or upper limit", PT_FLOAT))
00335 ((GAS_RATE, "Gas rate target or upper limit", PT_FLOAT))
00336 ((OUTER_RATE, "Liquid rate target or upper limit", PT_FLOAT))
00337 ((INNER_RATE, "Reservoir fluid volume rate target or upper limit", PT_FLOAT))
00338 ((BHP, "BHP target or lower limit", PT_FLOAT))
00339 );
00340
00342 virtual ~WCONPROD_event () {}
00343 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00344
00345 protected:
00346 virtual std::string get_well_name () const;
00347 virtual std::string get_event_name () const;
00348 };
00349
00350
00351
00352
00364 template <typename strategy_t>
00365 class BS_API_PLUGIN WCONHIST_event: public well_event<strategy_t>
00366 {
00367 public:
00368 typedef reservoir <strategy_t> reservoir_t;
00369
00370 typedef well <strategy_t> well_t;
00371 typedef wells::connection <strategy_t> connection_t;
00372 typedef wells::well_controller <strategy_t> well_controller_t;
00373 typedef wells::well_limit_operation well_limit_operation_t;
00374 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00375 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00376 typedef calc_model <strategy_t> calc_model_t;
00377
00378 typedef smart_ptr <well_t, true> sp_well_t;
00379 typedef smart_ptr <connection_t, true> sp_connection_t;
00380 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00381 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00382 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00383 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00384 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00385
00386 typedef smart_ptr <reservoir_t, true> sp_top;
00387 BLUE_SKY_TYPE_DECL(WCONHIST_event);
00388 public:
00389
00390
00391 MAIN_PARAMS (
00392 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00393 ((WELL_STATE, "Open/shut flag for the well", PT_STR))
00394 ((WELL_CONTROL_MODE, "Control mode", PT_STR))
00395 ((OIL_RATE, "Observed oil production rate", PT_FLOAT))
00396 ((WATER_RATE, "Observed water production rate", PT_FLOAT))
00397 ((GAS_RATE, "Observed gas production rate", PT_FLOAT))
00398 ((PARAM7, "", PT_STR))
00399 ((PARAM8, "", PT_STR))
00400 ((PARAM9, "", PT_STR))
00401 ((BHP, "Observed bottom hole pressure (BHP)", PT_FLOAT))
00402 );
00403
00405 virtual ~WCONHIST_event () {}
00406 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00407
00408 protected:
00409 virtual std::string get_well_name () const;
00410 virtual std::string get_event_name () const;
00411 };
00412
00413
00414
00415
00423 template <typename strategy_t>
00424 class BS_API_PLUGIN WCONINJE_event: public well_event<strategy_t>
00425 {
00426 public:
00427 typedef reservoir <strategy_t> reservoir_t;
00428
00429 typedef well <strategy_t> well_t;
00430 typedef wells::connection <strategy_t> connection_t;
00431 typedef wells::well_controller <strategy_t> well_controller_t;
00432 typedef wells::well_limit_operation well_limit_operation_t;
00433 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00434 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00435 typedef calc_model <strategy_t> calc_model_t;
00436
00437 typedef smart_ptr <well_t, true> sp_well_t;
00438 typedef smart_ptr <connection_t, true> sp_connection_t;
00439 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00440 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00441 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00442 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00443 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00444
00445 typedef smart_ptr <reservoir_t, true> sp_top;
00446 BLUE_SKY_TYPE_DECL(WCONINJE_event);
00447 public:
00448
00449
00450 MAIN_PARAMS (
00451 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00452 ((INJECTOR_TYPE, "Injector type", PT_STR))
00453 ((WELL_STATE, "Open/shut flag for the well", PT_STR))
00454 ((WELL_CONTROL_MODE, "Control mode", PT_STR))
00455 ((OUTER_RATE, "Surface flow rate target or upper limit", PT_FLOAT))
00456 ((INNER_RATE, "Reservoir fluid volume rate target or upper limit", PT_FLOAT))
00457 ((BHP, "BHP target or lower limit", PT_FLOAT))
00458 ((PARAM1, "dummy for bug", PT_STR))
00459 );
00460
00462 virtual ~WCONINJE_event () {}
00463 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00464
00465
00466
00467 protected:
00468 virtual std::string get_well_name () const;
00469 virtual std::string get_event_name () const;
00470 };
00471
00472
00473
00479 template <typename strategy_t>
00480 class BS_API_PLUGIN WECON_event: public well_event<strategy_t>
00481 {
00482 public:
00483 typedef reservoir <strategy_t> reservoir_t;
00484
00485 typedef well <strategy_t> well_t;
00486 typedef wells::connection <strategy_t> connection_t;
00487 typedef wells::well_controller <strategy_t> well_controller_t;
00488 typedef wells::well_limit_operation well_limit_operation_t;
00489 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00490 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00491 typedef calc_model <strategy_t> calc_model_t;
00492
00493 typedef smart_ptr <well_t, true> sp_well_t;
00494 typedef smart_ptr <connection_t, true> sp_connection_t;
00495 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00496 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00497 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00498 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00499 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00500
00501 typedef smart_ptr <reservoir_t, true> sp_top;
00502 BLUE_SKY_TYPE_DECL(WECON_event);
00503 public:
00504
00505
00506 MAIN_PARAMS (
00507 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00508 ((MIN_OIL_RATE, "Minimum oil production rate", PT_FLOAT))
00509 ((WATER_CUT, "Maximum water cut", PT_FLOAT))
00510 ((OPERATION, "Workover procedure on exceeding limit", PT_STR))
00511 );
00512
00514 virtual ~WECON_event () {}
00515 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00516
00517 protected:
00518 virtual std::string get_well_name () const;
00519 virtual std::string get_event_name () const;
00520 };
00521
00522
00523
00529 template <typename strategy_t>
00530 class BS_API_PLUGIN WECONINJ_event: public well_event<strategy_t>
00531 {
00532 public:
00533 typedef reservoir <strategy_t> reservoir_t;
00534
00535 typedef well <strategy_t> well_t;
00536 typedef wells::connection <strategy_t> connection_t;
00537 typedef wells::well_controller <strategy_t> well_controller_t;
00538 typedef wells::well_limit_operation well_limit_operation_t;
00539 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00540 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00541 typedef calc_model <strategy_t> calc_model_t;
00542
00543 typedef smart_ptr <well_t, true> sp_well_t;
00544 typedef smart_ptr <connection_t, true> sp_connection_t;
00545 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00546 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00547 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00548 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00549 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00550
00551 typedef smart_ptr <reservoir_t, true> sp_top;
00552 BLUE_SKY_TYPE_DECL(WECONINJ_event);
00553 public:
00554
00555
00556 MAIN_PARAMS (
00557 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00558 ((MIN_RATE, "Minimum economic water injection rate", PT_FLOAT))
00559 );
00560
00562 virtual ~WECONINJ_event () {}
00563 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00564
00565 protected:
00566 virtual std::string get_well_name () const;
00567 virtual std::string get_event_name () const;
00568 };
00569
00570
00571
00577 template <typename strategy_t>
00578 class BS_API_PLUGIN WEFAC_event: public well_event<strategy_t>
00579 {
00580 public:
00581 typedef reservoir <strategy_t> reservoir_t;
00582
00583 typedef well <strategy_t> well_t;
00584 typedef wells::connection <strategy_t> connection_t;
00585 typedef wells::well_controller <strategy_t> well_controller_t;
00586 typedef wells::well_limit_operation well_limit_operation_t;
00587 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00588 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00589 typedef calc_model <strategy_t> calc_model_t;
00590
00591 typedef smart_ptr <well_t, true> sp_well_t;
00592 typedef smart_ptr <connection_t, true> sp_connection_t;
00593 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00594 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00595 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00596 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00597 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00598
00599 typedef smart_ptr <reservoir_t, true> sp_top;
00600 BLUE_SKY_TYPE_DECL(WEFAC_event);
00601 public:
00602
00603
00604 MAIN_PARAMS (
00605 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00606 ((OPERATION_FACTOR, "Efficiency factor for the well", PT_FLOAT))
00607 );
00608
00610 virtual ~WEFAC_event () {}
00611 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00612
00613 protected:
00614 virtual std::string get_well_name () const;
00615 virtual std::string get_event_name () const;
00616 };
00617
00618
00619
00635 template <typename strategy_t>
00636 class BS_API_PLUGIN WELTARG_event: public well_event<strategy_t>
00637 {
00638 public:
00639 typedef reservoir <strategy_t> reservoir_t;
00640
00641 typedef well <strategy_t> well_t;
00642 typedef wells::connection <strategy_t> connection_t;
00643 typedef wells::well_controller <strategy_t> well_controller_t;
00644 typedef wells::well_limit_operation well_limit_operation_t;
00645 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00646 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00647 typedef calc_model <strategy_t> calc_model_t;
00648
00649 typedef smart_ptr <well_t, true> sp_well_t;
00650 typedef smart_ptr <connection_t, true> sp_connection_t;
00651 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00652 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00653 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00654 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00655 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00656
00657 typedef smart_ptr <reservoir_t, true> sp_top;
00658 BLUE_SKY_TYPE_DECL(WELTARG_event);
00659 public:
00660
00661
00662 MAIN_PARAMS (
00663 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00664 ((WELL_CONTROL, "Definition of the control or constraint quantity to be changed", PT_STR))
00665 ((VALUE, "New value", PT_FLOAT))
00666 );
00667
00669 virtual ~WELTARG_event () {}
00670 void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00671
00672 protected:
00673 virtual std::string get_well_name () const;
00674 virtual std::string get_event_name () const;
00675 };
00676
00677
00678
00693 template <typename strategy_t>
00694 class BS_API_PLUGIN WPIMULT_event: public well_event<strategy_t>
00695 {
00696 public:
00697 typedef reservoir <strategy_t> reservoir_t;
00698
00699 typedef well <strategy_t> well_t;
00700 typedef wells::connection <strategy_t> connection_t;
00701 typedef wells::well_controller <strategy_t> well_controller_t;
00702 typedef wells::well_limit_operation well_limit_operation_t;
00703 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00704 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00705 typedef calc_model <strategy_t> calc_model_t;
00706
00707 typedef smart_ptr <well_t, true> sp_well_t;
00708 typedef smart_ptr <connection_t, true> sp_connection_t;
00709 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00710 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00711 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00712 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00713 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00714
00715 typedef smart_ptr <reservoir_t, true> sp_top;
00716 BLUE_SKY_TYPE_DECL(WPIMULT_event);
00717 public:
00718
00719
00720 MAIN_PARAMS (
00721 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00722 ((PERM_FACTOR, "Multiplier to act on the well’s connection transmissibility factors and Kh values", PT_FLOAT))
00723 ((I, "I - location of connecting grid block(s)", PT_INT))
00724 ((J, "J - location of connecting grid block(s)", PT_INT))
00725 ((K, "K - location of connecting grid block(s)", PT_INT))
00726 ((Z1, "Number of first completion in range", PT_INT))
00727 ((Z2, "Number of last completion in range", PT_INT))
00728 );
00729
00731 virtual ~WPIMULT_event () {}
00732 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00733
00734 protected:
00735 virtual std::string get_well_name () const;
00736 virtual std::string get_event_name () const;
00737 };
00738
00739
00740
00746 template <typename strategy_t>
00747 class BS_API_PLUGIN COMPENSATION_event: public well_event<strategy_t>
00748 {
00749 public:
00750 typedef reservoir <strategy_t> reservoir_t;
00751
00752 typedef well <strategy_t> well_t;
00753 typedef wells::connection <strategy_t> connection_t;
00754 typedef wells::well_controller <strategy_t> well_controller_t;
00755 typedef wells::well_limit_operation well_limit_operation_t;
00756 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00757 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00758 typedef calc_model <strategy_t> calc_model_t;
00759
00760 typedef smart_ptr <well_t, true> sp_well_t;
00761 typedef smart_ptr <connection_t, true> sp_connection_t;
00762 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00763 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00764 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00765 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00766 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00767
00768 typedef smart_ptr <reservoir_t, true> sp_top;
00769 BLUE_SKY_TYPE_DECL(COMPENSATION_event);
00770 public:
00771
00772
00773 MAIN_PARAMS (
00774 ((WELL_GROUP, "Name of the group to which the well belongs", PT_STR))
00775 ((COMPENSATION_RATE, "Compensation rate", PT_FLOAT))
00776 ((COMPENSATION_TYPE, "Compensation type", PT_STR))
00777 );
00778
00780 virtual ~COMPENSATION_event () {}
00781 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00782
00783 protected:
00784 virtual std::string get_event_name () const;
00785 };
00786
00787
00788
00795 template <typename strategy_t>
00796 class BS_API_PLUGIN FRACTURE_event: public well_event<strategy_t>
00797 {
00798 public:
00799 typedef reservoir <strategy_t> reservoir_t;
00800
00801 typedef well <strategy_t> well_t;
00802 typedef wells::connection <strategy_t> connection_t;
00803 typedef wells::well_controller <strategy_t> well_controller_t;
00804 typedef wells::well_limit_operation well_limit_operation_t;
00805 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00806 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00807 typedef calc_model <strategy_t> calc_model_t;
00808
00809 typedef smart_ptr <well_t, true> sp_well_t;
00810 typedef smart_ptr <connection_t, true> sp_connection_t;
00811 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00812 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00813 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00814 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00815 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00816
00817 typedef smart_ptr <reservoir_t, true> sp_top;
00818 BLUE_SKY_TYPE_DECL(FRACTURE_event);
00819 public:
00820
00821
00822 MAIN_PARAMS (
00823 ((WELL_NAME, "Well name, well name root or well list name", PT_STR))
00824 ((I, "I - location", PT_INT))
00825 ((J, "J - location", PT_INT))
00826 ((KW1, "fracture head location", PT_INT))
00827 ((KW2, "fracture tail location", PT_INT))
00828 ((HALF_LENGHT, "Half of the fracture length", PT_FLOAT))
00829 ((TETTA, "the angle between fracture and positive OX direction", PT_FLOAT))
00830 ((SKIN, "Skin factor", PT_FLOAT))
00831 ((WELL_STATE, "Open/shut flag for the well", PT_STR))
00832 ((PARAM10, "", PT_STR))
00833 ((PARAM11, "", PT_STR))
00834 );
00836 virtual ~FRACTURE_event () {}
00837 virtual void apply_internal (const sp_top &top, const sp_mesh_iface_t &msh, const sp_calc_model_t &calc_model) const;
00838
00839 protected:
00840 virtual std::string get_well_name () const;
00841 virtual std::string get_event_name () const;
00842 };
00843
00844
00845
00852 template <typename strategy_t>
00853 class BS_API_PLUGIN PERMFRAC_event: public well_event<strategy_t>
00854 {
00855 public:
00856 typedef reservoir <strategy_t> reservoir_t;
00857
00858 typedef well <strategy_t> well_t;
00859 typedef wells::connection <strategy_t> connection_t;
00860 typedef wells::well_controller <strategy_t> well_controller_t;
00861 typedef wells::well_limit_operation well_limit_operation_t;
00862 typedef rs_mesh_iface <strategy_t> mesh_iface_t;
00863 typedef rs_smesh_iface <strategy_t> smesh_iface_t;
00864 typedef calc_model <strategy_t> calc_model_t;
00865
00866 typedef smart_ptr <well_t, true> sp_well_t;
00867 typedef smart_ptr <connection_t, true> sp_connection_t;
00868 typedef smart_ptr <mesh_iface_t, true> sp_mesh_iface_t;
00869 typedef smart_ptr <smesh_iface_t, true> sp_smesh_iface_t;
00870 typedef smart_ptr <well_controller_t, true> sp_well_controller_t;
00871 typedef smart_ptr <well_limit_operation_t, true> sp_well_limit_operation_t;
00872 typedef smart_ptr <calc_model_t, true> sp_calc_model_t;
00873
00874 typedef smart_ptr <reservoir_t, true> sp_top;
00875 BLUE_SKY_TYPE_DECL(PERMFRAC_event);
00876 public:
00877
00878
00879 MAIN_PARAMS (
00880 ((I, "I - location", PT_INT))
00881 ((J, "J - location", PT_INT))
00882 ((KW1, "fracture head location", PT_INT))
00883 ((KW2, "fracture tail location", PT_INT))
00884 ((NUM_RIGHT, "Number of cell placed at right side of central fracture cell", PT_INT))
00885 ((NUM_LEFT, "Number of cell placed at left side of central fracture cell", PT_INT))
00886 ((FRAC_PERM, "Fracture permeability", PT_FLOAT))
00887 ((SKIN, "Skin factor", PT_FLOAT))
00888 ((FRACTURE_DIRECTION, "Fracture direction", PT_STR))
00889 ((PARAM10, "", PT_STR))
00890 );
00891
00893 virtual ~PERMFRAC_event () {}
00894
00895 protected:
00896 virtual std::string get_event_name () const;
00897 };
00898
00899 }
00900
00901 #endif//WELL_EVENTS_H_
00902