Skip to content

bug: wrf Potential Temperature interpolation using incorrect value for one corner #1011

@hkershaw-brown

Description

@hkershaw-brown

🐛 🌵

Describe the bug

  1. run model_mod_check (or perfect_model_obs or filter) with wrf dart interpolating QTY_POTENTIAL_TEMPERATURE for a 3d (non surface) location
  2. Correct interpolation
  3. Incorrect value calculated

Error Message

No error, just incorrect results.

Which model(s) are you working with?

WRF and WRF-CHEM

Screenshots

If applicable, add screenshots to help explain your problem.

The k+1 get state gets x_ill twice, leading to the interpolated value for k+1 for x_iull using the value from k the previous step

DART/models/wrf/model_mod.f90

Lines 1834 to 1835 in a32ab03

x_ill = get_state(ill, state_handle)
x_ill = get_state(ill, state_handle)

Version of DART

Which version of DART are you using?
You can find the version using git describe --tags
v11.19.0-32-ge09693e1e

Looks to have been in for 10+ years

Have you modified the DART code?

Yes, wrf_unified model_mod, but this bug is present in main

Build information

Please describe:

  1. Mac M
  2. gcc13 13.3.0_2+stdlib_flag) 13.3.0

Metadata

Metadata

Labels

BugSomething isn't workingwrfWeather Research & Forecasting Model

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions