[Previous]
[Next]
NAME:
vectorproduct
PURPOSE:
Calculate vector or scalar product for two vectors
CATEGORY:
gen/idl/toolbox/math
CALLING SEQUENCE:
result = vectorproduct(r1, r2 [, /unit, /cylin, /sphere, /rect, /degrees, /scalar, /angle])
INPUTS:
r1 arrays[3,*]; type: int or float
r1 arrays[3,*]; type: int or float
vectors for which the product is to be taken.
the first dimension identifies the three coordinates: Cartesian (default),
cylindrical or spherical.
OPTIONAL INPUT PARAMETERS:
/scalar by default the vector (cross-product) is calculated. If /scalar is set
then the scalar product is calculated instead.
/angle if set then information about the angle between the two vectors is returned:
for vector products sin(angle) = |r1 x r2|/|r1||r2|
for scalar products cos(angle) = |r1.r2|/|r1||r2|
/unit if set, then a unit vector along the cross-product vector is returned
(keyword not used if /scalar is set)
/cylin, /sphere, /rect
indicates whether input vectors are in cylindrical, spherical or rectangular
coordinates. If none is set then rectangular is assumed.
For cross-products the output vectors are in the same units as the input vectors.
/degrees if set, and spherical or cylindrical coordinates are used, then the angles
are assumed to be in degrees (default: radians)
OUTPUTS:
result array[3,*] or array[*] same type as input
cross-products are returned as array[3,*] (same as the input arrays)
scalar products or angle information are returned as array[n]
OPTIONAL OUTPUT PARAMETERS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, InitVar, SyncArgs, SyncDims
CALLED BY:
PlotSolarDisk, brachistochrone, losgeometry, miscfig, plot3darc, projfig
sgp4_orbit_axis, smeifig, unitvectors
PROCEDURE:
> The arrays r1 and r2 do not necessarily have the same dimensions, i.e.
if r1 is an array[3,n] and r2 is an array[3] then r2 is interpreted as an array[3,n]
with all n vectors the same (SyncArgs is used to synchronize the array dimensions).
> Arrays r1 and r2 can have more than two dimensions, i.e. if r1 and r2 are both
arrays[3,n,m] then the output cross-vectors also will be an array[3,n,m] while scalar
products will be returned as array[n,m]
MODIFICATION HISTORY:
AUG-1999, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
view
PURPOSE:
Display 2D bitmap array. Display if running X-windows.
CATEGORY:
Imaging
CALLING SEQUENCE:
PRO view, $
input_image = input_image, $
output_image = output_image, $
new_window = new_window, $
log_scale = log_scale, $
stretch_image = stretch_image,$
truecolorimage = TrueColorImage,$
rgbplane = RGBPlane, $
tl = tl, $
trtr= tr, $
br = br, $
bl = bl, $
center = center,$
cl = cl, $
tc = tc, $
cr = cr, $
bc = bc, $
levels = levels, $
covered=covered, $
_extra = _extra
INPUTS:
input_image - file name containing 2D array, or
a 2D or 3D array
/log_scale convert the image on a log scale
(if the image contains negative values, the displayed
image is alog10(INPUT-min(INPUT)+1))
/new_window passed to TWIN to open a new window for the image
(by default the last window opened by TWIN is overwritten)
OPTIONAL OUTPUT PARAMETERS:
input_image (if input value was a file name)
array read from input file
output_image array actually displayed (different from input if
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, IsDisplay, IsType, img_read, twin
CALLED BY:
PRO bold, PRO test_magnify, TMO_tracksky, even_light, miscfig, qView_Wall, show_wso
smei_findobj, smei_star_fit, smei_star_lsqfit, smei_star_standard, stardistance
test_dumbbell, testnic, tomography_sp, trypleiades
PROCEDURE:
> The image is plotted using the TV procedure
> img_read is used to read the file
> 3D arrays are displayed using the twin/wallpaper option
MODIFICATION HISTORY:
JAN-1994, Paul Hick (UCSD)
[Previous]
[Next]
NAME:
view3d
CALLING SEQUENCE:
pro view3d, nr
INCLUDE:
@compile_opt.pro
CALLS: ***
CONGRID, CV_COORD, FILEPATH, InitVar, NewcombSun, S, SCALE3, T3D, TimeGet, TimeOp, TimeSet
TimeUnit, WRITE_BMP, WhatIs, flt_read, gridgen, vox_write
[Previous]
[Next]
NAME:
vlist
CALLING SEQUENCE:
pro vlist
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
FILEPATH, FIX2DIGITYEAR, MEAN, STDDEV, TimeGet, TimeSet, WhatIs, qBar
[Previous]
[Next]
NAME:
vox_read
PURPOSE:
Read a vox file for use with the Volume Pro board
CATEGORY:
I/O
CALLING SEQUENCE:
FUNCTION vox_read, InFile , $
count = count , $
minf = minf , $
maxf = maxf , $
topb = topb , $
version = version , $
copyright = copyright , $
vol_size = vol_size , $
vox_size = vox_size , $
vol_name = vol_name , $
gen_comments= gen_comments, $
vol_comments= vol_comments, $
errormessage= errormessage, $
silent = silent
INPUTS:
Filename scalar; type: string
file name for vox file
OUTPUTS:
Volume array[N,N,N]; type: any
array to be written to vox file
If the array is not of type byte it will be
converted to byte using the IDL bytscl function.
OPTIONAL OUTPUTS:
minf=minf
maxf=maxf
topb=topb
vol_name = vol_name
scalar; type: string
identifying name of volume data
copyright = copyright
scalar; type: string
copyright notice
gen_comments = gen_comments
array; type: string
comments stored as part of the general header information
vol_comments = vol_comments
array; type: string
comments stored as part of the volume section describing the
data array V.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, IsType, WhatIs, do_file, flt_string, gunzip_file
CALLED BY:
vu_vox_read
SEE ALSO:
write_vox
PROCEDURE:
See write_vox
MODIFICATION HISTORY:
JUL-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vox_update
PROCEDURE:
Updates collection of vox files in IPS forecast
CALLING SEQUENCE:
PRO vox_update, list, silent=silent
INPUTS:
list scalar; type: string
list of nv3d and wson files to process
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
FILEPATH, InitVar, destroyvar, hide_env, strposn, txt_read, vu_header, vu_prefix
vu_vox_write
MODIFICATION HISTORY:
JUN-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vox_write
PURPOSE:
Write a vox file for use with the Volume Pro board
CATEGORY:
I/O
CALLING SEQUENCE:
PRO vox_write, Filename, Volume, $
_extra =_extra , $
minf = minf , $
maxf = maxf , $
topb = topb , $
volumename = VolumeName, $
copyright = Copyright , $
general_comments= General_Comments, $
volume_comments = Volume_Comments , $
silent = silent
INPUTS:
Filename scalar; type: string
file name for vox file
Volume array[N,N,N]; type: any
array to be written to vox file
If the array is not of type byte it will be
converted to byte using the IDL bytscl function.
OPTIONAL INPUT PARAMETERS:
minf=minf passed to IDL function bytscl in min keyword
maxf=maxf passed to IDL function bytscl in max keyword
topb=topb passed to IDL function bytscl in top keyword
ndim=ndim scalar; type: integer
resolution of the binary file stored in the vox file
if specified then the IDL function congrid is used to
rebin the array to ndim in all three dimensions
volumename = VolumeName
scalar; type: string; default: 'Data'
identifying name of volume data
copyright = Copyright
scalar; type: string; default: 'UCSD/CASS Solar Physics Group'
copyright notice
general_comments = General_Comments
array; type: string
comments stored as part of the general header information
volume_comments = Volume_Comments
array; type: string
comments stored as part of the volume section describing the
data array V.
silent=silent
scalar; type: integer
1 or 2: suppress informational messages (higher value suppresses
more information)
OUTPUTS:
(vox file)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CONGRID, InitVar, IsType, boost
CALLED BY:
view3d, vu_vox_write
RESTRICTIONS:
PROCEDURE:
The vox file format is described in the pdf document
vp500_vol_file_format.pdf (RTViz Voxel File Format) available at
http://www.terarecon.com/support/vp500/vp500_sup_document.html
(link was alive as of 2003/05/28)
The main sections are a header section for general information, followed
by sections for each of the data volumes (including the data array
itself). Currently only a single volume is stored.
The 'Endian' indicator is set to 'B'. Note that Intel/AMD processors
are actually little endian. Since endian-ness only affects byte ordering
the setting doesn't matter as long as byte data are written to the vox
file.
MODIFICATION HISTORY:
JAN-2001, Paul Hick (UCSD/CASS)
JUL-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added /silent keyword
[Previous]
[Next]
NAME:
vu_atlocation
PURPOSE:
Extract a function values from heliospheric matrix at specified
locations (heliographic longitude, latitude, distance and time).
CATEGORY:
WWW
CALLING SEQUENCE:
FUNCTION vu_atlocation, XC3D, R3D, dR3D, F3D, sequence=sequence, $
location=location, times=times, power=power, degrees=degrees, _extra=_extra
INPUTS:
The 3D heliospheric matrix is described by the following input:
XC3D array[2] or array[2,ntime]; type: float
Carrington range of reconstruction
R3D scalar or array[ntime]; type: float
heliocentric distance at inner boundary of matrix
dR3D scalar or array[ntime]; type: float
heliocentric distance resolution of the heliospheric matrix
F3D array[n,m,l,ntype,ntime]; float
3D heliocentric matrix;
1st dim: Carrington variable, covering range XC3D
2nd dim: Heliographic latitude, covering [-90,90] degrees
3rd dim: Heliocentric distance, with inner boundary at R3D and resolution dR3D
4th dim: different data types (usually 2: velocity/density, Br/Bt
5th dim: # members in a (time-dependent) sequence
OPTIONAL INPUT PARAMETERS:
sequence=sequence
array[ntime]; type: time structure of float; default: none
if specified, these are the times corresponding to the ntime
data arrays specified in argument F3D.
power=power array[ntype]
power of heliocentric distance to be removed from the time series
(2 for normalized density; 2 for radial component of the magnetic field;
1 for tangential component)
location=location
array[3,N]; type: float
heliographic locations: longitude or Carrington variable, latitude and
heliocentric distance.
times=times array[N]; type: float or time structure
times associated with N locations.
/degrees if set, then all angles are in degrees (default: radians)
/is_carrington passed to InterpolateHeliosphere
/cv2carrington passed to InterpolateHeliosphere
/periodic passed to InterpolateHeliosphere
OUTPUTS:
F array[N]; float
the function values for all N locations
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, Carrington, InterpolateHeliosphere, IsType, SubArray, SuperArray, SyncDims
TimeInterpol, TimeOp, TimeUnit
CALLED BY:
vu_linecut, vu_planarcut, vu_radialcut, vu_solardisk, vu_spherecut, vu_synopticmap
PROCEDURE:
> The time associated with a given Carrington variable is the time at which the
corresponding heliographic longitude crossed the center of the solar disk.
MODIFICATION HISTORY:
AUG-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_check
PURPOSE:
Checks whether file names conforms to the syntax used for output files from
the tomography programs
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_check, files, times, imark, $
count = count , $
prefixlen = prefixlen , $
marker = marker , $
str_message = str_message , $
offset = offset , $
silent = silent
INPUTS:
files array; type: string
list of file names
OPTIONAL INPUT PARAMETERS:
prefixlen = prefixlen
scalar; type: integer; default: 4
length of the prefix preceding the Carrington variable in the file
name (i.e., 4 for 'nv3d2003.1234')
marker=marker
scalar; type: integer: 0,1 or not defined; default: not defined
if 0: only return filenames that do not include a marker value
(as used by the corotating tomography)
if 1: only return filenames that include a marker value
(as used by the time-dependent tomography)
if undefined:
if all filenames contain marker value then return the input list
and set return value marker=1
if none of the filenames contain marker values then return the
input list and set return value marker=0
if there is a mix of files with and without markers only return
the files without a marker and set return value marker=0
offset=offset
scalar; type: ??; default: 0
?????
OUTPUTS:
Result status??
files array; type: string
list of file names that conform. File names that don't conform
are removed from the input list
times array; type: double
times coded into the file names (Carrington variable)
imark array; type: integer
marker value coded into file name (for time-dependent tomography
files only)
OPTIONAL OUTPUT PARAMETERS:
marker=marker
scalar; type: integer
0: if none of the output filenames contain markers
1: if all of the output filenames contain marker values
count=count scalar; type: integer
# conforming file names (i.e. size of arrays files, times and imark)
str_message=str_message
scalar; type: string
message describing return status
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
GetFileSpec, InitVar, SetFileSpec, SuperArray, flt_string
CALLED BY:
vu_select, vu_set_time_entry
PROCEDURE:
MODIFICATION HISTORY:
OCT-2002, Paul Hick (UCSD/CASS)
JUN-2003, Paul Hick (UCSD/CASS)
Added check for names of gzipped files (with .gz extension)
MAR-2013, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Documented 'marker' keyword more carefully: it really is also
used for output.
[Previous]
[Next]
NAME:
vu_coronagraph
PURPOSE:
Wrapper for PlotCoronagraph. Displays a view of the sky from Earth
using a 3D heliospheric matrix from one of the tomography programs.
This is a special version of the fisheye-maps plotted by
vu_earthskymap, optimized for small coronagraph-like patches of sky.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_coronagraph, hdr, ff, $
hdr_bb = hdr_bb , $
bb = bb , $
ut0 = ut0 , $
ihdr = ihdr , $
type = type , $
nodata = nodata , $
maxelo = maxelo , $
degrees = degrees , $
equator = equator , $
_extra = _extra , $
solar = solar , $
is_sequence = is_sequence , $
point_sources=point_sources , $
printer = printer , $
count = count , $
nEE = nEE , $
nRR = nRR , $
dRR = dRR , $
silent = silent , $
module = module , $
zero_shift = zero_shift , $
wavelength = wavelength , $
filter_bb = filter_bb , $
center = center , $
use_mask = use_mask
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from the 'hdr' argument is used.
See Carrington for more details.
maxelo scalar; type: float; default: 7 degrees
Determines the size of the fisheye map
destination=destination
if set to valid directory then graphics output is saved as GIF files
/degrees if set, indicates that all angles are in degrees. Default: radians.
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along the ecliptic
Three parameters define the grid used to calculate the sky map (see PROCEDURE).
These are passed to EarthSky3DLoc:
nEE = nEE scalar; type: int; default: 100
# points in elongation
nRR = nRR scalar; type: int; default: 20
# steps along lines of sight at each point in the sky
dRR = dRR scalar; type: float; default: 0.1 AU
step size along line of sight (AU)
zero_shift passed to EarthSky3DLoc
By default the skymap is centered on the Sun. Setting 'zero_shift' moves
the center to increasing RA (or ecliptic longitude) by 'zero_shift'.
E.g. to produces an anti-solar skymap set zero_shift=!pi
(or zero_shift=180, /degrees).
point_sources=point_sources
array[n]; type: structure
information about IPS observation (location in sky, IPS speed
and g-level; see getnagoyasources.
/names if set, then the names of the point sources are plotted
/solar
Several keywords are passed to vu_type_skymap:
The most important ones set the data type to be plotted:
/ips_speed IPS speed
/ips_glevel IPS g-level
/brightness Thomson scattering brightness
/pb Thomson scattering polarization brightness
/rotationmeasure Faraday rotation measure
type=type array[1]; type: structure
wavelength=wavelength
scalar; type: any; default: none
radio wavelength in meters (used only for Faraday
rotation maps to convert the rotation measure
(in degrees/m^2) to rotation (degrees).
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
EXTERNAL:
IPS_hlevel_w, IPS_velocity, IPS_velocity_w, ThomsonBrightness
CALLS: ***
Carrington, CvSky, EarthSky3DLoc, EulerRotate, FILEPATH, GetFileSpec, IPS_params
InitVar, IntegrateLOS, IsType, PlotCoronagraph, SetFileSpec, SuperArray
ThomsonRadialFilter, ThomsonUBVConst, TimeGet, TimeUnit, ToDegrees, ToRadians
destroyvar, gridgen, set_page, smei_sky_getmask, vu_fnc, vu_get, vu_get_page
vu_getdata, vu_gettime, vu_point_source, vu_prefix, vu_select, vu_type_skymap
PROCEDURE:
The sky map is build from nRA*nDE lines of sight integrations
through the F3D array.
The locations in the sky of the lines of sight are
RA/Lng = (RA/Lng Sun) -180 + (360./nRA)*[0.5, 1.5, .. , nRA-0.5 ]
Decl./Lat = - 90 + (180./nDE)*[0.5, 1.5, .. , nDE-0.5 ]
Dist along los = dRR*[0.5,1.5,...,nRR-1]
Note that each line of sight is centered on a 'box' of 360/nRA by
180/nDE degrees, and that all lines of sight together cover the
entire sky. The edges of the boxes for all lines of sight are
returned in the RA and DE keywords
MODIFICATION HISTORY:
MAR-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Based on vu_earthskymap
[Previous]
[Next]
NAME:
vu_correlate
PURPOSE:
Correlate time series for tomography and in situ data;
CALLING SEQUENCE:
PRO vu_correlate, t1, f1, t2, f2, $
density = density , $
speed = speed , $
bradial = bradial , $
btang = btang , $
bnorm = bnorm , $
bstrength = bstrength , $
data_type = data_type , $
sc_label = sc_label , $
tm_label = tm_label , $
result_fit = result_fit , $
result_str = result_str , $
silent = silent
INPUTS:
t1 array[N]; type: time structure
times of available data points for tomographic data
f1 array[N,M]; type: float
tomographic time series.with 'bad data' indicated by
!values.f_nan. The second dimension (m) identifies the
physical quantity
m=0: density
m=1: velocity
m=2: radial magnetic field component
m=3: tangential magnetic field component
m=4: radial magnetic field component
m=5: bt^2+bn^2
m=6: total field strength
Currently only m=0,1,2,3 are provided. The others are
calculated internally. The normal component is set to zero.
t2 array[N2]; type: time structure
times of available data point for in situ data
(always the same as t1???)
f2 array[N2,M]; type: float
spacecraft in situ time series with 'bad data' indicated
by !values.f_nan containing same quantities as f1.
OPTIONAL INPUT PARAMETERS:
/speed select velocity plots
/density select density plots
/bradial select radial component of magnetic field
/btang select tangential component of magnetic field
/bnorm select normal component of magnetic field
/bstrength select magnetic field strength
tm_label=tm_label
scalar; type: string; default: 'corotating'
label used for the tomography time series
sc_label=sc_label
scalar; type: string; default: 'in situ'
label used to indicate origin of in situ data
(usually this is obtained from Instrument with
the keyword /label set).
OPTIONAL OUTPUT PARAMETERS:
result_str=result_str
array[n]; type: scalar
identifying string of correlation results for all time
series for which correlations were calculated.
result_fit=result_fit
array[6,n]; type: float
result[ 0,n]: correlation coefficient
result[1:5,n]: best fit result from function lsqNormalFit
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, CORRELATE, InitVar, boost, lsqNormalFit, say
PROCEDURE:
The 'tomo' arrays are usually extracted from a tomography output file
The 'insitu' arrays is set up by a call to InsituTimeseries
MODIFICATION HISTORY:
JUL-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Extracted from PlotInsituCurve (now called vu_insitu_curve)
[Previous]
[Next]
NAME:
vu_cvgrid
PURPOSE:
Convert between grid indices to heliospheric location and v.v.
CATEGORY:
sat/util/vupack
CALLING SEQUENCE:
FUNCTION vu_cvgrid, hdr, fromsun=fromsun, fromgrid=fromgrid, tosun=tosun, togrid=togrid, $
carrington=carrington, latitude=latitude, radius=radius, time=time
INPUTS:
hdr
OPTIONAL INPUT PARAMETERS:
fromsun = fromsun
fromgrid = fromgrid
/tosun
/togrid
/carrington
/latitude
/radius
/time
OUTPUTS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, IsType, SubArray, vu_get
PROCEDURE:
MODIFICATION HISTORY:
AUG-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_earthskymap
PURPOSE:
Wrapper for PlotEarthSkymap [1]. Displays a view of the sky from Earth
using a 3D heliospheric matrix from one of the tomography programs.
CATEGORY:
WWW: graphics
CALLING SEQUENCE:
PRO vu_earthskymap, hdr, ff, $
hdr_bb = hdr_bb , $
bb = bb , $
ut0 = ut0 , $
ihdr = ihdr , $
type = type , $
nodata = nodata , $
maxelo = maxelo , $
geolng = geolng , $
degrees = degrees , $
equator = equator , $
_extra = _extra , $
solar = solar , $
band = band , $
F_full = FF_full , $
RA_full = RA_full , $
;is_sequence = is_sequence , $
point_sources =point_sources , $
printer = printer , $
count = count , $
nRA = nRA , $
nDE = nDE , $
nRR = nRR , $
dRR = dRR , $
silent = silent , $
module = module , $
zero_shift = zero_shift , $
wavelength = wavelength , $
filter_bb = filter_bb , $
center = center , $
use_mask = use_mask
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from the 'hdr' argument is used.
See Carrington for more details.
maxelo scalar; type: float
if set and non-zero then a fish-eye map is plotted out to
elongation 'maxelo'. By default a Hammer-Aitoff map is drawn
destination=destination
if set to valid directory then graphics output is saved as GIF files
/degrees if set, indicates that all angles are in degrees. Default: radians.
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along the ecliptic
geolng scalar; type: float
geographic longitude of location on Earth (in units implied
by /degrees keyword). If 'geolng' is specified then a 'transit map'
is calculated for a one-day period centered on 'ut'
Four parameters define the grid used to calculate the sky map (see PROCEDURE).
These are passed to EarthSky3DLoc and EarthTransit3DLoc:
nRA = nRA scalar; type: int; default: 72
# points in skymap in longitudinal direction
(either right ascension or ecliptic longitude)
nDE = nDE scalar; type: int; default: 36
# points in skymap in latitudinal direction
(either declination or ecliptic latitude)
nRR = nRR scalar; type: int; default: 20
# steps along lines of sight at each point in the sky
dRR = dRR scalar; type: float; default: 0.1 AU
step size along line of sight (AU)
zero_shift passed to EarthSky3DLoc
(NOT used for sky sweeps, i.e. NOT used if 'geolng' is set).
By default the skymap is centered on the Sun. Setting 'zero_shift' moves
the center to increasing RA (or ecliptic longitude) by 'zero_shift'.
E.g. to produces an anti-solar skymap set zero_shift=!pi
(or zero_shift=180, /degrees).
point_sources=point_sources
array[n]; type: structure
information about IPS observation (location in sky, IPS speed
and g-level; see getnagoyasources.
/names if set, then the names of the point sources are plotted
/solar
(only if keyword 'band' is used)
band=band scalar; type float
used to replace a limited strip in RA in an
already existing skymap.
band: width of strip in hours
The strip is inserted into arrays specified
in keywords F_full and RA_full.
RA_full=RA_full array(nRA); type: float
F_full=FF_full array(nRA,nDE); type: float
skysweep arrays (RA and function value) where
only a strip of width band needs to be updated.
Usually these are obtained from a previous call
to this procedure. If they don't exist yet then
keyword 'band' is ignored and a full skysweep
map is intialized.
Several keywords are passed to vu_type_skymap:
The most important ones set the data type to be plotted:
/ips_speed IPS speed
/ips_glevel IPS g-level
/brightness Thomson scattering brightness
/pb Thomson scattering polarization brightness
/rotationmeasure Faraday rotation measure
type=type array[1]; type: structure
wavelength=wavelength
scalar; type: any; default: none
radio wavelength in meters (used only for Faraday
rotation maps to convert the rotation measure
(in degrees/m^2) to rotation (degrees).
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUTS:
(only if keyword 'band' is used)
RA_full=RA_full array(nRA); type: float: default: none
F_full=FF_full array(nRA,nDE); type: float; default: none
updated skysweep arrays (RA and function value)
with new strip of width band inserted
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
EXTERNAL:
IPS_hlevel_w, IPS_velocity, IPS_velocity_w, ThomsonBrightness
CALLS: ***
BadValue, Carrington, EarthSky3DLoc, EarthTransit3DLoc, FILEPATH, GetFileSpec
IPS_params, InitVar, IntegrateLOS, IsType, PlotEarthSkymap [1]
PlotEarthSkymap [2], PlotEarthSkymap [3], PlotEarthSkymap [4], SetFileSpec
SuperArray, ThomsonRadialFilter, ThomsonUBVConst, TimeGet, TimeUnit, destroyvar, say
set_page, smei_sky_getmask, vu_fnc, vu_get, vu_get_page, vu_getdata, vu_gettime
vu_point_source, vu_prefix, vu_select, vu_type_skymap
CALLED BY:
GetColors [2], GetColors [3], PlotEarthSkymap [3], PlotEarthSkymap [4], forecast
vu_localskymap, vu_movie, vu_nagoyasourcemap, vu_thomson_antifish
vu_thomson_fisheye, vu_thomson_hammer
PROCEDURE:
The sky map is build from nRA*nDE lines of sight integrations
through the F3D array.
The locations in the sky of the lines of sight are
RA/Lng = (RA/Lng Sun) -180 + (360./nRA)*[0.5, 1.5, .. , nRA-0.5 ]
Decl./Lat = - 90 + (180./nDE)*[0.5, 1.5, .. , nDE-0.5 ]
Dist along los = dRR*[0.5,1.5,...,nRR-1]
Note that each line of sight is centered on a 'box' of 360/nRA by
180/nDE degrees, and that all lines of sight together cover the
entire sky. The edges of the boxes for all lines of sight are
returned in the RA and DE keywords
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
AUG-2000, Paul Hick (UCSD/CASS)
Added option to accept a vu_read structure as a 1st argument
SEP-2001, Paul Hick (UCSD/CASS)
Fixed bug in vu_type_skymap calls
JAN-2002, Paul Hick (UCSD/CASS)
Changed the initialization procedure for a skysweep with the 'band'
keyword set. The initialization now ignores the 'band' value and simply
calculates a full skysweep map (the earlier initialization put a new
strip in an otherwise empty sky).
JUL-2002, Paul Hick (UCSD/CASS)
Added interpolation between neigbouring times of ut0, instead of
truncating to nearest grid time.
AUG-2004, Paul Hick (UCSD/CASS)
Modifed IntegrateLOS calls. For Thomson scattering brightness
maps with point sources overplotted a radial filter was applied
to the maps but not to the point sources. Fixed.
OCT-2004, Paul Hick (UCSD/CASS)
Added keyword zero_shift.
JUN-2007, Paul Hick (UCSD/CASS)
Added keyword wavelength
SEP-2007, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Bugfix. Added filter_bb as keyword.
[Previous]
[Next]
NAME:
vu_elotime
PURPOSE:
Produces a "J-map" (time vs elongation for a line-of-sight
integrated quantity from a time-dependent tomography solution
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_elotime, hdr, ff, ut0=ut0, ihdr=ihdr, $
ts_all = ts_all , $ ; Defines times in time series
ts_range = ts_range , $
ts_step = ts_step , $
pa_angle = pa_angle , $
elo_grid = elo_grid , $
nRR = nRR , $
dRR = dRR , $
degrees = degrees , $
silent = silent , $
_extra = _extra , $
delta_time = delta_time, $
readall = readall , $
printer = printer
INPUTS:
hdr array[k]; type: structure
information about the tomographic reconstruction
(single file or time-dependent sequence)
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2,k]; type: float
3D volume data associated with 'hdr'
if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from 'hdr[ihdr]' is used.
See Carrington for more details.
ihdr=ihdr scalar; type: integer; default: 0
index of header to be used for display
Keywords to define the time series (i.e. the times at which data are evaluated).
Either ts_all is used, or the pair ts_range and ts_step. If neither of these is set then
the times in 'hdr' are used).
ts_all=ts_all array; type: float or time structures
times at which data are to be evaluated, as Carrington times
or UT times.
ts_step=ts_step scalar; type: float or difference time structure: default: 0.25
time step in time series in days.
ts_range=ts_range
array[2]; type: float; default: [-15,15]
range of times centered on ut0 in days. The time series covers
[ut0-ts_range[0],ut0+ts_range[1]] in steps of ts_step.
INCLUDE:
@compile_opt.pro
@vu_fnc_include.pro ;
CALLS: ***
Carrington, CvSky, EarthSky3DLoc, EulerRotate, IPS_params, InitVar, IntegrateLOS
IsTime, IsType, PlotEloTimeMap, SuperArray, ThomsonRadialFilter, ThomsonUBVConst
TimeGet, TimeOp, TimeSet, TimeUnit, ToDegrees, ToRadians, destroyvar, gridgen, set_page
vu_fnc, vu_get, vu_get_page, vu_getdata, vu_gettime, vu_is_sequence, vu_point_source
vu_select, vu_type_skymap
MODIFICATION HISTORY:
DEC-2008, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_extract
PURPOSE:
Interpolate data in region of interest for points
specified in any one of the reference frames
supported by CvSky
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_extract, hdr, ff , $
speed = speed , $
density = density , $
brad = brad , $
btang = btang , $
rr = rr , $
ndim = ndim , $
range = range , $
grid = grid , $
coord1 = coord1 , $
coord2 = coord2 , $
coord3 = coord3 , $
rectangular = rectangular , $
degrees = degrees , $
write = write , $
format = format , $
destination = destination , $
outfiles = outfiles , $
silent = silent , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
/speed if set, processes the velocity data
This is the default if neither /speed or /density are set.
/density if set, processes the density data
/bradial if set, process radial magnetic field
/btang if set, process tangential magnetic field
The reference frame is selected using one of the from_* keywords
of CvSky (e.g. if /from_ihg is set then all coordinates are
assumed to be IHG coordinates).
/degrees if set, then all angles are in degrees (default: radians)
/rectangular if set, then input coordinates are assumed to be
in rectangular coordinates (default: spherical
coordinates).
The heliospheric locations where interpolated data are requested
can be specified using one of three ways:
(1) Explicitly (using keyword "rr"):
rr = rr array[3,*]; type: float; default: none
Points specified in spherical or rectangular
coordinates, depending on setting of /rectangular:
If /rectangular NOT set:
rr[0,*]: longitudes
rr]1,*]: latitudes
rr[2,*]; heliocentric distances (AU)
If /rectangular SET:
rr[0,*]: x-coordinates (AU)
rr[1,*]: y-coordinates (AU)
rr[2,*]: z-coordinates (AU)
If rr is defined then the keywords below (ndim,range,coord1
coord2,coord3) are ignored.
(2) Specify the range of the three spatial dimensions
using the keywords coord1, coord2, coord3.
When used, all three keyword must be specified.
coord1 = coord1 scalar or array[n1]; type: float
x-coordinates or longitudes of points
coord2 = coord2 scalar or array[n2]; type: float
y-coordinate of latitudes of points
coord3 = coord3 scalar or array[n2]; type: float
z-coordinates or heliocentric distances of points
If /rectangular is SET then rectangular
(x,y,z) coordinates are assumed.
If /rectangular is NOT set, then spherical
(longitude, latitude, heliocentric distance)
coordinates are assumed.
If /grid is SET then coord1,coord2,coord3 are
assumed to be 1-dim grids (not necessarily
equally spaced) for the three spatial
coordinates. The 3-D grid used has dimension
[3,n1,n2,n3], combining all elements in
coord1, coord2 and coord3.
In this case keyword "ndim" is ignored.
If /grid is NOT set, then coord1, coord2 and
coord3 are assumed to be 2-element array
representing ranges (start and end values),
and the 3-element array "ndim" specifies the
number of grid points in each dimension.
The 3-D grid has dimensions
[3,ndim[0],ndim[1],ndim[2]] covering ranges
coord1, coord2 and coord3 in each dimension.
If /rectangular is NOT set, then an open grid
is used for longitude and latitude, e.g. for
36 points of longitude the values will be
5,15,..,355.
(3) Use keywords range and ndim, to set up an equally
spaced spherical or rectangular grid.
ndim = ndim scalar; array[3]; type: integer
grid resolution for three spatial dimensions
/rectangular NOT set: default: [72,36,31]
/rectangular SET : default: [31,31,31]
range = range array[2,3]; ranges for the three spatial dimensions
Angles are in units set by keyword /degrees;
distances are in AU.
/rectangular NOT set:
longitude (default: [ 0,360])
latitude (default: [-90, 90])
heliocentric distance (default: [0,3]
An open grid is used for longitude and latitude,
e.g. for 36 points of longitude the values will
be 5,15,..,355.
/rectangular SET:
rectangular x,y,z coordinates
(default: [-3,3] AU for all three coordinates)
/write If set, then write function values into
ascii files.
destination = destination
scalar; type: string; default: same
directory as tomography file
Destination directory for output files.
Only used if /write is set
Additional keywords:
Keywords passed to vu_getdata are explained there.
/from_* keywords are passed to CvSky.
OUTPUTS:
rr = rr array[3,*]; type: float
grid for which function values are returned.
This is returned in the coordinate system
implied by the selected from_* keyword to CvSky.
OPTIONAL OUTPUTS:
outfiles=outfiles array; type: string
list of names of all files created
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
AngleRange, CV_COORD, Carrington, CvSky, FILEPATH, GetFileSpec, InitVar, IsType
PutFileSpec, SetFileSpec, SuperArray, TimeGet, ToDegrees, WhatIs, boost, destroyvar
gridgen, hide_env, vu_fnc, vu_get, vu_getdata, vu_type_insitu
EXAMPLE:
gg = vu_extract(hdr,ff,coord1=[0,360],coord2=[-90,90], $
coord3=1.0,ndim=[360,180],/degrees,/from_ihg,/density)
or
gg = vu_extract(hdr,ff,range=[[0,360],[-90,90],[1,1]], $
ndim=[360,180,1],/degrees,/from_ihg,/density)
returns a float array of size [360,180,1] for the density
at 1 AU for a 1-degree grid in IHG coordinates.
PROCEDURE:
> The name of the output file is based on the name of the
tomography file, e.g. t3d_1962.345 will be output as
t3d_1962_345.out
The selected matrix is used to calculate function values
by linear interpolation.
MODIFICATION HISTORY:
JUN-2008, Paul Hick (UCSD/CASS)
[Previous]
[Next]
NAME:
vu_filename
PURPOSE:
Construct filename for tomography output file
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_filename, prefix, time, marker=marker, root=root, format=format
INPUTS:
prefix scalar; type: string; default: 'nv3d' (plasma file)
'nv3d' or 'wson' (magnetic field file)
time time to be coded into filename as a Carrington variable
OPTIONAL INPUT PARAMETERS:
marker=marker 'marker' value coded into file name if not equal zero
format=format scalar; type: string; default: '(F9.4)'
format used to code Carrington variable into filenamae
root=root scalar; type: string; default: none
directory prefixed to constructed filename
OUTPUTS:
result scalar; type: string
filename
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, FILEPATH, InitVar, IsType, vu_prefix
CALLED BY:
vu_write
PROCEDURE:
MODIFICATION HISTORY:
SEP-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_fnc
PURPOSE:
Returns in situ quantities for plotting by other vu_* procedures
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_fnc, id, ff , $
count = count , $
unit = unit , $
symbol = symbol , $
normalized = normalized, $
name = name , $
shortid = shortid , $
color = color , $
t3d_array = t3d_array , $
dimension = dimension , $
get_order = get_order , $
los = los , $
all = all
INPUTS:
id
ff
OPTIONAL INPUT PARAMETERS:
/count
/unit
/symbol
/name
/shortid
/color
/t3d_array
dimension=dimension
/get_order
/los
OUTPUTS:
Result
OPTIONAL OUTPUT PARAMETERS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
InitVar, IsType, SubArray
CALLED BY:
PlotCoronagraph, PlotEarthSkymap [1], RemoteView_Display2D, vu_coronagraph
vu_earthskymap, vu_elotime, vu_extract, vu_insitu, vu_insitu_type__define
vu_insitucurve, vu_linecut, vu_planarcut, vu_radialcut, vu_remoteview
vu_skymap_type__define, vu_solardisk, vu_spherecut, vu_synopticmap
vu_type_insitu, vu_type_skymap, vu_vox_write, vu_whatis
PROCEDURE:
MODIFICATION HISTORY:
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_fnc_include
PURPOSE:
Include file for vu package
CATEGORY:
CALLING SEQUENCE:
@vu_fnc_include
PROCEDURE:
MODIFICATION HISTORY:
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_get
PURPOSE:
Extract information from headers produced by tomography programs
CATEGORY:
sat/util/vupack
CALLING SEQUENCE:
FUNCTION vu_get, hdr, $
file = file , $
created = created , $
bad = bad , $
version = version , $
prefix = prefix , $
time_index = time_index , $
uttime = uttime , $
forecast_time = forecast_time , $
array_range = array_range , $
roi_range = roi_range , $
latitude_range = latitude_range, $
start_distance = start_distance, $
stop_distance = stop_distance , $
distance_step = distance_step , $
start_time = start_time , $
time_step = time_step , $
power_density = power_density , $
power_distance = power_distance, $
density_at_1AU = density_at_1AU, $
smooth_filter = smooth_filter , $
fill_filter = fill_filter , $
time_filter = time_filter , $
clip_longitude = clip_longitude, $
scale = scale , $
power_norm = power_norm , $
nlng = nLng , $
nlat = nLat , $
nrad = nRad , $
ntim = nTim , $
dimension = dimension , $
iteration = iteration , $
nltot = nltot , $
nlos = nlos , $
dlos = dlos , $
binx = binx , $
user_info = user_info , $
marker = marker , $
plasma = plasma , $
magnetic = magnetic , $
all_radii = all_radii , $
start_lng = start_lng , $
degrees = degrees
INPUTS:
hdr array[n]; array of headers extracted from tomography files
OPTIONAL INPUT PARAMETERS:
The output R depends on the keyword set:
Keyword: Return values:
/file scalar; type: string; fully-qualified file name
/created scalar; type: string; time at which file was created
/bad scalar; type: float; value reprenting 'bad' data
/version scalar; type: string; version number for header layout
/time_index
/uttime
/forecast_time
/array_range
/roi_range
/latitude_range
/start_distance
/stop_distance
/distance_step
/start_time
/time_step
/power_density
/power_distance
/density_at_1AU
/smooth_filter
/fill_filter
/time_filter
/clip_longitude
/scale array[4]; type: float; scaling factors
/power_norm array[2]; type: float
/nlng scalar; type: integer; longitudinal dimension
/nlat scalar; type: integer; latitudinal dimension
/nrad scalar; type: integer; radial dimension
/ntim scalar; type: integer; time dimension
/dimension array[4]; type: integer; # longitudes, latitudes, distances and times
/iteration
/nltot array[2]; type: integer; # lines of sight
/nlos array[2]; type: integer, # line-of-sight segments
/dlos array[2]; type: float; length of line-of-sight segment
/binx array[2]; type: float; # line-of-sight segments per bin threshold
/user_info
/marker
/plasma scalar; type: integer: 1 for velocity/density data
/magnetic scalar; type: integer; 1 for magnetic field data
/all_radii array[nRad]; type: float; array of heliocentric distances for hdr[0] only
/start_lng scalar; type: double: heliographic longitude at start of ROI
/degrees
OUTPUTS:
R requested entry from header
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
ToDegrees, gridgen
CALLED BY:
GetColors [2], GetColors [3], PlotEarthSkymap [3], PlotEarthSkymap [4], forecast
make_r2_density, qRemoteView_Pick, qvu_draw, qvu_pick, vu_coronagraph, vu_cvgrid
vu_earthskymap, vu_elotime, vu_extract, vu_getdata, vu_gettime, vu_insitu
vu_insitu_persist, vu_insitu_raw, vu_is_sequence, vu_linecut, vu_lineofsight
vu_mean, vu_movie, vu_new_time, vu_planarcut, vu_quick_movie, vu_radialcut, vu_read
vu_remoteview, vu_select, vu_solardisk, vu_spherecut, vu_stereoview, vu_syncgrid
vu_synopticmap, vu_thomson_antifish, vu_thomson_hammer, vu_vox_write, vu_whatis
vu_write
SEE ALSO:
T3D_get, T3D_iget
MODIFICATION HISTORY:
JUL-2001, Paul Hick (UCSD/CASS)
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added start_lng keyword
PROCEDURE:
[Previous]
[Next]
NAME:
vu_get_page
PURPOSE:
Save the zbuffer into image files to be used for the IPS forecast Web page
CATEGORY:
I/O
CALLING SEQUENCE:
PRO vu_get_page, hdr, module, $
destination = destination , $
device = device , $
use_image = use_image , $
png = png , $
gif = gif , $
bmp = bmp , $
title = title , $
ut = ut , $
upto = upto , $
silent = silent , $
new = new , $
logo = logo , $
notwin = notwin
INPUTS:
hdr array[1]; type: structure
scalar; type: string
header structure or name of tomography file used
to generate the plot
module scalar; type: string
module name describing the plot in the z-buffer
e.g. 'earth_insitu_v', etc.
OPTIONAL INPUTS:
destination=destination
scalar or array[2]; type: string
If the first element is a valid directory then an
image file is created in that directory with a name
based on the module name.
If a 2nd directory is specified a backup copy is written
to subdirectory 'module' of this 2nd directory.
If this keyword is not specified then the image is
displayed on the terminal.
The first element can also be a valid file name to
be used to name the output image file
gif=gif if set then images are saved as gif files
png=png if set then images are saved as png files
ut=ut scalar or array[1]; time; default: none
time used in title for IDL window, or used in
construction of image file name. Usually this is the
forecast time.
device=device scalar; type: string; default: none
graphics device to switch to after the z-buffer has
been read.
use_image=use_image
scalar; type: string
If keyword 'destination' is specified, then the image
file (and optional backup copy) is by default created
by reading the Z-buffer.
If an image file is already created then its
fully-qualified name can be specified in keyword
'use_image', bypassing reading the Z-buffer. The
use_image file will be moved to 'destination[0]'
and, optionally, a copy is placed in a subdirectory
of 'destination[1]'.
OUTPUTS:
(Two image files)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, CheckDir, FILEPATH, GetFileSpec, InitVar, IsType, STRETCH, SetFileSpec
TimeGet, TimeUnit, boost, do_file, flip_colors, get_page, hide_env, say
CALLED BY:
GetColors [2], GetColors [3], PlotEarthSkymap [3], PlotEarthSkymap [4]
vu_coronagraph, vu_earthskymap, vu_elotime, vu_insitu, vu_insitu_persist
vu_planarcut, vu_remoteview, vu_solardisk, vu_spherecut, vu_synopticmap
vu_thomson_antifish, vu_thomson_hammer
PROCEDURE:
The current graphics device should be the z-buffer. The z-buffer is read
by a simple tvrd(), and is then either displayed on the screen, or written
to an image file.
Two identical image files are created in subdirectories, 'www' and
'images/module' of the root directory $dat/nagoya.
The file in 'www' is named 'module#.gif' where # is an integer digit,
equal to the number of elements in nv3d_file. This file is used directly
in the Web page.
The file in 'images' is named 'nv3d_file[0]_#####.module#.gif. Here the
5-digit integer is the time differences in minutes between the system
time and the time that file nv3d_file[0] was created. This file serves
as a backup copy and can also be used to make movies from sequences of
GIF files.
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
MAY-2000, Paul Hick (UCSD/CASS)
The skysweep map is now written only once for each tomography run
(instead of each hour).
AUG-2000, Paul Hick (UCSD/CASS)
Added /speed and /density keywords. If one of these is set then '_v'
or '_n' is added to the name of the gif files.
Added 'destination' keyword to control destination of gif files.
FEB-2001, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added the postfix _v or _n to the subdirectory in $dat/nagoya/image
where the backup copy of the gif file is stored, i.e. density and
velocity images are now stored in separate directories).
APR-2003, Paul Hick (UCSD/CASS)
Removed check for modules skysweep, fore/aftcast (used to avoid
unnecessarily writing files). Changed file name convention for the
backup image file. The title keyword explicitly allows specification
of a prefix, replacing the default name of the nv3d file name
specified in 'hdr'. The forecast time is now encoded as a UT time
string instead of a Carrington rotation.
APR-2003, Paul Hick (UCSD/CASS)
Introduce hide_env calls in messages.
AUG-2004, Paul Hick (UCSD/CASS)
Added option to allow destination[0] to be a valid filename.
OCT-2006, Paul Hick (UCSD/CASS)
Added logo keyword
[Previous]
[Next]
NAME:
vu_getdata
PURPOSE:
Provides a standardized way of reading in tomography files
CATEGORY:
Tomography I/O
CALLING SEQUENCE:
FUNCTION vu_getdata, hdr, ff, $
ut0 = ut0 , $
ihdr = ihdr , $
count = count , $
fresh = fresh , $
last_hdr = last_hdr , $
silent = silent , $
_extra = _extra , $
bfield = bfield , $
bcount = bcount , $
bhdr = bhdr , $
bff = bff
INPUTS:
hdr array; type: header structure
ff array; data arrays associated with 'hdr' array
If not specified, then data will be read using
vu_select or vu_read.
OPTIONAL INPUT PARAMETERS:
/fresh if set, input variables hdr and ff are destroyed, triggering
selection of new data files.
ihdr = ihdr scalar; type: integer
Identifies 'principal header'; the only effect of this
keyword is, that if ut0 is NOT set then the return value
of ut is hdr[ihdr].time ihdr takes precedence over ut0
ut0 = ut0 scalar; type: float; default: none
array[1]; type: time structure
Carrington variable or time structure.
Alternative way of selecting the 'principal header' if
keyword ihdr is NOT set: ihdr is set to the index
of the header with time closest to ut0
For additional keywords see vu_select and vu_read
OUTPUTS:
Result scalar; type: float
array[1]; type: time structure
'Principal time'.
Set to iput value of 'ut0' if specified, or else set
to the time of the 'principal header' hdr[ihdr].time
hdr array; type: header structure
ff array; data arrays associated with 'hdr' array
Data read by vu_select or vu_read
OPTIONAL OUTPUT PARAMETERS:
count=count scalar; type: integer
# headers and files read; 0 if something went wrong
ihdr=ihdr scalar; type: integer
index of 'principal header'.
If specified as input value it is checked to stay
inside array limits. If no input 'ihdr' is specified
then the 'ihdr' value nearest to 'ut0' is selected.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, FILEPATH, GetFileSpec, InitVar, IsType, SetFileSpec, TimeGet, TimeOp
TimeUnit, destroyvar, say, vu_get, vu_read, vu_select
CALLED BY:
GetColors [2], GetColors [3], PlotEarthSkymap [3], PlotEarthSkymap [4]
make_r2_density, qvu_pick, vu_coronagraph, vu_earthskymap, vu_elotime, vu_extract
vu_insitu, vu_linecut, vu_lineofsight, vu_localskymap, vu_planarcut, vu_radialcut
vu_remoteview, vu_solardisk, vu_spherecut, vu_stereoview, vu_synopticmap
vu_thomson_antifish, vu_thomson_hammer, vu_vox_write, vu_whatis
PROCEDURE:
ut can be a Carrington variable or a time structure. Use Carrington to
settle on either one of these.
MODIFICATION HISTORY:
APR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Modified use of keyword ut0. ut0 now only sets the return
value of ihdr, not the return value ut anymore (used to be set to
hdr[ihdr].time if hdr referred to a time sequence.
[Previous]
[Next]
NAME:
vu_gettime
PURPOSE:
Get data for a specific time
CATEGORY:
Tomography I/O
CALLING SEQUENCE:
FUNCTION vu_gettime, hdr, ff, $
ut = ut , $
count = count , $
ff_ut = ff_ut , $
fixgrid = fixgrid , $
bracket = bracket , $
nowrap = nowrap , $
silent = silent
INPUTS:
hdr array; type: header structure
ff array; data arrays associated with 'hdr' array
Typically these arrays have been read
by a previous call to vu_getdata
OPTIONAL INPUT PARAMETERS:
ut = ut scalar; type: float; default: none
array[1]; type: time structure
Carrington variable or time structure.
Time at which data are needed
/fixgrid if set then time ut is rounded to the nearest grid time
(instead of interpolating between neighbouring times)
/nowrap passed to vu_mean (which passes it to AlignHeliosphere)
OUTPUTS:
Result array[1]; type: header structure
Header structure for data at time ut0
ff_ut array[*,*,*,2]; data array associated with 'hdr_ut' array
OPTIONAL OUTPUT PARAMETERS:
count=count scalar; type: integer
0 on error; 1 if data array was obtained successfully
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, InitVar, IsTime, IsType, TimeInterpol, TimeOp, TimeUnit, say, vu_get, vu_mean
EXTERNAL:
vu_header__define
CALLED BY:
GetColors [2], GetColors [3], PlotEarthSkymap [3], PlotEarthSkymap [4], forecast
qvu_draw, vu_coronagraph, vu_earthskymap, vu_elotime, vu_insitu_persist
vu_insitu_raw, vu_linecut, vu_lineofsight, vu_planarcut, vu_radialcut
vu_remoteview, vu_solardisk, vu_spherecut, vu_synopticmap, vu_thomson_antifish
vu_thomson_hammer
PROCEDURE:
ut can be a Carrington variable or a time structure.
Use Carrington to settle on either one of these.
MODIFICATION HISTORY:
JUL-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu
[Previous]
[Next]
NAME:
vu_header
PURPOSE:
Reads header from nv3d* or wson* file
CATEGORY:
I/O
CALLING SEQUENCE:
FUNCTION vu_header, files, $
check = check , $
index = index , $
count = count , $
sort_time = sort_time , $
allow_nrad_changes = allow_nrad_changes, $
silent = silent
INPUTS:
files array; type: string
list of file names
OPTIONAL INPUT PARAMETERS:
/check forces consistency checks
- check array dimensions
- check source surface distance and radial separation
- check data type
/sort_time sort headers into chronological order before returning
(if the 'files' array is output from vu_select this is done
already)
/allow_nrad_changes
if /check is set this bypasses the check on the number of
radial distances. The start distance and step size must be
identical for all headers, but the number of distances
can vary (vu_read will only read the minimum number
of distances specified in all headers).
OUTPUTS:
Result array; type: vu_header structure
header information for all files
if /sort_time is set then the headers are sorted
into chronological order before returning.
files array; type: string
input array with files that are not
valid nv3d* or wson* files remove
OPTIONAL OUTPUT PARAMETERS:
count scalar; type: long integer
# entries returned in arrays 'files' and 'hdrs'
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, GetFileSpec, InitVar, SetFileSpec, TimeOp, TimeSet, TimeUnit, destroyvar
flt_read, flt_string, hide_env, say, vu_set_time_entry
EXTERNAL:
vu_header__define
CALLED BY:
ipsv [1], ipsv [2], ipsv [3], vox_update, vu_select
RESTRICTIONS:
Using the /sort_time keyword may have unexpected effects when reading files
with markers in the file name (from the time-dependent tomography) due to
precision problems with the Carrington variables used in the file name
(the last digit is just barely significant).
PROCEDURE:
Lines in the file header are used to fill a structure containing the
information about the file content. The exact strings used to identify the
information in each line should match the strings used in the Fortran
subroutine vu_header.
MODIFICATION HISTORY:
FEB-2001, Paul Hick (UCSD/CASS)
JAN-2001, Paul Hick (UCSD/CASS)
Added /exp to flt_string call for reading powers for density and distance
dependence of density flucuations
JUL-2002, Paul Hick (UCSD/CASS)
V1.03; added nl, nlos, dlos and binx
JUN-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added capability to handle *.gz files transparently
[Previous]
[Next]
NAME:
vu_header__define
PURPOSE:
Automatic definition of structure for storing parameters
for Nagoya IPS observations
CATEGORY:
tomography
CALLING SEQUENCE:
PRO vu_header__define
INPUTS:
(none)
OUTPUTS:
(none)
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL BY:
vu_gettime, vu_header, vu_select
PROCEDURE:
Called automatically when when using expression {vu_header}
MODIFICATION HISTORY:
FEB-2001, Paul Hick (UCSD/CASS)
MAR-2002, Paul Hick (UCSD/CASS)
V1.02; added hdr.latitude_range
JUL-2002, Paul Hick (UCSD/CASS)
V1.03; added nl, nlos, dlos and binx
SEP-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
V1.04; added prefix
[Previous]
[Next]
NAME:
vu_image
PURPOSE:
Save the zbuffer into image files to be used for the IPS forecast Web page
CATEGORY:
I/O
CALLING SEQUENCE:
PRO vu_image, hdr, module, $
destination = destination , $
device = device , $
notwin = notwin , $
use_image = use_image , $
png = png , $
title = title , $
ut = ut , $
upto = upto
INPUTS:
hdr array[1]; type: structure
scalar; type: string
header structure or name of tomography file used
to generate the plot
module scalar; type: string
module name describing the plot in the z-buffer
e.g. 'earth_insitu_v', etc.
OPTIONAL INPUTS:
destination=destination
scalar or array[2]; type: string
If the first element is a valid directory then an
image file is created in that directory with a name based
on the module name.
If a 2nd directory is specified a backup copy is written
to subdirectory 'module' of this 2nd directory.
If this keyword is not specified then the image is
displayed on the terminal.
gif=gif if set then images are saved as gif files
png=png if set then images are saved as png files
ut=ut scalar or array[1]; time; default: none
time used in title for IDL window, or used in construction
of image file name. Usually this is the forecast time.
device=device scalar; type: string; default: none
graphics device to switch to after the z-buffer has been read.
/notwin if set then the call to 'view' is skipped, and the content of the
Z-buffer is displayed directly using the 'tv' command.
use_image=use_image
scalar; type: string
If keyword 'destination' is specified, then the image file (and optional
backup copy) is by default created by reading the Z-buffer.
If an image file is already created then its fully-qualified
name can be specified in keyword 'use_image', bypassing reading
the Z-buffer. The use_image file will be moved to 'destination[0]'
and, optionally, a copy is placed in a subdirectory of 'destination[1]'.
OUTPUTS:
(Two image files)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, CheckDir, FILEPATH, GetFileSpec, InitVar, IsDisplay, IsType, SetFileSpec
TimeGet, TimeUnit, do_file, flip_colors, get_page, say
PROCEDURE:
The current graphics device should be the z-buffer. The z-buffer is read by a simple
tvrd(), and is then either displayed on the screen, or written to an image file.
Two identical image files are created in subdirectories, 'www' and 'images/module'
of the root directory $dat/nagoya.
The file in 'www' is named 'module#.gif' where # is an integer digit, equal to the
number of elements in nv3d_file. This file is used directly in the Web page.
The file in 'images' is named 'nv3d_file[0]_#####.module#.gif. Here the 5-digit integer
is the time differences in minutes between the system time and the time that file
nv3d_file[0] was created. This file serves as a backup copy and can also be used to
make movies from sequences of GIF files.
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
MAY-2000, Paul Hick (UCSD/CASS)
The skysweep map is now written only once for each tomography run (instead of each hour).
AUG-2000, Paul Hick (UCSD/CASS)
Added /speed and /density keywords. If one of these is set then '_v' or '_n' is added
to the name of the gif files.
Added 'destination' keyword to control destination of gif files.
FEB-2001, Paul Hick (UCSD/CASS)
Added the postfix _v or _n to the subdirectory in $dat/nagoya/image where the
backup copy of the gif file is stored, i.e. density and velocity images are now
stored in separate directories).
APR-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu
Removed check for modules skysweep, fore/aftcast (used to avoid unnecessarily writing files).
Changed file name convention for the backup image file. The title keyword explicitly allows
specification of a prefix, replacing the default name of the nv3d file name specified in 'hdr'.
The forecast time is now encoded as a UT time string instead of a Carrington rotation.
[Previous]
[Next]
NAME:
vu_insitu
PURPOSE:
Produces a plot, comparing a time series from a tomographic reconstruction
and insitu observations from instrument 'source'.
CATEGORY:
vupack
CALLING SEQUENCE:
PRO vu_insitu, hdr, ff, ut0=ut0, ihdr=ihdr, $
ts_all = ts_all , $ ; Defines times in time series
ts_range = ts_range , $
ts_step = ts_step , $
ti_range = ti_range , $ ; Controls s/c insitu data
nofuture = nofuture , $
delt = delt , $
source = source , $
periodic = periodic , $
printer = printer , $
noplot = noplot , $
tm_label = tm_label , $
power = power , $
type = type , $
nosequence = nosequence, $
use_forecast_time = use_forecast_time, $
cast_offset = cast_offset, $
silent = silent , $
body = body , $
module = module , $
ascii_file = ascii_file, $
_extra = _extra , $
sc_label = sc_label , $
f1=f1, f2=f2, t1=t1, t2=t2
INPUTS:
hdr array[k]; type: structure
information about the tomographic reconstruction
(single file or time-dependent sequence)
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2,k]; type: float
3D volume data associated with 'hdr'
if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from 'hdr[ihdr]' is used.
See Carrington for more details.
ihdr=ihdr scalar; type: integer; default: 0
index of header to be used for display
/nosequence Only used if n_elements(hdr) > 1
if n_elements(hdr) > 1 then an attempt is made to determine whether
the input data can be treated as a time-ordered sequence, e.g. output
from the time-dependent tomography (see vu_is_sequence).
Override this check by setting /nosequence.
/forecast if set, a dashed line at the plot center is added, and the word
'FORECAST' is plotted to the right of the dashed line.
/use_forecast_time
(only for internal use by vu_rawtimeseries)
power=power scalar, array[2] or array[2,k]; type: float
normalization applied to the data if 'ff' by vu_timeseries.
If NOT set then then the values are extracted from 'hdr'.
Override these values by setting this keyword. If setting these
to an array be careful to be consistent with the array structure
of 'hdr' and 'ff'.
body=body scalar; type: string; default: none
selects a body for which we have an ephemeris available
the timeseries for the selected body is plotted.
E.g. body=jpl_body(/mars,/string) plots a time series for Mars.
Keywords to define the time series (i.e. the times at which data are evaluated).
Either ts_all is used, or the pair ts_range and ts_step. If neither of these is set then
the times in 'hdr' are used).
ts_all=ts_all array; type: float or time structures
times at which data are to be evaluated, as Carrington times
or UT times.
ts_step=ts_step scalar; type: float or difference time structure: default: 0.25
time step in time series in days.
ts_range=ts_range
array[2]; type: float; default: [-15,15]
range of times centered on ut0 in days. The time series covers
[ut0-ts_range[0],ut0+ts_range[1]] in steps of ts_step.
Keywords to limit the range of in situ data plotted.
ti_range=ti_range
array[1] or array[2]; type: time_structure or Carrington variable
if array[1] only in situ data upto ti_range[0] are plotted
if array[2] only in situ data inside time range ti_range are plotted.
/nofuture if set, ti_range is set to ut0, i.e. only in situ data up to time ut0
(usually the forecast time) are plotted.
Keywords to select in situ data (see InsituTimeSeries):
source=source scalar; type: integer
identifies insitu instrument (see function Instrument
delt=delt scalar; type: time difference structure, or float; default: 0.0
if present, and non-zero, time window used for averaging (days)
the in situ date from instrument 'source'
For keywords controlling plot layout see vu_type_insitu.
ascii_file=ascii_file
scalar; type: string
name of file used to write timeseries data in ascii
If ascii_file='terminal" output is written to terminal.
OUTPUTS:
(graphics)
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
BadValue, Carrington, InitVar, InsituTimeSeries, Instrument, IsTime, IsType
SetFileSpec, TimeGet, TimeOp, TimeSet, TimeUnit, UNIQ, big_body, destroyvar, gridgen
hide_env, jpl_body, set_page, vu_fnc, vu_get, vu_get_page, vu_getdata, vu_insitucurve
vu_is_sequence, vu_prefix, vu_timeseries, vu_type_insitu
CALLED BY:
forecast, vu_insitu_persist, vu_insitu_raw, vu_movie
PROCEDURE:
> The input file(s) come from a tomographic reconstruction, and contain 3D
heliospheric matrices for density and velocity (nv3d* file) or magnetic
field (wson* file). The file(s) are read using vu_getdata.
> If a time-dependent sequence is processed the times from the headers are
used for the time series at Earth. For a single matrix ut0, ts_range and
ts_step determine the time series.
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
SEP-2002, Paul Hick (UCSD/CASS)
Added ts_all and /user_forecast_time keywords.
OCT-2002, Paul Hick (UCSD/CASS)
Dropped /earth keyword and associated section of code that
was used to compare time series from nv3d* and ea* files.
FEB-2007, Paul Hick (UCSD/CASS)
Added option to print to terminal
AUG-2007, George Megally(UCSD/CASS; gmegally@ucsd.edu
Expanded program to include STEREO A/B satellites.
AUG-2007, Paul Hick (UCSD/CASS)
Renamed keyword 'from' to 'source' to avoid conflicts
with 'from' keyword 'from' Time* functions
NOV-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added keyword sc_label to return value set here to caller.
[Previous]
[Next]
NAME:
vu_insitu_persist
PURPOSE:
Makes time series plots of data values at the location of Earth
from the raw tomography files (in particular from time-dependent tomography).
All available 'raw' tomography runs in the specified input directory are used.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_insitu_persist, hdr, ff , $
ut0 = ut0 , $
cast_offset = cast_offset , $
ntrail = ntrail , $
silent = silent , $
printer = printer , $
_extra = _extra
INPUTS:
hdr
ff
OPTIONAL INPUT PARAMETERS:
ut0 = ut0 scalar ; type: float
array[1]; type: time structure
forecast time on which to center the time series
specified as Carrington time or time structure in UT
(passed to vu_insitu)
cast_offset=cast_offset
scalar : type: float; default: 0.0
array[1]; type: time difference structure
fore- or aftcast time relative to the forecast time
(i.e. relative to the time at which the tomography was run)
specified in days or as a time difference structure.
ntrail=ntrail scalar; type: integer; default: none
if set, then only the most recent 'ntrail' tomography are
used
OUTPUTS:
(plot to screen, printer or image file)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, InitVar, IsTime, IsType, TimeGet, TimeInterpol, TimeOp, TimeSet, TimeUnit, UNIQ
set_page, vu_get, vu_get_page, vu_gettime, vu_insitu, vu_insitucurve, vu_select
vu_type_insitu, where_common
EXAMPLE:
vu_insitu_persist,path=filepath(root=getenv('NAGOYA'),sub=['fast','raw'],'nice'),filter='nv3h*',delt=0.25,source='acesw',/correlation,/timeseries
PROCEDURE:
The time axis on the plot is the forecast time stored in the headers
(retrieved with vu_get(hdr, /forecast_time).
Works similar to the fore/aftcast plots made by vu_insitu_raw, but instead
of using the tomography forecast at t+cast_offset and plotting it against
the insitu data at the same times, it plots the tomography difference
between times t+cast_offset and t against the insitu difference between
the same times.
MODIFICATION HISTORY:
NOV-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Based on vu_insitu_raw
[Previous]
[Next]
NAME:
vu_insitu_raw
PURPOSE:
Makes time series plots of data values at the location of Earth
from the raw tomography files (in particular from time-dependent tomography).
All available 'raw' tomography runs in the specified input directory are used.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_insitu_raw, hdr, ff , $
ut0 = ut0 , $
fixed_time = fixed_time , $
cast_offset = cast_offset , $
ntrail = ntrail , $
raw_time = raw_time , $
last_raw = last_raw , $
silent = silent , $
_extra = _extra
INPUTS:
hdr
ff
OPTIONAL INPUT PARAMETERS:
ut0 = ut0 scalar ; type: float
array[1]; type: time structure
forecast time on which to center the time series
specified as Carrington time or time structure in UT
(passed to vu_insitu)
cast_offset=cast_offset
scalar : type: float; default: 0.0
array[1]; type: time difference structure
fore- or aftcast time relative to the forecast time
(i.e. relative to the time at which the tomography was run)
specified in days or as a time difference structure.
Only used if 'fixed_time' and 'raw_time' are NOT set.
fixed_time=fixed_time
scalar ; type: float
array[1]; type: time structure
Time for which all reconstructed data are requested
(as Carrington time or time structure)
i.e. this picks one point at the same 'fixed_time'
from each tomography run.
raw_time=raw_time scalar ; type: float
array[1]; type: time structure
Forecast time for which to plot time series
(the nearest actual forecast run is used).
/last_raw specified instead of 'raw_time'. Selects the most recent
tomographic run.
ntrail=ntrail scalar; type: integer; default: undefined
use only the highest 'ntrail' marker values.
OUTPUTS:
(plot to screen, printer or image file)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, Carrington, GetFileSpec, InitVar, IsTime, IsType, TimeGet, TimeInterpol
TimeOp, TimeSet, TimeUnit, UNIQ, hide_env, say, vu_get, vu_gettime, vu_insitu, vu_select
where_common
CALLED BY:
forecast
PROCEDURE:
The time axis on the plot is the forecast time stored in the headers
(retrieved with vu_get(hdr, /forecast_time).
MODIFICATION HISTORY:
SEP-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_insitu_type__define
PURPOSE:
Automatic definition of structure for storing image type parameters
CATEGORY:
tool
CALLING SEQUENCE:
PRO vu_insitu_type__define
INPUTS:
(none)
OUTPUTS:
(none)
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL BY:
vu_type_insitu
CALLS: ***
vu_fnc
PROCEDURE:
(called when using expression {vu_insitu_type})
Structure definition:
tmp = {vu_insitu_type, $
data : lonarr(vu_fnc(/count)),$
display : '' , $ ; Type of display; also used in construction of gif file name
prefix : '' , $ ; Prefix for tomography file containing 3D data arrays
ctable : 0 , $ ; Color table
xysize : [0,0] , $
charsize: 0.0 , $
thick : 0.0 , $
label : '' , $ ; Postfix to 'display' used in construction of gif file name
Fmin : 0.0 , $
Fmax : 0.0 , $
format : '' , $ ; Format used by GetColors to turn 'breakval' into strings
breakval: fltarr(255), $ ; Contour levels
delay : !TheTime } ; Time delay for aft-/forcast
[Previous]
[Next]
NAME:
vu_insitucurve
PURPOSE:
Plots time series for tomography and in situ data;
and/or correlation plots of tomography vs. in situ data
CALLING SEQUENCE:
PRO vu_InsituCurve, ttomo, ytomo, tsitu, ysitu, $
data_type = data_type , $
timeseries = timeseries , $
correlation = correlation , $
ut0 = ut0 , $
tx_range = tx_range , $
forecast = forecast , $
fmin = fmin , $
fmax = fmax , $
upto = upto , $
sc_label = sc_label , $
tm_label = tm_label , $
digits = digits , $
_extra = _extra , $
plot_type = plot_type , $
vert_ut = vert_ut , $
nocolors = nocolors , $
silent = silent
INPUTS:
ttomo array[N]; type: time structure
times of available data points for tomographic data
ytomo array[N1,M,K]; type: float
tomographic time series.with 'bad data' indicated by
!values.f_nan. The second dimension (m) identifies the
physical quantity
m=0: density
m=1: velocity
m=2: radial magnetic field component
m=3: tangential magnetic field component
m=4: normal magnetic field component
m=5: bt^2+bn^2
m=6: total field strength
m=7: dynamic pressure
The 3rd dimension identifies multiple sets of tomographic
data (this is currently only used to compare timeseries from
the nv3d files with the ea files).
tsitu array[N2]; type: time structure
times of available data point for in situ data
(always the same as ttomo???)
ysitu array[N2,M]; type: float
spacecraft in situ time series with 'bad data' indicated
by !values.f_nan containing same quantities as ytomo.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar; type: integer or time structure
If absent, then array 'ttomo' defines the timeaxis
If present, 'ttomo' determines the range of the time axis,
but the time axis will be centered on 'ut0'.
If 'ut0' is specified as an integer then it is interpreted
as the difference between local time and UT in hours
tx_range=tx_range
array[2]; float or time structure
defines the range of the time axis. A float array is
interpreted as a time range in days centered on 'ut0'
/forecast only used if keyword 'ut0' is set.
Adds a vertical dashed line at the center of the time
series (marking time 'ut0'), and adds the word 'FORECAST'
to the right of the dashed line.
If 'ut0' is absent then the time series reflects the time range of the
'ttomo' array.
fmin = fmin scalar, array[2]; type: any
scalar is same as [scalar,scalar]
fmax = fmax scalar, array[2]; type: any
scalar is same as [scalar,scalar]
sets minimum and maximum on the two timeseries plotted
Speed/density plots cannot be mixed with magnetic field plots.
/speed select velocity plots
/density select density plots
/bradial select radial component of magnetic field
/btang select tangential component of magnetic field
/bnorm select normal component of magnetic field
/brtmag
/bmag select magnetic field strength
/pdynamic select dynamic (ram) pressure
data_type=data_type
array[n] (n=8 currently); type: integer
array with 0 (data type not plotted) or 1 (data type plotted)
If not specified the array is constructed from the data type
keywords listed above.
If specified it usually is the tag entry with the same name
from the structure defined by vu_type_insitu.
/timeseries plot time series for selected quantities
/correlation plot correlations only
(if both are omitted than time series and correlation are
plotted).
sc_label=sc_label
scalar; type: string
label used to indicate origin of in situ data
(usually this is obtained from Instrument with
the keyword /label set).
tm_label=tm_label
scalar or array; type: string; default: ['corotating', 'time dependent']
labels used for the tomography time series
_extra=_extra IDL graphics keyword passed to plot statement
(charsize, thick, etc.)
OPTIONAL OUTPUT PARAMETERS:
tx_range=tx_range
array[2]; time structure
actual time range used to plot time axis
plot_type=plot_type
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
CORRELATE, Carrington, InitVar, IsTime, IsType, LOADCT, MEAN, PlotCurve, TimeGet
TimeLimits, TimeOp, TimeSet, TimeUnit, TimeXAxis, anicenum, flip_colors, gridgen
lsqNormalFit, vu_fnc
CALLED BY:
dusan_earth, vu_insitu, vu_insitu_persist
PROCEDURE:
The 'tomo' arrays are usually extracted from a tomography output file
The 'insitu' arrays is set up by a call to InsituTimeseries
MODIFICATION HISTORY:
NOV-1999, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS)
Added keyword /forecast (before this was functionality was
included with keyword 'ut0'
AUG-2002, Paul Hick (UCSD/CASS)
Added keyword tx_range. Also modified the calculation of tx_range
if it is not specified.
SEP-2002, Paul Hick (UCSD/CASS)
Renamed PlotCompareInsitu to PlotInsituCurve and revamped.
APR-2004, Paul Hick (UCSD/CASS)
Bug fix (call to TimeAdd instead of TimeOp)
Added keyword digits to pass info to function 'anicenum'.
JUL-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Restructured the plotting of the timeseries to provide better
plots if no tomography data are available. It used to make a
black window; now it plots 'no data'.
Removed keyword noplot.
Removed keywords result_str and result_fit returning info from
correlation between tomographic and in situ timeseries (now done
by vu_correlate).
Renamed PlotInsituCurve to vu_InsituCurve.
NOV-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
The insitu timeseries was ignored unless keyword sc_label was
defined. Now sc_label is set to 'UNKNOWN S/C' if not provided
as input, and the insitu time series is plotted (unless it
only contains NaNs).
[Previous]
[Next]
NAME:
vu_is_sequence
PURPOSE:
Check whether a 'hdr' array refers to a sequence from a time-dependent
tomography run.
CATEGORY:
Tomography
CALLING SEQUENCE:
FUNCTION vu_is_sequence, hdr, silent=silent
INPUTS:
hdr
OPTIONAL INPUTS:
silent=silent scalar; type: integer
0,1,2: suppresses informational messages
OUTPUTS:
Result scalar; type: integer
0: not a sequence
1: is a sequence; returned if hdr is an array with more
than 1 element and all marker values have the same
non-zero value.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, TimeOp, TimeUnit, vu_get
CALLED BY:
vu_elotime, vu_insitu, vu_synopticmap, vu_whatis
PROCEDURE:
If more than one hdr is present, check whether it is from a single time-dependent
tomography run (i.e. whether all markers have the same non-zero value).
MODIFICATION HISTORY:
APR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added check for sorted time sequence. This is now used to identify
a sequence rather than a single marker value for all headers.
[Previous]
[Next]
NAME:
vu_linecut
PURPOSE:
Makes cut along line through tomography output
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_linecut, hdr, ff, ihdr=ihdr, ut0=ut0, $
radius = radius , $
zoffset = zoffset , $
type = type , $
printer = printer , $
silent = silent , $
module = module , $
body = body , $
abg_euler = abg_euler , $
degrees = degrees , $
edge = edge , $
circle = circle , $
textfile = textfile , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data arrays)
then a synoptic map for data at index 'ihdr' is displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
(passed to vu_getdata)
Time (converted to an Earth-based Carrington variable).
If not specified then the time in 'hdr' is used.
If a sequence of files from a time-dependent tomography run is
used, and ihdr is not specified, then the hdr closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
radius=radius
scalar; type: float: default: outer boundary of data sphere
The planarcut covers a square with sides 2*radius with the
Sun in the center.
/circle Shows the planar cut always as a circular area with radius
specified by keyword 'radius'
(For values of radius larger/equal to the radius of the
data sphere, the presence of keyword /circle does not
make a difference).
zoffset=zoffset
scalar; type: float; default: 0.0
distance of plane of the cut to the origin (the Sun)
body=body passed to PlotPlanarCut
abg_euler array[3]; type: float; default: none
See PROCEDURE
textfile scalar; type: string
File name with or without path to write time and values to
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
AngleRange, BadValue, CV_COORD, Carrington, CombineRotations, CvSky, EulerRotate
FILEPATH, InitVar, IsType, PlotCurve, TimeGet, TimeUnit, ToDegrees, boost, destroyvar
flt_read, vu_atlocation, vu_fnc, vu_get, vu_getdata, vu_gettime, vu_type_insitu
PROCEDURE:
The cut plane is along the equator of the selected spherical
coordinate system using one of the from_* keywords
to CvSky. E.g. setting
/from_centered_ecliptic, /heliocentric
will produce a cut along the ecliptic plane with the Earth
on the positive x-axis.
The keyword zoffset is used to displace the cut plane
parallel to the equator.
The Euler angles abg_euler are used to make cuts along
planes other the equator. To set up a user-defined cut,
define a spherical coordinate system with the user-defined
cut plane as equator (i.e., containing x-axis and y-axis
(with z-axis completing a right-handed coordinate system).
The thus-defined x-axis will be pointing to the right in
the plot; the y-xaxis will be up.
Then abg_euler are the Euler angles needed to rotate the
user-defined coordinate system to the selected CvSky
coordinate system.
For meridional cuts perpendicular to the ecliptic with the
Earth on the x-axis use:
/from_centered_ecliptic, /heliocentric, $
abg_euler=[-90,-90,+90], /degrees
The 2nd Euler angle (-90) sets the tilt of the cut plane
relative to the ecliptic. E.g. to make a cut at a 30-deg
tilt with the ecliptic with the west side of the plane
above the ecliptic use -30 deg for the 2nd angle.
The 3rd Euler angle (+90 deg) sets the longitude of the
nodes of the meridianal plane on the ecliptic.
E.g. to make a cut at 30 deg west of the Sun use +120 deg
for the 3rd angle.
MODIFICATION HISTORY:
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_lineofsight
PURPOSE:
CATEGORY:
user/phick/idl
CALLING SEQUENCE:
PRO vu_lineofsight, hdr, ff , $
hdr_bb = hdr_bb , $
bb = bb , $
ut0 = ut0 , $
ihdr = ihdr , $
filter_bb = filter_bb , $
ephemeris = ephemeris , $
RA = RA , $
DEC = DEC , $
nRR = nRR , $
dRR = dRR , $
equator = equator , $
degrees = degrees , $
silent = silent , $
_extra = _extra
INPUTS:
hdr array; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
ra array[n]; ra/ecl long of line(s) of sight
dec array[n]; decl/ecl latitude of line(s) of sight
ephemeris array[2,n]; alternative way of specifying ra,dec
(if used, this overrides ra,dec)
OPTIONAL INPUT PARAMETERS:
ut0=ut0 array[1]; type: time structure
UT time
nrr=nrr scalar; type: integer
nr of segments along line(s) of sight
drr=drr scalar; type: float
stepsize along line(s) of sight (AU)
/degrees if set, indicates that all angles are in degrees. Default: radians.
/equator if set, ra and dec are assumed to be equatorial
coordinates (default is ecliptic long and latitude)
/sw_density solar wind density
/sw_speed solar wind speed
/ips_speed IPS speed
/ips_glevel IPS g-level
/thomson_b Thomson scattering brightness
/thomson_pb Thomson scattering polarization brightness
OUTPUTS:
Print to standard output
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
EXTERNAL:
IPS_hlevel_w, IPS_velocity, IPS_velocity_w, ThomsonBrightness
CALLS: ***
BadValue, EarthSky3DLoc, GetFileSpec, IPS_params, IPS_velocity, InitVar
IntegrateLOS, InterpolateHeliosphere, IsType, RotationMeasure, SetFileSpec
SubArray, SuperArray, ThomsonUBVConst, TimeGet, TimeUnit, ToRadians, say, vu_get
vu_getdata, vu_gettime, vu_prefix, vu_select
CALLED BY:
vu_los
PROCEDURE:
> Several parameters define the grid used to calculate the sky map.
These are passed to EarthSky3DLoc and EarthTransit3DLoc:
nRR scalar; type: int; default: 20
# steps along lines of sight at each point in the sky
dRR scalar; type: float; default: 0.1 AU
step size along line of sight (AU)
MODIFICATION HISTORY:
FEB-2007, Paul Hick (UCSD/CASS)
[Previous]
[Next]
NAME:
vu_localskymap
PURPOSE:
Overplot IPS sources for given day on a 'sky sweep'
map derived from a tomographic reconstruction.
CATEGORY:
Forecast project
CALLING SEQUENCE:
PRO vu_localskymap, hdr, ff, $
ihdr = ihdr , $
ut0 = ut0 , $
dut = dut , $
degrees = degrees , $
_extra = _extra , $
utnoon = UTnoon , $
RA_full = RA_full , $
F_full = F_full , $
track = track , $
solar = solar , $
band = band , $
silent = silent , $
module = module , $
sourcesdir = sourcesdir, $
ooty = ooty , $
nagoya = nagoya , $
use_good_sources = use_good_sources
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer
identifies the header to be used if hdr is an array with
more than one element
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from the 'hdr' argument is
used. See Carrington for more details.
/degrees if set then all angles are in degrees (default: radians)
/track if set sources within +/-12 hours of ut0 (/solar NOT set) or
24 hours preceding ut0 (/solar set) are plotted.
if NOT set sources within +/-12 hours of noon of previous noon
(/solar NOT set) or 24 hours preceding previous noon
(/solar set) are plotted.
/solar
band=band scalar; type: any; default: none
strip
Additional keywords can be passed to vu_getdata and
vu_earthskymap. The most important ones are:
maxelo scalar; type: float
controls type of map: Hammer-Aitoff, fish-eye or Mercator
map
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along
the ecliptic
sourcesdir=sourcesdir
scalar; type: string
passed to getnagoyasources
OUTPUTS:
utnoon=utnoon
array[1]; type: time structure
UT for local noon at Nagoya or Ooty
for which the sky sweep is made.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, GETOOTYSOURCES, GeographicInfo, InitVar, IsTime, IsType, TimeGet, TimeOp
TimeSet, TimeUnit, getnagoyasources, say, vu_earthskymap, vu_getdata
CALLED BY:
forecast, vu_movie
PROCEDURE:
The skymap is built from strips along the local meridian
at Nagoya or Ooty, centered on the last noon preceeding
the input time T for which IPS data are available.
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_los
CALLING SEQUENCE:
PRO vu_los
INCLUDE:
@compile_opt.pro
CALLS: ***
AngleUnits, CvPrecess, FILEPATH, TimeSet, vu_lineofsight
PROCEDURE:
Source co-ordinates (J2000.0) for PSR J1022+1001 are:
RA (hh:mm:ss.sss): 10:22:58.011
Dec (dd:mm:ss.ss): +10:01:52.85
UT 13 August 2014 at ~13 UT.
[Previous]
[Next]
NAME:
vu_losmap
PURPOSE:
Plots lines of sight stored in v_los.txt or g_los.txt output
from tomography programs.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_losmap, ff, $
carrington_nr = carrington_nr , $
xrange = xrange , $
timenr = timenr , $
losnrs = losnrs , $
all = all , $
_extra = _extra
INPUTS:
ff scalar; type: string
fully-qualified name of file with los info
(typically v_los.txt or g_los.txt)
OPTIONAL INPUT PARAMETERS:
/carrington_nr if set, plot Carrington rotation number on x-axis
xrange=xrange array[2]; type: float
controls range of x-axis (this is passed
directly to the IDL plot function).
Note that to get Carrington variable increasing
left to right xrange[0] must be larger than xrange[1]
timenr=timenr array; type: integer
list of times to be plotted
(selected from 3rd column of input file)
losnrs=losnrs array; type: integer
list of lines of sight to be plotted
(selected from 1st column in input file)
OUTPUTS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, FILEPATH, InitVar, IsType, PlotCurve, UNIQ, flt_read, where_common
PROCEDURE:
The format of the los text file is:
los nr seg nr time nr cr var lat
2 40 4 2055.9404297 9.0538921
If /carrington_nr NOT set then the heliographic longitude
is used for the x-axis. All Carrington variables will be
mapped back into the range [0,360], i.e. a single rotation
is plotted with longitude running from [0,360].
If /carrington_nr is SET then the Carrington variable (4th
column in input file) is used as x-axis. Since the range
of Carrington variables will generally not be an integer
number of Carrington rotations, the keyword xrange is
usually needed to get the x-axis to look good.
MODIFICATION HISTORY:
DEC-2008, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_mean
PURPOSE:
Calculate a weighted average of a set of tomography arrays
CATEGORY:
Tomography
CALLING SEQUENCE:
FUNCTION vu_mean, hdr, ff, weights, tt_weight=tt_weight, userinfo=userinfo, $
hdr_index=hdr_index, last_hdr=last_hdr, marker=marker, ff_mean=ff_mean, $
setbad=setbad, nowrap=nowrap, silent=silent
INPUTS:
hdr array[n]; type: structure
header information for all data arrays
ff array[nLng,nLat,nRad,2,n]
3D data arrays (velocity and density, or magnetic field components)
weights array[n]; type: float
weights to be applied to data arrays
tt_weight=tt_weight
array[1]; type: float or time structure
time at which mean array is required.
This time is used to calculated the Carrington range and
range of interest of the mean array by interpolating on the
the input values in argument 'hdr'.
OPTIONAL INPUT PARAMETERS:
hdr_index=hdr_index
scalar; type: integer; default: 0
0 <= hdr_index <= n-1; identifies element in 'hdr' on which to base
the header for the mean data
/last_hdr if set, the hdr_index = n-1 is used
/marker ???? maybe useful when processing files for same times from different
tomography run (the marker values are written into 'userinfo'
setbad=setbad scalar; type: integer
if set, then bad values in the matrix nearest to tt_weight
are also flagged bad in the output matrix.
/nowrap passed to AlignHeliosphere
OUTPUTS:
ret_hdr array[1]; type: structure
header information for returned mean data. The header is based
on one of the headers in the input 'hdr' array (determined by
keywords hdr_index and last_hdr) with some fields updated
(see PROCEDURE).
ff_mean=ff_mean array[nLng,nLat,nRad,2]; type: float
weighted mean data
if n=1 then the input data are returned unmodified
OPTIONAL OUTPUT PARAMETERS:
userinfo=userinfo array[2]; type: string
contains some descriptive information about the averaging
process (times of original files and weight factors).
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
AlignHeliosphere, BadValue, Carrington, InitVar, IsType, SuperArray, TimeGet
TimeInterpol, TimeOp, TimeUnit, UNIQ, say, vu_get, vu_set
CALLED BY:
vu_gettime, vu_new_time, vu_update_marker
RESTRICTIONS:
The input data need to be arranged chronologically, i.e.
the hdr.time array needs to be monotic (if vu_select and vu_read are
used to set up the input 'hdr' and 'ff' arrays this condition is satisfied).
PROCEDURE:
> The Carrington range and region of interest for the mean array is calculated by
linear interpolation on time on the input values in the 'hdr' array.
> The arrays to be combined may refer to different ranges of Carrington variables
(i.e. with different hdr.array and hdr.roi values). Before calculating the weighted
mean array a linear interpolation in the longitudinal dimension is used to put all
arrays on the grid needed for the mean array (this is done by AlignHeliosphere).
> The return header 'ret_hdr' is based on one of the headers in the input 'hdr' array
(the first one unless /last_hdr or hdr_index is set). The following fields are updated:
ret_hdr.time set to tt_weight
ret_hdr.array obtained by linear interpolation on hdr.array vs. hdr.time at time tt_weight
ret_hdr.roi obtained by linear interpolation on hdr.roi vs. hdr.time at time tt_weight
ret_hdr.file set to blank string (vu_write creates a file name based on hdr_time)
ret_hdr.time_forecast set to tt_weight
ret_hdr.time_start set to tt_weight
ret_hdr.marker if all hdr.marker values are the same that value is retained;
otherwise set to zero (vu_write appends a non-zero ret_hdr.marker
value to the file name)
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS)
Modified error procedure to avoid divide by zero
The forecast time in the return header is now also set to tt_weight
NOV-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added /nowrap keyword
[Previous]
[Next]
NAME:
vu_movie
PURPOSE:
Create animations from final (averaged) tomography files
CATEGORY:
smei/sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_movie, ut, map_type , $
ut_extra = ut_extra , $
path = path , $
filter = filter , $
highmark = highmark , $
movie_destination=movie_destination,$
image_destination=image_destination,$
hdr = hdr , $
ff = ff , $
movie_file = movie_file , $
delay = delay , $
png = png , $
gif = gif , $
mpeg = mpeg , $
fillsky = fillsky , $
skip = skip , $
type = type , $
roi_offset = roi_offset , $
ut_off = ut_off , $
silent = silent , $
nv_filter = nv_filter , $
nv_hdr = nv_hdr , $
nv_ff = nv_ff , $
source = source , $
_extra = _extra
INPUTS:
ut array[2]; type: float or time structure
range of times for which movie is required.
Times can be specified as Carrington variables or in UT
map_type scalar; type: character
Any one of 'synoptic', 'earth_skysnap', 'earth_skysweep',
'earth_insitu'
OPTIONAL INPUT PARAMETERS:
hdr = hdr array[k]; type: structure
headers of tomography files used to make individual images
ff = ff array[n,l,m,2,k]; type: float
3d heliospheric arrays used
These arrays are either density/velocity or magnetic field data.
If these do not exist on entry then files are selected and read, and
output in these keywords (see OUTPUT PARAMETERS). Altnernatively, these
arrays are passed from a previous call, bypassing the read section here.
This saves a lot of time.
nv_hdr = nv_hdr
array[k]; type: structure
headers of tomography files (density/velocity)
nv_ff = nv_ff
array[n,l,m,2,k]; type: float
3d heliospheric arrays (density/velocity)
These arrays should only be specified if hdr,ff contain magnetic data.
They should contain the density/velocity data matching the magnetic data,
and will be used only to make a density/velocity remoteview movie, with the
current sheet embedded in it.
If nv_hdr is not defined on entry, and nv_filter is set then an attempt
is made to locate the density/velocity data matching the hdr,ff data.
path=path scalar; type: string; default: $dat/nagoya/slow/final
directory in which to search for files
filter=filter
scalar; type: string; default: nv3d*.*
file filter (including wildcard) used to search for files
nv_filter=nv_filter
scalar; type: string; default: nv3d*.*
file filter (including wildcard) used to search for
density/velocity files
movie_destination=movie_destination
scalar; type: string; default: $TUB
destination directory for animations
If the directory doesn't exist then the animation is
written to $TUB
image_destination=image_destination
scalar; type: string; default: none
destination directory for individual frames
By default the individual frames are deleted.
If image_destination is set to an existing directory then
the individual frames are saved in this directory.
/mpeg by default an animated png is created; if /mpeg or /gif is set
then an mpeg movie (NOT YET IMPLEMENTED) or animated gif
/gif (REQUIRES CAPABILITY TO WRITE GIFS) is made.
_extra=_extra
OUTPUTS:
(animation, and optionally the individual frames)
OPTIONAL OUTPUT PARAMETERS:
hdr = hdr array[k]; type: structure
headers of tomography files used to make individual images
ff = ff array[n,l,m,2,k]; type: float
3d heliospheric arrays used
nv_hdr = nv_hdr
array[k]; type: structure
headers of tomography files (density/velocity)
nv_ff = nv_ff
array[n,l,m,2,k]; type: float
3d heliospheric arrays (density/velocity)
Will only be filled if nv_hdr does not exist on entry, and nv_filter is set.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, CheckDir, FILEPATH, GetFileSpec, InitVar, Instrument, IsTime, IsType
SetFileSpec, TimeGet, TimeOp, TimeSet, TimeUnit, UNIQ, big_body, boost, destroyvar
do_file, gridgen, jpl_body, mk_flick, say, vu_earthskymap, vu_get, vu_insitu
vu_localskymap, vu_planarcut, vu_remoteview, vu_select, vu_solardisk
vu_synopticmap, vu_type_insitu, vu_type_skymap
CALLED BY:
forecast_movie
PROCEDURE:
> The returned 'hdr' and 'ff' arrays can be passed to a subsequent call to
make another movie from the same data. This bypasses the time-consuming
reading of the same set of files.
> All nv3d files in the source directory 'path' fitting the 'filter' wildcard
within the time range 'ut' are processed. Image are created at the time
of each file.
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
JUL-2003, Paul Hick (UCSD/CASS)
Adapted to make movies of remoteviews with hcs embedded
JUL-2004, Paul Hick (UCSD/CASS)
Improved handling of individual frames for movies.
SEP-2007, Paul Hick (UCSD/CASS)
Added Stereo A and Stereo B
NOV-2011, John Clover (UCSD/CASS)
Modified to handle interpolation of magnetic field data
MAR-2013, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added keyword source to be able to override the default choice (ACE)
based on type.label
[Previous]
[Next]
NAME:
vu_nagoyasourcemap
PURPOSE:
Overplot IPS sources for given day on a sky map derived from a
tomographic reconstruction.
CATEGORY:
IPS forecast: WWW
CALLING SEQUENCE:
PRO vu_nagoyasourcemap, $
ut0 = ut0 , $
degrees = degrees , $
_extra = _extra , $
utnoon = utnoon , $
point_sources = point_sources , $
geolng = geolng , $
nosweep = nosweep , $
silent = silent
INPUTS:
ut0=ut0 array[1]; type: time structure
Defines the time (UT) for the skymap
A scalar is interpreted as the difference between local
time and UT, and is used to get a UT from the system time.
If absent then T = 8 is assumed (offset PST and UT)
OPTIONAL INPUT PARAMETERS:
geolng=geolng scalar; type: float
geographic longitude of Nagoya.
point_sources=point_sources
array; type: ips_point_source structure
Both arguments are calculated internally if not specified
/degrees if set then all angles are in degrees (default: radians)
/ips_speed if set, plot IPS speed values
/ips_glevel if set, plot IPS g-level values
maxelo scalar; type: float
if set and non-zero then a fish-eye map is plotted out to
elongation 'maxelo'. By default a Hammer-Aitoff map is drawn
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along the ecliptic
/names if set, then the names of the point sources are plotted
OPTIONAL OUTPUT PARAMETERS:
UTnoon array; type: time structure
UT for previous time when Sun crossed local
meridian (i.e. local noon)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, GeographicInfo, InitVar, IsType, TimeGet, TimeOp, TimeSet, destroyvar
getnagoyasources, say, vu_earthskymap
CALLED BY:
qnagoya_skymap
PROCEDURE:
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_new_time
PURPOSE:
Create or update averaged tomography files from original 'raw' files
CATEGORY:
Tomography: I/O
CALLING SEQUENCE:
PRO vu_new_time, ut, $
path = path , $
filter = filter , $
destination = destination , $
ff = ff , $
update = update , $
triangle = triangle , $
nofuture = nofuture , $
setbad = setbad , $
count = count , $
silent = silent , $
rounds = rounds , $
gzip = gzip
INPUTS:
ut array[*]; type: time structure
/update NOT set: times for which new averaged files are
to be calculated; should be in chronological order.
if /update set: only ut[0] is used and usually refers to
the time of the last tomography run (i.e. the time of
the last 'raw' file available. All files in 'destination'
which are affected by this raw file are updated.
OPTIONAL INPUT PARAMETERS:
path=path scalar; type: string
directory where to search for 'raw' files to be used
to calculate the new averaged file
(passed to vu_select)
filter=filter scalar; type: string
file name filter for 'raw' files (incl. wildcard)
(passed to vu_select)
destination=destination
scalar; type string
destination directory of the new averaged file
if not specified, then no output file is written.
update_fast=update_fast
if set then files in 'destination' are updated
triangle=triangle
array[4]; type: float; default: [ [4,-(7+4),7-4]/!sun.synodicp, 1.0 ]
defines the range of time which affects the averaging
near a given time, i.e. files with times inside this range
will be given a non-zero weight in the averaging process.
(see vu_weight).
/nofuture if set, the average is calculated from files with times earlier than
the specified time.
/setbad passed to vu_weight
silent=silent suppresses messages from vu_read and vu_write
OUTPUTS:
ff
OPTIONAL OUTPUT PARAMETERS:
count=count scalar; type: integer
if /update NOT set: # times in 'ut' for which new averaged files
were created
if /update set: # times around ut[0] for which averaged files
were found and updated.
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, InitVar, IsBadTime, IsType, TimeGet, TimeOp, TimeSet, TimeUnit, say, vu_get
vu_mean, vu_select, vu_set, vu_weight, vu_write, where_common
CALLED BY:
vu_update_hours
PROCEDURE:
> vu_select is called with keyword /nohdr set, i.e. file names
are returned without actually reading the headers.
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
AUG-2002, Paul Hick (UCSD/CASS)
Added /allow_nrad_changes to vu_select call
NOV-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added /gzip keyword
[Previous]
[Next]
NAME:
vu_planarcut
PURPOSE:
Makes planar cut through tomography output
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_planarcut, hdr, ff, ihdr=ihdr, ut0=ut0, $
radius = radius , $
zoffset = zoffset , $
type = type , $
printer = printer , $
silent = silent , $
module = module , $
body = body , $
abg_euler = abg_euler , $
degrees = degrees , $
edge = edge , $
circle = circle , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data arrays)
then a synoptic map for data at index 'ihdr' is displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
(passed to vu_getdata)
Time (converted to an Earth-based Carrington variable).
If not specified then the time in 'hdr' is used.
If a sequence of files from a time-dependent tomography run is
used, and ihdr is not specified, then the hdr closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
radius=radius
scalar; type: float: default: outer boundary of data sphere
The planarcut covers a square with sides 2*radius with the
Sun in the center.
/circle Shows the planar cut always as a circular area with radius
specified by keyword 'radius'
(For values of radius larger/equal to the radius of the
data sphere, the presence of keyword /circle does not
make a difference).
zoffset=zoffset
scalar; type: float; default: 0.0
distance of plane of the cut to the origin (the Sun)
body=body passed to PlotPlanarCut
abg_euler array[3]; type: float; default: none
See PROCEDURE
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
AngleRange, BadValue, CV_COORD, Carrington, CombineRotations, CvSky, EulerRotate
FILEPATH, InitVar, IsType, PlotPlanarCut, TimeGet, TimeUnit, ToDegrees, boost
destroyvar, flt_read, gridgen, say, set_page, vu_atlocation, vu_fnc, vu_get, vu_get_page
vu_getdata, vu_gettime, vu_type_insitu
CALLED BY:
forecast, vu_movie
PROCEDURE:
The cut plane is along the equator of the selected spherical
coordinate system using one of the from_* keywords
to CvSky. E.g. setting
/from_centered_ecliptic, /heliocentric
will produce a cut along the ecliptic plane with the Earth
on the positive x-axis.
The keyword zoffset is used to displace the cut plane
parallel to the equator.
The Euler angles abg_euler are used to make cuts along
planes other the equator. To set up a user-defined cut,
define a spherical coordinate system with the user-defined
cut plane as equator (i.e., containing x-axis and y-axis
(with z-axis completing a right-handed coordinate system).
The thus-defined x-axis will be pointing to the right in
the plot; the y-xaxis will be up.
Then abg_euler are the Euler angles needed to rotate the
user-defined coordinate system to the selected CvSky
coordinate system.
For meridional cuts perpendicular to the ecliptic with the
Earth on the x-axis use:
/from_centered_ecliptic, /heliocentric, $
abg_euler=[-90,-90,+90], /degrees
The 2nd Euler angle (-90) sets the tilt of the cut plane
relative to the ecliptic. E.g. to make a cut at a 30-deg
tilt with the ecliptic with the west side of the plane
above the ecliptic use -30 deg for the 2nd angle.
The 3rd Euler angle (+90 deg) sets the longitude of the
nodes of the meridianal plane on the ecliptic.
E.g. to make a cut at 30 deg west of the Sun use +120 deg
for the 3rd angle.
MODIFICATION HISTORY:
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_point_source
PURPOSE:
Manipulates structure used for plotting of point sources.
CATEGORY:
/sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_point_source, point_sources, update, $
elongation = elongation , $
name = name , $
time = time , $
location = location , $
ips_speed = ips_speed , $
ips_glevel = ips_glevel , $
brightness = brightness , $
pb = pb , $
field = field , $
size_base = size_base , $
size_ratio = size_ratio , $
xy_pixel = xy_pixel , $
degrees = degrees , $
create = create
INPUTS:
pnt array; type: sky_point_source structure
OPTIONAL INPUT PARAMETERS:
update if it exists, used to update a field in the input
structure (as indicated by appropriate keyword)
create=create
scalar; type: integer
only used if 'update' exists. Creates a new structure
of 'create' elements (destroying the input 'pnt' structure).
/degrees if set then all angles are in degrees, instead of radians
/name return or set name of source
/time return or set time of observation
/location return or set locatione of source in sky as RA,dec
/ips_speed return or set IPS speed
/ips_glevel return or set IPS g-level
/brightness return or set Thomson scattering brightness
/pb return or set pB
/size_ratio if set in combination with /ips_speed, /ips_glevel, /brightness
or /pb, then the increase of the circle size per data unit
is returned. In PlotEarthSkymap [1] this is used to increase
the circle size for larger differences between point source
and background map.
/size_base return or set the base size (minimum size) of circle used
for plotting point sources
field=field scalar; type: integer
return or set the indicated field in the 'pnt' structure
This overrides any of the above keywords.
OUTPUTS:
Result if the input 'update' argument does NOT exist, then
a field from the 'pnt' structure (or a quantity
derived from one or more fields) as indicated by
keyword settings, is returned
if the input 'update' argument DOES exist, then
the modified structure is returned
OPTIONAL OUTPUT PARAMETERS:
INCLUDE:
@compile_opt.pro ; On error, return to caller.
EXTERNAL:
sky_point_source__define
CALLS: ***
CvSky, InitVar, IsType, ToDegrees, big_eph, jpl_body, sphere_distance
CALLED BY:
GetColors [2], GetColors [3], PlotCoronagraph, PlotEarthSkymap [1]
PlotEarthSkymap [2], PlotEarthSkymap [3], PlotEarthSkymap [4], PlotPolarSkymap
getipssources, getnagoyasources, getootyasources, getsmeisources, vu_coronagraph
vu_earthskymap, vu_elotime, vu_thomson_antifish, vu_thomson_hammer
PROCEDURE:
Mostly intended to hide the exact structure of the point source
structure from users.
MODIFICATION HISTORY:
SEP-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_point_source__define
PURPOSE:
Automatic definition of structure for storing parameters
for Nagoya IPS observations
CATEGORY:
tomography
CALLING SEQUENCE:
PRO vu_point_source__define
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL BY:
qnagoya
PROCEDURE:
Called automatically when when using expression {vu_point_source}
Should be used only by vu_point_source (which also takes
care of the initialization of some of the fields).
All angles are stored in the structure in degrees. vu_point_source
takes care of the conversion to radians/degrees using the
usual keyword /degrees.
MODIFICATION HISTORY:
JAN-2001, Paul Hick (UCSD/CASS)
SEP-2004, Paul Hick (UCSD/CASS)
Renamed from ips_point_source. Added fields for Thomson
scattering brightness, pB and circle sizes
tmp = { vu_point_source,$
name: 'name', $ ; Name of source
pp : fltarr(2), $ ; RA and declination
tt : !TheTime, $ ; Time of observation
gg : 0.0, $ ; IPS g-level
vv : 0.0, $ ; IPS speed
bb : 0.0, $ ; Thomson scattering brightness
pb : 0.0, $ ; Polarization brightness
sz : 0.0, $ ; Base (minimum) circle size
szgg: 0.0, $ ; Circle size increase per unit of g-level
szvv: 0.0, $ ; Circle size increase per km/s
szbb: 0.0, $ ; Circle size increase per S10
szpb: 0.0, $ ; Circle size increase per S10
xy : lonarr(2) }
[Previous]
[Next]
NAME:
vu_prefix
PURPOSE:
Get file name prefix to be used for locating output files
from the tomography.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_prefix, prefix, $
magnetic = magnetic , $
fast = fast , $
silent = silent , $
error = error
OPTIONAL INPUT PARAMETERS:
/magnetic if not set then the filter for the plasma
data is returned (see PROCEDURE).
if set then the filter for magnetic data
is returned (see PROCEDURE).
/fast if set then the filter for time-dependent
tomography is returned.
if not set then env var $fast is checked
if not set and env var $fast is not defined
then the filter for corotating tomography
is returned.
silent=silent
OUTPUTS:
OPTIONAL OUTPUT PARAMETERS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, say
CALLED BY:
forecast, forecast_movie, run_map, run_marker, run_mean, run_movie, vox_update
vu_coronagraph, vu_earthskymap, vu_filename, vu_insitu, vu_lineofsight
vu_remoteview, vu_select, vu_type_insitu, vu_type_skymap, vu_update_hours
vu_update_marker, vu_vox_write
PROCEDURE:
If /magnetic NOT set:
- first check env var $NV_PREFIX
- if it doesn't exist, check for env var $NV_PREFIX_'kind'
where 'kind' = 'slow' or 'fast' (depending on setting of /fast)
- if neither env var exists use the default 'nv3d' if /fast NOT set,
or 'nv3f' if /fast SET.
If /magnetic SET:
- first check env var $BB_PREFIX
- if it doesn't exist, check for env var $BB_PREFIX_'kind'
where 'kind' = 'slow' or 'fast' (depending on setting of /fast)
- if neither env var exists use the default 'wson'.
MODIFICATION HISTORY:
AUG-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_quick_movie
PURPOSE:
Create animated gifs from final (averaged) tomography files
CATEGORY:
Tomography
CALLING SEQUENCE:
PRO vu_quick_movie, ut, path=path, movie_dir=movie_dir, movie_file=movie_file, delay=delay, silent=silent
INPUTS:
ut array[2]; type: float or time structure
range of times for which movie is required.
Times can be specified as Carrington variables or in UT
map_type
scalar; type: character
Any one of 'synoptic', 'earth_skysnap', 'earth_skysweep',
'earth_insitu'
OPTIONAL INPUT PARAMETERS:
path=path
scalar; type: string; default: $dat/nagoya/slow/final
directory in which to search for files
filter=filter
scalar; type: string; default: nv3d*.*
file filter (including wildcard) used to search for files
movie_dir=movie_dir
scalar; type: string; default: $TUB
destination directory for animated gif.
If the directory doesn't exist then the animated gif is written to $TUB
gif_dir=gif_dir
scalar; type: string; default: $TUB
destination directory for individual gifs
By default the individual gifs are deleted. If gif_dir is set to an
existing directory then the individual gifs are saved in this directory.
/mpeg by default an animated gif is created; if /mpeg is set then an mpeg movie is
made (NOT YET IMPLEMENTED)
_extra=_extra
OUTPUTS:
(animated gif, and optionally the individual gifs)
OPTIONAL OUTPUT PARAMETERS:
hdr = hdr
array[k]; type: structure
headers of tomography files used to make individual images
ff = ff
array[n,l,m,2,k]; type: float
3d heliospheric arrays used
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, CheckDir, FILEPATH, GetFileSpec, InitVar, IsType, SetFileSpec, do_file
flt_string, mk_flick, say, vu_get
PROCEDURE:
> The returned 'hdr' and 'ff' arrays can be passed to a subsequent call to
make another movie from the same data. This bypasses the time-consuming
reading of the same set of files.
> All t3d files in the source directory 'path' fitting the 'filter' wildcard
within the time range 'ut' are processed. Image are created at the time
of each file.
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_radialcut
PURPOSE:
Makes cut along raidal line through tomography output
from Sun to the position of any of bodies supported by the
ephemeris program big_eph.
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_radialcut, hdr, ff, ihdr=ihdr, ut0=ut0, $
radius = radius , $
type = type , $
printer = printer , $
silent = silent , $
module = module , $
body = body , $
degrees = degrees , $
textfile = textfile , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data arrays)
then a synoptic map for data at index 'ihdr' is displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
(passed to vu_getdata)
Time (converted to an Earth-based Carrington variable).
If not specified then the time in 'hdr' is used.
If a sequence of files from a time-dependent tomography run is
used, and ihdr is not specified, then the hdr closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
radius=radius
scalar; type: float: default: outer boundary of data sphere
The planarcut covers a square with sides 2*radius with the
Sun in the center.
/circle Shows the planar cut always as a circular area with radius
specified by keyword 'radius'
(For values of radius larger/equal to the radius of the
data sphere, the presence of keyword /circle does not
make a difference).
zoffset=zoffset
scalar; type: float; default: 0.0
distance of plane of the cut to the origin (the Sun)
body=body passed to PlotPlanarCut
abg_euler array[3]; type: float; default: none
See PROCEDURE
textfile scalar; type: string
File name with or without path to write time and values to
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
Carrington, InitVar, IsType, PlotCurve, SuperArray, TimeGet, TimeUnit, big_eph, boost
destroyvar, say, vu_atlocation, vu_fnc, vu_get, vu_getdata, vu_gettime, vu_type_insitu
PROCEDURE:
The cut plane is along the equator of the selected spherical
coordinate system using one of the from_* keywords
to CvSky. E.g. setting
/from_centered_ecliptic, /heliocentric
will produce a cut along the ecliptic plane with the Earth
on the positive x-axis.
The keyword zoffset is used to displace the cut plane
parallel to the equator.
The Euler angles abg_euler are used to make cuts along
planes other the equator. To set up a user-defined cut,
define a spherical coordinate system with the user-defined
cut plane as equator (i.e., containing x-axis and y-axis
(with z-axis completing a right-handed coordinate system).
The thus-defined x-axis will be pointing to the right in
the plot; the y-xaxis will be up.
Then abg_euler are the Euler angles needed to rotate the
user-defined coordinate system to the selected CvSky
coordinate system.
For meridional cuts perpendicular to the ecliptic with the
Earth on the x-axis use:
/from_centered_ecliptic, /heliocentric, $
abg_euler=[-90,-90,+90], /degrees
The 2nd Euler angle (-90) sets the tilt of the cut plane
relative to the ecliptic. E.g. to make a cut at a 30-deg
tilt with the ecliptic with the west side of the plane
above the ecliptic use -30 deg for the 2nd angle.
The 3rd Euler angle (+90 deg) sets the longitude of the
nodes of the meridianal plane on the ecliptic.
E.g. to make a cut at 30 deg west of the Sun use +120 deg
for the 3rd angle.
MODIFICATION HISTORY:
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_read
PURPOSE:
Read output file from tomography
CATEGORY:
I/O
CALLING SEQUENCE:
FUNCTION vu_read, hdr, $
nobad = nobad , $
get_roi = get_roi , $
get_full= get_full , $
fss = fss , $
shfts = shfts , $
losxs = losxs , $
silent = silent , $
count = count , $
roi_offset=roi_offset
INPUTS:
hdr array; type: structure
information extracted from file headers
OPTIONAL INPUTS:
/nobad by default 'bad' values are replaced by !values.f_nan.
The 'bad value' indicator is read from the file header, or,
if not found in the header is assumed to be -9999.9990
Set /nobad to suppress this 'bad value' replacement
/get_full extract full array (not just region of interest)
/get_roi extract region of interest only (this is the default)
roi_offset=roi_offset
scalar; type: float: default: 0.0
offset to be added to the region of interest specified in the
header (not used if /get_full is set)
OUTPUTS:
Result array[*,*,*,2 or 3,*; type: float
3D matrix (invalid values marked by large negative value)
Either velocity/density or radial/azimuthal magnetic field.
First three dims are longitude, latitude and radial distance.
4th dimension is 2 (velocity/density or Br/Bt) or 3 (Br/Bt/Bn).
5th dimension is usually time (=count)
OPTIONAL OUTPUT PARAMETERS:
count scalar; type: integer
# files read; this will be either 0 of the number of valid
nv3d* or wson* files. If there is a read error on the first of
these files then count=0 is returned and none of the output
arrays will exist. If it happens for the second or later file
then its slot in the output arrays is filled with bad values.
silent=silent
if set, informational messages are suppressed
The following arrays may not be present in the file:
fss=fss array[*,*,2]; type: float
source surface maps
shfts=shfts
array[*,*,*]; type: float
3D shift matrix (shft[*,*,0]=0)
losxs=losxs
array[*,*,2]; type: float
# line of sight crossings at source surface
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
BadValue, InitVar, IsType, SuperArray, TimeGet, WhatIs, boost, destroyvar, flt_read
hide_env, say, vu_get, vu_set
CALLED BY:
SkyForecast, ipsv [1], ipsv [2], ipsv [3], qRemoteView_Pick, test_sky, test_td
vu_getdata, vu_select
PROCEDURE:
> The files are read using procedure flt_read. If there is a read error
then the value zero is returned.
> The shift array is assumed to be stored at the end of the file
MODIFICATION HISTORY:
AUG-1999, Paul Hick (UCSD/CASS)
MAR-2001, Paul Hick (UCSD/CASS)
rewrite to deal with new headers of tomography files
NOV-2001, Paul Hick (UCSD/CASS)
added keyword roi_offset to adjust the region of interest
specified in the header.
AUG-2002, Paul Hick (UCSD/CASS)
modification to allow for reading of files with different
number of radial distances. The lowest number of distances
is read from each file.
JUN-2003, Paul Hick (UCSD/CASS)
Fixed bug which prevented reading of source surface map fss correctly.
NOV-2003, Paul Hick (UCSD/CASS)
Fixed bug in determining indices for ROI. If the ROI edges fell exactly
halfway two gridpoints, one edge would sometimes be rounded up, the
other rounded down.
NOV-2003, Paul Hick (UCSD/CASS)
Modified handling of read errors. If the error occurs on the first file
then nothing is returned; if it happens for a later file its slot
in the output arrays is filled with bad values.
OCT-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
For magnetic data the third component is added as zeroes if it
is absent. The radial (1st) and tangential (2nd) component are always
present. The normal (3rd) component is not (yet) present in the
magnetic files.
[Previous]
[Next]
NAME:
vu_remoteview
PURPOSE:
Reads tomography files for processing in RemoteView
CATEGORY:
Volume rendering
CALLING SEQUENCE:
PRO vu_remoteview, hdr, ff, $
ut0 = ut0 , $
ihdr = ihdr , $
degrees = degrees , $
type_ff = type_ff , $
volsize = volsize , $
images = images , $
meshhcs = MeshHCS , $
mergehcs= MergeHCS , $
nearest = nearest , $
hdr_bb = hdr_bb , $
bb = bb , $
filter_bb=filter_bb , $
type_bb = type_bb , $
location=location , $
upto = upto , $
silent = silent , $
_extra = _extra , $
module = module
INPUTS:
hdr array[k]; type: header structure
ff array[n,l,m,2,k]; data arrays associated with 'hdr' array
(for k=1 the last dimension may be absent). If not
specified, then data will be read using vu_getdata.
OPTIONAL INPUT PARAMETERS:
ihdr = ihdr scalar; type: integer
ut0 = ut0 scalar; type: float
array[1]; type: time structure
keyywords are passed to vu_getdata
type_ff = type_ff
array[1]; type: structure
This structure is passed to vu_type_insitu,
and is used to initialize some of the entries in its
return structure. See vu_type_insitu.
volsize = volsize
scalar, or array[2]; type: float
inner and outer limit on radial distance displayed in
the volume rendering. A scalar specifies only the outer
limit (with the inner limit assumed to be zero).
If not specified then the full range (extracted from the
headers) is used. The values will be rounded to the
nearest grid distances inside the specified range.
/degrees if set, all angles are in degrees (default: radians)
/meshhcs if set, the heliospheric current sheet is added to the
display. This requires magnetic field data, either
read from file or specified through keyword 'bb'.
/mergehcs if set, the heliospheric current sheet is added to the
display. This requires magnetic field data, either
read from file or specified through keyword 'bb'.
/nearest ???
bb = bb array[n,l,m,2,kk]; type: float
(for kk=1 the last dimension may be absent)
If kk=1 the same magnetic field matrix is used for
k volume matrices.
destination=destination
directory where to write a gif file of the display
(passed to vu_get_page; useful only when processing
single view).
/png save image as png file
/gif save image as gif file (this is the default)
location=location
array[3,k]; type: float
viewing locations associated with each of the
k data arrays.
Keywords passed to RemoteView are explained there.
upto = upto passed to remoteview and vu_get_page
OUTPUTS:
hdr array[k]; type: header structure
ff array[n,l,m,2,k]; data arrays associated with 'hdr' array
(for k=1 the last dimension may be absent)
Data read using vu_getdata.
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
bb = bb array[n,l,m,2,kk]; type: float
(for kk=1 the last dimension may be absent)
Magnetic field data read from file.
type_ff = type_ff
array[1]; type: structure
vu_type_insitu structure used in the display
volsize = volsize
array[2]; type: float
actual inner and outer limit on radial distance
displayed in the volume rendering.
images = images
array[k]; type: string
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
AngleRange, Carrington, GetFileSpec, InitVar, IsType, RemoteView, SetFileSpec, TimeGet
TimeInterpol, TimeUnit, ToRadians, destroyvar, say, vu_fnc, vu_get, vu_get_page
vu_getdata, vu_gettime, vu_prefix, vu_select, vu_type_insitu
CALLED BY:
forecast, vu_movie, vu_stereoview
EXAMPLE:
vu_remoteview, file=filepath(root=getenv('DAT'),subdir='tomography', $
'nv3d1653.5000'), full_range=[5,40.0], /density, $
full_color=[125,225], full_opa=[0,0.5], ngrid=91, cme=[2,!pi,0], $
view_time=Carrington(1653.5d0)
PROCEDURE:
full_color = [125,225]
full_opa = [0,.5]
full_range = [5.0,40.0]
ngrid = 91
MODIFICATION HISTORY:
APR-2001, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_select
PURPOSE:
Find selection of tomography files (nv3d* or wson*)
CALLING SEQUENCE:
FUNCTION vu_select, files , $
files_ = files_ , $
path = path , $
filter = filter , $
pick = pick , $
marker = marker , $
highmark = highmark , $
one_mark = one_mark , $
check = check , $
allow_nrad_changes=allow_nrad_changes, $
prefixlen = prefixlen , $
tt_range = tt_range , $
tt_nfile = tt_nfile , $
rounds = rounds , $
nohdr = nohdr , $
count = count , $
rots = rots , $
imark = imark , $
read_all = read_all , $
ff = ff , $
silent = silent , $
nosort = nosort , $
_extra = _extra
INPUTS:
files array; type: string
list of files. Alternative ways of specifying a set
of files involve keywords path, filter and pick.
OPTIONAL INPUT PARAMETERS:
path=path scalar; type: string; default: $NAGOYA/slow/raw
directory in which to search for files
filter=filter scalar; type: string; default: nv3d*.*
file filter (incl. wildcard) to search for files
/pick IDL dialog_pickfile function is called to let user
select files. If not set then FindAllFiles is used.
/nohdr if set no headers are read. Instead the Carrington times
from the file names are returned. (If /nohder is
not set these times are available in return keyword
'rots'
prefixlen=prefixlen scalar; type: integer; default: 4
length of filename prefix. This is 4 for the normal
tomography output files (nv3d, nv3f, wson, nson).
If set to 3 vu_select can also be used to extract
times from e.g. ea_ and e3_ files (make sure
to set /nohdr or there will be trouble !!!)
/check passed to vu_header
This keyword is not used if /nohdr is set
/allow_nrad_changes passed to vu_header
Only used if keyword /check is set
tt_range=tt_range array[1] or array[2]; type: time structure or float
if array[1] only ea* files prior to tt_range are used
if array[2] only ea* files between tt_range[0] and
tt_range[1] will be used
tt_range can be specified as time structure or as
modified Carrington variable.
tt_nfile=tt_nfile scalar; type: integer
max. # files selected
only the most recent tt_nfile files are used.
/read_all if set than the selected files are read, and the result
is returned in keyword ff (vu_read keywords,
such as /get_roi and /silent are also permitted)
/marker if set, only headers of files with a marker in the file
name (made by the time-dependent tomography program)
are returned. Keyword needs to be set only to
separate marker files from non-marker files. If the
file selection consist of either marker files only,
or non-marker files only, then this keyword is
ignored (i.e. all files are read regardles of the
/marker setting).
/highmark if set, then only files with the highest marker value,
i.e. files from the most recent time-dependent
tomography run are selected.
rounds=rounds scalar; type: integer; default: none
Only affects the return argument 'rots'.
The Carrington variables in the headers typically
refer to UT times at integer hours. This is the case
for the raw time-dependent files (each 6 hours) and
for the final files for both corotating and
time-dependent tomography (every 2 and every 6
hours, respectively). The imprecision in the
Carrington times causes deviations of several
minutes. This is corrected by converting to UT time,
rounding to the specified time (rounds=300 should
do), and then convert back to Carrington variable.
Procedure forecast_map uses this to try to get an
exact match between current system time (rounded to
an integer hour) and a matrix time to avoid
unnecessary interpolation in the time dimension.
OUTPUTS:
Result array[count]; type: structure
header information for all files
Only if /nohdr is set:
array[count]; type: double
Carrington times extracted from file names
Entries are sorted chronologically. Entries with the
same times (from time-dependent tomography) are also
sorted on marker value.
OPTIONAL OUTPUTS:
count=count scalar; type: integer
number of valid tomography files found
ff=ff array[n,l,m,2,k]; type: float
3D heliospheric arrays (only if /read_all is set)
rots=rots array; type: time structure
times extracted from file names converted
from Carrington variable to UT time.
imark=imark array; type: integer
Marker values extracted from file name
(only if /marker is set)
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL:
vu_header__define
CALLS: ***
Carrington, FILEPATH, FindAllFiles, InitVar, IsBadTime, IsTime, IsType, MEAN, TimeGet
TimeOp, TimeUnit, WhatIs, boost, hide_env, say, vu_check, vu_get, vu_header, vu_prefix
vu_read, vu_set
CALLED BY:
compipsd, forecast, forecast_ice, qRemoteView_Pick, vu_coronagraph, vu_earthskymap
vu_elotime, vu_getdata, vu_insitu_persist, vu_insitu_raw, vu_lineofsight, vu_movie
vu_new_time, vu_remoteview, vu_synopt, vu_thomson_fisheye, vu_update_hours
vu_update_marker, vu_vox_write
PROCEDURE:
Keywords path, filter and pick are used only if argument 'files' is not
specified.
The tomographic data are stored in files with names having the form
abc1234.6789_00001, where 1234.678 indicates a modified Carrington variable,
and 00001 is a counter for the number of files in rotation 1234.
Only files with names of the specified form are put in the returned list of
headers. If one of the keywords tt_range and/or tt_nfile are specified then
the list of files is further reduced
If tt_range is specified then only files prior to tt_range[0] are used
(if tt_range has only one elements) or all files between tt_range[0] and
tt_range[1] are used (if tt_range has two elements).
After tt_range has been applied a group of files remain. If tt_nfile is
specified then only the most recent tt_nfile files are used.
If tt_nfile is not specified then all files are returned.
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS)
Added keyword imark to return marker values if keyword /marker is set.
Some modifications for increased efficiency. Simplified explicit
do-loop required by limitation of IDL 'string' function to 1024
-element string arrays. Modified call to flt_string.
SEP-2002, Paul Hick (UCSD/CASS)
Added keyword 'prefixlen' to be able to extract times from the
file names for ea_ and e3_ files.
The time-dependent tomography produces multiple reconstructions for the
same times, differentiated by different marker values. However, the
Fortran tomography program does not always use completely identical
times due to inherent imprecision in the calculation of Carrington
times. Differences should be no bigger than 0.0001 Carrington rotation.
These differences are eliminated now by using the mean time for all
entries with different marker values (but referring to the same time).
Replaced call to IDL findfile function to a call to FindAllFiles
(including _extra keyword). This allows recursive searches.
OCT-2002, Paul Hick (UCSD/CASS)
Added keyword rounds
OCT-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added keyword /highmark
[Previous]
[Next]
NAME:
vu_set
PURPOSE:
Update information in headers produced by tomography programs
CATEGORY:
sat/util/vupack
CALLING SEQUENCE:
hdr = vu_set(hdr [, keyword=value] )
INPUTS:
hdr array[n]; array of headers extracted from tomography files
OPTIONAL INPUT PARAMETERS:
Keyword: Set values:
file = file scalar; type: string; fully-qualified file name
created = created scalar; type: string; time at which file was created
bad = bad scalar; type: float; value reprenting 'bad' data
version = version scalar; type: string; version number for header layout
prefix = prefix scalar; type: string; filename prefix (e.g. 'nv3d')
time_index = time_index
uttime = uttime
forecast_time = forecast_time
array_range = array_range
roi_range = roi_range
latitude_range = latitude_range
start_distance = start_distance
distance_step = distance_step
start_time = start_time
time_step = time_step
power_density = power_density
power_distance = power_distance
density_at_1AU = density_at_1AU
smooth_filter = smooth_filter
fill_filter = fill_filter
time_filter = time_filter
clip_longitude = clip_longitude
scale = scale array[4]; type: float; scaling factors
power_norm = power_norm array[2]; type: float
dimension = dimension array[4]; type: integer; # longitudes, latitudes, distances and times
iteration = iteration
nltot = nltot array[2]; type: integer; # lines of sight
nlos = nlos array[2]; type: integer, # line-of-sight segments
dlos = dlos array[2]; type: float; length of line-of-sight segment
binx = binx array[2]; type: float; # line-of-sight segments per bin threshold
user_info = user_info
marker = marker
/plasma scalar; type: integer: 1 for velocity/density data
/magnetic scalar; type: integer; 1 for magnetic field data
/degrees
OUTPUTS:
R requested entry from header
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, InitVar, IsType, ToDegrees
CALLED BY:
vu_mean, vu_new_time, vu_read, vu_select, vu_syncgrid, vu_update_marker
SEE ALSO:
T3D_get, T3D_iget
PROCEDURE:
MODIFICATION HISTORY:
AUG-2002, Paul Hick (UCSD/CASS)
AUG-2002, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added workaround for an IDL platform inconsistency concerning the
presence/absence of a leading dummy dimension in hdr.uttime and
hdr.time_forecast. IDL5.5 on Linux has a dummy dimension, which is
absent in IDL5.5 on Windows and IDL6.0beta on Linux.
[Previous]
[Next]
NAME:
vu_set_header_entry
PURPOSE:
Only for internal use by vu_header
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
flt_string
MODIFICATION HISTORY:
OCT-2005, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Extracted from vu_header
[Previous]
[Next]
NAME:
vu_set_time_entry
PURPOSE:
Only for internal use by vu_header
CALLING SEQUENCE:
FUNCTION vu_set_time_entry, hdr_str, str, offset
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, IsTime, TimeSet, flt_string, vu_check
CALLED BY:
vu_header
MODIFICATION HISTORY:
OCT-2005, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Extracted from vu_header.
[Previous]
[Next]
NAME:
vu_skymap_type__define
PURPOSE:
Automatic definition of structure for storing image type parameters
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_skymap_type__define
INPUTS:
(none)
OUTPUTS:
(none)
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL BY:
vu_type_skymap
CALLS: ***
vu_fnc
PROCEDURE:
(called when using expression {vu_skymap_type})
Structure definition:
tmp = {vu_skymap_type, $
data : lonarr(vu_fnc(/count,/los)), $
display : '' , $ ; Type of display; also used in construction of gif file name
prefix : '' , $ ; Prefix for tomography file containing 3D data arrays
ctable : 0 , $ ; Color table
xysize : [0,0] , $
charsize: 0.0 , $
thick : 0.0 , $
label : '' , $ ; Postfix to 'display' used in construction of gif file name
Fmin : 0.0 , $
Fmax : 0.0 , $
format : '' , $ ; Format used by GetColors to turn 'breakval' into strings
breakval: fltarr(255), $ ; Contour levels
delay : !TheTime } ; Time delay for aft-/forcast
[Previous]
[Next]
NAME:
vu_solardisk
PURPOSE:
Projects tomographic data at fixed distance from the Sun onto the
plane of the sky.
CATEGORY:
Tomography
CALLING SEQUENCE:
PRO vu_solardisk, hdr, ff, ihdr=ihdr, ut0=ut0, $
radius = radius , $
type = type , $
printer = printer , $
focus_center= focus_center , $
degrees = degrees , $
silent = silent , $
module = module , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data arrays)
then a synoptic map for data at index 'ihdr' is displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Time (converted to an Earth-based Carrington variable)on which
the map is centered. If not specified then the time in 'hdr' is used.
If a sequence of files from a time-dependent tomography run is
used, and ihdr is not specified, then the hdr closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
radius=radius scalar; type: float: default: 1 AU
heliocentric distance for synoptic map (AU)
The radius is rounded to the nearest grid distance in the 3D
heliospheric matrix.
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
AngleRange, BadValue, CV_COORD, Carrington, CvSky_Heliographic, CvT3d, InitVar, IsType
PlotSolarDisk, TimeGet, TimeUnit, ToRadians, big_eph, boost, destroyvar, gridgen
jpl_body, say, set_page, vu_atlocation, vu_fnc, vu_get, vu_get_page, vu_getdata
vu_gettime, vu_type_insitu
CALLED BY:
forecast, vu_movie
PROCEDURE:
MODIFICATION HISTORY:
AUG-2002, Paul Hick (UCSD/CASS)
JAN-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Minor bug fix. The diameter variable passed to PlotSolarDisk was misspelled.
[Previous]
[Next]
NAME:
vu_spherecut
PURPOSE:
Makes cut on sun-centered sphere in tomography output
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_spherecut, hdr, ff, ihdr=ihdr, ut0=ut0, $
radius = radius , $
type = type , $
printer = printer , $
silent = silent , $
module = module , $
abg_euler = abg_euler , $
degrees = degrees , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data arrays)
then a synoptic map for data at index 'ihdr' is displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
(passed to vu_getdata)
Time (converted to an Earth-based Carrington variable).
If not specified then the time in 'hdr' is used.
If a sequence of files from a time-dependent tomography run is
used, and ihdr is not specified, then the hdr closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
radius=radius
scalar; type: float: default: outer boundary of data sphere
The sphere covers a sphere at heliocentric distance
of 'radius' AU.
abg_euler array[3]; type: float; default: none
See PROCEDURE
OUTPUTS:
Output is displayed on the screen or written to file.
See vu_get_page for information on the keywords involved.
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
AngleRange, CV_COORD, Carrington, CombineRotations, CvSky, EulerRotate, InitVar
IsType, PlotSphereCut, TimeGet, TimeUnit, ToRadians, boost, destroyvar, gridgen, say
set_page, vu_atlocation, vu_fnc, vu_get, vu_get_page, vu_getdata, vu_gettime
vu_type_insitu
PROCEDURE:
The sphere is at the distance specified in the 'radius' keyword.
By default the horizontal is along the ecliptic plane.
This can be changed using one of the from_* keywords
to CvSky.
MODIFICATION HISTORY:
MAY-2010, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_stereoview
PURPOSE:
Makes remote view of density and fish-eye map of
the Thomson scattering brightness
as seen from Stereo spacecraft
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_stereoview, hdr, ff, ut0=ut0, ihdr=ihdr, $
density = density , $
brightness = brightness, $
ips_glevel = ips_glevel, $
degrees = degrees , $
fovsize = fovsize , $
sun_offset = sun_offset, $
volsize = volsize , $
full_color = full_color, $
full_range = full_range, $
full_opa = full_opa , $
behind = behind , $
earth = earth , $
delta_loc = delta_loc , $
silent = silent , $
_extra = _extra
INPUTS:
hdr
ff
OPTIONAL INPUT PARAMETERS:
/behind select Stereo B (default: Stereo A)
/degrees if set, angles are in degrees
/brightness makes Thomson scattering brightness map
/ips_glevel makes IPS g-level map
fovsize=fovsize scalar; type: float: default: 35 deg
field-of-view halfwidth
sun_offset=sun_offset scalar; type: float: default: 53.3 deg
offset from Sun in ecliptic longitude for
viewing direction
silent = silent controls amount of informational
message
volsize=volsize
volsize = volsize
full_color = full_color
full_range = full_range
full_opa = full_opa
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL:
CALLS: ***
AngleRange, InitVar, IsType, TimeGet, TimeUnit, ToDegrees, big_eph, vu_get, vu_getdata
vu_remoteview, vu_type_insitu
PROCEDURE:
By default images are displayed on the screen.
For ways to save images, see RemoteView_Display2D
and RemoteView_Display3D, especially keywords
base_dir and base_name, and the image type keywords
for RemoteView_Init_View (/png, /gif, etc)
MODIFICATION HISTORY:
SEP-2008, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_syncgrid
PURPOSE:
Change resolution of tomography arrays
CATEGORY:
smei/sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_syncgrid, old_hdr, old_ff, $
ref_hdr = ref_hdr_ , $
ref_ff = ref_ff_ , $
new_hdr = new_hdr_ , $
new_ff = new_ff_ , $
silent = silent
INPUTS:
old_hdr array[k]; type: structure
headers of tomography files
old_ff array[n,l,m,2,k]; type: float
3d heliospheric arrays that need to be resampled
OPTIONAL INPUT PARAMETERS:
ref_hdr = ref_hdr
array[K]; type: structure
reference headers
ref_ff = ref_ff
array[N,L,M,2,k]; type: float
reference 3d heliospheric arrays used
OUTPUTS:
result scalar; type: integer
0: error
1: resampling successfull
OPTIONAL OUTPUT PARAMETERS:
new_hdr = new_hdr
array[k]; type: structure
update headers matching the output array 'result'
These will be the same as the input 'old_hdr' array
with the grid parameters updated with values
from 'ref_hdr'
new_ff = new_ff
array[N,L,M,2,k]
resampled array
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, IsType, REVERSE, SuperArray, destroyvar, gridgen, say, vu_get, vu_set
PROCEDURE:
Note that the last dimension MUST be the same
as for input array 'ff'.
MODIFICATION HISTORY:
APR-2013, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_synopt
CALLING SEQUENCE:
pro vu_synopt
CALLS: ***
GetFileSpec, vu_select, vu_synopticmap
[Previous]
[Next]
NAME:
vu_synopticmap
PURPOSE:
Plot a synoptic map extracted from a heliospheric tomography file
CATEGORY:
Tomography
CALLING SEQUENCE:
PRO vu_synopticmap, hdr, ff, $
ut0 = ut0 , $
ihdr = ihdr , $
radius = radius , $
type = type , $
ylshow = ylshow , $
degrees = degrees , $
earth = earth , $
forecast = forecast , $
printer = printer , $
timeaxis = timeaxis , $
eastlimb = eastlimb , $
westlimb = westlimb , $
upto = upto , $
xysize = xysize , $
module = module , $
diskcenter = diskcenter, $
fromcenter = fromcenter, $
ascii_file = ascii_file, $
mhd_string = mhd_string, $
mhd_unit = mhd_unit , $
silent = silent , $
_extra = _extra
INPUTS:
hdr array[1]; type: structure
header information about the tomographic reconstruction
as returned from vu_select. If 'hdr' does not exist,
vu_select is called.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ihdr=ihdr scalar; type: integer: default: 0
If 'hdr' is an array (and 'ff' the corresponding data
arrays) then a synoptic map for data at index 'ihdr' is
displayed.
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Time (converted to an Earth-based Carrington variable)
on which the map is centered. If not specified then the
time in 'hdr' is used.
If a sequence of files from a time-dependent tomography
run is used, and ihdr is not specified, then the hdr
closest to ut0 is used.
type=type array[1]; type: structure
output structure from vu_type_insitu
/timeaxis if set, adds a time axis at the top of the map, specifying
the time at which the corresponding heliographic
longitude crossed the central meridian on the solar disk
(as seen from Earth).
radius=radius scalar; type: float: default: 1 AU
heliocentric distance for synoptic map (AU)
The radius is rounded to the nearest grid distance in
the 3D heliospheric matrix.
/earth sets keyword 'radius' to the heliocentric distance of Earth
at the time corresponding to the center of the synoptic
map plotted on the screen (see PROCEDURE). Also plots
the Earth symbol at the heliographic location of Earth
at that time. If /timeaxis is set, also forces plotting
of a time series at Earth along the bottom of the map.
/forecast if /timeaxis is set, plots vertical dashed line in center of
map; and the word 'FORECAST' inside left part of map.
ylshow=ylshow array[2]; type: float; default: [-60,60] degrees
range of latitudes shown in the synoptic map in units
determined by keyword /degrees
/degrees if set, then ylshow is assumed to be in degrees (default: radians)
/printer if set, print to print device (or EPS) instead of to z-buffer
ascii_file=ascii_file
if set to valid file name the map array will be written to this
file (at the resolution of the tomography file).
One record for each latitude is written (from bottom to
top of the map)
Keywords used only when a time-ordered sequence is processed:
/eastlimb same as fromcenter = -90 (degrees)
/westlimb same as fromcenter = +90 (degrees)
/diskcenter same as fromcenter = 0 (degrees)
fromcenter=fromcenter
scalar; type: float; default: none
offset in heliographic longitude -180 < fromcenter < 180 degrees)
If none of the above four keywords is set than a synoptic map
at a single time is plotted. The time is specified through keywords
ut0 or ihdr.
If a time-ordered sequence is processed and one of these keywords is
set then a synoptic map is build from narrow longitudinal strips
with each strip extracted at a different time.
E.g. if /diskcenter is SET then strips perpendicular to the solar
equator at the sub-Earth point (at diskcenter) are extracted from
each of sequence members.
If /eastlimb or /westlimb are set the strips are extracted above
the east or west limb, respectively.
Additional keywords can be passed to vu_get_page if /printer is not set
OUTPUTS:
(plot to screen)
OPTIONAL OUTPUT PARAMETERS:
hdr array[1]; type: structure
ff array[n,m,l,2]; type: float
Returns headers and arrays read by vu_select and vu_read
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
Carrington, GetColors [1], GetColors [2], GetColors [3], INTERPOL, InitVar, IsType
MEAN, PlotSynopticMap, SuperArray, TimeGet, TimeUnit, ToRadians, big_eph, boost
destroyvar, gridgen, jpl_body, say, set_page, vu_atlocation, vu_fnc, vu_get, vu_get_page
vu_getdata, vu_gettime, vu_is_sequence, vu_timeseries, vu_type_insitu
CALLED BY:
forecast, vu_movie, vu_synopt
PROCEDURE:
> A t3d file contains a 3D matrix defined on a regular grid in heliographic
coordinates. The array processed here covers one Carrington rotation [xc,xc+1].
Typically, the array refers to time xc+0.5.
> A 2D matrix is extracted at the distance set by keyword 'radius', or implied by
keyword /earth.
> If argument 'ut' is not specified then the synoptic map plotted covers [xc, xc+1].
> If argument 'ut' is specified the plot covers the Carrington variable at time 'ut
+/- 0.5 rotation.
MODIFICATION HISTORY:
AUG-1999, Paul Hick (UCSD/CASS)
DEC-2000, Paul Hick (UCSD/CASS)
Added keyword degree
Added keyword ylshow to set latitude range shown in the synoptic map.
JAN-2001, Paul Hick (UCSD/CASS)
Added keyword /earth.
Added capability to plot synoptic map at any radius inside the range
covered by the t3d array by linear interpolation on the 3D matrix,
MAR-2001, Paul Hick (UCSD/CASS)
Rearrange argument list. Arguments 'hdr' and 'type' are now used to
set up the display.
SEP-2001, Paul Hick (UCSD/CASS)
Fixed bug in call to vu_type_insitu
JUL-2002, Paul Hick (UCSD/CASS)
Added interpolation between neigbouring times of ut0, instead of
truncating to nearest grid time.
AUG-2002, Paul Hick (UCSD/CASS)
Activated option to generate synoptic maps simulating the way some
types of synoptic data are made: assembling the map from strips of
data (limb scans, slit along central meridian) taken at different times.
NOV-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added ascii_file keyword.
[Previous]
[Next]
NAME:
vu_thomson_antifish
PURPOSE:
Wrapper for PlotEarthSkymap [1]. Displays a view of the sky from Earth
using a 3D heliospheric matrix from one of the tomography programs.
CATEGORY:
WWW: graphics
CALLING SEQUENCE:
PRO vu_EarthSkymap, hdr, ff, ut0=ut0, ihdr=ihdr, type=type, $
nodata=nodata, maxelo=maxelo, geolng=geolng, $
degrees=degrees, equator=equator, _extra=_extra, $
solar=solar, band=band, F_full=FF_full, RA_full=RA_full, $
is_sequence=is_sequence, point_sources=point_sources, $
hardcopy=hardcopy, count=count, nRA=nRA, nDE=nDE, nRR=nRR, $
dRR=dRR, silent=silent, module=module, zero_shift=zero_shift
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from the 'hdr' argument is used.
See arg_time for more details.
maxelo scalar; type: float
if set and non-zero then a fish-eye map is plotted out to
elongation 'maxelo'. By default a Hammer-Aitoff map is drawn
destination=destination
if set to valid directory then graphics output is saved as GIF files
/degrees if set, indicates that all angles are in degrees. Default: radians.
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along the ecliptic
geolng scalar; type: float
geographic longitude of location on Earth (in units implied
by /degrees keyword). If 'geolng' is specified then a 'transit map'
is calculated for a one-day period centered on 'ut'
zero_shift passed to EarthSky3DLoc
(NOT used for sky sweeps, i.e. NOT used if 'geolng' is set).
By default the skymap is centered on the Sun. Setting 'zero_shift' moves
the center to increasing RA (or ecliptic longitude) by 'zero_shift'.
E.g. to produces an anti-solar skymap set zero_shift=!pi
(or zero_shift=180, /degrees).
point_sources=point_sources
array[n]; type: structure
information about IPS observation (location in sky, IPS speed
and g-level; see GetNagoyaSources.
/names if set, then the names of the point sources are plotted
/solar
(only if keyword 'band' is used)
band=band scalar; type float
used to replace a limited strip in RA in an already existing skymap.
band: width of strip in hours
The strip is inserted into arrays specified in keywords
F_full and RA_full.
RA_full=RA_full array(nRA); type: float
F_full=FF_full array(nRA,nDE); type: float
skysweep arrays (RA and function value) where only a strip of width
band needs to be updated. Usually these are obtained from a
previous call to this procedure. If they don't exist yet then
keyword 'band' is ignored and a full skysweep map is intialized.
Several keywords are passed to vu_type_skymap:
The most important ones set the data type to be plotted:
/ips_speed IPS speed
/ips_glevel IPS g-level
/brightness Thomson scattering brightness
/pb Thomson scattering polarization brightness
type=type array[1]; type: structure
OUTPUTS:
(none)
OPTIONAL OUTPUTS:
(only if keyword 'band' is used)
RA_full=RA_full array(nRA); type: float: default: none
F_full=FF_full array(nRA,nDE); type: float; default: none
updated skysweep arrays (RA and function value)
with new strip of width band inserted
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL:
IPS_hlevel_w, IPS_velocity, IPS_velocity_w, ThomsonBrightness
CALLS: ***
ARG_TIME, AngleRange, BadValue, ColorSkybox, CvSky, EarthSky3DLoc, EarthTransit3DLoc
EulerRotate, FILEPATH, FishEye, GeographicInfo, GetColors [1], GetColors [2]
GetColors [3], GetFileSpec, HammerAitoff, INTERPOL, IPS_params, InitVar
IntegrateLOS, IsType, LOADCT, MercatorProj, NewcombSun, PlotCurve
PlotEarthSkymap [1], PlotEarthSkymap [2], PlotEarthSkymap [3]
PlotEarthSkymap [4], REVERSE, STRETCH, ThomsonRadialFilter, TimeGet, TimeSet
TimeString, TimeUnit, ToDegrees, ToRadians, UBVCONST, UNIQ, VU_TYPE_SKY, WhatIs
anicenum, destroyvar, flt_read, gridgen, reset_colors, set_page, vu_earthskymap
vu_get, vu_get_page, vu_getdata, vu_gettime, vu_point_source
CALLED BY:
GetColors [2], PlotEarthSkymap [3]
PROCEDURE:
> Several parameters define the grid used to calculate the sky map.
These are passed to EarthSky3DLoc and EarthTransit3DLoc:
nRA scalar; type: int; default: 72
# points in skymap in longitudinal direction (either right ascensions
of ecliptic longitude)
nDE scalar; type: int; default: 36
# points in skymap in latitudinal direction(either declination or
ecliptic latitude)
nRR scalar; type: int; default: 20
# steps along lines of sight at each point in the sky
dRR scalar; type: float; default: 0.1 AU
step size along line of sight (AU)
> The sky map is build from nRA*nDE lines of sight integrations through the F3D array
The locations in the sky of the lines of sight are
RA/Lng = (RA/Lng Sun) -180 + (360./nRA)*[0.5, 1.5, .. , nRA-0.5 ]
Decl./Lat = - 90 + (180./nDE)*[0.5, 1.5, .. , nDE-0.5 ]
Dist along los = dRR*[0.5,1.5,...,nRR-1]
Note that each line of sight is centered on a 'box' of 360/nRA by 180/nDE degrees,
and that all lines of sight together cover the entire sky.
The edges of the boxes for all lines of sight are returned in the RA and DE keywords
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
AUG-2000, Paul Hick (UCSD/CASS)
Added option to accept a vu_read structure as a 1st argument
SEP-2001, Paul Hick (UCSD/CASS)
Fixed bug in vu_type_sky calls
JAN-2002, Paul Hick (UCSD/CASS)
Changed the initialization procedure for a skysweep with the 'band'
keyword set. The initialization now ignores the 'band' value and simply
calculates a full skysweep map (the earlier initialization put a new
strip in an otherwise empty sky).
JUL-2002, Paul Hick (UCSD/CASS)
Added interpolation between neigbouring times of ut0, instead of
truncating to nearest grid time.
AUG-2004, Paul Hick (UCSD/CASS)
Modifed IntegrateLOS calls. For Thomson scattering brightness maps with
point sources overplotted a radial filter was applied to the maps but
not to the point sources. Fixed.
OCT-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added zero_shift keyword.
[Previous]
[Next]
NAME:
vu_thomson_fisheye
CALLING SEQUENCE:
pro vu_thomson_fisheye
CALLS: ***
CARRINGTONT, GetFileSpec, STRSPLIT, TimeString, TimeUnit, gridgen, vu_earthskymap
vu_select
[Previous]
[Next]
NAME:
vu_thomson_hammer
PURPOSE:
Wrapper for PlotEarthSkymap [1]. Displays a view of the sky from Earth
using a 3D heliospheric matrix from one of the tomography programs.
CATEGORY:
WWW: graphics
CALLING SEQUENCE:
PRO vu_EarthSkymap, hdr, ff, ut0=ut0, ihdr=ihdr, type=type, $
nodata=nodata, maxelo=maxelo, geolng=geolng, $
degrees=degrees, equator=equator, _extra=_extra, $
solar=solar, band=band, F_full=FF_full, RA_full=RA_full, $
is_sequence=is_sequence, point_sources=point_sources, $
hardcopy=hardcopy, count=count, nRA=nRA, nDE=nDE, nRR=nRR, $
dRR=dRR, silent=silent, module=module, zero_shift=zero_shift
vu_EarthSkymap, hdr, ff, ut0=ut0, /nodata, $
maxelo=maxelo, geolng=geolng, point_sources=point_sources, $
/degrees, /equator, destination=destination
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ut0=ut0 scalar or array[1]; type: time structure, float or integer
Specifies the time on which the time series is centered.
If not specified then the time from the 'hdr' argument is used.
See arg_time for more details.
maxelo scalar; type: float
if set and non-zero then a fish-eye map is plotted out to
elongation 'maxelo'. By default a Hammer-Aitoff map is drawn
destination=destination
if set to valid directory then graphics output is saved as GIF files
/degrees if set, indicates that all angles are in degrees. Default: radians.
/equator if set, the 'horizontal' in the sky map is parallel to the
equatorial plane. By default the horizontal is along the ecliptic
geolng scalar; type: float
geographic longitude of location on Earth (in units implied
by /degrees keyword). If 'geolng' is specified then a 'transit map'
is calculated for a one-day period centered on 'ut'
zero_shift passed to EarthSky3DLoc
(NOT used for sky sweeps, i.e. NOT used if 'geolng' is set).
By default the skymap is centered on the Sun. Setting 'zero_shift' moves
the center to increasing RA (or ecliptic longitude) by 'zero_shift'.
E.g. to produces an anti-solar skymap set zero_shift=!pi
(or zero_shift=180, /degrees).
point_sources=point_sources
array[n]; type: structure
information about IPS observation (location in sky, IPS speed
and g-level; see getnagoyasources.
/names if set, then the names of the point sources are plotted
/solar
(only if keyword 'band' is used)
band=band scalar; type float
used to replace a limited strip in RA in an already existing skymap.
band: width of strip in hours
The strip is inserted into arrays specified in keywords
F_full and RA_full.
RA_full=RA_full array(nRA); type: float
F_full=FF_full array(nRA,nDE); type: float
skysweep arrays (RA and function value) where only a strip of width
band needs to be updated. Usually these are obtained from a
previous call to this procedure. If they don't exist yet then
keyword 'band' is ignored and a full skysweep map is intialized.
Several keywords are passed to vu_type_sky:
The most important ones set the data type to be plotted:
/ips_speed IPS speed
/ips_glevel IPS g-level
/brightness Thomson scattering brightness
/pb Thomson scattering polarization brightness
type=type array[1]; type: structure
OUTPUTS:
(none)
OPTIONAL OUTPUTS:
(only if keyword 'band' is used)
RA_full=RA_full array(nRA); type: float: default: none
F_full=FF_full array(nRA,nDE); type: float; default: none
updated skysweep arrays (RA and function value)
with new strip of width band inserted
INCLUDE:
@compile_opt.pro ; On error, return to caller
EXTERNAL:
IPS_hlevel_w, IPS_velocity, IPS_velocity_w, ThomsonBrightness
CALLS: ***
ARG_TIME, AngleRange, BadValue, ColorSkybox, CvSky, EarthSky3DLoc, EarthTransit3DLoc
EulerRotate, FILEPATH, FishEye, GeographicInfo, GetColors [1], GetColors [2]
GetColors [3], GetFileSpec, HammerAitoff, INTERPOL, IPS_params, InitVar
IntegrateLOS, IsType, LOADCT, MercatorProj, NewcombSun, PlotCurve
PlotEarthSkymap [1], PlotEarthSkymap [2], PlotEarthSkymap [3]
PlotEarthSkymap [4], REVERSE, STRETCH, ThomsonRadialFilter, TimeGet, TimeSet
TimeString, TimeUnit, ToDegrees, ToRadians, UBVCONST, UNIQ, UlyssesOrbit, VU_TYPE_SKY
WhatIs, anicenum, destroyvar, flt_read, gridgen, reset_colors, set_page
vu_earthskymap, vu_get, vu_get_page, vu_getdata, vu_gettime, vu_point_source
CALLED BY:
GetColors [3], PlotEarthSkymap [4]
PROCEDURE:
> Several parameters define the grid used to calculate the sky map.
These are passed to EarthSky3DLoc and EarthTransit3DLoc:
nRA scalar; type: int; default: 72
# points in skymap in longitudinal direction (either right ascensions
of ecliptic longitude)
nDE scalar; type: int; default: 36
# points in skymap in latitudinal direction(either declination or
ecliptic latitude)
nRR scalar; type: int; default: 20
# steps along lines of sight at each point in the sky
dRR scalar; type: float; default: 0.1 AU
step size along line of sight (AU)
> The sky map is build from nRA*nDE lines of sight integrations through the F3D array
The locations in the sky of the lines of sight are
RA/Lng = (RA/Lng Sun) -180 + (360./nRA)*[0.5, 1.5, .. , nRA-0.5 ]
Decl./Lat = - 90 + (180./nDE)*[0.5, 1.5, .. , nDE-0.5 ]
Dist along los = dRR*[0.5,1.5,...,nRR-1]
Note that each line of sight is centered on a 'box' of 360/nRA by 180/nDE degrees,
and that all lines of sight together cover the entire sky.
The edges of the boxes for all lines of sight are returned in the RA and DE keywords
MODIFICATION HISTORY:
MAR-2000, Paul Hick (UCSD/CASS)
AUG-2000, Paul Hick (UCSD/CASS)
Added option to accept a vu_read structure as a 1st argument
SEP-2001, Paul Hick (UCSD/CASS)
Fixed bug in vu_type_sky calls
JAN-2002, Paul Hick (UCSD/CASS)
Changed the initialization procedure for a skysweep with the 'band'
keyword set. The initialization now ignores the 'band' value and simply
calculates a full skysweep map (the earlier initialization put a new
strip in an otherwise empty sky).
JUL-2002, Paul Hick (UCSD/CASS)
Added interpolation between neigbouring times of ut0, instead of
truncating to nearest grid time.
AUG-2004, Paul Hick (UCSD/CASS)
Modifed IntegrateLOS calls. For Thomson scattering brightness maps with
point sources overplotted a radial filter was applied to the maps but
not to the point sources. Fixed.
OCT-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added zero_shift keyword.
[Previous]
[Next]
NAME:
vu_timeseries
PURPOSE:
Extract a time series at Earth from a 3D heliospheric matrix obtained with
one of the tomography programs
CATEGORY:
WWW
CALLING SEQUENCE:
FUNCTION vu_timeseries, XC3D, R3D, dR3D, F3D, $
ut = ut , $
range = range , $
delt = delt , $
T = T , $
periodic= periodic , $
sequence= sequence , $
radius = radius , $
nearL1 = nearL1 , $
power = power , $
body = body , $
silent = silent , $
_extra = _extra
INPUTS:
The 3D heliospheric matrix is described by the following input:
XC3D array[2] or array[2,ntime]; type: float
Carrington range of reconstruction
R3D scalar or array[ntime]; type: float
heliocentric distance at inner boundary of matrix
dR3D scalar or array[ntime]; type: float
heliocentric distance resolution of the heliospheric matrix
F3D array[n,m,l,ntype,ntime]; float
3D heliocentric matrix;
1st dim: Carrington variable, covering range XC3D
2nd dim: Heliographic latitude, covering [-90,90] degrees
3rd dim: Heliocentric distance, with inner boundary at R3D and resolution dR3D
4th dim: different data types (usually 2: velocity/density, Br/Bt
5th dim: # members in a (time-dependent) sequence
OPTIONAL INPUT PARAMETERS:
sequence=sequence
array[ntim]; type: time structure of float; default: none
if specified, these are the times corresponding to the
ntime data arrays specified in argument F3D.
T=T array; type: time structure or float
times at which time series is evaluated. A float array
is interpreted as an array of Carrington times. If T is
not set then the times are set up using the 'range' and
'ut' keywords.
range=range array[2]; type: float; default: XC3D[*,0]
(NOT used if explicit times are specified using the T
keyword) the Carrington range (start and end Carrington
variable of time series to be extracted)
ut=ut scalar; type: integer
array[1]; type: time structure
(NOT used if explicit times are specified using the T
keyword). Defines the time (UT) used to center the time
series. A scalar is interpreted as the difference
between local time and UT, and is used to get a UT from
the system time. The time series corresponds to
UT +/- half a the range specified in keyword 'range'.
delt=delt scalar; type: float
time steps in time series (days)
if not specified then the time step is determined from
the resolution in Carrington variable of F3D
radius=radius
body=body scalar; type: string
usually set to return value of function jpl_body.
if SET then the JPL ephemeris is used to calculate the
heliospheric locations where the time series is extracted.
if NOT set then function big_eph is used to extract
a time series at Earth (i.e. NOT setting 'body' should give the
save results as setting body=jpl_body(/earth)).
Note the keyword /nearL1 only makes sense if body=jpl_body(/earth)
/nearL1 indicates whether time series is for spacecraft at L1;
if set the heliocentric distance calculated from
big_eph is multiplied with 0.99)
power=power array[ntype] or array[ntype,ntime]
power of heliocentric distance to be removed from the time series
(0 for velocity, 2 for normalized density;
2 for radial component of the magnetic field; 1 for tangential component)
OUTPUTS:
F array[*]; float
the function values for the time series
OPTIONAL OUTPUT PARAMETERS:
T array[*]; time structure
times at which function values where calculated
1st and last time correspond to the selected time range
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
AngleUnits, BadValue, Carrington, CvSky, InitVar, InterpolateHeliosphere, IsType, MEAN
SuperArray, TimeInterpol, TimeOp, TimeUnit, big_body, big_eph, flt_string, gridgen
jpl_body, say
CALLED BY:
vu_insitu, vu_synopticmap
PROCEDURE:
> The time associated with a given Carrington variable is the time at which the
corresponding heliographic longitude crossed the center of the solar disk.
> The times (or equivalent Carrington variables) to be extracted can be set in several ways:
1. Explicitly set the times array T
2. Set 'range' to a two-element array with start and end time or Carrington variable.
Not setting 'range' is the same as setting 'range' to XC3D
3. Setting 'range' to a scalar fraction of a rotation is the same as setting
range = mean(XC3D)+0.5*range*[-1,1], i.e. range=0.5 picks one rotation centered
on the mean of XC3D.
> Setting 'ut' shifts 'range' and centers it on 'ut'
> A time array with the specified step size is set up, and converted to an array of
Carrington variable. The function values are obtained by interpolating on the 3D matrix.
> The heliocentric distance by default is the Sun-Earth distance. This can be modified
using the 'radius' and 'nearL1' keywords. 'radius' can be used to explicitly
set the distance (usually this will be a scalar). Setting /nearL1 multiplies
the heliocentric Sun-Earth distance with 0.99.
MODIFICATION HISTORY:
OCT-1999, Paul Hick (UCSD/CASS)
MAY-2001, Paul Hick (UCSD/CASS
added /nearL1 keyword)
APR-2004, Paul Hick (UCSD/CASS)
activated keyword 'body' to enable use of JPL ephemeris.
OCT-2006, Paul Hick (UCSD/CASS)
Replaced jp_eph by big_eph and made keyword body a string.
This allows access to all bodies in the list returned by
the function big_body()
FEB-2007, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Replaced longitudes keyword by cv2carrington keyword in
InterpolateHeliosphere calls.
[Previous]
[Next]
NAME:
vu_type_insitu
PURPOSE:
Sets up a structure with plot information
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
FUNCTION vu_type_insitu, display, $
density = density , $
speed = speed , $
bradial = bradial , $
btang = btang , $
bnorm = bnorm , $
brtmag = brtmag , $
bmag = bmag , $
pdynamic = pdynamic , $
error = error , $
hdr = hdr , $
type = type , $
ymin = ymin , $
ymax = ymax , $
breakval = BreakVal , $
xysize = xysize , $
add2label = add2label , $
charsize = charsize , $
thick = thick , $
delay = delay , $
ctable = ctable , $
data_type = data_type
INPUTS:
display scalar; type: string; default: 'earth_insitu'
identifies the type of map to be made. Valid values
are: 'earth_insitu','synoptic'
OPTIONAL INPUT PARAMETERS:
/density, /speed, /bradial, /btang, /bnorm, /brtmag, /bmag, /pdynamic
identifies which type of data will be used to make
the plot. More than one of these can be set.
hdr=hdr array[*]; type: structure
headers from nv3d* or wson* files (used only to pick
a data type.
type=type array[n]; type: structure
used to initialize the 'type' structure
(one structure for each data type selected).
data_type=data_type array[8]; type: integer
0: corresponding data type is not processed
1: corresponding data type is processed
All the following keywords are use to override default values:
ymin=ymin scalar; type: float
ymax=ymax scalar; type: float
sets min and max. value used in plot of time series
(one for each data type selected).
breakval=BreakVal array[*]; type: float
contour levels for synoptic map
xysize=xysize array[1] or array[2]; type: integer
size of plot window
charsize=charsize scalar; type: float
thick=thick scalar; type: float
correspond to standard IDL keywords
delay scalar; type: float; default: 0
array[1]; type: time difference structure
time difference for fore- and aftcasts in hours or
as a difference structure (positive for forecasts)
OUTPUTS:
type array[n]; type: structure
see vu_insitu_type__define
n is the number of data types selected (i.e. the
number of keywords in /density, /speed, /bradial,
/btang set).
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
BadValue, InitVar, IsType, SubArray, destroyvar, vu_fnc, vu_prefix
EXTERNAL:
vu_insitu_type__define
CALLED BY:
forecast, forecast_html, forecast_movie, vu_extract, vu_insitu, vu_insitu_persist
vu_linecut, vu_movie, vu_planarcut, vu_radialcut, vu_remoteview, vu_solardisk
vu_spherecut, vu_stereoview, vu_synopticmap, vu_vox_write, vu_whatis
PROCEDURE:
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS)
Rearranged processing of xysize keyword to allow explicit setting
of both horizontal and vertical window sizes independently.
SEP-2002, Paul Hick (UCSD/CASS)
Added 'delay' keyword, Added 'earth_corr' keyword
SEP-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Some reorganization; also added /pdynamis
AUG-2007, George Megally (UCSD/CASS; gmegally@ucsd.edu)
Expanded program to include STEREO A/B satellites
[Previous]
[Next]
NAME:
vu_type_skymap
PURPOSE:
Sets up a structure passed to vu_earthskymap
CATEGORY:
CALLING SEQUENCE:
FUNCTION vu_type_skymap, display , $
ips_speed = ips_speed , $
ips_glevel = ips_glevel , $
brightness = brightness , $
pb = pb , $
column_density = column_density, $
rotation_measure= rotation_measure, $
error = error , $
hdr = hdr , $
type = type , $
ymin = Fmin , $
ymax = Fmax , $
breakval= BreakVal , $
xysize = xysize , $
ysize = ysize , $
charsize= charsize , $
thick = thick , $
add2label= add2label, $
hammer = hammer , $
ctable = ctable
INPUTS:
display scalar; type: string; default: 'earth_skysnap'
identifies the type of map to be made. Valid values are:
'earth_skysnap', 'earth_skysweep'
OPTIONAL INPUT PARAMETERS:
/ips_speed, /ips_glevel, /brightness, /pb, /column_density, /rotation_measure
one (and only one) of these MUST be set.
identifies which type of data will be used to make the map
if none are set then an empty structure is returned
hdr=hdr array[*]; type: structure
headers from nv3d* or wson* files. Used only to pick a data type
if none of keywords /density, /speed, /bradial, /btang is set.
type=type array[1]; type: structure
used to initialize the structure.
All the following keywords are use to override default values:
fmin=Fmin scalar; type: float
fmax=Fmax scalar; type: float
sets min and max. value used in plot of time series
breakval=BreakVal array[*]; type: float
contour levels for synoptic map
xysize=xysize array[1] or array[2]; type: integer
size of plot window
charsize=charsize scalar; type: float
thick=thick scalar; type: float
correspond to standard IDL keywords
OUTPUTS:
type array[1]; type: structure
see vu_skymap_type__define
INCLUDE:
@compile_opt.pro ; On error, return to caller
@vu_fnc_include.pro ;
CALLS: ***
BadValue, InitVar, IsType, gridgen, vu_fnc, vu_prefix
EXTERNAL:
vu_skymap_type__define
CALLED BY:
forecast, forecast_html, vu_coronagraph, vu_earthskymap, vu_elotime, vu_movie
PROCEDURE:
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
SEP-2001, Paul Hick (UCSD/CASS)
Improved processing of input keyword 'type'
OCT-2004, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added column density.
[Previous]
[Next]
NAME:
vu_update_hours
PURPOSE:
Update the set of available final tomography files
(usually called when a new raw tomography file has been created)
CATEGORY:
WWW
CALLING SEQUENCE:
PRO vu_update_hours, kind , $
filter = filter , $
nday_future = nday_future , $
nday_past = nday_past , $
hour_step = hour_step , $
triangle = triangle , $
setbad = setbad , $
silent = silent , $
rounds = rounds , $
gzip = gzip
INPUTS:
kind scalar; type: string; default: 'slow'
'slow' or 'fast'
OPTIONAL INPUT PARAMETERS:
filter=filter scalar; type: string; default: 'nv3d'
type of tomography files ('nv3d' or 'wson')
(*.* is appended if not present yet)
hour_step scalar; type: integer; default: 2
time step between averaged output files in hours
nday_past=nday_past
scalar; type: integer; default: 2
nday_future=nday_future
scalar; type: integer; default: 2
final (averaged) files are created up to nday_future days
after the time of the last raw tomography file
/gzip compresses output files with gzip
silent=silent suppresses messages from vu_new_time
Keywords passed to vu_new_time:
triangle=triangle
/setbad
OUTPUTS:
(updated and new final tomography files)
INCLUDE:
@compile_opt.pro ; On error return to caller
CALLS: ***
FILEPATH, InitVar, IsBadTime, TimeGet, TimeOp, TimeSet, TimeUnit, say, vu_new_time
vu_prefix, vu_select
CALLED BY:
run_mean
PROCEDURE:
> The last raw tomography file is identified by looking for all
filter+*.* files in directory root = $NAGOYA/kind
The list of files is sorted, and the last file on the sorted list is
assumed to be the most recent raw tomography file.
> The final (averaged) tomography files are assumed to be located in
dest = filepath(root=root, subdir='final', '')
> First all final (averaged) tomography files that are affected by the new tomography
file are updated (by overwriting them). Then a number of new final files are
created by extending the range of final files to at most 3 days beyond the time of
the new tomography file.
MODIFICATION HISTORY:
APR-2000, Paul Hick (UCSD/CASS)
SEP-2001, Paul Hick (UCSD/CASS)
The max # of new files was limited to cover nday=nday_past+nday_future days,
starting from the last final file found in directory 'dest'.
This prevented automatic recovery from a big gap in the production of raw
tomography files (as happened in August 2001). Problem was fixed by centering
the range of 'nday' days on the time of the last raw tomography file found in 'root'.
SEP-2002, Paul Hick (UCSD/CASS)
Fixed bug which prevented processing of anything other than 'nv3d' files
NOV-2003, Paul Hick (UCSD/CASS)
Added /gzip keyword.
NOV-2005, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Made sure that the start time for a new sequence of final files
always starts at a multiple of hour_step hours into the day.
[Previous]
[Next]
NAME:
vu_update_marker
PURPOSE:
Update set of 'best' tomography files at regular time intervals
(at the same time cadence used by the Fortran tomography itself)
by incorporating results of new tomography run.
CATEGORY:
Tomography I/O
CALLING SEQUENCE:
PRO vu_update_marker, prefix, $
silent = silent , $
rounds = rounds , $
gzip = gzip , $
final_destination = final_destination, $
last_is_best = last_is_best
INPUTS:
prefix scalar; type: character; default: 'nv3d'
file name prefix for data files
(typical values are 'nv3d','nv3f','wson','nson'
OPTIONAL INPUTS:
/last_is_best if set, the the last tomography run is taken
as the best one, i.e. it is not combined with
earlier runs using some weighted mean.
final_destination=final_destination
scalar; type: character; default: 'final'
subdirectory in $NAGOYA where the 'best'
files are written
silent=silent suppresses messages from vu_write
/gzip compresses output files with gzip (passed to vu_write)
OUTPUTS:
(written to new tomography data files)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, FILEPATH, InitVar, TimeGet, TimeOp, TimeUnit, forecast_cfg, hide_env, say
vu_mean, vu_prefix, vu_select, vu_set, vu_write
CALLED BY:
run_marker
PROCEDURE:
> Input files are picked up from directory $NAGOYA/fast/raw
Output files are written to $NAGOYA/fast/final (or the subdirectory
specified in keyword 'final_destination'.
> The procedure is run after a new time-dependent forecast has been
made. All output files from the last tomography (one for each time)
are integrated with the averages from results from previous runs
including the same times.
> vu_select is called with keywords /marker and /nohdr set, i.e.
only files with a rotation counter are picked up, and the file names
are returned without actually reading the headers.
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
NOV-2003, Paul Hick (UCSD/CASS)
Added /gzip keyword.
JUL-2011, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added keyword 'final_destination'
[Previous]
[Next]
NAME:
vu_vox_drawelatitude
PURPOSE:
Internal use by vu_vox_showeclipgrid only
CATEGORY:
Volume Pro board
CALLING SEQUENCE:
FUNCTION vu_vox_drawelatitude, F,ut,zero_lng,lat,cntr,dvox, obj_val
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, CvSky, gridgen
CALLED BY:
vu_vox_showeclipgrid
MODIFICATION HISTORY:
JUL-2002, Cindy Wang
[Previous]
[Next]
NAME:
vu_vox_drawelongitude
PURPOSE:
Internal use by vu_vox_showeclipgrid only
CATEGORY:
Volume Pro board
CALLING SEQUENCE:
FUNCTIOn vu_vox_drawelongitude, F,ut,zero_lng,earthlng,lng,cntr,dvox, obj_val
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, CvSky, gridgen
CALLED BY:
vu_vox_showeclipgrid
MODIFICATION HISTORY:
JUL-2002,Cindy Wang xin_wang02@hotmail.com
[Previous]
[Next]
NAME:
vu_vox_drawhcs
PURPOSE:
Internal use by vu_vox
CATEGORY:
CALLING SEQUENCE:
FUNCTION vu_vox_drawhcs, F, B, obj_val
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
ArrayLocation
CALLED BY:
vu_vox_write
MODIFICATION HISTORY:
SEP-2001, Kevin Nguyen, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_vox_drawhlatitude
PURPOSE:
Internal use by vu_vox_showheliogrid only
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, gridgen
CALLED BY:
vu_vox_showheliogrid
MODIFICATION HISTORY:
JUL-2002, Cindy Wang xin_wang02@hotmail.com
[Previous]
[Next]
NAME:
vu_vox_drawhlongitude
PURPOSE:
Internal use by vu_vox_showheliogrid only
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, gridgen
CALLED BY:
vu_vox_showheliogrid
MODIFICATION HISTORY:
JUL-2002, Cindy Wang
[Previous]
[Next]
NAME:
vu_vox_draworbit
PURPOSE:
Internal use by vu_vox only
CALLING SEQUENCE:
FUNCTION vu_vox_draworbit, F, ut, hdr, zero_lng, cntr, dvox, obj_val
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
CV_COORD, CvSky, TimeOp, TimeSet, big_eph, gridgen, jpl_body
CALLED BY:
vu_vox_write
MODIFICATION HISTORY:
SEP-2001, Kevin Nguyen, Paul Hick (UCSD/CASS)
OCT-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Replaced NewcombSun by big_eph
[Previous]
[Next]
NAME:
vu_vox_drawsphere
PURPOSE:
Internal use by vu_vox only
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to callers
CALLS: ***
InitVar, gridgen
CALLED BY:
vu_vox_write
MODIFICATION HISTORY:
SEP-2001, Kevin Nguyen, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_vox_read
PURPOSE:
Read binary file used for Volume Pro board
CATEGORY:
I/O
CALLING SEQUENCE:
count = vu_vox_read(files, volume=volume)
INPUTS:
files array; type: string
list of vox file names
If not specified then the IDL pickfile
dialog is called
OPTIONAL INPUT PARAMETERS:
OUTPUTS:
count scalar; type: integer
# volumes
volume array[count]; type: pointer
volume data
OPTIONAL OUTPUTS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
InitVar, IsType, TimeSet, flt_string, vox_read
PROCEDURE:
MODIFICATION HISTORY:
JUL-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_vox_sequence
PURPOSE:
Processes group of t3d files for Volume Pro board
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_vox_sequence, hdr, ff, _extra=_extra, silent=silent
INPUTS:
hdr array[k]; type: structure
information about the tomographic reconstruction
(single file or time-dependent sequence)
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,k,2]; type: float
3D volume data associated with 'hdr'
if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
All keywords of vu_vox_write are permitted.
OUTPUTS:
(vox files, one voxlist file)
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
GetFileSpec, InitVar, say, vu_vox_write
CALLED BY:
qvox
RESTRICTIONS:
M. Bailey's Volume Explorer program vx.exe must be located in
%SWW_SMEI%\win\exe
PROCEDURE:
MODIFICATION HISTORY:
JUL-2001, Paul Hick (UCSD/CASS)
NOV-2005, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Substantial rewrite. Instead of creating a DOS batch file
to run the vx.exe program with a list of input files on the
command line, now an ASCII file *.voxlist is created with
the names of all the vox files in it. The list files is written
into the same directory as the vox files themselves.
[Previous]
[Next]
NAME:
vu_vox_showeclipgrid
PURPOSE:
Internal use by vu_vox only
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
vu_vox_drawelatitude, vu_vox_drawelongitude
CALLED BY:
vu_vox_write
MODIFICATION HISTORY:
JUL-2002, Cindy Wang
[Previous]
[Next]
NAME:
vu_vox_showheliogrid
PURPOSE:
Internal use by vu_vox only
CATEGORY:
Volume Pro board
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
vu_vox_drawhlatitude, vu_vox_drawhlongitude
CALLED BY:
vu_vox_write
MODIFICATION HISTORY:
JUL-2002, Cindy Wang xin_wang02@hotmail.com
[Previous]
[Next]
NAME:
vu_vox_write
PURPOSE:
Convert ascii t3d file to vox file for Volume Pro board
CATEGORY:
sat/idl/util/vupack
CALLING SEQUENCE:
PRO vu_vox_write, hdr, ff, $
destination = destination , $
speed = speed , $
density = density , $
brad = brad , $
btang = btang , $
ndim = ndim , $
range = range , $
lngrange = lngrange , $
latrange = latrange , $
fix_sun = fix_sun , $
fix_earth = fix_earth , $
fix_stars = fix_stars , $
fix_ihg = fix_ihg , $
_extra = _extra , $
show_sun = show_sun , $
show_earth = show_earth , $
show_orbit = show_orbit , $
show_heliogrid = show_heliogrid, $
show_eclipgrid = show_eclipgrid, $
show_hcs = show_hcs , $
obj_val = obj_val , $
nodata = nodata , $
hdr_bb = hdr_bb , $
bb = bb , $
nearest = nearest , $
vox_files = vox_files , $
silent = silent , $
bb_filter = bb_filter
INPUTS:
hdr array[1]; type: structure
information about the tomographic reconstruction.
if 'hdr' does not exist, then user is prompted for
a data file using the 'pickfile' dialog.
ff array[n,m,l,2]; type: float
3D volume data; if not present then the files
specified in the 'hdr' argument are read.
OPTIONAL INPUT PARAMETERS:
ndim=ndim scalar; type: integer; default: 128
resolution of the binary file stored in the vox file
(128 or 256)
range=range scalar or array[2]; type: float; default=[0.0,1.5]
range of radial distances (AU) written to binary file.
Only the part of the array inside range[0],range[1] is
extracted and stored in the vox file.
lngrange=lngrange scalar or array[2];type;integer;default = [-180,180]
range of longitudes will be passed as a parameter to
functions of the show_heliogrid and show_eclipgrid
latrange=latrange scarlar or array[2];type;integer;default = [-90,90]
range of latitudes will be passed as a parameter to
functions of the show_heliogrid and show_eclipgrid
By default the start of the region of interest of a matrix is put along
the x-axis in the vox volume. For an animated sequence of vox files it is
important to set one of the following three keywords.
/fix_sun makes the x-y-z coordinates of the vox file coincide with
heliographic coordinates (i.e. heliographic longitude zero
is put along the x-axis)
/fix_earth puts the Sun-Earth direction along the x-axis
/fix_stars puts the heliographic longitude of the equinox (ecliptic
longitude zero, ecliptic latitude zero) on the x-axis
(i.e. uses a sidereal coordinate frame)
/fix_ihg puts the ascending node of the solar equator on the
ecliptic on the x-axis. This also is essentially
a sidereal coordinate frame (except for the slow motion
of the ascending node over time (1 deg per 72 year).
/speed if set, processes the velocity data
This is the default if neither /speed or /density are set.
/density if set, processes the density data
/bradial if set, process radial magnetic field
/btang if set, process tangential magnetic field
destination=destination
scalar; type: string; default: same directory as t3d file
Destination directory
Keywords for merging objects with volume data:
/show_sun show Sun at center of vox volume
/show_earth show Earth
/show_orbit show Earth's orbit
/show_heliogrid show longitudes and latitudes in heliographic coordinates
/show_eclipgrid show longitudes and latitudes in ecliptic coordinates
/show_hcs try to add current sheet
hdr_bb=hdr_bb, bb=bb
as an alternative to setting /show_hcs headers
and volume data for the magnetic field can be specified
directly using these two keywords.
obj_val=obj_val scalar; type: real; default: 1.1 x max value in volume data
Function values used to mark objects added to vox volume
with show_* keywords. The units are the same as used for
the volume data (e.g. km/s for velocity, cm^-3 for number
densities, etc.)
/nodata if set, the volume data are suppressed (by muliplying with
zero). (useful for showing merged objects only)
Additional keywords:
Keywords passed to vu_getdata are explained there.
Keywords passed to vox_write are explained there.
The most important ones are.
minf=minf these three keywords are used in vox_write to convert
maxf=maxf the volume data scale to byte (they are used as arguments
topb=topb to the idl 'bytscl' function).
OUTPUTS:
(*.vox file)
OPTIONAL OUTPUTS:
vox_files=vox_files array; type: string
list of file names of all vox files created
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
AngleRange, BadValue, CV_COORD, Carrington, CvSky, FILEPATH, GetFileSpec, InitVar
IsType, PutFileSpec, SetFileSpec, TimeGet, TimeOp, TimeSet, TimeUnit, big_eph, boost
destroyvar, gridgen, jpl_body, say, vox_write, vu_fnc, vu_get, vu_getdata, vu_prefix
vu_select, vu_type_insitu, vu_vox_drawhcs, vu_vox_draworbit, vu_vox_drawsphere
vu_vox_showeclipgrid, vu_vox_showheliogrid
CALLED BY:
vox_update, vu_vox_sequence
PROCEDURE:
> When processing a time sequence of tomography files one of the keywords
/fix_sun, /fix_earth, /fix_stars or /fix_ihg should be set, to control
the heliographic longitude that is put along the x-axis in the vox volume.
Also the minf, maxf and topb keywords should be used to make sure that the
same color scale is used for each of the images.
> The name of the vox file is based on the name of the t3d file
e.g. t3d_1962.345 will be output as t3d_1962_345.vox
The selected density or velocity matrix is used to calculate
function values on a Cartesian grid by linear interpolation.
MODIFICATION HISTORY:
JAN-2001, Paul Hick (UCSD/CASS)
SEP-2001, Kevin Nguyen, Paul Hick (UCSD/CASS)
Added options to merge objects (Sun, Earth, Earth's orbit)
Added option to add current sheet
JUL-2002, Cindy Wang
Added options to show grid in heliographic coordination
Added options to show grid in ecliptic coordination
JUN-2003, Paul Hick (UCSD/CASS)
Added postfix to name of output vox file, depending on type
of data (density, speed, etc.).
OCT-2006, Paul Hick (UCSD/CASS)
Replaced NewcombSun by big_eph
JUN-2006, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added /fix_ihg
[Previous]
[Next]
NAME:
vu_weight
PURPOSE:
Set weight to be used by vu_mean to get weighted mean
of 3D tomography data
CATEGORY:
Tomography
CALLING SEQUENCE:
FUNCTION vu_weight, t0, tt, triangle=triangle
INPUTS:
t0 array[1]; type: double
time origin as Carrington variable
tt array[*]; type: double
times for which weight factors are needed
(as Carrington variable)
OPTIONAL INPUT PARAMETERS:
triangle array[4]; type: double
parameters defining weight function
OUTPUTS:
ww array[*]; type: double
weight factors
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
IsType, TimeOp, TimeSet, TimeUnit
CALLED BY:
vu_new_time
PROCEDURE:
Units in triangle are fraction of Carrington rotation
triangle[0]: position of top of triangle
triangle[1]: left corner of triangle
triangle[2]: right corner of triangle
triangle[3]; weight at top of triangle
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_whatis
PURPOSE:
Summary of tomography file
CATEGORY:
CALLING SEQUENCE:
PRO vu_whatis, hdr, ff, histo=histo, _extra=_extra, $
sequence = sequence, $
minimum = minimum, $
maximum = maximum, $
good = good, $
what = what, $
silent = silent, $
ibeg = ibeg, $
iend = iend
INPUTS:
OPTIONAL INPUT PARAMETERS:
OUTPUTS:
OPTIONAL OUTPUT PARAMETERS:
INCLUDE
@compile_opt.pro ; On error, return to caller
CALLS: ***
Carrington, InitVar, TimeGet, TimeOp, TimeUnit, WhatIs, qBar, vu_fnc, vu_get, vu_getdata
vu_is_sequence, vu_type_insitu
PROCEDURE:
MODIFICATION HISTORY:
APR-2001, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
[Previous]
[Next]
NAME:
vu_write
PURPOSE:
Write tomography t3d* or b3d* file
CATEGORY:
Tomography: I/O
CALLING SEQUENCE:
PRO vu_write, in_hdr, in_ff , $
userinfo = userinfo , $
destination = destination , $
silent = silent , $
gzip = gzip
INPUTS:
in_hdr
in_ff
OPTIONAL INPUT PARAMETERS:
destination=destination
scalar; type: string
destination directory for output file
/gzip compresses output files with gzip
userinfo
OUTPUTS:
See PROCEDURE
OPTIONAL OUTPUT PARAMETERS:
INCLUDE:
@compile_opt.pro ; On error, return to caller
CALLS: ***
FILEPATH, GetFileSpec, InitVar, IsType, TimeGet, TimeSystem, TimeUnit, do_file
gzip_file, hide_env, say, vu_filename, vu_get
CALLED BY:
vu_new_time, vu_update_marker
SIDE EFFECTS:
RESTRICTIONS:
SEE PROCEDURE
EXAMPLE:
PROCEDURE:
The file name specified in in_hdr.file is ignored (usually
it is a blank string anyway). The filename is build from the
destination keywords in combination with the time hdr.time,
hdr.marker and hdr.prefix
MODIFICATION HISTORY:
MAR-2001, Paul Hick (UCSD/CASS)
JUL-2002, Paul Hick (UCSD/CASS)
V1.03; added nl, nlos, dlos and binx
NOV-2003, Paul Hick (UCSD/CASS; pphick@ucsd.edu)
Added /gzip keyword.
Also added a trick to avoid having two tomography files
for the same time present in the directory while the
new file is being written.