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

fix compute_meltfraction #222

Merged
merged 5 commits into from
Oct 12, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Energy/Shearheating.jl
Original file line number Diff line number Diff line change
Expand Up @@ -172,7 +172,7 @@

function compute_shearheating(s::AbstractMaterialParamsStruct, args::Vararg{Any,N}) where N
if isempty(s.ShearHeat)
return 0.0 # return zero if not specified
return 0e0 # return zero if not specified

Check warning on line 175 in src/Energy/Shearheating.jl

View check run for this annotation

Codecov / codecov/patch

src/Energy/Shearheating.jl#L175

Added line #L175 was not covered by tests
else
return compute_shearheating(s.ShearHeat[1], args...)
end
Expand Down
4 changes: 2 additions & 2 deletions src/MeltFraction/MeltingParameterization.jl
Original file line number Diff line number Diff line change
Expand Up @@ -747,15 +747,15 @@ end
# Computational routines needed for computations with the MaterialParams structure
function compute_meltfraction(s::AbstractMaterialParamsStruct, args)
if isempty(s.Melting) #in case there is a phase with no melting parametrization
return zero(typeof(args).types[1])
return 0e0 # return zero if not specified
else
return compute_meltfraction(s.Melting[1], args)
end
end

function compute_dϕdT(s::AbstractMaterialParamsStruct, args)
if isempty(s.Melting) #in case there is a phase with no melting parametrization
return zero(typeof(args).types[1])
return 0e0 # return zero if not specified
else
return compute_dϕdT(s.Melting[1], args)
end
Expand Down
Loading