Repository navigation
Module 04
Curriculum part: Mathematical and Theoretical Foundations
Study level: Foundational
Content status: Substantive introductory chapter; supporting exercises and implementations are maintained separately.
The MP neuron models threshold logic; the perceptron introduces learnable weights and bias, making a linear decision boundary adaptable from data.
After studying this module, you should be able to:
- Explain the central problem and assumptions of the methods covered.
- Interpret the principal mathematical objects, equations and tensor dimensions.
- Work through a small numerical example without relying on a framework.
- Implement or verify the central operation using NumPy or PyTorch.
- Identify failure modes and select appropriate follow-up material.
Prerequisites: Basic Boolean logic and coordinate geometry.
The module follows the principle write once, reference everywhere. Foundational derivations are maintained in their primary module; later modules focus on how those ideas are used rather than repeating the full derivation.
A biological neuron receives signals through dendrites, integrates them in the cell body and transmits signals through an axon. This is inspiration, not a faithful simulation. An MP neuron aggregates binary excitatory and inhibitory inputs and compares the result with a threshold. It can represent Boolean functions such as AND and OR. A perceptron extends the model to real-valued inputs with z=wᵀx+b and a step output. Its decision boundary is wᵀx+b=0. The bias shifts the boundary away from the origin. The perceptron convergence theorem applies to finite linearly separable datasets; XOR is not linearly separable and cannot be solved by a single perceptron.
A compact form of the central operation is:
z=wᵀx+b; ŷ=1 if z≥0, else 0. With labels y∈{−1,+1}, a misclassified example updates w←w+ηyx, b←b+ηy.
The equations above define the main computational objects. When implementing them, specify tensor shapes, reduction axes, normalization conventions and whether a loss is summed or averaged. Those details determine the actual computation.
For OR, w=(1,1), b=−0.5 yields scores −0.5,0.5,0.5,1.5 for inputs (0,0),(1,0),(0,1),(1,1), giving outputs 0,1,1,1. XOR requires a nonlinear feature map or hidden layer.
Use the example as a check on notation and implementation. Change one input at a time and verify how the output changes; this is often more informative than immediately moving to a large dataset.
flowchart TD
A[Define the problem and data] --> B[Identify mathematical objects]
B --> C[Write equations and tensor shapes]
C --> D[Work through a small numerical case]
D --> E[Implement the operation]
E --> F[Verify outputs and gradients]
F --> G[Evaluate limitations and connect to later modules]
Enumerate Boolean truth tables, plot points and decision boundaries, and implement the perceptron update. Compare separable data with XOR; then solve XOR using a two-layer network.
A good implementation sequence is:
- Write the operation in plain mathematical notation.
- Calculate a tiny example by hand.
- Implement the operation with NumPy.
- Compare against a trusted PyTorch operation.
- Add shape and numerical assertions.
- Only then run a larger experiment.
See the implementation roadmap for a module-specific progression.
A perceptron is not probabilistic; its step output is not a calibrated probability. Bias is generally necessary. The convergence theorem does not apply to non-separable data. Stacking linear layers without nonlinearities remains a linear map.
Study margin perceptrons, SVMs, kernel methods, logistic regression and multilayer expressivity.
These are extensions beyond the minimum conceptual foundation. Treat them as directions for further reading or experiments, not as claims that an implementation or benchmark is already complete.
This module is best studied as one integrated chapter; the lesson map divides the reading sequence without duplicating the theory.
- Lesson map — recommended reading order.
- Numerical exercises and practice — problems to test understanding.
- Implementation roadmap — coding progression.
- Research extensions — selected directions beyond the core.
- Module 05: Activation Functions, Neural Network Units and Expressivity — see how this concept is used in a later architecture or research setting.
- Module 07: Feedforward Neural Networks and Backpropagation — see how this concept is used in a later architecture or research setting.
The original course material is the primary basis for the course topics in this curriculum. Mathematical prerequisites are included to make the course topics understandable from first principles. Additional modern methods are identified as extensions where appropriate. The chapter does not imply that every proposed coding exercise or research experiment has already been executed.
These sources provide canonical starting points for the concepts in this chapter. They are not a claim that every extension listed above is covered by the original course material.
- McCulloch, W. S., & Pitts, W. (1943). A logical calculus of the ideas immanent in nervous activity. Bulletin of Mathematical Biophysics, 5, 115–133.
- Rosenblatt, F. (1958). The perceptron: a probabilistic model for information storage and organization in the brain. Psychological Review, 65(6), 386–408.
- Explain the main ideas in your own words.
- Re-derive the central equations and check dimensions.
- Solve the worked example independently.
- Complete at least one numerical exercise.
- Implement and verify the central operation.
- Explain at least two limitations or failure modes.
- Follow the cross-module links relevant to your learning path.
Next: Continue to the lesson map or return to the curriculum map.
🏠 Home · 🗺️ Curriculum · 🧭 Learning paths · ❓ Question bank · 📖 Glossary · 📚 References · ✏️ Contributing
🏠 Home · 🗺️ Curriculum · 🧭 Learning paths
❓ Question bank · 📖 Glossary · 📚 References
Jump to module:
01 02 03 04 05 06 07 08 09 10 11 12
13 14 15 16 17 18 19 20 21 22 23 24