Engineering Papers⌕ Search

SEARCH · Engineering Papers

Results for “Coding”

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 451 records · Page 25

ARCS: Agentic Retrieval-Augmented Code Synthesis with Iterative Refinement

Agentic Retrieval-Augmented Code Synthesis with Iterative RefinementIn supercomputing, efficient and optimized code generation is essential to leverage high-performance systems effectively. We have developed Agentic Retrieval-Augmented Code Synthesis (ARCS), an advanced framework for accurate, robust, and efficient code generation, completion, and translation. ARCS integrates Retrieval-Augmented Generation (RAG) with Chain-of-Thought (CoT) reasoning to systematically break down and iteratively refine complex programming tasks. An agent-based RAG mechanism retrieves relevant code snippets, while real-time execution feedback drives the synthesis of candidate solutions. This process is formalized as a state-action search tree optimization, balancing code correctness with editing efficiency. Evaluations on the Geeks4Geeks and HumanEval benchmarks demonstrate that ARCS significantly outperforms traditional prompting methods in translation and generation quality. By enabling scalable and precise code synthesis, ARCS offers transformative potential for automating and optimizing code development in supercomputing applications, enhancing computational resource utilization

Bhattarai, Manish [Los Alamos National Labs]↗

Preserving Envelope Efficiency in Performance Based Code Compliance

The City of Seattle 2012 Energy Code (Seattle 2014), one of the most progressive in the country, is under revision for its 2015 edition. Additionally, city personnel participate in the development of the next generation of the Washington State Energy Code and the International Energy Code. Seattle has pledged carbon neutrality by 2050 including buildings, transportation and other sectors. The United States Department of Energy (DOE), through Pacific Northwest National Laboratory (PNNL) provided technical assistance to Seattle in order to understand the implications of one potential direction for its code development, limiting trade-offs of long-lived building envelope components less stringent than the prescriptive code envelope requirements by using better-than-code but shorter-lived lighting and heating, ventilation, and air-conditioning (HVAC) components through the total building performance modeled energy compliance path. Weaker building envelopes can permanently limit building energy performance even as lighting and HVAC components are upgraded over time, because retrofitting the envelope is less likely and more expensive. Weaker building envelopes may also increase the required size, cost and complexity of HVAC systems and may adversely affect occupant comfort. This report presents the results of this technical assistance. The use of modeled energy code compliance to trade-off envelope components with shorter-lived building components is not unique to Seattle and the lessons and possible solutions described in this report have implications for other jurisdictions and energy codes.

32 ENERGY CONSERVATION, CONSUMPTION, AND UTILIZATI↗

DSD2D-FLS 2010: Bdzil's 2010 DSD Code Base; Computing tb and Dn with Edits to Reduce the Noise in the Dn Field Near HE Boundaries

The full level-set function code, DSD3D, is fully described in LA-14336 (2007) [1]. This ASCI-supported, DSD code project was the last such LANL DSD code project that I was involved with before my retirement in 2007. My part in the project was to design and build the core DSD3D solver, which was to include a robust DSD boundary condition treatment. A robust boundary condition treatment was required, since for an important local “customer,” the only description of the explosives’ boundary was through volume fraction data. Given this requirement, the accuracy issues I had encountered with our “fast-tube,” narrowband, DSD2D solver, and the difficulty we had building an efficient MPI-parallel version of the narrowband DSD2D, I decided DSD3D should be built as a full level-set function code, using a totally local DSD boundary condition algorithm for the level-­set function, phi, which did not rely on the gradient of the level-­set function being one, |grad(phi)| = 1. The narrowband DSD2D solver was built on the assumption that |grad(phi)| could be driven to one, and near the boundaries of the explosive this condition was not being satisfied. Since the narrowband is typically no more than10*dx wide, narrowband methods are discrete methods with a fixed, non-­resolvable error, where the error is related to the thickness of the band: the narrower the band the larger the errors. Such a solution represents a discrete approximation to the true solution and does not limit to the solution of the underlying PDEs under grid resolution.The full level-­set function code, DSD3D, is fully described in LA-14336 (2007) [1]. This ASCI-­supported, DSD code project was the last such LANL DSD code project that I was involved with before my retirement in 2007. My part in the project was to design and build the core DSD3D solver, which was to include a robust DSD boundary condition treatment. A robust boundary condition treatment was required, since for an important local “customer,” the only description of the explosives’ boundary was through volume fraction data. Given this requirement, the accuracy issues I had encountered with our “fast-­tube,” narrowband, DSD2D solver, and the difficulty we had building an efficient MPI-parallel version of the narrowband DSD2D, I decided DSD3D should be built as a full level-­set function code, using a totally local DSD boundary condition algorithm for the level-­set function, phi, which did not rely on the gradient of the level-­set function being one, |grad(phi)| = 1. The narrowband DSD2D solver was built on the assumption that |grad(phi)| could be driven to one, and near the boundaries of the explosive this condition was not being satisfied. Since the narrowband is typically no more than10*dx wide, narrowband methods are discrete methods with a fixed, non-resolvable error, where the error is related to the thickness of the band: the narrower the band the larger the errors. Such a solution represents a discrete approximation to the true solution and does not limit to the solution of the underlying PDEs under grid resolution.

