Scheduled Downtime
On Friday 21 April 2023 @ 5pm MT, this website will be down for maintenance and expected to return online the morning of 24 April 2023 at the latest

Warm Bubble Initialization Several Hours into a Simulation

This post was from a previous version of the WRF&MPAS-A Support Forum. New replies have been disabled and if you have follow up questions related to this post, then please start a new thread from the forum home page.

wflams

New member
Hi All,

I'm trying to initialize a warm bubble in the idealized supercell simulation several hours into a simulation (rather than at time = 0). Does anyone have experience doing something similar? Thanks!
 
Hello,

I have no direct experience with supercell simulations but have faced a similar issue when I wanted to release the tracers at a specific time and for a user given duration. I had to create two new namelist variables (tracer_start_time and tracer_run_time) and modify the initialize and solver code accordingly to start the tracers at a user-specified time. At every timestep I would check if the current time is greater than the user specified start_time and if it is, I would start releasing the tracers. Similar to mine, In your case, I would assume modifying the module_initialize code for that ideal case and then the solve file might help.

Hope this helps.

Sudheer
 
wflams said:
Hi All,

I'm trying to initialize a warm bubble in the idealized supercell simulation several hours into a simulation (rather than at time = 0). Does anyone have experience doing something similar? Thanks!

I'm trying to do the same thing in the em_fire ideal case... I want to have a spin up period, and delay the bubble for a few hours... I can't seem to figure out how to do it either... a bit over my head fortran wise... Did you ever figure this out? Thanks!
 
Hi All,
In order to initialize a warm bubble later in an idealized simulation, there are a couple of files you'll need to modify:
dyn_em/solve_em.F
dyn_em/module_initialize_*.F (the initialization file appropriate to your case)

I have played around with this a bit for the supercell case, and will attach the modified files (these are modified from V4.0 code).Basically, you will need to go into the module_initialize_ideal.F file and search for the word 'bubble.' The first place you find it is inside the supercell case (starting around line 1075). If you put an #if 0......#endif statement around the entire content inside that case, it will ignore the initialization of the bubble at the beginning of the simulation (see the attached file).

You then need to take all of that content from the module_initialize_ideal file (within the above-mentioned supercell case section) and put it inside the solve_em.F file after the call to 'get_ijk_from_grid' (around line 231), and before the call to 'get_ijk_from_subgrid' section (around line 238). You will also need to make the following modifications (see the attached file - search for 'wrfhelp' to see where any modified code is, or you can diff the modified file, versus a pristine copy:
1) add an if statement around the whole new section to specify the time_step you want the bubble released
2) all the variables that are *_1 (e.g., ph_1), should be changed to *_2 (e.g., ph_2). This makes a couple of lines irrelevant, so those can be removed
3) all variables in this new section that are not preceded by "grid%" are local variables that were specifically declared in module_initialize_ideal, so they will need to be declared further up in solve_em (again, just search for 'wrfhelp').
4) all jts,jte,its,ite need to be changed to jps,jpe,ips,ipe
5) around line 303 in the original file, you should find the line "grid%itimestep = grid%itimestep + 1." Change this to whatever time step you'd like the bubble released (e.g., grid%itimestep = 100), and set the same for the if-test in step 1) above.

All this being said, we have not tested this thoroughly and are not certain how reasonable the results will be. Please proceed with caution. Because some of these cases have open boundaries, it could cause some unexpected results. You may need to make further modifications to cater this to your particular application.
 

Attachments

  • module_initialize_ideal.F
    68.3 KB · Views: 89
  • solve_em.F
    247.4 KB · Views: 91
Sir, I would like to know is it necessary to modify code when super cell ideal case is being simulated?
because I have done modification only in namelist and it gives constant field of wind and other parameters. here I have attached the namelist.
 

Attachments

  • namelist.input
    4.7 KB · Views: 53
please help.
Idealized simulation of supercell shows constant field in wrfout file
what to do
here I have attached the namelist.input
 

Attachments

  • namelist.input
    4.7 KB · Views: 51
kwerner said:
Hi All,
In order to initialize a warm bubble later in an idealized simulation, there are a couple of files you'll need to modify:
dyn_em/solve_em.F
dyn_em/module_initialize_*.F (the initialization file appropriate to your case)

I have played around with this a bit for the supercell case, and will attach the modified files (these are modified from V4.0 code).Basically, you will need to go into the module_initialize_ideal.F file and search for the word 'bubble.' The first place you find it is inside the supercell case (starting around line 1075). If you put an #if 0......#endif statement around the entire content inside that case, it will ignore the initialization of the bubble at the beginning of the simulation (see the attached file).

You then need to take all of that content from the module_initialize_ideal file (within the above-mentioned supercell case section) and put it inside the solve_em.F file after the call to 'get_ijk_from_grid' (around line 231), and before the call to 'get_ijk_from_subgrid' section (around line 238). You will also need to make the following modifications (see the attached file - search for 'wrfhelp' to see where any modified code is, or you can diff the modified file, versus a pristine copy:
1) add an if statement around the whole new section to specify the time_step you want the bubble released
2) all the variables that are *_1 (e.g., ph_1), should be changed to *_2 (e.g., ph_2). This makes a couple of lines irrelevant, so those can be removed
3) all variables in this new section that are not preceded by "grid%" are local variables that were specifically declared in module_initialize_ideal, so they will need to be declared further up in solve_em (again, just search for 'wrfhelp').
4) all jts,jte,its,ite need to be changed to jps,jpe,ips,ipe
5) around line 303 in the original file, you should find the line "grid%itimestep = grid%itimestep + 1." Change this to whatever time step you'd like the bubble released (e.g., grid%itimestep = 100), and set the same for the if-test in step 1) above.

All this being said, we have not tested this thoroughly and are not certain how reasonable the results will be. Please proceed with caution. Because some of these cases have open boundaries, it could cause some unexpected results. You may need to make further modifications to cater this to your particular application.

Hi,
I am, using WRF version 3.9.1. I have previously simulated the supercell case successfully. I now need to simulate multiple warm bubbles at different locations and times. I am able to initiate more than one bubble, but still have no control over the time specification. All the bubbles are getting initiated at the beginning. Have you tried this anytime??
Thank you
 
@sandeepj_123,
So even when you completely remove the initialization of the warm bubble from the initialization routine, it still happens?
 
Thanks for the reply. I have tried removing the routine and adding the code block to the solver as mentioned above, but that did not work.
I could initiate multiple bubbles by specifying it within the "module_initialize_quarter_ss.F". But the issue is that all bubbles get started at the beginning of the run. I tried putting the block inside an "IF" statement with specified timestep using "grid%itimestep", but then the bubble was not at all getting initiated. I could correctly specify the location of the bubble, radius, and the perturbation, but not the required timestep.

Thank you
 
@sandeepj_123,
Unfortunately this falls out of the scope of our support. We are able to support the out-of-the-box released WRF code, and can attempt to give pointers to solve other issues if resources allow, but we aren't able to invest a lot of time into modifying code for an individual use. As I'm not very familiar with this specific code, I don't have much advice except to perhaps start with pristine code and try making minor tweaks to see if you can get them to work. Once you get the general concept down, you can then try adding more specific features for your case. It's also possible that someone else on the forum will see your inquiry and will know how to advise you. If you do figure it out, if you have time, please post the solution so someone in the future may benefit. Thanks and I apologize for the inconvenience.
 
Hello,

Thank you for the response. I understand that my request was a bit too specific. But the forum and the posts here have helped me a lot. I shall try to figure it out, and share the info if I am succesful at it. Thank you once again.
 
Top