File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -684,11 +684,14 @@ def _repr_latex_(self) -> str:
684684 random_symbols = [symbol for symbol in profit_function .free_symbols if is_random (symbol )]
685685
686686 if random_symbols :
687- random_symbol = random_symbols [0 ]
688- h = sympy .Function ('h' )(random_symbol )
689- integrand = profit_function * h
690- lower_bound , upper_bound = pspace (random_symbol ).domain .set .args [:2 ]
691- integral = sympy .Integral (integrand , (random_symbol , lower_bound , upper_bound ))
687+ integrand = profit_function
688+ for random_symbol in random_symbols :
689+ integrand *= density (random_symbol ).pdf (random_symbol )
690+ integral = integrand
691+ for random_symbol in random_symbols :
692+ lower_bound , upper_bound = pspace (random_symbol ).domain .set .args [:2 ]
693+ integral = sympy .Integral (integral , (random_symbol , lower_bound , upper_bound ))
694+
692695 s = latex (integral , mode = 'plain' , order = None )
693696 else :
694697 s = latex (profit_function , mode = 'plain' , order = None )
You can’t perform that action at this time.
0 commit comments