Splashery

Aisle 3No. 31 of 460

Splashery

Multilayer Net

439,988 small parts. Assembled in your browser.

Empty. Now look down.

Multilayer Net, a still.
203003100009
$0.00

Swipe across the pack to tear it open.

Press and hold. It pulls itself together.

Let go to drop it.

It stays in its pack here. The Playground has the rest.

Playground

AI and Computing · Built from a recipe

Multilayer Net

One perceptron can only split its inputs with a single straight line, so it cannot learn XOR, “exclusive or”, which is 1 when exactly one of two inputs is 1.

Play with it in the Playground

How to play

Tap it to try all four inputs. Hands-on: tap each input to flip it; XOR answers.

Toy facts

Item
No. 31 of 460
Shelf
Aisle 3, AI and Computing
Kind
Built from a recipe
Small parts
439,988
Sound
Yes
Hands-on
Yes
Batteries
None
Assembly
It does that itself
Licenses
Own work (made in the page)
Price
$0.00

Small parts are the splats in its usual build on a computer. A phone may draw fewer.

Its controls

ControlKindRangeStart
Try all four inputsTap
RunButton
FlipButton
ViewList2 choicesPoster (2D)

About it

One perceptron can only split its inputs with a single straight line, so it cannot learn XOR, “exclusive or”, which is 1 when exactly one of two inputs is 1. Put neurons in layers and it can. Here an OR neuron and a NAND (“not both”) neuron feed an AND neuron, and together they give XOR. Blue wires add to a neuron's sum and red wires subtract.

Tap it and it tries the inputs 00, 01, 10 and 11 in turn, lighting each neuron that fires, and fills in the truth table: 0, 1, 1, 0. Pick the poster or a 3D model in the Splash tab. With ✋ Hands-on on, tap each input lamp to flip it: the OR and NAND neurons and the output show XOR's answer at once, and the truth table marks the row.

Details

Splats
Opens at 200,000 at Mid Detail, 120,001 at Low, and up to 630,000 at Max

Is it right?

The hidden units produce the XOR truth table correctly. The splash demonstrates a fixed nonlinear circuit; it does not learn XOR from examples.

  1. Correct

    A single linear decision boundary cannot represent XOR; hidden nonlinear units can.1

    The fixed hidden units compute OR and NAND; their final threshold computes XOR for all four input pairs.

  2. Correct

    The XOR output is one when exactly one input is one.2

    The actual XOR helper returns 0, 1, 1, 0 for 00, 01, 10, 11.

  3. Simplified

    The picture illustrates a multilayer network, not a trained model.1

    The weights and thresholds are stored constants; tapping cycles the four input cases.

  1. 1Multilayer perceptrons, Dive into Deep Learning authors
  2. 2Half adder, All About Circuits textbook
Simplified
The XOR network uses fixed threshold units. Its truth table is real, but there is no loss calculation or training step.

Sources and credits

Made in Splashery. Its code is MIT.

Share it

This link opens it in the Playground. To put it on your own page, add the element and one script tag. Every option.

https://splashery.app/play/?toy=multilayer-perceptron
<script type="module" src="https://splashery.app/play/src/element.js"></script>
<splashery-toy toy="multilayer-perceptron"></splashery-toy>