97 MATHEMATICS AND COMPUTING↗

Final Technical Report for GO17004 Regulatory Logic: Codes and Standards for the Hydrogen Economy

The objectives of this project are to: develop a robust supporting research and development program to provide critical hydrogen behavior data and a detailed understanding of hydrogen combustion and safety across a range of scenarios, needed to establish setback distances in building codes and minimize the overall data gaps in code development; support and facilitate the completion of technical specifications by the International Organization for Standardization (ISO) for gaseous hydrogen refueling (TS 20012) and standards for on-board liquid (ISO 13985) and gaseous or gaseous blend (ISO 15869) hydrogen storage by 2007; support and facilitate the effort, led by the NFPA, to complete the draft Hydrogen Technologies Code (NFPA 2) by 2008; with experimental data and input from Technology Validation Program element activities, support and facilitate the completion of standards for bulk hydrogen storage (e.g., NFPA 55) by 2008; facilitate the adoption of the most recently available model codes (e.g., from the International Code Council [ICC]) in key regions; complete preliminary research and development on hydrogen release scenarios to support the establishment of setback distances in building codes and provide a sound basis for model code development and adoption; support and facilitate the development of Global Technical Regulations (GTRs) by 2010 for hydrogen vehicle systems under the United Nations Economic Commission for Europe, World Forum for Harmonization of Vehicle Regulations and Working Party on Pollution and Energy Program (ECE-WP29/GRPE); and to Support and facilitate the completion by 2012 of necessary codes and standards needed for the early commercialization and market entry of hydrogen energy technologies.

08 HYDROGEN↗

The MARS Code System User’s Guide Version 15(2016)

This paper is a user’s guide to the current version of the MARS15 Monte Carlo code. MARS allows inclusive and, in many cases, exclusive simulations of three-dimensional hadronic and electromagnetic cascades and modeling of heavy ion, muon and low energy neutron-photon transport in accelerator, detector, spacecraft and shielding components. Particles can have energies from a fraction of an electronvolt up to about 100 TeV. The code has undergone substantial improvements since the last documented version MARS13(95) and since previous releases of MARS15; all these as well as other specific features of the MARS code system are explained in detail. Descriptions of general input and output with commentary and recommendations are given. Examples are given for running the program with distributed sources, complex compounds, arbitrary geometries, and magnetic fields. A built-in graphical-user interface allows the visualization and detailed analysis of the geometry description. Enhanced options are described for the MARS code being coupled with: the DPMJET hadron event generator, the MCNP code for low-energy neutron transport, the ANSYS system for thermal and stress analysis, physics analysis and graphics packages, the MAD accelerator lattice description via a universal MAD-MARS beam line builder, the STRUCT program for tracking particles in accelerator lattices with beam loss recording, the DETRA code for nuclide decay and transmutation calculations, the EGS5 code for precise modeling of low-energy electromagnetic showers, and the ROOT system for description and visualization of arbitrary geometries. Use of the code in a multistage mode, coupled with event generators (DPMJET), with the STRUCT program for tracking particles in accelerator lattices with beam loss recording, and with physics analysis and graphics packages is demonstrated with typical input and output examples.

