Engineering Papers⌕ Search

SEARCH · Engineering Papers

Results for “Python codes”

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 397 records · Page 22

Coupling RELAP5-3D to BISON

This report details two approaches for coupling the BISON nuclear fuel performance code with RELAP5-3D. Both approaches are shown to work well. The first is a Python-based approach, and the second combines the two applications into one executable with data passed in memory from one library to the other. This second coupling approach forms the basis for analysis of complex loss of coolant scenarios and enables future calculations of modeling uncertainties.

11 NUCLEAR FUEL CYCLE AND FUEL MATERIALS↗

Field and Model Data Associated with the Manuscript “Drivers of Streamflow Intermittency in Humid Regions: 2. Evaluating Controls on Flow Persistence in an Urbanized Catchment”

This package contains field data, modeling files, and scripts supporting the investigation of the drivers of streamflow intermittency in an urbanized catchment. It includes the field data collected from electrical resistivity tomography (ERT) surveys, distributed temperature sensing (DTS), continuous self-potential (SP) monitoring, groundwater and stilling well. In addition, it contains the data and results of the coupled water- and electrical-flow model developed using the COMSOL Multiphysics and Advanced Terrestrial Simulator (ATS), as well as software files and Jupyter notebooks used to process the data and generate figures in the manuscript submitted for peer review. The data archive is organized in the following directories: 1) Climate Includes hourly precipitation and daily evapotranspiration time series (2024 – 2025) provided as CSV files, alongside a text file detailing dataset units. 2) Coupled_model Field_Application subfolder contains the ATS XML input scripts, data files, output data for the SP site. It also contains the Jupyter notebook (Plot_final_calib.ipynb) to visualize the results of the modeled SP, stream-groundwater exchange and moisture content. The flow model simulation is executed using the ATS XML scripts and the included Python script (generate_data_set.py) to convert ATS output to COMSOL-ready input. COMSOL Multiphysics template (.m can only be used with COMSOL with MATLAB) is executed using the ATS output data to simulate the potential field. 3) Discharge Includes the electrical conductivity (EC) time series (provided as CSV files) from salt slug injections. It also includes the Jupyter notebook (Discharge_process.ipynyb) used to estimate discharge. All discharge measurements collated into rating_curve_processed.csv 4) DTS Contains collated DTS data including raw Stokes and anti-Stokes measurement (provided as .h5 file). It also includes DTS processing.ipynb, a Jupyter notebook for calibrating the DTS data using dts_calibration Python package. cooler_calibration.csv is the DTS calibration CSV used in the calibration sequence. 5) ERT Contains raw resistivity data (provided as CSV files), spatial location of each of the electrodes (provided as CSV files), and files used for the resistivity inversion. 6) Slug_test Includes the slug test data at all the groundwater wells provided as CSV files, as well as the Jupyter notebook (Slug_test.ipynb) for calculating hydraulic conductivity. 7) SP Contains the SP data collected in field at the SP sites (provided as CSV files). 8) Well_data Contains two subfolders: 1) Raw, which provides unprocessed pressure, electrical conductivity and temperature timeseries downloaded from the loggers in all the groundwater and stilling wells, and 2) Processed, which contains sorted, QA/QC timeseries data for each well. The data archive also contains data_process.ipynb, a Jupyter notebook used for field data analysis and generating figures (plotting well, SP, climate, and discharge data, as well as calculating head gradient at sites with nested groundwater wells). Note: Code files (.ipynb, .py, .xml) can be opened in any standard code editor, .exo file can be viewed using Paraview, .h5 files can be opened using HDFView software and h5py Python package, and .resipy file can be opened with the open-source ResIPy software.

ATS↗

UQpy: A general purpose Python package and development environment for uncertainty quantification

