Constructing Stereo Images of Error Surfaces in Problems of Numerical Methods Verification

. The tasks of constructing stereo representations of texts and formulas on an autostereoscopic monitor in stereo presentations designed to display the results of numerical modeling are an urgent sub-task in developing methods and algorithms for constructing stereo displays of scientific research results. In this paper, the construction of stereo images on an autostereoscopic monitor is considered. The autostereoscopic monitor allows you to watch stereo images without glasses, while ensuring the quality of the stereo image, which is not inferior to the quality of the stereo image presented using the classic 3D projection stereo system. The possibility of combining several stereo objects with different parameters on one frame with various parameters allowing to achieve the maximum stereo effect is being investigated. This technology has been applied practically to visualize the problems of verification of numerical methods and their comparative analysis. Similar solutions for the two-parameter problem are represented in the form of error surfaces constructed for each numerical method involved in the comparison. The construction of error surfaces in stereo mode is implemented for an autostereoscopic monitor based on a multi-view.


Introduction
To date, stereo animation begins to play an important role in displaying the obtained scientific results in various applied scientific research and industries.This is largely due to the fact that a situation often arises when a flat image of an object does not have the entirety of information to achieve its goals and limits the analysis to a schematic image or a truncated viewing angle.Unlike a two-dimensional flat image, three-dimensional stereo allows you to more effectively explore and model objects with a developed spatial structure or interpret photographs taken during the experiment from different angles at given times and combined into animation.
A lot of works has been devoted to this topic.They discuss methods for constructing images for various types of stereo devices, both passive and active types.The difference between these concepts is that passive ones allow one or another material to be demonstrated according to a predetermined scenario, however, the viewer is not able to influence the display process.Active (or interactive) installations mean that the viewer has the opportunity to work with the demonstration material and directly influence the demonstration process.General aspects of image construction for various types of stereo units are presented in [1].
The specific problems that arise when using a computer system to generate and visualize a composite multi-screen stereo frame, and methods for solving such problems are described in sufficient detail in [1][2][3].
The gradual spread of modern stereo systems has generated great interest in the development of practical algorithms for stereo presentation of static and animated images, which is reflected in [4,[5][6][7][8][9][10][15][16][17].These works present the tasks of constructing stereo images in various fields of research: from the explosion of a Supernova to the processes of oil displacement from porous media.
The spread of stereo animations and virtual reality also revealed a rather important particular structural subproblem.The standard procedure for a report, presentation of something or a virtual walk implies the presence of not only a visual type of information in them, but also a symbolic one -letters, numbers, symbols, metric quantities, names, numbers, Federal Standards, without which the perception and assimilation of information by the viewer is significantly complicated.
The problems of constructing stereo images for geometries and fields of physical quantities have been developed in sufficient detail, but quite a few works have been devoted to the development of specific practical approaches and algorithms for constructing stereo representations of texts and formulas with sufficient expressiveness and the necessary stereo effect.One of them, which cannot be ignored, is the work [11] describing a study conducted in Japan of the perception of stereo images of fonts on the screens of stereoscopic mobile devices.
This work is a continuation of a series of research papers [1][2][3]7,[12][13][14]18,19] conducted at the Keldysh Institute of Applied Mathematics RAS based on the available stereo units of two types.
The first type of device is a 3D projection stereo system for displaying stereo presentations, educational applications, graphics and films.It is an example of a classical stereoscopic system using two projectors, a screen and linear polarization glasses.Studies [12][13] describe in detail studies on the presentation of textual information on this type of stereo unit using a linear stereo base.In these works, test inscriptions were constructed with variations of the font, background, font embossment, the whole angle of rotation of the inscription, and shift along the linear stereo base.
The parameters that provided the maximum effect were found and the basic requirements for the fonts used and a number of conditions were identified, the satisfaction of which is necessary to achieve the optimal result.
The second type of device is a Dimenco DM654MAS autostereoscopic monitor.Autostereoscopic monitors provide stereo images without having to track the position of the observer.Typically, such monitors make it possible to observe stereo images, providing several fixed segments in the space for observation.The viewer can move between segments, getting the opportunity to view the displayed object in 3D from different angles.The principle of operation of the autostereoscopic monitor is the use of parallax partitions or Fresnel lenses installed behind the protective glass of the screen, which gives it one of the most important advantages: displaying the image does not require special glasses or other devices from the viewer.
An autostereoscopic monitor is capable of demonstrating a visualization object using two methods: either using a composite frame containing views of the visualization object at different angles that form a certain viewing sector -this is called a multiview, or using depth maps.
In multi-view image construction, nine frames are combined into one image according to the principle of a 3 × 3 matrix.In the first and last (ninth) frames, the desired object, for example, the inscription is in its extreme positions, and in the intermediate frames it is rotated sequentially by a given angle.
After solving the problem of creating stereo texts on their own, as separate frames in a stereo presentation or stereo animation, another important sub-task was identified: combining images and text information in one frame.This problem is described in [18] in detail.The developed methods and approaches for constructing stereo images made it possible to apply them to the construction of error surfaces for the analysis of the comparative accuracy of OpenFOAM solvers for the oblique shock wave problem with variation of the Mach number and angle of attack.To build stereo images, a multi-view method was used on an autostereoscopic monitor.

