PYroMat icon indicating copy to clipboard operation
PYroMat copied to clipboard

Create a state class

Open chmarti1 opened this issue 2 years ago • 2 comments

This was originally posted by @DanielSarmiento04 as a comment in #77. I've re-posted it here because it's an interesting idea.

         I have been using the library for the past few months in parallel to a thermodynamics course

I like the piromat ecosystem

I made this repository when I used for solve Brayton, Rankine and >combine Cicle, these example you can use for tutorials.

Another suggestion that I found is the next

  • Simply code Normally, for optimize time processed and debugger I use
    state_x = 'fluid'.state('propierties')

this return a dictionary and for mapping the information we have to use .get dictionary method h_x = state_x.get('h') something to improve is use the status type objects

  • Example
class State(object):
  h
  s
  T
  v
 # Some propierties

and then use h_x = state_x.h

Originally posted by @DanielSarmiento04 in https://github.com/chmarti1/PYroMat/issues/77#issuecomment-1397545933

chmarti1 avatar Jan 20 '23 14:01 chmarti1