fix: [Phase B.3] Fix free-floating temperature failures (#666)#677
Closed
fix: [Phase B.3] Fix free-floating temperature failures (#666)#677
Conversation
- Disabled empirically-derived 6R2C correction factors (5.2, 1.74) - These factors were papering over calculation errors in h_tr_ms - Now using physics-based values directly Issue #665
- Remove incorrect 'if !ctf_primary' guard that was blocking CTF heat flux from zone air heat balance - CTF contribution now properly included in t_i_free calculation for ctf_primary cases (900FF, 950FF) - Result: Min temp improved from -8.10°C to -4.21°C (closer to reference -6.40 to -1.60°C) - Max temp changed from 81.27°C to 83.74°C (still far from reference 41.80-46.40°C - further work needed) Root cause: When ctf_primary=true, the CTF heat flux was being EXCLUDED from the zone air heat balance at line 1499, causing t_i_free to be calculated with the lumped 6R2C parameters instead of CTF's accurate thermal mass representation. Note: The max temperature issue persists (83°C vs 41-46°C target). This indicates additional thermal mass modeling issues beyond the scope of this fix. The ASHRAE 140 reference cases for 900FF require time constants of 120-200h, but current model produces ~26h.
CTFSolver::new() initializes history with zero flux and uniform 20°C, causing unphysical heat flux values at simulation start for high-mass constructions (900FF, 950FF). Switch to with_warmup() which runs 7-day diurnal warmup cycles to establish realistic flux history before simulation begins. Tests: - test_ctf_wrapper_warmup_initializes_flux_history: verifies warmup - test_ctf_wrapper_without_warmup_vs_with_warmup: regression test Fixes #679
Owner
Author
|
Closing this PR - it contains the REGRESSION (6R2C factors set to 1.0, ctf_primary guard removed) instead of the correct fix. The proper fix has been merged via PR #687. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Fixes #666 and #679 by addressing two root causes of free-floating temperature failures in high-mass constructions (900FF, 950FF).
Issue #666 - CTF Flux Guard
When
ctf_primary=true, the CTF heat flux was being excluded from the zone air heat balance at line 1499 inthermal_model_physics.rs:Fix: Removed the
if !self.0.ctf_primaryguard so CTF heat flux is properly included.Issue #679 - Missing Warmup
CTFSolver::new()initialized history with zero flux and uniform 20°C, causing unphysical heat flux values at simulation start.Fix: Switched to
CTFSolver::with_warmup()which runs 7-day diurnal warmup cycles.Changes
src/physics/ctf_solver_wrapper.rs: ChangedCTFSolver::new()→CTFSolver::with_warmup(..., 20.0, 20.0, 7)src/sim/thermal_model_physics.rs: Removed incorrectif !ctf_primaryguardResults
Testing
test_ctf_wrapper_warmup_initializes_flux_historytest_ctf_wrapper_without_warmup_vs_with_warmup