[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
[phpBB Debug] PHP Warning: in file [ROOT]/includes/bbcode.php on line 112: preg_replace(): The /e modifier is no longer supported, use preg_replace_callback instead
CAPE-OPEN • View topic - Calculate following Validate

Calculate following Validate

Discusses use of CAPE-OPEN interfaces in DWSIM, an open-source piece of sofware developed by Daniel WAGNER.

Moderator: DanW

Calculate following Validate

Postby greTol » 20 October 2017, 13:22

Attachments
DWSIM_error_not_validated.png
error: unit has not been validated
DWSIM_error_not_validated.png (79.96 KiB) Viewed 12089 times
Last edited by greTol on 23 October 2017, 12:42, edited 2 times in total.
greTol
 
Posts: 20
Joined: 26 August 2013, 14:45

Re: Calculate following Validate

Postby jasper » 21 October 2017, 09:56

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

Re: Calculate following Validate

Postby greTol » 30 November 2017, 15:52

This discussion continued in the DWSIM forum
(https://sourceforge.net/p/dwsim/discuss ... /3682f2f1/).
Here are my conclusions:

In the DWSIM socket we have/had
1) Validate()
2) RestorePorts() -> this invalidates the unit operation, because the "portConnectionChanged" event is fired and we cannot gurantee that the state is still valid.
3) Calculate() -> check for validation fails

The CO interface specification for Unit Operations (CO_Unit_Operations_v6.25) says, regarding 'Validate':
"However, Validate must be called before Calculate in case any (one or more) changes to the following
configuration aspects of the Unit Operation have changed since the last call to Calculate:
• ...
• connecting an object to a port
• disconnecting an object from a port
• ... "

So calling Validate() after RestorePorts() is fix to this particular problem.
greTol
 
Posts: 20
Joined: 26 August 2013, 14:45


Return to DWSIM

Who is online

Users browsing this forum: No registered users and 2 guests

cron