Skip to content

Commit

Permalink
Merge pull request #222 from JuliaGeodynamics/pa-melting
Browse files Browse the repository at this point in the history
fix `compute_meltfraction`
  • Loading branch information
aelligp authored Oct 12, 2024
2 parents cd97cfc + 33b9368 commit ba13daf
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
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 @@ end

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
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

0 comments on commit ba13daf

Please sign in to comment.