Dear Dennis & Kilian,
 Thank you for reply. You are right, it's better to implement  OOIP in .cc
or problem file.

Regards,
Ranjeet






On Fri, Nov 9, 2018 at 10:00 PM <[email protected]>
wrote:

> Send Dumux mailing list submissions to
>         [email protected]
>
> To subscribe or unsubscribe via the World Wide Web, visit
>         https://listserv.uni-stuttgart.de/mailman/listinfo/dumux
> or, via email, send a message with subject or body 'help' to
>         [email protected]
>
> You can reach the person managing the list at
>         [email protected]
>
> When replying, please edit your Subject line so it is more specific
> than "Re: Contents of Dumux digest..."
>
>
> Today's Topics:
>
>    1. Re: Calculation of Original Oil in Place(OOIP) (Gl?ser)
>    2. Re: Calculation of Original Oil in Place(OOIP) (Weishaupt, Kilian)
>
>
> ----------------------------------------------------------------------
>
> Message: 1
> Date: Thu, 8 Nov 2018 17:16:09 +0000
> From: Gl?ser, Dennis <[email protected]>
> To: "[email protected]"
>         <[email protected]>,      "[email protected]"
>         <[email protected]>
> Subject: Re: [DuMuX] Calculation of Original Oil in Place(OOIP)
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset="iso-8859-1"
>
> Hi Ranjeet,
>
>
> you better obtain the element index using the mapper provided in the
> FvGridGeometry, i.e.:
>
>
> const auto eIdx = this->fvGridGeometry().elementMapper().index(element)
>
>
> then it also works for grids that have several geometry types. Does your
> code compile and run? It looks okay as long as your porosity field
> (porosity_) is a container of the size of number of elements with all
> values initialized properly.
>
>
> Also, this only works if your initial water saturation is 0.4 in the
> entire domain (as you hard-coded this into you constructor). I furthermore
> wonder why you do this in the spatial parameters, I would rather do it in
> the problem where you have access to the spatial parameters (and thus the
> porosity) as well as the initial saturation values. This way you can
> compute this depending on your choice for the initial saturations.
>
>
> Best wishes,
> Dennis
>
>
> ________________________________
> Von: Dumux <[email protected]> im Auftrag von
> Ranjeet kumar <[email protected]>
> Gesendet: Donnerstag, 8. November 2018 07:54:15
> An: [email protected]
> Betreff: [DuMuX] Calculation of Original Oil in Place(OOIP)
>
> Hi all,
> I want to calculate original oil in place for 2p problem where
> OOIP = 10^4 * element.volume()*phi*(1-Sw)/Bo.
>
> I have implemented as follow in the constructor of spatialparams.hh file:
>
>         Sw_ = 0.4;
>         for (const auto& element : elements(gridView)) {
>             auto geo = element.geometry();
>             //get cell index
>              int eIdx = gridView.indexSet().index(element);
>             OOIP_ += geo.volume()*porosity_[eIdx] *(1-Sw);  //assumed Bo =
> 1;
>         }
>         OOIP_ = OOIP_*10000;
>         std::cout << "OOIP =" << OOIP_ << " m^3." << std::endl;
> Is this correct?
>
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> http://listserv.uni-stuttgart.de/pipermail/dumux/attachments/20181108/735ba36a/attachment-0001.html
> >
>
> ------------------------------
>
> Message: 2
> Date: Fri, 9 Nov 2018 07:09:49 +0000
> From: "Weishaupt, Kilian" <[email protected]>
> To: "[email protected]"
>         <[email protected]>
> Subject: Re: [DuMuX] Calculation of Original Oil in Place(OOIP)
> Message-ID: <[email protected]>
> Content-Type: text/plain; charset="us-ascii"
>
> Hi Ranjeet,
>
>
> this seems to be correct to me.
>
>
> You could slightly change your loop so that it also works for a
> non-constant saturation or at any given time, assuming
> FluidSystem::phase1Idx refers to your oil phase. However, this should then
> be rather done in your main (.cc) file, where you have access to your
> gridVariables.
>
>
>         for (const auto& element : elements(fvGridGeometry.gridView()))
>
>         {
>             auto fvGeometry = localView(fvGridGeometry);
>             fvGeometry.bindElement(element);
>
>             auto elemVolVars = localView(gridVariables.curGridVolVars());
>             elemVolVars.bindElement(element, fvGeometry, curSol);
>
>             for (auto&& scv : scvs(fvGeometry))
>             {
>                 const auto& volVars = elemVolVars[scv];
>                 OOIP +=  volVars.saturation(FluidSystem::phase1Idx) *
> volVars.porosity() * volVars.extrusionFactor();
>             }
>         }
>         OOIP *= 1e4;
>
> Best regards
> Kilian
>
>
>
>
>
> ________________________________
> Von: Dumux <[email protected]> im Auftrag von
> Ranjeet kumar <[email protected]>
> Gesendet: Donnerstag, 8. November 2018 07:54:15
> An: [email protected]
> Betreff: [DuMuX] Calculation of Original Oil in Place(OOIP)
>
> Hi all,
> I want to calculate original oil in place for 2p problem where
> OOIP = 10^4 * element.volume()*phi*(1-Sw)/Bo.
>
> I have implemented as follow in the constructor of spatialparams.hh file:
>
>         Sw_ = 0.4;
>         for (const auto& element : elements(gridView)) {
>             auto geo = element.geometry();
>             //get cell index
>              int eIdx = gridView.indexSet().index(element);
>             OOIP_ += geo.volume()*porosity_[eIdx] *(1-Sw);  //assumed Bo =
> 1;
>         }
>         OOIP_ = OOIP_*10000;
>         std::cout << "OOIP =" << OOIP_ << " m^3." << std::endl;
> Is this correct?
>
>
> -------------- next part --------------
> An HTML attachment was scrubbed...
> URL: <
> http://listserv.uni-stuttgart.de/pipermail/dumux/attachments/20181109/4c53f0a5/attachment-0001.html
> >
>
> ------------------------------
>
> Subject: Digest Footer
>
> _______________________________________________
> Dumux mailing list
> [email protected]
> https://listserv.uni-stuttgart.de/mailman/listinfo/dumux
>
>
> ------------------------------
>
> End of Dumux Digest, Vol 93, Issue 8
> ************************************
>
_______________________________________________
Dumux mailing list
[email protected]
https://listserv.uni-stuttgart.de/mailman/listinfo/dumux

Reply via email to