Unix * 3 PC 2 Linux, Mac *4 Windows Cygwin Cygwin gnuplot Cygwin unix emulator online gnuplot *5 matplotlib *6 SuperMongo *7 gnuplot gnuplot OS *8 Uni

Similar documents
1 1 Gnuplot gnuplot Windows gnuplot gp443win32.zip gnuplot binary, contrib, demo, docs, license 5 BUGS, Chang

2 Windows 10 *1 3 Linux 3.1 Windows Bash on Ubuntu on Windows cygwin MacOS Linux OS Ubuntu OS Linux OS 1 GUI Windows Explorer Mac Finder 1 GUI

cpall.dvi

X Window System X X &


PowerPoint プレゼンテーション

tebiki00.dvi

GNU Emacs GNU Emacs

GNUPLOT GNUPLOT GNUPLOT 1 ( ) GNUPLO

PowerPoint プレゼンテーション

05 I I / 56

1.3 2 gnuplot> set samples gnuplot> plot sin(x) sin gnuplot> plot [0:6.28] [-1.5:1.5] sin(x) gnuplot> plot [-6.28:6.28] [-1.5:1.5] sin(x),co

gnuplot.dvi

Microsoft PowerPoint - InfPro_I6.pptx

I I / 68

gnuplot の使い方 gnuplot は汎用的で しかも手軽に使えるプロッティング プログラムです 計算結果をグラフにするとき に非常に便利なので ぜひ覚えてください 1 gnuplot の始め方 終わり方 gnuplot の始め方は ターミナル上のプロンプトの後ろで gnuplot と打つだけ

KNOB Knoppix for Bio Itoshi NIKAIDO

I #2 : ( 8-13), () URL : j inoue/prog2007/prog2007.html

UNIX version Copyright c Daikoku Manabu 1 UNIX 1.1 UNIX UNIX UNIX OS Windows UNIX UNIX UN

273? C

Debian での数学ことはじめ。 - gnuplot, Octave, R 入門


PowerPoint プレゼンテーション

10/ / /30 3. ( ) 11/ 6 4. UNIX + C socket 11/13 5. ( ) C 11/20 6. http, CGI Perl 11/27 7. ( ) Perl 12/ 4 8. Windows Winsock 12/11 9. JAV

-2 gnuplot( ) j ( ) gnuplot /shell/myscript 1

programmingII2019-v01

情報の分析 1. Linux ツールの活用

x1 GNUPLOT 2 x4 12 x1 Gnuplot Gnuplot,,. gnuplot, PS (Post Script), PS ghostview.,.,,,.,., gnuplot,,, (x2). x1.1 Gnuplot (gnuplot, quit) gnuplot,. % g

unix.dvi

untitled

gnuplot gnuplot 1 3 y = x 3 + 3x 2 2 y = sin x sin(x) x*x*x+3*x*x

大規模ソフトウェアを手探る

PowerPoint プレゼンテーション

図 1: 場所をクリックし ホームフォルダーをクリックすると (上図) ホーム フォルダー下にあるファイルやディレクトリの一覧を見ることができる 下図 2

Fermi ( )

Windows Cygwin Mac *1 Emacs Ruby ( ) 1 Cygwin Bash Cygwin Windows Cygwin Cygwin Mac 1 Mac 1.2 *2 ls *3 *1 OS Linux *2 *3 Enter ( ) 2

2 I I / 61

y2=x2(x+1)-001.ps

UNIX

CentOSv2_furoku

2 A I / 58

¥¤¥ó¥¿¡¼¥Í¥Ã¥È·×¬¤È¥Ç¡¼¥¿²òÀÏ Âè11²ó

3 4 17:00 Address: ( ) (Subject) ( ) LeapMotion EyeTribe Processing LeapMotion EyeTribe 1. Mac OS X, LeapMotion, EyeTribe, Proces

というプロンプトだったのが gnuplot> というプロンプトに変わっていることに注意してください gnuplot を終了させるときには gnuplot> というプロンプトの後ろで quit と打ちこみます すると /home/snaoki> のようなプロンプトに戻るはずです 2 グラフを描いてみよ

