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

LatentHeatMelt material model has a bug in thermal_expansion_coefficient #1666

Closed
bangerth opened this issue May 15, 2017 · 1 comment
Closed

Comments

@bangerth
Copy link
Contributor

Pointed out by @alarshi: This function doesn't make much sense:

    template <int dim>
    double
    LatentHeatMelt<dim>::
    thermal_expansion_coefficient (const double temperature,
                                   const double pressure,
                                   const std::vector<double> &composition,
                                   const Point<dim> &position) const
    {
      return thermal_alpha;

      const double melt_frac = melt_fraction(temperature, pressure, composition, position);
      return thermal_alpha * (1-melt_frac) + melt_thermal_alpha * melt_frac;
    }

The git log information is as follows:

b434d073 source/material_model/latent_heat_melt.cc (Juliane Dannberg  2014-06-19 18:40:51 +0200 143)     {
924f6d13 source/material_model/latent_heat_melt.cc (Rene Gassmoeller  2016-11-22 10:01:33 -0700 144)       return thermal_alpha;
b434d073 source/material_model/latent_heat_melt.cc (Juliane Dannberg  2014-06-19 18:40:51 +0200 145) 
b434d073 source/material_model/latent_heat_melt.cc (Juliane Dannberg  2014-06-19 18:40:51 +0200 146)       const double melt_frac = melt_fraction(temperature, pressure, composition, position);
b434d073 source/material_model/latent_heat_melt.cc (Juliane Dannberg  2014-06-19 18:40:51 +0200 147)       return thermal_alpha * (1-melt_frac) + melt_thermal_alpha * melt_frac;
b434d073 source/material_model/latent_heat_melt.cc (Juliane Dannberg  2014-06-19 18:40:51 +0200 148)     }

@jdannberg , @gassmoeller -- any insight into the reasoning why the first return was added?

@jdannberg
Copy link
Contributor

This was fixed by #1706.

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

No branches or pull requests

2 participants