FFT 튜토리얼 http://www.phys.nsu.ru/cherk/fft.pdf 푸리에 변환을 쓰는지에 대한 글(왜 주파수로 변환해서 판단하는지) https://community.sw.siemens.com/s/article/what-is-the-fourier-transform What is the Fourier Transform? *** On-Demand Webinar: Digital Signal Processing Fundamentals *** The Fourier Transform is an important mathematical tool in many fields including vibration analysis, audio engineering, and image processing. Why..
#include #include typedef struct ListNode {int coef;int expon;struct ListNode *link;} ListNode; typedef struct ListHeader {int length;ListNode *head;ListNode *tail;}ListHeader; void init(ListHeader *list){list->length = 0;list->tail = list->head = NULL;} void error(char *mes){fprintf(stderr, "%s\n", mes);exit(1);} void insert_node(ListHeader *list, int coef, int expon){ListNode *p = (ListNode *)..
#include #include typedef struct Dlist_node {int data;struct Dlist_node *llink;struct Dlist_node *rlink;}Dlist_node; // 포인터에서 포인터의주소 그 포인터의 주소를 불러들일려면 struct Dlist_node를 전반에 후반에 둘다 선언해줘야된다. void init(Dlist_node *head){head->llink = head;head->rlink = head;} void before_right_node(Dlist_node *before, Dlist_node *new_node){new_node->llink = before; // 새로운 노드의 왼쪽은 before 노드로new_node->rlink = before..
#include #include typedef struct {int data;struct ListNode *link;} ListNode; void insert_first(ListNode **head, ListNode *node){if (*head == NULL){*head = node; // 헤드는노드node->link = node; // 노드의 다음 주소는 노드}else {node->link = (*head)->link; // 노드의 다음주소는 헤드의 주소(*head)->link = node; // 헤드의 다음주소는 노드}} void insert_last(ListNode **head, ListNode *node){if (*head == NULL){*head = node; //헤드의 주소는 노드node-..
#include #include typedef struct {int data;struct ListNode *link;} ListNode; ListNode *create_node(int data, ListNode *link){ListNode *new_node;new_node = (ListNode *)malloc(sizeof(ListNode));if (new_node == NULL) printf("메모리 할당 에러\n");new_node->data = data;new_node->link = link;return(new_node);} ListNode *search(ListNode *head, int fdata){ListNode *p = head;while (p != NULL){if (p->data == fda..
#include #include #define MAX_LIST_SIZE 100 typedef struct {int list[MAX_LIST_SIZE];int length;} Array_list; void error(char *message){printf("%s\n",message);exit(1);} void init(Array_list *list){list->length = 0;} int is_empty(Array_list *list){return list->length == 0;} int is_full(Array_list *list){return list->length == MAX_LIST_SIZE;} void display(Array_list *list){for (int i = 0; i < list-..
#include #define MAX_NAME 50#define MAX_STUDENTS 100 typedef struct {int month;int date;} BirthdayType; typedef struct {char name[MAX_NAME];BirthdayType birthday;} student; student students[MAX_STUDENTS]; void strcpy(char *name, char *cname){while (*name = *cname){name++;cname++;}} void main(){strcpy(students[0].name, "길동차");students[0].birthday.month = 12;students[0].birthday.date = 25; printf(..
void(*pf) (int *result, int value_1, int value_2); // 함수 포인터 설정 void add(int *result, int value_1, int value_2){*result = value_1 + value_2;} void subtract(int *result, int value_1, int value_2){*result = value_1 - value_2;} void main(void){int z;printf("value 1: 20 value 2: 30 기준으로 계산 \n\n");pf = add; // 포인터 함수에 add 함수 주소 저장pf(&z, 20, 30);printf("add 함수 결과값 : %d\n\n", z);pf = subtract; // 포인터 함..
// 변수 구조 선언typedef struct{char title[50];char address[50];int s_num;}univ; void main(void){univ sku = { "성공대학교","서울시",2000 };univ *ptr = &sku; // 포인터에 주소 할당 printf("학교: %s 주소: %s 학생 수: %d \n", ptr->title, ptr->address, ptr->s_num); // 포인터가 가르키는 구조체 멤버 printf("학교: %s 주소: %s 학생 수: %d \n",(*ptr).title,(*ptr).address,(*ptr).s_num); // 포인터가 가르키는 구조체 멤버 printf("학교: %s 주소: %s 학생 수: %d \n", sku.title, s..
// 구조체 여러개 설정할때 쓰이는 변수 구조 선언struct book{char book_name[50];char book_author[50];char book_public[50];int page;int price;}; //각각 구조체를 하나의 변수로 설정할때struct{char book_name[50];char book_author[50];char book_public[50];int page;int price;}book_2; struct{char name[50];char author[50];char public_bk[50];int page;int price;}book_different_type; //변수구조선언(ex. struct name)를 원하는 이름으로 구문선언typedef struct{char ..