HCBBS Forum (English)
Submit Chemical Projects / Find Solutions
Amplify Your Requirements on a Broader Chemical Platform *Engineering · Technology · Equipment · Solutions*
Submit Request

Attached is the original code for help (program issue)

2009-03-06View Original

Thread Content

There are 9 components in logistics; why can the program only handle the first three of the mixed components? If you can help me with this, I’ll treat you to a meal in Beijing. QQ: 534989768. The procedure is as follows:
SUBROUTINE MODEL (NSIN, NINFI, SIN1, SIN2, SIN3, SIN4, SINFI, NSOUT, NINFO, SOUT1, SOUT2, SOUT3, SOUT4, SINFO, NSUBS, IDXSUB, ITYPE, NINT, INT, NREAL, REAL, IDS, NPO, NBOPST, NIWORK, IWORK, NWORK, WORK, NSIZE, SIZE, INTSIZ, LD)
C IMPLICIT NONE
C C Declare variables used in dimensioning
C INTEGER NSUBS, NINT, NPO, NIWORK, NWORK, NSIZE
C #include “ppexec_user.cmn”
EQUIVALENCE (RMISS, USER_RUMISS)
EQUIVALENCE (IMISS, USER_IUMISS)
C REAL*8 B(1), IB(1)
EQUIVALENCE (B(1), IB(1))
#include “dms_ncomp.cmn”
#include “shs_stwork.cmn”
#include “dms_global.cmn”
#include “dms_ppwork.cmn”
#include “dms_ipwork.cmn”
C C Declare arguments
C INTEGER IDXSUB(NSUBS), ITYPE(NSUBS), INT(NINT), IDS(2,13), NBOPST(6,NPO), IWORK(NIWORK), INTSIZ(NSIZE), NSIN, NINFI, NSOUT, NINFO, NREAL, LD, J
REAL*8 SIN1(1), SIN2(1), SIN3(1), SIN4(1), SOUT1(1), SOUT2(1), SOUT3(1), SOUT4(1), WORK(NWORK), SIZE(NSIZE), SINFI, SINFO
C C Declare local variables
C INTEGER IMISS, IC, IO2, DMS_KFORMC, DMS_KCCIDC, DMS_KNCIDC, DMS_KNCID
INTEGER IASH, IH2, IN2, IS, ICL2, IH2O, K, DMS_IFCMNC, ICOAL, I
INTEGER LI1, LI2, LI, LIDSCC
REAL*8 REAL(NREAL), RMISS, SPLIT(9)
CHARACTER*8 ASH, C
C C C Begin executable code
C SPLIT(1)=1
SPLIT(2)=1
SPLIT(3)=1
SPLIT(4)=0.5
SPLIT(5)=1
SPLIT(6)=0.5
SPLIT(7)=0.5
SPLIT(8)=0.5
SPLIT(9)=0.5
C Split the first inlet into the first and second outlets
C SOUT1(1) = SIN1(1) * REAL(1)
SOUT1(2) = SIN1(2) * REAL(2)
SOUT1(3) = SIN1(3) * REAL(3)
SOUT2(4) = SIN1(4) * REAL(4)
SOUT3(5) = SIN1(5) * REAL(5)
SOUT4(6) = SIN1(6) * REAL(6)
SOUT1(7) = SIN1(7) * REAL(7)
SOUT1(8) = SIN1(8) * REAL(8)
SOUT1(9) = SIN1(9) * REAL(9)
C SOUT2(I) = SIN1(I) – SOUT1(I)
C Copy all intensive variables
C DO 200 I = NCOMP_NCC+2, NCOMP_NCC+9
SOUT1(I) = SIN1(I)
200 CONTINUE
DO 300 I = NCOMP_NNCC+2, NCOMP_NNCC+9
SOUT1(I) = SIN1(I)
300 CONTINUE
RETURN
END
Reply #22009-03-06
SOUT2(4) = SIN1(4) * REAL(4) SOUT3(5) = SIN1(5) * REAL(5) SOUT4(6) = SIN1(6) * REAL(6) change to SOUT1(4) = SIN1(4) * REAL(4) SOUT1(5) = SIN1(5) * REAL(5) SOUT1(6) = SIN1(6) * REAL(6)
Reply #32009-03-06
It shows that you’ve taken the time to study this program; we can have more discussions when you have time
Reply #42009-03-09
Try changing to the usr2 module, OP
Reply #52009-05-22
Good question, I’ll take a look at it tonight. It’s a pity there’s no Fortran installed at home

Submit a Project

**Looking for Chemical Technology, Equipment & Solutions?** No Registration Required Broader Platform Exposure | Global Chemical Service Provider Connections

Submit Request — Free Consultation

Disclaimer

This is an automated machine translation of the original thread. Some technical terms may have inaccuracies; the original text shall prevail. Click "View Original" at the top right to access the source page, which supports IP-based automatic real-time language translation. Please watch out for contact details and sales inducements to prevent fraud. All content and translations are for reference only, representing solely the poster's personal views. For enquiries, email service@hcbbs.com.