30 use discretelement
, only: des_mmax
61 IF(no_of_rxns == 0)
allocate(rxn_name(1))
65 lmmax = smax + des_mmax
73 CALL checkspeciesinc(
nmax(0), species_alias_g(:), lmmax, &
78 IF(no_of_rxns > 0)
THEN 80 rxn_chem_eq, usrdh,
usrfdh, reaction)
85 des_rxn_chem_eq, des_usrdh,
des_usrfdh, des_reaction)
131 INTEGER,
INTENT(IN) :: COUNT
152 DOUBLE PRECISION netMassTransfer(0:
dim_m)
161 allocate(rxn_array(count))
173 this%Name = trim(name(l))
178 IF(len_trim(this%Name) == 0)
THEN 183 1100
FORMAT(
'Error 1100: No reaction name identified for reaction ', &
184 i3,
'.',/
'This should have been caught during the parsing ', &
188 this%ChemEq = trim(chem_eq(l))
191 IF(len_trim(this%ChemEq) == 0)
THEN 192 WRITE(*,1101) trim(this%Name)
196 1101
FORMAT(
'Error 1101: No chemical equation identified for ', &
197 'reaction ',a,
'.',/
'Please correct the mfix.dat file.')
200 CALL setreaction(this, nmax(0), species_alias_g(:),lmmax, &
201 nmax(1:lmmax), species_alias_s(:,:), dh(l), fdh(l,:))
205 IF(.NOT.
energy_eq .AND. .NOT.this%Calc_DH)
THEN 206 WRITE(
err_msg,1200) trim(this%Name)
210 1200
FORMAT(
'Error 1200: Inconsistent user input. Energy equations ', &
211 'are NOT being',/
'solved and a user defined heat of reaction',&
212 ' was detected',
' for chemical',/
' reaction ',a,
'.',/
'Please',&
213 ' correct the mfix.dat file.')
216 IF(this%nSpecies == 0 .AND. this%nPhases == 0)
THEN 221 ELSEIF((this%nPhases == 0 .AND. this%nSpecies /= 0) .OR. &
222 (this%nPhases /= 0 .AND. this%nSpecies == 0))
THEN 224 WRITE(
err_msg,1201) trim(this%Name), this%nPhases, &
229 1201
FORMAT(
'Error 1201: Illogical data returned from setReaction ', &
230 'for chemical',/
'reaction',1x,a,
'.',//
' Number of phases ', &
231 'identified: ',i3,/
'Number of species identified: ',i3,//, &
232 'Please check the mfix.dat file.')
236 CALL checkthermoreqs(this, species_g, species_s,
rdatabase, &
243 CALL checkmassbalance(
'CHECK_CHEMICAL_RXNS', this, &
244 netmasstransfer(:), ier)
247 species_alias_s(:,:), .true.)
252 CALL calcinterphasetxfr(
'CHECK_CHEMICAL_RXNS', this, &
254 species_alias_g(:), lmmax, species_alias_s(:,:))
262 species_alias_s(:,:), .false.)
double precision, dimension(dim_m) c_ps0
subroutine setreaction(RxN, lNg, lSAg, lM, lNs, lSAs, lDH, lfDH)
character(len=18), dimension(dim_m, dim_n_s) species_s
subroutine check_chemical_rxns
character(len=32), dimension(:), allocatable rxn_name
integer, parameter dimension_rxn
logical, dimension(0:dim_m) species_eq
double precision, dimension(:,:), allocatable des_usrfdh
character(len=32), dimension(dim_n_g) species_alias_g
double precision, dimension(dim_n_g) mw_g
character(len=32), dimension(:), allocatable des_rxn_name
subroutine init_err_msg(CALLER)
subroutine checkmassbalance(CALLER, RxN, lnMT, IER)
subroutine write_rxn_summary(RxN, lSAg, lSAs, ABORT, fUNIT)
subroutine calcinterphasetxfr(CALLER, RxN, lnMT, lEEq, lSEq, lSAg, lMMx, lSAs)
subroutine checkspeciesinc(lNg, SA_g, lMMx, lNs, SA_s, lNRxn, lRNames, lNRxn_DES, lRNames_DES)
double precision, dimension(:), allocatable usrdh
double precision, dimension(:), allocatable des_usrdh
logical, dimension(0:dim_m, dim_n_g) rdatabase
character(len=512), dimension(:), allocatable des_rxn_chem_eq
integer, dimension(0:dim_m) nmax
double precision, dimension(:,:), allocatable usrfdh
character(len=512), dimension(:), allocatable rxn_chem_eq
subroutine checkduplicatealiases(lNg, SA_g, lMMx, lNs, SA_s)
double precision, dimension(dim_m, dim_n_s) mw_s
integer, parameter undefined_i
character(len=line_length), dimension(line_count) err_msg
subroutine check_chemical_rxns_common(COUNT, NAME, CHEM_EQ, DH, fDH, RXN_ARRAY)
character(len=18), dimension(dim_n_g) species_g
character(len=32), dimension(dim_m, dim_n_s) species_alias_s
subroutine checkthermoreqs(RxN, S_g, S_s, rDB, MWg, MWs, Cpg0, Cps0)
subroutine flush_err_msg(DEBUG, HEADER, FOOTER, ABORT, LOG, CALL_TREE)