Function Repository Resource:

SolarImage

Source Notebook

Retrieve images of the Sun from many NASA/ESA scientific instruments

Contributed by: Jeff Bryant

ResourceFunction["SolarImage"][]

returns the most recent HMI intensitygram of the Sun.

ResourceFunction["SolarImage"][date]

returns the HMI intensitygram nearest to the specified date.

ResourceFunction["SolarImage"][{date1,date2,}]

returns an event series of the HMI intensitygrams nearest to the specified dates.

ResourceFunction["SolarImage"][instcode]

returns a most recent solar image from the instrument specified by instcode.

ResourceFunction["SolarImage"][date,instcode]

returns a solar image for the specified instcode nearest to date.

ResourceFunction["SolarImage"][{date1,date2,},instcode]

returns an event series for the specified instcode nearest to the specified dates.

ResourceFunction["SolarImage"][date,instcode,"Image"]

returns a solar image for the specified instcode nearest to date.

ResourceFunction["SolarImage"][date,instcode,"Date"]

returns the observation date for the specified instcode nearest to date.

ResourceFunction["SolarImage"][{date1,date2,},instcode,"EventSeries"]

returns an event series for the specified instcode nearest to the specified dates.

ResourceFunction["SolarImage"]["InstrumentAssociation"]

returns an association of the instrument codes and their descriptions.

Details and Options

If a date isn't specified, the result is for the most recent image available.
If an "EventSeries" is requested, but a list of dates isn't specified, then the results are for the past week with "Day" granularity.
HMI is the Helioseismic and Magnetic Imager on the Solar Dynamics Observatory (SDO).
Solar images come from a variety of NASA/ESA instruments in different wavelengths.
SolarImage takes the following options:
"BlendColors"Automaticcolors to blend together to colorize the resulting image
"Colorize"Truewhether to colorize the original black and white images
ImageSizeMediumimage size of the resulting image
"BlendColors" must either be Automatic, a list of colors, or a gradient known to ColorData.
Data availability varies depending on the instrument.
The instrument code, instcode, can be any of the following integer values corresponding to known instruments (date range estimates are given where available):
0SOHO EIT 171 (1996/01/05–2013/08/07)
1SOHO EIT 195 (1996/01/05–2013/08/07)
2SOHO EIT 284 (1996/01/05–2013/08/07)
3SOHO EIT 304 (1996/01/05–2013/08/07)
4SOHO LASCO C2 (1996/04/01–present)
5SOHO LASCO C3 (1996/04/14–present)
6SOHO MDI Mag (1996/05/19–2011/01/11)
7SOHO MDI Int (1996/05/19–2011/01/11)
8SDO AIA 94 (2010/06/02–present)
9SDO AIA 131 (2010/06/02–present)
10SDO AIA 171 (2010/06/02–present)
11SDO AIA 193 (2010/06/02–present)
12SDO AIA 211 (2010/06/02–present)
13SDO AIA 304 (2010/06/02–present)
14SDO AIA 335 (2010/06/02–present)
15SDO AIA 1600 (2010/06/02–present)
16SDO AIA 1700 (2010/06/02–present)
17SDO AIA 4500 (2010/06/02–present)
18SDO HMI Int (2010/12/06–present)
19SDO HMI Mag (2010/12/06–present)
20STEREO EUVI-A 171 (2006/11/11-present)
21STEREO EUVI-A 195 (2006/11/7-present)
22STEREO EUVI-A 284 (2006/12/4-present)
23STEREO EUVI-A 304 (2006/12/4-present)
24STEREO EUVI-B 171 (2006/11/11-2014/9/27)
25STEREO EUVI-B 195 (2006/11/11-2014/9/27)
26STEREO EUVI-B 284 (2006/12/13-2014/9/27)
27STEREO EUVI-B 304 (2006/12/13-2014/9/27)
28STEREO COR1-A (2006/12/4-present)
29STEREO COR2-A (2006/12/28-present)
30STEREO COR1-B (2006/12/12-2014/9/27)
31STEREO COR2-B (2007/1/9-2014/9/27)
32SWAP 174 (2010/1/4-present)
33SXT AlMgMn (1991/9/13-2001/12/14)
34SXT thin-Al (1991/9/13-2001/12/14)
35SXT white-light (1991/9/11-1992/11/13)
39Hinode XRT Al_med/Al_thick (2008/9/4-2017/9/10)
40Hinode XRT Al_med/Be_thick (2009/11/13-2009/11/13)
42Hinode XRT Al_med/Open (2006/11/7-2023/4/6)
43Hinode XRT Al_med/Ti_poly (2010/9/25-2010/11/18)
44Hinode XRT Al_poly/Al_mesh (2007/2/3-2020/10/23)
45Hinode XRT Al_poly/Al_thick (2006/12/16-2017/9/10)
46Hinode XRT Al_poly/Be_thick (2007/2/3-2013/4/12)
48Hinode XRT Al_poly/Open (2006/10/28-2023/4/7)
49Hinode XRT Al_poly/Ti_poly (2006/12/20-2023/4/2)
54Hinode XRT Be_med/Open (2006/11/7-2023/4/7)
62Hinode XRT C_poly/Al_mesh (2007/3/23-2007/3/24)
63Hinode XRT C_poly/Al_thick (2006/12/15-2015/3/11)
66Hinode XRT C_poly/Open (2006/11/6-2021/5/21)
67Hinode XRT C_poly/Ti_poly (2007/5/13-2014/12/11)
69Hinode XRT Open/Al_mesh (2006/10/26-2023/4/7)
70Hinode XRT Open/Al_thick (2006/10/26-2023/3/8)
71Hinode XRT Open/Be_thick (2006/10/26-2023/4/7)
74Hinode XRT Open/Ti_poly (2006/10/26-2017/8/8)
75TRACE 171 (1998/5/6-2010/6/17)
76TRACE 195 (1998/5/6-2010/6/16)
77TRACE 284 (1998/5/6-2010/6/16)
78TRACE 1216 (1998/5/6-2010/6/16)
79TRACE 1550 (1998/5/6-2010/6/16)
80TRACE 1600 (2008/5/31-2010/6/17)
81TRACE 1700 (1998/5/6-2010/6/16)
82TRACE white-light (1998/5/6-2010/6/17)
83COSMO KCor (2018/11/28-2022/11/25)
2000SUVI 94 (2022/6/15-present)
2001SUVI 131 (2022/6/15-present)
2002SUVI 171 (2022/6/15-present)
2003SUVI 195 (2022/6/9-present)
2004SUVI 284 (2022/6/15-present)
2005SUVI 304 (2022/6/9-present)
10001Hinode XRT Any/Any (2006/10/26-2023/4/7)
10002Hinode XRT Any/Al_mesh (2022/3/7-2023/4/7)
10003Hinode XRT Any/Al_thick (2022/3/11-2023/3/8)
10004Hinode XRT Any/Be_thick (2022/3/7-2023/4/7)
10006Hinode XRT Any/Open (2022/3/6-2023/4/7)
10007Hinode XRT Any/Ti_poly (2022/3/7-2023/4/2)
10008Hinode XRT Al_med/Any (2022/3/7-2023/4/6)
10009Hinode XRT Al_poly/Any (2022/3/6-2023/4/7)
10010Hinode XRT Be_med/Any (2022/3/7-2023/4/7)
10011Hinode XRT Be_thin/Any XRT Be_thin/Open (2022/3/6-2023/4/7)
10013Hinode XRT Open/Any (2022/3/7-2023/4/7)

