A SMALLER DIODE STEP DOES NOT AUTOMATICALLY GIVE A BETTER SLOPE

This package contains a design and software tested on a computer. No physical
measurements, firmware build, native import or publication are claimed. Read the
full article before wiring or interpreting a measurement.

RUN WITH PYTHON 3

Extract into a new directory. Use the Python standard library; no extra packages
or target board are required. Commands:

 python3 -m unittest -v test_diode_brackets.py
 python3 diode_brackets.py constructed-example.csv --kind constructed
 python3 diode_brackets.py physical-blank.csv --kind observed
 python3 make_constructed.py new-constructed-directory

The blank-physical command must exit 2 until all measured cells are filled. The
generator refuses a populated destination. Its illustrative values are quantized
to 1 mV and are explicitly constructed, not bench data. Keep them separate from
the physical worksheet. --kind is a mandatory declaration, not proof of acquisition.

Exit 0 means a valid JSON report, possibly unsupported or unresolved. JSON means
JavaScript Object Notation, the structured output text. Check controls_passed,
interpretation_supported, conditional_model and the chord flags. Exit 2 means
malformed/incomplete input: standard error (stderr), the terminal error-output
stream, explains the problem and no JSON is emitted.

EXACT FIXTURE

D1: Vishay 1N4148-TAP, axial DO-35/DO-204AH. Its black band marks the cathode.
R1: Vishay MRS25000C3901FCT00, 3.90 kΩ ±1%.
Control: Vishay MRS25000C1001FCT00, 1.00 kΩ ±1%, replacing D1.
Source: RIGOL DP832A channel 1 (CH1); other outputs off. Start at zero with output
disabled. Set a 10 mA current limit and 5.0 V overvoltage protection (OVP), keeping
the programmed voltage at or below 5.0 V. These settings are backups, not current
references. Use two separate battery-operated Fluke 87V MAX digital multimeters
(DMMs), both in normal 6.000 V direct-current (DC) mode and voltage sockets.

Source positive S+ → R1 → node A → diode anode. Banded cathode → source negative N.
M1 red VΩ at S+; M1 COM at A. This reads series_v, called VR.
M2 red VΩ at A; M2 COM at N. This reads forward_v, called VF.
VΩ is the voltage/resistance socket; COM is that meter's common-return socket.
Do not join the two COM nodes: A=N shorts the diode/control. R1 remains in series.
A common grounded oscilloscope cannot substitute for these floating meter connections.
Use voltage inputs, never a current input across the source.

Fit one load at a time. With output off, replace D1 by the control between A and N.
Keep the same meter on each sense pair. Stop for current limiting, overload,
unexpected polarity or persistent instability; turn output off and inspect wiring.
Do not invent a reading to complete a stopped sheet.

ACQUIRE THE 36 ROWS IN ORDER

CSV means comma-separated values, a plain-text worksheet. The exact header is:

 device,cycle,step,target_ua,series_v,forward_v

For diode cycles 1, 2 and 3, repeat this nine-step sequence:
 C0 500 µA; WL 400 µA; C1 500 µA; WH 600 µA; C2 500 µA;
 NL 490 µA; C3 500 µA; NH 510 µA; C4 500 µA.

After all 27 diode rows, replace the load with output off. For control cycles
1, 2 and 3, acquire L 400 µA; C 500 µA; H 600 µA. These add nine rows.
The exact device labels are diode and control. Do not sort the file, duplicate
center keys, pair different cycles or replace actual currents by target labels.
The blank sheet has metadata filled and measured cells empty; empty is not zero.

At each point wait at least 30 seconds, then compare a second voltage pair five
seconds later. If either reading changes by more than its single-reading error
allowance, wait and repeat. Record the final settled pair and keep both checks in
bench notes. The 30-second wait and manual five-second check are acquisition
requirements; the software does not verify them. Record the two displayed drops
close together, using their real signs. Keep mounting, leads, airflow and room
conditions stable without deliberately heating the diode.

Adjust source voltage using corrected measured current, not the current-limit
setting. A ±0.5% nominal-current matching screen selects experiment points; it does
not establish 0.5% absolute current accuracy. One milliampere (mA) is 1000
microamperes (µA); an ampere is the unit of current. Enter voltages in volts (V).

FIXED CONDITIONAL MODEL

The normal 6 V meter range has 1 mV counts. A millivolt is 0.001 V. Use voltage
error ±(0.05% of reading + 1 count), or 0.0005*abs(v)+0.001 V. The detailed accuracy
applies within TWO YEARS after calibration, at 18–28 degrees Celsius (°C), with the
manual's applicable humidity and electromagnetic conditions, including 0–95%
relative humidity (RH). Electromagnetic compatibility (EMC) conditions concern
interference around the meter. The software does not certify those conditions.
High-resolution extra digits do not lower the absolute count term; 600 mV mode
has another error specification and may overrange the diode.

Use R1 = 3900 ±42.9 Ω and control = 1000 ±11 Ω. An ohm (Ω) is the unit of
resistance; a kilohm (kΩ) is 1000 Ω. These 1.1% intervals include the stated 1%
part tolerance and an additional CHOSEN 0.1% thermal/fixture allowance. Nominal
meter input resistance is 10 MΩ, or ten million ohms, for each meter. The loaded
current is:

 I = VR*(1/R1 + 1/10000000) - VF/10000000

M1 loading adds current into A; M2 loading diverts it around the load. Evaluate all
voltage/R endpoint combinations, then widen by a CHOSEN ±0.5 µA loading allowance
per point. Nominal input resistance is not a certified minimum or exact value.
The extra R and loading allowances are engineering assumptions, not manufacturer
guarantees of thermal or input-conductance coverage. Reported intervals are
conditional on those assumptions fitting the actual setup. Do not reduce them to
obtain a preferred result. This first command-line interface (CLI) has no precision-adjustment options.

Signed differences use high.lower-low.upper and high.upper-low.lower for both
voltage and current. If the lower current difference is not positive, withhold the
quotient. Otherwise evaluate every endpoint quotient. Retain a negative lower
bound; it is uncertainty, not measured negative diode differential resistance.
No abs(), clipping, rounding or target-current substitution can make it resolved.
Repetitions do not divide fixed errors by sqrt(N). Numerical comparison allowances
of 1e-12 V and 1e-15 A only handle floating-point boundaries.

CONTROLS AND INTERPRETATION

Each point needs the declared meter range, positive lower voltage/current bounds,
a voltage upper-bound sum no greater than 5.05 V and nominal target matching.
All 15 diode center-current intervals must overlap, and their full VF range plus
the two extreme reading errors must fit a chosen 5 mV screen. Per-cycle center
checks remain visible. Apply the same checks separately to the three control C
rows. Do not mix diode and control voltages.

Every control V/I interval and each control L/H chord must overlap [989,1011] Ω.
Overlap supports consistency, not certification of every instrument, contact or
part. Failed controls suppress interpretation without deleting diagnostic
arithmetic or changing the model. Center returns cannot prove identical currents,
equal endpoint junction temperatures or absence of brief disturbances. Settled
self-heating and nonlinear curvature remain limitations.

A chord is the finite slope between two settled points. An infinitesimal derivative
is the limiting slope at one point. These DC chords are neither that derivative
nor an alternating-current impedance measurement. No nVT/I value, ideality factor,
expected slope or required wide/narrow pattern is an acceptance criterion.
V/I at the center is context only.

interpretation_supported is accompanied by the conditional model. Each chord also
has arithmetic_positive and positive_slope_resolved. A width's summary is positive
only if ALL THREE cycles support its positive chord. The five possible patterns
are unsupported, neither, wide_only, narrow_only and both. No pattern is forced.
Summary intervals use a hull enclosing all three bounds, never a smaller error of
a mean. The reader's logarithmic example is constructed and is not a diode promise.

INPUT BOUNDARIES

Use UTF-8 (Unicode Transformation Format, 8-bit), the plain-text byte format. The
physical header must be exact, unique and ordered. The file must contain exactly
36 ordered acquisition rows and at most 65536 bytes. Reject malformed quotes,
invalid text, blank/nonfinite numeric cells, extra/missing fields or rows, wrong
keys/targets and reordered acquisitions. These are exit-2 errors with no JSON.

Finite wrong-polarity, over-range, mismatched or drifting observations are valid
unsupported data: exit 0 with reasons. For readings outside ±6 V, the declared
meter model is inapplicable. The out-of-range reading’s voltage interval, derived
current and dependent quotient intervals are null; valid companion-voltage or
voltage-difference diagnostics may remain.
An entered OL is incomplete/non-numeric input, not an invented voltage. The model
cannot observe a current-limit lamp or a manual settling check; retain bench notes.

ARCHIVE CONTENTS

diode_brackets.py / test_diode_brackets.py / make_constructed.py
README-experiment.txt / physical-blank.csv / constructed-example.csv
diode-bracket-resolution.svg / diode-bracket-resolution.png

The Scalable Vector Graphics (SVG) original is editable. The full-size Portable
Network Graphics (PNG) raster is an illustration of actual circuit connections
and constructed intervals, not a photograph of built hardware. Read the complete
article for source qualification, calculations, limitations and the challenge.
