Storage of different adjustments

Discusses use of COCO, the process simulation and modelling software suite from AmsterCHEM, downloadable from http://www.cocosimulator.org

Moderator: jasper

Storage of different adjustments

Postby Florian041190 » 10 June 2015, 13:46

Hello ladies and gentlemen,

at the moment I am trying to simulate a combined cycle gas turbine.
The demand is every month different.

Is there a possibility in Cofe to store all the different adjustments for every month in one file?

What I am trying to do is, that I press january and because of the stored datas the system knows how much gas for the gasturbine and water for the steam cycle is needed in January.

I would be delighted about an answer.

Best wishes
Florian
Florian041190
 
Posts: 6
Joined: 02 June 2015, 08:37

Re: Storage of different adjustments

Postby jasper » 10 June 2015, 13:54

You could try a Matlab, Scilab or Excel unit operation

Matlab and Scilab allow for option parameters, with a list of valid values {January, February, ...}

Excel at this point only allows for real parameters, but you could put the month number in there and use HLOOKUP, VLOOKUP or LOOKUP inside Excel
User avatar
jasper
 
Posts: 1128
Joined: 24 October 2012, 15:33
Location: Spain

Re: Storage of different adjustments

Postby Florian041190 » 11 June 2015, 07:40

Is it possible to add streams of 2 different property packs to an Excel Unit?

Because I would like to do the gas stream as well as the feedwater streams variable.
For the gas stream I use a TEA PP and for the other 2 a water PP.

I tried a few things but I just can add the streams of 1 PP to the Unit and not from the second.
Florian041190
 
Posts: 6
Joined: 02 June 2015, 08:37

Re: Storage of different adjustments

Postby jasper » 11 June 2015, 08:08

Not at this point.

COFE disallows, by default, connection of different material types to a single unit. But you can tick this off at the Ports tab when double clicking the unit, as for some unit operations (e.g. a heat exchanger) this is valid.

The Excel unit operation however makes the assumption of a single compound slate, and its validate method checks for this; you will not be able to run an Excel unit operation connected to streams with different compound slates. This assumption covers by far most cases, and letting go of this restriction complicates things a lot in the layout of the Excel sheets and in the arguments to the thermodynamic routines. This is not an easy assumption to drop. Same holds for the Matlab and Scilab unit ops, so they do not provide a way out in this case.

I am afraid that your next step will be a custom unit operation, which involves some programming. Or perhaps you can get away with a combination of two Excel unit operations (one for one compound slate, the other for the other compound slate) that communicate via parameters (on virtual ports, on information streams). You could embed the combination of two Excel unit operations and the coupling information streams in a COFE unit operation, to make it look like a single unit operation.

(or a third party unit operation, not sure whether for example GO:CAPE-OPEN deals with multiple compound slates, but it might)
User avatar
jasper
 
Posts: 1128
Joined: 24 October 2012, 15:33
Location: Spain

Re: Storage of different adjustments

Postby Florian041190 » 12 June 2015, 10:28

Everything works fine now.
Thank you very much!

Best wish
Florian
Florian041190
 
Posts: 6
Joined: 02 June 2015, 08:37

Re: Storage of different adjustments

Postby jasper » 12 June 2015, 11:14

Glad to hear it. Which solution did you pick?
User avatar
jasper
 
Posts: 1128
Joined: 24 October 2012, 15:33
Location: Spain

Re: Storage of different adjustments

Postby Florian041190 » 15 June 2015, 09:50

I took 2 excel units and connected them with a information stream and a measure unit.
Florian041190
 
Posts: 6
Joined: 02 June 2015, 08:37

Re: Storage of different adjustments

Postby jasper » 15 June 2015, 11:18

Nice.
User avatar
jasper
 
Posts: 1128
Joined: 24 October 2012, 15:33
Location: Spain


Return to COCO (AmsterCHEM)

Who is online

Users browsing this forum: No registered users and 17 guests