Search NASA⌕ Search

SEARCH · Search NASA

Results for “nested iteration”

Search indexed NASA NTRS and DOE OSTI research on propulsion, heat transfer, battery materials and energy systems. Follow report and document links to the original sources.

Quote a phrase for an exact phrase match. Source license links do not imply unrestricted reuse.

At least 19 records

Perl Modules for Constructing Iterators

The Iterator Perl Module provides a general-purpose framework for constructing iterator objects within Perl, and a standard API for interacting with those objects. Iterators are an object-oriented design pattern where a description of a series of values is used in a constructor. Subsequent queries can request values in that series. These Perl modules build on the standard Iterator framework and provide iterators for some other types of values. Iterator::DateTime constructs iterators from DateTime objects or Date::Parse descriptions and ICal/RFC 2445 style re-currence descriptions. It supports a variety of input parameters, including a start to the sequence, an end to the sequence, an Ical/RFC 2445 recurrence describing the frequency of the values in the series, and a format description that can refine the presentation manner of the DateTime. Iterator::String constructs iterators from string representations. This module is useful in contexts where the API consists of supplying a string and getting back an iterator where the specific iteration desired is opaque to the caller. It is of particular value to the Iterator::Hash module which provides nested iterations. Iterator::Hash constructs iterators from Perl hashes that can include multiple iterators. The constructed iterators will return all the permutations of the iterations of the hash by nested iteration of embedded iterators. A hash simply includes a set of keys mapped to values. It is a very common data structure used throughout Perl programming. The Iterator:: Hash module allows a hash to include strings defining iterators (parsed and dispatched with Iterator::String) that are used to construct an overall series of hash values.

Tilmes, Curt↗

A low-communication, parallel algorithm for solving PDEs based on range decomposition

This work proposes a new, low-communication algorithm for solving PDEs on massively parallel computers. The range decomposition (RD) algorithm exposes coarse-grain parallelism by applying nested iteration and adaptive mesh refinement locally before performing a global communication step. Just a few such steps are observed to be sufficient to obtain accuracy within a small multiple of discretization error. The target applications are petascale and exascale machines, where hierarchical parallelism is required and traditional parallel numerical PDE communication patterns are costly because of message latency. The RD algorithm uses a partition of unity to equally distribute the error, and thus, the work. The computational advantages of this approach are that the decomposed problems can be solved in parallel without any communication until the partitioned solutions are summed. This offers potential advantages in the paradigm of expensive communication but very cheap computation. This paper introduces the method and explains the details of the communication step. Two performance models are developed, showing that the latency cost associated with a traditional parallel implementation of nested iteration is proportional to log(P) 2 , whereas the RD method reduces the communication latency to log(P), while maintaining similar bandwidth costs. Numerical results for two problems, Laplace and advection diffusion, demonstrate the enhanced performance, and a heuristic argument explains why the method converges quickly.

97 MATHEMATICS AND COMPUTING↗

Development of Fast Algorithms Using Recursion, Nesting and Iterations for Computational Electromagnetics

In the first phase of our work, we have concentrated on laying the foundation to develop fast algorithms, including the use of recursive structure like the recursive aggregate interaction matrix algorithm (RAIMA), the nested equivalence principle algorithm (NEPAL), the ray-propagation fast multipole algorithm (RPFMA), and the multi-level fast multipole algorithm (MLFMA). We have also investigated the use of curvilinear patches to build a basic method of moments code where these acceleration techniques can be used later. In the second phase, which is mainly reported on here, we have concentrated on implementing three-dimensional NEPAL on a massively parallel machine, the Connection Machine CM-5, and have been able to obtain some 3D scattering results. In order to understand the parallelization of codes on the Connection Machine, we have also studied the parallelization of 3D finite-difference time-domain (FDTD) code with PML material absorbing boundary condition (ABC). We found that simple algorithms like the FDTD with material ABC can be parallelized very well allowing us to solve within a minute a problem of over a million nodes. In addition, we have studied the use of the fast multipole method and the ray-propagation fast multipole algorithm to expedite matrix-vector multiplication in a conjugate-gradient solution to integral equations of scattering. We find that these methods are faster than LU decomposition for one incident angle, but are slower than LU decomposition when many incident angles are needed as in the monostatic RCS calculations.

