MCPcopy Create free account
hub / github.com/QuEST-Kit/QuEST / demo_getInlineCompMatr

Function demo_getInlineCompMatr

examples/isolated/initialising_matrices.cpp:35–49  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33
34
35void demo_getInlineCompMatr() {
36
37 // inline literal; identical to getCompMatr1() for consistencty with C API
38 CompMatr1 a = getInlineCompMatr1( {{1,2_i},{3_i+.1,-4}} );
39 reportCompMatr1(a);
40
41 // we must specify all elements (only necessary in C++), else runtime validation triggered
42 CompMatr2 b = getInlineCompMatr2({
43 {1, 2, 3, 4},
44 {5, 6, 8, 8},
45 {5, 7, 6, 1},
46 {4, 4, 3, 3}
47 });
48 reportCompMatr2(b);
49}
50
51
52void demo_getCompMatr() {

Callers 1

mainFunction · 0.70

Calls 2

reportCompMatr1Function · 0.85
reportCompMatr2Function · 0.85

Tested by

no test coverage detected