Date Class Function Manual

DAY

| HOME | BACK |

Purpose

To report the current day of the Date object.

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

Class

Date

Usage

{int} ret  =  object.DAY()

Example:

->d = Date(1960,12,9,0.00)

->print d

  9/12/1960 Time: 0 00 00.0000000

->d.day()

  ans = 9

->

See also (class function)

month, year, time

| HOME | BACK |


DOW

| HOME | BACK |

Purpose

To compute the day of week of the Date object.

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

The result in a number representing day of week, as follows.

1 = Sunday

2 = Monday

3 = Tuesday

4 = Wednesday

5 = Thursday

6 = Friday

7 = Saturday

Class

Date

Usage

{double} ret  =  object.DOW()

Example:

->d = Date(1960,12,9,0.00)

->print d

  9/12/1960 Time: 0 00 00.0000000

->d.dow()

  ans = 6.000

->

See also (class function)

jd

| HOME | BACK |


INIT

| HOME | BACK |

Purpose

To initialize a Date object.

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

Class

Date

Usage

{void} ret  =  object.DOW({int} argm1, {int} argm2,{int} argm3, {double} argm4)

argm1 = year e.g. 1960

argm2 = month e.g. 12 (means December)

argm3 = day e.g. 9

argm4 = time e.g. 14.5   means 14h 30min 0.00 sec

Example:

->d = Date()

->d.init(1960,12,9,deg(12.30456789))

->print d

  9/12/1960 Time: 12 30 45.6789000

->

See also (class function)

day, month, year, time

| HOME | BACK |


JD

| HOME | BACK |

Purpose

To compute the julian day of the Date object. 

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

Algorithm is from Hofmann-Wellenhof, B et al (1997) Global Positioning System Theory and Practice, Springer Wien, New York.

Class

Date

Usage

{double} ret  =  object.JD()

Example:

->d = Date()

->d.init(1960,12,9,deg(12.30456789))

->print d

  9/12/1960 Time: 12 30 45.6789000

->d.jd()

  ans = 2437278.02136

->

See also (class function)

dow

| HOME | BACK |


MONTH

| HOME | BACK |

Purpose

To report the current month of the Date object.

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

Class

Date

Usage

{int} ret  =  object.MONTH()

Example:

->d = Date()

->d.init(1960,12,9,deg(12.30456789))

->print d

  9/12/1960 Time: 12 30 45.6789000

->d.month()

  ans = 12

->

See also (class function)

year, day, time

| HOME | BACK |


TIME

| HOME | BACK |

Purpose

To report the current time of the Date object.

Please pay attention that the time in the Date object is considered the GMT (Greenwich Mean Time) in all calculation.

Class

Date

Usage

{double} ret  =  object.TIME()

Example:

->d = Date()

->d.init(1960,12,9,deg(12.30456789))

->print d

  9/12/1960 Time: 12 30 45.6789000

->d.time()

  ans = 12.51269

->

See also (class function)

year month, day

| HOME | BACK |


YEAR

| HOME | BACK |

Purpose

To report the current year of the Date object.

Please pay attention that the time in the Date object is considered to be GMT (Greenwich Mean Time) in all calculation.

Class

Date

Usage

{int} ret  =  object.YEAR()

Example:

->d = Date()

->d.init(1960,12,9,deg(12.30456789))

->print d

  9/12/1960 Time: 12 30 45.6789000

->d.year()

  ans = 1960

->

See also (class function)

month, day, time

| HOME | BACK |