Class: When::CalendarNote::Japanese::SolarTerms

Inherits:
SolarTerms show all
Defined in:
lib/when_exe/region/japanese/notes.rb

Overview

太陽黄経による暦注

Direct Known Subclasses

SolarTermsRevised

Constant Summary collapse

Notes12 =
%w(正月 二月 三月 四月 五月 六月 七月 八月 九月 十月 十一月 十二月)
Notes10 =
[
%w(初伏 初伏),
%w(仲伏 中伏),
%w(後伏 末伏)
Notes60_A =
[
  #  +0      
  '侯小過外', # 315 : 正月
  '侯需外',   # 345 : 二月
  '侯豫外',   #  15 : 三月
  '侯旅外',   #  45 : 四月
  '侯大有外', #  75 : 五月
  '侯鼎外',   # 105 : 六月
  '侯恆外',   # 135 : 七月
  '侯巽外',   # 165 : 八月
  '侯歸妹外', # 195 : 九月
  '侯艮外',   # 225 : 十月
  '侯未濟外', # 255 : 十一月
  '侯屯外'    # 285 : 十二月
]
Notes60_B =
[
  #  +3          +9       +15       +21       +27
  '大夫蒙',   '卿益',   '公漸',   '辟泰',   '侯需内',   # 315 : 正月
  '大夫随',   '卿晋',   '公解',   '辟大壯', '侯豫内',   # 345 : 二月
  '大夫訟',   '卿蠱',   '公革',   '辟夬',   '侯旅内',   #  15 : 三月
  '大夫師',   '卿比',   '公小畜', '辟乾',   '侯大有内', #  45 : 四月
  '大夫家人', '卿井',   '公咸',   '辟姤',   '侯鼎内',   #  75 : 五月
  '大夫豊',   '卿渙',   '公履',   '辟遯',   '侯恆内',   # 105 : 六月
  '大夫節',   '卿同人', '公損',   '辟否',   '侯巽内',   # 135 : 七月
  '大夫萃',   '卿大畜', '公賁',   '辟観',   '侯歸妹内', # 165 : 八月
  '大夫無妄', '卿明夷', '公困',   '辟剥',   '侯艮内',   # 195 : 九月
  '大夫既濟', '卿噬嗑', '公大過', '辟坤',   '侯未濟内', # 225 : 十月
  '大不蹇',   '卿頤',   '公中孚', '辟復',   '侯屯内',   # 255 : 十一月
  '大夫謙',   '卿睽',   '公升',   '辟臨',   '侯小過内'  # 285 : 十二月
]
Notes72 =
[
      # 儀鳳暦         宣明暦(中国)       宣明暦            貞享暦   宝暦暦・寛政暦 略本暦
      # 315 : 正月
%w(雞始乳       東風解凍          東風解凍          東風解凍     東風解凍   東風解凍),
%w(東風解凍     蟄始振            蟄虫始振          梅花乃芳     黄鶯睍睆   黄鶯睍睆),
%w(蟄蟲始振     魚上氷            魚上氷            魚上氷       魚上氷     魚上氷),
%w(魚上冰       獺祭魚            獺祭魚            土脈潤起     土脈潤起   土脉潤起),
%w(獺祭魚       鴻雁来            鴻雁来            霞彩碧空     霞始靆     霞始靆),
%w(鴻雁來       草木萌動          草木萌動          草木萌動     草木萌動   草木萌動),

      # 345 : 二月
%w(始雨水       桃始華            桃始華            蟄虫啓戸     蟄虫啓戸   蟄虫啓戸),
%w(桃始花       倉庚鳴            倉庚鳴            寒雨間熟     桃始笑     桃始笑),
%w(倉庚鳴       鷹化爲鳩          鷹化爲鳩          菜虫化蝶     菜虫化蝶   菜虫化蝶),
%w(鷹化爲鳩     玄鳥至            玄鳥至            雀始巣       雀始巣     雀始巣),
%w(玄鳥至       雷乃發聲          雷乃發聲          雷乃発声     桜始開     桜始開),
%w(雷始發聲     始電              始電              桜始開桃始笑 雷乃発声   雷乃発声),

      #  15 : 三月
%w(始雷         桐始華            桐始華            玄鳥至       玄鳥至     玄鳥至),
%w(蟄蟲咸動     田鼠化爲鴑        田鼠化爲鴑        鴻雁北       鴻雁北     鴻雁北),
%w(蟄蟲啓戸     虹始見            虹始見            虹始見       虹始見     虹始見),
%w(桐始華       萍始生            萍始生            葭始生       葭始生     葭始生),
%w(田鼠化爲鴑   鳴鳩拂其羽        鳴鳩拂其羽        牡丹華       霜止出苗   霜止出苗),
%w(虹始見       戴勝降于桑        戴勝降于桑        霜止出苗     牡丹華     牡丹華),

      #  45 : 四月
%w(萍始生       螻蟈鳴            螻蟈鳴            鵑始鳴       鼃始鳴     鼃始鳴),
%w(戴勝降于桑   蚯蚓出            蚯蚓出            蚯蚓出       蚯蚓出     蚯蚓出),
%w(螻蟈鳴       王瓜生            王瓜生            竹笋生       竹笋生     竹笋生),
%w(蚯蚓出       苦菜秀            苦菜秀            蚕起食桑     蚕起食桑   蚕起食桑),
%w(王瓜生       靡草死            靡草死            紅花栄       紅花栄     紅花栄),
%w(苦菜秀       小暑至            小暑至            麦秋至       麦秋至     麦秋至),
   
      #  75 : 五月
%w(靡草死       螳蜋生            螳蜋生            螳螂生       螳螂生     螳螂生),
%w(小暑至       鵙始鳴            鵙始鳴            腐草為螢     腐草為螢   腐草為螢),
%w(螳螂生       反舌無聲          反舌無聲          梅始黄       梅子黄     梅子黄),
%w(鵙始鳴       鹿角解            鹿角解            乃東枯       乃東枯     乃東枯),
%w(反舌無聲     蜩始鳴            蜩始鳴            分龍雨       菖蒲華     菖蒲華),
%w(鹿角解       半夏生            半夏生            半夏生       半夏生     半夏生),

      # 105 : 六月
%w(蟬始鳴       温風至            温風至            温風至       温風至     温風至),
%w(半夏生       蟋蟀居壁          蟋蟀居壁          蓮始華       蓮始華     蓮始開),
%w(木槿榮       鷹乃學習          鷹乃學習          鷹乃学習     鷹乃学習   鷹乃学習),
%w(温風至       腐草爲螢          腐草爲螢          桐始結花     桐始結花   桐始結花),
%w(蟋蟀居壁     土潤溽暑          土潤溽暑          土潤溽暑     土潤溽暑   土潤溽暑),
%w(鷹乃學習     大雨時行          大雨時行          大雨時行     大雨時行   大雨時行),

      # 135 : 七月
%w(腐草爲螢     涼風至            涼風至            涼風至       涼風至     涼風至),
%w(土潤溽暑     白露降            白露降            山沢浮雲     寒蝉鳴     寒蝉鳴),
%w(涼風至       寒蟬鳴            寒蟬鳴            霧色已成     蒙霧升降   蒙霧升降),
%w(白露降       鷹乃祭鳥          鷹乃祭鳥          寒蝉鳴       綿柎開     綿柎開),
%w(寒蟬鳴       天地始肅          天地始肅          天地始粛     天地始粛   天地始粛),
%w(鷹祭鳥       禾乃登            禾乃登            禾乃登       禾乃登     禾乃登),

      # 165 : 八月
%w(天地始肅     鴻雁来            鴻雁来            草露白       草露白     草露白),
%w(暴風至       玄鳥歸            玄鳥歸            鶺鴒鳴       鶺鴒鳴     鶺鴒鳴),
%w(鴻雁來       群鳥養羞          群鳥養羞          玄鳥去       玄鳥去     玄鳥去),
%w(玄鳥歸       雷乃收聲          雷乃收聲          鴻雁来       雷乃収声   雷乃収声),
%w(羣鳥養羞     蟄蟲坏戸          蟄蟲坏戸          蟄虫坏戸     蟄虫坏戸   蟄虫坏戸),
%w(雷始收聲     水始涸            水始涸            水始涸       水始涸     水始涸),

      # 195 : 九月
%w(蟄蟲坏戸     鴻雁來賓          鴻雁來賓          棗栗零       鴻雁来     鴻雁来),
%w(陰氣方盛     雀入大水爲蛤      雀入大水爲蛤      蟋蟀在戸     菊花開     菊花開),
%w(陽氣始衰     菊有黄花          菊有黄花          菊花開       蟋蟀在戸   蟋蟀在戸),
%w(水始涸       豺乃祭獸          豺乃祭獸          霜始降       霜始降     霜始降),
%w(鴻雁來賓     草木黄落          草木黄落          蔦楓紅葉     霎時施     霎時施),
%w(雀入水爲蛤   蟄蟲咸俯          蟄蟲咸俯          鶯雛鳴       楓蔦黄     楓蔦黄),

      # 225 : 十月
%w(菊有黄花     水始冰            水始冰            山茶始開     山茶始開   山茶始開),
%w(豺祭獣       地始凍            地始凍            地始凍       地始凍     地始凍),
%w(水始冰       野雞入大水爲蜃    野雞入大水爲蜃    霎乃降       金盞香     金盞香),
%w(地始凍       虹藏不見          虹藏不見          虹蔵不見     虹蔵不見   虹蔵不見),
%w(野雞入水爲蜃 天氣上騰地氣下降  天氣上騰地氣下降  樹葉咸落     朔風払葉   朔風払葉),
%w(虹藏不見     閉塞而成冬        閉塞而成冬        橘始黄       橘始黄     橘始黄),

      # 255 : 十一月
%w(冰益壯       鶡鳥不鳴          鶡鳥不鳴          閉塞成冬     閉塞成冬   閉塞成冬),
%w(地始坼       虎始交            虎始交            熊蟄穴       熊蟄穴     熊蟄穴),
%w(鶡鳥不鳴     茘挺生            茘挺生            水仙開       鱖魚群     鱖魚群),
%w(虎始交       蚯蚓結            蚯蚓結            乃東生       乃東生     乃東生),
%w(芒始生       麋角解            麋角解            麋角解       麋角解     麋角解),
%w(茘挺生       水泉動            水泉動            雪下出麦     雪下出麦   雪下出麦),

      # 285 : 十二月
%w(蚯蚓結       雁北郷            雁北郷            芹乃栄       芹乃栄     芹乃栄),
%w(麋角解       鵲始巣            鵲始巣            風気乃行     水泉動     水泉動),
%w(水泉動       野雞始鴝          野雞始鴝          雉始雊       雉始雊     雉始雊),
%w(雁北郷       雞始乳            雞始乳            款冬華       款冬華     款冬華),
%w(鵲始巣       鷙鳥厲疾          鷙鳥厲疾          水沢腹堅     水沢腹堅   水沢腹堅),
%w(雉始雊       水澤腹堅          水澤腹堅          鶏始乳       鶏始乳     鶏始乳)
Patch =

計算結果の修正

{
  2039054 => [149.0, 1], # 貞観12(0870).07.17 [149.0, 0] 没
  2039055 => [150.0, 0], # 貞観12(0870).07.18 [150.0, 1] 処暑

  2107233 => [ 29.0, 1], # 天喜05(1057).03.10 [ 29.0, 0] 没
  2107234 => [ 30.0, 0], # 天喜05(1057).03.11 [ 30.0, 1] 穀雨

  2160437 => [269.0, 0], # 建仁02(1202).10=29 [270.0, 1] 冬至
  2160438 => [270.0, 1], # 建仁02(1202).11.01 [271.0, 1]
  2160439 => [271.0, 1], # 建仁02(1202).11.02 [272.0, 1]
  2160440 => [272.0, 1], # 建仁02(1202).11.03 [272.0, 0] 没

  2175412 => [269.0, 1], # 寛元01(1243).11.03 [269.0, 0] 没
  2175413 => [270.0, 0], # 寛元01(1243).11.04 [270.0, 1] 冬至

  2189200 => [179.0, 0], # 弘安04(1281).07=30 [180.0, 1] 秋分
  2189201 => [180.0, 1], # 弘安04(1281).08.01 [181.0, 1]
  2189202 => [181.0, 1], # 弘安04(1281).08.02 [181.0, 0] 没

  2243577 => [136.0, 0], # 永享02(1430).07.11 [136.0, 1] (立秋の翌日)
  2243578 => [136.0, 1], # 永享02(1430).07.12 [137.0, 1]
  2243579 => [137.0, 1], # 永享02(1430).07.13 [138.0, 1]
  2243580 => [138.0, 1], # 永享02(1430).07.14 [139.0, 1]
  2243581 => [139.0, 1], # 永享02(1430).07.15 [140.0, 1]
  2243582 => [140.0, 1], # 永享02(1430).07.16 [141.0, 1]
  2243583 => [141.0, 1], # 永享02(1430).07.17 [142.0, 1]
  2243584 => [142.0, 1], # 永享02(1430).07.18 [143.0, 1]
  2243585 => [143.0, 1], # 永享02(1430).07.19 [144.0, 1]
  2243586 => [144.0, 1], # 永享02(1430).07.20 [145.0, 1]
  2243587 => [145.0, 1], # 永享02(1430).07.21 [146.0, 1]
  2243588 => [146.0, 1], # 永享02(1430).07.22 [147.0, 1]
  2243589 => [147.0, 1], # 永享02(1430).07.23 [148.0, 1]
  2243590 => [148.0, 1], # 永享02(1430).07.24 [149.0, 1]
  2243591 => [149.0, 1], # 永享02(1430).07.25 [149.0, 0] 没 (処暑の前日)

  2311770 => [ 29.0, 1], # 元和03(1617).03.18 [ 29.0, 0] 没
  2311771 => [ 30.0, 0], # 元和03(1617).03.19 [ 30.0, 1] 穀雨

  2396062 => [314.0, 0], # 弘化04(1847).12.30 [315.0, 1] 立春 (計算誤差の補正)
  2396063 => [315.0, 1], # 弘化05(1848).01.01 [315.0, 0] 没

  2397583 => [ 15.0, 1], # 嘉永05(1852).02=15 [ 14.0, 0] 没
  2397584 => [ 16.0, 0], # 嘉永05(1852).02=16 [ 15.0, 1] 清明 (計算誤差の補正)

  2451110 => [210.0, 1], # 平成10(1998).10.23 [209.0, 0] 没
  2451111 => [211.0, 0], # 平成10(1998).10.24 [210.0, 1] 霜降 (計算誤差の補正)

  2459950 => [284.0, 0], # 令和05(2023).01.05 [285.0, 1] 小寒 (計算誤差の補正)
  2459951 => [285.0, 1], # 令和05(2023).01.06 [285.0, 0] 没

  2460651 => [254.0, 0], # 令和06(2024).12.06 [255.0, 1] 大雪 (計算誤差の補正)
  2460652 => [255.0, 1], # 令和06(2024).12.07 [255.0, 0] 没

  2461031 => [269.0, 0], # 令和07(2025).12.21 [270.0, 1] 冬至 (計算誤差の補正)
  2461032 => [270.0, 1]  # 令和07(2025).12.22 [270.0, 0] 没
}

Constants inherited from When::CalendarNote

Bahai, CalendarDepend, Chinese, CommonWithRokuyo, CommonWithSovietFiveDay, CommonWithSovietSixDay, Default, HashProperty, When::CalendarNote::Javanese, When::CalendarNote::JulianDay, Mayan, Tibetan, Yis

Constants included from Parts::Resource

Parts::Resource::ConstList, Parts::Resource::ConstTypes, Parts::Resource::IRIDecode, Parts::Resource::IRIDecodeTable, Parts::Resource::IRIEncode, Parts::Resource::IRIEncodeTable, Parts::Resource::IRIHeader, Parts::Resource::LabelProperty

Constants included from Namespace

Namespace::DC, Namespace::DCQ, Namespace::DCT, Namespace::FOAF, Namespace::OWL, Namespace::RDF, Namespace::RDFC, Namespace::RDFS, Namespace::RSS, Namespace::XSD

Class Attribute Summary collapse

Attributes inherited from LuniSolarPositions

#delta, #den, #formula, #margin, #num

Attributes inherited from When::CalendarNote

#event

Attributes inherited from TM::ReferenceSystem

#domain_of_validity, #position

Attributes inherited from BasicTypes::Object

#label

Attributes included from Parts::Resource

#_pool, #child, #keys, #locale, #namespace

Class Method Summary collapse

Methods inherited from LuniSolarPositions

_setup_, _setup_info, #event_eval, #event_time, #position

Methods inherited from When::CalendarNote

#copy, #day, #duration, #enum_for, #include?, #month, #note?, #notes, #year

Methods inherited from TM::ReferenceSystem

#domain, #name

Methods included from Parts::Resource

#[], #^, _abbreviation_to_iri, _decode, _encode, _extract_prefix, _instance, _instantiate, _parse, _path_with_prefix, _replace_tags, _setup_, _setup_info, _simplify_path, base_uri, #each, #enum_for, #hierarchy, #include?, #included?, #iri, #leaf?, #m17n, #map, #parent, #registered?, root_dir

Methods included from Parts::Resource::Pool

#[], #[]=, #_pool, #_setup_, #pool_keys

Methods included from Parts::Resource::Synchronize

#synchronize

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class When::Parts::Resource

Class Attribute Details

.patch=(value) ⇒ Object (writeonly)

テスト用の属性



1300
1301
1302
# File 'lib/when_exe/region/japanese/notes.rb', line 1300

def patch=(value)
  @patch = value
end

Class Method Details

._day_notes(notes, dates, conditions = {}) ⇒ Object

日の暦注



1305
1306
1307
1308
1309
1310
1311
1312
1313
1314
1315
1316
1317
1318
1319
1320
1321
1322
1323
1324
1325
1326
1327
1328
1329
1330
1331
1332
1333
1334
1335
1336
1337
1338
1339
1340
1341
1342
1343
1344
1345
1346
1347
1348
1349
1350
1351
1352
1353
1354
1355
1356
1357
1358
1359
1360
1361
1362
1363
1364
1365
1366
1367
1368
1369
1370
1371
1372
1373
1374
1375
1376
1377
1378
1379
1380
1381
1382
1383
1384
1385
1386
1387
1388
1389
1390
1391
1392
1393
1394
1395
1396
1397
1398
1399
1400
1401
1402
1403
1404
1405
1406
1407
1408
1409
1410
1411
1412
1413
1414
1415
1416
1417
1418
1419
1420
1421
1422
1423
1424
1425
1426
1427
1428
1429
1430
1431
1432
1433
1434
1435
1436
1437
1438
1439
1440
1441
1442
1443
1444
1445
1446
1447
1448
1449
1450
1451
1452
1453
1454
1455
1456
1457
1458
1459
1460
1461
1462
1463
1464
1465
1466
1467
1468
1469
1470
1471
1472
1473
1474
1475
1476
1477
1478
1479
1480
1481
1482
1483
1484
1485
1486
1487
1488
1489
1490
1491
1492
1493
1494
1495
1496
1497
1498
1499
1500
1501
1502
1503
1504
1505
1506
1507
1508
1509
1510
1511
1512
1513
1514
1515
1516
1517
1518
1519
1520
# File 'lib/when_exe/region/japanese/notes.rb', line 1305

def _day_notes(notes, dates, conditions={})
  date  = When.when?(dates.o_date.to_cal_date.to_s,
            {:frame=>dates.o_date.frame,
             :clock=>dates.s_date.frame._time_basis[0]})
  patch = (@patch || Patch)[date.to_i] unless dates.o_date.frame.respond_to?(:twin) &&
                                              dates.o_date.frame.twin
  date_without_era = date.without_era
  longitude, motsu = patch ? patch : dates.cal4note.s_terms.position(date)

  # 三伏 - 庚
  #
  # 初 : 夏至から 20..29
  # 仲 : 夏至から 30..39
  # 後 : 立秋から  0..9 
  if !notes['三伏'] && notes[''].remainder == 6 # 庚
    index = dates.range >= 11 ? 1 : 0
    if 109 <= longitude && longitude <= 129      # 夏至から
      term = dates.cal4note.s_terms.term(date_without_era, [-270,360])
      diff = dates.s_date.to_i - term.to_i
      notes['三伏'] = Notes10[0][index] if 20 <= diff && diff <= 29
      notes['三伏'] = Notes10[1][index] if 30 <= diff && diff <= 39
    elsif longitude == 135                     # 立秋
      notes['三伏'] = Notes10[2][index]
    elsif 136 <= longitude && longitude <= 144 # 立秋から
      term = dates.cal4note.s_terms.term(date_without_era, [-225,360])
      diff = dates.s_date.to_i - term.to_i
      notes['三伏'] = Notes10[2][index] if 0 < diff && diff <= 9
    end
  end

  # 社 - 戊
  #
  # 春秋分から -5..4
  if !notes[''] && notes[''].remainder == 4 # 戊
    if (longitude + 5) % 180 < 10 # 春秋分の近傍
      term = dates.cal4note.s_terms.term(date_without_era - When.Duration('P5D'), [0,180])
      diff = dates.s_date.to_i - term.to_i
      notes[''] = '' if -5 <= diff && diff <= 4
    end
  end

  # 臘 - 辰
  #
  # 小寒から 12..23
  if !notes[''] && notes[''].remainder == 4 # 辰
    if (longitude - 295) % 360 < 15 # 大寒の近傍
      term = dates.cal4note.s_terms.term(date_without_era - When.Duration('P25D'), [285,360])
      diff = dates.s_date.to_i - term.to_i
      notes[''] = '' if 12 <= diff && diff <= 23
    end
  end

  # 土用事
  unless notes['土用事']
    _longitude, _motsu = dates.cal4note.s_terms2.instance_of?(self) && dates.cal4note.doyo == 0 ? [longitude, motsu] :
                         dates.cal4note.s_terms2.position(date, -dates.cal4note.doyo)
    if _motsu != 0 && _longitude % 90 == 27
      notes['土用事'] =
        begin
          event_name =
            case dates.range
            when 0     ; '土用'   # 元嘉暦以前
            when 1     ; '土王'   # 麟徳暦
            when 2..10 ; '土用事' # 大衍暦~宣明暦
            else       ; '土用入' # 貞享暦以降
            end
          if conditions[:shoyo]
            dates.cal4note.s_terms2.event_time(date, event_name, [27-dates.cal4note.doyo, 90])
          else
            event_name
          end
        end
    end
  end

  # 入梅 - 壬
  #
  # 貞享2(1685)~ 芒種から 1..10 日の壬の日
  # 元文5(1740)~ 芒種から 0..9  日の壬の日
  # 明治9(1876)~ 太陽黄経80度
  unless notes['入梅']
    if dates.year >= 1876
      notes['入梅'] = '入梅' if longitude == 80 && motsu == 1
    elsif notes[''].remainder == 8 # 壬
      if (longitude - 75) % 360 <= 10 # 芒種の近傍
        term  = dates.cal4note.s_terms.term(date_without_era - When.Duration('P11D'), [75,360])
        diff  = dates.s_date.to_i - term.to_i
        diff += 1 if dates.year >= 1740
        notes['入梅'] = '入梅' if dates.range >= 11 && 1 <= diff && diff <= 10
      end
    end
  end

  # 半夏生
  #
  # 太陽黄経100度
  notes['半夏生'] ||= '半夏生' if longitude == 100 && motsu == 1

  # 立春を起算日とする雑節
  #
  unless notes['節分'] && notes['八十八夜'] && notes['二百十日'] && notes['二百廿日']
    term = dates.cal4note.s_terms.term(date_without_era + When.Duration('P3D'), [-45,360])
    case dates.s_date.to_i - term.to_i
    when  -1 ; notes['節分']     ||= '節分'
    when  87 ; notes['八十八夜'] ||= '八十八夜'
    when 209 ; notes['二百十日'] ||= '二百十日'
    when 219 ; notes['二百廿日'] ||= '二百廿日'
    end
  end

  # 日食
  unless notes['日食'] && notes['小字注']
    level = (conditions[:solar_eclipse]||0).to_i
    if level == -1
      note = nil
    else
      key  = dates.m_date.to_s[/\(.+\z/]
      if key
        note, = Japanese::Eclipse::Eclipses[key.gsub(/[()]/,'')]
      elsif dates.o_date.location &&
            dates.o_date.frame.kind_of?(When::CalendarTypes::Christian)
        info  = dates.o_date.location.solar_eclipse(date..date)
        note  = '' + Japanese::Eclipse.eclipse_summary(info[0]) unless info.empty?
      end
      if note
        note.sub!(/\*.*\z/, '')
        note  = nil unless // =~ note
        note  = nil if level[0] == 1 && //  =~ note
        note  = nil if level[1] == 1 && /^\(/ =~ note
      end
    end
    notes['日食'] = note
  end

  # 彼岸
  unless notes['彼岸']
    if dates.range < 11
      notes['彼岸'] = '彼岸' if longitude % 180 == 2 # 宣明暦以前(没を除いて3日後)
    else
      term = dates.cal4note.s_terms.term(date_without_era - When.Duration('P7D'), [0,180]) # 近傍の春秋分
      case dates.s_date.to_i - term.to_i
      when  2 ; notes['彼岸'] = '彼岸' if dates.range == 11 # 貞享暦(没を含めて3日後)
      when -5 ; notes['彼岸'] = '彼岸' if longitude >  180 && (1755...1844).include?(dates.year) # 宝暦暦・寛政暦(春-6日前))
      when -1 ; notes['彼岸'] = '彼岸' if longitude <= 180 && (1755...1844).include?(dates.year) # 宝暦暦・寛政暦(秋-2日前)
      when -3 ; notes['彼岸'] = (dates.range < 14 ? '彼岸' : '彼岸入り') if dates.year >= 1844   # 天保暦以降(秋-4日前)
      when  0 ; notes['彼岸'] = '彼岸の中日' if dates.range >= 14 # 明治改暦以降
      when +3 ; notes['彼岸'] = '彼岸明け'   if dates.range >= 14 # 明治改暦以降
      end
    end
    notes['彼岸'] = nil unless /彼岸/ =~ notes['彼岸']
  end

  # 土用の丑
  if !notes['土用の丑'] && notes[''].remainder == 1 # 丑
    first  = dates.cal4note.s_terms.term(date_without_era - When.Duration('P20D'), [117,360]) # 夏の土用
    last   = dates.cal4note.s_terms.term(date_without_era - When.Duration('P20D'), [135,360]) # 立夏
    length = last.to_i - first.to_i
    diff   = dates.s_date.to_i - first.to_i
    notes['土用の丑'] = '土用の丑'   if  0 <= diff && diff < 12
    notes['土用の丑'] = '土用二の丑' if 12 <= diff && diff < length
    notes['土用の丑'] = nil unless /土用/ =~ notes['土用の丑']
  end

  # 没
  if motsu == 0
    notes[''] = dates.range < 11 ? '' : nil
    return notes unless patch
  else
    notes[''] = nil
  end

  # 廿四節気
  div, mod = longitude.divmod(15)
  if mod == 0
    note = (div - 21) % 24
    div, mod = note.divmod(2)
    notes['節中']     ||= Notes12[div] + %w( )[mod]
    notes['廿四節気'] ||= 
      begin
        residue = When.Resource(dates.range == 1 ? '_co:Common?V=0618' : '_co:Common')['二十四節気::*'][(note-3) % 24]
        if conditions[:shoyo]
          dates.cal4note.s_terms.event_time(date, residue.label, [0,15])
        else
          residue
        end
      end
  end

  # 七十二候
  div, mod = longitude.divmod(5)
  notes['七十二候'] ||= mod == 0  ? Notes72[(div - 63) % 72][dates.index_s]  : nil

  # 往亡
  unless notes['往亡'] && notes['神吉'] && notes['雑事吉']
    month    = dates.s_date.cal_date[-2] - 1
    day      = dates.s_date.cal_date[-1] - 1
    div, mod = month.divmod(3)
    deg      = (div+7)*(mod+1) + month * 30 + 314
    notes['往亡'] = (dates.range < 11 ? (deg - longitude) % 360 == 0  :               # 没を含まない
                                        (deg - 315      ) %  30 == day)? '往亡' : nil # 没を含む
  end

  # 伏龍
  notes['伏龍']     ||= {
    315 => '庭内去堂',  15 => '門内百日', 115 => '東垣六十日',
    175 => '四隅百日', 275 => '竈内四十日'
  }[longitude]

  # 六十卦
  div, mod = longitude.divmod(30)
  notes['六十卦']   ||= mod == 15 ? Notes60_A[(div - 10) % 12] : nil
  div, mod = longitude.divmod(6)
  notes['六十卦']   ||= mod == 0  ? Notes60_B[(div - 53) % 60] : nil

  notes
end