In this paper, we present the UQpy software toolbox, an open-source Python package for general uncertainty quantification (UQ) in mathematical and physical systems. The software serves as both a user-ready toolbox that includes many of the latest methods for UQ in computational modeling and a convenient development environment for Python programmers advancing the field of UQ. The paper presents an introduction to the software's architecture and existing capabilities, divided in the code in a set of modules centered around different UQ tasks such as sampling methods, generation of random processes and random fields, probabilistic inverse modeling, reliability analysis, surrogate modeling, and active learning. The paper also highlights the importance of the RunModel module, which is used to drive simulations in the uncertainty analyses performed in UQpy. This module conveniently allows the user to define computational models directly in Python, or to run simulations from a third-party software in serial or in parallel. To illustrate the various capabilities, two examples are tracked throughout the paper and analyzed repeatedly for various UQ tasks. The first is a Python model solving a nonlinear structural dynamics problem, used to illustrate UQpy's capabilities in sampling and forward propagation of high dimensional random vectors (stochastic processes), and probabilistic inference. The second model is a third-party Abaqus finite element model solving the thermomechanical response of a beam structure. This example is used to illustrate UQpy's capabilities in variance reduction sampling techniques, reliability analysis, surrogate modeling and active learning techniques.

97 MATHEMATICS AND COMPUTING↗

RAVEN Theory Manual

RAVEN is a software framework able to perform parametric and stochastic analysis based on the response of complex system codes. The initial development was aimed at providing dynamic risk analysis capabilities to the thermohydraulic code RELAP-7, currently under development at Idaho National Laboratory (INL). Although the initial goal has been fully accomplished, RAVEN is now a multi-purpose stochastic and uncertainty quantification platform, capable of communicating with any system code. In fact, the provided Application Programming Interfaces (APIs) allow RAVEN to interact with any code as long as all the parameters that need to be perturbed are accessible by input files or via python interfaces. RAVEN is capable of investigating system response and explore input space using various sampling schemes such as Monte Carlo, grid, or Latin hypercube. However, RAVEN strength lies in its system feature discovery capabilities such as: constructing limit surfaces, separating regions of the input space leading to system failure, and using dynamic supervised learning techniques. The development of RAVEN started in 2012 when, within the Nuclear Energy Advanced Modeling and Simulation (NEAMS) program, the need to provide a modern risk evaluation framework arose. RAVEN’s principal assignment is to provide the necessary software and algorithms in order to employ the concepts developed by the Risk Informed Safety Margin Characterization (RISMC) program. RISMC is one of the pathways defined within the Light Water Reactor Sustainability (LWRS) program. In the RISMC approach, the goal is not just to identify the frequency of an event potentially leading to a system failure, but the proximity (or lack thereof) to key safety-related events. Hence, the approach is interested in identifying and increasing the safety margins related to those events. A safety margin is a numerical value quantifying the probability that a safety metric (e.g. peak pressure in a pipe) is exceeded under certain conditions. Most of the capabilities, implemented having RELAP-7 as a principal focus, are easily deployable to other system codes. For this reason, several side activates have been employed (e.g. RELAP5-3D, any MOOSE-based App, etc.) or are currently ongoing for coupling RAVEN with several different software. The aim of this document is to provide a set of commented examples that can help the user to become familiar with the RAVEN code usage.

97 MATHEMATICS AND COMPUTING↗

Python Robust Phase Estimation (PyRPE)

