Wednesday, July 3, 2019: New Moon 3:17am (CST)
Tuesday, July 9, 2019: First Quarter Moon 6:57pm (CST)
Wednesday, July 17, 2019: Full Moon 5:35am (CST)
Thursday, July 25, 2019: Last Quarter Moon 9:25am (CST)
Thursday, August 1, 2019: New Moon 11:13am (CST)
(defun calendar-chinese-from-absolute (date)
"Compute Chinese date (cycle year month day) corresponding to absolute DATE.
The absolute date is the number of days elapsed since the (imaginary)
Gregorian date Sunday, December 31, 1 BC."
(let* ((g-year (calendar-extract-year
(calendar-gregorian-from-absolute date)))
(c-year (+ g-year 2695))
(list (append (calendar-chinese-year (1- g-year))
(calendar-chinese-year g-year)
(calendar-chinese-year (1+ g-year)))))
(while (<= (cadr (cadr list)) date)
;; The first month on the list is in Chinese year c-year.
;; Date is on or after start of second month on list...
(if (= 1 (caar (cdr list)))
;; Second month on list is a new Chinese year...
(setq c-year (1+ c-year)))
;; ...so first month on list is of no interest.
(setq list (cdr list)))
(list (/ (1- c-year) 60)
;; Remainder of c-year/60 with 60 instead of 0.
(1+ (mod (1- c-year) 60))
(caar list)
(1+ (- date (cadr (car list)))))))