|
|
@ -235,18 +235,10 @@ storm_rational_number_ptr storm_rational_number_mod(storm_rational_number_ptr a, |
|
|
|
} |
|
|
|
|
|
|
|
storm_rational_number_ptr storm_rational_number_min(storm_rational_number_ptr a, storm_rational_number_ptr b) { |
|
|
|
#ifndef RATIONAL_NUMBER_THREAD_SAFE
|
|
|
|
std::lock_guard<std::mutex> lock(rationalNumberMutex); |
|
|
|
#endif
|
|
|
|
|
|
|
|
return storm_rational_number_less_or_equal(a, b) ? storm_rational_number_clone(a) : storm_rational_number_clone(b); |
|
|
|
} |
|
|
|
|
|
|
|
storm_rational_number_ptr storm_rational_number_max(storm_rational_number_ptr a, storm_rational_number_ptr b) { |
|
|
|
#ifndef RATIONAL_NUMBER_THREAD_SAFE
|
|
|
|
std::lock_guard<std::mutex> lock(rationalNumberMutex); |
|
|
|
#endif
|
|
|
|
|
|
|
|
return storm_rational_number_less(a, b) ? storm_rational_number_clone(b) : storm_rational_number_clone(a); |
|
|
|
} |
|
|
|
|
|
|
@ -580,27 +572,11 @@ storm_rational_function_ptr storm_rational_function_mod(storm_rational_function_ |
|
|
|
} |
|
|
|
|
|
|
|
storm_rational_function_ptr storm_rational_function_min(storm_rational_function_ptr a, storm_rational_function_ptr b) { |
|
|
|
#ifndef RATIONAL_FUNCTION_THREAD_SAFE
|
|
|
|
std::lock_guard<std::mutex> lock(rationalFunctionMutex); |
|
|
|
#endif
|
|
|
|
|
|
|
|
if (storm_rational_function_less_or_equal(a, b)) { |
|
|
|
return storm_rational_function_clone(a); |
|
|
|
} else { |
|
|
|
return storm_rational_function_clone(b); |
|
|
|
} |
|
|
|
return storm_rational_function_less_or_equal(a, b) ? storm_rational_function_clone(a) : storm_rational_function_clone(b); |
|
|
|
} |
|
|
|
|
|
|
|
storm_rational_function_ptr storm_rational_function_max(storm_rational_function_ptr a, storm_rational_function_ptr b) { |
|
|
|
#ifndef RATIONAL_FUNCTION_THREAD_SAFE
|
|
|
|
std::lock_guard<std::mutex> lock(rationalFunctionMutex); |
|
|
|
#endif
|
|
|
|
|
|
|
|
if (storm_rational_function_less(a, b)) { |
|
|
|
return storm_rational_function_clone(b); |
|
|
|
} else { |
|
|
|
return storm_rational_function_clone(a); |
|
|
|
} |
|
|
|
return storm_rational_function_less(a, b) ? storm_rational_function_clone(b) : storm_rational_function_clone(a); |
|
|
|
} |
|
|
|
|
|
|
|
int storm_rational_function_less(storm_rational_function_ptr a, storm_rational_function_ptr b) { |
|
|
|