2.2 Sage I 11 factor Sage Sage exit quit 1 sage : exit 2 Exiting Sage ( CPU time 0m0.06s, Wall time 2m8.71 s). 2.2 Sage Python Sage 1. Sage.sage 2. sa

SHOBI_Portal_Manual

K-BASIC 1st: ユニケージ基礎編(前編)

/

bash on Ubuntu on Windows bash on Ubuntu on Windows bash on Ubuntu on Windows bash on Ubuntu on Windows bash on Ubuntu on Windows ˆ Windows10 64bit Wi

a0postercls? Gerlinde Kettl, Matthias Weiser T E Xmacro wwwctanorg/tex-archive/macros/latex/contrib/a0poster LAT E X


目次

( ) kadai4, kadai4.zip.,. 3 cos x [ π, π] Python. ( 100 ), x cos x ( ). (, ). def print cos(): print cos()

slice00_install.dvi

Linux Activities for Promoting Desktop Linux Utilization Jun Iio Research Center for Information Technology, Mitsubish

help gem gem gem my help

LeapMotion JINS MEME 2019

背景

( ) Shift JIS ( ) ASCII ASCII ( ) 8bit = 1 Byte JIS(Japan Industrial Standard) X 0201 (X ) 2 Byte JIS ISO-2022-JP, Shift JIS, EUC 1 Byte 2 By

Asterisk PBX 不正利用防止



Microsoft PowerPoint - スハ?コン利用入門_ _UNIX利用の基礎知識.pptx

2 1. Ubuntu 1.1 OS OS OS ( OS ) OS ( OS ) VMware Player VMware Player jp/download/player/ URL VMware Plaeyr VMware

PowerPoint プレゼンテーション

