<s> r"""<STR_LIT>""" <EOL> import scipy as _sp <EOL> def linear ( phase , m , b , poreprop , ** kwargs ) : <EOL> r"""<STR_LIT>""" <EOL> T = phase [ poreprop ] <EOL> value = b + m * T <EOL> return value <EOL> def polynomial ( phase , a , poreprop , ** kwargs ) : <EOL> r"""<STR_LIT>""" <EOL> x = phase [ poreprop ] <EOL> value = <NUM_LIT:0.0> <EOL> for i in range ( <NUM_LIT:0> , len ( a ) ) : <EOL> value += a [ i ] * x ** i <EOL> return value <EOL> def ideal_mixture ( phase , poreprop , <EOL> composition = '<STR_LIT>' , <EOL> ** kwargs ) : <EOL> r"""<STR_LIT>""" <EOL> value = _sp . zeros ( ( phase . Np , ) ) <EOL> for comp in phase . _phases : <EOL> value = value + comp [ poreprop ] * comp [ composition ] <EOL> return value <EOL> def mixture_value ( phase , propname , ** kwargs ) : <EOL> r"""<STR_LIT>""" <EOL> mixture = phase . _phases [ <NUM_LIT:0> ] <EOL> vals = mixture [ propname ] <EOL> return vals </s>