43 PARTICLE ACCELERATORS↗

PDC: Plant Dynamics Code for Design and Transient Analysis of Supercritical Brayton Cycles

The current report documents the Plant Dynamics Code developed at the Argonne National Laboratory for steady-state and transient analysis of supercritical Brayton cycles. The report consists of three major parts. Code Overview provides the general description of the code, including the purpose of the code development and the code’s main features. User’s Guide explains how to work with the code, including its user interface. Code Manual provides the detailed description of the code, including modeling, assumptions, and the solution schemes.

21 SPECIFIC NUCLEAR REACTORS AND ASSOCIATED PLANTS↗

Final Energy Savings Analysis of the Proposed NYStretch-Energy Code 2018

In 2017, New York State Energy Research and Development Authority (NYSERDA) developed its 2016 Stretch Code Supplement to the 2016 New York State Energy Conservation Construction Code. Since2017, NYSERDA has continued to develop the 2018 edition, as part of the efforts to achieve a statewide Net Zero Energy Code by 2028. To support this effort, Pacific Northwest National Laboratory (PNNL)conducted energy simulation analysis to quantify the energy savings of proposed commercial provisions of the NYStretch-Energy Code 2018 compared to ANSI/ASHRAE/IES1 Standard 90.1-2013. Specifically, PNNL collaborated with New Buildings Institute (NBI), and developed energy-efficiency measures (EEMs) from national model codes and standards, high-performance building codes and standards, regional energy codes, and measures being proposed as part of the ongoing NYStretch-Energy code development process. PNNL analyzed these measures using whole building energy simulation for selected prototype commercial and multifamily buildings representing buildings in New York State.

29 ENERGY PLANNING, POLICY, AND ECONOMY↗

The Release of the Simplified Radionuclide Transport (SRT) Code (V.2.1)

Reactor licensing centers on the protection of the public and environment from the inadvertent release of radioactive material. Therefore, mechanistic source term analysis, or the realistic evaluation of radionuclide transport from the source to the environment for specific transient scenarios, is vital to reactor licensing efforts. Developed to resolve a gap in mechanistic source term modeling capabilities for sodium fast reactors (SFRs), the Simplified Radionuclide Transport (SRT) code created by Argonne National Laboratory (Argonne) is now utilized by advanced reactor vendors, universities, and research institutions to support a multitude of design, licensing, and research efforts. Recently, SRT version 2.1 was released, which includes improvements to code models and verification and validation (V&V) suite to support the SRT user community. The following work provides an overview of the improvements made as part of the release of SRT version 2.1. This effort is supported by the U.S. Department of Energy Office of Nuclear Energy (DOE:NE) Advanced Reactor Technologies (ART) Fast Reactor Program (FRP), as part of the program’s support of national laboratory design and safety analysis computer codes utilized by the fast reactor industry. The expansion of SRT code capabilities and improvements to code V&V associated with version 2.1 are in response to user requests and lessons learned from recent source term analyses performed by Argonne and advanced reactor vendors. They also align with the evolving role of SRT, from research and development tool to software utilized for reactor licensing calculations. The report is structured in alignment with the code improvements, as outlined in Figure 1-1. Section 2 provides background information on SRT, including its history, capabilities, and utilization. Section 3 details new code capabilities as part of version 2.1, while Section 4 focuses on the expansion of the code’s V&V suite. Lastly, Section 5 provides a summary and discussion of next steps.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

Verification of RESRAD-BUILD Code Version 4

