Skip to content

Commit f17eaff

Browse files
mjohnson541ssun30
authored andcommitted
missing domain tweaks for phi/d
1 parent 19d339f commit f17eaff

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

src/Domain.jl

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -826,9 +826,9 @@ function FragmentBasedConstantTrhoDomain(; phase::Z, initialconds::Dict{X,E}, co
826826
end
827827

828828
C = N/V
829-
dGrxns = -(phase.stoichmatrix*Gs)
830-
kfs,krevs = getkfkrevs(phase,T,P,C,N,ns,Gs,diffs,V,0.0,0.0)
831-
kfsnondiff = getkfs(phase,T,P,C,ns,V,0.0,dGrxns,0.0)
829+
dGrxns = -(phase.stoichmatrix*Gs).+phase.electronchange.*(phi*F)
830+
kfs,krevs = getkfkrevs(phase,T,P,C,N,ns,Gs,diffs,V,phi,d)
831+
kfsnondiff = getkfs(phase,T,P,C,ns,V,phi,dGrxns,d)
832832
p = vcat(Gs,kfsnondiff)
833833
if sparse
834834
jacobian = zeros(typeof(T), length(getphasespecies(phase)), length(getphasespecies(phase)))
@@ -926,8 +926,8 @@ function ConstantTLiqFilmDomain(; phase::Z, initialconds::Dict{X,E}, constantspe
926926
end
927927
P = 1.0e8 #essentiallly assuming this is a liquid
928928
C = N / V
929-
kfs, krevs = getkfkrevs(phase, T, P, C, N, ns, Gs, diffs, V, phi)
930-
kfsnondiff = getkfs(phase, T, P, C, ns, V, phi)
929+
kfs, krevs = getkfkrevs(phase, T, P, C, N, ns, Gs, diffs, V, phi, d)
930+
kfsnondiff = getkfs(phase, T, P, C, ns, V, phi, d)
931931
p = vcat(Gs, kfsnondiff)
932932
if sparse
933933
jacobian = zeros(typeof(T), length(phase.species), length(phase.species))

0 commit comments

Comments
 (0)