fftw에서 overlap 하는 예제는 못 찾았고

kissfft를 이용해서 (bsd-3 clause) 하는 예제도 아니고 걍.. git 발견

 

아무튼 아래와 같이 입력을 중첩하고 결과를 낸다는데

그림을 봐도 어떻게 데이터를 구성하고 합쳐내는지 감이 안온다.


overlap add
input

output


[링크 : https://github.com/fbdp1202/DSP_Overlap-Save_Overlap_Add]

'프로그램 사용 > fft, fftw' 카테고리의 다른 글

pFFFT 사용법  (0) 2023.06.15
fft 결과의 amplitude가 0.5가 나오는 이유  (0) 2023.06.13
fft size overlap window size  (0) 2023.06.12
fftw 라이브러리 사용 테스트  (0) 2023.06.12
fft 잘못 사용하고 있었나?  (0) 2023.06.02
Posted by 구차니

'프로그램 사용 > fft, fftw' 카테고리의 다른 글

fft 결과의 amplitude가 0.5가 나오는 이유  (0) 2023.06.13
overlap kissfft  (0) 2023.06.12
fftw 라이브러리 사용 테스트  (0) 2023.06.12
fft 잘못 사용하고 있었나?  (0) 2023.06.02
fft 라이브러리 목록  (0) 2023.06.01
Posted by 구차니

fftw()에

1. 입력 범위는 크게 의미 없으나 0.0~1.0 사이로 1의 높이로 정규화 하는 것이 용이할 수도 있음

2. DC 성분은 fft_result[0]에 있으며 / Sample 을 하면 DC 성분의 높이를 알 수 있음

2. sine() 성분은 fft_result[1~1/N]에 있으며 / Sample 을 하면 sine() 성분의 높이를 알 수 있음. (+/- x로 해석?)

3. phase는 모르겠다 -ㅁ-

-----------------

입력 값 범위 테스트

그냥 정상적인 0~1 사이의 실수 범위 입력

  for ( i = 0; i < n; i++ )
    in[i] = ( double ) sin ( 360.0f * (double)i / n  * 3.1415927f / 180.0f);

 

입력 범위 확인

출력 결과

도대체.. 1Hz 에서 32는 무슨 의미냐..

샘플링 횟수로 나눌게 아니라 최대 주파수 로 나누어야 하는건가?

  Input Data:

    0,    0.000000
    1,    0.098017
    2,    0.195090

...

  Output FFT Coefficients:

    0,   -0.000000,    0.000000,    0.000000
    1,    0.000003,  -32.000000,   32.000000
    2,   -0.000000,    0.000001,    0.000001

 

걍 무지성으로 100,000 곱하기(0 다섯개)

  for ( i = 0; i < n; i++ )
    in[i] = ( double ) sin ( 360.0f * (double)i / n  * 3.1415927f / 180.0f) * 100000;

 

FFT 결과 자체는 동일하지만(?) 결과 자체는 곱해준 100,000 만큼 증가

  Input Data:

    0,    0.000000
    1, 9801.714305
    2,19509.032738

...

  Output FFT Coefficients:

    0,   -0.008742,    0.000000,    0.008742
    1,    0.271011,-3199999.955619,3200000.000000
    2,   -0.008742,    0.118444,    0.118767

 

위상(phase)

동일 값, 위치만 8 칸 미룸(8/64 = 1/8 phase)

phase는 atan(b/a) 로 계산한다는데 일단 하라는대로 하니, -1.5 대충 pi/2 정도 최대값으로 나오는 듯.

  Input Data:

    0,    0.000000
    1, 9801.714305
    2,19509.032738
    3,29028.468510
    4,38268.344246
    5,47139.674887
    6,55557.024665
    7,63439.329895
    8,70710.679664
    9,77301.046896
   10,83146.962748
   11,88192.127851
   12,92387.954506
   13,95694.034604
   14,98078.528786
   15,99518.473069
   16,100000.000000


  Output FFT Coefficients:

    0,   -0.008742,    0.000000,    0.008742,    3.141593
    1,    0.271011,-3199999.955619,3199999.955619,   -1.570796
    2,   -0.008742,    0.118444,    0.118767,    1.644472
  Input Data:

    0,70710.679664
    1,77301.046896
    2,83146.962748
    3,88192.127851
    4,92387.954506
    5,95694.034604
    6,98078.528786
    7,99518.473069
    8,100000.000000
    9,99518.472212
   10,98078.527081
   11,95694.032066
   12,92387.951160
   13,88192.123730
   14,83146.957891
   15,77301.041350
   16,70710.673482

  Output FFT Coefficients:

    0,    0.119650,    0.000000,    0.119650,    0.000000
    1,2262741.972266,-2262741.421146,3199999.995629,   -0.785398
    2,   -0.048261,    0.083753,    0.096663,    2.093553

[링크 : https://blog.naver.com/lyb0684/221159899932]

 

atan과 atan2는 범위가 다르다고 한다. (범위가 달라지는 거지 radian을 degree로 계산하는게 달라지는건 아니니..)

atan
RETURN VALUE
       On success, these functions return the principal value of the arc  tan‐
       gent of x in radians; the return value is in the range [-pi/2, pi/2].

atan2
RETURN VALUE
       On  success, these functions return the principal value of the arc tan‐
       gent of y/x in radians; the return value is in the range [-pi, pi].

 

아무튼 귀찮으니 atan2의 radian 값 출력을 각도로 변환해서 출력해보면

  for ( i = 0; i < nc; i++ )
  {
      printf ( "  %3d,%12f,%12f,%12f,%12f,%12f\n", i, out[i][0], out[i][1],  
      sqrt(out[i][0] * out[i][0] +  out[i][1] * out[i][1]),
      atan2(out[i][1], out[i][0]) * 180 / PI,
      atan(out[i][1] / out[i][0]) * 180 / PI
  }

[링크 : https://spiralmoon.tistory.com/entry/프로그래밍-이론-두-점-사이의-절대각도를-재는-atan2]

 

뭔가 잘못 계산한 느낌이다?

+ 0      1,    0.000003,  -32.000000,   32.000000,  -89.999993,  -89.999993
+ 8     1,   22.627420,  -22.627414,   32.000000,  -44.999992,  -44.999992
+ 16     1,   32.000000,    0.000004,   32.000000,    0.000008,    0.000008
+ 32     1,   -0.000006,   32.000000,   32.000000,   90.000007,  -89.999988

 

 

+

DC성분

아래와 같이 1.0 값으로 64개를 만들어 fft를 돌리면

  for ( i = 0; i < n; i++ )
  { 
    in[i] = ( double )1.0f;
  }

 

64번 샘플링한게 1씩 있어서 합산하여 64가 나오나?

아무튼 실수부의 경우 -와 +의 차이가 있지만 abs()로 처리하면 부호가 사라지니 같은 값으로 보이게 된다.

  Output FFT Coefficients:

    0,   64.000000,    0.000000,   64.000000,    0.000000,    0.000000,    0.000000
  Output FFT Coefficients:

    0,  -64.000000,    0.000000,   64.000000,    3.141593,  179.999995,   -0.000000

 

0.5로 하면 32가 나온다. 도대체 이 DC는 어떻게 해석해야 할까?

  Output FFT Coefficients:

    0,   32.000000,    0.000000,   32.000000,    0.000000,    0.000000,    0.000000

 

sin() * 0.5는 DC 성분이 0으로 나오고 1Hz 에서는 16 으로 나온다(0.5로 봐야하나?)

  Output FFT Coefficients:

    0,   -0.000000,    0.000000,    0.000000,    3.141593,  179.999995,   -0.000000
    1,    0.000001,  -16.000000,   16.000000,   -1.570796,  -89.999993,  -89.999993
    2,   -0.000000,    0.000001,    0.000001,    1.644472,   94.221297,  -85.778698

 

sin() * 0.5 + 0.5(0.0~1.0=1.0) 하면 DC 32에 1Hz 16 (1 * 16?)

 

걍 맘편하게 주파수는 진폭, DC는 

  Output FFT Coefficients:

    0,   32.000000,    0.000000,   32.000000,    0.000000,    0.000000,    0.000000
    1,    0.000001,  -16.000000,   16.000000,   -1.570796,  -89.999993,  -89.999993
    2,   -0.000000,    0.000001,    0.000001,    1.644472,   94.221297,  -85.778698

 

sin() 은(-1.0~1.0=2.0 Height?) DC 0 1Hz 32 (2 * 16?)

 

  Output FFT Coefficients:

    0,   -0.000000,    0.000000,    0.000000,    3.141593,  179.999995,   -0.000000
    1,    0.000003,  -32.000000,   32.000000,   -1.570796,  -89.999993,  -89.999993

 

sin() * 0.5 + 0.5 (0.0~1.0=1.0) 에 절반의 파형만 줄 경우

1Hz에 18 

  Output FFT Coefficients:

    0,   26.177734,    0.000000,   26.177734,    0.000000,    0.000000,    0.000000
    1,    0.500000,  -18.177734,   18.184609,   -1.543297,  -88.424406,  -88.424406
    2,   -3.403504,   -0.000000,    3.403504,   -3.141593, -179.999990,    0.000005

 

sin(2x)

 

sin 주기가 늘어났다고 해서 16이 아니게 되는건 또 아니네?

그 와중에 0.5의 DC는 또 32.. 도대체 머냐고?!

0.5 * 64 = 32

sine 16/32 = 0.5. 혹시 +-0.5 라는건가?

  Output FFT Coefficients:

    0,   32.000000,    0.000000,   32.000000,    0.000000,    0.000000,    0.000000
    1,   -0.000000,   -0.000001,    0.000001,   -1.716660,  -98.357374,   81.642621
    2,    0.000003,  -16.000000,   16.000000,   -1.570796,  -89.999988,  -89.999988
    3,   -0.000000,    0.000001,    0.000001,    1.652756,   94.695926,  -85.304069
    4,   -0.000000,    0.000001,    0.000001,    1.718417,   98.458014,  -81.541981

 

혹시나 해서 sin(2x) * 0.1 + 0.9 해보는데

57.6

산술적으로는 64 * 0.9 = 57.6

3.2 / 32 = 0.1 이니.. DC랑 혼합될 때랑 단독일때랑 다르게 나오나?

(+- 0.1 로 해석하면 쉬울지도?)

  Output FFT Coefficients:

    0,   57.600000,    0.000000,   57.600000,    0.000000,    0.000000,    0.000000
    1,   -0.000000,   -0.000000,    0.000000,   -1.716660,  -98.357374,   81.642621
    2,    0.000001,   -3.200000,    3.200000,   -1.570796,  -89.999988,  -89.999988
    3,   -0.000000,    0.000000,    0.000000,    1.652756,   94.695926,  -85.304069

 

sin(2x)의 절반 파형만 도배!

고조파 처럼 나오네?

DC 52.3

4Hz 6.8, 8Hz 1.42, 12Hz 0.65, 16Hz 0.39, 20Hz 0.28, 24Hz 0.23, 28Hz0.20,  32Hz 0.19 (합계 10.251662)

  Output FFT Coefficients:

    0,   52.306340,    0.000000,   52.306340,    0.000000,    0.000000,    0.000000
    1,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    2,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    3,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    4,   -6.856612,   -0.000001,    6.856612,   -3.141593, -179.999990,    0.000005
    5,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    6,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    7,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
    8,   -1.425690,   -0.000000,    1.425690,   -3.141592, -179.999986,    0.000009
    9,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   10,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   11,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   12,   -0.652365,   -0.000000,    0.652365,   -3.141592, -179.999983,    0.000012
   13,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   14,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   15,    0.000000,    0.000000,    0.000000,    0.000000,    0.000000,        -nan
   16,   -0.397825,   -0.000000,    0.397825,   -3.141592, -179.999982,    0.000013
   17,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   18,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   19,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   20,   -0.286168,   -0.000000,    0.286168,   -3.141592, -179.999983,    0.000012
   21,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   22,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   23,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   24,   -0.231164,   -0.000000,    0.231164,   -3.141592, -179.999986,    0.000009
   25,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   26,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   27,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   28,   -0.204855,   -0.000000,    0.204855,   -3.141593, -179.999990,    0.000005
   29,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   30,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   31,    0.000000,   -0.000000,    0.000000,   -0.000000,   -0.000000,        -nan
   32,   -0.196983,    0.000000,    0.196983,    3.141593,  179.999995,   -0.000000

'프로그램 사용 > fft, fftw' 카테고리의 다른 글

overlap kissfft  (0) 2023.06.12
fft size overlap window size  (0) 2023.06.12
fft 잘못 사용하고 있었나?  (0) 2023.06.02
fft 라이브러리 목록  (0) 2023.06.01
fftw 다차원 분석  (0) 2023.05.27
Posted by 구차니
개소리 왈왈/컴퓨터2023. 6. 11. 23:44

ATX 폼팩터라 어쩔수 없긴 한데..

어떻게 해도 파워가 쓸데없이 크고

어떻게 해도 파워 케이블(cpu 4핀) 길이가 답이 안나온다.

 

 

 

저놈의 파워가 겁나 거슬리네..

DC to DC를 사야하나?

 

한화로 32,862원 써있는데 구글에서는 왜 8936원이냐 -_-

[링크 : https://ko.aliexpress.com/item/4001266864322.html]

 

아무튼.. 저 가격에 저 성능이 나올수 있는지도 미지수고

400W 면 12V에 33A는 넘어야 하는데

50.5$ ... 미네랄 ㅋㅋㅋㅋㅋㅋ

[링크 : https://kr.made-in-china.com/co_szpcsy/product_Desktop-AC-DC-12V-30A-Power-Adapter-360W-AC-Adaptor_rionnyhhg.html]

'개소리 왈왈 > 컴퓨터' 카테고리의 다른 글

TFX 파워지름  (0) 2023.06.15
TFX 파워  (0) 2023.06.13
케이스 만들기 어렵네?  (0) 2023.06.10
미니 컴퓨터 만들기는 험란하다  (0) 2023.06.06
CPU fan은 그냥 DC 팬이 아니다  (0) 2023.06.06
Posted by 구차니
개소리 왈왈/컴퓨터2023. 6. 10. 22:48

mATX 규격 메인보드를 종이 상자에 넣어서 만들려고 하는데

파워서플라이 커넥터와 cpu 전원이랑 해서

위치와 케이블 길이가 참 미묘~하다라는 느낌

왜 이렇게 이상한 위치에다가 그리고 표준(?)  ATX에 늘려서 하지 않고

도대체 왜 메인보드에서 cpu에 직결하도록 파워를 설계했냐 까지 멘붕이 우스스스

 

아무튼 메인보드 자체는 크기가 나쁘지 않지만

ATX 파워가 너~~~무 크고, 돈을 들이면 줄일수 있긴 한데

400W 면은.. 12V에 최소 35A는 흘릴수 있어야 한다는건데.. 도대체 어떻게 되어먹은 시스템이어야 가능하려나?

[링크 : https://ko.aliexpress.com/item/4001266864322.html?pdp_npi=2%40dis%21KRW%21%E2%82%A932%2C862%21%E2%82%A932%2C862%21%21%21%21%21%402141005d16864047174667666e6deb%2110000015529029098%21btf&_t=pvid%3A9c6dd9a7-2343-4605-bd71-e60fbae0f8bd&afTraceInfo=4001266864322__pc__pcBridgePPC__xxxxxx__1686404717&spm=a2g0o.ppclist.product.mainProduct&gatewayAdapt=glo2kor]

'개소리 왈왈 > 컴퓨터' 카테고리의 다른 글

TFX 파워  (0) 2023.06.13
케이스 만들기는 일단 완료  (0) 2023.06.11
미니 컴퓨터 만들기는 험란하다  (0) 2023.06.06
CPU fan은 그냥 DC 팬이 아니다  (0) 2023.06.06
노트북 시트지 바름  (0) 2023.04.06
Posted by 구차니

말이 거창한데 다르게 보면.. AM demodulation?

 

3. 다이오드 포락선 검파기(evelope detector) 

[링크 : http://ael.cbnu.ac.kr/lectures/undergraduate/정보통신실험/2019-2/10-진폭복조(Op-Amp)/10주-am-demodulator-theory.htm]

 

+

저런 회로를 거치면

 

아래와 같이 AM 모듈레이션 된 신호에 대한 envelope(포락선)을 검출할 수 있나보다.

 

 

[링크 : https://en.wikipedia.org/wiki/Envelope_detector]

 

그래프만 보면

1. 음수값 날리고

2. LPF 필터 적용하면 끝!

[링크 : https://www.dsprelated.com/showarticle/938.php]

'이론 관련 > 전기 전자' 카테고리의 다른 글

pvt - process voltage temperature  (0) 2023.06.30
필터 차수(order)  (0) 2023.06.21
인덕턴스  (0) 2023.04.20
Wilkinson power divider  (0) 2023.03.13
RC / RCD 스너버  (0) 2023.03.04
Posted by 구차니
Programming/golang2023. 6. 8. 22:21

'Programming > golang' 카테고리의 다른 글

golang goarch=arm64 와 디스어셈블러  (0) 2023.08.23
golang echo 서버 이상한 버그 발견?  (0) 2023.06.27
golang waitgroup  (0) 2023.05.24
golang echo server middleware  (0) 2023.05.24
golang 동시성  (0) 2023.05.24
Posted by 구차니

하도 안했더니 잠겨서 푼다고 개고생

결국에는 상담원 통해서 해제완료!

'게임 > 오리진&스팀&유플레이' 카테고리의 다른 글

갑자기 게임을 지르고 싶어짐  (2) 2024.10.25
식물대 좀비 fatal error  (0) 2023.07.23
ea origin은 어디가고..  (2) 2023.06.06
abzu 플레이  (0) 2023.05.29
스위치 둠 공략 - 챕터..4?  (0) 2022.08.30
Posted by 구차니

freecad로 fan 설계

[링크 : https://www.youtube.com/watch?v=fdikenPo4pE]

 

freecad로 설계한 도면을 salome를 이용하여 mesh(?)로 변환

[링크 : https://www.youtube.com/watch?v=FwseuCiSdiE]

[링크 : https://www.salome-platform.org/?page_id=15]

[링크 : https://www.salome-platform.org/]

 

openfoam + paraview

[링크 : https://www.youtube.com/watch?v=79-x2YQVE6Q]

[링크 : https://github.com/20jeka08/OpenFOAM_Propeller_simpleFoam] openfoam 설정(?) 파일

'프로그램 사용 > openFOAM' 카테고리의 다른 글

mpirun illegal instruction  (0) 2023.09.01
openFOAM tutorial with youtube  (0) 2023.05.24
openfoam on ubuntu  (0) 2023.05.24
openFOAM tutorial  (4) 2023.05.24
openfoam7 on ubuntu 18.04  (0) 2020.08.09
Posted by 구차니

gnuplot이 논문 등에서 그래프 그리는 용도로 많이 언급되는데 써보는건 첨인듯..

 

인터프리터(?)에서 아래와 같이 명령을 주면 된다고 한다.

gnuplot:> splot [2:-1] [-1:2] 3*x**2 + 2y**2

[링크 : https://namu.wiki/w/gnuplot]

 

혹시나 해서 gnuplot-qt를 깔았는데 저 gui가 qt 기반인건가?

$ gnuplot

G N U P L O T
Version 5.4 patchlevel 2    last modified 2021-06-01 

Copyright (C) 1986-1993, 1998, 2004, 2007-2021
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 is now 'qt'
gnuplot> splot [2:-1] [-1:2] 3*x**2 + 2y**2
Warning: Ignoring XDG_SESSION_TYPE=wayland on Gnome. Use QT_QPA_PLATFORM=wayland to run on Wayland anyway.

gnuplot> splot [2:-1] [-1:2] 3*x**2 + 2y**2
                                       ^
         unexpected or unrecognized token: y

gnuplot> quit

 

아무튼 이쁘게 잘 그려준다.

 

csv 파일을 그리려면 ,를 구분자로 설정해주면 되고

set datafile separator ','
plot "test.csv" using 0:1 with lines

[링크 : https://raymii.org/s/tutorials/GNUplot_tips_for_nice_looking_charts_from_a_CSV_file.html]

[링크 : https://stackoverflow.com/questions/48885697/gnuplot-graph-csv]

 

using 뒤에 숫자는 X 축과 Y축에 대해서 설정하는 것이고, 기본적으로 1 열에 대해서만 그래프를 그려준다.

using 1:3 파일에 있는 1열(X축)과 3열(Y축)을 사용하겠음

[링크 : https://m.blog.naver.com/gfeel323/40201727680]

 

여러 열을 한 그래프에 그리고 싶으면 아래와 같이  , "" 하고 using 구문을 추가해도 되고, for 문을 이용해서 반복해도 된다.

> plot "tt.csv" using 0:1 with lines, "" using 0:2 with lines
> plot for [col=1:4] 'file' using 0:col with lines

[링크 : https://stackoverflow.com/questions/16073232/gnuplot-plotting-a-file-with-4-columns-all-on-y-axis]

[링크 : https://raymii.org/s/tutorials/GNUplot_tips_for_nice_looking_charts_from_a_CSV_file.html]

 

만약 csv 파일에 일련번호로 쓸 내용이 없다면(대개는 시간이 있긴 하지만)

아래의 명령을 이용하여 x 축에 pseudocolumns를 추가해줄 수 있다고 한다.

가장 편한건 x축 지정하지 않는 using n이 무난한 듯.

plot "file.dat" using (column(0)):3

You can even use plot "file.dat" using 0:3
Or, as pointed out in the other answer, even plot "file.dat" using 3

[링크 : https://stackoverflow.com/questions/9664472/having-automatic-x]

 

stackoverflow에 내용을 참조해서 도움말을 보니 column("컬럼명") 혹은 column("컬럼 번호") 로 쓰는데

인덱스는 0부터가 아니라 1부터 시작되는 듯

gnuplot> help plot datafile using
// 생략
 if the data file contains
       Height    Weight    Age
       val1      val1      val1
       ...       ...       ...
 then the following plot commands are all equivalent
       plot 'datafile' using 3:1, '' using 3:2
       plot 'datafile' using (column("Age")):(column(1)), \
                    '' using (column("Age")):(column(2))
       plot 'datafile' using "Age":"Height", '' using "Age":"Weight"

 

그렇기에 (column(0)) 을 해주면 되는데 column(0)에러 난다.(!)

gnuplot> help plot datafile using pseudocolumns
 Expressions in the `using` clause of a plot statement can refer to additional
 bookkeeping values in addition to the actual data values contained in the input
 file. These are contained in "pseudocolumns".
       column(0)   The sequential order of each point within a data set.
                   The counter starts at 0, increments on each non-blank,
                   non-comment line, and is reset by two sequential blank
                   records.  The shorthand form $0 is available.
       column(-1)  This counter starts at 0, increments on a single blank line,
                   and is reset by two sequential blank lines.
                   This corresponds to the data line in array or grid data.
                   It can also be used to distinguish separate line segments
                   or polygons within a data set.
       column(-2)  Starts at 0 and increments on two sequential blank lines.
                   This is the index number of the current data set within a
                   file that contains multiple data sets.  See `index`.
       column($#)  The special symbol $# evaluates to the total number of
                   columns available, so column($#) refers to the last
                   (rightmost) field in the current input line.
                   column($# - 1) would refer to the last-but-one column, etc.

 

터미널 변경은 set terminal을 쓰면 된다.

$ gnuplot

G N U P L O T
Version 5.4 patchlevel 2    last modified 2021-06-01 

Copyright (C) 1986-1993, 1998, 2004, 2007-2021
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 is now 'qt'

gnuplot> set terminal dumb
Terminal type is now 'dumb'
Options are 'feed  size 79, 24 aspect 2, 1 mono'

[링크 : https://www.postgresql.kr/blog/gnuplot_dumb_terminal.html]

 

같은 그래프를 dump과

 

qt로 설정해서 출력한 모양

 

qt 에서 휠 드래그로 중심이동은 안되고

ctrl - wheel로 x축, y축 확대

ctrl - shift- wheel은 x 축 확대

shift - wheel 혹은 alt -wheel 로 x축 이동

wheel 로 y 축 이동이 기본 값으로 지정된다.

'프로그램 사용 > gnuplot' 카테고리의 다른 글

gnuplot  (0) 2022.06.13
Posted by 구차니