This report documents the verification of the RESRAD-BUILD code, Version 4.0, which was released on December 22, 2022. Two earlier reports verifying Versions 3.0 and 3.1, respectively, were published in 2001 (Kamboj, et al. 2001) and 2003 (Tetra Tech NUS 2003). Version 4.0 of the RESRAD-BUILD code has many new features and modeling enhancements over the earlier versions, including the previously released Version 3.5. Chapter 2 of this report focuses on verifying the external dose and risk modeling for point, line, area, and volume sources, as well as for floor deposition. Besides verification, the external radiation doses calculated by RESRAD-BUILD were also benchmarked with those calculated by the MCNP code (Briemeister 1993). Section J.3 of the RESRAD-BUILD User’s Manual Vol. 1 (Yu et al. 2022) documents the results of that benchmarking effort. Chapter 3 of this report focuses on verifying the ventilation modeling, from checking the remaining source inventory, releases of radionuclides to the air, air concentrations and deposited floor concentrations over time, to the radiation dose and risk associated with inhalation, ingestion, and air submersion, with and without vacuuming. The verification efforts involve designing spreadsheets to perform calculations the same as or like those performed by the RESRAD-BUILD code and then comparing the spreadsheet results with those produced by the code. When the results agree or the differences are within acceptable range, the accuracy of model implementation in the code is verified. In addition to model implementation, the implementation of key functions and features that facilitate the modeling or the use of the code were also verified during the release testing of the code. Appendix A presents the test cases developed for these verification testing, and Appendix B presents the testing results that verify proper implementation of key functions and features.

54 ENVIRONMENTAL SCIENCES↗

Verification of RESRAD-OFFSITE Code (V.4)

This report documents the verification of RESRAD-OFFSITE Version 4.0 and describes, where necessary, the verification of the following: • The data comprising the standard dose and risk coefficient libraries in the RESRAD database files Master_dcf_ICRP07.mdb and Master_dcf_2k.mdb. • The extraction and transfer of the data from the selected database file to the computational code by the RESRAD-OFFSITE 4.0 interface, ResOWin.exe. • The different processes that are modeled by the main computational code in RESRAD OFFSITE 4.0, ResOMain.exe. • The data displayed in the graphical and text reports. Many verifications were performed as part of the quality assurance quality control program associated with the development and release of RESRAD-OFFSITE 4.0, namely: • developer testing, • internal independent testing, and • release testing. Some were also performed in response to questions from users regarding the performance of the code. The main text of the report focuses on summarizing a subset of those tests, both independent and developer tests that verified the computations performed by the code. The verifications included in this report served as the basis for the development of the release tests of the computational executables and provided the quantitative results to be compared with the code output. The input and output interfaces and the data transfers between the various executables of the code were tested while performing the verification testing. They were tested intentionally during release testing. This report also provides some basic information to help in understanding the activities that were verified. The report: • outlines the components of RESRAD-OFFSITE 4.0 and the interconnections between these components, • outlines the processes modeled by the computational code, • provides summary figures and tables to offer confirmation of the verification of the computational components of the code, • reproduces the verifiers’ reports, if available, in individual appendices, • refers to the previous verification report (Yu et al. 2011) for more details about some of the verifications, and • reproduces the test cases and the testers’ reports from the release testing in individual appendices, when possible.

54 ENVIRONMENTAL SCIENCES↗

Improving the Capabilities and Computational Efficiency of the RTE+RRTMGP Radiation Code (Final Report)

This report details progress on the RTE+RRTMGP radiation codes made during the period of performance. RTE+RRTMGP is a set of codes for computing radiative fluxes in planetary atmospheres. RRTMGP uses a k-distribution to provide an optical description (absorption and possibly Rayleigh optical depth) of the gaseous atmosphere, along with the relevant source functions, on a pre-determined spectral grid given temperatures, pressures, and gas concentration. RTE computes fluxes given spectrally-resolved optical descriptions and source functions. Spectrally-resolved fluxes are summarized (“reduced”) via a user extensible class. The initial release of the code and the design choices are described in Pincus et al. 2019; the codes are available on Github. Although RRTMGP was based on current (at the time) empirical spectroscopic data, RTE and RRTMGP were developed in large part to modernize software practices. The design focused on flexibility broadly interpreted: by separating code from data and allowing data to drive computation; in coupling to the host model (e.g. the coupling of clouds to radiative fluxes is user-controlled); with respect to programming languages (computational tasks are accessed via widely-compatible C interfaces); and with respect to hardware (the codes run on a range of CPU and GPU architectures). The code also puts an emphasis on modularity and clarity. RTE+RRTMGP v1.0 was released in September 20219. This award supported the evolution of the RTE+RRTMGP code base to support greater flexibility, accuracy, and efficiency.

54 ENVIRONMENTAL SCIENCES↗

MCNP® Code Version 6.3.1 Release Notes

The Monte Carlo N-Particle® (MCNP® ) code is a general-purpose, continuous-energy, generalized-geometry, time-dependent, radiation transport code developed by the MCNP development team. MCNP calculations provide predictive capabilities that can replace expensive or impossible-to-perform experiments. Specific application problems include simulations of experimental diagnostics, intrinsic radiation, radiation detection and measurement, criticality safety, nuclear threat reduction and response, radiation health protection, nuclear weapons effects, and nuclear forensics. This MCNP code, version 6.3.1, follows the MCNP6.3.0 version. Since the release of MCNP6.3.0, a variety of bug fixes and code enhancements have been completed for MCNP6.3.1. A few new features have also been added to this release to support both ongoing research and the release of the latest ENDF/B-VIII.1 nuclear data library. The MCNP code, version 6.3.1, theory and user input information is documented in MCNP® Code Version 6.3.1 Theory & User Manual, the build guidance for various platforms is documented in MCNP® Code Version 6.3.1 Build Guide, and the verification and validation testing for various application benchmark test suites is documented in MCNP® Code Version 6.3.1 Verification & Validation Testing.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

High-Temperature Gas-Cooled Reactors Multiphysics Simulation Demonstration and Code Validation

This study presents a comprehensive benchmarking and verification effort of several thermal-hydraulic and multiphysics capabilities for high-temperature gas-cooled reactor applications. The first part of this effort focuses on the running-in verification of Griffin’s multiphysics capabilities, specifically for simulating the evolution of pebble-bed reactor cores from startup to equilibrium. Since Fiscal Year 2024, improvements and enhancements have been implemented in Griffin, including simplifying the process to specify streamlines and developing the online cross-section generation capability. In the absence of validation data, code-to-code comparisons are conducted with kugelpy, showing good agreement for integral quantities like k-eff predictions and predictions for maximum power density. However, accuracy issues are noted for more detailed quantities like the spatial distribution of fission rate densities which will require further work to address. The second part of this report presents an improved System Analysis Module (SAM) core channel model where the effects of cross flow are considered during the pressurized loss of forced cooling transient, resulting in an improved agreement of the predicted pebble temperature with respect to the predictions from the SAM 2D porous media model. Additionally, the wall channeling effect due to variable porosity at the near wall region of the core is also investigated. Furthermore, to demonstrate Griffin’s online cross-section generation capability, a Multiphysics simulation is performed by coupling Griffin to the SAM core channel model. In the third part of the report, as a part of the Organisation for Economic Co-operation and Development/Nuclear Energy Agency (OECD/NEA) thermal-hydraulic code validation benchmark activity for a high-temperature gas-cooled reactor, the High Temperature Test Facility (HTTF) is investigated first using the NekRS computational fluid dynamics (CFD) code to study the flow mixing phenomenon in the lower plenum of the facility. Then, code-to-code and code-to-data comparisons are performed for Test PG27, which is a pressurized conduction cooldown (PCC) test, using five different codes by six organizations from five countries. The different simulations show good agreements in terms of the general trend but there are differences in some results such as the peak temperatures of different regions and heat removal rate.

22 GENERAL STUDIES OF NUCLEAR REACTORS↗

CTF Code Verification and Solution Verification

The CTF code is part of the suite of codes developed with DOE funding under the CASL Program to bring the benefits of high-performance computing to issues of importance to the US nuclear power industry. This document primarily focuses on code and solution verification test problems that have been developed to ensure that CTF converges to the correct answer for the intended application. Convergence behavior and numerical errors are quantified for each of the tests. The observed convergence behavior in all available tests is consistent with expectations for the numerical methods employed by CTF, providing evidence that there are no significant code bugs or algorithm deficiencies in the code. The suite of code verification and solution verification tests are mapped to core capabilities of CTF. Gaps were identified in the code verification test suite and they are being addressed. Two new code verification problems were developed to address gaps that were identified.

