{
 "cells": [
  {
   "metadata": {},
   "cell_type": "markdown",
   "source": [
    "# Supplementary Explanation\n",
    "\n",
    "After understanding the three basic levels in `braincell` — `Cell`, `Channel`, and `Ion` — you may have questions:\n",
    "- Why was `braincell` developed?\n",
    "- Why is it feasible to develop `braincell`?\n",
    "- What advantages does `braincell` offer?\n",
    "\n",
    "This section will answer these questions.\n",
    "\n",
    "## Development Background\n",
    "\n",
    "Current mainstream neural modeling tools generally have limitations and cannot simultaneously meet the requirements of biological realism, computational efficiency, and flexibility:\n",
    "- Traditional brain simulation tools: Mainstream tools include NEURON, NEST, Brian2, etc. NEURON can accurately simulate biophysical details but relies on static code generation, offering low flexibility and inefficient large-scale network simulations; NEST focuses on population network dynamics but simplifies single-cell electrophysiology, making it difficult to capture fine ion-channel-level dynamics; Brian2 faces certain iteration speed limitations when handling complex models.\n",
    "- Deep learning frameworks: Mainstream frameworks such as [PyTorch](https://pytorch.org/) and [TensorFlow](https://tensorflow.google) excel at large-scale parallel computing but lack native support for neural dynamics. Their core design is optimized for backpropagation, making direct modeling of differential equations challenging, and electrophysiological constraints must be manually implemented, reducing reusability.\n",
    "\n",
    "To address these issues, we built the [BrainPy](https://github.com/brainpy/BrainPy) ecosystem, aiming to unify biological accuracy with computational efficiency in neural modeling. `braincell`, as the core component of this ecosystem, focuses on resolving the pain points of neural detail modeling, filling the gap in cross-scale simulations from ions to networks.\n",
    "\n",
    "## Feasibility\n",
    "\n",
    "The development of `braincell` is grounded in electrophysiological theory and technical support, with clear feasibility:\n",
    "- Electrophysiological principles:\n",
    "  Based on classical neuroscience theories, directly mapping verifiable electrophysiological mechanisms: from ion channel gating dynamics, spatial current propagation in multi-compartment neurons, to chemical and electrical signal conversion in synapses, all strictly follow experimental observations, ensuring models can be directly compared with electrophysiological data.\n",
    "- Dynamical principles:\n",
    "  Neural dynamics are essentially rigid differential equation systems. `braincell` leverages the [JAX](https://github.com/jax-ml/jax) framework for automatic differentiation and hardware acceleration, efficiently solving such systems. At the same time, its modular design decomposes dynamics into reusable states and rules, aligning with the mathematical logic of dynamical systems while supporting flexible expansion.\n",
    "\n",
    "## Necessity\n",
    "\n",
    "The development of `braincell` addresses current bottlenecks in neural modeling, with core values reflected in:\n",
    "- Filling the technical gap:\n",
    "  Achieves tight integration of detailed modeling and large-scale parallel computing. It offers single-cell modeling precision while benefiting from deep learning frameworks’ hardware adaptability, supporting full-scale simulations from ion channels to large-scale neuronal networks.\n",
    "- Modularity and reusability:\n",
    "  Provides a simple and modular modeling framework. Ion channels, compartmental structures, etc., are separated into independent components, allowing users to combine models like building blocks, significantly lowering the threshold for custom modeling.\n",
    "- Instant connectivity:\n",
    "  As the foundational layer of the BrainPy ecosystem, `braincell` can seamlessly integrate with higher-level tools, achieving a closed loop of cross-scale modeling from ion channels to networks and supporting rapid iterative validation.\n",
    "\n",
    "## Ecosystem\n",
    "\n",
    "`braincell` is the cornerstone of the [brain modeling ecosystem](https://ecosystem-for-brain-dynamics.readthedocs.io/), which aims for unified multi-scale neural dynamics modeling and forms a hierarchical architecture.\n"
   ],
   "id": "6c90b4234d120749"
  }
 ],
 "metadata": {
  "kernelspec": {
   "display_name": "Python 3",
   "language": "python",
   "name": "python3"
  },
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 2
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython2",
   "version": "2.7.6"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 5
}