Robust Phase Estimation (RPE) is a quantum algorithm to determine the relative phases of eigenstates of a unitary operator. This code implements the classical portion of the RPE algorithm, useful both in simulation (e.g., Sandia's pyGSTi or IBM's Qiskit simulators) and on actual quantum hardware (e.g., IBM's Qiskit Quantum Experience). It additionally implements improvements in these dependent software packages, for both required core function of the RPE and improved usability. SAND2020-12547 M Sandia National Laboratories is a multimission laboratory managed and operated by National Technology & Engineering Solutions of Sandia, LLC, a wholly owned subsidiary of Honeywell International Inc., for the U.S. Department of Energy's National Nuclear Security Administration under contract DE-NA0003525.

Russo, Antonio↗

RAVEN User Manual

RAVEN is a generic software framework to perform parametric and probabilistic analysis based on the response of complex system codes. The initial development was aimed to provide dynamic risk analysis capabilities to the Thermo-Hydraulic code RELAP-7, currently under development at the Idaho National Laboratory (INL). Although the initial goal has been fully accomplished, RAVEN is now a multi-purpose probabilistic and uncertainty quantification platform, capable to agnostically communicate with any system code. This agnosticism includes providing Application Programming Interfaces (APIs). These APIs are used to allow RAVEN to interact with any code as long as all the parameters that need to be perturbed are accessible by inputs files or via python interfaces. RAVEN is capable of investigating the system response, and investigating the input space using Monte Carlo, Grid, or Latin Hyper Cube sampling schemes, but its strength is focused to- ward system feature discovery, such as limit surfaces, separating regions of the input space leading to system failure, using dynamic supervised learning techniques. The development of RAVEN has started in 2012, when, within the Nuclear Energy Advanced Modeling and Simulation (NEAMS) program, the need to provide a modern risk evaluation framework became stronger. RAVEN principal assignment is to provide the necessary software and algorithms in order to employ the concept developed by the Risk Informed Safety Margin Characterization (RISMC) program. RISMC is one of the pathways defined within the Light Water Reactor Sustainability (LWRS) program. In the RISMC approach, the goal is not just the individuation of the frequency of an event potentially leading to a system failure, but the closeness (or not) to key safety-related events. Hence, the approach is interested in identifying and increasing the safety margins related to those events. A safety margin is a numerical value quantifying the probability that a safety metric (e.g. for an important process such as peak pressure in a pipe) is exceeded under certain conditions. The initial development of RAVEN has been focused on providing dynamic risk assessment capability to RELAP-7, currently under development at the INL and, likely, future replacement of the RELAP5-3D code. Most the capabilities that have been implemented having RELAP-7 as principal focus are easily deployable for other system codes. For this reason, several side activates are currently ongoing for coupling RAVEN with soft- ware such as RELAP5-3D, etc. The aim of this document is the explanation of the input requirements, focalizing on the input structure.

97 MATHEMATICS AND COMPUTING↗

Using CUBIT to Create Unstructured Mesh Models for MCNP Simulations

The Monte Carlo N-Particle (MCNP) transport code version 6 (also known as MCNP6) has the capability for tracking particles on unstructured mesh (UM) geometry models embedded into constructive solid geometry (CSG) cells. This feature has been developed for performing calculations of complex geometry models because creating CSG models is a time-consuming and error-prone process as the complexities of geometries increase. An MCNP UM calculation requires UM geometry input files. The UM capability was originally designed to work with UM models created with the Abaqus/CAE software and ASCII input files that it generates. The Abaqus-formatted input files needed for MCNP UM calculations must have the correct Abaqus syntax and meet the additional MCNP requirements. Several software packages can generate a UM model formatted as an Abaqus input file. Cubit, the Sandia National Laboratory automated mesh generation toolkit, can generate a UM model formatted as an Abaqus input file. However, the Abaqus input files created by Cubit cannot be used for MCNP simulations. A Python script has been developed to convert an Abaqus file created by Cubit to an Abaqus file that the MCNP code can process. This report describes the process of using Cubit to create UM models for MCNP calculations.

97 MATHEMATICS AND COMPUTING↗

Hydrologic Model Data for the East Fork Poplar Creek Watershed Simulated with the Advanced Terrestrial Simulator (ATS): Streamflow and Network Expansion–Contraction Dynamics

This dataset supports hydrologic modeling and stream network expansion–contraction analysis for the East Fork Poplar Creek (EFPC) Watershed in Tennessee. It includes a Jupyter notebook for model setup, model configuration files, simulation outputs, and derived products used to evaluate model performance and investigate stream dynamics under varying hydrologic conditions. The dataset was generated using the Watershed Workflow Python package and the Advanced Terrestrial Simulator (ATS), enabling integrated surface–subsurface hydrologic simulations using a stream-aligned mesh. Outputs include high-resolution time series of streamflow, active network length, water table depth, and related hydrologic variables. Also included are spatially explicit stream persistency indices and classifications of reaches as perennial or non-perennial. These data facilitate reproducibility and support further research on stream intermittency and variability in network extent.The model data archive is organized in following directories:1) model_setup_inputsContains the Watershed Workflow Jupyter notebooks (accessed through any open source code editor), selected input datasets, and resulting ATS input files, including XML files (access through any open source code editor), computational mesh (.exo files can be viewed using Paraview), and meteorological forcing files (.h5 files can be accessed through h5py python package and HDFView open source software). 2) model_outputsIncludes ATS simulation outputs relevant to this study. Time series of spatially integrated or averaged variables (e.g., streamflow, water table depth) are provided as CSV files. Select spatial fields (e.g., ponded depth and water table depth) are saved as pickled Python objects to reduce file size, and can be accessed through pickle package in Python. Key geometry objects from Watershed Workflow—such as the surface mesh and river tree—are also included to support analysis of streamflow persistency and expansion–contraction dynamics. These files can also be accessed through Watershed Workflow Python package.3) model_evaluationProvides observed streamflow time series and field survey-based flow regime classifications used to evaluate model performance. Jupyter notebooks for processing ATS outputs and comparing model predictions with observations to build confidence in the model prior to scientific analysis are also included.4) Q_L_relationshipsContains workflows for generating time series of discharge, active network length, and related hydrologic variables used in the stream network expansion–contraction analysis. Includes routines for delineating baseflow-dominated periods. For each catchment, notebooks and processed data (as pickled DataFrames accessed through Pandas Python package) are provided. 5) figure_scriptsProvides the Jupyter notebooks used to generate the figures presented in the paper.