3. :, c, ν. 4. Burgers : t + c x = ν 2 u x 2, (3), ν. 5. : t + u x = ν 2 u x 2, (4), c. 2 u t 2 = c2 2 u x 2, (5) (1) (4), (1 Navier Stokes,., ν. t +

3.2 Linux root vi(vim) vi emacs emacs 4 Linux Kernel Linux Git 4.1 Git Git Linux Linux Linus Fedora root yum install global(debian Ubuntu apt-get inst

Microsoft Word - gnuplot

Microsoft PowerPoint - 遺伝統計学夏の学校2018_Linux入門.pptx

6 Tgif William Chia-Wei Chang tgif 3.0 pixmap URL Tgif 6.1: Tgif

<Documents Title Here>

1 ( ) Level ################# #myls # ################ #!/bin/sh # if [ $# -eq 0 ] ; then pw=. elif [ $# -eq 1 ] ; then pw $1 else echo

,…I…y…„†[…e…B…fi…O…V…X…e…•‡Ì…J†[…l…‰fi®“ì‡Ì›Â”‰›»pdfauthor

160420c_unix.pptx

() (MeCab) *1 Juman ChaSen *2 MeCab ChaSen 1.3 MeCab MeCab OS Windows MeCab [] [Binary package for MS-Windows] [] sourceforge.net [mecab-win32] Mac OS

1. (Aladin-Japanese perso.string.utf).aladin.aladin Vista C: WinXP C: Documents and Settings Mac (Unix $

Microsoft PowerPoint - JohoEnshuu06_07.ppt

BEVEL( Cute Sister TRPG X PDF

PowerPoint プレゼンテーション

LAN Copyright c Daikoku Manabu This tutorial is licensed under a Creative Commons Attribution 2.1 Japan License

PowerPoint Presentation

e164.arpa DNSSEC Version JPRS JPRS e164.arpa DNSSEC DNSSEC DNS DNSSEC (DNSSEC ) DNSSEC DNSSEC DNS ( ) % # (root)

() (MeCab) *1 Juman ChaSen *2 MeCab ChaSen 1.3 MeCab MeCab OS Windows MeCab [] [Binary package for MS-Windows] [] sourceforge.net [mecab-win32] Mac OS


94

PowerPoint プレゼンテーション

Script started on Sun May 26 2::26 22 oyabun% gnuplot G N U P L O T Unix version 3.7 patchlevel ( //8) last modified Fri Oct 22 8:: BST 999 Cop

スパコンに通じる並列プログラミングの基礎


A : kerl kerl Erlang/OTP Erlang/OTP 2 2 Elixir/Phoenix URL 2 PDF A.2 Bash macos.bash_profile exp

SE-PostgreSQL Linux SELinux Security-Enhanced PostgreSQL

datavis_01_

スパコンに通じる並列プログラミングの基礎

ECCS. ECCS,. ( 2. Mac Do-file Editor. Mac Do-file Editor Windows Do-file Editor Top Do-file e

3. :, c, ν. 4. Burgers : u t + c u x = ν 2 u x 2, (3), ν. 5. : u t + u u x = ν 2 u x 2, (4), c. 2 u t 2 = c2 2 u x 2, (5) (1) (4), (1 Navier Stokes,.,

Microsoft PowerPoint _2.プログラミングの基礎_final.pptx

EQUIUM EQUIUM S5010 1

¥¤¥ó¥¿¡¼¥Í¥Ã¥È·×¬¤È¥Ç¡¼¥¿²òÀÏ Âè2²ó

NEC Storage series NAS Device

スライド 1

Transcription:

2015 8 1 ( ) Unix 1 *1 Unix Unix Unix Perl, Python *2 Unix 2 PC gnuplot *1 100 10 10 6 10 = 10 7 1 1/3 3 10 7 10 7.5 1 24 3600 = (30 6)(30 + 6) 100 = 86400 1 10 7.5 *2 Perl, Python Python 1

Unix * 3 PC 2 Linux, Mac *4 Windows Cygwin Cygwin gnuplot Cygwin unix emulator online gnuplot *5 matplotlib *6 SuperMongo *7 gnuplot gnuplot OS *8 Unix Unix Unix 3 Unix emacs *9 3 3.1 pwd *3 http://www.naoj.org/observing/datareduction/mtk/spring12/references/unix_class.pdf Unix http://www.naoj.org/observing/datareduction/mtk/spring12/references/linuxbasic10s.pdf *4 *5 / *6 1 Python Python *7 2 *8 *9 emacs, vi, gedit 2

* 10 $ pwd /home/ichikawa /home/ichikawa /home/ichikawa * 11 $ wget http://www.kusastro.kyoto-u.ac.jp/~ichikawa/autumn2015.tar.gz ls * 12 $ ls Autumn2015.tar.gz ls $ ls Autumn2015.tar.gz Autumn2015.tar.gz Autumn2015.tar.gz $ ls A $ ls Autumn2015.tar.gz Unix.tar.gz tar $ tar zxvf Autumn2015.tar.gz * 13 ls $ ls Autumn2015/ Autumn2015.tar.gz *10 print working directory *11 *12 list *13 tar zxvf A 3

wget wget which $ which wget /usr/bin/wget * 14 wget wget URL which $ which wget $ wget * 15 wget URL mv YourDownloadDirectory. mv $ mv YourDownloadDirectory/Autumn2015.tar.gz. $ tar zxvf Autumn2015.tar.gz. tar Autumn2015 cp 3.2 Swift/BAT 70 ( BAT ) X * 16 (E = 14 195 kev) 70 * 17 BAT * 18 1 BAT 70-month Survey Products Catalog: ASCII ( 300 KB) * 19 ( ) (SWIFT *14 /usr/bin/wget wget *15 wget *16 X hard X-ray X hard ( ) X soft ( ) X soft/hard E = 2 kev soft hard *17 detect NGC 1068 Hα *18 http://swift.gsfc.nasa.gov/results/bs70mon/ *19 4

1 Swift/BAT 70 http://swift.gsfc.nasa.gov/results/bs70mon/ JXXXX.X-XXXX ) (RA) (DEC) PC Mac Cmd+s * 20 wget * 21 $wget http://swift.gsfc.nasa.gov/results/bs70mon/inc/data/bat_70m_catalog_20nov2012.txt BAT 70m catalog 20nov2012.txt ls $ls Autumn2015/ Autumn2015.tar.gz BAT_70m_catalog_20nov2012.dat BAT mkdir * 22 $ mkdir BAT70mon $ ls Autumn2015/ Autumn2015.tar.gz BAT70mon/ BAT_70m_catalog_20nov2012.dat *20 *21 wget Autumn2015/ cp *22 Make directory 5

mv * 23 $ mv BAT_70m_catalog_20nov2012.dat BAT70mon/ $ ls Autumn2015/ Autumn2015.tar.gz BAT70mon/ ls BAT BAT BAT70mon BAT70mon cd * 24 $ cd BAT70mon/ $ pwd /home/ichikawa/bat70mon $ ls BAT_70m_catalog_20nov2012.dat BAT70mon BAT 3.3 BAT less $ less BAT_70m_catalog_20nov2012.dat BAT_NAME RA DEC SNR COUNTERPART_NAME deg deg 1 SWIFT J0001.0-0708 0.261-7.123 6.10 2MASX J00004876-0709117 2 SWIFT J0001.6-7701 0.326-77.001 5.41 Fairall 1203 3 SWIFT J0002.5+0323 0.664 3.332 5.10 NGC 7811 4 SWIFT J0003.3+2737 0.862 27.676 5.03 2MASX J00032742+2739173...... deg 6 6 awk $ which awk /usr/bin/awk PC awk awk 6 *23 move *24 change directory 6

$ awk -F" " {print $6} BAT_70m_catalog_20nov2012.txt... 2MASX J23470479+5142179 PKS 2349-01 IGR J23524+5842 2MASX J23525143-1704370 H 2356-309 PKS 2356-61 $ 6 awk {print $6} awk -F BAT 70m catalog 20nov2012.txt 6 ( ) 3 (R.A. * 25 ) 4 (Dec * 26 ) 8 (ctpt RA) 9 (ctpt DEC) * 27 8 9 8 9 awk $ awk -F" " {print $8,$9} BAT_70m_catalog_20nov2012.txt... 358.1120 58.7000 358.2143-17.0770 359.7830-30.6280 359.7682-60.9165 $6 $8, $9 8 9 > ra vs dec.txt $ awk -F" " {print $8,$9} BAT_70m_catalog_20nov2012.txt > ra_vs_dec.txt $ ls BAT_70m_catalog_20nov2012.dat $ less ra_vs_dec.txt ra_vs_dec.txt CTPT_RA CTPT_DEC *25 R.A. Right Ascension http://www.kusastro.kyoto-u.ac.jp/~iwamuro/lecture/obs/coord.html *26 Declination *27 http://adsabs.harvard.edu/abs/2013apjs..207...19b 7

deg deg 0.2032-7.1532 0.4419-76.9540 0.6103 3.3519 0.8643 27.6548 1.0082 70.3217 1.5813 20.2029... ra vs dec.txt > ( ) (ra vs dec.txt) $ awk NR>3{print} ra_vs_dec.txt > ra_vs_dec_nohead.txt NR awk NR 1 NR 2 m NR m NR>3{print} NR 3 print awk print ra vs dec.txt 4 * 28 less head head 10 $ head ra_vs_dec_nohead.txt 0.2032-7.1532 0.4419-76.9540 0.6103 3.3519 0.8643 27.6548 1.0082 70.3217 1.5813 20.2029 2.2982-0.6152 2.6292 10.9749 4.2853 81.5856 5.2814-19.1682 3 n n *28 {print} 8

$ head -n ra_vs_dec_nohead.txt 3.4 gnuplot gnuplot $ gnuplot G N U P L O T Version 4.6 patchlevel 1 last modified 2012-09-26 Build System: Darwin x86_64 Copyright (C) 1986-1993, 1998, 2004, 2007-2012 Thomas Williams, Colin Kelley and many others gnuplot home: http://www.gnuplot.info faq, bugs, etc: type "help FAQ" immediate help: type "help" (plot window: hit h ) Terminal type set to x11 gnuplot> gnuplot gnuplot> plot sin(x) 2 1 0.8 sin(x) 0.6 0.4 0.2 0-0.2-0.4-0.6-0.8-1 -10-5 0 5 10 2 gnuplot y = sin(x) 9

gnuplot gnuplot gnuplot> plot "ra_vs_dec_nohead.txt" u 1:2 3 ra vs dec nohead.txt 1 2 u 1:2 u using gnuplot gnuplot set se gnuplot 100 80 "ra_vs_dec_nohead.txt" 60 40 20 0-20 -40-60 -80-100 0 50 100 150 200 250 300 350 400 3 BAT R.A. Dec 3 (180, 60) (300, 40) ra vs dec.txt 0 x 360 90 y 90 gnuplot> se xrange[0:360] gnuplot> se yrange[-90:90] gnuplot> plot "ra_vs_dec_nohead.txt" u 1:2 notitle 4 (.png ).eps.pdf.eps gnuplot> se term eps 10

80 60 40 20 0-20 -40-60 -80 0 50 100 150 200 250 300 350 4 BAT R.A. Dec Terminal type set to epscairo Options are transparent fontscale 0.5 size 5.00in, 3.00in gnuplot> se output "radec.eps" gnuplot> replot gnuplot> exit eps (se term eps) (se output radec.eps ) (replot) gnuplot (exit) 4 radec.eps $ ls BAT_70m_catalog_20nov2012.dat ra_vs_dec.txt ra_vs_dec_nohead.txt radec.eps eps Mac Linux open $ open radec.eps open Linux 3.5 BAT 18 z * 29 19 X * 30 log 2 *29, redshift z λ ini λ obs λ obs = (1 + z)λ ini z z z = 0.1 10 z cosmo calc http://www.astro.ucla.edu/~wright/cosmocalc.html *30 : erg/s 11

awk $ awk -F" " {print $18,$19} BAT_70m_catalog_20nov2012.dat... 0.1640 44.95-1.0000 NULL 0.1651 45.16 0.0963 44.52 z 1.0000 2 NULL z Unix wc $ wc -l BAT_70m_catalog_20nov2012.dat 1213 BAT_70m_catalog_20nov2012.dat $ awk -F" " $19~/NULL/{print $18,$19} BAT_70m_catalog_20nov2012.dat wc -l 432 19 NULL 18 19 * 31 wc -l 432 1213 * 32 432 z z 432 $ awk -F" " NR>3 && $19!~/NULL/{print $18,$19} BAT_70m_catalog_20nov2012.dat > z_vs_lx.txt awk 4 (NR> 3) 19 NULL ($19! /NULL/) 18 19 z X log L X z vs lx.txt z sort $ sort z_vs_lx.txt... 3.1040 48.36 3.2000 47.98 3.2680 48.42 3.3660 48.01 *31 *32 3 1210 12

3.6680 48.14 1 z z = 3.668 X X 2 sort 2 sort -k $ sort -k2 z_vs_lx.txt... 3.2680 48.42 2.4000 48.45 2.3450 48.55 2.9793 48.57 2.5000 48.63 X log L X /erg s 1 = 48.63 4 10 33 erg s 1 10 15 X sort head $ sort -k2 z_vs_lx.txt head -5 0.0007 39.81 0.0011 40.79 0.0029 41.02 0.0015 41.03 0.0033 41.47 sort -r ( ) $ sort -k2 -r z_vs_lx.txt... 0.0033 41.47 0.0015 41.03 0.0029 41.02 0.0011 40.79 0.0007 39.81 X log L X /erg s 1 = 39.81 10 6 z vs lx.txt gnuplot $ gnuplot gnuplot> plot "z_vs_lx.txt" u 1:2 5 z < 0.5 z = 4.0 log x log gnuplot 13

49 48 "z_vs_lx.txt" 47 46 45 44 43 42 41 40 39 0 0.5 1 1.5 2 2.5 3 3.5 4 5 BAT z (x ) X (y ) gnuplot> se logscale x gnuplot> plot "z_vs_lx.txt" u 1:2 6 49 48 "z_vs_lx.txt" 47 46 45 44 43 42 41 40 39 0.0001 0.001 0.01 0.1 1 10 6 BAT z (x ) X (y ) 6 z = 0.01 0.3 (z 1) ( z 0.01) (log L X = 42 44) BAT flux (z log L X ) BAT (z log L X ) z, X flux flux (luminosity) flux 14

3.6 3 4 BAT id 21 R.A., Dec plot (Active Galactic Nuclei; AGN) id =4 8 $ awk -F" " $21>=4 && $21<=8 {print $8,$9} BAT_70m_catalog_20nov2012.dat > ra_vs_dec_agn.txt gnuplot plot ( ) 7 100 80 "ra_vs_dec_agn.txt" 60 40 20 0-20 -40-60 -80-100 0 50 100 150 200 250 300 350 400 7 BAT AGN R.A. Dec 7 AGN AGN AGN gnuplot awk X (X-ray binary) (cataclysmic variable; CV) id = 1 9 id 15 * 33 8 8 2 ((80, 70) (20, 75) ) 3.7 Unix awk Unix awk *33 awk or ( ) 15

80 60 40 20 0-20 -40-60 -80-100 0 50 100 150 200 250 300 350 400 8 BAT R.A. Dec Python 16

4 1. Unix Unix 2. BAT BAT 70m catalog 20nov2012.dat Unix wc tail * 34 BAT 70m catalog nohead.dat wc 3. 3 # BAT 70m catalog cmthead.dat 4. BAT z > 1 BAT 70m catalog zgt1.dat 5. BAT 70m catalog zgt1.dat 2 (BAT source type) 6. BAT 70m catalog zgt1.dat 2 * 35 BAT 70m catalog zgt1 ty7.dat BAT 70m catalog zgt1 ty8.dat 7. BAT 70m catalog zgt1 ty7.dat BAT 70m catalog zgt1 ty8.dat ( R. A., Dec) gnuplot *34 tail: *35 : awk 17

Unix awk google Mac Unix Unix for Mac OS X * 36 awk AWK * 37 awk * 38 BAT NASA Extragalactic Database (NED) * 39 z ( Blazar ) SIMBAD Astronomical Database * 40 Simbad * 41 NED Simbad NED Simbad ( ) AGN NED AGN AGN (Ichikawa, Kohei) https://motigomeman.wordpress.com/ ( ) (AGN) *36 http://www.oreilly.co.jp/books/9784873116440/ *37 https://www.usp-lab.com/book.awk.html *38 *39 http://ned.ipac.caltech.edu/ *40 http://simbad.u-strasbg.fr/simbad/ *41 AladinLite 18

5 1. 2. $ wc BAT_70m_catalog_20nov2012.dat 1213 20988 301789 BAT_70m_catalog_20nov2012.dat $ tail -1210 BAT_70m_catalog_20nov2012.dat > BAT_70m_catalog_nohead.txt $ wc BAT_70m_catalog_nohead.txt 1210 20956 301290 BAT_70m_catalog_nohead.txt 3. $ awk NR<=3{print "#"$0}NR>3 BAT_70m_catalog_20nov2012.dat > BAT_70m_catalog_cmthead.txt 4. $ awk -F" " $18>1.0 BAT_70m_catalog_nohead.txt > BAT_70m_catalog_zgt1.txt $ wc -l BAT_70m_catalog_zgt1.txt 30 BAT_70m_catalog_zgt1.txt 30 5. $ awk -F" " {print $21} BAT_70m_catalog_zgt1.txt sort uniq 7 8 source type 7: Blazar/BL Lac 8: QSO $ awk -F" " $21==7{print $21} BAT_70m_catalog_zgt1.txt wc -l 11 $ awk -F" " $21==8{print $21} BAT_70m_catalog_zgt1.txt wc -l 19 7 11 8 19 6. $ awk -F" " $21==7 {print} BAT_70m_catalog_zgt1.txt > BAT_70m_catalog_zgt1_ty7.txt $ awk -F" " $21==8 {print} BAT_70m_catalog_zgt1.txt > BAT_70m_catalog_zgt1_ty8.txt 7. $ gnuplot gnuplot> se datafile sepa " " gnuplot> plot "BAT_70m_catalog_zgt1_ty7.txt" u 8:9, "BAT_70m_catalog_zgt1_ty8.txt" u 8:9 gnuplot> se term eps Terminal type set to epscairo Options are transparent fontscale 0.5 size 5.00in, 3.00in gnuplot> se output "radec_zgt1.eps" gnuplot> replot gnuplot> exit 19

100 80 "BAT_70m_catalog_zgt1_ty7.txt" u 8:9 "BAT_70m_catalog_zgt1_ty8.txt" u 8:9 60 40 20 0-20 -40-60 0 50 100 150 200 250 300 350 400 9 BAT R.A. Dec 20