#!/usr/bin/env python3
"""
spinning_ball_physics.py

What if atoms are literally spinning balls?
Let's use proper rotational mechanics.
"""

import numpy as np
import scipy.constants as const

def analyze_spinning_ball(name, mass_kg, radius_m, L_quantum):
    """Analyze as actual spinning sphere"""
    
    c = const.c
    
    # For solid sphere: I = (2/5)mr²
    I = (2/5) * mass_kg * radius_m**2
    
    # Angular momentum L = Iω
    omega = L_quantum / I
    
    # Surface velocity
    v_surface = omega * radius_m
    
    # Centripetal acceleration at surface
    a_centripetal = omega**2 * radius_m
    
    # "Weight" on surface
    F_surface = mass_kg * a_centripetal
    
    print(f"\n{name}:")
    print(f"  Moment of inertia: I = {I:.2e} kg⋅m²")
    print(f"  Angular velocity: ω = {omega:.2e} rad/s")
    print(f"  Surface velocity: v = {v_surface:.2e} m/s = {v_surface/c:.3f}c")
    print(f"  Centripetal acceleration: a = {a_centripetal:.2e} m/s²")
    print(f"  Surface 'weight': F = {F_surface:.2e} N")
    
    if v_surface > c:
        print(f"  ⚠️  IMPOSSIBLE: Surface moving faster than light!")
    
    return v_surface, F_surface

def main():
    print("SPINNING BALL ANALYSIS - PROPER ROTATIONAL MECHANICS")
    print("="*60)
    print("Treating atoms/particles as actual spinning spheres")
    
    hbar = const.hbar
    me = const.m_e
    mp = const.m_p
    
    # Test cases
    cases = [
        # Name, mass, radius, angular momentum
        ("Hydrogen atom", me, 5.29e-11, hbar),  # Bohr radius
        ("Proton", mp, 0.875e-15, hbar/2),     # Spin-1/2
        ("Electron", me, 2.82e-15, hbar/2),    # Classical electron radius
    ]
    
    for case in cases:
        analyze_spinning_ball(*case)
    
    print("\n" + "="*60)
    print("KEY INSIGHT:")
    print("At small radii, spinning balls hit speed of light limit!")
    print("This suggests quantum 'spin' is NOT classical rotation")
    print("We need a different model for quantum scales")

if __name__ == "__main__":
    main()
