Giter VIP home page Giter VIP logo

eistoolbox's Introduction

eistoolbox

eistoolbox is a toolbox for MATLAB(R) used for batch fitting Electrochemical Impedance Spectroscopy (EIS) data to equivalent circuit models.

The goal is to calculate the optimal circuit elements using standard minimization functions, such as the complex nonlinear least-squares method.

After obtaining the best fit, the toolbox also estimates the chi-square Goodness-of-Fit. This parameter describes how well the fitted data adjusts to the original measured data.

The toolbox is currently under active development.

Instructions

Run 'eistoolbox.m' to start the main program!

  1. Add CSV or DTA data with the button 'Add files...'
  2. Write your circuit in the dialog (based on Zfit format)
  3. Select the fitting algorithm
  4. Hit the 'Fit' button!
  5. Save the results with the button 'Save as...'

Input file formats

  • CSV files must have three columns: FREQ,REAL,IMAG
  • DTA files are from Gamry Instruments (tested Gamry 1000 Interface)

Circuit string formats

At the moment, circuits can be written according to the Zfit specification:

-Elements can be connected in series as s(R1,R1) or in parallel as p(R1,R1) with as many elements as you want. Example: s(R1,R1,C1,C1,p(R1,C1,E2))

-All elements must include the number of fitting parameters. A resistance has one fitting parameter and therefore it is R1. A CPE has two parameters and therefore is written as E2.

-Careful! Do not treat elements as labels (i.e. R1, R2, R3... is incorrect.) The correct way is R1, R1 and R1.

-ToDo: Click the "load" button next to the fit string to load some predefined circuit examples.

-Read the source of the file Zfit.m for full documentation about circuit string formatting.

Screenshots

Main window of eistoolbox

Results screen

Correlations screen

External libraries used in this toolbox

export_fig by Yair Altman is found here

fminsearchbnd by John D'Errico is found here.

Zfit is from Jean-Luc Dellis, available here.

More fitting functions will be available in the future (such as Levenberg-Marquardt, Nelder-Mead, BFGS, Powell). If you have more algorithm suggestions, let me know.

License

Copyright (C) 2016 Juan J. Montero-Rodriguez

This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, in the version 3.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/.

Capabilities already implemented

  • Read Gamry DTA files from Gamry Framework
  • Read CSV files in the format [FREQ,REAL,IMAG]
  • Fitting engine (thanks to Zfit from Jean-Luc Dellis!)
  • Weighting functions: Proportional, Unit and Modulus
  • Algorithms: fminsearchbnd (thanks to John D'Errico)
  • Algorithms: genetic algorithm (experimental!)
  • Algorithms: simulated annealing (experimental!)
  • Algorithms: fmincon (experimental!)
  • Plot input data as Bode/Nyquist/ReIm plots
  • Plot fitted data as Bode/Nyquist/ReIm plots
  • Simulate circuits without fitting (using initial parameter values)
  • Add button for saving each plot individually (thanks to export_fig from Yair Altman)
  • Display fitting results as a table
  • Compute linear correlation coefficients between fitted vs. measured data
  • Compute Chi2 Goodness-of-Fit test
  • Save fitting results and statistics as XLS spreadsheet (csvwrite does not work on Linux!)

Planned for future releases

  • Algorithms: Levenberg-Marquardt
  • Algorithms: Nelder-Mead
  • Algorithms: BFGS
  • Algorithms: Powell
  • Algorithms: Other algorithms
  • Compute the Kramers-Kronig test

If you have comments or suggestions, send me an e-mail

eistoolbox's People

Contributors

jmonrods avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar Yashwanth Pochareddy avatar junting bao avatar Stefan Skoog avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.