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

No response to manually inserted print statements

m3mc3

New member
Hi,

For the project I'm working on right now I need the full model pressure at every timestep, and we're running very small timesteps (sub 1 second) that the history_interval can't output, so I'm trying to insert a print statement in module_big_step_utilities_em.F within subroutine "phy_prep", but so far I've had no luck.

I tried using "print *, p(i, j, k)", I've tried making calls to module_wrf_error using "write(message, *) p(i, j, k) \\ CALL wrf_message(message)", and using "IPRNT = .true." but so far nothing has worked. I can recompile, everything builds successfully, and my simulations run without any errors, but there are no signs of the pressure values being printed in any rsl.out or rsl.error files.

Just to be sure, I tried adding print statements for simple lines that I can grep for within solve_em.F, module_after_all_rk_steps.F, and module_timing.F (I even found and added to the "Timing for" statement that prints at all timesteps in rsl.out.0000) but none of them appear (again, no problems with the build or the job, though).

I'm very stuck and I hope the community can help me out with this one.
Thanks!
 
Can you attach the code you modified and let me know which model version you're using? Thanks!
 
Hi, I'm using version 4.3.3. My latest attempt was to define a variable "temp", and then use a WRITE statement and a call to wrf_debug. This didn't work either.
 

Attachments

  • 1698528742100.png
    1698528742100.png
    17.2 KB · Views: 4
Hi,
Can you please attach the actual files you've modified, instead of just a screenshot? Thanks.
 
Hi,
Can you please attach the actual files you've modified, instead of just a screenshot? Thanks.

Hey I would be very interested in how to use the wrf_message to write an output but I can't find how to do that anywhere. I need to write some values to debug a certain procces that I edited. Please let me know how to do this correcly.
 
Hey I would be very interested in how to use the wrf_message to write an output but I can't find how to do that anywhere. I need to write some values to debug a certain procces that I edited. Please let me know how to do this correcly.
You don't need to use wrf_message to write output for these values. You can just add a print statement that prints out the variable(s), and at a particular location, if you wish. For e.g., if you created a new variable called "myvar," and you wanted to see the value over time for the 32,22 grid cell, you could add
something like

Code:
print *, "myvar value = ", myvar(32,22)

depending on the indices in the code for the value. In other words, "myvar(32,22)" in the above line may look different, depending on how this variable appears in the code.
 
Top