comando.interfaces.baron module
Input file generation for BARON.
- class comando.interfaces.baron.BaronParser(sym_map)[source]
Bases:
StrParser
A class for parsing comando expressions to baron Syntax.
- comando.interfaces.baron.apply_cse(P, var_map)[source]
Replace reoccurring expressions with variables.
- comando.interfaces.baron.baron_pow_callback(parser, expr, idx)[source]
Handle special pow calls in BARON.
- comando.interfaces.baron.con_name(n=1, i=None)
Generate n unused names of the form {prefix}{i} starting from i.
- comando.interfaces.baron.constraints_section(con_map, rel_only_cons, convex_cons, parse)[source]
Write the (RELAXATION_ONLY/CONVEX) EQUATIONS sections.
- comando.interfaces.baron.discretize(P, sym_map)[source]
Discretize differential equations in P using implicit Euler.
- comando.interfaces.baron.get_results(results_file_name='res.lst')[source]
Code for parsing baron results files.
- comando.interfaces.baron.get_times_and_bounds(baron_log_file)[source]
Code for parsing baron logs for time, and bounds.
- comando.interfaces.baron.handle_tanh(expr, tanh_definitions, var_map)[source]
Search the expression for occurrences of tanh and substitute them.
- comando.interfaces.baron.normalize(con)[source]
Bring constraints to a normal form baron can handle.
- comando.interfaces.baron.solve(P, file_name=None, silent=False, cse=False, reuse=None, **options)[source]
Solve the problem specified in the input_file with baron.
- comando.interfaces.baron.var_name(n=1, i=None)
Generate n unused names of the form {prefix}{i} starting from i.