54 ENVIRONMENTAL SCIENCES↗

Implementation of real‐time TDDFT for periodic systems in the open‐source PySCF software package

Abstract We present a new implementation of real‐time time‐dependent density functional theory (RT‐TDDFT) for calculating excited‐state dynamics of periodic systems in the open‐source Python‐based PySCF software package. Our implementation uses Gaussian basis functions in a velocity gauge formalism and can be applied to periodic surfaces, condensed‐phase, and molecular systems. As representative benchmark applications, we present optical absorption calculations of various molecular and bulk systems and a real‐time simulation of field‐induced dynamics of a (ZnO) 4 molecular cluster on a periodic graphene sheet. We present representative calculations on optical response of solids to infinitesimal external fields as well as real‐time charge‐transfer dynamics induced by strong pulsed laser fields. Due to the widespread use of the Python language, our RT‐TDDFT implementation can be easily modified and provides a new capability in the PySCF code for real‐time excited‐state calculations of chemical and material systems.

37 INORGANIC, ORGANIC, PHYSICAL, AND ANALYTICAL CH↗

Finding pythons in unexpected places

In this work, we argue that novel (highly nonclassical) quantum extremal surfaces (QESs) play a crucial role in reconstructing the black hole interior even for isolated, single-sided, non-evaporating black holes (i.e. with no auxiliary reservoir). Specifically, any code subspace where interior outgoing modes can be excited will have a QES in its maximally mixed state. We argue that as a result, reconstruction of interior outgoing modes is always exponentially complex. Our construction provides evidence in favor of a strong python’s lunch proposal: that nonminimal QESs are the exclusive source of exponential complexity in the holographic dictionary. We also comment on the relevance of these QESs to the geometrization of state dependence in the typicality arguments for firewalls.

71 CLASSICAL AND QUANTUM MECHANICS, GENERAL PHYSIC↗

MS2Planner: improved fragmentation spectra coverage in untargeted mass spectrometry by iterative optimized data acquisition

