Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Provide option to show reference as area bw. 2 Parker spirals (instead of arrow/cone) #32

Closed
jgieseler opened this issue Mar 10, 2023 · 2 comments
Labels
enhancement New feature or request

Comments

@jgieseler
Copy link
Owner

Similar to #6, provide option to show reference as an shaded area between 2 Parker spirals.

@jgieseler jgieseler added the enhancement New feature or request label Mar 10, 2023
@jgieseler
Copy link
Owner Author

jgieseler commented Mar 21, 2023

With d2b0783 (upcoming release 0.1.6), SolarMACH.plot() has 3 new options for this purpose:

  • long_sector: list of 2 numbers, optional
    Start and stop longitude of a shaded area; e.g. [350, 20] to get a cone from 350 to 20 degree longitude (for long_sector_vsw=None).
  • long_sector_vsw: list of 2 numbers, optional
    Solar wind speed used to calculate Parker spirals (at start and stop longitude provided by long_sector) between which a reference cone should be drawn; e.g. [400, 400] to assume for both edges of the fill area a Parker spiral produced by solar wind speeds of 400 km/s. If None, instead of Parker spirals straight lines are used, i.e. a simple cone wil be plotted. By default None.
  • long_sector_color: string, optional
    String defining the matplotlib color used for the shading defined by long_sector. By default 'red'.
  1. Full example:
from solarmach import SolarMACH
body_list = ['STEREO-A', 'Earth', 'BepiColombo', 'PSP', 'Solar Orbiter', 'Mars']
vsw_list = [400, 400, 400, 400, 400, 400]
date = '2022-3-11 12:00:00'

sm = SolarMACH(date, body_list, vsw_list)
sm.plot(numbered_markers=True, long_sector=[290,328], long_sector_vsw=[400,600], long_sector_color='cyan')

issue32

  1. For long_sector_vsw=None (default), instead of Parker spirals straight lines are drawn:
from solarmach import SolarMACH
body_list = ['STEREO-A', 'Earth', 'BepiColombo', 'PSP', 'Solar Orbiter', 'Mars']
vsw_list = [400, 400, 400, 400, 400, 400]
date = '2022-3-11 12:00:00'

sm = SolarMACH(date, body_list, vsw_list)
sm.plot(numbered_markers=True, long_sector=[290,328], long_sector_vsw=None, long_sector_color='red')

issue6

  1. Note that there still is a bug if the speeds in long_sector_vsw differ to some extent; then the plotting might not work as intended:
from solarmach import SolarMACH
body_list = ['STEREO-A', 'Earth', 'BepiColombo', 'PSP', 'Solar Orbiter', 'Mars']
vsw_list = [400, 400, 400, 400, 400, 400]
date = '2022-3-11 12:00:00'

sm = SolarMACH(date, body_list, vsw_list)
sm.plot(numbered_markers=True, long_sector=[290,328], long_sector_vsw=[400,700], long_sector_color='cyan')

issue32_bug

@jgieseler
Copy link
Owner Author

NB: Renamed fill_between to long_sector with f8ab303

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant