op_ex_mc.cpp
Go to the documentation of this file.
1/** @file op_ex_mc.cpp
2
3Tutorial to demonstarte the verification of mutual controllability.
4
5@ingroup Tutorials
6
7*/
8
9
10#include <stdio.h>
11#include <iostream>
12#include "libfaudes.h"
13
14
15// make libFAUDES namespace available
16using namespace faudes;
17
18
19int main(int argc, char* argv[]) {
20
21 // read two generators from file input
22 System gen1("./data/ex_mc/ex_mc1.gen");
23 System gen2("./data/ex_mc/ex_mc2.gen");
24
25 // Verify mutual controllability of gen1 and gen2. In this case, mutual controllabiity is violated.
26 bool mc = IsMutuallyControllable(gen1,gen2);
27 std::cout << "#################################################\n";
28 std::cout << "# Mutual controllability verification - result: " << mc << std::endl;
29 std::cout << "#################################################\n";
30
31 // read one further generator from file input
32 System gen3("./data/ex_mc/ex_mc3.gen");
33 // Verify mutual controllability of gen3 and gen2. In this case, mutual controllability holds.
34 mc = IsMutuallyControllable(gen3,gen2);
35 std::cout << "##################################################\n";
36 std::cout << "# Mutual controllability verification - result: " << mc << std::endl;
37 std::cout << "##################################################\n";
38
39
40 return 0;
41}
int main()
bool IsMutuallyControllable(const System &rGen1, const System &rGen2)
Definition op_mc.cpp:32

libFAUDES 2.33k --- 2025.09.16 --- c++ api documentaion by doxygen