Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Reorganize getdata section of temperature_component.cpp #595

Merged
merged 3 commits into from
Mar 30, 2022

Conversation

kdorheim
Copy link
Contributor

This PR address part of #586 re organizes how the output variables are returned

@kdorheim kdorheim requested a review from bpbond March 24, 2022 13:42
Copy link
Member

@bpbond bpbond left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I didn't follow logic all the way through but seems right 👍 thanks!

@@ -103,7 +103,7 @@ class TemperatureComponent : public IModelComponent {
double taudif; // interior ocean heat uptake time scale, yr
double tauksl; // sea-land heat exchange time scale, yr
double taukls; // land-sea heat exchange time scale, yr
unitval q2co2; // radiative forcing for atmospheric CO2 doubling (W/m2)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why removal of units?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh no it has units and I need to add them!

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed it from a unitval because the math it is used in does not like the unitval, beforehand we had some code that basically extracted the unitval information and reassigned it as a const double which seemed uncessairy.

@@ -180,7 +180,7 @@ void TemperatureComponent::setData( const string& varName,
volscl = data.getUnitval(U_UNITLESS);
} else if(varName == D_QCO2) {
H_ASSERT( data.date == Core::undefinedIndex(), "date not allowed" );
q2co2 = data.getUnitval(U_UNDEFINED);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

...because it's unitless I guess :)

@kdorheim
Copy link
Contributor Author

@bpbond okay to merge?

@bpbond
Copy link
Member

bpbond commented Mar 30, 2022

Yes!

@kdorheim kdorheim merged commit b0baa15 into land_tracking Mar 30, 2022
@kdorheim kdorheim deleted the krd_more_doeclim_changegs branch March 30, 2022 12:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants