# Shannon's Equation for Dummies **Educational Web Application for Satellite Communications** Exploration from Claude Shannon's initial theory to its practical application to satellite communications. ## ๐Ÿš€ Stack - **Frontend**: [Streamlit](https://streamlit.io) with [Plotly](https://plotly.com) interactive charts - **Backend**: Python 3.11+ with scientific libraries (numpy, scipy, itur, astropy) - **Database**: SQLite for community contributions - **Deployment**: Docker + docker-compose, designed for 24/7 multi-user operation ## ๐Ÿ“ Project Structure ``` . โ”œโ”€โ”€ app.py # Main Streamlit entry point โ”œโ”€โ”€ core/ # Core business logic โ”‚ โ”œโ”€โ”€ calculations.py # Shannon equations & satellite link budget โ”‚ โ”œโ”€โ”€ database.py # SQLite contribution management โ”‚ โ””โ”€โ”€ help_texts.py # Educational help content โ”œโ”€โ”€ views/ # UI pages โ”‚ โ”œโ”€โ”€ theory.py # Theoretical exploration (Shannon limit) โ”‚ โ”œโ”€โ”€ real_world.py # Real-world link budget calculator โ”‚ โ””โ”€โ”€ contributions.py # Community knowledge database โ”œโ”€โ”€ .streamlit/config.toml # Streamlit configuration โ”œโ”€โ”€ Dockerfile # Container image definition โ”œโ”€โ”€ docker-compose.yml # Orchestration with nginx-proxy โ””โ”€โ”€ requirements.txt # Python dependencies ``` ## ๐Ÿ› ๏ธ Local Development ### Prerequisites - Python 3.11+ - pip ### Setup ```bash # Create virtual environment python3 -m venv .venv source .venv/bin/activate # On Windows: .venv\Scripts\activate # Install dependencies pip install -r requirements.txt # Run the app streamlit run app.py ``` The app will open at `http://localhost:8501` ## ๐Ÿณ Docker Deployment ### Build and run ```bash docker-compose up -d ``` The app will be available at `http://localhost:8080` ### Environment - **Port**: 8080 (configurable in `.streamlit/config.toml`) - **Health Check**: `/_stcore/health` - **Data Persistence**: SQLite databases stored in `shannon_data` volume ### Production Setup The `docker-compose.yml` is configured for nginx-proxy: - Network: `nginx-proxy` - Virtual host: `shannon.antopoid.com` - HTTPS ready (with appropriate Let's Encrypt configuration) ## ๐Ÿ“š Features ### 1. Theoretical Exploration - Shannon capacity calculation (C = BW ร— logโ‚‚(1 + C/N)) - Bandwidth and power sensitivity analysis - Bit rate factor maps - Interactive Plotly graphs ### 2. Real-World Link Budget - Complete satellite link calculation - ITU-R atmospheric attenuation models - Receiver noise and baseband impairments - Practical Shannon limits with penalties ### 3. Community Contributions - Collaborative knowledge database - Search and filter capabilities - Read/Write/Delete permissions ## ๐ŸŽ“ Educational Value The application provides extensive background information accessible through help expanders on every input/output, covering: - Shannon's theorem and its implications - Satellite communication fundamentals - Atmospheric propagation effects - Modulation and coding schemes - Real-world system design trade-offs ## ๐Ÿ“ License & Author ยฉ 2021-2026 ยท Shannon Equation for Dummies Created by JPC (February 2021) Migrated to Streamlit (2026)