EIS Equivalent-Circuit Fitting
Fit EIS data with equivalent-circuit models and export curves, parameters, and residual diagnostics.

After reviewing the Nyquist and Bode plots, you may want to convert the resistance, capacitance, diffusion, or transmission-line features in the spectrum into comparable parameters. This workflow is designed for that step.
It fits EIS data with an equivalent circuit and outputs fitted curves, parameter tables, and residual diagnostics for each sample. It is useful for comparing samples, treatment conditions, or interfacial kinetic changes before and after cycling.
Input Data
Select a folder containing instrument-exported raw EIS data, or multi-select a group of raw EIS data files. Common text, CSV, Excel, EC-Lab .mpr, Gamry .dta, and VersaStudio .par files can be recognized automatically.
Procedure
- Select EIS Data: choose a folder, or multi-select a group of files from the same experiment.
- Select a Circuit Model: use one of the preset models, or type a custom circuit expression.
- Configure Fit Parameters: use automatic initial values and recommended bounds by default; when needed, enter parameter rules for initial values, bounds, or fixed values.
- Review the Fit: after fitting, inspect the Nyquist fit, frequency-dependent residuals, and KK checks before using the parameters in a report or manuscript.
- Optionally Export a Word Analysis Report: generate an illustrated
.docxbatch report for archiving, communication, and further editing. - Optionally Export an Origin Project: generate an
.opjufile if you need further figure editing.
Circuit Expression Syntax
- Use
-for series connection, such asR0-C1. - Use
p(...)for parallel connection. For example,R0-p(C1,R1)means a series resistance followed by a capacitor/resistor parallel branch. - Full-width parentheses, Chinese commas, Chinese dash-like connectors, and
P(...)are accepted and normalized automatically. For example,R0-P(C1,R1)-W1is treated asR0-p(C1,R1)-W1. - Use numeric suffixes to distinguish elements of the same type, such as
R0,R1, andC1. - If an element is entered without a numeric suffix, the workflow adds one automatically. For example,
R0-p(C1,R1)-G-Lis treated asR0-p(C1,R1)-G1-L1. - If element identifiers are repeated, the workflow automatically assigns unique identifiers to later elements and shows both expressions. For example,
R0-p(CPE1,R1)-p(CPE1,R1)is normalized toR0-p(CPE1,R1)-p(CPE2,R2). After you confirm the normalized model, parameter settings, fitting, and exports all use the confirmed expression. - Multi-parameter elements are expanded into multiple fit parameters. For example,
CPE1corresponds toCPE1_0andCPE1_1;Wo1corresponds toWo1_0andWo1_1.
Common preset models:
R0-C1— series resistance + a single capacitorR0-p(C1,R1)— series resistance + parallel capacitor/resistor (the typical double-layer capacitance with charge-transfer resistance)R0-CPE1— series resistance + constant phase element (non-ideal capacitance)R0-p(CPE1,R1)— series resistance + parallel CPE/resistor (useful for rough interfaces, porous structures, or distributed time constants)R0-p(C1,R1)-W1— series resistance + (parallel capacitor/resistor) + Warburg (adds semi-infinite diffusion impedance after interfacial charge transfer)
See the "Element Overview" section below for the full list of supported elements with their units and impedance equations.
How to Configure Fit Parameters
In most cases, use the default settings. All parameters participate in the fit, while the workflow estimates initial values separately for each sample and uses recommended parameter bounds.
The parameter section lists every parameter in the current circuit with its units and recommended range. Leave the rule input blank to fit every parameter with automatic initial values and recommended bounds. Enter rules only when you need to override those settings:
R0=1.0: fixR0at1.0, excluding it from optimization and fitted confidence intervals.R1~100: fitR1with an initial value of100.R1>0orR1<=1e6: set a one-sided fitting bound.0<CPE1_1<=1: set both lower and upper bounds.R1~100, 0<R1<1e6: combine an initial value with bounds.
Separate rules with commas or semicolons. Full-width punctuation from Chinese input methods is also accepted. Parameters omitted from the rules retain automatic settings. Every rule applies to all samples selected for the run.
Fixed values should come from independent measurements, geometric relationships, or an explicit model hypothesis. A value obtained from one fit is not automatically a reliable physical prior. When a fixed value or input bound exceeds the recommended range, the workflow records and displays a warning but allows an expert user with a justified reason to continue. If an automatic initial value falls outside input bounds, it is moved inside those bounds and the adjustment is recorded.
If the initial values are uncertain but the circuit is relatively complex, you can enable global optimization. It explores a wider parameter space, but it also takes noticeably longer.
Output
Each sample produces:
*_circuit_fit.csv: experimental impedance, fitted impedance, and real/imaginary residuals.*_circuit_fit.png: Nyquist comparison between experimental points and the circuit fit, with frequency-dependent relative residuals.circuit_summary.json: circuit expression, original parameter rules, resolved initial values and bounds for each parameter, fixed values, warnings, fitted parameters, confidence intervals, and RMSE.
Batch-level results include:
fit_summary.csv: fitted parameters for all samples.fit_diagnostics.csv: fit quality and simple diagnostic information.fit_diagnostics.md: a quick-readable fitting report.filter_circuit_report.docx: an illustrated analysis report generated after clicking Export Word report.filter_circuit_fit.opju: optional Origin project.
The fitting report also contains a Markdown table with one row per sample and parameter. Its "Fixed rule" column uses the parameter=value format so that a result can be copied and fixed on a later run. In a batch run, a manually entered fixed value applies to every sample, so verify that the copied value is appropriate for the entire batch.
Word Analysis Report
The workflow exports one filter_circuit_report.docx for each fitting batch. The report includes:
- sample names, source file names, detected formats, file sizes, modification times, valid point counts, and frequency ranges;
- the preprocessing steps actually applied, plus explicit confirmation that smoothing, outlier removal, blank subtraction, and baseline correction were not applied;
- the circuit expression, fitting method, Lin-KK settings, parameter rules, initial guesses, bounds, fixed parameters, and parameter warnings;
- batch fitting summaries, data-integrity/high-frequency-real/KK checks, and necessary warnings;
- the circuit diagram, per-sample Lin-KK figures, Nyquist fitting figures, and complete parameter tables;
- interpretation limits, analysis workflow version, analysis time, and scientific package versions.
The report is generated from data available in the current fitting run. Lin-KK and fitting-quality labels are engineering screening aids only; they do not by themselves establish a unique circuit mechanism or parameter interpretation.
If the button shows Word export unavailable, upgrade Oparic and try again; fitting remains available.
How to Judge Whether the Fit Is Trustworthy
- The fitted line should closely follow the experimental points in the Nyquist plot, especially near the semicircle apex, low-frequency diffusion tail, and high-frequency intercept.
- A smaller
rmse_relmeans a smaller overall residual, but a small residual does not prove that the model is unique or mechanistically correct. - Parameters should have reasonable magnitudes. For example, solution resistance should be positive, and the CPE exponent is usually between 0 and 1.
- Do not interpret a single parameter in isolation. Compare the circuit structure, fitted plot, residuals, and electrochemical context together.
- If several circuits fit well, prefer the simpler model with clearer physical meaning.
Element Overview
The following table lists the equivalent-circuit elements supported by this workflow. Let and .
| Element | Fit Parameters | Units | Common Meaning |
|---|---|---|---|
R | R0 | Ohmic, solution, or charge-transfer resistance | |
C | C0 | Ideal capacitance, such as ideal double-layer capacitance | |
L | L0 | Inductance or high-frequency parasitic response | |
W | W0 | Semi-infinite Warburg diffusion impedance | |
Wo | Wo0_0, Wo0_1 | , | Open finite-space Warburg element |
Ws | Ws0_0, Ws0_1 | , | Short finite-length Warburg element |
CPE | CPE0_0, CPE0_1 | , dimensionless | Constant phase element for non-ideal capacitance |
La | La0_0, La0_1 | , dimensionless | Modified inductance for non-ideal inductive behavior |
G | G0_0, G0_1 | , | Gerischer element for coupled reaction-diffusion response |
Gs | Gs0_0, Gs0_1, Gs0_2 | , , dimensionless | Finite-length Gerischer element |
K | K0_0, K0_1 | , | Single RC relaxation process |
Zarc | Zarc0_0, Zarc0_1, Zarc0_2 | , , dimensionless | Depressed semicircle or Cole-Cole-type relaxation |
TLMQ | TLMQ0_0, TLMQ0_1, TLMQ0_2 | , , dimensionless | Simplified transmission-line model with non-ideal interfacial capacitance |
T | T0_0, T0_1, T0_2, T0_3 | , , dimensionless, | Macrohomogeneous porous-electrode transmission-line model |
Appendix: Element Equations
The series and parallel combination rules are:
The impedance expressions for the supported elements are:
| Element | Equation |
|---|---|
R | |
C | |
L | |
W | |
Wo | |
Ws | |
CPE | |
La | |
G | |
Gs | |
K | |
Zarc | |
TLMQ | , where |
T | , where |
For multi-parameter elements, _0, _1, _2, and _3 follow the parameter order in the equation. For example, CPE1_0 is and CPE1_1 is ; Wo1_0 is and Wo1_1 is ; Gs1_0, Gs1_1, and Gs1_2 are , , and , respectively. Use the units listed in the Element Overview table above.
Practical Tips
If you have not yet inspected the raw EIS curves, use EIS Plotting: Nyquist and Bode first to review the Nyquist and Bode plots. If the curve contains obvious outliers, inductive tails, or low-frequency drift, address the data quality before fitting an equivalent circuit.
If the circuit parameters are unstable or difficult to interpret, use EIS/DRT Analysis to inspect the distribution of relaxation times, then return to this workflow with a more physically motivated circuit structure.