27 | | mat R1 ( "0.5 0.48; 0.48 0.5" ); |
28 | | mat R2 ( "0.5 0; 0 0.1" ); |
29 | | f1->set_parameters ( "1 1", R1 ); |
30 | | f2->set_parameters ( "1 1", mat ( "0.5 0; 0 0.1" ) ); |
| 27 | mat R1 ( "0.5 0.48; 0.48 0.5" ); |
| 28 | mat R2 ( "0.5 0; 0 0.1" ); |
| 29 | f1->set_parameters ( "1 1", R1 ); |
| 30 | f2->set_parameters ( "1 1", mat ( "0.5 0; 0 0.1" ) ); |
36 | | int Npoints = 100; |
37 | | mat x_grid ( 1, Npoints ); |
38 | | x_grid.set_row ( 0, linspace ( -2.0, 4.0, Npoints ) ); |
39 | | mat y_grid ( 1, Npoints ); |
40 | | y_grid.set_row ( 0, linspace ( -2.0, 4.0, Npoints ) ); |
| 36 | int Npoints = 100; |
| 37 | mat x_grid ( 1, Npoints ); |
| 38 | x_grid.set_row ( 0, linspace ( -2.0, 4.0, Npoints ) ); |
| 39 | mat y_grid ( 1, Npoints ); |
| 40 | y_grid.set_row ( 0, linspace ( -2.0, 4.0, Npoints ) ); |
42 | | mat Grid ( 2, Npoints*Npoints ); |
43 | | Grid.set_submatrix ( 0, 0, kron ( x_grid, ones ( 1, Npoints ) ) ); |
44 | | Grid.set_submatrix ( 1, 0, kron ( ones ( 1, Npoints ), y_grid ) ); |
| 42 | mat Grid ( 2, Npoints*Npoints ); |
| 43 | Grid.set_submatrix ( 0, 0, kron ( x_grid, ones ( 1, Npoints ) ) ); |
| 44 | Grid.set_submatrix ( 1, 0, kron ( ones ( 1, Npoints ), y_grid ) ); |
62 | | it_file it ( "merger_2d_test.it" ); |
63 | | it << Name ( "Npoints" ) << Npoints; |
64 | | it << Name ( "Grid" ) << Grid; |
65 | | it << Name ( "Res1" ) << Res1; |
66 | | it << Name ( "Res2" ) << Res2; |
67 | | it << Name ( "S1" ) << f1->evallog_mat ( Grid ); |
68 | | it << Name ( "S2" ) << f2->evallog_mat ( Grid ); |
| 62 | it_file it ( "merger_2d_test.it" ); |
| 63 | it << Name ( "Npoints" ) << Npoints; |
| 64 | it << Name ( "Grid" ) << Grid; |
| 65 | it << Name ( "Res1" ) << Res1; |
| 66 | it << Name ( "Res2" ) << Res2; |
| 67 | it << Name ( "S1" ) << f1->evallog_mat ( Grid ); |
| 68 | it << Name ( "S2" ) << f2->evallog_mat ( Grid ); |