Search NASA⌕ Search

SEARCH · Search NASA

Results for “MATLAB”

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

PDMATLAB2D: A Peridynamics MATLAB Two-dimensional Code

PDMATLAB2D is a meshfree peridynamics implementation in MATLAB suitable for simulation of two-dimensional fracture problems. The purpose of this code is twofold. First, it provides an entry-level peridynamics computational tool for educational and training purposes. Second, it serves as an accessible and easily modifiable computational tool for peridynamics researchers who would like to adapt the code for a multitude of peridynamics simulation scenarios. The current version of the code implements a bond-based brittle elastic peridynamic model and a critical stretch criterion for bond breaking. However, the code is designed to be extendable for other peridynamic models and computational features. In this paper, we provide an overview of the code structure and functions with illustrative examples. In conclusion, due to the integrated computation and postprocessing MATLAB capabilities, PDMATLAB2D can serve as an effective testbed for testing new constitutive models and advanced numerical features for peridynamics computations.

97 MATHEMATICS AND COMPUTING↗

Matlab Code for Multiscale Topology Optimization

This Matlab script implements a simple topology optimization algorithm that minimizes the compliance of a structure within a 3D prismatic design domain. It uses a simple linear elastic finite element solver to solve the equilibrium equations, and the optimality criterion (00) method to update the design iteratively. This functionality is identical to, or the simplest possible extension from 2D to 3D of, a 99-line Matlab code released in 2001 in a journal article by Sigmund. What is new in this code is our implementation of simple surrogate models for several truss micro-architectures, which converts this code to a multiscale design tool, whereas the original code is single-scale. The development of these surrogate models and their implementation is described in a journal article we intend to submit. We plan to include the full source code in an Appendix in this paper. The code’s primary function is as a pedagogical tool rather than as a finished software product. Sigmund’s 2001 paper describes the implementation line-by-line. We are including this updated version of the code to allow the reader to understand exactly what changes must be made to a “standard” topology optimization code to implement the surrogate models and thus multiscale design optimization.

Watts, Seth↗

MatLab Package for Whispering Gallery Mode Data

Dye-doped whispering gallery mode resonator (WGMR) microspheres yield highly structured emission spectra that are extremely sensitive to their environment and are of intense interest for use in a variety of sensing applications. Efforts to leverage the unique sensitivities of WGMRs have relied on stringent experimental requirements to correlate specific spectral shifts/changes to an analyte/stimulus such as 1) precise positional knowledge, 2) reference spectra for each microsphere, and 3) high mechanical stability. Consequently, these can hinder adequate mixing or incorporation of analytes and creates challenges for remote sensing. The MATLAB codes provided here are to be used in conjunction with a continuous flow technique for measuring WGM spectra of dye-doped microspheres suspended in solution. One MATLAB script, smooths the data, automatically baseline corrects it to isolate the whispering gallery modes (WGM) from the unwanted bulk emission, and assesses the similarity of each spectrum to aid in selecting a set of unique WGM spectra for further analysis. The next script is designed to analyze WGM spectra to determine the size of the resonator and the refractive index (RI) of its local environment without a priori knowledge of the individual microsphere. The final script allows the user to cluster spheres based on the product of their RI and radius and the contrast ratio of the RI of the sphere material and that of its environment by using a shared nearest neighbor spectral clustering algorithm.

Lilley, Laura↗

Deep Lynx Matlab Adapter

The Deep Lynx MATLAB Adapter is a Python application that connects the Deep Lynx data warehouse with any MATLAB simulation.

Wilsdon, KatherineN [Idaho National Laboratory] (0↗

PolyMat: an efficient Matlab code for multi-material topology optimization

We introduce a Matlab implementation of topology optimization for compliance minimization on unstructured polygonal finite element meshes that efficiently accommodates many materials and many volume constraints. Leveraging the modular structure of the educational code, PolyTop, we extend it to the multi-material version, PolyMat, with only a few modifications. First, a design variable for each candidate material is defined in each finite element. Next, we couple a Discrete Material Optimization interpolation with the existing penalization and introduce a new parameter such that we can employ continuation and smoothly transition from a convex problem without any penalization to a non-convex problem in which material mixing and intermediate densities are penalized. Mixing that remains due to the density filter operation is eliminated via continuation on the filter radius. To accommodate flexibility in the volume constraint definition, the constraint function is modified to compute multiple volume constraints and the design variable update is modified in accordance with the Zhang-Paulino-Ramos Jr. (ZPR) update scheme, which updates the design variables associated with each constraint independently. The formulation allows for volume constraints controlling any subset of the design variables, i.e., they can be defined globally or locally for any subset of the candidate materials. Borrowing ideas for mesh generation on complex domains from PolyMesher, we conclude which design variables are associated with each local constraint of arbitrary geometry. A number of examples are presented to demonstrate the many material capability, the flexibility of the volume constraint definition, the ease with which we can accommodate passive regions, and how we may use local constraints to break symmetries or achieve graded geometries.

79 ASTRONOMY AND ASTROPHYSICS↗

KSSOLV 2.0: An efficient MATLAB toolbox for solving the Kohn-Sham equations with plane-wave basis set

KSSOLV (Kohn-Sham Solver) is a MATLAB toolbox for performing Kohn-Sham density functional theory (DFT) calculations with a plane-wave basis set. KSSOLV 2.0 preserves the design features of the original KSSOLV software to allow users and developers to easily set up a problem and perform ground-state calculations as well as to prototype and test new algorithms. Furthermore, it includes new functionalities such as new iterative diagonalization algorithms, k-point sampling for electron band structures, geometry optimization and advanced algorithms for performing DFT calculations with local, semi-local, and hybrid exchange-correlation functionals. It can be used to study the electronic structures of both molecules and solids. So, we describe these new capabilities in this work through a few use cases. We also demonstrate the numerical accuracy and computational efficiency of KSSOLV on a variety of examples.

97 MATHEMATICS AND COMPUTING↗

LandMOD ET mapper: A new matlab-based graphical user interface (GUI) for automated implementation of SEBAL and METRIC models in thermal imagery

Remote sensing based surface energy balance (SEB) models, such as SEB Algorithm for Land (SEBAL) and Mapping evapotranspiration (ET) at high Resolution with Internalized Calibration (METRIC) are widely used to monitor ET. However, their operational use is challenged by model complexity and the tedious process of selecting hot and cold pixels. We developed a new Matlab-based ET mapping toolbox named “LandMOD ET Mapper” for automated implementation of these models to facilitate their widespread applications among new users. The toolbox is demonstrated using one Landsat and one Moderate Resolution Imaging Spectroradiometer (MODIS) Terra image covering three AmeriFlux sites in Nebraska, U.S. Daily ET estimates were comparable with the observed ET for five days when near cloud-free Landsat and MODIS Terra images were available in the 2006 maize growing season. The toolbox provides a viable ET mapping option to new and inexperienced users with reduced time and labor demands.

54 ENVIRONMENTAL SCIENCES↗

baseflow: a MATLAB and GNU Octave package for baseflow recession analysis

baseflow is a MATLAB® toolbox designed for baseflow recession analysis, a technique used in hydrologic science to infer aquifer properties from streamflow. By leveraging widely available streamflow data, baseflow can be used to estimate aquifer properties such as hydraulic conductivity and drainable porosity over the modern instrumental stream gage record. The toolbox is intended for analysis of measured streamflow values recorded on a daily timestep, and is tailored for shallow, unconfined riparian aquifers that discharge groundwater laterally into adjacent streams. Additionally, baseflow can analyze the collective behavior of individual hillslope aquifers constituting hydrologic catchments, known as “watersheds”, from a nonlinear dynamical systems perspective. The toolbox incorporates recent advances in baseflow recession analysis to enable objective estimations of aquifer properties, and their sensitivity to methodological decisions, at both hillslope and catchment scales.

97 MATHEMATICS AND COMPUTING↗

Matlab implementation of a novel semi-structured kinetic model for methanotroph-photoautotroph cocultures

This paper presents the MatLab implementation details of a novel semi-structured kinetic model for methanotroph-photoautotroph cocultures. This includes the parameterization of the modeling equations, and the initialization of the simulation based on experimental conditions. More importantly, it provides details on how the differential equations governing mass balances in both gas and liquid phases are integrated together to simulate the system dynamics over time. The semi-structured kinetic model for methanotroph-photoautotroph coculture is validated using a wide range of experimental conditions. The model: Accurate predicts both the coculture growth in liquid phase and the gas composition changes in head space over time; Explicitly models the exchange of in situ produced O 2 and CO 2 within the coculture; Considers the self-shading effect on the growth of photoautotroph.

42 ENGINEERING↗

Version 2.0.0 - M-SPARC: Matlab-Simulation Package for Ab-initio Real-space Calculations

M-SPARC is a Matlab code for performing ab initio Kohn–Sham Density Functional Theory simulations. Version 2.0.0 of the software further extends its capability to include relativistic effects, dispersion interactions, and advanced semilocal/nonlocal exchange–correlation functionals. These features significantly increase the fidelity of first principles calculations that can be performed using M-SPARC.

97 MATHEMATICS AND COMPUTING↗

Ultrafast Laser Pulse Generation by Mode Locking: MATLAB-Based Demonstrations

Ultrafast laser spectroscopy is a valuable and increasingly accessible technique for studies of rapid chemical reactions. Critical to ultrafast spectroscopy is the concept of mode locking, a technique that enables a fixed phase relationship between laser modes, resulting in laser pulses with very short duration (in the fs or ps range). Despite the increasing importance of ultrafast lasers in chemistry, the introduction of key concepts behind their operation into the undergraduate and graduate chemistry coursework has been limited. To help the incorporation of these topics into chemistry courses, we report here a hands-on activity that helps students develop an intuitive understanding of the factors that impact electromagnetic wave evolution in optical cavities and the process of mode locking. We first provide the theoretical background by introducing cavity modes and contrasting them with well-known propagating electromagnetic waves. We then explore what happens when modes are added and how the relative phase between the modes affects their behavior. In the second section of this report, three teaching modules are provided, along with associated MATLAB codes and animated images, that can be used in the classroom to introduce concepts of cavity modes and mode locking. These teaching modules start by contrasting propagating electromagnetic waves with cavity modes and then illustrate what happens when multiple modes are present in the cavity and how the relative phase between the modes affects the overall electromagnetic field in the cavity.

37 INORGANIC, ORGANIC, PHYSICAL, AND ANALYTICAL CH↗

Teaching Nonradiative Transitions with MATLAB and Python

Nonradiative transitions are changes in energy states of atoms, ions, or molecules that do not involve the emission or absorption of photons. Despite their importance in understanding luminescent properties and photochemical reaction mechanisms, nonradiative transitions are rarely given more than a qualitative overview in undergraduate and even graduate physical chemistry curricula. To supplement the coverage of nonradiative transition topics, we provide here a set of active learning exercises to help students develop an intuitive understanding of the factors that determine the rate of nonradiative transitions. Here, we start by outlining the theoretical background through the formulations of the Franck–Condon factor and its relation to the rate of nonradiative transition. We then introduce three teaching modules, with associated MATLAB and Python codes, to explore how (1) the excited state nuclear displacement, (2) the electronic energy gap between excited and ground state and (3) the excited/ground state vibrational mode frequencies affect the magnitude of the Franck–Condon factor and thereby the rate of nonradiative transitions. The wave function overlap plots that accompany all teaching modules provide direct visualization of the effect of input parameters on the magnitude of Franck–Condon overlap integral.

37 INORGANIC, ORGANIC, PHYSICAL, AND ANALYTICAL CH↗

ED-LPD, MATLAB standalone

This computer software is a MATLAB standalone code for implementation of the Lumped Particle Domain model. The model solves charge transfer kinetics, lithium diffusion dynamics, charge conservation and energy conservation occurring across the porous electrode pair unit cell sandwich to predict electrical and thermal response of a battery. Physico-chemical states of batteries are also evaluated by the model.

Kim, Gi-Heon↗

Bead-Tracking Toolbox for MATLAB

A collection of MATLAB scripts forming a toolbox for video (frame by frame) detection and tracking of beads imaged with fluorescence microscope for estimating bead flow and location tracks. Scripts accept tiff image stacks of video frames and provide bead locations and tracked positions over frames in stack. Various utility functions are also provided to assist in data I/O. A custom solution for specific data source - specifically, the software works well for noisy/out of focus florescence microscopy images.

Rose, DerekC.↗

2-D Surface Temperature Simulation Data and Matlab Scripts

SAND2023-07249O The 2-D Surface Temperature Simulation Data and Matlab software can estimate 2D temperature fields from electrical measurements along the edge of the 2D domain. 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.

Sjoberg, Carl Magnus↗

ISAP-MATLAB Package for Sensitivity Analysis of High-Dimensional Stochastic Chemical Networks

Stochastic simulation and modeling play an important role to elucidate the fundamental mechanisms in complex biochemical networks. The parametric sensitivity analysis of reaction networks becomes a powerful mathematical and computational tool, yielding information regarding the robustness and the identifiability of model parameters. However, due to overwhelming computational cost, parametric sensitivity analysis is a extremely challenging problem for stochastic models with a high-dimensional parameter space and for which existing approaches are very slow. Here we present an information-theoretic sensitivity analysis in path-space (ISAP) MATLAB package that simulates stochastic processes with various algorithms and most importantly implements a gradient-free approach to quantify the parameter sensitivities of stochastic chemical reaction network dynamics using the pathwise Fisher information matrix (PFIM; Pantazis, Katsoulakis, and Vlachos 2013). The sparse, block-diagonal structure of the PFIM makes its computational complexity scale linearly with the number of model parameters. As a result of the gradientfree and the sparse nature of the PFIM, it is highly suitable for the sensitivity analysis of stochastic reaction networks with a very large number of model parameters, which are typical in the modeling and simulation of complex biochemical phenomena. Finally, the PFIM provides a fast sensitivity screening method (Arampatzis, Katsoulakis, and Pantazis 2015) which allows it to be combined with any existing sensitivity analysis software.

37 INORGANIC, ORGANIC, PHYSICAL, AND ANALYTICAL CH↗

MATLAB Reference [Slides]

These slides are intended to be used as a reference for the MATLAB programming language and development environment.

97 MATHEMATICS AND COMPUTING↗

Plotting XPS Narrow Scans (and Other data) with MATLAB, 1. Using the 'plot' and 'subplot' functions.

As researchers, we often focus more on data collection than data work-up. However, skillfully plotting data so that it can be effectively visualized is often an important step toward making it impactful. Data visualization in academic writing takes the form of plots, figures, graphs, spectra, etc., which are often combined with cartoons and schematics. An important goal of data visualization is to make complex data and concepts more accessible, understandable, and usable, and to do this in a concise manner – ‘a picture is worth a thousand words’ as the old cliché goes. Data visualization is both art and science, where, of course, data visualization depends on the type of data in question. Herein, we discuss ways of representing/plotting data using MATLAB from the MathWorks ® .

97 MATHEMATICS AND COMPUTING↗