Chew, W. C.↗

A Note on Multigrid Theory for Non-nested Grids and/or Quadrature

We provide a unified theory for multilevel and multigrid methods when the usual assumptions are not present. For example, we do not assume that the solution spaces or the grids are nested. Further, we do not assume that there is an algebraic relationship between the linear algebra problems on different levels. What we provide is a computationally useful theory for adaptively changing levels. Theory is provided for multilevel correction schemes, nested iteration schemes, and one way (i.e., coarse to fine grid with no correction iterations) schemes. We include examples showing the applicability of this theory: finite element examples using quadrature in the matrix assembly and finite volume examples with non-nested grids. Our theory applies directly to other discretizations as well.

Douglas, C. C.↗

thornado-transport: Anderson- and GPU-accelerated nonlinear solvers for neutrino-matter coupling

Algorithms for neutrino-matter coupling in core-collapse supernovae (CCSNe) are investigated in the context of a spectral two-moment model, which is discretized in space with the discontinuous Galerkin method, integrated in time with implicit-explicit (IMEX) methods, and implemented in the toolkit for high-order neutrino-radiation hydrodynamics (thornado). The model considers electron neutrinos and antineutrinos and tabulated opacities from Bruenn (1985), which includes neutrino-electron scattering and pair processes. The nonlinear system arising from implicit time discretization of the equations governing neutrino-matter coupling is iterated to convergence using Anderson-accelerated fixed-point methods, which avoid formation of Jacobians and inversion of dense linear systems. Numerical experiments show that, for a given tolerance, a nested iteration scheme which aims to reduce opacity evaluations can lower the computational cost. Our initial port to GPUs, using both OpenMP and OpenACC, shows an overall speedup of up to ~ 100× when compared to results using a single CPU core. These results indicate that the algorithms implemented in thornado are well-suited to GPU acceleration.

Laiu, Paul↗

RESOLVING THE ELECTROCHEMICAL EQUATIONS OF A SOLID OXIDE FUEL CELL FOR USE IN TRANSIENT SIMULATION AND INTEGRATION INTO CYBER-PHYSICAL SYSTEMS

A major challenge with complex cyber-physical systems stems from long model computational time that creates a mismatch between the model system and the physical system. The numerical modeling of solid oxide fuel cells (SOFCs) presents particular challenges due to the highly coupled nature of the underlying equations and the multiphysics needed to fully resolve their behavior during a transient event. To this end current approaches revolve around splitting the computational efforts into resolving temperature effects and resolving electrochemical effects. Current methods employed for the transient simulation of an SOFC for implementation in the Hybrid Performance (HyPer) facility cyberphysical plant at the National Energy Technology Laboratory reveal a distinct need for accelerated results with a high degree of stability. To this aim, an investigation into the computational time for the code reveals that the underlying electrochemical algorithm takes an order of magnitude more time than its thermal counterpart and has a tendency to vary in terms of iteration time and as such a rework of the underlying system is proposed. The primary method for accelerated electrochemical algorithm solutions is to employ higher order root finding recipes for the resolution of the highly coupled electrochemical equations. This is done with the intention to reduce the overall number of subiterations necessary for resolving voltage, current density, and species concentration, properties of the fuel cell that are all directly coupled and require nested iterative approaches. The overall objective of this approach is an order of magnitude reduction in calculation time without sacrificing stability and increasing accuracy. Specific approaches involve using both bounded and unbounded techniques, such as the False Position method and the Secant method (or if applicable Newton-Raphson) respectively, the drawbacks being slower convergence for False Position and instability for the Secant or Newton-Raphson methods. Current preliminary results on simplified versions of the parent functions involved for electrochemical calculations indicate a reduction in computational steps by a factor of two for the secant method and a factor of three for Newton-Raphson. When implemented into new modified electrochemical algorithms, the results indicate a possible order of magnitude reduction in calculation time.

Arias, Jesus↗

A least-squares finite element method based on the Helmholtz decomposition for hyperbolic balance laws

