Explore chapters and articles related to this topic
Building the Simulation in Simio
Published in Andrew Greasley, Simulation Modelling, 2023
The ribbon across the top of the screen has a number of screen tabs that collect together commands into logical groups. Screen tabs are included for run commands and view options. Below the ribbon, there is a further series of tabs called the Project Model Tabs that are used to select options regarding the active model. If the Facility tab is selected as in figure 7B.1, then to the left of the screen the object library is displayed. By default, the screen will display the Standard Library and, at the bottom of the screen, the Project Library. The Properties Window is on the right-hand side of the screen and shows the characteristics of any object or item currently selected. The main area of the screen (with grid) is named the Navigation Window. Objects are placed from an Object Library onto the Navigation Window and are defined/edited from the Navigation Window in the Properties Window. To move around the Navigation Window, hold down the left mouse button and move the mouse. To zoom in and out of the Navigation Window, hold down the right mouse button and move the mouse.
War of Control Hijacking
Published in Uzzal Sharma, Parmanand Astya, Anupam Baliyan, Salah-ddine Krit, Vishal Jain, Mohammad Zubair Khan, Advancing Computational Intelligence Techniques for Security Systems Design, 2023
Ragini Karwayun, Monika Sainger
The basic idea behind libsafe is to exchange vulnerable functions with safer alternatives. In the first step, libsafe first checks the safety of the called function. After it ensures that the function can be safely called. If yes, then it either calls the original function or executes functionally equivalent code. Otherwise, it displays warnings and terminates the process. As libsafe is incorporated as a shared library that is loaded into memory, it is able to replace its alternatives in place of the original functions. For Linux systems, the responsibility of loading the various program code and libraries into the memory is performed by the runtime loader. If libsafe is activated, the libsafe library is loaded into memory prior to the standard library. As the alternative libsafe functions have the same names as the original functions, the loader replaces the standard library functions with the libsafe functions. First, a safety check is done by most of the libsafe functions and then either the original function or a safer alternative is called. (e.g., snprintf()is called in place ofsprintf()) [24].
Introduction
Published in Randall L. Eubank, Ana Kupresanin, Statistical Computing in C++ and R, 2011
Randall L. Eubank, Ana Kupresanin
One of the proposed extensions to the C++ standard library is the implementation of several template classes for the generation of pseudo-random numbers. At a high level, there are two kinds of classes: engines and distributions. An engine basically describes a random number generator (see Chapter 4) that produces pseudo-random integers that are intended to be uniformly distributed over the length of its period. They come in two varieties: a basic engine provides an implementation of a specific generator, while a compound engine either modifies a basic engine, or combines two of them into a single generator. A distribution transforms a sequence (or stream) of (uniformly distributed) integers into floating-point values that obey a particular distribution. It is also possible to explicitly combine an engine and a distribution in an object of type variate_generator. An example of syntax for this latter purpose looks like
Characterizing Tradeoffs in Memory, Accuracy, and Speed for Chemistry Tabulation Techniques
Published in Combustion Science and Technology, 2023
Elizabeth Armstrong, John C. Hewson, James C. Sutherland
When using Lagrange interpolants for tabulation, the data to be interpolated are tabulated in memory. This means when the interpolant is queried at a new location, the correct neighboring points from the table have to be found in order to evaluate the Lagrange polynomial, , and their corresponding dependent variables. For non-uniform grids, this step requires a nonlinear solve for the index of each independent variable bracketing the new location. In this study, the lower_bound function from the C++ standard library, employing bisection, is used for determining these indices. In the case of uniform grids, the index search simplifies to a few arithmetic operations based on . The Lagrange polynomials themselves can also be simplified for constant grid spacing.
Do we need to pay technical debt in blockchain software systems?
Published in Connection Science, 2022
Yubin Qu, Tie Bao, Xiang Chen, Long Li, Xianzhen Dou, Meng Yuan, Hongmei Wang
We download the source code of the latest stable versions of the six projects from Github. We need to extract the code comments from the source codes. As shown in Table 1, there are five different programming languages in the six projects, including C++, Rust, Python, go, and Solidity. For the projects coded by C++ programming language, we use srcML9 to parse source files into XML files. Then we develop a Python-based parser to extract code comments from the XML files. For the projects coded by Python programming language, we use the tokenise module10 in the Python standard library to extract code comments according to “COMMENT” tag. For the projects coded by Rust programming language, go Rust programming language and Solidity programming language, we develop Python-based programs for each programming language. Single-line comments and multi-line comments are extracted from the source codes. Finally, we extract a total of 125,430 comments from the 6 projects.
Exploring beneath the surface using interactive data transects
Published in Annals of GIS, 2021
In the input selection module, a window with four drop-down lists for selecting and ordering sub-surface layers as shown in Figure 2 will ‘pop up’ after clicking on the add-in toolbar. The pop-up window is implemented using the combobox widget in the ttk module of Tkinter package. Tkinter is a standard library, which is available with the installation of Python. However, the direct use of Tkinter as an add-in script to create a graphical user interface (GUI) will result in the ArcMap module crashing. To resolve this issue, the script for implementing the dialog window was put in a separate Python script file, which was then saved in the add-in’s Instal directory. The dialog is launched in a sub-process, and then the names of input layers are stored as a list and pass back to the add-in script using the communicate method in the Popen class of the sub-process module. Currently, the maximum number of input layers for the transect tool is four; this limit could be increased but four layers are sufficient to demonstrate the utility of the tool. If there are fewer than four layers, the user would complete the drop-down list from the bottom layer to the top layer, and leave the remaining layers blank. The choices of each drop-down menu are the names of the raster layers that exist within the active data frame of the current map document; thus, the sub-surface datasets need to be added in ArcMap before applying the transect tool.