Documentation
¶
Index ¶
- Variables
- func Altitude(date time.Time, ra, dec, lon, lat float64) float64
- func ApparentAltitude(date time.Time, ra, dec, lon, lat, pressureHPa, temperatureC float64) float64
- func ApparentSiderealTime(date time.Time) float64
- func ApparentZenith(date time.Time, ra, dec, lon, lat, pressureHPa, temperatureC float64) float64
- func Azimuth(date time.Time, ra, dec, lon, lat float64) float64
- func Constellation(ra, dec float64, date time.Time) string
- func ConstellationCode(ra, dec float64, date time.Time) string
- func ConstellationEN(ra, dec float64, date time.Time) string
- func CulminationTime(date time.Time, ra, lon float64) time.Time
- func DownTime(date time.Time, ra, dec, lon, lat, height float64, aero bool) (time.Time, error)deprecated
- func HourAngle(date time.Time, ra, lon float64) float64
- func InitStarDatabase() error
- func MeanSiderealTime(date time.Time) float64
- func ParallacticAngle(date time.Time, ra, dec, lon, lat float64) float64
- func RiseTime(date time.Time, ra, dec, lon, lat, height float64, aero bool) (time.Time, error)
- func SetTime(date time.Time, ra, dec, lon, lat, height float64, aero bool) (time.Time, error)
- func StarDataByHR(hr int) (basic.StarData, error)
- func StarDataByName(name string) (basic.StarData, error)
- func TopBrightStars() ([]basic.StarData, error)
- func Zenith(date time.Time, ra, dec, lon, lat float64) float64
Constants ¶
This section is empty.
Variables ¶
var ( ERR_STAR_NEVER_RISE = errors.New("ERROR:极夜,星星在今日永远在地平线下!") ERR_STAR_NEVER_SET = errors.New("ERROR:极昼,星星在今日永远在地平线上!") // ERR_STAR_NEVER_DOWN deprecated: -- use ERR_STAR_NEVER_SET instead ERR_STAR_NEVER_DOWN = ERR_STAR_NEVER_SET )
Functions ¶
func Altitude ¶ added in v0.1.0
Altitude 恒星高度角 / stellar altitude.
ra/dec 为瞬时赤经赤纬,单位度;lon/lat 为观测者经纬度,东正西负、北正南负;返回值单位度。 ra/dec are apparent equatorial coordinates in degrees; lon/lat are east-positive and north-positive; the result is in degrees.
func ApparentAltitude ¶ added in v0.1.0
ApparentAltitude 恒星视高度角 / apparent stellar altitude.
func ApparentSiderealTime ¶
ApparentSiderealTime 真恒星时 / apparent sidereal time.
返回 date 对应绝对时刻的格林尼治真恒星时,单位小时。 Returns Greenwich apparent sidereal time at the instant represented by date, in hours.
func ApparentZenith ¶ added in v0.1.0
ApparentZenith 恒星视天顶距 / apparent stellar zenith distance.
func Azimuth ¶
Azimuth 恒星方位角 / azimuth.
ra/dec 为瞬时赤经赤纬,单位度;lon/lat 为观测者经纬度,东正西负、北正南负;返回值按正北为 0°、向东增加。 ra/dec are apparent equatorial coordinates in degrees; lon/lat are east-positive and north-positive; azimuth is measured from north toward east.
func Constellation ¶
Constellation 星座中文名 / Chinese constellation name.
ra/dec 为给定时刻的赤经赤纬,单位度;date 作为所属历元使用。 ra/dec are equatorial coordinates in degrees and date provides the epoch used by the constellation boundaries.
func ConstellationCode ¶ added in v0.1.0
ConstellationCode IAU 星座代码 / IAU constellation code.
ra/dec 为给定时刻的赤经赤纬,单位度;date 作为所属历元使用。 ra/dec are equatorial coordinates in degrees and date provides the epoch used by the constellation boundaries.
func ConstellationEN ¶ added in v0.1.0
ConstellationEN 星座英文名 / English constellation name.
ra/dec 为给定时刻的赤经赤纬,单位度;date 作为所属历元使用。 ra/dec are equatorial coordinates in degrees and date provides the epoch used by the constellation boundaries.
func CulminationTime ¶
CulminationTime 恒星中天时刻 / culmination time.
date 取其所在时区的当地日期,返回值保持相同时区;ra 为瞬时赤经,单位度;lon 为观测者经度,东正西负。 date is interpreted on its local civil day and the result keeps the same time zone. ra is the apparent right ascension in degrees and lon is east-positive longitude.
func HourAngle ¶
HourAngle 恒星时角 / hour angle.
ra 为瞬时赤经,单位度;lon 为观测者经度,东正西负;date 为观测时刻,会读取其时区参与地方时计算。 ra is the apparent right ascension in degrees; lon is east-positive longitude; date is the observing instant and its zone offset participates in local-time calculations.
func InitStarDatabase ¶
func InitStarDatabase() error
InitStarDatabase 初始化恒星数据库 / initializes the embedded star catalog.
func MeanSiderealTime ¶
MeanSiderealTime 平恒星时 / mean sidereal time.
返回 date 对应绝对时刻的格林尼治平恒星时,单位小时。 Returns Greenwich mean sidereal time at the instant represented by date, in hours.
func ParallacticAngle ¶ added in v0.1.0
ParallacticAngle 恒星视差角(天顶方向角) / stellar parallactic angle.
ra/dec 为瞬时赤经赤纬,单位度;lon/lat 为观测者经纬度,东正西负、北正南负。 返回值为有符号视差角,单位度。
func RiseTime ¶
RiseTime 恒星升起时刻 / stellar rise time.
date 取其所在时区的当地日期,返回值保持相同时区;ra/dec 为该日期附近使用的瞬时赤经赤纬,单位度; lon/lat 为观测者经纬度,东正西负、北正南负;height 为海拔高度,单位米;aero 为 true 时加入标准大气折射。 date is interpreted on its local civil day and the result keeps the same time zone. ra/dec are apparent coordinates in degrees; lon/lat are east-positive and north-positive, height is observer elevation in meters, and aero enables standard atmospheric refraction.
func SetTime ¶
SetTime 恒星落下时刻 / stellar set time.
参数与 RiseTime 相同,返回给定当地日期内的落下时刻。 Uses the same inputs as RiseTime and returns the set time on the corresponding local civil day.
func StarDataByHR ¶
StarDataByHR 按 HR 编号查询恒星数据 / returns star data by HR number.
func StarDataByName ¶
StarDataByName 按中文名查询恒星数据 / returns star data by Chinese name.
func TopBrightStars ¶
TopBrightStars 明亮恒星样本 / bright-star sample list.
返回按视星等大致由亮到暗排列、视星等约不高于 3 的内置恒星数据。 Returns the built-in bright-star sample, roughly ordered from brighter to dimmer and limited to stars around magnitude 3 or brighter.
Types ¶
This section is empty.