In this paper, a least-squares finite element method for scalar nonlinear hyperbolic balance laws is proposed and studied. The approach is based on a formulation that utilizes an appropriate Helmholtz decomposition of the flux vector and is related to the standard notion of a weak solution. This relationship, together with a corresponding connection to negative-norm least-squares, is described in detail. As a consequence, an important numerical conservation theorem is obtained, similar to the famous Lax–Wendroff theorem. The numerical conservation properties of the method in this paper do not fall precisely in the framework introduced by Lax and Wendroff, but they are similar in spirit as they guarantee that when L 2 convergence holds, the resulting approximations approach a weak solution to the hyperbolic problem. The least-squares functional is continuous and coercive in an H -1 -type norm, but not L 2 -coercive. Nevertheless, the L 2 convergence properties of the method are discussed. Convergence can be obtained either by an explicit regularization of the functional, that provides control of the L 2 norm, or by properly choosing the finite element spaces, providing implicit control of the L 2 norm. Numerical results for the inviscid Burgers equation with discontinuous source terms are shown, demonstrating the L 2 convergence of the obtained approximations to the physically admissible solution. The numerical method utilizes a least-squares functional, minimized on finite element spaces, and a Gauss–Newton technique with nested iteration. Finally, we believe that the linear systems encountered with this formulation are amenable to multigrid techniques and combining the method with adaptive mesh refinement would make this approach an efficient tool for solving balance laws (this is the focus of a future study).

97 MATHEMATICS AND COMPUTING↗

Efficient and Extensible Quasi-Explicit Modular Nonlinear Multiscale Battery Model: GH-MSMD

Complex physics and long computation time hinder the adoption of computer aided engineering models in the design of large-format battery cells and systems. A modular, efficient battery simulation model -- the multiscale multidomain (MSMD) model -- was previously introduced to aid the scale-up of Li-ion material and electrode designs to complete cell and pack designs, capturing electrochemical interplay with 3-D electronic current pathways and thermal response. Here, this paper enhances the computational efficiency of the MSMD model using a separation of time-scales principle to decompose model field variables. The decomposition provides a quasi-explicit linkage between the multiple length-scale domains and thus reduces time-consuming nested iteration when solving model equations across multiple domains. In addition to particle-, electrode- and cell-length scales treated in the previous work, the present formulation extends to bus bar- and multi-cell module-length scales. We provide example simulations for several variants of GH electrode-domain models.

30 DIRECT ENERGY CONVERSION↗

Distributed Reinforcement Learning with ADMM-RL

This paper presents a new algorithm for distributed Reinforcement Learning (RL). RL is an artificial intelligence (AI) control strategy such that controls for highly nonlinear systems over multi-step time horizons may be learned by experience, rather than directly computed on the fly by optimization. Here we introduce ADMM-RL, a combination of the Alternating Direction Method of Multipliers (ADMM) and reinforcement learning that allows for integrating learned controllers as subsystems in generally convergent distributed control applications. ADMM has become the workhorse algorithm for distributed control, combining the advantages of dual decomposition (namely, enabling decoupled, parallel, distributed solution) with the advantages of the method of multipliers (namely, convexification/stability). Our ADMM-RL algorithm replaces one or more of the subproblems in ADMM with several steps of RL. When the nested iterations converge, we are left with a pretrained subsolver that can potentially increase the efficiency of the deployed distributed controller by orders of magnitude. We illustrate ADMM-RL in both distributed wind farm yaw control and distributed grid-aware demand aggregation for water heaters.

ADMM↗

Multigrid method for a vortex breakdown simulation

An inviscid model for a steady axisymmetric flow with swirl was studied. The governing equation is a nonlinear elliptic equation which has more than one solution for a certain range of the swirl parameter. The physically interesting solutions have closed streamlines that look like vortex breakdown (bubble-like solutions). A multigrid method is used to find these solutions. Using an FMG algorithm (nested iteration), the problem is solved in just a few multigrid cycles.

Taasan, S.↗

Interference Lattice-based Loop Nest Tilings for Stencil Computations

