22 #include "common_sys.hh"
27 #include "parseaut/public.hh"
29 #include "twaalgos/stats.hh"
30 #include "twaalgos/sccinfo.hh"
31 #include "twaalgos/gtec/gtec.hh"
32 #include "twaalgos/reducerun.hh"
33 #include "twaalgos/word.hh"
34 #include "twaalgos/isdet.hh"
35 #include "common_file.hh"
39 enum automaton_format_t {
50 extern automaton_format_t automaton_format;
52 extern const char* opt_name;
54 extern const struct argp aoutput_argp;
57 extern char F_doc[32];
58 extern char L_doc[32];
61 extern const struct argp aoutput_io_format_argp;
62 extern const struct argp aoutput_o_format_argp;
65 int parse_opt_aoutput(
int key,
char* arg,
struct argp_state* state);
68 enum stat_style { no_input, aut_input, ltl_input };
79 stat_style input = no_input)
82 if (input == aut_input)
94 if (input != ltl_input)
108 print(
const spot::const_parsed_aut_ptr& haut,
109 const spot::const_twa_graph_ptr& aut,
111 const char* filename,
int loc,
double run_time)
113 filename_ = filename ? filename :
"";
114 if (loc >= 0 &&
has(
'L'))
116 std::ostringstream os;
118 location_ = os.str();
122 if (loc < 0 &&
has(
'L'))
124 std::ostringstream os;
126 location_ = os.str();
132 haut_states_ = s.states;
133 haut_edges_ = s.transitions;
134 haut_trans_ = s.sub_transitions;
139 haut_states_ = s.states;
140 haut_edges_ = s.transitions;
144 auto n = haut->aut->get_named_prop<std::string>(
"automaton-name");
148 haut_name_.val().clear();
151 haut_states_ = haut->aut->num_states();
154 haut_acc_ = haut->aut->acc().num_sets();
161 std::ostringstream os;
162 os << haut->aut->get_acceptance();
163 haut_gen_acc_ = os.str();
169 auto n = aut->get_named_prop<std::string>(
"automaton-name");
173 aut_name_.val().clear();
180 auto run = res->accepting_run();
185 std::ostringstream out;
186 w.print(out, aut->get_dict());
187 aut_word_ = out.str();
191 aut_word_.val().clear();
216 std::ostringstream name;
218 std::ostringstream outputname;
220 std::map<std::string, std::unique_ptr<output_file>> outputfiles;
227 print(
const spot::twa_graph_ptr& aut,
230 const char* filename =
nullptr,
234 const spot::const_parsed_aut_ptr& haut =
nullptr);
An infinite word stored as a lasso.
Definition: word.hh:29
Definition: sccinfo.hh:27
tgba_sub_statistics sub_stats_reachable(const const_twa_ptr &g)
Compute sub statistics for an automaton.
std::ostream & print(const const_twa_graph_ptr &aut, formula f=nullptr, double run_time=-1.)
print the configured statistics.
emptiness_check_ptr couvreur99(const const_twa_ptr &a, option_map options=option_map())
Check whether the language of an automate is empty.
prints various statistics about a TGBA
Definition: stats.hh:77
Definition: formater.hh:29
std::ostream & print(const spot::const_parsed_aut_ptr &haut, const spot::const_twa_graph_ptr &aut, spot::formula f, const char *filename, int loc, double run_time)
print the configured statistics.
Definition: common_aoutput.hh:108
prints various statistics about a TGBA
Definition: common_aoutput.hh:75
tgba_run_ptr reduce_run(const const_twa_ptr &a, const const_tgba_run_ptr &org)
Reduce an accepting run.
Definition: common_aoutput.hh:213