Skip to content

Instantly share code, notes, and snippets.

View riku1314's full-sized avatar

Rikuto_Watanabe riku1314

View GitHub Profile
#include <stdio.h>
#include <stdlib.h>
#include<omp.h>
#include "jikken.h"
int main(int argc, char *argv[])
{
/* ここに変数を定義します */
int size;
int i,j=0,k=0;
#include <stdio.h>
#include <stdlib.h>
#define ID "/*?? */"
#define NAME "/*?? */"
//----------------------------------
typedef enum { OK, EMPTY, FULL } result_t;
// キューの要素(ノード)を表す構造体
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
/* 関数のプロトタイプ宣言 */
unsigned char *read_ppm(char *fname, int *width, int *height);
void save_pgm(char *fname, unsigned char *gray, int width, int height);
void trans(unsigned char *src, unsigned char *out, int width, int height, int g[]);
void edge5(unsigned char *src, unsigned char *out, int width, int height, int threshold);
void edge6(unsigned char *src, unsigned char *out, int width, int height, int threshold);
void sobel(unsigned char *src,unsigned char *out,int width,int height,int threshold);
extern void make_matrix(unsigned int size, int flag,double **a,double **b,unsigned int number)
{
int i,j;
*a=(double*)malloc(sizeof(double)*size);
*b=(double*)malloc(sizeof(double)*size);
for(i=0;i<size;i++){
for(j=0;j<size;j++){
a[i][j]=flag;
b[i][j]=flag;
}
extern void make_matrix(unsigned int size, int flag,double **a,double **b,unsigned int number)
{
int i,j;
for(i=0;i<size;i++){
for(j=0;j<size;j++){
a[i][j]=flag;
b[i][j]=flag;
}
}
}