Skip to content

Add Connerney et al. (1981, 2020) Jupiter magnetodisc current sheet model#13

Open
Beforerr wants to merge 2 commits intomainfrom
claude/connor-jupiter-current-sheet-u4iVb
Open

Add Connerney et al. (1981, 2020) Jupiter magnetodisc current sheet model#13
Beforerr wants to merge 2 commits intomainfrom
claude/connor-jupiter-current-sheet-u4iVb

Conversation

@Beforerr
Copy link
Copy Markdown
Member

Summary

This PR adds support for the Connerney et al. (1981, 2020) Jupiter magnetodisc current sheet model, which describes the magnetic field contribution from a washer-shaped azimuthal current sheet near Jupiter's magnetic equator. This is a key external field component for accurate Jupiter magnetosphere modeling.

Key Changes

  • New module src/current_sheet.jl: Implements the complete Connerney current sheet model with:

    • CurrentSheetModel struct implementing the InternalFieldModel interface
    • CurrentSheetParameters for configurable model parameters (current intensity, disc geometry, tilt angles, radial current)
    • CurrentSheetEquationType enum supporting three calculation methods:
      • Analytical: Fast Edwards et al. (2001) approximations
      • Integral: Accurate Connerney et al. (1981) numerical integration
      • Hybrid: Combines both methods based on position (default, recommended)
  • Coordinate transformations: Implements conversions between SIII spherical coordinates and the tilted current sheet frame to handle the disc's tilt relative to Jupiter's spin axis

  • Field calculations:

    • Cylindrical coordinate field computation with azimuthal and radial current contributions
    • Analytical field expressions with helper functions for efficient computation
    • Numerical integration using Bessel function approximations
    • Radial current contribution (CON2020 feature)
  • Public API functions:

    • CON2020(): Creates the 2020 model with modern parameters and radial current
    • CAN1981(): Creates the original 1981 model for comparison
  • Comprehensive test suite (test/test_con2020.jl):

    • Model loading and parameter validation
    • Field evaluation at various positions
    • Symmetry properties verification
    • Comparison of different equation types
    • Custom parameter handling
    • Integration with JRM33 internal field model
    • Edge case handling (near axis, at disc edges, outside disc)
  • Integration: Updated main module to export new model types and convenience functions

Notable Implementation Details

  • Uses polynomial approximations for Bessel functions (J₀, J₁) for efficient numerical integration
  • Handles singularities near the rotation axis with special case logic
  • Supports both with/without radial current for flexibility between model versions
  • Tilt angles configurable in degrees for user convenience, converted internally to radians
  • Field components properly transformed between coordinate systems to maintain physical accuracy

https://claude.ai/code/session_01832e6uXkGU6WZZL7qnj6pU

Implement the Connerney et al. (1981, 2020) magnetodisc current sheet model
for Jupiter's magnetosphere. This external field model provides the magnetic
field contribution from the washer-shaped azimuthal current sheet near
Jupiter's magnetic equator.

Features:
- CON2020() - Modern model with radial current (Connerney 2020)
- CAN1981() - Original model without radial current
- Three equation types: analytical (fast), integral (accurate), hybrid (default)
- Coordinate transformations for tilted disc frame
- Configurable parameters (inner/outer radii, thickness, tilt, current)

Default parameters from Juno mission:
- μ_i/2 = 139.6 nT (current intensity)
- r0 = 7.8 Rⱼ (inner edge)
- r1 = 51.4 Rⱼ (outer edge)
- d = 3.6 Rⱼ (half-thickness)
- Tilt: 9.3° toward 155.8° SIII longitude
- Radial current: 16.7 MA

References:
- Connerney et al. (1981), J. Geophys. Res., 86(A10), 8370-8384
- Edwards et al. (2001), Planet. Space Sci., 49, 1115-1123
- Connerney et al. (2020), J. Geophys. Res., 125, e2020JA028138

https://claude.ai/code/session_01832e6uXkGU6WZZL7qnj6pU
- Use InternalFieldModel from GeoCotrans instead of custom ExternalFieldModel
- Implement evalmodel() for CurrentSheetModel to integrate with GeoCotrans
- Add getcsys() method for coordinate system handling
- Remove MagneticModel wrapper (no longer needed with new architecture)
- Simplify code from ~750 to ~400 lines
- Update tests to match simplified API

https://claude.ai/code/session_01832e6uXkGU6WZZL7qnj6pU
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants