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 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!
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.