2012幎ã®åãã«ãæåã«åé¡ãçºçããŸããã以åã¯ãã¹ã¯ãããããŒãžã§ã³ã§äœ¿çšãããŠãããšã³ãžã³ããªãœãŒã¹ãå¿ èŠãšãããããã¢ãã€ã«ããã€ã¹ã§ã¯äœ¿çšã§ããŸããã äœããããå¿ èŠããããŸããã
æ¢è£œã®ãœãªã¥ãŒã·ã§ã³ãäœã£ãŠã¿ãŸãããïŒ
ã«ãŒãã£ã³ã°ãšã³ãžã³ã¯ãå®è£ ã®åŸ®åŠãªç¹ã§äžå¯èœãªã¿ã¹ã¯ã§ãããšããæèŠããããŸãã ããŒã¹ã::ã°ã©ãã«å ¥ããªããã®ããã«ããããæ®ãã¹ãã§ã¯ãããŸããïŒæ ç»ã¯æ®åœ±ãããŠããªããç¥ããªãã¯ãã§ããã¯ãïŒãæ¢è£œã®ãœãªã¥ãŒã·ã§ã³ãèŠã€ããã®ã¯ç°¡åã§ãã ããããããããç§ãã¡ã®å Žåã¯ããã§ã¯ãããŸããã
ãã®èšäºãããããæããã«ãªãããšãé¡ã£ãŠããŸã-åžžèãã¡ãã£ãšããåéºäž»çŸ©ããããŠãã¹ãŠã®ããã®æ¢è£œã®ã¬ã€ããã©ããªåé¡ã解決ããã§ãããã
å ¬å¹³ãæãããã«ãã°ã©ãã§ã®æ€çŽ¢ïŒã5,000äžé ç¹ïŒã®çµéšããã§ã«ããããšã«æ³šæããå¿ èŠããããŸãã
ã¯ããã«ïŒ
- ãµãŒããŒããŒãžã§ã³ã§ã¯ãåãã³ãŒããæ©èœããã¯ãã§ãããèšå®ã¯ç°ãªããŸãã
- ãã¹ã®æ§ç¯ã¯ã劥åœãªæéå ã«æºåž¯é»è©±ã§æ©èœããã¯ãã§ãã
- ã¢ã»ããã«ã¯ãæºåãã§ããïŒæ€èšŒæžã¿ã®ïŒéè·¯ã°ã©ãããããŸãã æ¢æã®ãœãªã¥ãŒã·ã§ã³ãæ€çŽ¢ããŠç ããããã¯ããã«ç°¡å/䟿å©/å®äŸ¡ã§ããããšãããããŸããã
åºæ¬ç㪠ïŒãããŠãäžè¬çãªãäžè¬çãªïŒ ååã瀺ããŸãïŒ
- ã¹ãã¬ãŒãžæ§é ã¯ã·ã³ãã«ã§ãªããã°ãªããŸããã
- ãªã³ã¯ã®å±ææ§ãåºæ¿ãããšäŸ¿å©ã§ãã ããŒã¿ãç©ççã«è¿ãïŒããšãã°ïŒã°ã©ãã®é ç¹ãåç §ããŠããå Žåãå¯èœã§ããã°ãã£ã¹ã¯äžã®è¿ãã«é 眮ããå¿ èŠããããŸãã
- ãã£ã¹ã¯äžã®ã°ã©ãèŠçŽ ã«äžåºŠã«1ã€ãã€ã¢ã¯ã»ã¹ããŠã¯ãªãããèªã¿åãã¯ãããã§ã®ã¿å®è¡ãããŸãã
- äœã¬ãã«ã®ãã£ãã·ã¥ã¯ã»ãšãã©åœ¹ã«ç«ããªãã®ã§ããé«äŸ¡ãªããªããžã§ã¯ãã®ã¿ãåŠçããå¿ èŠããããŸãã ããšãã°ããã£ã¹ã¯ã³ãŒã«ãçŽæ¥ãã£ãã·ã¥ããã®ã§ã¯ãªããã¢ã«ãŽãªãºã çã«ãã®æ°ãæå°éã«æããããã«æ³šæããããšããå§ãããŸãã
- ã°ã©ãå ã®æ€çŽ¢ããžãã¯ã¯ãå¯èœãªå Žåã¯åçŽåããå¿ èŠããããŸããããã¯ãããã€ãã©ã€ã³ãç Žæããå ŽåãïŒCïŒ
- ãã£ã¹ã¯äžã®ããŒã¿ãå§çž®ããã®ã¯è¯ãããšã§ãã
- ããã©ãŒãã³ã¹ãåªå ããŠç²ŸåºŠãç¡èŠããããšã¯éé£ã§ããŸããã
äž»ãªã¢ã€ãã¢
- ã©ãã£ã¹ã«é ç¹ã®åº§æšã眮ããŸãã ã€ãŸã æµ®åå°æ°ç¹åº§æšãæŽæ°ã«å€æããŸãã ã©ãã£ã¹ã¯ããªãç²ãããããšãã§ããé ç¹ãäºãã«ãã£ã€ããŸã§ããŸãã¯ããã«æªãããšã«é·ããŒãã®ãšããžã圢æããããŸã§ãã¹ããããå¢ãããŸãã ç§ãã¡ãæ€çŽ¢ãããšãã座æšã¯æçµïŒããã³ãããã°ïŒãŸã§ã®æ®ãã®è·é¢ãæšå®ããããã«å¿
èŠã§ãããæ Œåããã£ããã·ã¥ã©ã€ã³ã®è¿ãã§å€§ããå¢å ãããšãã¢ã«ãŽãªãºã ã¯å¥åŠãªåäœãéå§ããŸãã
ã°ã¬ãŒãã£ã³ã°ãç²ãã»ã©ããã£ã¹ã¯äžã®ããŒã¿éãå°ãªããªããããæ¬åœã«å¿ èŠãªå Žåã¯ãç¹°ãè¿ãéžæããããšãã§ããŸãã ã°ãªãããããã¯1ã¡ãŒãã«ã§ãã
ããã¯ãã°ãªããäžã«æ€ããããã°ã©ãã®æçã®ããã§ãã - 粟ç¥çã«ã°ã©ãã®ç¯å²ããæ Œåã圢æããããã€ãã®é·æ¹åœ¢ã®ã¿ã€ã«ã«åå²ããŸãã ãã®æ Œåã¯ãããŒã¯ã§ãã®å¯æ Œåã§ããå¿ èŠã¯ãããŸããã
- ã¿ã€ã«ã¯ããã£ã¹ã¯ããã®åæèªã¿èŸŒã¿ãšãã£ãã·ã¥ã®å¯Ÿè±¡ãšãªãè«çãŠãããã§ãã ããã«ã¯ããã¹ãŠã®é ç¹ãšåºåã¢ãŒã¯ïŒã€ãŸãããã®é ç¹ãæåã®é ç¹ã«ããã¢ãŒã¯ïŒãå«ãŸããŸãã ãã©ã¹é¢é£æ
å ±ïŒããå ŽåïŒã
ã¢ã¹ã¯ã¯ã®éè·¯ã°ã©ãã®æçã®äŸã«ããã1ã€ã®ã¿ã€ã«ã«é¥ããšããžã®äŸã - ã¿ã€ã«ã®ãµã€ãºã¯ãã°ã©ãã®ãµã€ãºã«åºã¥ããŠéžæããå¿ èŠããããŸãã ãã£ã¹ã¯ããäœããããŒããããããèªã¿åãããæ å ±ã®åèšéããã£ã¹ã¯ãããã¡ã®ãµã€ãºã«èŠåã£ããã®ã«ãªãã®ã¯åŠ¥åœã§ãã ãã£ã¹ã¯ã¢ã¯ã»ã¹ã®åœ¢åŒã§éãç ²ã䜿çšããŠã100ãã€ãã«åãŸãããã€ãã®ããŒã¯ã«ã¢ã¯ã»ã¹ããã®ã¯å¥åŠã§ãã ãã¡ãããã°ã©ãã¯åäžã«é 眮ãããŠããŸããããå¹³åå€ãã¢ããŒã«ã§ããŸããããšãã°ãã°ã©ãã¯ãã£ã¹ã¯äžã§20 MBãæ¶è²»ããŸãã 2500 8KããŒãžããããã£ãŠãã°ã©ãã®ç¯å²ã¯50Ã50ã®éšåã«åå²ãããŸãïŒsqrtïŒ2500ïŒïŒã ããã§ã¯ãã¿ã€ã«ã«é¢ãããã¹ãŠã®æ å ±ã1ã€ã®å Žæã«ãããšæé»çã«æ³å®ãããŠããŸãã ããã§ãªãå Žåã¯ãé©åãªä¿®æ£ãè¡ãå¿ èŠããããŸãã
- ã¿ã€ã«ããã£ãã·ã¥ããããšã¯çã«ããªã£ãŠããŸãã
- ã¡ã¢ãªïŒãŸãã¯ãã®äžéšïŒã«èªã¿èŸŒãŸããã°ã©ãã¯ãå€æ°ã®å°ããªãªããžã§ã¯ãã§ãã 倧éã®å°ããªãªããžã§ã¯ããéé¢ããŠå
é€ããããšã¯ã§ããŸããã ãããã£ãŠãå¯èœãªéãã»ãã·ã§ã³ããŒã¹ã®ããŒãžã¢ãã±ãŒã¿ã䜿çšããŸãã ããã«ãããé床ãšå€§å¹
ã«å°ãªãã¡ã¢ãªã®æçåã«å ããŠãããŒã¿ãããã¯ã®ããããŒã°ãšãšãããŒã°ïŒäºéã©ãã«ã¢ã«ãŽãªãºã ïŒãç¯çŽãããŸãã
ããŒãžã¢ãã±ãŒã¿ã¯ãããã«å±ããåºå®ãµã€ãºã®ããŒãžããã¡ã¢ãªãåé ãïŒå¯èœãªå ŽåïŒãå¿ èŠã«å¿ããŠã·ã¹ãã ã«èŠæ±ããŸãã ãã¹ãã©ã¯ã¿ã§ãã¹ãŠã®ã¡ã¢ãªã®ã¿ãããã«è§£æŸãããŸãã - ã¿ã€ã«ã«ã¯å¿ ç¶çã«ãã®ãããªã¢ãã±ãŒã¿ãŒããããããŒãæã«ç®ç«ã€ãã®ã¯ãã¹ãŠã¿ã€ã«ããååŸããããã£ãã·ã¥ãã匷å¶çã«åé€ããããšã¿ã€ã«ãšãšãã«æ¶æ» ããŸãã
- ããŒãžã¢ãã±ãŒã¿ãŒã䜿çšããå¥ã®åè£ã¯å®éã®æ€çŽ¢ã§ãããã®æ¹æ³ã§ã°ã©ãã®æž¡ãããéšåã«é¢ããæ å ±ãä¿åãããšäŸ¿å©ã§ã
- å®éã«ã¯æ€çŽ¢ã¢ã«ãŽãªãºã ã åäžã®ãæ³¢ãã§éåžžã®A *ã䜿çšãã移åè·é¢ïŒãŸãã¯æéïŒãšæ®ãã®æšå®å€ã®åèšã®åœ¢åŒã§é ç¹å€ãæšå®ããŸãã
- A *-ãªããªã å ã®ãã€ã¯ã¹ãã©ã¢ã«ãŽãªãºã ãšæ¯èŒããŠãééããããŒã¯ã®æ°ãæžããããšãã§ããŸãã
- 1ã€ã®æ³¢ã§-2ã€ã®çç±ã 第äžã«ã2ã€ã®æ³¢ãäºãã«åããŠçºå°ãããšãã°ã©ãã®éééšåãæžããŸãããåæ¢åºæºãè€éã«ãªããŸãã 2ã€ã®æ³¢ãè¡çªãããã©ãããåžžã«ç¢ºèªããå¿ èŠããããŸãã ãããŠãããã«ã¯ãåçãªäžé£ã®ããŒã¯ã®åæ³¢ã®ã³ã³ãã³ãããŸãã¯çŽæ¥èªã¿èŸŒãŸããã¿ã€ã«ã®å€æŽãå¿ èŠã§ãã
- 第äºã®çç±-è¿ã¥ããŠããæ³¢ã®ååšã¯ãäŸãã°mental骚ã«ç²Ÿç¥çã«å°éãããŸã§ã«äº€éç¶æ³ãå€åãããããrib骚ã®ã³ã¹ãã«åçã«åœ±é¿ãäžããããšã¯ã§ããŸããã
- äžè§åœ¢ã®äžçåŒã«éåããªãéããæ®ãã®ãã¹ã®ã³ã¹ãã®æšå®å€ã¯ã©ãã§ãããŸããŸããã ããšãã°ãæ£çŽãªãŠãŒã¯ãªããè·é¢ãŸãã¯ãã§ãã·ã§ãè·é¢ã䜿çšã§ããŸãã
ãœãŒã¹ããŒã¿
- ã°ã©ãã®é ç¹-座æšãšèå¥åãæã€æ§é
- ãšããžã«ã¯ãéå§é ç¹ãšçµäºé ç¹ã®èå¥åãé·ããã¿ã€ããããã³èå¥åãå«ãŸããŸãã ãã¹ãŠã®ãªãã¯äžæ¹åã§ãã
- å¶é-ãšããžã®ãã¢ããã®éã®é·ç§»ã¯äžå¯èœã§ãã å¶çŽã¯ãäž¡æ¹ã®ãšããžã«å ±éããç¹å®ã®é ç¹ã«é¢é£ä»ããããŠããŸãã ãã®ãããªããªãåãæšãŠãããå¶éã«ã€ããŠèª¬æããŸãããå¿ èŠã«å¿ããŠèªè ã¯ç°¡åã«äžè¬åã§ããŸãã
ååŠç
- ã°ã©ãã®å æ¬çãªç¯å²ãèŠã€ããŸãã
- 座æšã°ãªããã§æ±ºå®ãããŸãã
- ã¿ã€ã«ã®ã°ãªããã決å®ããŸãã åã¿ã€ã«ã«ã¯èå¥åãå²ãåœãŠãããŸãã èå¥åã¯ãã¹ã€ãŒãæ²ç·ã®çµæãšããŠå¢å ããæ°å€ã§ãã ãã®ãããªæ²ç·ã«ã¯ãæ°Žå¹³ã¹ãã£ã³ïŒã€ã°ã«ãŒïŒããã«ãã«ãæ²ç·ããŸãã¯ãããã€ã³ã¿ãŒãªãŒãã³ã°æ²ç·ïŒzorderïŒããããŸãã æŠããŠãã¿ã€ã«ããã€ã³ãã®åº§æšã«è©²åœãããã€ã³ããç¹å®ã§ããããšã ããéèŠã§ãã ãŸããã¹ã€ãŒãæ²ç·ã®éžæã¯ãããŒã¿ã®å§çž®èœåã«ã®ã¿åœ±é¿ããŸãã
- åé ç¹ãç¹å®ã®ã¿ã€ã«ã«å²ãåœãŠãŸãã åæã«ãåé ç¹ã«ã¿ã€ã«ã®ã·ãªã¢ã«çªå·ãå²ãåœãŠãŸããããã¯å§çž®ã«ã圹ç«ã¡ãŸãã
- ãšããžããšã«ãã©ã®ã¿ã€ã«ããã©ã®ã¿ã€ã«ãååŸããããããã³çºä¿¡ãã€ã³ããšçä¿¡ãã€ã³ãã®å éšçªå·ã決å®ããŸãã
ãã£ã¹ã¯ã¹ãã¬ãŒãž
ããŒã¿èªäœã¯BããªãŒã«æ ŒçŽãããããæ£ç¢ºã«ã¯ãã®çš®é¡ã®1ã€ã«æ ŒçŽãããŸãã
ããŒã¿ãŠã§ã¢ããŠã¹ããã䞊ã¹æ¿ããããN-oké åãä¿åãããããã®ééããã°ããèªã¿åãæ©èœãå¿ èŠã§ãã
æŠããŠãã¹ãã¬ãŒãžã®éžæã¯åºæ¬çãªãã®ã§ã¯ãªããBããªãŒãéžæããŸããã
- ç解ãšãããã°ãç°¡å
- 詳现ã«çžãããããšãªãããŒã¿ãå§çž®ã§ããŸã
- æãéèŠãªã®ã¯ãå®è£ ãæå ã§ãã¹ããããããšã§ãã
ãããã£ãŠãããã€ãã®ããªãŒããããŸãã
1. ããŒã¯ã®ããªãŒã ãã®ããªãŒã®N-kaã¯4ã€ã®èŠçŽ ã§æ§æãããŠããŸãã
- é ç¹ã¿ã€ã«ID
- ãã®ã¿ã€ã«ã®é ç¹ã·ãªã¢ã«çªå·
- X-ãã€ã³ã座æš
- Yã¯ãã€ã³ãã®åº§æšã§ãã
2. rib骚ã®æš ã圌ã®éµã¯7ã€ã®èŠçŽ ã§æ§æãããŠããŸãã
- ã¢ãŠãããŠã³ãã¿ã€ã«ID
- ã¿ã€ã«ã®çºä¿¡é ç¹çªå·
- é ç¹ã¿ã€ã«ID
- ã¿ã€ã«å ã®çä¿¡é ç¹ã®æ°
- Ri骚ã®ã³ã¹ããäŸãã°é·ã
- ãšããžã¿ã€ãïŒéè·¯ã¯ã©ã¹ãªã©ïŒ
- ãšããžã®å€éšèå¥åã
3. èå¥åã®ããªãŒã å€ã®äžçãšéä¿¡ããã®ã«åœ¹ç«ã¡ãŸãã ããŒã«ã¯5ã€ã®èŠçŽ ãå«ãŸããŸãã
- å€éšãšããžèå¥å
- ã¢ãŠãããŠã³ãã¿ã€ã«çªå·
- ã¿ã€ã«ã®çºä¿¡é ç¹çªå·
- çä¿¡ã¿ã€ã«çªå·
- ã¿ã€ã«å ã®çä¿¡é ç¹ã®çªå·ã
4.é·ã4ã®ããŒãæã€å¶éããªãŒïŒ
- å¶çŽé ç¹ã®ã¿ã€ã«çªå·ã
- ã¿ã€ã«å ã®ãã®é ç¹ã®æ°
- 移åãçŠæ¢ãããŠãããšããžã®å€éšèå¥å
- 移åãçŠæ¢ãããŠãããšããžã®å€éšèå¥åã
ææ ®æ·±ãèªè ã¯æ¬¡ã®ããã«èšãã§ãããã 1ã€ã®ã¿ã€ã«ã«é¢ãããã¹ãŠã®æ å ±ãèªã¿åãã«ã¯ãããªãŒäžã§3è¡ãå®è¡ããå¿ èŠããããŸãã ãã¹ãŠãBLOBã«ãŸãšããŠäžæ°ã«æã¡äžããæ¹ãè¯ãã®ã§ã¯ãªãã§ããããïŒãèªã¿åãå°çšããŒã¿ã®å Žåã¯ããã¡ãããé床ãšå§çž®å質ã®äž¡æ¹ãåªããŠããŸãã ããããããã¯è¿œå ã®äœæ¥ã§ãããè¿œå ã®ãã¹ãã§ãã ããã«ããããã¡ã€ãªã³ã°ã¯ãå®éã«ã¯ãæ¹åãæ€çŽ¢ãããšãã«ããŒã¿ã®èªã¿åããããã«ããã¯ã§ã¯ãªãããšã瀺ããŸããã
åçã«å€åããå¯èœæ§ã®ããããŒã¿ã«ã€ããŠè©±ããŠããå ŽåãBããªãŒã¯ç«¶åãè¶ ããŠããŸãã ç¬èªã®ããªãŒã®å®è£ ã¯å¿ èŠãããŸãããSQLã¹ãã¬ãŒãžã䜿çšã§ããäžèšã®ãšã³ãã£ãã£ã¯ã1ã€ã®äž»ããŒã®ã¿ã§æ§æãããããŒãã«ãšããŠå®çŸ©ã§ããŸãã ãããã£ãŠã説æãããŠãããšã³ãžã³ã®å身ã®1ã€ã¯ãããŒãã«èªäœãããªãŒã®ããã«é 眮ãããŠããOpenLink Virtuoso DBMSã«åºã¥ããŠæ§ç¯ãããŠããããã®å ŽåãããŒã¿èªäœã®éè€ã¯ãããŸããïŒã€ã³ããã¯ã¹å ã®ããŒãã«ã®ããŒã¿ã®éè€ãæå³ããŸãïŒã
ã¡ã¢ãªå ã®ã°ã©ãã®è¡šçŸ
ãã®ã»ã¯ã·ã§ã³ã§ã¯ãã¢ã³ããã¯ãããã°ã©ããã¡ã¢ãªå ã§ã©ã®ããã«èŠãããã説æããŸãã
1.ã¡ã¢ãªå ã®ã°ã©ãå šäœãååšããªãå ŽåããããŸãã ãã§ã«è¿°ã¹ãããã«ã誰ãããã®ã°ã©ãã®äžéšãå¿ èŠãšãããšãã«ãã¿ã€ã«ã«ããŒããããŸãã
2.ãããã£ãŠãã¿ã€ã«ã®ãã£ãã·ã¥ãšãã®ãã£ãã·ã¥ã®ãã«ããŒããããŸãã ãã£ãã·ã³ã°æŠç¥ã¯ä»»æã§ãã ãã®LRUïŒLeast Recent UsedïŒããããŸãã
3.ã¡ã¢ãªã«ããŒããããã¿ã€ã«-ãã®é åã«èœã¡ãããŒã¿ã«é¢ãããã¹ãŠã®æ å ±ãå«ãŸããŸãã æ¢ã«è¿°ã¹ãããã«ããã®ããã®ãã¹ãŠã®ã¡ã¢ãªã¯ãã¿ã€ã«ã«å±ããã¢ãã±ãŒã¿ããå²ãåœãŠãããã¿ã€ã«ãæ¶æ» ãããšè§£æŸãããŸãã ããªãã¡ïŒ
struct vertex_t {int x_; int y_; const link_t*links_; }; , .. . links_ , . struct link_t { int64_tfid_; // int len_; // int class_; // int vert_id_; // , >0, union { const vertex_t *vertex_; // int tile_id_; // }; const link_t *next_; // }; struct restriction_t {uint64_t from_; uint64_t to_;}; . , ( ) . , .
4.ãããã£ãŠãã¡ã¢ãªå ã®ã¿ã€ã«ã¯ãããã«äœ¿çšã§ããã°ã©ãã®äžéšã§ãã
- çªå·ã§é ç¹ãçºè¡
- é ç¹ã«ããå€åãã®ãšããžã®æ€åº
- ãªãã®å¶éããã¹ãããŸã
- ãšããžã¯ãã¿ã€ã«å ã移åãããšãã®ãã€ã³ã¿ãŒããŸãã¯ã¿ã€ã«çªå·/é ç¹çªå·ã®ãã¢ã®ãã¢ã®ããããã§ãã ãã®ãã¢ã§ã¯ãã°ã©ãã«æ²¿ã£ãŠç§»åãããšãã«ããã£ãã·ã¥ãã«ããŒããå¿ èŠãªã¿ã€ã«ãééçã«èŠæ±ããå¿ èŠã«å¿ããŠããŒãããŠãåãæ¿ããããšãã§ããŸãã
å®éã«æ€çŽ¢
1.æ€çŽ¢ãéå§ããåã«ãã°ã©ãã«æ·»ä»ããå¿ èŠããããŸãã ã€ãŸã å€éšã§ã¯ã2ã»ããã®ãã€ã³ã-ãœãŒã¹ãšãšã³ããååŸããŸãã åãã€ã³ãã®èª¬æã¯ããã®å€éšã°ã©ããšããžèå¥åãšå€ã§æ§æãããŸãã éå§ç¹ã«ã€ããŠãã®ãšããžã®éå§ç¹ã«å°éããã³ã¹ããããã³çµäºç¹ã«ã€ããŠãšããžã®çµäºç¹ããæçµç¹ãŸã§ã®ãã¹ã®ã³ã¹ãã ã ããïŒ
2.èå¥åã®ããªãŒã䜿çšããŠããšããžã®èå¥åãã°ã©ãã®ãšã³ããªãã€ã³ãã«å€æããŸãïŒconst vertex_t *ïŒã ãããè¡ãã«ã¯ãã¿ã€ã«ãã£ãã·ã¥ãã«ããŒã«é£çµ¡ããŠå¿ èŠãªãã®ãããŒãããå¿ èŠããããŸãã
ãªããžã§ã¯ããå¿ èŠã§ã-ã¿ã€ã«èå¥åãšé ç¹çªå·ãå«ããæçµã«é¢ããæ å ±ã®ä¿æè ã ãã®ãªããžã§ã¯ããæã€å¥ã®æçšãªæ å ±ã¯ããã£ããã·ã¥ã©ã€ã³ã®å¹ŸäœåŠçäœçœ®ã§ãã æ瀺çã«èšå®ã§ããŸãããããšãã°ãæçµãã€ã³ãã®éå¿ãšããŠèšç®ã§ããŸãã ã¢ã«ãŽãªãºã Aã®å°éããŒã¯ã®ã³ã¹ãã®æšå®éšåãèšç®ããã«ã¯ããã®ç¹ãå¿ èŠã§ã*
3.ããã§ãããŠã§ãŒãããã«ããŒãå¿ èŠã§ãã 次ã®ãã®ã§æ§æãããŸãã
aã ã¢ãã±ãŒã¿ãŒããŸãã圌ãªãã§ã
bã ããŒããããã¿ã€ã«ã®ã»ããã é©åãªãµã€ãºã®ã°ã©ãã®å Žåãããããã¹ã¯ã§ååã§ãã ã€ãŸããæåã«ã¿ã€ã«ãããããããšãã«ããã®ãã¹ã¯ã®å¯Ÿå¿ããããããããŒã¯ãããã®ãªã³ã¯ã®ã«ãŠã³ã¿ãŒãå¢ãããŸãã ãã®ãã¹ã¯ã«çŠç¹ãåãããŠæ€çŽ¢ãå®äºããåŸããªã³ã¯ã«ãŠã³ããããŒã«ããã¯ããŸãã åæã«ãã«ãŠã³ã¿ãŒããŒãã«ãªã»ãããããã¿ã€ã«ã¯ãå°æ¥ãã£ãã·ã¥ããé£ã³åºãå¯èœæ§ããããŸãã
cã åªå ãã¥ãŒã ãã€ããªãœãŒãããŒãã䜿çšããŸãã åè£ã衚瀺ããŸãã ããšãã°ãéå§ç¹ã¯ãããããŸã£ããé²ã¿ãŸãã ããŒã¯ã移åè·é¢ãŸãã¯è²»ããããæéã§ãã ãããŠãå€ã¯æž¡ããããã€ã³ãã®èšè¿°åãžã®ãã€ã³ã¿ã§ã
dã æž¡ããããã€ã³ãã®ã»ããã ãã®ãããªåãã€ã³ãã¯ãæ§é ã«ãã£ãŠèšè¿°ãããŸãã
struct vertex_ptr_t { int64_t fid_; // , // 0 const vertex_t *ptr_; // const vertex_ptr_t *prev_; // size_t cost_len_; // size_t cost_time_; // };
ãã¡ããããããã®æ§é ã¯ã¢ãã±ãŒã¿ãŒãšããŠéç«ã£ãŠããŸãã
4.ãããã£ãŠãéå§ç¹ããšã«èšè¿°åãäœæããããŒãã«é 眮ããŸãã ããã§ãæ€çŽ¢ãéå§ããæºåãæŽããŸããã
5.ããŒãå ã«äœããååšããéïŒããã³ãæ¢ã«èŠã€ãã£ãåè£ãããæœåšçã«åªããŠããéïŒããã®äžããæãå®äŸ¡ãªèŠçŽ ãéžæãã以äžãå®è¡ããŸãã
aã çºä¿¡ãšããžã®ãªã¹ãã«æ²¿ã£ãŠå®è¡ããããããã«ã€ããŠïŒ
I.åã®ãšããžãããã®ãšããžã«åãæ¿ããå¯èœæ§ã確èªããŸãã
IIã ãã®ãšããžãæãã°ã©ãã®é ç¹ãèŠã€ããã ããããããã¯æ°ããã¿ã€ã«ãããŒããããã®ãã€ã³ãã¯ããã«ãããŸãã
IIIããã®æ°ãããã€ã³ããéæããããã®ã³ã¹ããèšç®ããŸãã ãããè¡ãã«ã¯ïŒ
- èç©ããããã¹ãšæéãåã
- çŸåšã®ãšããžã®é·ãã§ãã¹ãèŠçŽããŸã
- çŸåšã®é·ããã¿ã€ãããã®ä»ã«å¿ããŠãçŸåšã®æéãå æããããã«å¿ èŠãªéã ãæéãå¢ãããŸã
- æ®ãã®ãã¹ã®æšå®å€ãèšç®ããŠè¿œå ããŸã-absïŒdxïŒ+ absïŒdyïŒãããã§dxãšdyã¯ããããçµåºŠãšç·¯åºŠã®å·®ã§ã
- æ®ãã®ãã¹ãæå»ãå¹³åé床ã®æšå®å€ã«åºã¥ããŠããã£ããã·ã¥ã©ã€ã³ãŸã§ã®æ®ãæéã®æšå®å€ãèšç®ããŠè¿œå ããŸã
- åæ Œããã¹ããŒãžãªã©
IVã æž¡ãããé ç¹ã®èšè¿°åãäœæããŠå¡ãã€ã¶ããŸã
V.ãã®ç¹ãæçµçââãªãã®ã§ã¯ãªãã確èªãã
VIã ããããã£ããã·ã¥ã©ã€ã³ã®å Žåãåã®ãªã¹ããå·»ãæ»ããŸã
ïŒvertex_ptr_t :: prev_ïŒ ããã®ãã€ã³ãããå§ãŸãã0ã«éãããŸã§ã
ã€ãŸã éå§ããŸãã åŒãæž¡ãã®å®æããåè£ã¯æ¬¡ã®ãšããã§ãã
VIIã äœæãããèšè¿°åãããŒãã«é 眮ããŸã
çµæ
åºå€§ãªç¥åœã®éŠéœã®éè·¯ã°ã©ãã®äŸã§ããã®è¡çºã®çµæãè©äŸ¡ããŠã¿ãŸãããã
- ã°ã©ãã«ã¯307,338åã®é ç¹ãå«ãŸããŠããŸã
- 806220ãªãã
- 寞æ³-92 x 112 km
- ã¿ã€ã«ã®æ°-46 x 56 = 2576å
- éè·¯ã°ã©ã13 980 kbãå ãããã£ã¹ã¯äžã®ããŒã¿ã®ç·é
- å¹³åã«ãŒãé·-32.8 km
- äŸãã°
éã¯æé©ãªã«ãŒãã瀺ããèµ€ã¯ãæ³¢ãã瀺ããŸãã
- åæã«ãå¹³å1,644åã®ããŒã¯ãš22åã®ã¿ã€ã«ã«ãã2,406åã®ãšããžã圱é¿ãåããŸã
- ããã«ã¯ãã¿ã€ã«ã«2096 kbããŠã§ãŒãã«116 kbãå¿ èŠã§ã
- Sony Xperia S 400 + 500ïŒã€ã³ããã¯ã¹ã®åæåçšïŒmsïŒIphone 4 800 + 1000ïŒ...ïŒmsïŒ
- äŸãã°ã©ãå šäœãéããã¹
åãšåãããã«ãéã¯æé©ãªã«ãŒãã瀺ããèµ€ã¯ãæ³¢ãã瀺ããŸãã
æ€çŽ¢ãã°ã©ãã®ïŒå®éã®ãæé»ã®ïŒéå±€æ§é ãæããã«ããããã䜿çšãå§ããæ§åã芳å¯ããã®ã¯é¢çœã
- èšç®ãããé·ãã¯135.3 kmã§ãã
- ãã®å Žåã120åã®ã¿ã€ã«ã«ãã2251åã®ããŒã¯ãš3044åã®ãšããžã圱é¿ãåããŸãã
- åæã«ãã¿ã€ã«ã«ã¯3,946 kbããŠã§ãŒãã«ã¯133 kbãå¿ èŠã§ãã
- ãã¡ãããSony Xperia SïŒ500 IPhone 4ïŒã«400ããªç§ãè²»ãããããã«å ããŠåã1åéãã®ã€ã³ããã¯ã¹ã®èªã¿èŸŒã¿ãè¡ããŸããã
- ãããŠãããã§ã¯ãããŸããŸãªèšå®ã§ããã·ãã«ã¹ã¯ãé転ãã3ã€ã®åçãã䜿çšããããã¥ãŒãªã¹ãã£ãã¯ã®éèŠæ§ã瀺ããŠããŸãã
åèš
ã芧ã®ãšããããã®ãããªåçŽãªããŒã¿æ§é ãšèª¬æãããŠããã¢ã«ãŽãªãºã ã«ãããéåžžã®ã¹ããŒããã©ã³ã§å€§éœåžã®åäžã¬ãã«ã®ã°ã©ããæäœã§ããŸãã ãŸããããšãã°ããµãŒããŒã®å Žåã«RAMãã¿ã€ã«ãã£ãã·ã¥ã®ãµã€ãºãå¢ããããšãèš±å¯ããå Žåã¯ãã°ã©ãå šäœãã¡ã¢ãªã«æ ŒçŽããããã«äœ¿çšã§ããè¡šçŸã§äœæ¥ããŸãã ããã¯ããã©ãŒãã³ã¹ã«æçãªå¹æããããŸãã
亀éç¶æ³ããã®äºæž¬ãéå±€ã°ã©ããèæ ®ã«å ¥ãããªã©ãæå³çã«ç¹å®ã®ãã€ã³ãã«è§ŠããŸããã§ãããããã¯ãŸã£ããå¥ã®è©±ã§ãã
ããã¯ãã¹ãŠã®äººã ã§ãïŒ