|
From: <mar...@di...> - 2018-01-05 13:25:37
|
Hi Arpit and everyone, how about trying to implement the UNIFAC and PSRK models to Ascend?: http://ascend4.org/Predictive_Soave-Redlich-Kwong_(PSRK) http://ascend4.org/Modified_UNIFAC_(Dortmund) I have a Python script for the modified UNIFAC model which I can send to you. But the first step would be to store all the needed parameters. To quote John from Ascend-sim-users Digest, Vol 34, Issue 1 (https://sourceforge.net/p/ascend-sim/mailman/message/34712639/): "You may have noticed the 'helmholtz_prepare' and 'pengrob_prepare' functions. These are for converting the 'filedata' datastructures (which could in principle be stored in data files rather than C structs_ and the 'rundata' data structures. These data structures are deliberately separated by design, so that pre-calculation can be done if needed. This is what we have done recently with the TTSE code (which is 90% complete, still needs some tweaks, it's in Sidharth's branch)." Take a look at http://code.ascend4.org/ascend/branches/sid/models/johnpye/fprops/helmholtz.c?diff_format=h&revision=2982&view=markup&pathrev=2982 and at http://ascend4.org/User:Sidharth So it would actually be nice to find a general way to store data for Ascend, be it as a SQLite database or XML data files with a graphical interface for users to add data. Quote from John: "Regarding the properties database, I should mention that Richard Towers did a bit of work on implementing XML storage for fluid properties. We didn't complete the integration work, but there's some interesting stuff there, including the ability to render the XML to HTML using XSD, for easy human-readable checking/review of correlation data that has been entered. Some kind of editable data file is good for people wanting to add new species, but at the same time, it adds some parsing overhead to the codebase compared to the current approach of declaring C99 data structures." See: http://ascend4.org/User:RichardTowers So either just convert all the data from appendix B in the following publication to C data structs: http://dx.doi.org/10.1016/j.fluid.2004.11.002 or try to go for a more elaborate way of storing the data as described above. When the whole database system is set up one could start implementing linear algebra routines for property calculations which are needed for e.g. UNIFAC and PSRK. ASCEND only has code covering the matrix routines needed for solving the system of equations of the model a user has implemented: "I don't think that reusing the ASCEND matrix routines is the necessarily the way to go for property calcs." So basically convert the Python script I then will send you to C and access the database and perform the matrix inversion and matrix multiplication with LAPACK/CBLAS. And finally embed the routine in ASCEND so that users can call UNIFAC/PSRK within ASCEND. Hope this was of any help or inspiration. ;) Cheers, mark On 2018-01-05 13:07, asc...@li... wrote: > Send Ascend-sim-users mailing list submissions to > asc...@li... > > To subscribe or unsubscribe via the World Wide Web, visit > https://lists.sourceforge.net/lists/listinfo/ascend-sim-users > or, via email, send a message with subject or body 'help' to > asc...@li... > > You can reach the person managing the list at > asc...@li... > > When replying, please edit your Subject line so it is more specific > than "Re: Contents of Ascend-sim-users digest..." > > > Today's Topics: > > 1. help to contribute (Arpit Thool) > > > ---------------------------------------------------------------------- > > Message: 1 > Date: Fri, 5 Jan 2018 01:12:44 +0530 > From: Arpit Thool <arp...@gm...> > To: asc...@li... > Subject: [ASCEND] help to contribute > Message-ID: > <CAC...@ma...> > Content-Type: text/plain; charset="utf-8" > > how can i contribute ? i am good at maths and am currently pursuing my > engineering degree in the field of computer science. > -------------- next part -------------- > An HTML attachment was scrubbed... > > ------------------------------ > > ------------------------------------------------------------------------------ > Check out the vibrant tech community on one of the world's most > engaging tech sites, Slashdot.org! http://sdm.link/slashdot > > ------------------------------ > > Subject: Digest Footer > > _______________________________________________ > Ascend-sim-users mailing list > Asc...@li... > https://lists.sourceforge.net/lists/listinfo/ascend-sim-users > > > ------------------------------ > > End of Ascend-sim-users Digest, Vol 44, Issue 1 > *********************************************** |