{"id":780,"date":"2016-12-06T14:02:29","date_gmt":"2016-12-06T14:02:29","guid":{"rendered":"http:\/\/opm-project.org\/?page_id=780"},"modified":"2018-10-31T14:02:57","modified_gmt":"2018-10-31T14:02:57","slug":"running-the-norne-case-with-flow","status":"publish","type":"page","link":"https:\/\/opm-project.org\/?page_id=780","title":{"rendered":"Running the Norne case with Flow"},"content":{"rendered":"<p>This tutorial will guide you through running and visualizing the Norne case, which is an open benchmark case of a real Norwegian Sea oilfield. It will also demonstrate how to run Flow in parallel, take a look at some available run-time parameters, and discuss the logging facilities of Flow.<\/p>\n<p>The tutorial assumes that you have already <a href=\"\/\/opm-project.org\/?page_id=36\">built or installed<\/a> OPM and Flow in particular, and have run through the <a href=\"\/\/opm-project.org\/?page_id=197\">first tutorial<\/a>.<\/p>\n<p>To follow the visualization parts, you must have <a href=\"\/\/opm-project.org\/?page_id=117\">ResInsight<\/a> installed.<\/p>\n<p><!--nextpage--><\/p>\n<h3>Running the Norne case<\/h3>\n<p>After the first tutorial, you should have a copy of the latest master branch of the opm-data repository. If you followed <a href=\"https:\/\/opm-project.org\/?page_id=197&amp;page=3\">the instructions in that tutorial<\/a> it will be named &#8220;opm-data-master&#8221;. Go to the Norne case by entering its directory:<\/p>\n<pre>cd opm-data-master\/norne\r\n<\/pre>\n<p>From here you could start a Norne run immediately by entering the following command:<\/p>\n<pre>flow NORNE_ATW2013.DATA --output-dir=out_serial\r\n<\/pre>\n<p>Note that there should be no spaces between the parameter key (&#8220;output_dir&#8221;) and the associated value. It is quite possible to leave out the &#8220;output_dir&#8221; parameter, that way all your output files will end up in the current directory. If, instead, you choose to use the parameter all output files will end up in the directory you name (and the directory will be created), &#8220;out_serial&#8221; in the example.<\/p>\n<p>Running the case will take some time, depending on the speed of your computer. Expect around half an hour on reasonably modern computers.<\/p>\n<p>Next, we will take a look at the output being produced by the simulator.<\/p>\n<p><!--nextpage--><\/p>\n<h3>Simulator log\u00a0output<\/h3>\n<p>The Flow simulator produces several logs:<\/p>\n<ul>\n<li>Terminal output<\/li>\n<li>The PRT file<\/li>\n<li>The DBG\u00a0file<\/li>\n<\/ul>\n<h5>Terminal output<\/h5>\n<p>The most important messages are written to the terminal. This includes warning and error messages, timesteps and timestep summaries. Warnings are printed in blue, errors in red, and numerical problems (typically leading to timestep chopping) in pink.<\/p>\n<p>By default, the terminal is limited to displaying a certain number of messages of the same type (note, warning, problem, error etc.), so after displaying a large number of warnings for example it will cease reporting them. Similarly, it will stop repeating similar messages (technical detail: messages with the same &#8220;tag&#8221;) after 10 such messages have been displayed. For example, you can see that after report step\u00a04, Flow prints the message: &#8220;Warning: Message limit reached for message tag: Unhandled output keyword&#8221;.<\/p>\n<p>Other than the time steps, the most interesting messages printed to the terminal are the well-control messages printed when wells are switched from one control setting to another due to breaking one or more constraints, and numerical problems encountered. If Flow fails to solve the current timestep for any reason it will retry with a smaller step size. That will be reported like this:<\/p>\n<pre>Problem: Solver convergence failure - Iteration limit reached\r\nTimestep chopped to 3.630000 days\r\n<\/pre>\n<h5>The PRT log (NORNE_ATW2013.PRT)<\/h5>\n<p>The PRT log file contains a lot more than is printed to the terminal.<\/p>\n<p>First, there are no message limits, so warnings that are eventually silenced in the terminal output, will remains as warnings here.<\/p>\n<p>Second, the log is a bit\u00a0more verbose. Initially, an overview of all command-line options used is printed. Also, fluid-in-place reports are printed for all fluid-in-place region after every time-step.<\/p>\n<h5>The DBG\u00a0log (NORNE_ATW2013.DBG)<\/h5>\n<p>The main difference between this and the PRT log is that this will contain absolutely all messages, including debug messages. In particular, the residuals are printed after every iteration, making it possible to follow the Newton-like nonlinear iteration process. This makes it useful to developers, less so for regular users. If you have a problem however, this log can be valuable in diagnosing your issue.<br \/>\n<!--nextpage--><\/p>\n<h3>Summary output<\/h3>\n<p>One of the main outputs from the simulator is the summary file (NORNE_ATW2013.UNSMRY), the ending UNSMRY means it is a unified summary file, i.e. containing data for all time-steps in a single unified file.<\/p>\n<p>In this file you will typically find data that are likely to be useful to plot as a function of time, such as well rates, bottom hole pressures or fluid-in-place quantities. Flow allows the input deck to configure what should be written to the summary file. To look at the summary you may use the <tt>ecl_summary<\/tt> tool as was <a href=\"http:\/\/opm-project.org\/?page_id=197&amp;page=5\">explained in the first tutorial<\/a>\u00a0(also you can use the\u00a0<tt>summaryplot<\/tt> tool to visualize well curves as explained there):<\/p>\n<pre>cd out_serial\r\necl_summary --list NORNE_ATW2013\r\n<\/pre>\n<p>This will give a huge list of keywords corresponding to quantities written to the summary. Some of the more important ideas to get from this are:<\/p>\n<ul>\n<li>Keywords start with a letter signifying its scope: C for completion (well perforation), F for field, G for group (of wells), R for region and W for wells.<\/li>\n<li>The rest of the keyword identifies the quantity, some examples (note that some of the concepts such as oil production rate makes sense and can be used with several of the scopes):\n<ul>\n<li>Well keywords (W): BHP for bottom hole pressures, GOR for gas-oil ratio, OPR for oil production rate, WIR for water injection rate.<\/li>\n<li>Region keywords (R): OIP for oil in place, GIPL for gas in place in the liquid\u00a0phase (dissolved in it).<\/li>\n<\/ul>\n<\/li>\n<li>The string after the colon (if any) is the name of the well or group, the region number, or (for completion data) the well name and completion location.<\/li>\n<\/ul>\n<p>To get a particular quantity, for example the bottom hole pressure of the well C-4H, issue the command<\/p>\n<pre>ecl_summary NORNE_ATW2013 WBHP:C-4H\r\n<\/pre>\n<p>Note that when the well is closed, the BHP is reported as zero.<\/p>\n<p>The units used in all summary (and restart) output files correspond to the unit family chosen in the input deck. For Norne, METRIC units are used, and so the BHP output is in bars, rates are in cubic meters per day etc. When FIELD units are used, BHP output will be in psi, rates in barrels per day for oil and water or 1000 cubic feet per day (yes, really!) for gas etc.<\/p>\n<p><!--nextpage--><\/p>\n<h3>Visualizing the solution\u00a0with ResInsight<\/h3>\n<p><em>Note: the rest of this guide was made with a version of ResInsight that is no longer current, the current version looks different, although the principles should be the same.<\/em><\/p>\n<p>The field data (3D data, typically per cell) is typically written to restart files. For the current case, you will find this in the file NORNE_ATW2013.UNRST (a unified restart file).<\/p>\n<p>We will now open the case in ResInsight to look at some solution variables. You can click on the pictures to see a larger version.<\/p>\n<p>First we need to import the case. Click the <em>Import Eclipse Case<\/em> button.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/1_import_eclipse_case.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-817\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/1_import_eclipse_case.png\" alt=\"1_import_eclipse_case\" width=\"1974\" height=\"1182\" \/><\/a><\/p>\n<p>Navigate to the directory containing the output (out_serial if you followed the instructions earlier) and choose the EGRID file.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/2_open_egrid_file.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-818\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/2_open_egrid_file.png\" alt=\"2_open_egrid_file\" width=\"1974\" height=\"1180\" \/><\/a><\/p>\n<p>The case should open, looking like this:<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/3_loaded1.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-819\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/3_loaded1.png\" alt=\"3_loaded\" width=\"1973\" height=\"1181\" \/><\/a><\/p>\n<p>You can rotate and zoom to get a better view. Use the right mouse button to rotate, the middle button to zoom and the left button to move the view.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/4_zoom_and_rotated.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-820\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/4_zoom_and_rotated.png\" alt=\"4_zoom_and_rotated\" width=\"1974\" height=\"1182\" \/><\/a><\/p>\n<p>By default, we are looking at the oil saturation. Now we want to look at all phase saturations using a ternary color scheme. Click on the <em>TERNARY<\/em> line in the property editor.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/5_ternary_display.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-821\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/5_ternary_display.png\" alt=\"5_ternary_display\" width=\"1973\" height=\"1182\" \/><\/a><\/p>\n<p>The wells are not as visible as we&#8217;d like, so we will change how they are displayed. Click <em>Simulation Wells<\/em> in the <em>Project Tree<\/em> view, then choose <em>Top of active cells BB<\/em> for <em>Well head position<\/em>. Now the well heads are shown at the edge of the full bounding box, and stand out better. Also we&#8217;ll change the <em>Well label color<\/em> to white.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/6_well_setting_display.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-822\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/6_well_setting_display.png\" alt=\"6_well_setting_display\" width=\"1973\" height=\"1182\" \/><\/a><\/p>\n<p>Then we&#8217;ll animate the results, click the <em>Play<\/em> button as shown.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/7_play.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-823\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/7_play.png\" alt=\"7_play\" width=\"1973\" height=\"1180\" \/><\/a><\/p>\n<p>By clicking <em>Pause<\/em> you can stop at any timestep of your choosing. Note that the number of wells change during the simulation.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/8_pause.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-824\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/8_pause.png\" alt=\"8_pause\" width=\"1975\" height=\"1180\" \/><\/a><\/p>\n<p><!--nextpage--><\/p>\n<h3>Visualizing summary data\u00a0with ResInsight<\/h3>\n<p>The ResInsight visualization tool can also display well curves and other summary data interactively. To do this, click the <em>Import Summary Case<\/em> button.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/1_open.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-808\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/1_open.png\" alt=\"1_open\" width=\"1972\" height=\"1180\" \/><\/a><\/p>\n<p>Navigate to the output directory and choose the SMSPEC file.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/2_open_smspec.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-809\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/2_open_smspec.png\" alt=\"2_open_smspec\" width=\"1973\" height=\"1180\" \/><\/a><\/p>\n<p>By default, field production rates for gas, oil, water and liquid (oil + water) are shown. The gas production curve\u00a0dominates the others in this case, as should be expected since it is a case using METRIC and rates\u00a0are therefore shown in cubic meters per day.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/3_loaded.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-810\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/3_loaded.png\" alt=\"3_loaded\" width=\"1969\" height=\"1157\" \/><\/a><\/p>\n<p>We&#8217;d like to inspect the bottom-hole pressure of the well B-1H. Expand <em>Summary plot 1<\/em> in the <em>Project Tree<\/em>, delete the production curves and add the well BHP curve as shown below.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/4_loaded.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-811\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/4_loaded.png\" alt=\"4_loaded\" width=\"1969\" height=\"1157\" \/><\/a><\/p>\n<p>Now we are looking at the BHP curve we wanted to.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/5_select_well_curves.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-812\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/5_select_well_curves.png\" alt=\"5_select_well_curves\" width=\"1970\" height=\"1157\" \/><\/a><\/p>\n<p>If we want to look at properties for a particular well, or a particular property, we can use a filter. Type the well name C-2H in the <em>Well name<\/em> field and the list of choices will be restricted to those relevant to that well. Choose <em>WBHP:C-2H<\/em> to see its BHP curve.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/6_select_well_filter.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-813\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/6_select_well_filter.png\" alt=\"6_select_well_filter\" width=\"1970\" height=\"1157\" \/><\/a><\/p>\n<p>ResInsight can export these images easily. In the <em>Edit<\/em> menu, choose <em>Snapshot To File<\/em> to export them to files. You can see a few examples below.<\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/C-2H_WBHP.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-814\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/C-2H_WBHP.png\" alt=\"c-2h_wbhp\" width=\"1638\" height=\"1066\" \/><\/a><\/p>\n<p><a href=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/F-1H_WWIR.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-815\" src=\"\/\/opm-project.org\/wp-content\/uploads\/2016\/12\/F-1H_WWIR.png\" alt=\"f-1h_wwir\" width=\"1638\" height=\"1066\" \/><\/a><br \/>\n<!--nextpage--><\/p>\n<h3>Running Flow in parallel<\/h3>\n<p>Flow supports running simulations in parallel using MPI. To use this\u00a0run Flow with <tt>mpi_run<\/tt>: (note that the next command should be a single line)<\/p>\n<pre>mpirun -np 4 flow NORNE_ATW2013.DATA --output-dir=out_parallel\r\n<\/pre>\n<p>The above command runs the simulator with four processes, so you should have at least four cores or hardware threads available to gain from this (adjust the parameter to suit your computer). The simulator should then run quite a bit faster (if not 4 times faster). It should be noted that since the input deck format and output file formats are serial in nature, input and output has not been parallelized.<\/p>\n<p>The resulting output should be equivalent to the output from the serial run. It will not be identical however, since the linear solver will not behave identically between the serial and parallel runs.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>This tutorial will guide you through running and visualizing the Norne case, which is an open benchmark case of a real Norwegian Sea oilfield. It will also demonstrate how to run Flow in parallel, take a look at some available run-time parameters, and discuss the logging facilities of Flow. The tutorial assumes that you have &hellip; <a href=\"https:\/\/opm-project.org\/?page_id=780\" class=\"more-link\">Continue reading <span class=\"screen-reader-text\">Running the Norne case with Flow<\/span> <span class=\"meta-nav\">&rarr;<\/span><\/a><\/p>\n","protected":false},"author":5,"featured_media":0,"parent":0,"menu_order":0,"comment_status":"closed","ping_status":"closed","template":"","meta":{"footnotes":""},"_links":{"self":[{"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/pages\/780"}],"collection":[{"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/users\/5"}],"replies":[{"embeddable":true,"href":"https:\/\/opm-project.org\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=780"}],"version-history":[{"count":35,"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/pages\/780\/revisions"}],"predecessor-version":[{"id":1181,"href":"https:\/\/opm-project.org\/index.php?rest_route=\/wp\/v2\/pages\/780\/revisions\/1181"}],"wp:attachment":[{"href":"https:\/\/opm-project.org\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=780"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}