Examples

Basic Examples (7) 

Get the most recent available image of the Sun from the Helioseismic and Magnetic Imager (HMI) on the Solar Dynamics Observatory (SDO):

In[1]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][]
Out[1]=

Get the most recent available image of the Sun from the Atmospheric Imaging Assembly (AIA) at 94 angstroms on SDO:

In[2]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][8]
Out[2]=

Get an image of the Sun from the SunSDO HMI Int nearest to a specific date:

In[3]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][DateObject[{2014, 10, 24}], 18]
Out[3]=

Get a list of images of the Sun from the SunSDO HMI Int nearest to a list of dates:

In[4]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][{DateObject[{2014, 10, 24}], DateObject[{2023, 7, 25}]}, 18, "Image"]
Out[4]=

Create an event series of solar images for a specified range of dates:

In[5]:=
With[{date = Now},
 ResourceFunction[
  "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][DateRange[date - Quantity[1, "Week"], date]]]
Out[5]=

Get an association of instrument codes and their descriptions:

In[6]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"]["InstrumentAssociation"]
Out[6]=

Return the observation date of the nearest image to the specified date:

In[7]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][
 DateObject[{2001, 3, 29}, TimeZone -> 0], 7, "Date"]
Out[7]=

Scope (5) 

Dates (4) 

Get older images of the Sun from the SOHO mission:

In[8]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][DateObject[{2001, 3, 29}, TimeZone -> 0], 7]
Out[8]=

Specify dates as strings:

In[9]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"]["March 29, 2001", 7]
Out[9]=

Get an event series of images for a list of dates:

In[10]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][{DateObject[{2023, 7, 1, 12, 0, 0}, TimeZone -> 0], DateObject[{2023, 7, 1, 10, 0, 0}, TimeZone -> 0], DateObject[{2023, 7, 21, 12, 0, 0}, TimeZone -> 0]}]
Out[10]=

Get an event series of images for a range of dates:

In[11]:=
es = With[{date = DateObject[{2001, 3, 29}, TimeZone -> 0]},
  ResourceFunction[
   "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][DateRange[date - Quantity[1, "Weeks"], date],
    7]]
Out[11]=
In[12]:=
ListAnimate[es]
Out[12]=

Get the nearest observation times for a range of dates:

In[13]:=
With[{date = Now},
 ResourceFunction[
  "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][DateRange[date - Quantity[1, "Week"], date], "Date"]]
Out[13]=

Get an event series of images of the Sun over the past week:

In[14]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"]["EventSeries"]
Out[14]=

Get an event series of images of the Sun over the past week for a specific instrument:

In[15]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][13, "EventSeries"]
Out[15]=

Instruments (1) 

Choose images from many different instruments:

In[16]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][1]
Out[16]=
In[17]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][2]
Out[17]=
In[18]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][4]
Out[18]=
In[19]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][5]
Out[19]=
In[20]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][6]
Out[20]=
In[21]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][7]
Out[21]=
In[22]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][8]
Out[22]=
In[23]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][9]
Out[23]=
In[24]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][10]
Out[24]=
In[25]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][11]
Out[25]=
In[26]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][12]
Out[26]=
In[27]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][13]
Out[27]=
In[28]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][14]
Out[28]=
In[29]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][15]
Out[29]=
In[30]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][18]
Out[30]=
In[31]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][19]
Out[31]=
In[32]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][20]
Out[32]=
In[33]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][21]
Out[33]=
In[34]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][22]
Out[34]=
In[35]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][23]
Out[35]=
In[36]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][24]
Out[36]=
In[37]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][25]
Out[37]=
In[38]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][26]
Out[38]=
In[39]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][27]
Out[39]=
In[40]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][29]
Out[40]=
In[41]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][32]
Out[41]=
In[42]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][35]
Out[42]=
In[43]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][49]
Out[43]=
In[44]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][75]
Out[44]=
In[45]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][83]
Out[45]=
In[46]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][2003]
Out[46]=
In[47]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][10007]
Out[47]=

Options (2) 

Colorize (1) 

"Colorize" can be used to turn off the artificial coloring applied by default:

In[48]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][8, "Colorize" -> False]
Out[48]=
In[49]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][10, "Colorize" -> False]
Out[49]=
In[50]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][11, "Colorize" -> False]
Out[50]=
In[51]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][12, "Colorize" -> False]
Out[51]=
In[52]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][13, "Colorize" -> False]
Out[52]=
In[53]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][15, "Colorize" -> False]
Out[53]=
In[54]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][16, "Colorize" -> False]
Out[54]=
In[55]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][18, "Colorize" -> False]
Out[55]=

BlendColors (1) 

"BlendColors" can be used to specify or override the default colors used by "Colorize":

In[56]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][18, "BlendColors" -> {Black, Orange, Yellow}]
Out[56]=
In[57]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][9, "BlendColors" -> {Black, Purple, Blue, Cyan, Green, Yellow, Orange, Red, Pink, White}]
Out[57]=
In[58]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][9, "BlendColors" -> "AuroraColors"]
Out[58]=

Neat Examples (2) 

The AIA 94 Angström instrument can show images of solar flares:

In[59]:=
ResourceFunction[
 "SolarImage", ResourceSystemBase -> "https://www.wolframcloud.com/obj/resourcesystem/api/1.0"][
 DateObject[{2023, 5, 16, 16, 43}, TimeZone -> "GMT"], 9]
Out[59]=

SpaceWeatherData can also view solar flares by plotting the X-ray emission and observing sudden spikes:

In[60]:=
DateListLogPlot[
 ResourceFunction["SpaceWeatherData"][
  Interval[{DateObject[{2023, 5, 16}, "Day"], DateObject[{2023, 5, 17}, "Day"]}], {"ShortSolarXRayFlux", "LongSolarXRayFlux"}], FrameLabel -> Automatic]
Out[60]=

Requirements

Wolfram Language 13.0 (December 2021) or above

Version History

  • 1.4.1 – 31 May 2024
  • 1.4.0 – 17 January 2024
  • 1.3.1 – 28 July 2023
  • 1.3.0 – 26 July 2023
  • 1.2.0 – 24 July 2023
  • 1.1.0 – 19 July 2023
  • 1.0.0 – 12 July 2023

Source Metadata

Related Resources

License Information