The Hydrogen Permeation and Absorption Tool (HyPAT v2.0.0) is an application that streamlines data analysis for hydrogen permeation and absorption experiments to measure the following hydrogen transport properties: permeability, diffusivity, and solubility. Specifically, HyPAT analyzes data from gas-driven permeation through metals using the build-up in closed volume method and data from absorption experiments using a Sieverts'-type apparatus. A built-in literature database provides direct comparison for experimental results as well as timescale and permeation rate estimates for experiment preparation based on the user-input parameters.
Find more details about HyPAT v1.0.0 in the SoftwareX publication "HyPAT: A GUI for high-throughput gas-driven hydrogen permeation data analysis." Find more details about HyPAT v2.0.0 in the SoftwareX publication "Hydrogen Permeation and Absorption Tool (HyPAT v2.0): An update to facilitate analyses of data from hydrogen absorption experiments."
The Hydrogen Permeation and Absorption Tool (HyPAT) provides a convenient application that allows the user to prepare permeation experiment estimates, quickly analyze multiple data files, and compare results to literature values.
Features:
- Calculates the hydrogen transport properties of permeability, diffusivity, and solubility from experimental pressure-rise permeation data.
- Calculates the hydrogen transport properties of permeability, diffusivity, and solubility from experimental absorption data obtained from a Sieverts'-type apparatus.
- Batchwise data analysis of multiple files.
- Direct comparison of measured hydrogen transport properties to known literature values.
- Predicts the permeation rates and diffusion times of permeation experiments.
- Easily customizable to adapt to user needs and experimental setups.
This tab calculates the hydrogen transport properties permeability, diffusivity, and solubility from experimental permeation data using pressure build-up in a secondary side closed volume while allowing for batchwise data analysis of multiple files. The required user inputs and associated errors are highlighted in yellow. Thickness (mm) is the only required sample property. The experimental apparatus parameters are the secondary side volume (m3) and permeation surface area (m2).
Clicking the "Steady State Variables" button beneath the top-right plot allows the user to edit the tolerance for determining steady state, the delay until steady state, and the number of points used to find the leak rate and steady state rate. The tolerance is the value at which the second derivative of the secondary side pressure with respect to time (∂2P/∂t2) is approximated to be zero. The delay until steady state is the minimum number of seconds to wait after the isolation valve is opened until initiating analysis to detect steady state. The leak range is the number of data points prior to opening the isolation valve used to determine the leak rate and initial values. The steady state range is the number of data points used to determine final values and when the permeation rate has reached a steady state.
Click the "Choose folder" button to select the folder containing experimental data. The graphs will then self-populate. Note: Only XLS and XLSX files are processed by the program; all other files are ignored. HyPAT assumes data is organized such that the data of each instrument (or set of instruments) has its own column in the Excel sheet without a header.
The bottom left graph displays the permeability calculated from each data set plotted against temperature. Use the "Current Measurement" drop-down menu to change to the diffusivity, solubility, or flux calculated from each file plotted against temperature (or against pressure, in the case of flux).
Also visible are a pressure versus time plot, a permeability versus time plot, and a comparison of different diffusivity optimizations plot, all using data from the first file in the selected folder. Use the "Current File" drop-down menu to use data from a different file for these plots.
By clicking the "Settings" button, you gain the ability to edit some of how the program processes the data. Specifically, the following parameters are editable:
- The columns of the Excel sheet from which the program reads data for each instrument,
- The row at which the program starts reading data from the Excel sheet,
- The number of rows at the end of the Excel sheet to ignore when reading data,
- The number of thermocouples used to measure the gas temperature,
- Conversion factors for each instrument to facilitate appropriate unit conversions,
- Constant and proportional errors of each instrument.
The "Absorption Plots" tab calculates the hydrogen transport properties permeability, diffusivity, and solubility from experimental absorption data obtained using a Sieverts'-type apparatus. HyPAT does this while allowing for batchwise data analysis of multiple files. The required user inputs and associated errors are highlighted in yellow. Thickness (mm), mass (g), volume (cm3), and molar mass (g mol-1) are the required sample properties. The required experimental apparatus parameters are the initial container volume (cm3) and the sample container volume (cm3). HyPAT also requires the user to submit whether the experiment type is "Single," meaning each data file has the sample measured at only one pressure, or "Isotherm," meaning at least one data file has the sample measured at multiple pressures along an isotherm.
Clicking the "Equilibrium Variables" button immediately beneath the top-right plot allows the user to edit the tolerance for determining equilibrium, the delay until equilibrium, the number of points used to find the equilibrium, and the number of data points used to find initial and equilibrium values. The tolerance is the value at which the second derivative of the pressure with respect to time (∂2P/∂t2) is approximated to be zero. The delay until equilibrium is the minimum number of seconds to wait after the isolation valve is opened until initiating analysis to detect equilibrium. The initial values range is the number of data points prior to opening the isolation valve used to determine the initial values. The equilibrium range is the number of data points used to determine final values and when the absorption rate has reached an equilibrium.
Click the "Choose folder" button to select the folder containing experimental data. The graphs will then self-populate. Note: Only XLS and XLSX files are processed by the program; all other files are ignored. HyPAT assumes data is organized such that the data of each instrument (or set of instruments) has its own column in the Excel sheet without a header.
The bottom left graph displays the solubility calculated from each data set plotted against temperature. Use the "Current Measurement" drop-down menu to change to the diffusivity or permeability calculated from each file plotted against temperature. The bottom middle graph displays the final pressure of each data set plotted against the final composition. The points are color coded according to final sample temperature, yielding a pressure-composition-temperature (PCT) plot.
Also visible are a raw data plot and a comparison of different diffusivity optimizations plot, each using data from the first file in the selected folder. Use the "Current File" drop-down menu to use data from a different file for the raw data and diffusivity comparison plots.
By clicking the "Settings" button, you gain the ability to edit some of how the program processes the data. Specifically, the following parameters are editable:
- The columns of the Excel sheet from which the program reads data for each instrument,
- The row at which the program starts reading data from the Excel sheet,
- The number of rows at the end of the Excel sheet to ignore when reading data,
- The number of thermocouples used to measure the gas temperature initially and after the isolation valve is opened,
- Conversion factors for each instrument to facilitate appropriate unit conversions,
- Constant and proportional errors of each instrument.
The "Overview Plots" tab allows quick comparison to literature values of diffusivity, solubility, and permeability taken from M. Shimada (2020). The user can select and remove materials displayed in these overview plots using the materials column. Materials can be added to, modified, or removed from the database with the "Add/Edit Material" button.
The button labelled "Arrhenius Fit" calculates the pre-exponential factors and activation energies of diffusivity, solubility, and permeability for a material.
Reference:
M. Shimada, "Tritium Transport in Fusion Reactor Materials" in Comprehensive Nuclear Materials 6, Second Edition, Elsevier (2020); https://doi.org/10.1016/B978-0-12-803581-8.11754-0
The "Permeation Estimates" tab provides predictions for permeation experiments based on specified user inputs. The required user inputs are highlighted in yellow. The sample properties are thickness (mm) and material. The experimental apparatus parameters are O-ring/sealing method, calibrated leak rate (mol s-1 Torr-1), secondary side volume (cc), and accumulation time (hr). The specific test parameters are sample temperature (°C) and primary calculated partial pressure (Torr).
The results reported in the "FINAL OUTPUT" section include estimated time-lag (s), permeation rate (mol s-1), and final secondary pressure (Torr).
By clicking the "Settings" button, O-rings can be added, edited, or removed. The default values for calibrated leak rate and secondary side volume can also be edited there. The options for sample material can be edited using the "Add/Edit Material" button on the "Overview Plots" tab.
- Select the button "Code" near the top of this directory.
- Select "Download ZIP" from the dropdown menu that appears.
- Extract the downloaded file to a folder of your choice.
- Open the command line, then move to the directory "HyPAT" within the downloaded folder.
- Run the following code to open the application: python main.py
- Note:
- Your system may require the following code instead: python3 main.py
- These instructions assume you already have Python and the required Python packages installed.
Python Interpreter: 3.8, 3.9, or 3.10
Python Packages: Matplotlib, Pandas, NumPy, tkmacosx, mplcursors, SciPy, and openpyxl
Compatible: macOS and Windows 10
There are no current updates planned for HyPAT.
The most recent updates made on this branch of HyPAT are made by contributor Nathan Gehmlich. the updates are as follows:
The plots of "pressure v time" and "permeability v time" had arbitrary units of time given by the data collecting computer. This recent update takes the first recorded time from the data file and subtracts this time from all other recorded times. This sets the first time as t=0 seconds and all others following that. The plots then use this updated scale to be more readable. This timescale is also helpful in calculating the diffusivity uncertainty in the time lag method.
In order to better compare the diffusivity calculated from the time lag method and the optimized method, the update includes two diffusivity outputs calculated from both methods. The time lag diffusivity was already calculated in the code, new code was implemented to find the time lag diffusivity uncertainty. This uncertainty was found using propagation of uncertainty from the x intercept. This code can be found in lines 1336-1346 in permeation_plots.py.
Another output added was the time to steady state, this was included for the purpose of comparing the estimated time to steady state from the estimates tab.
In this update, a new way to calculate the pressure derivative was used. The previous method only relied on a single point and the point ahead of it. This improved derivative is commonly called the "5-point stencil," it takes the derivative based on the 2 points ahead and behind the point that is beign differentiated. This method allows for more accuracy in numerically differentiating.
In this update, an option to filter the original secondary pressure data can be applied to smooth the data more and significantly decreases the uncertainty in the optimized diffusivity calculation. The filter used is the "Savitzky-Golay filter." This filter fits windows of this data to a polynomial of a desired degree. The window size as well as the degree of the polynomial can be adjusted to the users liking on the "Filter and Smoothing" tab. Playing with the window size and polynomial degree, the lowest amount of uncertainty was found with a 2nd degree polynomial and a window size of about 20. This tab also allows to turn on and off the filter completely as well as the rolling average smoothing that occurs. (This Rolling average was the only data smoothing that was used before adding the filter option function.) Note: The toggle switch that allows for the on/off feature of the rolling average only applies to the first derivative of the secondary pressure. The second derivative is also calculated in finding the steady state, however the rolling average is always present to this deriviative in this stage of the code.
If you notice a feature that you want or a bug that needs to be fixed, please contact Chase Taylor or Thomas Fuerst.
George Evans
Joseph Watkins
Thomas Fuerst
Chase Taylor
Nathan Gehmlich
Joey Watkins (https://github.com/joeymwatkins) built most of the original functionality. George Evans (https://github.com/GeorgeEvans0) added the "Absorption Plots" tab, cleaned up errors, made visual changes, and added functionality. Thomas Fuerst (https://github.com/FuerstT) was the primary supervisor over this project, with Chase Taylor (https://github.com/taylchas) as secondary supervisor. Nathan Gehmlich (https://github.com/BigNate7) provided updates to the code as of 08/15/23.
This work was prepared for the U.S. Department of Energy, Office of Fusion Energy Sciences, under the DOE Idaho Field Office contract number DE-AC07–05ID14517.
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the file "LICENSE" for the specific language governing permissions and limitations under the License.