A common method for improving performance of stencil operations on structured multi-dimensional discretization grids is loop tiling. Tile shapes and sizes are usually determined heuristically, based on the size of the primary data cache. We provide a lower bound on the numbers of cache misses that must be incurred by any tiling, and a close achievable bound using a particular tiling based on the grid interference lattice. The latter tiling is used to derive highly efficient loop orderings. The total number of cache misses of a code is the sum of (necessary) cold misses and misses caused by elements being dropped from the cache between successive loads (replacement misses). Maximizing temporal locality is equivalent to minimizing replacement misses. Temporal locality of loop nests implementing stencil operations is optimized by tilings that avoid data conflicts. We divide the loop nest iteration space into conflict-free tiles, derived from the cache miss equation. The tiling involves the definition of the grid interference lattice an equivalence class of grid points whose images in main memory map to the same location in the cache-and the construction of a special basis for the lattice. Conflicts only occur on the boundaries of the tiles, unless the tiles are too thin. We show that the surface area of the tiles is bounded for grids of any dimensionality, and for caches of any associativity, provided the eccentricity of the fundamental parallelepiped (the tile spanned by the basis) of the lattice is bounded. Eccentricity is determined by two factors, aspect ratio and skewness. The aspect ratio of the parallelepiped can be bounded by appropriate array padding. The skewness can be bounded by the choice of a proper basis. Combining these two strategies ensures that pathologically thin tiles are avoided. They do not, however, minimize replacement misses per se. The reason is that tile visitation order influences the number of data conflicts on the tile boundaries. If two adjacent tiles are visited successively, there will be no replacement misses on the shared boundary. The iteration space may be covered with pencils larger than the size of the cache while avoiding data conflicts if the pencils are traversed by a scanning-face method. Replacement misses are incurred only on the boundaries of the pencils, and the number of misses is minimized by maximizing the volume of the scanning face, not the volume of the tile. We present an algorithm for constructing the most efficient scanning face for a given grid and stencil operator. In two dimensions it is based on a continued fraction algorithm. In three dimensions it follows Voronoi's successive minima algorithm. We show experimental results of using the scanning face, and compare with canonical loop orderings.

VanderWijngaart, Rob F.↗

Power System Optimization Codes Modified

A major modification of and addition to existing Closed Brayton Cycle (CBC) space power system optimization codes was completed. These modifications relate to the global minimum mass search driver programs containing three nested iteration loops comprising iterations on cycle temperature ratio, and three separate pressure ratio iteration loops--one loop for maximizing thermodynamic efficiency, one for minimizing radiator area, and a final loop for minimizing overall power system mass. Using the method of steepest ascent, the code sweeps through the pressure ratio space repeatedly, each time with smaller iteration step sizes, so that the three optimum pressure ratios can be obtained to any desired accuracy for each of the objective functions referred to above (i.e., maximum thermodynamic efficiency, minimum radiator area, and minimum system mass). Two separate options for the power system heat source are available: 1. A nuclear fission reactor can be used. It is provided with a radiation shield 1. (composed of a lithium hydride (LiH) neutron shield and tungsten (W) gamma shield). Suboptions can be used to select the type of reactor (i.e., fast spectrum liquid metal cooled or epithermal high-temperature gas reactor (HTGR)). 2. A solar heat source can be used. This option includes a parabolic concentrator and heat receiver for raising the temperature of the recirculating working fluid. A useful feature of the code modifications is that key cycle parameters are displayed, including the overall system specific mass in kilograms per kilowatt and the system specific power in watts per kilogram, as the results for each temperature ratio are computed. As the minimum mass temperature ratio is encountered, a message is printed out. Several levels of detailed information on cycle state points, subsystem mass results, and radiator temperature profiles are stored for this temperature ratio condition and can be displayed or printed by users.

Juhasz, Albert J.↗

NUMERICAL MODELING OF A SOLID OXIDE FUEL CELL FOR USE IN REAL-TIME SIMULATION AND CYBER-PHYSICAL SYSTEMS

