å¤é¨å¤å½¢ã¯ ãã¼ã¿ã®ããåããããã¹ããã¡ã¤ã«ã§è¡ãã®ã§ ããã°ã©ã è¨èªã¯ èªç±ã«é¸ã¶ãã¨ãã§ãã¾ããå³å½¢ã¯æ©è½çãã¤ã·ã³ãã«ãªãããæ°å¤ãã®ã¦ã¼ã¶ã¼ã«åãå ¥ãããã¦ãã¾ãã
Â
ãªã§ããã§ï¼ç·ã®äº¤è§ãè¨ç®ãã
/* ãªã§ããã§ï¼ç·ã®äº¤è§ãè¨ç®ãã
@cls & echo off
path C:\nadesiko_1_589;%path%
copy jwc_temp.txt myfiles > nul
cnako %0 > jwc_temp.txt
goto:eof
REM #jww
REM #1%dln ç·ãæ示ãã¦ãã ããã
REM #2%dln ç·ãæ示ãã¦ãã ããã
REM #bz
REM #e
*/
âATAN2(y, x)
ããã(x = 0)ãªã(PI / 2 * SIGN(y))ãæ»ã
ãaã¨ã¯å®æ° = ARCTAN(y / x)
 ãã(x < 0)ãªã
  ãã(y < 0)ãªã
   a = a - PI
  éãã°
   a = a + PI
ãaãæ»ã
âABS(x)
ã(x * SIGN(x))ãæ»ã
âDEG(x)
ãxã度å¤æãã¦æ»ã
âRAD(x)
ãxãã©ã¸ã¢ã³å¤æãã¦æ»ã
âSPLIT(s)
 sãã ãã§åºåã£ããã®ãæ»ã
âINTERS(ç·1, ç·2)
 F1ã¨ã¯é
å; dx1ã¨ã¯å®æ°; dy1ã¨ã¯å®æ°; m1ã¨ã¯å®æ°; u1ã¨ã¯å®æ°
 F2ã¨ã¯é
å; dx2ã¨ã¯å®æ°; dy2ã¨ã¯å®æ°; m2ã¨ã¯å®æ°; u2ã¨ã¯å®æ°
 aaã¨ã¯å®æ°
 F1 = ç·1ãã ãã§åºåã£ããã®
 dx1 = F1[2] - F1[0]
 dy1 = F1[3] - F1[1]
 ãã(dx1 = 0)ãªã
  m1 = 10 ^ 20
 éãã°
  m1 = dy1 / dx1
 F2 = ç·2ãã ãã§åºåã£ããã®
 dx2 = F2[2] - F2[0]
 dy2 = F2[3] - F2[1]
 ãã(dx2 = 0)ãªã
  m2 = 10 ^ 20
 éãã°
  m2 = dy2 / dx2
 aa = m1 - m2
 ãã(ABS(aa) < 1e-10)ãªã(aa = 0)
 ãã(aa <> 0)ãªã
  u1 = F1[1] - m1 * F1[0]
  u2 = F2[1] - m2 * F2[0]
  ã{(u2 - u1) / aa} {(m1 * u2 - m2 * u1) / aa}ããæ»ã
 éãã°
  "heå¦çã§ãã¾ãã"ã表示
  çµäº
âLN_HPSNAP(ç·, ç¹)
 Fã¨ã¯é
å = SPLIT(ç¹)
 tã¨ã¯å®æ° = LN_HPDIST(ç·, ç¹)
 dã¨ã¯å®æ° = LNSLOPE(ç·)
 ã{F[0] + t * SIN(d)} {F[1] - t * COS(d)}ããæ»ã
âLN_HPDIST(ç·, ç¹)
 Fã¨ã¯é
å = SPLIT(ç·)
 Xã¨ã¯æåå = "{ç¹} {F[0]} {F[1]}"
 (LNLENGTH(X) * SIN(LNSLOPE(ç·) - LNSLOPE(X)))ãæ»ã
âLNLENGTH(ç·)
 Fã¨ã¯é
å = SPLIT(ç·)
 HYPOT(F[2] - F[0], F[3] - F[1])ãæ»ã
âLNSLOPE(ç·)
 Fã¨ã¯é
å = SPLIT(ç·)
 ATAN2(F[3] - F[1], F[2] - F[0])ãæ»ã
ãmyfilesããæ¯è¡èªãã§å復
 ããã(対象ãã^hqãã§æ£è¦è¡¨ç¾ããã)ãªãã°
  ãbzãã表示
  ç¶ãã
 ããã(対象ãã^hp(\d+)ln-?\s+(\S+ \S+)ãã§æ£è¦è¡¨ç¾ããã)ãªãã°
  hp[æ½åºæåå[0]] = æ½åºæåå[1]
  ç¶ãã
 ããã(対象ãã^hhp(\d+)lnãã§æ£è¦è¡¨ç¾ããã)ãªãã°
  i = æ½åºæåå[0]
  ç¶ãã
 ããã(対象ãã^\s+(\S+ \S+ \S+ \S+)ãã§æ£è¦è¡¨ç¾ããã)ãªãã°
  ln[i] = æ½åºæåå[0]
pc = INTERS(ln[1], ln[2])
p1 = LN_HPSNAP(ln[1], hp[1])
p2 = LN_HPSNAP(ln[2], hp[2])
d1 = DEG(LNSLOPE("{pc} {p1}"))
d2 = DEG(LNSLOPE("{pc} {p2}"))
xang = d2 - d1
ãã(SIGN(xang - 180) = 1)ãªã(xang = xang - 360)
ãã(SIGN(xang + 180) =-1)ãªã(xang = xang + 360)
xang = ROUND(xang*1000)/1000
d1 = ROUND(d1*1000)/1000
d2 = ROUND(d2*1000)/1000
ãh#â {xang}ï¾ {d1} {d2}ãã表示
Â
Â
Â
Â
è§åº¦ã¯å·¦åããæ£ã¨ãã¦ãã¾ãã