Tag Archives: Euclidean distance

To accelerate self-organizing maps with stacked memristor arrays: compute Euclidean distance in memory

Michael Berger gives a good description of neuromorphic (brainlike) computing and memristors before (pun alert!) explaining how Euclidean distance factors into the equation in his January 21, 2026 Nanowerk Spotlight article, Note: Links have been removed,

Neuromorphic computing seeks to replicate one of the brain’s most remarkable features: its ability to store information and process it within the same physical structure. Conventional computers, built on the von Neumann architecture that has dominated since the 1940s, continuously shuttle data between separate memory and processing units. This arrangement creates bottlenecks that waste both time and energy, a problem that grows increasingly severe as artificial intelligence demands more computational power.

Memristors, devices whose electrical resistance can be programmed to hold different values, emerged as a promising solution. When arranged in crossbar arrays, memristors can perform vector-matrix multiplication in parallel, with data stored directly in the resistance states of the devices themselves. This capability has enabled impressive demonstrations of supervised neural networks running directly on memristive hardware.

Unsupervised learning algorithms, however, present a different challenge. Unlike supervised learning, where networks train on labeled examples with known correct answers, unsupervised learning discovers hidden patterns and groupings in data without any guidance. This makes it invaluable for exploring datasets where labeling would be prohibitively expensive or simply impossible, such as astronomical surveys containing billions of objects, genomic sequences from unstudied organisms, or sensor streams from industrial equipment.

Self-organizing maps, introduced by Finnish researcher Teuvo Kohonen in the 1980s, represent one of the most elegant approaches to unsupervised learning. These networks transform complex, high-dimensional data into intuitive two-dimensional maps that preserve relationships between similar items.

Imagine trying to understand a dataset where each sample has dozens or hundreds of measurements. A self-organizing map learns to arrange neurons on a grid such that similar inputs activate nearby neurons while dissimilar inputs activate distant ones. The result resembles a topographic map where proximity reflects similarity.

…

And now for Euclidean distance, from the January 21, 2026 Nanowerk Spotlight article, Note: A link has been removed,

Researchers have applied self-organizing maps to cluster gene expression profiles, detect fraud in financial transactions, segment customers by purchasing behavior, and solve optimization puzzles like finding efficient delivery routes.

The algorithm works through competitive learning. When presented with an input, the network identifies which neuron’s stored weights most closely resemble that input. This winning neuron, called the best matching unit, then adjusts along with its neighbors to better represent the input. The network gradually organizes itself through repeated exposure to data.

Finding the best matching unit requires computing Euclidean distance, the straight-line separation between points in multidimensional space. This calculation demands subtraction followed by squaring and accumulation. Memristor crossbars excel at multiplication and addition but cannot natively perform subtraction. Previous hardware implementations have relied on peripheral digital processors or approximate similarity measures, adding complexity and eroding efficiency gains.
A study published in Advanced Functional Materials (“In‐Memory Euclidean Distance Computation in a Stacked Memristor Crossbar for Hardware Self‐Organizing Maps”) by researchers at Hanyang University in Seoul demonstrates a fundamentally different approach. The team developed a three-dimensional stacked memristor crossbar array that computes squared Euclidean distance directly within the memory structure, requiring no external arithmetic circuits.

The innovation exploits a shared middle electrode connecting two vertically stacked memristor layers. The lower layer stores weight values while the upper layer stores their squares. When input voltages are applied, currents flow through both layers simultaneously but with opposite polarity. The middle electrode naturally sums these opposing currents, yielding a net value proportional to squared Euclidean distance. The neuron producing the smallest current corresponds to the best matching unit.

…

For the more technical details, there’s the January 21, 2026 Nanowerk Spotlight article or you can follow this link (with citation),

In-Memory Euclidean Distance Computation in a Stacked Memristor Crossbar for Hardware Self-Organizing Maps by Jinwoo Park, Hyungjin Kim. Advanced Functional Materials Volume 36, Issue 34 27 April 2026 e31235 DOI: https://doi.org/10.1002/adfm.202531235 First published online: 14 January 2026

This paper is open access.