Cyber-physical systems provide a mechanism with which to investigate the physical phenomena and behavior of traditionally cost-prohibitive or otherwise fragile equipment. For the National Energy Technology Laboratory (NETL), this approach resulted in the Hybrid Performance (Hyper) facility which features a gas turbine-SOFC hybrid cycle utilizing real turbomachinery and a simulated SOFC stack. This allows for the investigation of combined cycle performance and control strategies, in an exhaustive manner, both without fear of destroying delicate state-of-the-art fuel cells, and with the full accuracy of real-world turbomachinery. Issues arose between the transient response of the SOFC model being limited to a sample time of 80 milliseconds, due to the calculation time of the SOFC model taking on average 40 milliseconds to calculate for a given timestep with spikes in calculation time reaching the 80 millisecond threshold. In order to be able to match the speed of transients from the turbomachinery and likewise better discern transient behavior, it was determined that the SOFC model must be optimized to operate at a sample time of 5 milliseconds. Therefore, it is necessary to optimize the SOFC model in order to decrease the calculation time from around 40 milliseconds, down to at the most 5 milliseconds. To do this, both the electrochemical algorithm and the thermal algorithm used to simulate the physical behavior of the SOFC are investigated to determine where improvements can be made. To this end the rootfinding numerical recipes of the electrochemical algorithm are investigated as the complex electrochemistry requires a highly iterative nested dual convergence loop to resolve the voltage-current relationship, and likewise the temporal discretization of the thermal algorithm is modified for the sake of higher accuracy and stability. Ultimately the new electrochemical algorithm featuring higher order rootfinding schemes proves to be efficient enough to reach the sub 5 millisecond target, signifying an order of magnitude reduction in calculation time, and when coupled with the new temporal discretization similar calculation time characteristics show that a fully implicit, higher order temporal discretization can also successfully be used if desired. Ultimately this result means that the cyber-physical simulation system can operate at higher sample rates, and resolve transient events at significantly higher resolution and fidelity.

Arias, Jesus↗

Analysis of a New Implicit Solver for a Semiconductor Model

Here, we present and analyze a new iterative solver for implicit discretizations of a simplified Boltzmann--Poisson system. The algorithm builds on recent work that incorporated a sweeping algorithm for the Vlasov--Poisson equations as part of nested inner-outer iterative solvers for the Boltzmann--Poisson equations. The new method eliminates the need for nesting and requires only one transport sweep per iteration. It arises as a new fixed-point formulation of the discretized system which we prove to be contractive for a given electric potential. We also derive an accelerator to improve the convergence rate for systems in the drift-diffusion regime. We numerically compare the efficiency of the new solver, with and without acceleration, against a recently developed nested iterative solver.

97 MATHEMATICS AND COMPUTING↗

Efficient flexible characterization of quantum processors with nested error models

We present a simple and powerful technique for finding a good error model for a quantum processor. The technique iteratively tests a nested sequence of models against data obtained from the processor, and keeps track of the best-fit model and its wildcard error (a metric of the amount of unmodeled error) at each step. Each best-fit model, along with a quantification of its unmodeled error, constitutes a characterization of the processor. We explain how quantum processor models can be compared with experimental data and to each other. We demonstrate the technique by using it to characterize a simulated noisy two-qubit processor.

71 CLASSICAL AND QUANTUM MECHANICS, GENERAL PHYSIC↗

Automating CPM-GOMS

CPM-GOMS is a modeling method that combines the task decomposition of a GOMS analysis with a model of human resource usage at the level of cognitive, perceptual, and motor operations. CPM-GOMS models have made accurate predictions about skilled user behavior in routine tasks, but developing such models is tedious and error-prone. We describe a process for automatically generating CPM-GOMS models from a hierarchical task decomposition expressed in a cognitive modeling tool called Apex. Resource scheduling in Apex automates the difficult task of interleaving the cognitive, perceptual, and motor resources underlying common task operators (e.g. mouse move-and-click). Apex's UI automatically generates PERT charts, which allow modelers to visualize a model's complex parallel behavior. Because interleaving and visualization is now automated, it is feasible to construct arbitrarily long sequences of behavior. To demonstrate the process, we present a model of automated teller interactions in Apex and discuss implications for user modeling. available to model human users, the Goals, Operators, Methods, and Selection (GOMS) method [6, 21] has been the most widely used, providing accurate, often zero-parameter, predictions of the routine performance of skilled users in a wide range of procedural tasks [6, 13, 15, 27, 28]. GOMS is meant to model routine behavior. The user is assumed to have methods that apply sequences of operators and to achieve a goal. Selection rules are applied when there is more than one method to achieve a goal. Many routine tasks lend themselves well to such decomposition. Decomposition produces a representation of the task as a set of nested goal states that include an initial state and a final state. The iterative decomposition into goals and nested subgoals can terminate in primitives of any desired granularity, the choice of level of detail dependent on the predictions required. Although GOMS has proven useful in HCI, tools to support the construction of GOMS models have not yet come into general use.

GOMS↗