22 GENERAL STUDIES OF NUCLEAR REACTORS↗

Assessment of Multi-Scale Thermal-Hydraulic Codes and Models for DNB Challenge Problem Applications

The objectives of this milestone work are to assess the improved capabilities of the multi-scale thermal-hydraulic (T/H) codes and models developed by the Consortium for Advanced Simulation of Light Water Reactors (CASL) for Departure from Nucleate Boiling (DNB) Challenge Problem (CP), in accordance with the DNB CP implementation plan. The multi-scale models can range from fine mesh Computational Fluid Dynamics (CFD) simulation of flow field surrounding a fuel rod to a full core modeling of a Pressurized Water Reactor (PWR). The assessments are performed based on the CASL subchannel code COBRA-TF (CTF) and the CFD code Hydra-TH. Significant improvements have been achieved on the CASL multi-scale T/H code and modeling capabilities based on the CTF subchannel code and the Hydra-TH CFD code in the past year for DNB CP applications. The improvements are reflected in the new transient modeling for the Reactivity Insertion Accident (RIA) DNB predictions and full assembly modeling using the CTF code and its processor, as well as the rod bundle modeling for single-phase flow and heat transfer simulations using the Hydra-TH code, the pre-processor for mesh generation and the post-processor for data visualization.

22 GENERAL STUDIES OF NUCLEAR REACTORS↗

Development of a Single-Phase, Transient, Subchannel Code, within the MOOSE Multi-Physics Computational Framework

Subchannel codes have been widely used for thermal-hydraulics analyses in nuclear reactors. This paper details the development of a novel subchannel code within the Idaho National Laboratory’s (INL) Multi-physics Object Oriented Simulation Environment (MOOSE). MOOSE is a parallel computational framework targeted at the solution of systems of coupled, nonlinear partial differential equations, that often arise in the simulation of nuclear processes. As such, it includes codes/modules able to solve the multiple linear and nonlinear physics that describe a nuclear reactor, under normal operation conditions or accidents. This includes thermal-hydraulics, fuel performance, and neutronics codes, between others. A MOOSE-based subchannel code is a new addition to the fleet of INL-developed codes, based on the MOOSE framework. In this work, we present the derivation of the subchannel equations for a single-phase fluid, we proceed with the description of the algorithm that is used to solve these equations and describe how this algorithm was implemented within MOOSE. We also present how this code can be coupled to the BISON fuel performance code. Next, we verify the friction model and the turbulent mixing model. We calibrate the turbulent modeling parameters for momentum mixing and enthalpy mixing, C T , β. We validate the code using experimental results and last demonstrate the coupling capabilities using a simple example.

42 ENGINEERING↗

Spatial transform coding of color images.

The application of the transform-coding concept to the coding of color images represented by three primary color planes of data is discussed. The principles of spatial transform coding are reviewed and the merits of various methods of color-image representation are examined. A performance analysis is presented for the color-image transform-coding system. Results of a computer simulation of the coding system are also given. It is shown that, by transform coding, the chrominance content of a color image can be coded with an average of 1.0 bits per element or less without serious degradation. If luminance coding is also employed, the average rate reduces to about 2.0 bits per element or less.

Pratt, W. K.↗

Arithmetic algorithms for error-coded operands.

Arithmetic algorithms for separate and nonseparate codes are considered. The nonseparate AN code is formed when an uncoded operand X is multiplied by the check modulus A to give the coded operand AX. The separate codes are the residue code, and the inverse-residue code, which has significant advantages in fault detection of repeated-use faults. A set of algorithms for low-cost AN-coded operands is discussed together with questions of their implementation in a byte-organized arithmetic processor. Algorithms for inverse-residue coded operands of the STAR computer are also examined.

Avizienis, A.↗