Motivation: Untargeted mass spectrometry experiments enable the profiling of metabolites in complex biological samples. The collected fragmentation spectra are the metabolite’s fingerprints that are used for molecule identification and discovery. Two main mass spectrometry strategies exist for the collection of fragmentation spectra: data-dependent acquisition (DDA) and data-independent acquisition (DIA). In the DIA strategy, all the metabolites ions in predefined mass-to-charge ratio ranges are co-isolated and co-fragmented, resulting in multiplexed fragmentation spectra that are challenging to annotate. In contrast, in the DDA strategy, fragmentation spectra are dynamically and specifically collected for the most abundant ions observed, causing redundancy and sub-optimal fragmentation spectra collection. Yet, DDA results in less multiplexed fragmentation spectra that can be readily annotated. Results: We introduce the MS2Planner workflow, an Iterative Optimized Data Acquisition strategy that optimizes the number of high-quality fragmentation spectra over multiple experimental acquisitions using topological sorting. Our results showed that MS2Planner increases the annotation rate by 38.6% and is 62.5% more sensitive and 9.4% more specific compared to DDA. Availability and implementation MS2Planner code is available at https://github.com/mohimanilab/MS2Planner. The generation of the inclusion list from MS2Planner was performed with python scripts available at https://github.com/lfnothias/IODA_MS.

47 OTHER INSTRUMENTATION↗

tomoCAM : fast model-based iterative reconstruction via GPU acceleration and non-uniform fast Fourier transforms

X-ray-based computed tomography is a well established technique for determining the three-dimensional structure of an object from its two-dimensional projections. In the past few decades, there have been significant advancements in the brightness and detector technology of tomography instruments at synchrotron sources. These advancements have led to the emergence of new observations and discoveries, with improved capabilities such as faster frame rates, larger fields of view, higher resolution and higher dimensionality. These advancements have enabled the material science community to expand the scope of tomographic measurements towards increasingly in situ and in operando measurements. In these new experiments, samples can be rapidly evolving, have complex geometries and restrictions on the field of view, limiting the number of projections that can be collected. In such cases, standard filtered back-projection often results in poor quality reconstructions. Iterative reconstruction algorithms, such as model-based iterative reconstructions (MBIR), have demonstrated considerable success in producing high-quality reconstructions under such restrictions, but typically require high-performance computing resources with hundreds of compute nodes to solve the problem in a reasonable time. Here, tomoCAM , is introduced, a new GPU-accelerated implementation of model-based iterative reconstruction that leverages non-uniform fast Fourier transforms to efficiently compute Radon and back-projection operators and asynchronous memory transfers to maximize the throughput to the GPU memory. The resulting code is significantly faster than traditional MBIR codes and delivers the reconstructive improvement offered by MBIR with affordable computing time and resources. tomoCAM has a Python front-end, allowing access from Jupyter -based frameworks, providing straightforward integration into existing workflows at synchrotron facilities.

73 NUCLEAR PHYSICS AND RADIATION PHYSICS↗

MaltQt

The code allows users to visualize data collected by the open source malt memory profiler. It is written in python and contains no physics whatsoever.

Balakireva, Lyudmila↗

sourcePy

Pollutant source identification techniques (of which there are many variations) are either locked behind researchers writing their own code for each use case or GUI platforms that are easy to use but inflexible and opaque. The Python package sourcePy brings together many of the pollutant source identification algorithms, giving the user full control out of the box. It aims to create a platform for source identification experiments where the full analysis from beginning to end can be done in Python, with a level of specificity in design that isn't available in the GUI options. sourcePy provides users with a few key features: -A Python interface with HYSPLIT, which can be used to generate trajectories and concentration plumes -Several Python classes which standardize the preparation and processing of data related to source identification experiments -Example scripts and notebooks that allow even new python users to get started with their own experiments quickly -Visualization methods

