Hi everyone,
This is my former question (Can’t open included file ‘usrnlst.inc’ when building solver). However, I meet new errors about the defination for chemical reaction rates. I have read 4.13.3. Reaction Examples in MFiX User Manual but still having the following errors. I am not sure how to solve these problems.
Biomass_13.mfx (21.3 KB)
usr_rates.f (2.3 KB)
usr_rates_des.f (3.3 KB)
species.inc:11:32:
INTEGER, PARAMETER :: Char = 2
1
Error: Cannot change attributes of USE-associated symbol at (1)
CMakeFiles\udfs.dir\build.make:78: recipe for target ‘CMakeFiles/udfs.dir/D_/7_Simulation_cases/Biomass_13/usr_rates.f.obj’ failed
mingw32-make.exe[2]: *** [CMakeFiles/udfs.dir/D_/7_Simulation_cases/Biomass_13/usr_rates.f.obj] Error 1
mingw32-make.exe[2]: *** Waiting for unfinished jobs…
species.inc:11:32:
INTEGER, PARAMETER :: Char = 2
1
Error: Cannot change attributes of USE-associated symbol at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:80:44:
ReactantMassFraction = DES_X_s(NP,CHAR)
1
Error: Function ‘char’ requires an argument list at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:62:25:
DES_RATES(Drying) = 5.13d6*exp(-8.79d7/(8314.d0*Tp))*MW_s(1,MOISTURE)
1
Error: Symbol ‘drying’ at (1) has no IMPLICIT type
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:53:33:
Tp = min(MAX_TEMP, DES_T_S(NP))
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:54:29:
Tg = min(MAX_TEMP, T_g(IJK))
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:60:38:
ReactantMassFraction = DES_X_s(NP,MOISTURE)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:71:37:
ReactantMassFraction = DES_X_s(NP,VOLATILE)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:77:41:
IF(nRR >= Pyrolysis) ReactionRates(IJK,Pyrolysis) = RATES(Pyrolysis)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:77:58:
IF(nRR >= Pyrolysis) ReactionRates(IJK,Pyrolysis) = RATES(Pyrolysis)
1
Error: Function ‘rates’ at (1) has no IMPLICIT type
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:81:61:
IF((ReactantMassFraction .GT. residuleMass) .AND. (X_g(IJK, CO2) .NE. 0)) THEN
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:84:38:
pco2 = P_g*MW_MIX_g(IJK)*X_g(IJK, CO2)/MW_g(CO2)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:84:29:
pco2 = P_g*MW_MIX_g(IJK)*X_g(IJK, CO2)/MW_g(CO2)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:84:9:
pco2 = P_g*MW_MIX_g(IJK)*X_g(IJK, CO2)/MW_g(CO2)
1
Error: Incompatible ranks 0 and 1 in assignment at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:89:34:
IF(nRR >= R1) ReactionRates(IJK,R1) = RATES(R1)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:89:44:
IF(nRR >= R1) ReactionRates(IJK,R1) = RATES(R1)
1
Error: Function ‘rates’ at (1) has no IMPLICIT type
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:91:61:
IF((ReactantMassFraction .GT. residuleMass) .AND. (X_g(IJK, H2O) .NE. 0)) THEN
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:94:38:
ph2o = P_g*MW_MIX_g(IJK)*X_g(IJK, H2O)/MW_g(H2O)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:94:29:
ph2o = P_g*MW_MIX_g(IJK)*X_g(IJK, H2O)/MW_g(H2O)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:94:9:
ph2o = P_g*MW_MIX_g(IJK)*X_g(IJK, H2O)/MW_g(H2O)
1
Error: Incompatible ranks 0 and 1 in assignment at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:99:34:
IF(nRR >= R2) ReactionRates(IJK,R2) = RATES(R2)
1
Warning: Legacy Extension: REAL array index at (1)
D:\7_Simulation_cases\Biomass_13\usr_rates_des.f:99:44:
IF(nRR >= R2) ReactionRates(IJK,R2) = RATES(R2)
1
Error: Function ‘rates’ at (1) has no IMPLICIT type
mingw32-make.exe[2]: *** [CMakeFiles/udfs.dir/D_/7_Simulation_cases/Biomass_13/usr_rates_des.f.obj] Error 1
CMakeFiles\udfs.dir\build.make:92: recipe for target ‘CMakeFiles/udfs.dir/D_/7_Simulation_cases/Biomass_13/usr_rates_des.f.obj’ failed
CMakeFiles\Makefile2:101: recipe for target ‘CMakeFiles/udfs.dir/all’ failed
Makefile:134: recipe for target ‘all’ failed
BUILD FAILED
==========================================================================
mingw32-make.exe[1]: *** [CMakeFiles/udfs.dir/all] Error 2
mingw32-make.exe: *** [all] Error 2