2
The construction of stereo images on an autostereoscopic monitor using multi-view method An autostereoscopic monitor has the ability to demonstrate a visualization object using a composite frame containing views of the visualization object at different angles, which together form a certain viewing sector.Usually, these are nine views.These nine views form eight stereopairs [8 | 9]), however, the viewer can observe only one of the stereopairs in one position, depending on the location in defined angular sector of observation.When the observer moves from sector to sector, he receives information about the object using all nine views, that is, as if looking at the visualization object from different angles.
When building a multi-view stereo image, nine frames are combined into one image according to the principle of a 3 × 3 matrix.In the first and last (ninth) frames, the represented object is in its extreme positions.In the first frame, the object is in its rightmost position, and in the last frame, in the leftmost position.Then in the middle frames, respectively, from the second to the eighth, with certain equal intervals, it moves to the left until it reaches the extreme left position.In this case, in each frame, the object is progressively rotated by the same angle and shifted by a predetermined interval.This allows you to achieve the most effective result when creating a stereo image of the object.

Methods of combining image and text information
After solving the problem of creating stereo labels on their own, as separate frames in a stereo presentation or stereo film, an equally important sub-task arises -combining the image and text information in one frame.Currently, in the case of demonstration of scientific results to observers, very many objects require accompanying information located directly on the same frame as the image.In many cases, the signature and the object cannot be separated into different frames, since they make up a single logical display of information.For example, when depicting a coordinate system, one cannot fail to mark a designation for each of the coordinates.An example is Fig. 1.This figure is not informative, like a graph, because it does not carry accurate data and is not bound to coordinates.This is a simple three-dimensional model, which is a schematic three-dimensional graph.
Fig. 1.Three-dimensional model of the coordinate system in volume.
The constructed nine-view image gave a stereo effect, which was recognized by observers as satisfactory.However, the presented figure does not carry an informative load, since it is not accompanied by the necessary additional information, and the viewer does not even have an idea about the coordinate system.Fig. 2 shows a more complete image.The coordinates are signed on it, and the letters indicating the coordinates also provide a stereo effect.Fig. 2. Three-dimensional model of the coordinate system in volume with signed coordinates.
To construct this stereo image, an image matrix was used (Fig. 2), to which volume letters were added and sequentially shifted and rotated on each frame by the same interval experimentally calculated earlier.As a result, a stereo image with a volume signature was obtained, the stereo effect of which was pronounced.Along with this, an additional effect was revealed when the viewer from different positions saw that the letters are on different planes each time.For example, the location of the letter Z was perceived by observers either behind the horizontal axis or in front of it, depending on the viewer's location in a particular observation sector in front of the screen of the autostereoscopic monitor.
Fig. 3 shows one of the results of previous studies -a multi-view image of the simulation results of a supersonic flow around a cone at an angle of attack with the corresponding inscription [18].The task was to combine in one stereo image the objects of different depths and sizes and text information (in this case, the cone and the inscription at the figure).Here the image of the simulated cone and separately the inscriptions to it are combined.Each of them is rotated by its own experimentally revealed angle and is shifted by a certain distance, also different.As shown in the figure, a matrix of images is further compiled, which in turn comprise a single stereo image.In the end, the inscription was located on top of the cone, but behind its tip, which in turn was perceived by observers as protruding from the screen by several centimeters.Fig. 3. Image of the simulation results of a supersonic flow around a cone with the corresponding signature [18].
A similar problem was posed for constructing stereo mappings of error surfaces with corresponding inscriptions.