Arseneau, Isaac [Oak Ridge National Laboratory (OR↗

TEAMER: Pitching Foil Crossflow Turbine Efficiency Data

This dataset documents the efficiency testing of a pitching foil crossflow turbine, conducted at the University of New Hampshire's (UNH) Chase Ocean Engineering Laboratory tow tank facility. The tests explored various pitch phases and amplitudes, ranging from 0 to 18 degrees, across different flow speeds and turbine RPMs. Specifically, testing was performed at pitch amplitudes of 0,3,6,9,12,15 and 18 degrees. The results indicate that turbine efficiency improves with increased pitch amplitude, reaching optimal performance at 12 degrees. Modifications were made to the test frame by UNH to enhance the stiffness of the support structure. The testing specifically mapped the efficiency of a single quadrant of the Ocean Renewable Power Company (ORPC) Autonomous Turbine Generator Unit (ATGU), covering the full range of allowable pitching amplitudes and phases. The dataset provides both raw and processed data, including drag and torque measurements, and contains Python scripts used for data processing and visualization. This research was supported by funding from TEAMER RFTS 1 (Request for Technical Support).

16 TIDAL AND WAVE POWER↗

ThinCurr: An open-source 3D thin-wall eddy current modeling code for the analysis of large-scale systems of conducting structures

In this paper we present a new thin-wall eddy current modeling code, ThinCurr, for studying inductively-coupled currents in 3D conducting structures -- with primary application focused on the interaction between currents flowing in coils, plasma, and conducting structures of magnetically-confined plasma devices. The code utilizes a boundary finite element method on an unstructured, triangular grid to accurately capture device structures. The new code, part of the broader Open FUSION Toolkit, is open-source and designed for ease of use without sacrificing capability and speed through a combination of Python, Fortran, and C/C++ components. Scalability to large models is enabled through use of hierarchical off-diagonal low-rank compression of the inductance matrix, which is otherwise dense. Ease of handling large models of complicated geometry is further supported by automatic determination of supplemental elements through a greedy homology approach. Here, a detailed description of the numerical methods of the code and verification of the implementation of those methods using cross-code comparisons against the VALEN code and Ansys commercial analysis software is shown.

70 PLASMA PHYSICS AND FUSION TECHNOLOGY↗

TEAMER: Crossflow Turbine Fairing Geometry Optimization - Report and CFD Modeling Files

The dataset includes computational fluid dynamics (CFD) models and simulation files for crossflow turbines as well as a detailed project report. The report documents the project undertaken by the Ocean Renewable Power Company (ORPC) to design and optimize a modular fairing for the Modular RivGen Marine Hydrokinetic (MHK) turbine, which enhances the efficient deployment and operation of turbine arrays. The project focused on optimizing the hydrodynamic performance of the fairing using CFD, with an emphasis on two key geometric parameters: the fairing's cross-sectional shape and the spacing between the rotor and the fairing. The analysis aimed to maximize net power output while also assessing discretized loading to evaluate ultimate and fatigue loads on the turbine components. The numerical modeling was conducted using both the commercial CFD software Star-CCM+ and the open-source code openFOAM, with the latter utilizing the actuator line library, turbinesFOAM. This dual-code approach was intended to increase confidence in the results and demonstrate the viability of using open-source tools for high-fidelity marine energy modeling. This dataset includes all necessary files for actuator line simulations in openFOAM, as well as 2D blade-resolved CFD results, along with Python and Java scripts for setting up and post-processing simulations.

16 TIDAL AND WAVE POWER↗

In silico evolution of oscillatory gene dynamics formerly Code sharing for a manuscript to be submitted to the journal iScience

The disclosure is about the numerical simulations and visualization implemented in general-purpose language Python and C++. The simulations were in-silico evolution of hypothetical gene circuits that potentially admit oscillatory dynamics. The aim of the study, which was invited to be submitted to a special issue "Timekeeping, noise and development across kingdoms" in the journal iScience, is to demonstrate that in contrast to common belief, noise in gene expression dynamics could significantly facilitate the evolutionary process for searching oscillatory dynamics, which are essential for developing circadian rhythm in living organisms.

Lin, Yen Ting↗