4
The construction of stereo for the problems of comparing the accuracy of numerical methods Stereoimaging is a useful and effective tool for deep understanding and presentation of the results of solving mathematical modeling problems.Construction of stereo images for comparative verification of numerical methods turned out to be a very effective visualization tool.In order to assess the accuracy of the numerical method for a specific problem, it is necessary to compare the numerical results with the reference solution (exact, calculated or experimental solution).The visual representation of the numerical calculation error allows for a comprehensive comparative assessment of numerical methods.In the absence of a reference solution, a certain estimate of the accuracy can be carried out on the basis of an ensemble of numerical solutions obtained using several independent numerical methods.Similar numerical solutions are presented in [19][20][21].
Below we present examples of constructed stereoimages for the presentation of the calculation results for the comparative assessment of the accuracy of numerical methods [19][20][21].
The first example presents the results of constructing error surfaces for oblique shock wave problem.These results are presented for four OpenFOAM solvers with variations in the Mach number from 2 to 4 and variations in the angle of attack from 6 to 20 degrees [19].It should be noted that error surfaces for the class of problems of the numerical methods accuracy comparative analysis were constructed in [19] for the first time.The left part of Fig. 4 shows four error surfaces for four OpenFOAM solvers -rhoCentralFoam (rCF), pisoCentralFoam (pCF), sonicFoam (sF) and QGDFoam (QGDF) with the corresponding text labels and notations.To construct a single stereo image, the same techniques were used as in [18] for the image of the cone.The constructed multi-view image is displayed on the right side of Fig. 4.    The next example of stereo image is constructed for the results, described in [21].In this research the authors used advantage of the ensemble of numerical solutions obtained by independent numerical algorithms.To obtain the approximation error, the differences between numerical solutions are treated in the frame of the Inverse Problem that is posed in the variational statement with the zero order regularization.In this work the authors [21] analyse the ensemble of numerical results that is obtained by five OpenFOAM solvers for the inviscid compressible flow around a cone at zero angle of attack.Fig. 6 presents the exact error of the pressure for the flowfield, computed by rCF.Fig. 7 presents the error of the pressure estimated by the Inverse Problem for the same flowfield.
For both cases the stereo images were created.Stereoimaging allows the researchers to study the internal structures of error in the flowfield in question.
The results obtained allow us to conclude that the previously developed technology for constructing stereoscopic presentations of the results of numerical studies can be used with benefit in problems of comparative assessment of the accuracy of numerical methods.

Conclusion
This work is a continuation of a works series devoted to the implementation of the project to build stereo presentations of the results solving mathematical modeling problems.The results of numerical experiments on the presentation of textual information on an autostereoscopic monitor that allows the construction of stereo images using depth and multi-view maps are presented.The problem of combining images and textual information in one frame for a multi-view presentation is considered.As a result of practical experiments, the most clear and expressive stereo effect was achieved.
The construction of stereo frames is carried out in the previously developed mode of combining in one stereo frame the main object of the visualization and the corresponding text labels and symbols.The constructed stereo frames provide the researcher with the possibility of a deep and thorough visual analysis of the results.

Fig. 4 .
Fig. 4. Image of the surface deviation from the exact solution for four OpenFOAM solvers with variation of the Mach number and angle of attack for the oblique shock wave problem.

Fig. 4
Fig.4shows that the best accuracy in the class of problems is provided by the rCF and pCF solvers, for which the error surfaces almost coincide.The developed technology allows one to create stereo images for these surfaces separately.The results are presented in Fig.5.

Fig. 5 .
Fig. 5. Image of error surface comparison for pCF and rCF solvers.

Fig. 5
Fig.5shows that the divergence of error surfaces is most pronounced for the smallest Mach number and the largest angle of attack.The constructed stereo image allows the researcher to thoroughly study the accuracy properties of solvers not on one single problem, but on the class of problems defined by the ranges of variation of the defining parameters (Mach number and angle of attack).The next example of stereo image is constructed for the results, described in[21].In this research the authors used advantage of the ensemble of numerical solutions obtained by independent numerical algorithms.To obtain the approximation error, the differences between numerical solutions are treated in the frame of the Inverse Problem that is posed in the variational statement with the zero order regularization.In this work the authors[21] analyse the ensemble of numerical results that is obtained by five OpenFOAM solvers for the inviscid compressible flow around a cone at zero angle of attack.Fig.6presents the exact error of the pressure for the flowfield, computed by rCF.Fig.7presents the error of the pressure estimated by the Inverse Problem for the same flowfield.For both cases the stereo images were created.Stereoimaging allows the researchers to study the internal structures of error in the flowfield in question.The results obtained allow us to conclude that the previously developed technology for constructing stereoscopic presentations of the results of numerical studies can be used with benefit in problems of comparative assessment of the accuracy of numerical methods.

Fig. 6 .
Fig. 6.The exact error of the pressure (for the flowfield, computed by rCF).

Fig. 7 .
Fig. 7.The error of the pressure estimated by the Inverse Problem (for the flowfield, computed by rCF).