diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..6405099 --- /dev/null +++ b/.gitignore @@ -0,0 +1,17 @@ +petsc/ +petsc4py/ +openmpi-2.1.1/ +openmpi-2.1.1.tar.bz2 +tools/connec/__pycache__/ +tools/postprocessK/__pycache__/ +tools/postprocessK/kperm/__pycache__/ +tools/solver/__pycache__/ +tools/__pycache__/ +tools/generation/__pycache__/ +output/ +tests/integration/tmp_output/ +output/ +tests/integration/__pycache__/ +fftma_module/gen/build/ +tools/connec/conec2d +tools/connec/conec3d diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..dd1eb89 --- /dev/null +++ b/Makefile @@ -0,0 +1,15 @@ + +install: + source ./script_install.sh + +run: + ./run_simulation.sh + +fftma: + cd fftma_module/gen && python3 setup.py install --user + +binaries: + ./script_fortran.sh + +test: binaries + cd tests/integration && python3 -m unittest test.py \ No newline at end of file diff --git a/README.md b/README.md index aa8aff8..59276eb 100644 --- a/README.md +++ b/README.md @@ -1 +1,41 @@ -# simulacion-permeabilidad \ No newline at end of file +# Paralelización de simulación de permeabilidad + +## Instalación de las librerías (Python 3) + +``` +make install +``` + +## Generación de los binarios de conectividad + +``` +make binaries +``` + +## Correr la simulación + +``` +make run +``` + +## Correr los casos de prueba + +``` +make test +``` + +## Instalar el binario FFTMA + +``` +make fftma +``` + +## Instalación de las librerías (Python 2) + +El sistema actualmente se encuentra migrado a Python3 por lo que no se recomienda correr este script. + +``` +./script_install_py2.sh +``` + + diff --git a/bash/AnidadoTupac_solver_runner.sh b/bash/AnidadoTupac_solver_runner.sh new file mode 100755 index 0000000..2bf9fe5 --- /dev/null +++ b/bash/AnidadoTupac_solver_runner.sh @@ -0,0 +1,28 @@ +#!/usr/bin/env bash +#SBATCH -J test_fftma +#SBATCH -N 4 +#SBATCH --ntasks-per-node 32 +#SBATCH --output %j_output.out +#SBATCH -p free-rider +#SBATCH -t 2-23:00:00 +#source activate_env.sh +ulimit -v 115343360 + + + + +k=0 + +for i in {1..4} # num de jobs totales divido num de cores (redondear para arriba) +do + + for j in {1..1} #Numero de "carpetas" en donde resuelve simultanemente + do + mpirun -np 4 python ./tools/solver/Ndar.py $k 1 & # job, refinamiento + k=$(($k+1)) + done + wait + +done + +wait diff --git a/bash/Local_solver_runner.sh b/bash/Local_solver_runner.sh new file mode 100755 index 0000000..60a6caa --- /dev/null +++ b/bash/Local_solver_runner.sh @@ -0,0 +1,8 @@ +#!/usr/bin/env bash + + +for i in {0..49} +do + mpirun python ./tools/solver/Ndar.py $i 2 +done + diff --git a/bash/SolverTupac.sh b/bash/SolverTupac.sh new file mode 100755 index 0000000..6413c05 --- /dev/null +++ b/bash/SolverTupac.sh @@ -0,0 +1,25 @@ +#!/usr/bin/env bash +#SBATCH -J test_fftma +#SBATCH -N 1 +#SBATCH --ntasks-per-node 32 +#SBATCH --output %j_output.out +#SBATCH -p free-rider +#SBATCH -t 2-23:00:00 +source activate_env.sh +ulimit -v 115343360 + + +for i in {1..4} + do + mpirun -np 32 python ./tools/solver/Ndar.py ./paper2_SinRef/$i/ 1 # job, refinamiento + k=$(($k+1)) + + done + +for i in {1..4} + do + mpirun -np 32 python ./tools/solver/Ndar.py ./paper2_ref4/$i/ 4 # job, refinamiento + k=$(($k+1)) + + done + diff --git a/bash/Tupac_generta_media.sh b/bash/Tupac_generta_media.sh new file mode 100755 index 0000000..8c4582d --- /dev/null +++ b/bash/Tupac_generta_media.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +#SBATCH -J test_fftma +#SBATCH -N 4 +#SBATCH --ntasks-per-node 32 +#SBATCH --output %j_output.out +#SBATCH -p free-rider +#SBATCH -t 2-23:00:00 +source activate_env.sh +ulimit -v 115343360 + + +mpirun python -np 32 mpirunner.py diff --git a/bash/activate_env.sh b/bash/activate_env.sh new file mode 100755 index 0000000..08b6c13 --- /dev/null +++ b/bash/activate_env.sh @@ -0,0 +1,4 @@ +export PATH=$HOME/python/Python-2.7.13/:$PATH +export PYTHONPATH=$HOME/python/Python-2.7.13 +export PATH=$HOME/.local/bin:$PATH +export PETSC_DIR=$HOME/soft/petsc diff --git a/bash/run.sh b/bash/run.sh new file mode 100755 index 0000000..ac506ba --- /dev/null +++ b/bash/run.sh @@ -0,0 +1,12 @@ +#!/usr/bin/env bash +#SBATCH -J connec3d_parte2 +#SBATCH -N 2 +#SBATCH --ntasks-per-node 32 +#SBATCH --output %j_output.out +#SBATCH -p free-rider +#SBATCH -t 2-23:00:00 +source activate_env.sh +ulimit -v 115343360 + + +mpirun python -np 64 mpirunner.py diff --git a/bash/seq_solver.sh b/bash/seq_solver.sh new file mode 100755 index 0000000..43e783a --- /dev/null +++ b/bash/seq_solver.sh @@ -0,0 +1,13 @@ +#!/usr/bin/env bash + +#SBATCH -J connec3d_parte2 +#SBATCH -N 2 +#SBATCH --ntasks-per-node 32 +#SBATCH --output %j_output.out +#SBATCH -p free-rider +#SBATCH -t 2-23:00:00 + +for i in {0..4} + do + mpirun -np 32 python ./tools/solver/Ndar.py ./data/$i/ 1 # job, refinamiento + done diff --git a/config.ini b/config.ini new file mode 100644 index 0000000..acb1f7c --- /dev/null +++ b/config.ini @@ -0,0 +1,44 @@ +[General] +simDir=output +startJob=0 +[Iterables] +p=[10,39,15] +seeds=[5462,2] +lc=[4] +connectivity=[1,2,3] +variances=[1] + +[Generation] +Nx = 16 +Ny = 16 +Nz = 16 +variogram_type=1 +binary = yes +kh = 100 +kl = 0.01 +compute_lc = yes +lcBin=yes +genera=yes + + +[Connectivity] +keep_aspect= yes +block_size = 4 +indicators_MinBlockSize =4 +Max_sample_size = 12 +compGconec= 1 +conec=yes + + +[Solver] +num_of_cores = 1 +ref = 2 +solve = yes +rtol = 1e-4 + +[K-Postprocess] +MinBlockSize =1 +Max_sample_size = 4 +kperm=yes +postprocess=yes +SaveVfield=yes diff --git a/env.sh b/env.sh new file mode 100755 index 0000000..5624947 --- /dev/null +++ b/env.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +source ~/miniconda3/etc/profile.d/conda.sh +conda activate py2_7 +python --version \ No newline at end of file diff --git a/fftma_module/bin/bin.c b/fftma_module/bin/bin.c new file mode 100644 index 0000000..48f243a --- /dev/null +++ b/fftma_module/bin/bin.c @@ -0,0 +1,47 @@ +#include +#define SWITCH(a,b,temp) temp=b; b=a; a=temp; + + +int med5(double* A, long k, int* pj) +{ + + return 0; +} + + + + +int mom(double* A, long N, long i) +{ + long k=0, q, rest; + int j; + double* Anext; + rest=N%5; + Anext=(double*)malloc(sizeof(double)*(q+1?0));///??? + q=N-rest; + while(k pivot] + + k = len(low) + if i < k: + return median_of_medians(low,i) + elif i > k: + return median_of_medians(high,i-k-1) + else: #pivot = k + return pivot + +#Here are some example lists you can use to see how the algorithm works +#A = [1,2,3,4,5,1000,8,9,99] +#B = [1,2,3,4,5,6] +#print median_of_medians(A, 0) #should be 1 +#print median_of_medians(A,7) #should be 99 +#print median_of_medians(B,4) #should be 5 + +b=np.sort(A) +c=np.array([median_of_medians(A, i) for i in range(len(A))]) +print b +print c +print bool(np.sum(b==c)) diff --git a/fftma_module/bin/sort5.py b/fftma_module/bin/sort5.py new file mode 100644 index 0000000..6d0d5bb --- /dev/null +++ b/fftma_module/bin/sort5.py @@ -0,0 +1,31 @@ +import numpy as np +import random as rd + +MAX=100000 + +def med3(l): + if l[0] 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ +void FFTMA(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*PLUS GRADIENT CALCULATIONS - GRADIENTS ARE */ +/*CALCULATED FOR THE GRADUAL DEFORMATION PARAMETERS */ +/* */ +/*INPUT: */ +/*------- */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*DZoverDRHO: gradients calculated durin the gradual */ +/* deformation process */ +/* */ +/*OUTPUT: */ +/*------- */ +/*realout: structure defining a realization - */ +/*DYoverDRHO : structure with the output gradients */ +void FFTMA_gradient(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct gradients_mod *DZoverDRHO,struct realization_mod *realout,struct gradients_mod *DYoverDRHO); + + +/* GENERATION OF A GAUSSIAN WHITE NOISE VECTOR */ +/*input: */ +/* seed: seed */ +/* n: number of components in the vector */ +/*output: */ +/* realization: structure defining the realization*/ +void generate(long *seed, int n, struct realization_mod *realization); + +void ikrig(int option, struct statfacies_mod facies, int kk,struct welldata_mod data, struct variotable_mod variogram,struct grid_mod grid,float *krigout); + + +/*kriging */ +/*interpolation from ponctual data with simple */ +/*kriging. kriging is used to interpolate standard */ +/*Gaussian data only */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void kriging(int k,struct welldata_mod data,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realout); + + +/*CHOLESKY SIMULATION TECHNIQUE - LUSIM */ +/*appropriate for regular grids and small number */ +/*of points */ +/*input: */ +/*variogram: structure defining the variogram model */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ +void LUSIM(struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout); + + +void nor2any(struct cdf_mod *pcumulf,struct realization_mod *realin,struct realization_mod *realout); + +/*TURNS NORMAL NUMBERS INTO LOGNORMAL NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* normal numbers */ +/*typelog: --> 3: lognormal (natural) */ +/* --> 4: lognormal (log10) */ +/*output: */ +/*realout: structure defining a realization - */ +/* lognormal numbers */ +void nor2log(struct realization_mod *realin, int typelog, struct realization_mod *realout); + + +/*TURNS NORMAL NUMBERS INTO UNIFORM NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zero mean and unit variance */ +/*output: */ +/*realout: structure defining a realization - */ +/* uniform numbers */ +void nor2unif(struct realization_mod *realin,struct realization_mod *realout); + + +/*o_kriging */ +/*interpolation from ponctual data with ordinary kriging */ +/*o_kriging is used to interpolate standard Gaussian data*/ +/*only */ +/*INPUT */ +/*k: measurement type or rank */ +/*variogram: structure describing the variogram model */ +/*data: structure with the well data */ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the kriged realization */ +void o_kriging(int k,struct vario_mod variogram,struct welldata_mod data,struct grid_mod grid,struct realization_mod *realout); + + +/*od_kriging */ +/*interpolation from ponctual data with ordinary dual*/ +/*kriging. od_kriging is used to interpolate */ +/*Gaussian data only */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void od_kriging(int k,struct welldata_mod well,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realout); + + +/*PLURIGAUSSIAN METHOD */ +/*Starting from two independent Gaussian realizations Y1*/ +/*and Y2 with zero mean and unit variance, but possibly */ +/*different variogram models, a categorial realization is */ +/*built. */ +/*Truncation is performed on the basis of a mask with the */ +/*x-axis associated to Y1 and the y-axis associated to Y2 */ +/*This truncation may be stationary or non stationary */ +/*The mask consists of lines perpendicular to the Y1 and */ +/*Y2 axes. They define rectangular subregions attributed */ +/*to categories i = [1...ncat] */ +/*INPUT: */ +/*facies: structure defining the facies proportions in the*/ +/* whole reservoir model */ +/*ineq: structure defining the mask for truncation */ +/*Y1: first starting Gaussian realization */ +/*Y2: second starting realization - same length as Y1 */ +/*OUTPUT: */ +/*Y: output realization */ +void plurigau(struct statfacies_mod facies,struct inequalities_mod ineq,struct realization_mod *Y1, struct realization_mod *Y2, struct realization_mod *Y); + + +/*tr_kriging */ +/*kriging with an external drift */ +/*The trend is limited to a 2-term function */ +/*m(u) = a0+a1y(u) where y(u) is a secondary */ +/*external variable (e.g., seismic) */ +/*INPUT: */ +/*k: measurement type or rank */ +/*variogram: structure describing the variogram */ +/* model */ +/*data: structure with the well data */ +/*grid: structure defining the grid */ +/*y: secondary external variable */ +/*OUTPUT: */ +/*realout: kriged realization */ +void tr_kriging(int k, struct vario_mod variogram,struct welldata_mod data,struct grid_mod grid,struct realization_mod *Y,struct realization_mod *realout); + + +/*truncat */ +/*TRUNCATES A STANDARD GAUSSIAN REALIZATION */ +/*WITH THE TRUNCATED GAUSSIAN METHOD */ +/*truncation may be stationary or nonstationary*/ +/*INPUT: */ +/*facies: description of the facies proportions*/ +/*thresholds: may be an input if they have been*/ +/* previously computed */ +/*realin: structure defining a realization - */ +/* must be a standard normal */ +/*OUTPUT: */ +/*realout: structure defining a realization - */ +/*thresholds: Gaussian thresholds corresponding*/ +/* to the facies volume fractions if*/ +void truncat(struct statfacies_mod facies,struct realization_mod *realin,struct realization_mod *realout, struct statfacies_mod *thresholds); + + +/*TURNS UNIFORM NUMBERS INTO NORMAL NUMBERS*/ +/*INPUT: */ +/*realin: structure defining a realization - */ +/* uniform numbers */ +/*OUTPUT: */ +/*realout: structure defining a realization - */ +/* must have zero mean and unit variance */ +void unif2nor(struct realization_mod *realin,struct realization_mod *realout); + + +/*Wany2nor */ +/*converts any kind of continuous data to Gaussian data*/ +/*INPUT: */ +/*k: type of measurement */ +/*wellin: structure with the input well data */ +/*seed: seed */ +/*OUTPUT: */ +/*wellout: structure with the output well data */ +/*pcumulf: structure describing the experimental */ +/* cumulative distribution */ +void Wany2nor(int k, struct welldata_mod wellin, long *seed,struct welldata_mod *wellout, struct cdf_mod *pcumulf); + + +/*Wfac2nor0 */ +/*turns the facies well measurements into Gaussian data */ +/*intervals only are respected - spatial variability is */ +/*disregarded */ +/*USES vf2thres, deflimit,trungasdev */ +/*This step is required before performing kriging */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2nor0(int k,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout); + + +/*Wfac2nor1 */ +/*turns the facies well measurements into Gaussian data */ +/*Proceeds in 2 steps */ +/* 1- builds a realization Y = LZ (variability ensured) */ +/* 2- proposes successively local changes for Z to */ +/* respect the intervals-Metropoils-Hastings approach */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*variogram: structure defining the variogram model */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2nor1(int k,struct vario_mod variogram,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout); + + +/*Wfac2norPG0 */ +/*turns the facies well measurements into Gaussian data */ +/*intervals only are respected - spatial variability is */ +/*disregarded */ +/*method developed for pluriGaussian realizations */ +/*stationary and nonstationary truncation */ +/*This step is required before performing kriging */ +/*INPUT: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*idreal: identification of the starting realization */ +/* = 1 for realization 1 */ +/* = 2 for realization 2 */ +/*ineq: structure defining the mask for truncation */ +/*OUTPUT: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2norPG0(int k,struct inequalities_mod ineq,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,int idreal,struct welldata_mod *wellout); + + +/*Wfac2norPG1 */ +/*turns the facies well measurements into Gaussian data */ +/*Proceeds in 2 steps */ +/* 1- builds a realization Y = LZ (variability ensured) */ +/* 2- proposes successively local changes for Z to */ +/* respect the intervals-Metropoils-Hastings approach */ +/*method developed for pluriGaussian realizations */ +/*STATIONARY TRUNCATION */ +/*INPUT: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*ineq: structure describing the truncation mask */ +/*variogram1: structure describing the variogram model */ +/* for realization Y1 */ +/*variogram2: structure describing the variogram model */ +/* for realization Y2 */ +/*ineq: structure defining the mask for truncation */ +/*OUTPUT: */ +/*wellout1: structure with converted well data for */ +/*realization 1 - the kth vector */ +/*wellout2: structure with converted well data for */ +/*realization 2 - the kth vector */ +void Wfac2norPG1(int k,struct inequalities_mod ineq,struct vario_mod variogram1,struct vario_mod variogram2,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout1,struct welldata_mod *wellout2); + + +/*Wlog2nor */ +/*turns the log well measurements into std Gaussian data*/ +/*This step is required before performing kriging */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 3 --> natural log */ +/* code = 4 --> logarithm 10 */ +/*grid: structure defining the grid */ +/*stat: structure defining the statistics */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wlog2nor(int k, struct welldata_mod wellin,struct grid_mod grid,struct statistic_mod stat,struct welldata_mod *wellout); + + +/*Wnor2nor */ +/*converts Well Normal numbers to the standard Gaussian */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/*grid: structure defining the grid */ +/*stat: structure defining the statistics */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wnor2nor(int k, struct welldata_mod wellin,struct grid_mod grid,struct statistic_mod stat,struct welldata_mod *wellout); + + +/*Wunif2nor */ +/*converts Well uniform numbers to the standard Gaussian*/ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wunif2nor(int k, struct welldata_mod wellin,struct welldata_mod *wellout); + + + +#endif // define _CONDOR_H_ diff --git a/fftma_module/gen/Interface/genlib.h b/fftma_module/gen/Interface/genlib.h new file mode 100755 index 0000000..f5a490f --- /dev/null +++ b/fftma_module/gen/Interface/genlib.h @@ -0,0 +1,163 @@ +/* + * File: genlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file contains several definitions that form the + * core of a general-purpose ANSI C library developed by Eric + * Roberts. The goal of this library is to provide a basic + * set of tools and conventions that increase the readability + * of C programs, particularly as they are used in a teaching + * environment. + * + * The basic definitions provided by genlib.h are: + * + * 1. Declarations for several new "primitive" types + * (most importantly bool and string) that are + * used throughout the other libraries and + * applications as fundamental types. + * + * 2. A new set of functions for memory allocation. + * + * 3. A function for error handling. + */ + +#ifndef _genlib_h +#define _genlib_h + +#include +#include +#include + +/* Section 1 -- Define new "primitive" types */ + +/* + * Type: bool + * ---------- + * This type has two values, FALSE and TRUE, which are equal to 0 + * and 1, respectively. Most of the advantage of defining this type + * comes from readability because it allows the programmer to + * provide documentation that a variable will take on only one of + * these two values. Designing a portable representation, however, + * is surprisingly hard, because many libraries and some compilers + * define these names. The definitions are usually compatible but + * may still be flagged as errors. + */ + +#ifdef THINK_C + typedef int bool; +#else +# ifdef TRUE +# ifndef bool +# define bool int +# endif +# else +# ifdef bool +# define FALSE 0 +# define TRUE 1 +# else + typedef enum {FALSE, TRUE} bool; +# endif +# endif +#endif + +/* + * Type: string + * ------------ + * The type string is identical to the type char *, which is + * traditionally used in C programs. The main point of defining a + * new type is to improve program readability. At the abstraction + * levels at which the type string is used, it is usually not + * important to take the string apart into its component characters. + * Declaring it as a string emphasizes this atomicity. + */ + +typedef char *string; + +/* + * Constant: UNDEFINED + * ------------------- + * Besides NULL, the only other constant of pointer type is + * UNDEFINED, which is used in certain packages as a special + * sentinel to indicate an undefined pointer value. In many + * such contexts, NULL is a legitimate data value and is + * therefore inappropriate as a sentinel. + */ + +#define UNDEFINED ((void *) undefined_object) + +extern char undefined_object[]; + +/* Section 2 -- Memory allocation */ + +/* + * General notes: + * -------------- + * These functions provide a common interface for memory + * allocation. All functions in the library that allocate + * memory do so using GetBlock and FreeBlock. Even though + * the ANSI standard defines malloc and free for the same + * purpose, using GetBlock and FreeBlock provides greater + * compatibility with non-ANSI implementations, automatic + * out-of-memory error detection, and the possibility of + * substituting a garbage-collecting allocator. + */ + +/* + * Function: GetBlock + * Usage: ptr = (type) GetBlock(nbytes); + * ------------------------------------- + * GetBlock allocates a block of memory of the given size. If + * no memory is available, GetBlock generates an error. + */ + +void *GetBlock(size_t nbytes); + +/* + * Function: FreeBlock + * Usage: FreeBlock(ptr); + * ---------------------- + * FreeBlock frees the memory associated with ptr, which must + * have been allocated using GetBlock, New, or NewArray. + */ + +void FreeBlock(void *ptr); + +/* + * Macro: New + * Usage: p = New(pointer-type); + * ----------------------------- + * The New pseudofunction allocates enough space to hold an + * object of the type to which pointer-type points and returns + * a pointer to the newly allocated pointer. Note that + * "New" is different from the "new" operator used in C++; + * the former takes a pointer type and the latter takes the + * target type. + */ + +#define New(type) ((type) GetBlock(sizeof *((type) NULL))) + +/* + * Macro: NewArray + * Usage: p = NewArray(n, element-type); + * ------------------------------------- + * NewArray allocates enough space to hold an array of n + * values of the specified element type. + */ + +#define NewArray(n, type) ((type *) GetBlock((n) * sizeof(type))) + +/* Section 3 -- Basic error handling */ + +/* + * Function: Error + * Usage: Error(msg, ...) + * ---------------------- + * Error generates an error string, expanding % constructions + * appearing in the error message string just as printf does. + * After printing the error message, the program terminates. + */ + +void Error(string msg, ...); + +#endif diff --git a/fftma_module/gen/Interface/geostat.h b/fftma_module/gen/Interface/geostat.h new file mode 100755 index 0000000..5d48919 --- /dev/null +++ b/fftma_module/gen/Interface/geostat.h @@ -0,0 +1,690 @@ +#include +#include +#include +#include + + +#ifndef _GEOSTAT_H +#define _GEOSTAT_H + +#define NTAB 32 + +/* Modified january, the 22th 2004 */ +/* from float to double */ + +/* List of structures: */ +/* ------------------- */ + +/* vario_mod */ +/* variotable_mod*/ +/* grid_mod */ +/* welldata_mod */ +/* statfacies_mod */ +/* inequalities_mod */ +/* statistic_mod */ +/* grad_mod */ +/* gradients_mod */ +/* cdf_mod */ +/* realization_mod */ + + +/* List of functions: */ +/* ------------------ */ + +/* axes, cardsin, choldc, coordinates */ +/* covariance, cov_matrix, cov_value, */ +/* cubic, cutspectr, deflimit, dual_kri */ +/* exponential, fourt, funtrun1, G, gammf */ +/* gammln, gammp, gasdev, gaussian, gcf, */ +/* gen_cov_matrix, Ginv, gradual, cgrid, */ +/* gser, invtrun1, krig_stat, length, */ +/* LtimeZ, mat_vec, maxfactor, metrop, norm */ +/* normal, nugget, power, ran2, scal_vect, */ +/* solve3, sort, spherical, stable, statlog2nor */ +/* test_fract, trun1, trungasdev,vec_vec, */ +/* vf2gthres,polint */ + + + + +/*STRUCTURES*/ +/*----------*/ +/*variogram */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct vario_mod { + int Nvario; + int *vario; + double *alpha; + double *ap; + double *scf; + double *var; +}; + + + +/*variogram table */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct variotable_mod { + int number_of_variograms; + int *Nvario; + int *vario; + float *alpha; + float *ap; + float *scf; + float *var; +}; + + + + + + +/*grid */ +/*NX: number of gridblocks along the X axis*/ +/*NY: number of gridblocks along the Y axis*/ +/*NZ: number of gridblocks along the Z axis*/ +/*DX: gridblock length along the X axis */ +/*DY: gridblock length along the Y axis */ +/*DZ: gridblock length along the Z axis */ +/*Xo: X-cell number of the origin cell */ +/*Yo: Y-cell number of the origin cell */ +/*Zo: Z-cell number of the origin cell */ +struct grid_mod { + int NX, NY, NZ; + double DX,DY,DZ; + double Xo,Yo,Zo; +}; + + +/*well data */ +/*nwell: number of wells */ +/*n: number of measurement points per well */ +/* i = [0...nwell-1] */ +/*ntype: number of measurement types */ +/*code: status of the measurements i=[0...ntype-1] */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: uniform */ +/* --> 7: any */ +/*x: X-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*y: Y-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*z: Z-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*measure: values of the measurements */ +/* same kind of indexation, but repeated per type of */ +/* measurement */ +/* type 1 : */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/* type 2 : */ +/* i=[sum(n[k])... sum(n[k])+n[0]-1 ... 2*(sum(n[k])-1)]*/ +struct welldata_mod { + int nwell; + int *n; + int ntype; + int *code; + float *x; + float *y; + float *z; + float *measure; +}; + + + +/*volume fractions for facies */ +/*ncat: number of facies */ +/*nblock: number of gridblocks with different */ +/* volume fractions */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*vf: volume fractions for the first ncat-1 facies*/ +/* i = [0...ncat-2]*nblock */ +struct statfacies_mod { + int ncat; + int nblock; + float *vf; +}; + + +/*inequalities for truncated plurigaussian realizations*/ +/*only two basic realizations Y1 and Y2 are considered */ +/*Y1 and Y2 are independent */ +/*nsY1: number of unknown thresholds for Y1 */ +/*nsY2: number of unknown thresholds for Y2 */ +/*thresholds: vector with the thresholds and -10 and 10*/ +/* the output values are the Gaussian */ +/* thresholds */ +/* i = [0 ... n+1], n = nsY1+nsY2 */ +/* thresholds[n] = -10,thresholds[n+1] = 10 */ +/* given at the beginning */ +/*address_sY1: successive upper and lower bounds for */ +/* the different facies for Y1 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY1 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +/*address_sY2: successive upper and lower bounds for */ +/* the different facies for Y2 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY2 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +struct inequalities_mod { + int nsY1; + int nsY2; + float *thresholds; + int *address_sY1; + int *address_sY2; +}; + + +/*statistical data */ +/*type --> 0 : normal */ +/* --> 1 : natural log */ +/* --> 2 : log 10 */ +/*nblock_mean: number of gridblocks with different */ +/* means */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*mean: mean of the variable i = [0...nblock_mean] */ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, MEAN IS LOG MEAN ! */ +/*nblock_var: number of gridblocks with different */ +/* variances */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*variance: variance of the variable i = [0...nblock_var]*/ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, VAR IS LOG VAR ! */ +struct statistic_mod { + int type; + int nblock_mean; + double *mean; + int nblock_var; + double *variance; +}; + + +/*gradual deformation parameters */ +/*Nadded: number of complementary realizations */ +/*NZONES: number of subregions */ +/*rho: gradual deformation parameters */ +/*rho[NZONES*(0...Nadded)] */ +/*cellini[NZONES*(0...2)] lower cell bound for */ +/*for subregions along axes X,Y,Z */ +/*cellfin[NZONES*(0...2)] upper cell bound for */ +/*for subregions along axes X,Y,Z */ +struct grad_mod { + int Nadded, NZONES; + float *rho; + int *cellini, *cellfin; +}; + + +/*gradient structures */ +/*Nparam : number of parameters for which gradients are */ +/* required */ +/*Ncells : number of cells for which gradients are */ +/* calculated */ +/*grad : vector with the calculated gradients */ +/* dimension = Nparam*Ncells */ +/* this vector is organized as */ +/* 0 1...Ncells-1 for the first parameter followed*/ +/* Ncells....2*Ncells-1 for the second parameter */ +/* and so on */ +struct gradients_mod { + int Nparam,Ncells; + float *grad; +}; + + + +/*description of discretized cumulative distributions */ +/*n: number of points */ +/*x: values along the x axis i = [0...n-1] */ +/*fx: corresponding values for the cumulative */ +/* distribution i = [0...n-1] */ +struct cdf_mod { + int n; + float *x; + float *fx; +}; + + +/*realization */ +/*n: number of components */ +/*code: status of the realization */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: conditional standard Normal */ +/* --> 7: conditional non standard Normal */ +/* --> 8: conditional lognormal (neperien) */ +/* --> 9: conditional lognormal (log10) */ +/* --> 10: conditional facies */ +/* --> 11: uniform numbers */ +/* --> 12: conditional uniform numbers */ +/* --> 13: unconditional any type */ +/* --> 14: conditional any type */ +/*vector: realization vector i = [0...n-1] */ +struct realization_mod { + int n; + int code; + double *vector; +}; + +/*=====================================================*/ + +/*FUNCTIONS*/ +/*---------*/ + + +/*normalization of the anostropy axes */ +/*ap: anisotropy axes */ +/*scf: correlation lengths */ +/* The returned normalized axes are in ap */ +void axes(double *ap, double *scf, int N); + + +/*cardsin covariance value for lag h*/ +double cardsin(double h); + + +/*Cholesky decomposition of matrix C */ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, 0 <= i <= n */ +/* n : dimension of matrix Cij */ +/* */ +/* C is turned into the lower triangular cholesky matrix*/ +void choldc(double *C, int n); + + +/*computes the coordinates of a given cell */ +/*as numbers of cells along the X,Y and Z axes*/ +/*maille = i[0]+1+i[1]*NX+i[2]*NX*NY */ +/*input: */ +/*maille: number of the cell to identify */ +/*grid: structure defining the grid */ +/*output: */ +/*i: vector with the coordinates */ +void coordinates(int maille, int i[3],struct grid_mod grid); + + +/*builds the sampled covariance function */ +/*dimensions are even */ +/*covar: covariance array, vector of size*/ +/*1+NX*NY*NZ, covar[0] is a dead cell */ +/*variogram: structure defined above */ +/*grid: structure defined above */ +/*n: number of gridblocks along X,Y and Z*/ +void covariance(double *covar,struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*computation of the covariance matrix for the well data*/ +/*well coordinates are given as a number of cells */ +/*The dimension of C is given by well.nwell */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +/*grid: structure defined above */ +void cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, struct grid_mod grid); + + +/*calculation of the covariance value for a distance h */ +/*defined by i,j,k */ +/*available variogram model: */ +/* 1 -> exponential */ +/* 2 -> gaussian */ +/* 3 -> spherical */ +/* 4 -> cardsin */ +/* 5 -> stable */ +/* 6 -> gamma */ +/* 7 -> cubic */ +/* 8 -> nugget */ +/* 9 -> power */ +/*variogram: variogram with the structure defined above*/ +/*di: distance along the X axis */ +/*dj: distance along the Y axis */ +/*dk: distance along the Z axis */ +/* The returned value is the computed covariance value */ +double cov_value(struct vario_mod variogram,double di,double dj,double dk); + +/*cubic covariance value for lag h*/ +double cubic(double h); + + +/*truncation of the power spectrum to remove */ +/*high frequencies - isotropic case */ +/*covar: power spectrum */ +/*kx: number of cells to save along the x-axis */ +/*ky: number of cells to save along the y-axis */ +/*kz: number of cells to save along the z-axis */ +/*n[3]: number of cells along the X, Y and Z axes*/ +void cutspectr(float *covar, int kx, int ky, int kz, int n[3]); + + +/*defines the threshold interval for a facies x*/ +/*lim_inf: lower bound */ +/*lim_sup: upper bound */ +/*x: facies */ +/*thresholds: Gaussian threshold vector */ +/*facies: structure defined above */ +/*nblock: gridcell number of point x */ +void deflimit(double *plim_inf, double *plim_sup, float x, float *thresholds, struct statfacies_mod facies,int nblock); + + +/*kriges the realization considering weights */ +/*realin: input realization */ +/*variogram: structure defining the variogram */ +/*k: type of measure */ +/*well: structure defining the well data */ +/*grid: structure defined above */ +/*D: weight vector of length Ndata, Di, i = 0...Ndata-1*/ +/*The kriged realization is stored in realout */ +void dual_kri(struct realization_mod *realin, struct vario_mod variogram,struct welldata_mod well, struct grid_mod grid, double *D,struct realization_mod *realout); + + + +/*exponential covariance value for lag h*/ +double exponential(double h); + + +/*Fast Fourier Transform - Cooley-Tukey algorithm */ +/*datar: real part vector - to be transformed */ +/*datai: imaginary part vector - to be transformed */ +/*nn: number of gridblocks along the X,Y and Z axes */ +/*ndim: number of dimensions */ +/*ifrwd: non-zero for forward transform, 0 for inverse*/ +/*icplx: non-zero for complex data, 0 for real */ +/*workr: utility real part vector for storage */ +/*worki: utility imaginary part vector for storage */ +/*The transformed data are returned in datar and datai*/ +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx,double *workr,double *worki); + + +/*calculates F(x) = (1/a)*exp(-x*x/2)*/ +double funtrun1(double x); + + +/*cumulative standard normal value*/ +float G(float x); + + +/*gamma covariance value for lag h and exponent alpha*/ +double gammf(double h, double alpha); + + +/*returns the value ln(G(x))*/ +float gammln(float xx); + + +/*incomplete gamma fnction*/ +float gammp(float a, float x); + + +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran1(idum) as the source */ +/*of uniform deviates */ +/*idum: seed */ +double gasdev(long *idum, long *idum2, long *iy, long *iv, int *iset); + +/*gaussian covariance value for lag h*/ +double gaussian(double h); + + +/*incomplete gamma function evaluated by its continued */ +/*fraction represented as gammcf, also returns ln(G(a))*/ +/*as gln */ +void gcf(float *gammcf, float a, float x, float *gln); + + +/*computation of the covariance matrix for the well data*/ +/*well coordinates have no specific unit */ +/*The dimension of C is given by n */ +/*C defines the correlation between the first n wells */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +void gen_cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, int n); + + +/*Ginv */ +/*Computes the inverse of the standard normal cumulative*/ +/*distribution function with a numerical approximation */ +/*from Statistical Computing,by W.J. Kennedy, Jr. and */ +/*James E. Gentle, 1980, p. 95. */ +/*input : */ +/*p: cumulative probability value */ +float Ginv(float p); + + +/*gradual combination of 1 realization + Nadded */ +/*complementary realizations */ +/*rho: gradual deformation parameters */ +/*rho[0...NZONES*Nadded-1] */ +/*rangement des vecteurs colonnes les uns apres */ +/*les autres */ +/*Zo: starting realization */ +/*Zo[0...n] */ +/*Z: complementary realizations all stored */ +/*Z[0...n-1 n...2n-1 ...(Nadded-1)n...Nadded.n-1]*/ +/*sequentially in a single vector */ +/*Nadded: number of complementary realizations */ +/*n: number of components per realization */ +/*NZONES: number of subregions */ +/*grid: grid definition */ +void gradual(struct grad_mod grad,float *Zo,float *Z,float *Zfinal,int n,struct grid_mod grid); + + +/*computes the size of the underlying grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*incomplete gamma function evaluated by its series*/ +/*representation as gamser, also returns ln(G(a)) */ +/*as gln */ +void gser(float *gamser, float a, float x, float *gln); + + +/*calculates x so that x = invF(u) */ +/*F is the cumulative density function for the */ +/*function approximating the Gaussian function */ +/*u: uniform deviate between 0 and 1 */ +/*lim_inf: lower bound of the considered interval*/ +/*lim_sup: upper bound of the considered interval*/ +/*C: normalizing constant */ +double invtrun1(double u, double lim_inf, double lim_sup, double C); + + +/*computes the kriging mean and variance*/ +/*for the vector bi, i = [0...n-1] */ +void krig_stat(float *b, int n, struct vario_mod variogram, struct welldata_mod well, float *mean, float *var); + + +/* computes the number of gridblocks for one dimension*/ +/*N: initial number of gridblocks */ +/*i: considered direction */ +/*scf: correlation length */ +/*ap: normalized anisotropy axes */ +int length(int N, int i, double *scf, double *ap, double D, int Nvari); + +/*calculates L.Z/ +/* L : lower triangular matrix recorded */ +/* (per raws) as a vector with only components */ +/* Lij so that j <= i, i = [0...n-1] */ +/* Z : vector, Zi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Lij */ +/* */ +/* The solution vector is returned in b */ +void LtimeZ(double *L, float *Z, float *b, int n); + + +/*calculates C.x/ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* x : vector, xi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Cij */ +/* */ +/* The result vector is returned in b */ +void mat_vec(double *C, double *x, double *b, int n); + + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n); + +/*metrop returns a boolean varible that issues a */ +/*verdict on whether to accept a reconfiguration */ +/*defined by the probability ratio "ratio". */ +/*If ratio >= 1, metrop = 1(true), while if ratio < 1, */ +/*metrop is only true with probability "ratio" */ +int metrop(double ratio,long *idum,long *idum2, long *iy, long *iv); + + +/*2-norm of vector b */ +/* b : vector */ +/* n : length of b, bi, i = [0...n-1]*/ +/*returns the norm of b */ +double norm(double *b,int n); + + +/*value of g(x) where g is the normal function*/ +double normal(double x); + + +/*nugget covariance value for lag h*/ +double nugget(double h); + + +/*power covariance value for lag h and exponent alpha*/ +double power(double h,double alpha); + + +/*generates uniform deviates between 0 and 1*/ +/*idum: seed */ +double ran2(long *idum, long *idum2, long *iy, long *iv); + + + +/*calculates bt.b */ +/* b : vector, bi, i = [0...n-1] */ +/* n : length of b */ +/*returns the scalar product of b*/ +double scal_vec(double *b,int n); + + +/*solves the set of n linear equations Cx = D */ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* D : right-hand side vector, Di avec i = [0...n-1]*/ +/* n : dimension of matrix Cij */ +/* */ +/* The solution vector is returned in D */ +/* CONJUGATE GRADIENT method */ +void solve3(double *C, double *D, int n); + + +/*sorts an array [0...n-1] into ascending order using */ +/*shell */ +void sort(float n, float *arr); + + +/*spherical covariance value for lag h*/ +double spherical(double h); + + +/*stable covariance value for lag h and exponent alpha*/ +double stable(double h, double alpha); + + +/*conversion of log mean and variance to nor*/ +void statlog2nor(struct statistic_mod *pstat); + + +/*tries factor */ +/*pnum: number to be decomposed */ +/*fact: suggested factor */ +/*pmaxfac: memory to keep the greatest factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac); + + +/*calculates the integrale of an approximate function*/ +/*for the Gaussian function over an interval defined */ +/*by lim_inf and lim_sup */ +/*lim_inf: lower bound of the considered interval */ +/*lim_sup: upper bound of the considered interval */ +double trun1(double lim_inf, double lim_sup); + + +/*draws a truncated gaussian variable between lim_inf*/ +/*and lim_sup */ +/*idum: seed */ +double trungasdev(long *idum,double lim_inf,double lim_sup,long *idum2, long *iy, long iv[NTAB]); + +/* tb1.b2 */ +/* b1 : vector */ +/* b2 : vector */ +/* n : length of b1 and b2, bi, i = [0...n-1]*/ +/*returns the norm the product tb1.b2 */ +double vec_vec(double *b1, double *b2,int n); + + +/*turns the volume fractions into Gaussian thresholds */ +/*facies: structure defined above */ +/*thresholds: output threshold vector fot i = [0...n-1]*/ +/*where n is the number of facies-1 */ +/*USES normal*/ +void vf2gthres(struct statfacies_mod facies,float *thresholds); + +void polint(float xa[],float ya[],int n,float x, float *y,float *dy); + + + +#endif diff --git a/fftma_module/gen/Interface/pressure.h b/fftma_module/gen/Interface/pressure.h new file mode 100755 index 0000000..826da7e --- /dev/null +++ b/fftma_module/gen/Interface/pressure.h @@ -0,0 +1,21 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _PRESSURE_H +#define _PRESSURE_H + +/*STRUCTURES*/ +/*----------*/ + +/* pressure_mod */ +/* x: macroscopic gradient value in x direction */ +/* y: macroscopic gradient value in x direction */ +/* z: macroscopic gradient value in x direction */ +struct pressure_mod { + double x,y,z; +}; + + +#endif // define _PRESSURE_H diff --git a/fftma_module/gen/Interface/simpio.h b/fftma_module/gen/Interface/simpio.h new file mode 100755 index 0000000..ca1efc9 --- /dev/null +++ b/fftma_module/gen/Interface/simpio.h @@ -0,0 +1,75 @@ +/* + * File: simpio.h + * Version: 1.0 + * Last modified on Wed Apr 27 07:29:13 1994 by eroberts + * ----------------------------------------------------- + * This interface provides access to a simple package of + * functions that simplify the reading of input data. + */ + +#ifndef _simpio_h +#define _simpio_h + +#include "genlib.h" + +/* + * Function: GetInteger + * Usage: i = GetInteger(); + * ------------------------ + * GetInteger reads a line of text from standard input and scans + * it as an integer. The integer value is returned. If an + * integer cannot be scanned or if more characters follow the + * number, the user is given a chance to retry. + */ + +int GetInteger(void); + +/* + * Function: GetLong + * Usage: l = GetLong(); + * --------------------- + * GetLong reads a line of text from standard input and scans + * it as a long integer. The value is returned as a long. + * If an integer cannot be scanned or if more characters follow + * the number, the user is given a chance to retry. + */ + +long GetLong(void); + +/* + * Function: GetReal + * Usage: x = GetReal(); + * --------------------- + * GetReal reads a line of text from standard input and scans + * it as a double. If the number cannot be scanned or if extra + * characters follow after the number ends, the user is given + * a chance to reenter the value. + */ + +double GetReal(void); + +/* + * Function: GetLine + * Usage: s = GetLine(); + * --------------------- + * GetLine reads a line of text from standard input and returns + * the line as a string. The newline character that terminates + * the input is not stored as part of the string. + */ + +string GetLine(void); + +/* + * Function: ReadLine + * Usage: s = ReadLine(infile); + * ---------------------------- + * ReadLine reads a line of text from the input file and + * returns the line as a string. The newline character + * that terminates the input is not stored as part of the + * string. The ReadLine function returns NULL if infile + * is at the end-of-file position. + */ + +string ReadLine(FILE *infile); + +#endif diff --git a/fftma_module/gen/Interface/toolsFFTMA.h b/fftma_module/gen/Interface/toolsFFTMA.h new file mode 100755 index 0000000..e2941de --- /dev/null +++ b/fftma_module/gen/Interface/toolsFFTMA.h @@ -0,0 +1,80 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _TOOLSFFTMA_H +#define _TOOLSFFTMA_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* kgeneration, FFTMA2, prebuild_gwn, build_real, addstat2, clean_real */ + + +/*FUNCTIONS*/ +/*----------*/ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y2, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise); + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver); + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal); + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2); + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout); + +#endif // define _TOOLSFFTMA_H diff --git a/fftma_module/gen/Interface/toolsIO.h b/fftma_module/gen/Interface/toolsIO.h new file mode 100755 index 0000000..8e22ea5 --- /dev/null +++ b/fftma_module/gen/Interface/toolsIO.h @@ -0,0 +1,91 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "pressure.h" + +#ifndef _TOOLSIO_H +#define _TOOLSIO_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* writefile,writefile_bin,readfile_bin,inputdata,inputfiledata,readdata,debuginput */ +/* testmemory, testopenfile */ + + +/*FUNCTIONS*/ +/*----------*/ + +/* Lecture dans un fichier */ + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +/* void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,struct realization_mod *Kfield, char *argv[]); */ + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +/* readfile_bin */ +/* */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin); + + +/* Writefile */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile( string filename, struct realization_mod *realin); + +/* Writefile_bin */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin( string filename, struct realization_mod *realin); + + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ +void debuginput(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite); + +/* Allocation test */ +void testmemory(double *realint); + +/* Test open file */ +void testopenfile(FILE *fp); + +#endif // define _TOOLSIO_H diff --git a/fftma_module/gen/LIBCS106X/._.DS_Store b/fftma_module/gen/LIBCS106X/._.DS_Store new file mode 100755 index 0000000..c9474ea Binary files /dev/null and b/fftma_module/gen/LIBCS106X/._.DS_Store differ diff --git a/fftma_module/gen/LIBCS106X/Makefile.libCS106X b/fftma_module/gen/LIBCS106X/Makefile.libCS106X new file mode 100755 index 0000000..ccef6b8 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/Makefile.libCS106X @@ -0,0 +1,13 @@ +CC = cc +CCFLAG = + +LIB = libCS106X_${ARCH}.a +%.o: %.c + $(CC) $(CCFLAG) -c $< + + +$(LIB) : genlib.o random.o simpio.o strlib.o symtab.o scanadt.o stack.o + ar r $@ $? + +clean : + rm *.o diff --git a/fftma_module/gen/LIBCS106X/Makefile_debug b/fftma_module/gen/LIBCS106X/Makefile_debug new file mode 100755 index 0000000..0ecafef --- /dev/null +++ b/fftma_module/gen/LIBCS106X/Makefile_debug @@ -0,0 +1,21 @@ +# CC = gcc +# CCFLAG = + +ifeq (${ARCH},sun) + CC = cc + CCFLAG = -g +endif +ifeq (${ARCH},linux) + CC = gcc + CCFLAG = -g +endif +LIB = libCS106X_debug_${ARCH}.a +%.o: %.c + $(CC) $(CCFLAG) -c $< + + +$(LIB) : genlib.o random.o simpio.o strlib.o symtab.o scanadt.o stack.o + ar r $@ $? + +clean : + rm *.o diff --git a/fftma_module/gen/LIBCS106X/genlib.c b/fftma_module/gen/LIBCS106X/genlib.c new file mode 100755 index 0000000..1a106f6 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/genlib.c @@ -0,0 +1,63 @@ +/* + * File: genlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file implements the general C library package. See the + * interface description in genlib.h for details. + */ + +#include +#include +#include +#include + +#include "genlib.h" + +/* + * Constants: + * ---------- + * ErrorExitStatus -- Status value used in exit call + */ + +#define ErrorExitStatus 1 + +/* Section 1 -- Define new "primitive" types */ + +/* + * Constant: UNDEFINED + * ------------------- + * This entry defines the target of the UNDEFINED constant. + */ + +char undefined_object[] = "UNDEFINED"; + +/* Section 2 -- Memory allocation */ + +void *GetBlock(size_t nbytes) +{ + void *result; + + result = malloc(nbytes); + if (result == NULL) Error("No memory available"); + return (result); +} + +void FreeBlock(void *ptr) +{ + free(ptr); +} + +/* Section 3 -- Basic error handling */ + +void Error(string msg, ...) +{ + va_list args; + + va_start(args, msg); + fprintf(stderr, "Error: "); + vfprintf(stderr, msg, args); + fprintf(stderr, "\n"); + va_end(args); + exit(ErrorExitStatus); +} diff --git a/fftma_module/gen/LIBCS106X/genlib.h b/fftma_module/gen/LIBCS106X/genlib.h new file mode 100755 index 0000000..f5a490f --- /dev/null +++ b/fftma_module/gen/LIBCS106X/genlib.h @@ -0,0 +1,163 @@ +/* + * File: genlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file contains several definitions that form the + * core of a general-purpose ANSI C library developed by Eric + * Roberts. The goal of this library is to provide a basic + * set of tools and conventions that increase the readability + * of C programs, particularly as they are used in a teaching + * environment. + * + * The basic definitions provided by genlib.h are: + * + * 1. Declarations for several new "primitive" types + * (most importantly bool and string) that are + * used throughout the other libraries and + * applications as fundamental types. + * + * 2. A new set of functions for memory allocation. + * + * 3. A function for error handling. + */ + +#ifndef _genlib_h +#define _genlib_h + +#include +#include +#include + +/* Section 1 -- Define new "primitive" types */ + +/* + * Type: bool + * ---------- + * This type has two values, FALSE and TRUE, which are equal to 0 + * and 1, respectively. Most of the advantage of defining this type + * comes from readability because it allows the programmer to + * provide documentation that a variable will take on only one of + * these two values. Designing a portable representation, however, + * is surprisingly hard, because many libraries and some compilers + * define these names. The definitions are usually compatible but + * may still be flagged as errors. + */ + +#ifdef THINK_C + typedef int bool; +#else +# ifdef TRUE +# ifndef bool +# define bool int +# endif +# else +# ifdef bool +# define FALSE 0 +# define TRUE 1 +# else + typedef enum {FALSE, TRUE} bool; +# endif +# endif +#endif + +/* + * Type: string + * ------------ + * The type string is identical to the type char *, which is + * traditionally used in C programs. The main point of defining a + * new type is to improve program readability. At the abstraction + * levels at which the type string is used, it is usually not + * important to take the string apart into its component characters. + * Declaring it as a string emphasizes this atomicity. + */ + +typedef char *string; + +/* + * Constant: UNDEFINED + * ------------------- + * Besides NULL, the only other constant of pointer type is + * UNDEFINED, which is used in certain packages as a special + * sentinel to indicate an undefined pointer value. In many + * such contexts, NULL is a legitimate data value and is + * therefore inappropriate as a sentinel. + */ + +#define UNDEFINED ((void *) undefined_object) + +extern char undefined_object[]; + +/* Section 2 -- Memory allocation */ + +/* + * General notes: + * -------------- + * These functions provide a common interface for memory + * allocation. All functions in the library that allocate + * memory do so using GetBlock and FreeBlock. Even though + * the ANSI standard defines malloc and free for the same + * purpose, using GetBlock and FreeBlock provides greater + * compatibility with non-ANSI implementations, automatic + * out-of-memory error detection, and the possibility of + * substituting a garbage-collecting allocator. + */ + +/* + * Function: GetBlock + * Usage: ptr = (type) GetBlock(nbytes); + * ------------------------------------- + * GetBlock allocates a block of memory of the given size. If + * no memory is available, GetBlock generates an error. + */ + +void *GetBlock(size_t nbytes); + +/* + * Function: FreeBlock + * Usage: FreeBlock(ptr); + * ---------------------- + * FreeBlock frees the memory associated with ptr, which must + * have been allocated using GetBlock, New, or NewArray. + */ + +void FreeBlock(void *ptr); + +/* + * Macro: New + * Usage: p = New(pointer-type); + * ----------------------------- + * The New pseudofunction allocates enough space to hold an + * object of the type to which pointer-type points and returns + * a pointer to the newly allocated pointer. Note that + * "New" is different from the "new" operator used in C++; + * the former takes a pointer type and the latter takes the + * target type. + */ + +#define New(type) ((type) GetBlock(sizeof *((type) NULL))) + +/* + * Macro: NewArray + * Usage: p = NewArray(n, element-type); + * ------------------------------------- + * NewArray allocates enough space to hold an array of n + * values of the specified element type. + */ + +#define NewArray(n, type) ((type *) GetBlock((n) * sizeof(type))) + +/* Section 3 -- Basic error handling */ + +/* + * Function: Error + * Usage: Error(msg, ...) + * ---------------------- + * Error generates an error string, expanding % constructions + * appearing in the error message string just as printf does. + * After printing the error message, the program terminates. + */ + +void Error(string msg, ...); + +#endif diff --git a/fftma_module/gen/LIBCS106X/random.c b/fftma_module/gen/LIBCS106X/random.c new file mode 100755 index 0000000..696312d --- /dev/null +++ b/fftma_module/gen/LIBCS106X/random.c @@ -0,0 +1,77 @@ +/* + * File: random.c + * Version: 1.0 + * Last modified on Mon Sep 13 10:42:45 1993 by eroberts + * ----------------------------------------------------- + * This file implements the random.h interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "random.h" + +/* + * Function: Randomize + * ------------------- + * This function operates by setting the random number + * seed to the current time. The srand function is + * provided by the library and requires an + * integer argument. The time function is provided + * by . + */ + +void Randomize(void) +{ + srand((int) time(NULL)); +} + +/* + * Function: RandomInteger + * ----------------------- + * This function first obtains a random integer in + * the range [0..RAND_MAX] by applying four steps: + * (1) Generate a real number between 0 and 1. + * (2) Scale it to the appropriate range size. + * (3) Truncate the value to an integer. + * (4) Translate it to the appropriate starting point. + */ + +int RandomInteger(int low, int high) +{ + int k; + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + k = (int) (d * (high - low + 1)); + return (low + k); +} + +/* + * Function: RandomReal + * -------------------- + * The implementation of RandomReal is similar to that + * of RandomInteger, without the truncation step. + */ + +double RandomReal(double low, double high) +{ + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + return (low + d * (high - low)); +} + +/* + * Function: RandomChance + * ---------------------- + * This function uses RandomReal to generate a number + * between 0 and 100, which it then compares to p. + */ + +bool RandomChance(double p) +{ + return (RandomReal(0, 1) < p); +} diff --git a/fftma_module/gen/LIBCS106X/random.h b/fftma_module/gen/LIBCS106X/random.h new file mode 100755 index 0000000..881af5f --- /dev/null +++ b/fftma_module/gen/LIBCS106X/random.h @@ -0,0 +1,73 @@ +/* + * File: random.h + * Version: 1.0 + * Last modified on Fri Jul 22 16:44:36 1994 by eroberts + * ----------------------------------------------------- + * This interface provides several functions for generating + * pseudo-random numbers. + */ + +#ifndef _random_h +#define _random_h + +#include "genlib.h" +#include + +/* + * Constant: RAND_MAX + * ------------------ + * Unfortunately, several libraries that supposedly conform to + * the ANSI standard do not define RAND_MAX in . To + * reduce portability problems, this interface defines RAND_MAX + * to be the largest positive integer if it is undefined. + */ + +#ifndef RAND_MAX +# define RAND_MAX ((int) ((unsigned) ~0 >> 1)) +#endif + +/* + * Function: Randomize + * Usage: Randomize(); + * ------------------- + * This function sets the random seed so that the random sequence + * is unpredictable. During the debugging phase, it is best not + * to call this function, so that program behavior is repeatable. + */ + +void Randomize(void); + +/* + * Function: RandomInteger + * Usage: n = RandomInteger(low, high); + * ------------------------------------ + * This function returns a random integer in the range low to high, + * inclusive. + */ + +int RandomInteger(int low, int high); + +/* + * Function: RandomReal + * Usage: d = RandomReal(low, high); + * --------------------------------- + * This function returns a random real number in the half-open + * interval [low .. high), meaning that the result is always + * greater than or equal to low but strictly less than high. + */ + +double RandomReal(double low, double high); + +/* + * Function: RandomChance + * Usage: if (RandomChance(p)) . . . + * --------------------------------- + * The RandomChance function returns TRUE with the probability + * indicated by p, which should be a floating-point number between + * 0 (meaning never) and 1 (meaning always). For example, calling + * RandomChance(.30) returns TRUE 30 percent of the time. + */ + +bool RandomChance(double p); + +#endif diff --git a/fftma_module/gen/LIBCS106X/scanadt.c b/fftma_module/gen/LIBCS106X/scanadt.c new file mode 100755 index 0000000..bd887c5 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/scanadt.c @@ -0,0 +1,162 @@ +/* + * File: scanadt.c + * --------------- + * This file implements the scanadt.h interface. + */ + +#include +#include +#include "genlib.h" +#include "strlib.h" +#include "scanadt.h" + +/* + * Type: scannerCDT + * ---------------- + * This structure is the concrete representation of the type + * scannerADT, which is exported by this interface. Its purpose + * is to maintain the state of the scanner between calls. The + * details of the representation are invisible to the client, + * but consist of the following fields: + * + * str -- Copy of string passed to SetScannerString + * len -- Length of string, saved for efficiency + * cp -- Current character position in the string + * savedToken -- String saved by SaveToken (NULL indicates none) + * spaceOption -- Setting of the space option extension + */ + +struct scannerCDT { + string str; + int len; + int cp; + string savedToken; + spaceOptionT spaceOption; +}; + +/* Private function prototypes */ + +static void SkipSpaces(scannerADT scanner); +static int ScanToEndOfIdentifier(scannerADT scanner); + +/* Exported entries */ + +scannerADT NewScanner(void) +{ + scannerADT scanner; + + scanner = New(scannerADT); + scanner->str = NULL; + scanner->spaceOption = PreserveSpaces; + return (scanner); +} + +void FreeScanner(scannerADT scanner) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + FreeBlock(scanner); +} + +void SetScannerString(scannerADT scanner, string str) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + scanner->str = CopyString(str); + scanner->len = StringLength(str); + scanner->cp = 0; + scanner->savedToken = NULL; +} + +string ReadToken(scannerADT scanner) +{ + char ch; + string token; + int start, finish; + + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + token = scanner->savedToken; + scanner->savedToken = NULL; + return (token); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + start = finish = scanner->cp; + if (start >= scanner->len) return (CopyString("")); + ch = scanner->str[scanner->cp]; + if (isalnum(ch)) { + finish = ScanToEndOfIdentifier(scanner); + } else { + scanner->cp++; + } + return (SubString(scanner->str, start, finish)); +} + +bool MoreTokensExist(scannerADT scanner) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + return (!StringEqual(scanner->savedToken, "")); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + return (scanner->cp < scanner->len); +} + +void SaveToken(scannerADT scanner, string token) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + Error("Token has already been saved"); + } + scanner->savedToken = token; +} + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option) +{ + scanner->spaceOption = option; +} + +spaceOptionT GetScannerSpaceOption(scannerADT scanner) +{ + return (scanner->spaceOption); +} + +/* Private functions */ + +/* + * Function: SkipSpaces + * Usage: SkipSpaces(scanner); + * --------------------------- + * This function advances the position of the scanner until the + * current character is not a whitespace character. + */ + +static void SkipSpaces(scannerADT scanner) +{ + while (isspace(scanner->str[scanner->cp])) { + scanner->cp++; + } +} + +/* + * Function: ScanToEndOfIdentifier + * Usage: finish = ScanToEndOfIdentifier(scanner); + * ----------------------------------------------- + * This function advances the position of the scanner until it + * reaches the end of a sequence of letters or digits that make + * up an identifier. The return value is the index of the last + * character in the identifier; the value of the stored index + * cp is the first character after that. + */ + +static int ScanToEndOfIdentifier(scannerADT scanner) +{ + while (isalnum(scanner->str[scanner->cp])) { + scanner->cp++; + } + return (scanner->cp - 1); +} diff --git a/fftma_module/gen/LIBCS106X/scanadt.h b/fftma_module/gen/LIBCS106X/scanadt.h new file mode 100755 index 0000000..1da09c3 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/scanadt.h @@ -0,0 +1,159 @@ +/* + * File: scanadt.h + * --------------- + * This file is the interface to a module that exports an abstract + * data type to facilitate dividing a string into logical units + * called "tokens," which are either + * + * 1. Strings of consecutive letters and digits representing words + * 2. One-character strings representing punctuation or separators + * + * To use this package, you must first create an instance of a + * scannerADT by calling + * + * scanner = NewScanner(); + * + * All other calls to the scanner package take this variable as their + * first argument to identify a particular instance of the abstract + * scanner type. + * + * You initialize the scanner to hold a particular string by calling + * + * SetScannerString(scanner, str); + * + * where str is the string from which tokens should be read. To + * retrieve each individual token, you make the following call: + * + * token = ReadToken(scanner); + * + * To determine whether any tokens remain to be read, you can call + * the predicate function MoreTokensExist(scanner). The ReadToken + * function returns the empty string after the last token is read. + * + * The following code fragment serves as an idiom for processing + * each token in the string inputString: + * + * scanner = NewScanner(); + * SetScannerString(scanner, inputString); + * while (MoreTokensExist(scanner)) { + * token = ReadToken(scanner); + * . . . process the token . . . + * } + * + * This version of scanadt.h also supports the following extensions, + * which are documented later in the interface: + * + * SaveToken + * SetScannerSpaceOption + */ + +#ifndef _scanadt_h +#define _scanadt_h + +#include "genlib.h" + +/* + * Type: scannerADT + * ---------------- + * This type is the abstract type used to represent a single instance + * of a scanner. As with any abstract type, the details of the + * internal representation are hidden from the client. + */ + +typedef struct scannerCDT *scannerADT; + +/* + * Function: NewScanner + * Usage: scanner = NewScanner(); + * ------------------------------ + * This function creates a new scanner instance. All other functions + * in this interface take this scanner value as their first argument + * so that they can identify what particular instance of the scanner + * is in use. This design makes it possible for clients to have more + * than one scanner process active at the same time. + */ + +scannerADT NewScanner(void); + +/* + * Function: FreeScanner + * Usage: FreeScanner(scanner); + * ---------------------------- + * This function frees the storage associated with scanner. + */ + +void FreeScanner(scannerADT scanner); + +/* + * Function: SetScannerString + * Usage: SetScannerString(scanner, str); + * -------------------------------------- + * This function initializes the scanner so that it will start + * extracting tokens from the string str. + */ + +void SetScannerString(scannerADT scanner, string str); + +/* + * Function: ReadToken + * Usage: token = ReadToken(scanner); + * ---------------------------------- + * This function returns the next token from scanner. If + * ReadToken is called when no tokens are available, it returns + * the empty string. The token returned by ReadToken is always + * allocated in the heap, which means that clients can call + * FreeBlock when the token is no longer needed. + */ + +string ReadToken(scannerADT scanner); + +/* + * Function: MoreTokensExist + * Usage: if (MoreTokensExist(scanner)) . . . + * ------------------------------------------ + * This function returns TRUE as long as there are additional + * tokens for the scanner to read. + */ + +bool MoreTokensExist(scannerADT scanner); + +/* + * Function: SaveToken + * Usage: SaveToken(scanner, token); + * --------------------------------- + * This function stores the token in the scanner data structure + * in such a way that the next time ReadToken is called, it will + * return that token without reading any additional characters + * from the input. + */ + +void SaveToken(scannerADT scanner, string token); + +/* + * Functions: SetScannerSpaceOption, GetScannerSpaceOption + * Usage: SetScannerSpaceOption(scanner, option); + * option = GetScannerSpaceOption(scanner); + * ----------------------------------------------- + * The SetScannerSpaceOption function controls whether the scanner + * ignores whitespace characters or treats them as valid tokens. + * By default, the ReadToken function treats whitespace characters, + * such as spaces and tabs, just like any other punctuation mark. + * If, however, you call + * + * SetScannerSpaceOption(scanner, IgnoreSpaces); + * + * the scanner will skip over any white space before reading a token. + * You can restore the original behavior by calling + * + * SetScannerSpaceOption(scanner, PreserveSpaces); + * + * The GetScannerSpaceOption function returns the current setting + * of this option. + */ + +typedef enum { PreserveSpaces, IgnoreSpaces } spaceOptionT; + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option); +spaceOptionT GetScannerSpaceOption(scannerADT scanner); + +#endif diff --git a/fftma_module/gen/LIBCS106X/simpio.c b/fftma_module/gen/LIBCS106X/simpio.c new file mode 100755 index 0000000..02e4025 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/simpio.c @@ -0,0 +1,157 @@ +/* + * File: simpio.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the simpio.h interface. + */ + +#include +#include + +#include "genlib.h" +#include "strlib.h" +#include "simpio.h" + +/* + * Constants: + * ---------- + * InitialBufferSize -- Initial buffer size for ReadLine + */ + +#define InitialBufferSize 120 + +/* Exported entries */ + +/* + * Functions: GetInteger, GetLong, GetReal + * --------------------------------------- + * These functions first read a line and then call sscanf to + * translate the number. Reading an entire line is essential to + * good error recovery, because the characters after the point of + * error would otherwise remain in the input buffer and confuse + * subsequent input operations. The sscanf line allows white space + * before and after the number but no other extraneous characters. + */ + +int GetInteger(void) +{ + string line; + int value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %d %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +long GetLong(void) +{ + string line; + long value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %ld %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +double GetReal(void) +{ + string line; + double value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %lf %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter a real number\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +/* + * Function: GetLine + * ----------------- + * This function is a simple wrapper; all the work is done by + * ReadLine. + */ + +string GetLine(void) +{ + return (ReadLine(stdin)); +} + +/* + * Function: ReadLine + * ------------------ + * This function operates by reading characters from the file + * into a dynamically allocated buffer. If the buffer becomes + * full before the end of the line is reached, a new buffer + * twice the size of the previous one is allocated. + */ + +string ReadLine(FILE *infile) +{ + string line, nline; + int n, ch, size; + + n = 0; + size = InitialBufferSize; + line = GetBlock(size + 1); + while ((ch = getc(infile)) != '\n' && ch != EOF) { + if (n == size) { + size *= 2; + nline = (string) GetBlock(size + 1); + strncpy(nline, line, n); + FreeBlock(line); + line = nline; + } + line[n++] = ch; + } + if (n == 0 && ch == EOF) { + FreeBlock(line); + return (NULL); + } + line[n] = '\0'; + nline = (string) GetBlock(n + 1); + strcpy(nline, line); + FreeBlock(line); + return (nline); +} diff --git a/fftma_module/gen/LIBCS106X/simpio.h b/fftma_module/gen/LIBCS106X/simpio.h new file mode 100755 index 0000000..ca1efc9 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/simpio.h @@ -0,0 +1,75 @@ +/* + * File: simpio.h + * Version: 1.0 + * Last modified on Wed Apr 27 07:29:13 1994 by eroberts + * ----------------------------------------------------- + * This interface provides access to a simple package of + * functions that simplify the reading of input data. + */ + +#ifndef _simpio_h +#define _simpio_h + +#include "genlib.h" + +/* + * Function: GetInteger + * Usage: i = GetInteger(); + * ------------------------ + * GetInteger reads a line of text from standard input and scans + * it as an integer. The integer value is returned. If an + * integer cannot be scanned or if more characters follow the + * number, the user is given a chance to retry. + */ + +int GetInteger(void); + +/* + * Function: GetLong + * Usage: l = GetLong(); + * --------------------- + * GetLong reads a line of text from standard input and scans + * it as a long integer. The value is returned as a long. + * If an integer cannot be scanned or if more characters follow + * the number, the user is given a chance to retry. + */ + +long GetLong(void); + +/* + * Function: GetReal + * Usage: x = GetReal(); + * --------------------- + * GetReal reads a line of text from standard input and scans + * it as a double. If the number cannot be scanned or if extra + * characters follow after the number ends, the user is given + * a chance to reenter the value. + */ + +double GetReal(void); + +/* + * Function: GetLine + * Usage: s = GetLine(); + * --------------------- + * GetLine reads a line of text from standard input and returns + * the line as a string. The newline character that terminates + * the input is not stored as part of the string. + */ + +string GetLine(void); + +/* + * Function: ReadLine + * Usage: s = ReadLine(infile); + * ---------------------------- + * ReadLine reads a line of text from the input file and + * returns the line as a string. The newline character + * that terminates the input is not stored as part of the + * string. The ReadLine function returns NULL if infile + * is at the end-of-file position. + */ + +string ReadLine(FILE *infile); + +#endif diff --git a/fftma_module/gen/LIBCS106X/stack.c b/fftma_module/gen/LIBCS106X/stack.c new file mode 100755 index 0000000..8bd5ee4 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/stack.c @@ -0,0 +1,122 @@ +/* + * File: stack.c + * ------------- + * This file implements the stack.h interface. Note that the + * implementation is independent of the type of value stored + * in the stack. That type is defined by the interface as + * the type name stackElementT. + */ + +#include +#include "genlib.h" +#include "stack.h" + +/* + * Constant: InitialStackSize + * -------------------------- + * This constant defines the initial size of the stack array. + * Any positive value will work correctly, although changing + * this parameter can affect performance. Making this value + * larger postpones the first reallocation but causes stacks + * to consume more memory. + */ + +#define InitialStackSize 100 + +/* + * Type: stackCDT + * -------------- + * The type stackCDT is the concrete representation of the type + * stackADT defined by the interface. In this implementation, + * the elements are stored in a dynamic array that doubles in + * size if the old stack becomes full. + */ + +struct stackCDT { + stackElementT *elements; + int count; + int size; +}; + +/* Private function prototypes */ + +static void ExpandStack(stackADT stack); + +/* Exported entries */ + +stackADT NewStack(void) +{ + stackADT stack; + + stack = New(stackADT); + stack->elements = NewArray(InitialStackSize, stackElementT); + stack->count = 0; + stack->size = InitialStackSize; + return (stack); +} + +void FreeStack(stackADT stack) +{ + FreeBlock(stack->elements); + FreeBlock(stack); +} + +void Push(stackADT stack, stackElementT element) +{ + if (stack->count == stack->size) ExpandStack(stack); + stack->elements[stack->count++] = element; +} + +stackElementT Pop(stackADT stack) +{ + if (StackIsEmpty(stack)) Error("Pop of an empty stack"); + return (stack->elements[--stack->count]); +} + +bool StackIsEmpty(stackADT stack) +{ + return (stack->count == 0); +} + +bool StackIsFull(stackADT stack) +{ + return (FALSE); +} + +int StackDepth(stackADT stack) +{ + return (stack->count); +} + +stackElementT GetStackElement(stackADT stack, int index) +{ + if (index < 0 || index >= stack->count) { + Error("Non-existent stack element"); + } + return (stack->elements[stack->count - index - 1]); +} + +/* Private functions */ + +/* Function: ExpandStack + * Usage: ExpandStack(stack); + * -------------------------- + * This function expands a full stack by doubling the size of its + * dynamic array, copying the old elements to the new array, and + * then freeing the old array storage. + */ + +static void ExpandStack(stackADT stack) +{ + stackElementT *array; + int i, newSize; + + newSize = stack->size * 2; + array = NewArray(newSize, stackElementT); + for (i = 0; i < stack->size; i++) { + array[i] = stack->elements[i]; + } + FreeBlock(stack->elements); + stack->elements = array; + stack->size = newSize; +} diff --git a/fftma_module/gen/LIBCS106X/stack.h b/fftma_module/gen/LIBCS106X/stack.h new file mode 100755 index 0000000..2f765d1 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/stack.h @@ -0,0 +1,115 @@ +/* + * File: stack.h + * ------------- + * This interface defines an abstraction for stacks. In any + * single application that uses this interface, the values in + * the stack are constrained to a single type, although it + * is easy to change that type by changing the definition of + * stackElementT in this interface. + */ + +#ifndef _stack_h +#define _stack_h + +#include "genlib.h" + +/* + * Type: stackElementT + * ------------------- + * The type stackElementT is used in this interface to indicate + * the type of values that can be stored in the stack. Here the + * stack is used to store values of type double, but that can + * be changed by editing this definition line. + */ + +typedef void *stackElementT; + +/* + * Type: stackADT + * -------------- + * The type stackADT represents the abstract type used to store + * the elements that have been pushed. Because stackADT is + * defined only as a pointer to a concrete structure that is not + * itself defined in the interface, clients have no access to + * the underlying fields. + */ + +typedef struct stackCDT *stackADT; + +/* + * Function: NewStack + * Usage: stack = NewStack(); + * -------------------------- + * This function allocates and returns a new stack, which is + * initially empty. + */ + +stackADT NewStack(void); + +/* + * Function: FreeStack + * Usage: FreeStack(stack); + * ------------------------ + * This function frees the storage associated with the stack. + */ + +void FreeStack(stackADT stack); + +/* + * Function: Push + * Usage: Push(stack, element); + * ---------------------------- + * This function pushes the specified element onto the stack. + */ + +void Push(stackADT stack, stackElementT element); + +/* + * Function: Pop + * Usage: element = Pop(stack); + * ---------------------------- + * This function pops the top element from the stack and returns + * that value. The first value popped is always the last one + * that was pushed. If the stack is empty when Pop is called, + * the function calls Error with an appropriate message. + */ + +stackElementT Pop(stackADT stack); + +/* + * Functions: StackIsEmpty, StackIsFull + * Usage: if (StackIsEmpty(stack)) . . . + * if (StackIsFull(stack)) . . . + * ------------------------------------- + * This functions test whether the stack is empty or full. + */ + +bool StackIsEmpty(stackADT stack); +bool StackIsFull(stackADT stack); + +/* + * Function: StackDepth + * Usage: depth = StackDepth(stack); + * --------------------------------- + * This function returns the number of elements currently pushed + * on the stack. + */ + +int StackDepth(stackADT stack); + +/* + * Function: GetStackElement + * Usage: element = GetStackElement(stack, index); + * ----------------------------------------------- + * This function returns the element at the specified index in + * the stack, where the top of the stack is defined as index 0. + * For example, calling GetStackElement(stack, 0) returns the top + * element on the stack without removing it. If the caller tries + * to select an out-of-range element, GetStackElement calls Error. + * Note: This function is not a fundamental stack operation and + * is instead provided principally to facilitate debugging. + */ + +stackElementT GetStackElement(stackADT stack, int index); + +#endif diff --git a/fftma_module/gen/LIBCS106X/strlib.c b/fftma_module/gen/LIBCS106X/strlib.c new file mode 100755 index 0000000..6f00938 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/strlib.c @@ -0,0 +1,246 @@ +/* + * File: strlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the strlib.h interface. + */ + +/* + * General implementation notes: + * ----------------------------- + * This module implements the strlib library by mapping all + * functions into the appropriate calls to the ANSI + * interface. The implementations of the individual functions + * are all quite simple and do not require individual comments. + * For descriptions of the behavior of each function, see the + * interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "strlib.h" + +/* + * Constant: MaxDigits + * ------------------- + * This constant must be larger than the maximum + * number of digits that can appear in a number. + */ + +#define MaxDigits 30 + +/* Private function prototypes */ + +static string CreateString(int len); + +/* Section 1 -- Basic string operations */ + +string Concat(string s1, string s2) +{ + string s; + int len1, len2; + + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to Concat"); + } + len1 = strlen(s1); + len2 = strlen(s2); + s = CreateString(len1 + len2); + strcpy(s, s1); + strcpy(s + len1, s2); + return (s); +} + +char IthChar(string s, int i) +{ + int len; + + if (s == NULL) Error("NULL string passed to IthChar"); + len = strlen(s); + if (i < 0 || i > len) { + Error("Index outside of string range in IthChar"); + } + return (s[i]); +} + +string SubString(string s, int p1, int p2) +{ + int len; + string result; + + if (s == NULL) Error("NULL string passed to SubString"); + len = strlen(s); + if (p1 < 0) p1 = 0; + if (p2 >= len) p2 = len - 1; + len = p2 - p1 + 1; + if (len < 0) len = 0; + result = CreateString(len); + strncpy(result, s + p1, len); + result[len] = '\0'; + return (result); +} + +string CharToString(char ch) +{ + string result; + + result = CreateString(1); + result[0] = ch; + result[1] = '\0'; + return (result); +} + +int StringLength(string s) +{ + if (s == NULL) Error("NULL string passed to StringLength"); + return (strlen(s)); +} + +string CopyString(string s) +{ + string newstr; + + if (s == NULL) Error("NULL string passed to CopyString"); + newstr = CreateString(strlen(s)); + strcpy(newstr, s); + return (newstr); +} + +/* Section 2 -- String comparison functions */ + +bool StringEqual(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringEqual"); + } + return (strcmp(s1, s2) == 0); +} + +int StringCompare(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringCompare"); + } + return (strcmp(s1, s2)); +} + +/* Section 3 -- Search functions */ + +int FindChar(char ch, string text, int start) +{ + char *cptr; + + if (text == NULL) Error("NULL string passed to FindChar"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strchr(text + start, ch); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +int FindString(string str, string text, int start) +{ + char *cptr; + + if (str == NULL) Error("NULL pattern string in FindString"); + if (text == NULL) Error("NULL text string in FindString"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strstr(text + start, str); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +/* Section 4 -- Case-conversion functions */ + +string ConvertToLowerCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToLowerCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = tolower(s[i]); + result[i] = '\0'; + return (result); +} + +string ConvertToUpperCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToUpperCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = toupper(s[i]); + result[i] = '\0'; + return (result); +} + +/* Section 5 -- Functions for converting numbers to strings */ + +string IntegerToString(int n) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%d", n); + return (CopyString(buffer)); +} + +int StringToInteger(string s) +{ + int result; + char dummy; + + if (s == NULL) { + Error("NULL string passed to StringToInteger"); + } + if (sscanf(s, " %d %c", &result, &dummy) != 1) { + Error("StringToInteger called on illegal number %s", s); + } + return (result); +} + +string RealToString(double d) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%G", d); + return (CopyString(buffer)); +} + +double StringToReal(string s) +{ + double result; + char dummy; + + if (s == NULL) Error("NULL string passed to StringToReal"); + if (sscanf(s, " %lg %c", &result, &dummy) != 1) { + Error("StringToReal called on illegal number %s", s); + } + return (result); +} + +/* Private functions */ + +/* + * Function: CreateString + * Usage: s = CreateString(len); + * ----------------------------- + * This function dynamically allocates space for a string of + * len characters, leaving room for the null character at the + * end. + */ + +static string CreateString(int len) +{ + return ((string) GetBlock(len + 1)); +} diff --git a/fftma_module/gen/LIBCS106X/strlib.h b/fftma_module/gen/LIBCS106X/strlib.h new file mode 100755 index 0000000..796d1d4 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/strlib.h @@ -0,0 +1,243 @@ +/* + * File: strlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:40 1994 by eroberts + * ----------------------------------------------------- + * The strlib.h file defines the interface for a simple + * string library. In the context of this package, strings + * are considered to be an abstract data type, which means + * that the client relies only on the operations defined for + * the type and not on the underlying representation. + */ + +/* + * Cautionary note: + * ---------------- + * Although this interface provides an extremely convenient + * abstraction for working with strings, it is not appropriate + * for all applications. In this interface, the functions that + * return string values (such as Concat and SubString) do so + * by allocating new memory. Over time, a program that uses + * this package will consume increasing amounts of memory + * and eventually exhaust the available supply. If you are + * writing a program that runs for a short time and stops, + * the fact that the package consumes memory is not a problem. + * If, however, you are writing an application that must run + * for an extended period of time, using this package requires + * that you make some provision for freeing any allocated + * storage. + */ + +#ifndef _strlib_h +#define _strlib_h + +#include "genlib.h" + +/* Section 1 -- Basic string operations */ + +/* + * Function: Concat + * Usage: s = Concat(s1, s2); + * -------------------------- + * This function concatenates two strings by joining them end + * to end. For example, Concat("ABC", "DE") returns the string + * "ABCDE". + */ + +string Concat(string s1, string s2); + +/* + * Function: IthChar + * Usage: ch = IthChar(s, i); + * -------------------------- + * This function returns the character at position i in the + * string s. It is included in the library to make the type + * string a true abstract type in the sense that all of the + * necessary operations can be invoked using functions. Calling + * IthChar(s, i) is like selecting s[i], except that IthChar + * checks to see if i is within the range of legal index + * positions, which extend from 0 to StringLength(s). + * IthChar(s, StringLength(s)) returns the null character + * at the end of the string. + */ + +char IthChar(string s, int i); + +/* + * Function: SubString + * Usage: t = SubString(s, p1, p2); + * -------------------------------- + * SubString returns a copy of the substring of s consisting + * of the characters between index positions p1 and p2, + * inclusive. The following special cases apply: + * + * 1. If p1 is less than 0, it is assumed to be 0. + * 2. If p2 is greater than the index of the last string + * position, which is StringLength(s) - 1, then p2 is + * set equal to StringLength(s) - 1. + * 3. If p2 < p1, SubString returns the empty string. + */ + +string SubString(string s, int p1, int p2); + +/* + * Function: CharToString + * Usage: s = CharToString(ch); + * ---------------------------- + * This function takes a single character and returns a + * one-character string consisting of that character. The + * CharToString function is useful, for example, if you + * need to concatenate a string and a character. Since + * Concat requires two strings, you must first convert + * the character into a string. + */ + +string CharToString(char ch); + +/* + * Function: StringLength + * Usage: len = StringLength(s); + * ----------------------------- + * This function returns the length of s. + */ + +int StringLength(string s); + +/* + * Function: CopyString + * Usage: newstr = CopyString(s); + * ------------------------------ + * CopyString copies the string s into dynamically allocated + * storage and returns the new string. This function is not + * ordinarily required if this package is used on its own, + * but is often necessary when you are working with more than + * one string package. + */ + +string CopyString(string s); + +/* Section 2 -- String comparison functions */ + +/* + * Function: StringEqual + * Usage: if (StringEqual(s1, s2)) ... + * ----------------------------------- + * This function returns TRUE if the strings s1 and s2 are + * equal. For the strings to be considered equal, every + * character in one string must precisely match the + * corresponding character in the other. Uppercase and + * lowercase characters are considered to be different. + */ + +bool StringEqual(string s1, string s2); + +/* + * Function: StringCompare + * Usage: if (StringCompare(s1, s2) < 0) ... + * ----------------------------------------- + * This function returns a number less than 0 if string s1 + * comes before s2 in alphabetical order, 0 if they are equal, + * and a number greater than 0 if s1 comes after s2. The + * ordering is determined by the internal representation used + * for characters, which is usually ASCII. + */ + +int StringCompare(string s1, string s2); + +/* Section 3 -- Search functions */ + +/* + * Function: FindChar + * Usage: p = FindChar(ch, text, start); + * ------------------------------------- + * Beginning at position start in the string text, this + * function searches for the character ch and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindChar(char ch, string text, int start); + +/* + * Function: FindString + * Usage: p = FindString(str, text, start); + * ---------------------------------------- + * Beginning at position start in the string text, this + * function searches for the string str and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindString(string str, string text, int start); + +/* Section 4 -- Case-conversion functions */ + +/* + * Function: ConvertToLowerCase + * Usage: s = ConvertToLowerCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to lower case. + */ + +string ConvertToLowerCase(string s); + +/* + * Function: ConvertToUpperCase + * Usage: s = ConvertToUpperCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to upper case. + */ + +string ConvertToUpperCase(string s); + +/* Section 5 -- Functions for converting numbers to strings */ + +/* + * Function: IntegerToString + * Usage: s = IntegerToString(n); + * ------------------------------ + * This function converts an integer into the corresponding + * string of digits. For example, IntegerToString(123) + * returns "123" as a string. + */ + +string IntegerToString(int n); + +/* + * Function: StringToInteger + * Usage: n = StringToInteger(s); + * ------------------------------ + * This function converts a string of digits into an integer. + * If the string is not a legal integer or contains extraneous + * characters, StringToInteger signals an error condition. + */ + +int StringToInteger(string s); + +/* + * Function: RealToString + * Usage: s = RealToString(d); + * --------------------------- + * This function converts a floating-point number into the + * corresponding string form. For example, calling + * RealToString(23.45) returns "23.45". The conversion is + * the same as that used for "%G" format in printf. + */ + +string RealToString(double d); + +/* + * Function: StringToReal + * Usage: d = StringToReal(s); + * --------------------------- + * This function converts a string representing a real number + * into its corresponding value. If the string is not a + * legal floating-point number or if it contains extraneous + * characters, StringToReal signals an error condition. + */ + +double StringToReal(string s); + +#endif diff --git a/fftma_module/gen/LIBCS106X/symtab.c b/fftma_module/gen/LIBCS106X/symtab.c new file mode 100755 index 0000000..6e27a10 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/symtab.c @@ -0,0 +1,180 @@ +/* + * File: symtab.c + * -------------- + * This file implements the symbol table abstraction. + */ + +#include +#include "genlib.h" +#include "strlib.h" +#include "symtab.h" + +/* + * Constants + * --------- + * NBuckets -- Number of buckets in the hash table + */ + +#define NBuckets 101 + +/* + * Type: cellT + * ----------- + * This type defines a linked list cell for the symbol table. + */ + +typedef struct cellT { + string key; + void *value; + struct cellT *link; +} cellT; + +/* + * Type: symtabCDT + * --------------- + * This type defines the underlying concrete representation for a + * symtabADT. These details are not relevant to and therefore + * not exported to the client. In this implementation, the + * underlying structure is a hash table organized as an array of + * "buckets," in which each bucket is a linked list of elements + * that share the same hash code. + */ + +struct symtabCDT { + cellT *buckets[NBuckets]; +}; + +/* Private function declarations */ + +static void FreeBucketChain(cellT *cp); +static cellT *FindCell(cellT *cp, string s); +static int Hash(string s, int nBuckets); + +/* Public entries */ + +symtabADT NewSymbolTable(void) +{ + symtabADT table; + int i; + + table = New(symtabADT); + for (i = 0; i < NBuckets; i++) { + table->buckets[i] = NULL; + } + return (table); +} + +void FreeSymbolTable(symtabADT table) +{ + int i; + + for (i = 0; i < NBuckets; i++) { + FreeBucketChain(table->buckets[i]); + } + FreeBlock(table); +} + +void Enter(symtabADT table, string key, void *value) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) { + cp = New(cellT *); + cp->key = CopyString(key); + cp->link = table->buckets[bucket]; + table->buckets[bucket] = cp; + } + cp->value = value; +} + +void *Lookup(symtabADT table, string key) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) return(UNDEFINED); + return (cp->value); +} + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData) +{ + int i; + cellT *cp; + + for (i = 0; i < NBuckets; i++) { + for (cp = table->buckets[i]; cp != NULL; cp = cp->link) { + fn(cp->key, cp->value, clientData); + } + } +} + +/* Private functions */ + +/* + * Function: FreeBucketChain + * Usage: FreeBucketChain(cp); + * --------------------------- + * This function takes a chain pointer and frees all the cells + * in that chain. Because the package makes copies of the keys, + * this function must free the string storage as well. + */ + +static void FreeBucketChain(cellT *cp) +{ + cellT *next; + + while (cp != NULL) { + next = cp->link; + FreeBlock(cp->key); + FreeBlock(cp); + cp = next; + } +} + +/* + * Function: FindCell + * Usage: cp = FindCell(cp, key); + * ------------------------------ + * This function finds a cell in the chain beginning at cp that + * matches key. If a match is found, a pointer to that cell is + * returned. If no match is found, the function returns NULL. + */ + +static cellT *FindCell(cellT *cp, string key) +{ + while (cp != NULL && !StringEqual(cp->key, key)) { + cp = cp->link; + } + return (cp); +} + +/* + * Function: Hash + * Usage: bucket = Hash(key, nBuckets); + * ------------------------------------ + * This function takes the key and uses it to derive a hash code, + * which is an integer in the range [0, nBuckets - 1]. The hash + * code is computed using a method called linear congruence. The + * choice of the value for Multiplier can have a significant effect + * on the performance of the algorithm, but not on its correctness. + */ + +#define Multiplier -1664117991L + +static int Hash(string s, int nBuckets) +{ + int i; + unsigned long hashcode; + + hashcode = 0; + for (i = 0; s[i] != '\0'; i++) { + hashcode = hashcode * Multiplier + s[i]; + } + return (hashcode % nBuckets); +} diff --git a/fftma_module/gen/LIBCS106X/symtab.h b/fftma_module/gen/LIBCS106X/symtab.h new file mode 100755 index 0000000..c83c307 --- /dev/null +++ b/fftma_module/gen/LIBCS106X/symtab.h @@ -0,0 +1,85 @@ +/* + * File: symtab.h + * -------------- + * This interface exports a simple symbol table abstraction. + */ + +#ifndef _symtab_h +#define _symtab_h + +#include "genlib.h" + +/* + * Type: symtabADT + * --------------- + * This type is the ADT used to represent a symbol table. + */ + +typedef struct symtabCDT *symtabADT; + +/* + * Type: symtabFnT + * --------------- + * This type defines the class of functions that can be used to + * map over the entries in a symbol table. + */ + +typedef void (*symtabFnT)(string key, void *value, + void *clientData); + +/* Exported entries */ + +/* + * Function: NewSymbolTable + * Usage: table = NewSymbolTable(); + * -------------------------------- + * This function allocates a new symbol table with no entries. + */ + +symtabADT NewSymbolTable(void); + +/* + * Function: FreeSymbolTable + * Usage: FreeSymbolTable(table); + * ------------------------------ + * This function frees the storage associated with the symbol table. + */ + +void FreeSymbolTable(symtabADT table); + +/* + * Function: Enter + * Usage: Enter(table, key, value); + * -------------------------------- + * This function associates key with value in the symbol table. + * Each call to Enter supersedes any previous definition for key. + */ + +void Enter(symtabADT table, string key, void *value); + +/* + * Function: Lookup + * Usage: value = Lookup(table, key); + * ---------------------------------- + * This function returns the value associated with key in the symbol + * table, or UNDEFINED, if no such value exists. + */ + +void *Lookup(symtabADT table, string key); + +/* + * Function: MapSymbolTable + * Usage: MapSymbolTable(fn, table, clientData); + * --------------------------------------------- + * This function goes through every entry in the symbol table + * and calls the function fn, passing it the following arguments: + * the current key, its associated value, and the clientData + * pointer. The clientData pointer allows the client to pass + * additional state information to the function fn, if necessary. + * If no clientData argument is required, this value should be NULL. + */ + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData); + +#endif diff --git a/fftma_module/gen/LIBFFTMA/._.DS_Store b/fftma_module/gen/LIBFFTMA/._.DS_Store new file mode 100755 index 0000000..c9474ea Binary files /dev/null and b/fftma_module/gen/LIBFFTMA/._.DS_Store differ diff --git a/fftma_module/gen/LIBFFTMA/Makefile.libFFTMA b/fftma_module/gen/LIBFFTMA/Makefile.libFFTMA new file mode 100755 index 0000000..a492b20 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/Makefile.libFFTMA @@ -0,0 +1,30 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +INTERFACE = ../include +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CC = cc +CCFLAGS = + +LIB = libFFTMA_${ARCH}.a + +NOBJS= gammf.o fftma.o addstat.o axes.o cgrid.o covariance.o fourt.o length.o maxfactor.o test_fact.o cov_value.o generate.o gasdev.o ran2.o stable.o gaussian.o power.o cubic.o spherical.o nugget.o exponential.o cardsin.o nor2log.o + + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/LIBFFTMA/addstat.c b/fftma_module/gen/LIBFFTMA/addstat.c new file mode 100755 index 0000000..ffcb781 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/addstat.c @@ -0,0 +1,106 @@ +#include +#include +#include "geostat.h" +#include "genlib.h" + + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ +void addstat(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + break; + case 6: + (*realout).code = 7; + break; + default: + (*realout).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + switch (stat.type) { + case 0: + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + break; + case 1: + /*lognormal (natural) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log(1.0+r); + break; + case 2: + /*lognormal (log10) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log10(1.0+r); + break; + default: + Error("Type not defined in addstat"); + break; + } + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/LIBFFTMA/axes.c b/fftma_module/gen/LIBFFTMA/axes.c new file mode 100755 index 0000000..b9e8351 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/axes.c @@ -0,0 +1,41 @@ +#include +#include + +/*normalizes anisotropy axes*/ +void axes(double *ap,double *scf,int N) +{ + double sclpdt, r, eps = 1.E-6; + int i,j,k; + + + for (k = 0; k < N; k++) { + + r = sqrt(ap[9*k]*ap[9*k]+ap[9*k+1]*ap[9*k+1]+ap[9*k+2]*ap[9*k+2]); + ap[9*k] /= r; + ap[9*k+1] /= r; + ap[9*k+2] /= r; + sclpdt = ap[9*k]*ap[9*k+3]+ap[9*k+1]*ap[9*k+4]+ap[9*k+2]*ap[9*k+5]; + if (sclpdt > eps) { + printf("Non orthogonal axes"); + exit; + } else { + r = sqrt(ap[9*k+3]*ap[9*k+3]+ap[9*k+4]*ap[9*k+4]+ap[9*k+5]*ap[9*k+5]); + ap[9*k+3] /= r; + ap[9*k+4] /= r; + ap[9*k+5] /= r; + ap[9*k+6] = ap[9*k+1]*ap[9*k+5]-ap[9*k+2]*ap[9*k+4]; + ap[9*k+7] = ap[9*k+2]*ap[9*k+3]-ap[9*k]*ap[9*k+5]; + ap[9*k+8] = ap[9*k]*ap[9*k+4]-ap[9*k+1]*ap[9*k+3]; + for (i=0; i<3; i++) { + for (j=0; j<3; j++) { + if (scf[3*k+j] == 0.) + scf[3*k+j] = 1.; + ap[9*k+3*j+i] /= scf[3*k+j]; + } + } + } + + } + return; +} + diff --git a/fftma_module/gen/LIBFFTMA/cardsin.c b/fftma_module/gen/LIBFFTMA/cardsin.c new file mode 100755 index 0000000..504f286 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/cardsin.c @@ -0,0 +1,18 @@ +#include +#include +#include "genlib.h" + +/*cardsin covariance function*/ +double cardsin(double h) +{ + float delta = 20.371; + double z; + + if (h != 0) { + z = (double)(h*delta); + z = sin(z)/z; + } else { + z = 1.; + } + return(z); +} diff --git a/fftma_module/gen/LIBFFTMA/cgrid.c b/fftma_module/gen/LIBFFTMA/cgrid.c new file mode 100755 index 0000000..19baee0 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/cgrid.c @@ -0,0 +1,43 @@ +#include +#include "geostat.h" + + +/*computes the size of the grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]) +{ + int i,N; + double D; + + if (n == NULL || n[0] == 0 || n[1] == 0 || n[2] == 0) { + for (i = 0; i<3; i++) { + switch (i) { + case 0: + N = grid.NX; + D = grid.DX; + break; + case 1: + N = grid.NY; + D = grid.DY; + break; + case 2: + N = grid.NZ; + D = grid.DZ; + break; + } + n[i] = length(N,i,variogram.scf,variogram.ap,D,variogram.Nvario); + } + } else { + if ((n[0] +#include "geostat.h" +#include "genlib.h" + +/*selection of model covariance*/ +double cov_value(struct vario_mod variogram,double di,double dj,double dk) +{ + double hx,hy,hz,h; + double cov; + int k; + + + cov = 0.; + + for (k = 0; k < variogram.Nvario; k++) { + + hx = di*variogram.ap[9*k]+dj*variogram.ap[9*k+1]+dk*variogram.ap[9*k+2]; + hy = di*variogram.ap[9*k+3]+dj*variogram.ap[9*k+4]+dk*variogram.ap[9*k+5]; + hz = di*variogram.ap[9*k+6]+dj*variogram.ap[9*k+7]+dk*variogram.ap[9*k+8]; + h = sqrt(hx*hx+hy*hy+hz*hz); + + + switch (variogram.vario[k]) { + case 1: + cov += variogram.var[k]*exponential(h); + break; + case 2: + cov += variogram.var[k]*gaussian(h); + break; + case 3: + cov += variogram.var[k]*spherical(h); + break; + case 4: + cov += variogram.var[k]*cardsin(h); + break; + case 5: + cov += variogram.var[k]*stable(h,variogram.alpha[k]); + break; + case 6: + cov += variogram.var[k]*gammf(h,variogram.alpha[k]); + break; + case 7: + cov += variogram.var[k]*cubic(h); + break; + case 8: + cov += variogram.var[k]*nugget(h); + break; + case 9: + cov += variogram.var[k]*power(h,variogram.alpha[k]); + break; + } + } + + return (cov); +} diff --git a/fftma_module/gen/LIBFFTMA/covariance.c b/fftma_module/gen/LIBFFTMA/covariance.c new file mode 100755 index 0000000..4678b2a --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/covariance.c @@ -0,0 +1,90 @@ +#include "geostat.h" + +/*builds the sampled covariance function*/ +/*dimensions are even*/ +void covariance(double *covar, struct vario_mod variogram, struct grid_mod mesh, int n[3]) + +{ + int i,j,k,maille,n2[3],symmetric; + double di,dj,dk; + + + for (i=0;i<3;i++) + n2[i] = n[i]/2; + + for (i=0; i<= n2[0]; i++) { + for (j=0; j<= n2[1]; j++) { + for (k=0; k<= n2[2]; k++) { + + + /*area 1*/ + maille = 1+i+n[0]*(j+n[1]*k); + di = (double)i*mesh.DX; + dj = (double)j*mesh.DY; + dk = (double)k*mesh.DZ; + covar[maille] = (double)cov_value(variogram,di,dj,dk); + + + if (k > 0 && k 0 && j 0 && i 0 && i 0 && k 0 && j 0 && i 0 && j < n2[1]) { + /*area 5*/ + di = -(double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+(n[0]-i)+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && j < n2[1]) { + /*area 3*/ + di = (double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+i+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && i +#include +#include "genlib.h" + + +/*cubic covariance function*/ +double cubic(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-7.*(double)(h*h)+(35./4.)*(double)(h*h*h)-3.5*(double)(h*h*h*h*h)+.75*(double)(h*h*h*h*h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/LIBFFTMA/exponential.c b/fftma_module/gen/LIBFFTMA/exponential.c new file mode 100755 index 0000000..003d1bb --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/exponential.c @@ -0,0 +1,9 @@ +#include +#include +#include "genlib.h" + +/*exponential covariance function*/ +double exponential(double h) +{ + return (exp(-3.*(double)h)); +} diff --git a/fftma_module/gen/LIBFFTMA/fftma.c b/fftma_module/gen/LIBFFTMA/fftma.c new file mode 100755 index 0000000..3daa08f --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/fftma.c @@ -0,0 +1,185 @@ + +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + + + +void FFTMA(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *table,*covar,*workr,*worki,*realization,temp; + + + /*test over the input realization*/ + /*if ((*realin).code != 0) { + printf("Input realizations in FFTMA must be Gaussian white noises"); + exit; + }*/ + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + if (covar == NULL) { + printf("FFTMA.c: No memory available for covar"); + exit; + } + + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("FFTMA.c: No memory available for table"); + exit; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("FFTMA.c: No memory available for realization"); + exit; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("FFTMA.c: No memory available for workr"); + exit; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("FFTMA.c: No memory available for worki"); + exit; + } + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + + /*power spectrum*/ + fourt(covar,table,n,NDIM,1,0,workr,worki); + + + /*organization of the input Gaussian white noise*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (i <= grid.NX && j <= grid.NY && k <= grid.NZ) { + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + realization[maille1] = (*realin).vector[maille0]; + } else { + realization[maille1] = 0.; + } + } + } + } + + + /*forward fourier transform of the GWN*/ + fourt(realization,table,n,NDIM,1,0,workr,worki); + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + table[maille1] *= temp; + } + } + } + + + free(covar); + + + /*backward fourier transform*/ + fourt(realization,table,n,NDIM,0,1,workr,worki); + + + free(table); + free(workr); + free(worki); + + + /*output realization*/ + + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("FFTMA.c: No memory available"); + exit; + } + } + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = realization[maille1]; + } + } + } + + + free(realization); + + + return; +} + + + + diff --git a/fftma_module/gen/LIBFFTMA/fourt.c b/fftma_module/gen/LIBFFTMA/fourt.c new file mode 100755 index 0000000..fe80035 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/fourt.c @@ -0,0 +1,591 @@ +#include +#include + +/*fast fourier transform */ +/* THE COOLEY-TUKEY FAST FOURIER TRANSFORM */ +/* EVALUATES COMPLEX FOURIER SERIES FOR COMPLEX OR REAL FUNCTIONS. */ +/* THAT IS, IT COMPUTES */ +/* FTRAN(J1,J2,...)=SUM(DATA(I1,I2,...)*W1**(I1-1)*(J1-1) */ +/* *W2**(I2-1)*(J2-1)*...), */ +/* WHERE W1=EXP(-2*PI*SQRT(-1)/NN(1)), W2=EXP(-2*PI*SQRT(-1)/NN(2)), */ +/* ETC. AND I1 AND J1 RUN FROM 1 TO NN(1), I2 AND J2 RUN FROM 1 TO */ +/* NN(2), ETC. THERE IS NO LIMIT ON THE DIMENSIONALITY (NUMBER OF */ +/* SUBSCRIPTS) OF THE ARRAY OF DATA. THE PROGRAM WILL PERFORM */ +/* A THREE-DIMENSIONAL FOURIER TRANSFORM AS EASILY AS A ONE-DIMEN- */ +/* SIONAL ONE, THO IN A PROPORTIONATELY GREATER TIME. AN INVERSE */ +/* TRANSFORM CAN BE PERFORMED, IN WHICH THE SIGN IN THE EXPONENTIALS */ +/* IS +, INSTEAD OF -. IF AN INVERSE TRANSFORM IS PERFORMED UPON */ +/* AN ARRAY OF TRANSFORMED DATA, THE ORIGINAL DATA WILL REAPPEAR, */ +/* MULTIPLIED BY NN(1)*NN(2)*... THE ARRAY OF INPUT DATA MAY BE */ +/* REAL OR COMPLEX, AT THE PROGRAMMERS OPTION, WITH A SAVING OF */ +/* ABOUT THIRTY PER CENT IN RUNNING TIME FOR REAL OVER COMPLEX. */ +/* (FOR FASTEST TRANSFORM OF REAL DATA, NN(1) SHOULD BE EVEN.) */ +/* THE TRANSFORM VALUES ARE ALWAYS COMPLEX, AND ARE RETURNED IN THE */ +/* ORIGINAL ARRAY OF DATA, REPLACING THE INPUT DATA. THE LENGTH */ +/* OF EACH DIMENSION OF THE DATA ARRAY MAY BE ANY INTEGER. THE */ +/* PROGRAM RUNS FASTER ON COMPOSITE INTEGERS THAN ON PRIMES, AND IS */ +/* PARTICULARLY FAST ON NUMBERS RICH IN FACTORS OF TWO. */ +/* TIMING IS IN FACT GIVEN BY THE FOLLOWING FORMULA. LET NTOT BE THE */ +/* TOTAL NUMBER OF POINTS (REAL OR COMPLEX) IN THE DATA ARRAY, THAT */ +/* IS, NTOT=NN(1)*NN(2)*... DECOMPOSE NTOT INTO ITS PRIME FACTORS, */ +/* SUCH AS 2**K2 * 3**K3 * 5**K5 * ... LET SUM2 BE THE SUM OF ALL */ +/* THE FACTORS OF TWO IN NTOT, THAT IS, SUM2 = 2*K2. LET SUMF BE */ +/* THE SUM OF ALL OTHER FACTORS OF NTOT, THAT IS, SUMF = 3*K3+5*K5+.. */ +/* THE TIME TAKEN BY A MULTIDIMENSIONAL TRANSFORM ON THESE NTOT DATA */ +/* IS T = T0 + T1*NTOT + T2*NTOT*SUM2 + T3*NTOT*SUMF. FOR THE PAR- */ +/* TICULAR IMPLEMENTATION FORTRAN 32 ON THE CDC 3300 (FLOATING POINT */ +/* ADD TIME = SIX MICROSECONDS), */ +/* T = 3000 + 600*NTOT + 50*NTOT*SUM2 + 175*NTOT*SUMF MICROSECONDS */ +/* ON COMPLEX DATA. */ +/* IMPLEMENTATION OF THE DEFINITION BY SUMMATION WILL RUN IN A TIME */ +/* PROPORTIONAL TO NTOT**2. FOR HIGHLY COMPOSITE NTOT, THE SAVINGS */ +/* OFFERED BY COOLEY-TUKEY CAN BE DRAMATIC. A MATRIX 100 BY 100 WILL */ +/* BE TRANSFORMED IN TIME PROPORTIONAL TO 10000*(2+2+2+2+5+5+5+5) = */ +/* 280,000 (ASSUMING T2 AND T3 TO BE ROUGHLY COMPARABLE) VERSUS */ +/* 10000**2 = 100,000,000 FOR THE STRAIGHTFORWARD TECHNIQUE. */ +/* THE COOLEY-TUKEY ALGORITHM PLACES TWO RESTRICTIONS UPON THE */ +/* NATURE OF THE DATA BEYOND THE USUAL RESTRICTION THAT */ +/* THE DATA FROM ONE CYCLE OF A PERIODIC FUNCTION. THEY ARE-- */ +/* 1. THE NUMBER OF INPUT DATA AND THE NUMBER OF TRANSFORM VALUES */ +/* MUST BE THE SAME. */ +/* 2. CONSIDERING THE DATA TO BE IN THE TIME DOMAIN, */ +/* THEY MUST BE EQUI-SPACED AT INTERVALS OF DT. FURTHER, THE TRANS- */ +/* FORM VALUES, CONSIDERED TO BE IN FREQUENCY SPACE, WILL BE EQUI- */ +/* SPACED FROM 0 TO 2*PI*(NN(I)-1)/(NN(I)*DT) AT INTERVALS OF */ +/* 2*PI/(NN(I)*DT) FOR EACH DIMENSION OF LENGTH NN(I). OF COURSE, */ +/* DT NEED NOT BE THE SAME FOR EVERY DIMENSION. */ + +/* THE CALLING SEQUENCE IS-- */ +/* CALL FOURT(DATAR,DATAI,NN,NDIM,IFRWD,ICPLX,WORKR,WORKI) */ + +/* DATAR AND DATAI ARE THE ARRAYS USED TO HOLD THE REAL AND IMAGINARY */ +/* PARTS OF THE INPUT DATA ON INPUT AND THE TRANSFORM VALUES ON */ +/* OUTPUT. THEY ARE FLOATING POINT ARRAYS, MULTIDIMENSIONAL WITH */ +/* IDENTICAL DIMENSIONALITY AND EXTENT. THE EXTENT OF EACH DIMENSION */ +/* IS GIVEN IN THE INTEGER ARRAY NN, OF LENGTH NDIM. THAT IS, */ +/* NDIM IS THE DIMENSIONALITY OF THE ARRAYS DATAR AND DATAI. */ +/* IFRWD IS AN INTEGER USED TO INDICATE THE DIRECTION OF THE FOURIER */ +/* TRANSFORM. IT IS NON-ZERO TO INDICATE A FORWARD TRANSFORM */ +/* (EXPONENTIAL SIGN IS -) AND ZERO TO INDICATE AN INVERSE TRANSFORM */ +/* (SIGN IS +). ICPLX IS AN INTEGER TO INDICATE WHETHER THE DATA */ +/* ARE REAL OR COMPLEX. IT IS NON-ZERO FOR COMPLEX, ZERO FOR REAL. */ +/* IF IT IS ZERO (REAL) THE CONTENTS OF ARRAY DATAI WILL BE ASSUMED */ +/* TO BE ZERO, AND NEED NOT BE EXPLICITLY SET TO ZERO. AS EXPLAINED */ +/* ABOVE, THE TRANSFORM RESULTS ARE ALWAYS COMPLEX AND ARE STORED */ +/* IN DATAR AND DATAI ON RETURN. WORKR AND WORKI ARE ARRAYS USED */ +/* FOR WORKING STORAGE. THEY ARE NOT NECESSARY IF ALL THE DIMENSIONS */ +/* OF THE DATA ARE POWERS OF TWO. IN THIS CASE, THE ARRAYS MAY BE */ +/* REPLACED BY THE NUMBER 0 IN THE CALLING SEQUENCE. THUS, USE OF */ +/* POWERS OF TWO CAN FREE A GOOD DEAL OF STORAGE. IF ANY DIMENSION */ +/* IS NOT A POWER OF TWO, THESE ARRAYS MUST BE SUPPLIED. THEY ARE */ +/* FLOATING POINT, ONE DIMENSIONAL OF LENGTH EQUAL TO THE LARGEST */ +/* ARRAY DIMENSION, THAT IS, TO THE LARGEST VALUE OF NN(I). */ +/* WORKR AND WORKI, IF SUPPLIED, MUST NOT BE THE SAME ARRAYS AS DATAR */ +/* OR DATAI. ALL SUBSCRIPTS OF ALL ARRAYS BEGIN AT 1. */ + +/* THERE ARE NO ERROR MESSAGES OR ERROR HALTS IN THIS PROGRAM. THE */ +/* PROGRAM RETURNS IMMEDIATELY IF NDIM OR ANY NN(I) IS LESS THAN ONE. */ + +/* PROGRAM MODIFIED FROM A SUBROUTINE OF BRENNER */ +/* 10-06-2000, MLR */ + + +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx, double *workr,double *worki) +{ + int ifact[21],ntot,idim,np1,n,np2,m,ntwo,iff,idiv,iquot,irem,inon2,non2p,np0,nprev,icase,ifmin,i,j,jmax,np2hf,i2,i1max,i3,j3,i1,ifp1,ifp2,i2max,i1rng,istep,imin,imax,mmax,mmin,mstep,j1,j2max,j2,jmin,j3max,nhalf; + double theta,wstpr,wstpi,wminr,wmini,wr,wi,wtemp,thetm,wmstr,wmsti,twowr,sr,si,oldsr,oldsi,stmpr,stmpi,tempr,tempi,difi,difr,sumr,sumi,TWOPI = 6.283185307179586476925286766559; + + ntot = 1; + for (idim = 0; idim < ndim; idim++) { + ntot *= nn[idim]; + } + + /*main loop for each dimension*/ + np1 = 1; + for (idim = 1; idim <= ndim; idim++) { + n = nn[idim-1]; + np2 = np1*n; + + if (n < 1) { + goto L920; + } else if (n == 1) { + goto L900; + } + + /*is n a power of 2 and if not, what are its factors*/ + m = n; + ntwo = np1; + iff = 1; + idiv = 2; + + L10: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L50; + if (irem == 0) { + ntwo *= 2; + ifact[iff] = idiv; + iff++; + m= iquot; + goto L10; + } + idiv = 3; + inon2 = iff; + + L30: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L60; + if (irem == 0) { + ifact[iff] = idiv; + iff++; + m = iquot; + goto L30; + } + + idiv += 2; + goto L30; + + L50: + inon2 = iff; + if (irem != 0) + goto L60; + ntwo *= 2; + goto L70; + + L60: + ifact[iff] = m; + + L70: + non2p = np2/ntwo; + + + /*SEPARATE FOUR CASES-- + 1. COMPLEX TRANSFORM + 2. REAL TRANSFORM FOR THE 2ND, 3RD, ETC. DIMENSION. METHOD: TRANSFORM HALF THE DATA, SUPPLYING THE OTHER HALF BY CONJUGATE SYMMETRY. + 3. REAL TRANSFORM FOR THE 1ST DIMENSION, N ODD. METHOD: SET THE IMAGINARY PARTS TO ZERO. + 4. REAL TRANSFORM FOR THE 1ST DIMENSION, N EVEN. METHOD: TRANSFORM A COMPLEX ARRAY OF LENGTH N/2 WHOSE REAL PARTS ARE THE EVEN NUMBERED REAL VALUES AND WHOSE IMAGINARY PARTS ARE THE ODD-NUMBERED REAL VALUES. UNSCRAMBLE AND SUPPLY THE SECOND HALF BY CONJUGATE SYMMETRY. */ + + icase = 1; + ifmin = 1; + if (icplx != 0) + goto L100; + icase = 2; + if (idim > 1) + goto L100; + icase = 3; + if (ntwo <= np1) + goto L100; + icase = 4; + ifmin = 2; + ntwo /= 2; + n /= 2; + np2 /= 2; + ntot /= 2; + i = 1; + for (j = 1; j <= ntot; j++) { + datar[j] = datar[i]; + datai[j] = datar[i+1]; + i += 2; + } + + /*shuffle data by bit reversal, since n = 2^k. As the shuffling can be done by simple interchange, no working array is needed*/ + L100: + if (non2p > 1) + goto L200; + np2hf = np2/2; + j = 1; + for (i2 = 1; i2 <= np2; i2 += np1) { + if (j >= i2) + goto L130; + i1max = i2+np1-1; + for (i1 = i2; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j3 = j+i3-i2; + tempr = datar[i3]; + tempi = datai[i3]; + datar[i3] = datar[j3]; + datai[i3] = datai[j3]; + datar[j3] = tempr; + datai[j3] = tempi; + } + } + + L130: + m = np2hf; + + L140: + if (j <= m) { + j += m; + } else { + j -= m; + m /= 2; + if (m >= np1) + goto L140; + } + + } + goto L300; + + /*shuffle data by digit reversal for general n*/ + L200: + for (i1 = 1; i1 <= np1; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j = i3; + for (i = 1; i <= n; i++) { + if (icase != 3) { + workr[i] = datar[j]; + worki[i] = datai[j]; + } else { + workr[i] = datar[j]; + worki[i] = 0.; + } + ifp2 = np2; + iff = ifmin; + L250: + ifp1 = ifp2/ifact[iff]; + j += ifp1; + if (j >= i3+ifp2) { + j -= ifp2; + ifp2 = ifp1; + iff += 1; + if (ifp2 > np1) + goto L250; + } + } + i2max = i3+np2-np1; + i = 1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + datar[i2] = workr[i]; + datai[i2] = worki[i]; + i++; + } + + } + } + + /*special case-- W=1*/ + L300: + i1rng = np1; + if (icase == 2) + i1rng = np0*(1+nprev/2); + if (ntwo <= np1) + goto L600; + for (i1 = 1; i1 <= i1rng; i1++) { + imin = np1+i1; + istep = 2*np1; + goto L330; + + L310: + j = i1; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]; + tempi = datai[i]; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] = datar[j]+tempr; + datai[j] = datai[j]+tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + + L330: + if (istep <= ntwo) + goto L310; + + /*special case-- W = -sqrt(-1)*/ + imin = 3*np1+i1; + istep = 4*np1; + goto L420; + + L400: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + if (ifrwd != 0) { + tempr = datai[i]; + tempi = -datar[i]; + } else { + tempr = -datai[i]; + tempi = datar[i]; + } + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + + imin = 2*imin-i1; + istep *= 2; + + L420: + if (istep <= ntwo) + goto L400; + } + + /*main loop for factors of 2. W=EXP(-2*PI*SQRT(-1)*m/mmax) */ + theta = -TWOPI/8.; + wstpr = 0.; + wstpi = -1.; + if (ifrwd == 0) { + theta = -theta; + wstpi = 1.; + } + mmax = 8*np1; + goto L540; + + L500: + wminr = cos(theta); + wmini = sin(theta); + wr = wminr; + wi = wmini; + mmin = mmax/2+np1; + mstep = np1*2; + for (m = mmin; m <= mmax; m += mstep) { + for (i1 = 1; i1 <= i1rng; i1++) { + istep = mmax; + imin = m+i1; + L510: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]*wr-datai[i]*wi; + tempi = datar[i]*wi+datai[i]*wr; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + if (istep <= ntwo) + goto L510; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + wstpr = wminr; + wstpi = wmini; + theta /= 2.; + mmax += mmax; + L540: + if (mmax <= ntwo) + goto L500; + + /*main loop for factors not equal to 2-- W=EXP(-2*PI*SQRT(-1)*(j2-i3)/ifp2)*/ + L600: + if (non2p <= 1) + goto L700; + ifp1 = ntwo; + iff = inon2; + L610: + ifp2 = ifact[iff]*ifp1; + theta = -TWOPI/ (double)ifact[iff]; + if (ifrwd == 0) + theta = -theta; + thetm = theta/ (double)(ifp1/np1); + wstpr = cos(theta); + wstpi = sin(theta); + wmstr = cos(thetm); + wmsti = sin(thetm); + wminr = 1.; + wmini = 0.; + + for (j1 = 1; j1 <= ifp1; j1 += np1) { + i1max = j1+i1rng-1; + for (i1 = j1; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + i = 1; + wr = wminr; + wi = wmini; + j2max = i3+ifp2-ifp1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + twowr = 2.*wr; + jmin = i3; + j3max = j2+np2-ifp2; + for (j3 = j2 ; j3 <= j3max; j3 += ifp2) { + j = jmin+ifp2-ifp1; + sr = datar[j]; + si = datai[j]; + oldsr = 0.; + oldsi = 0.; + j -= ifp1; + L620: + stmpr = sr; + stmpi = si; + sr = twowr*sr-oldsr+datar[j]; + si = twowr*si-oldsi+datai[j]; + oldsr = stmpr; + oldsi = stmpi; + j -= ifp1; + if (j > jmin) + goto L620; + workr[i] = wr*sr-wi*si-oldsr+datar[j]; + worki[i] = wi*sr+wr*si-oldsi+datai[j]; + jmin += ifp2; + i++; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + i = 1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + j3max = j2+np2-ifp2; + for (j3 = j2; j3 <= j3max; j3 += ifp2) { + datar[j3] = workr[i]; + datai[j3] = worki[i]; + i++; + } + } + } + } + wtemp = wminr*wmsti; + wminr = wminr*wmstr-wmini*wmsti; + wmini = wmini*wmstr+wtemp; + } + iff++; + ifp1 = ifp2; + if (ifp1 < np2) + goto L610; + + /*complete a real transform in the 1st dimension, n even, by conjugate symmetries*/ + L700: + switch (icase) { + case 1: + goto L900; + break; + case 2: + goto L800; + break; + case 3: + goto L900; + break; + } + + nhalf = n; + n += n; + theta = -TWOPI/ (double) n; + if (ifrwd == 0) + theta = -theta; + wstpr = cos(theta); + wstpi = sin(theta); + wr = wstpr; + wi = wstpi; + imin = 2; + jmin = nhalf; + goto L725; + L710: + j = jmin; + for (i = imin; i <= ntot; i += np2) { + sumr = (datar[i]+datar[j])/2.; + sumi = (datai[i]+datai[j])/2.; + difr = (datar[i]-datar[j])/2.; + difi = (datai[i]-datai[j])/2.; + tempr = wr*sumi+wi*difr; + tempi = wi*sumi-wr*difr; + datar[i] = sumr+tempr; + datai[i] = difi+tempi; + datar[j] = sumr-tempr; + datai[j] = tempi-difi; + j += np2; + } + imin++; + jmin--; + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + L725: + if (imin < jmin) { + goto L710; + } else if (imin > jmin) { + goto L740; + } + if (ifrwd == 0) + goto L740; + for (i = imin; i <= ntot; i += np2) { + datai[i] = -datai[i]; + } + L740: + np2 *= 2; + ntot *= 2; + j = ntot+1; + imax = ntot/2+1; + L745: + imin = imax-nhalf; + i = imin; + goto L755; + L750: + datar[j] = datar[i]; + datai[j] = -datai[i]; + L755: + i++; + j--; + if (i < imax) + goto L750; + datar[j] = datar[imin]-datai[imin]; + datai[j] = 0.; + if (i >= j) { + goto L780; + } else { + goto L770; + } + L765: + datar[j] = datar[i]; + datai[j] = datai[i]; + L770: + i--; + j--; + if (i > imin) + goto L765; + datar[j] = datar[imin]+datai[imin]; + datai[j] = 0.; + imax = imin; + goto L745; + L780: + datar[1] += datai[1]; + datai[1] = 0.; + goto L900; + + /*complete a real transform for the 2nd, 3rd, ... dimension by conjugate symmetries*/ + L800: + if (nprev <= 2) + goto L900; + for (i3 = 1; i3 <= ntot; i3 += np2) { + i2max = i3+np2-np1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + imax = i2+np1-1; + imin = i2+i1rng; + jmax = 2*i3+np1-imin; + if (i2 > i3) + jmax += np2; + if (idim > 2) { + j = jmax+np0; + for (i = imin; i <= imax; i++) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j--; + } + } + j = jmax; + for (i = imin; i <= imax; i += np0) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j -= np0; + } + } + } + + /*end of loop on each dimension*/ + L900: + np0 = np1; + np1 = np2; + nprev = n; + } + L920: + return; +} diff --git a/fftma_module/gen/LIBFFTMA/gammf.c b/fftma_module/gen/LIBFFTMA/gammf.c new file mode 100755 index 0000000..97ff3f9 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/gammf.c @@ -0,0 +1,16 @@ +#include +#include +#include "genlib.h" + + +/*gamma covariance function*/ +double gammf(double h, double alpha) +{ + float delta; + double z; + + delta = pow(20.,1./alpha)-1.; + z = 1./(double)(pow(1.+h*delta,alpha)); + return(z); +} + diff --git a/fftma_module/gen/LIBFFTMA/gasdev.c b/fftma_module/gen/LIBFFTMA/gasdev.c new file mode 100755 index 0000000..a25dfa2 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/gasdev.c @@ -0,0 +1,31 @@ +#include +#include "genlib.h" + +#define NTAB 32 + +double gasdev(long *idum,long *idum2, long *iy, long iv[NTAB]) +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran2(idum) as the source */ +/*of uniform deviates */ +{ + double ran2(long *idum,long *idum2, long *iy, long iv[NTAB]); + static int iset = 0; + static double gset; + double fac,rsq,v1,v2; + + if (iset == 0) { + do { + v1 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + v2 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + rsq = v1*v1+v2*v2; + } while (rsq >= 1.0 || rsq == 0.0); + + fac = sqrt(-2.0*log(rsq)/rsq); + gset = v1*fac; + iset = 1; + return (v2*fac); + } else { + iset = 0; + return (gset); + } +} diff --git a/fftma_module/gen/LIBFFTMA/gaussian.c b/fftma_module/gen/LIBFFTMA/gaussian.c new file mode 100755 index 0000000..5ef9911 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/gaussian.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*gaussian covariance function*/ +double gaussian(double h) +{ + return (exp(-3.*(double)(h*h))); +} diff --git a/fftma_module/gen/LIBFFTMA/generate.c b/fftma_module/gen/LIBFFTMA/generate.c new file mode 100755 index 0000000..46869d3 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/generate.c @@ -0,0 +1,43 @@ +#include +#include +#include "geostat.h" + + +/* GENERATION OF A GAUSSIAN WHITE NOISE VECTOR */ +/*input: */ +/* seed: seed */ +/* n: number of components in the vector */ +/*output: */ +/* realization: structure defining the realization*/ + +void generate(long *seed, int n, struct realization_mod *realization) +{ + int i; + long idum2 = 123456789,iy = 0; + long *iv; + int iset =0; + + iv = (long *) malloc(NTAB * sizeof(long)); + + /*negative seed*/ + if (*seed > 0.0) + *seed = -(*seed); + + /*realization definition*/ + (*realization).n = n; + (*realization).code = 0; + (*realization).vector = (double *) malloc(n * sizeof(double)); + if ((*realization).vector == NULL) { + printf("No memory available in generate"); + exit; + } + + /*Gaussian white noise generation*/ + for (i=0; i < n; i++) + (*realization).vector[i] = gasdev(seed,&idum2,&iy,iv,&iset); + + return; +} + + + diff --git a/fftma_module/gen/LIBFFTMA/geostat.h b/fftma_module/gen/LIBFFTMA/geostat.h new file mode 100755 index 0000000..3f36ecf --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/geostat.h @@ -0,0 +1,689 @@ +#include +#include +#include +#include + + +#ifndef _GEOSTAT_H +#define _GEOSTAT_H + +#define NTAB 32 + +/* Modified january, the 22th 2004 */ +/* from float to double */ + +/* List of structures: */ +/* ------------------- */ + +/* vario_mod */ +/* variotable_mod*/ +/* grid_mod */ +/* welldata_mod */ +/* statfacies_mod */ +/* inequalities_mod */ +/* statistic_mod */ +/* grad_mod */ +/* gradients_mod */ +/* cdf_mod */ +/* realization_mod */ + + +/* List of functions: */ +/* ------------------ */ + +/* axes, cardsin, choldc, coordinates */ +/* covariance, cov_matrix, cov_value, */ +/* cubic, cutspectr, deflimit, dual_kri */ +/* exponential, fourt, funtrun1, G, gammf */ +/* gammln, gammp, gasdev, gaussian, gcf, */ +/* gen_cov_matrix, Ginv, gradual, cgrid, */ +/* gser, invtrun1, krig_stat, length, */ +/* LtimeZ, mat_vec, maxfactor, metrop, norm */ +/* normal, nugget, power, ran2, scal_vect, */ +/* solve3, sort, spherical, stable, statlog2nor */ +/* test_fract, trun1, trungasdev,vec_vec, */ +/* vf2gthres,polint */ + + + + +/*STRUCTURES*/ +/*----------*/ +/*variogram */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct vario_mod { + int Nvario; + int *vario; + double *alpha; + double *ap; + double *scf; + double *var; +}; + + + +/*variogram table */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct variotable_mod { + int number_of_variograms; + int *Nvario; + int *vario; + float *alpha; + float *ap; + float *scf; + float *var; +}; + + + + +/*grid */ +/*NX: number of gridblocks along the X axis*/ +/*NY: number of gridblocks along the Y axis*/ +/*NZ: number of gridblocks along the Z axis*/ +/*DX: gridblock length along the X axis */ +/*DY: gridblock length along the Y axis */ +/*DZ: gridblock length along the Z axis */ +/*Xo: X-cell number of the origin cell */ +/*Yo: Y-cell number of the origin cell */ +/*Zo: Z-cell number of the origin cell */ +struct grid_mod { + int NX, NY, NZ; + double DX,DY,DZ; + double Xo,Yo,Zo; +}; + + +/*well data */ +/*nwell: number of wells */ +/*n: number of measurement points per well */ +/* i = [0...nwell-1] */ +/*ntype: number of measurement types */ +/*code: status of the measurements i=[0...ntype-1] */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: uniform */ +/* --> 7: any */ +/*x: X-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*y: Y-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*z: Z-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*measure: values of the measurements */ +/* same kind of indexation, but repeated per type of */ +/* measurement */ +/* type 1 : */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/* type 2 : */ +/* i=[sum(n[k])... sum(n[k])+n[0]-1 ... 2*(sum(n[k])-1)]*/ + +struct welldata_mod { + int nwell; + int *n; + int ntype; + int *code; + float *x; + float *y; + float *z; + float *measure; +}; + + + +/*volume fractions for facies */ +/*ncat: number of facies */ +/*nblock: number of gridblocks with different */ +/* volume fractions */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*vf: volume fractions for the first ncat-1 facies*/ +/* i = [0...ncat-2]*nblock */ +struct statfacies_mod { + int ncat; + int nblock; + float *vf; +}; + + +/*inequalities for truncated plurigaussian realizations*/ +/*only two basic realizations Y1 and Y2 are considered */ +/*Y1 and Y2 are independent */ +/*nsY1: number of unknown thresholds for Y1 */ +/*nsY2: number of unknown thresholds for Y2 */ +/*thresholds: vector with the thresholds and -10 and 10*/ +/* the output values are the Gaussian */ +/* thresholds */ +/* i = [0 ... n+1], n = nsY1+nsY2 */ +/* thresholds[n] = -10,thresholds[n+1] = 10 */ +/* given at the beginning */ +/*address_sY1: successive upper and lower bounds for */ +/* the different facies for Y1 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY1 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +/*address_sY2: successive upper and lower bounds for */ +/* the different facies for Y2 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY2 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +struct inequalities_mod { + int nsY1; + int nsY2; + float *thresholds; + int *address_sY1; + int *address_sY2; +}; + + +/*statistical data */ +/*type --> 0 : normal */ +/* --> 1 : natural log */ +/* --> 2 : log 10 */ +/*nblock_mean: number of gridblocks with different */ +/* means */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*mean: mean of the variable i = [0...nblock_mean] */ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, MEAN IS LOG MEAN ! */ +/*nblock_var: number of gridblocks with different */ +/* variances */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*variance: variance of the variable i = [0...nblock_var]*/ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, VAR IS LOG VAR ! */ +struct statistic_mod { + int type; + int nblock_mean; + double *mean; + int nblock_var; + double *variance; +}; + + +/*gradual deformation parameters */ +/*Nadded: number of complementary realizations */ +/*NZONES: number of subregions */ +/*rho: gradual deformation parameters */ +/*rho[NZONES*(0...Nadded)] */ +/*cellini[NZONES*(0...2)] lower cell bound for */ +/*for subregions along axes X,Y,Z */ +/*cellfin[NZONES*(0...2)] upper cell bound for */ +/*for subregions along axes X,Y,Z */ +struct grad_mod { + int Nadded, NZONES; + float *rho; + int *cellini, *cellfin; +}; + + +/*gradient structures */ +/*Nparam : number of parameters for which gradients are */ +/* required */ +/*Ncells : number of cells for which gradients are */ +/* calculated */ +/*grad : vector with the calculated gradients */ +/* dimension = Nparam*Ncells */ +/* this vector is organized as */ +/* 0 1...Ncells-1 for the first parameter followed*/ +/* Ncells....2*Ncells-1 for the second parameter */ +/* and so on */ +struct gradients_mod { + int Nparam,Ncells; + float *grad; +}; + + + +/*description of discretized cumulative distributions */ +/*n: number of points */ +/*x: values along the x axis i = [0...n-1] */ +/*fx: corresponding values for the cumulative */ +/* distribution i = [0...n-1] */ +struct cdf_mod { + int n; + float *x; + float *fx; +}; + + +/*realization */ +/*n: number of components */ +/*code: status of the realization */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: conditional standard Normal */ +/* --> 7: conditional non standard Normal */ +/* --> 8: conditional lognormal (neperien) */ +/* --> 9: conditional lognormal (log10) */ +/* --> 10: conditional facies */ +/* --> 11: uniform numbers */ +/* --> 12: conditional uniform numbers */ +/* --> 13: unconditional any type */ +/* --> 14: conditional any type */ +/*vector: realization vector i = [0...n-1] */ +struct realization_mod { + int n; + int code; + double *vector; +}; + +/*=====================================================*/ + +/*FUNCTIONS*/ +/*---------*/ + + +/*normalization of the anostropy axes */ +/*ap: anisotropy axes */ +/*scf: correlation lengths */ +/* The returned normalized axes are in ap */ +void axes(double *ap, double *scf, int N); + + +/*cardsin covariance value for lag h*/ +double cardsin(double h); + + +/*Cholesky decomposition of matrix C */ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, 0 <= i <= n */ +/* n : dimension of matrix Cij */ +/* */ +/* C is turned into the lower triangular cholesky matrix*/ +void choldc(double *C, int n); + + +/*computes the coordinates of a given cell */ +/*as numbers of cells along the X,Y and Z axes*/ +/*maille = i[0]+1+i[1]*NX+i[2]*NX*NY */ +/*input: */ +/*maille: number of the cell to identify */ +/*grid: structure defining the grid */ +/*output: */ +/*i: vector with the coordinates */ +void coordinates(int maille, int i[3],struct grid_mod grid); + + +/*builds the sampled covariance function */ +/*dimensions are even */ +/*covar: covariance array, vector of size*/ +/*1+NX*NY*NZ, covar[0] is a dead cell */ +/*variogram: structure defined above */ +/*grid: structure defined above */ +/*n: number of gridblocks along X,Y and Z*/ +void covariance(double *covar,struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*computation of the covariance matrix for the well data*/ +/*well coordinates are given as a number of cells */ +/*The dimension of C is given by well.nwell */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +/*grid: structure defined above */ +void cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, struct grid_mod grid); + + +/*calculation of the covariance value for a distance h */ +/*defined by i,j,k */ +/*available variogram model: */ +/* 1 -> exponential */ +/* 2 -> gaussian */ +/* 3 -> spherical */ +/* 4 -> cardsin */ +/* 5 -> stable */ +/* 6 -> gamma */ +/* 7 -> cubic */ +/* 8 -> nugget */ +/* 9 -> power */ +/*variogram: variogram with the structure defined above*/ +/*di: distance along the X axis */ +/*dj: distance along the Y axis */ +/*dk: distance along the Z axis */ +/* The returned value is the computed covariance value */ +double cov_value(struct vario_mod variogram,double di,double dj,double dk); + +/*cubic covariance value for lag h*/ +double cubic(double h); + + +/*truncation of the power spectrum to remove */ +/*high frequencies - isotropic case */ +/*covar: power spectrum */ +/*kx: number of cells to save along the x-axis */ +/*ky: number of cells to save along the y-axis */ +/*kz: number of cells to save along the z-axis */ +/*n[3]: number of cells along the X, Y and Z axes*/ +void cutspectr(float *covar, int kx, int ky, int kz, int n[3]); + + +/*defines the threshold interval for a facies x*/ +/*lim_inf: lower bound */ +/*lim_sup: upper bound */ +/*x: facies */ +/*thresholds: Gaussian threshold vector */ +/*facies: structure defined above */ +/*nblock: gridcell number of point x */ +void deflimit(double *plim_inf, double *plim_sup, float x, float *thresholds, struct statfacies_mod facies,int nblock); + + +/*kriges the realization considering weights */ +/*realin: input realization */ +/*variogram: structure defining the variogram */ +/*k: type of measure */ +/*well: structure defining the well data */ +/*grid: structure defined above */ +/*D: weight vector of length Ndata, Di, i = 0...Ndata-1*/ +/*The kriged realization is stored in realout */ +void dual_kri(struct realization_mod *realin, struct vario_mod variogram,struct welldata_mod well, struct grid_mod grid, double *D,struct realization_mod *realout); + + + +/*exponential covariance value for lag h*/ +double exponential(double h); + + +/*Fast Fourier Transform - Cooley-Tukey algorithm */ +/*datar: real part vector - to be transformed */ +/*datai: imaginary part vector - to be transformed */ +/*nn: number of gridblocks along the X,Y and Z axes */ +/*ndim: number of dimensions */ +/*ifrwd: non-zero for forward transform, 0 for inverse*/ +/*icplx: non-zero for complex data, 0 for real */ +/*workr: utility real part vector for storage */ +/*worki: utility imaginary part vector for storage */ +/*The transformed data are returned in datar and datai*/ +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx,double *workr,double *worki); + + +/*calculates F(x) = (1/a)*exp(-x*x/2)*/ +double funtrun1(double x); + + +/*cumulative standard normal value*/ +float G(float x); + + +/*gamma covariance value for lag h and exponent alpha*/ +double gammf(double h, double alpha); + + +/*returns the value ln(G(x))*/ +float gammln(float xx); + + +/*incomplete gamma fnction*/ +float gammp(float a, float x); + + +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran1(idum) as the source */ +/*of uniform deviates */ +/*idum: seed */ +double gasdev(long *idum, long *idum2, long *iy, long *iv, int *iset); + +/*gaussian covariance value for lag h*/ +double gaussian(double h); + + +/*incomplete gamma function evaluated by its continued */ +/*fraction represented as gammcf, also returns ln(G(a))*/ +/*as gln */ +void gcf(float *gammcf, float a, float x, float *gln); + + +/*computation of the covariance matrix for the well data*/ +/*well coordinates have no specific unit */ +/*The dimension of C is given by n */ +/*C defines the correlation between the first n wells */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +void gen_cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, int n); + + +/*Ginv */ +/*Computes the inverse of the standard normal cumulative*/ +/*distribution function with a numerical approximation */ +/*from Statistical Computing,by W.J. Kennedy, Jr. and */ +/*James E. Gentle, 1980, p. 95. */ +/*input : */ +/*p: cumulative probability value */ +float Ginv(float p); + + +/*gradual combination of 1 realization + Nadded */ +/*complementary realizations */ +/*rho: gradual deformation parameters */ +/*rho[0...NZONES*Nadded-1] */ +/*rangement des vecteurs colonnes les uns apres */ +/*les autres */ +/*Zo: starting realization */ +/*Zo[0...n] */ +/*Z: complementary realizations all stored */ +/*Z[0...n-1 n...2n-1 ...(Nadded-1)n...Nadded.n-1]*/ +/*sequentially in a single vector */ +/*Nadded: number of complementary realizations */ +/*n: number of components per realization */ +/*NZONES: number of subregions */ +/*grid: grid definition */ +void gradual(struct grad_mod grad,float *Zo,float *Z,float *Zfinal,int n,struct grid_mod grid); + + +/*computes the size of the underlying grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*incomplete gamma function evaluated by its series*/ +/*representation as gamser, also returns ln(G(a)) */ +/*as gln */ +void gser(float *gamser, float a, float x, float *gln); + + +/*calculates x so that x = invF(u) */ +/*F is the cumulative density function for the */ +/*function approximating the Gaussian function */ +/*u: uniform deviate between 0 and 1 */ +/*lim_inf: lower bound of the considered interval*/ +/*lim_sup: upper bound of the considered interval*/ +/*C: normalizing constant */ +double invtrun1(double u, double lim_inf, double lim_sup, double C); + + +/*computes the kriging mean and variance*/ +/*for the vector bi, i = [0...n-1] */ +void krig_stat(float *b, int n, struct vario_mod variogram, struct welldata_mod well, float *mean, float *var); + + +/* computes the number of gridblocks for one dimension*/ +/*N: initial number of gridblocks */ +/*i: considered direction */ +/*scf: correlation length */ +/*ap: normalized anisotropy axes */ +int length(int N, int i, double *scf, double *ap, double D, int Nvari); + +/*calculates L.Z/ +/* L : lower triangular matrix recorded */ +/* (per raws) as a vector with only components */ +/* Lij so that j <= i, i = [0...n-1] */ +/* Z : vector, Zi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Lij */ +/* */ +/* The solution vector is returned in b */ +void LtimeZ(double *L, float *Z, float *b, int n); + + +/*calculates C.x/ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* x : vector, xi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Cij */ +/* */ +/* The result vector is returned in b */ +void mat_vec(double *C, double *x, double *b, int n); + + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n); + +/*metrop returns a boolean varible that issues a */ +/*verdict on whether to accept a reconfiguration */ +/*defined by the probability ratio "ratio". */ +/*If ratio >= 1, metrop = 1(true), while if ratio < 1, */ +/*metrop is only true with probability "ratio" */ +int metrop(double ratio,long *idum,long *idum2, long *iy, long *iv); + + +/*2-norm of vector b */ +/* b : vector */ +/* n : length of b, bi, i = [0...n-1]*/ +/*returns the norm of b */ +double norm(double *b,int n); + + +/*value of g(x) where g is the normal function*/ +double normal(double x); + + +/*nugget covariance value for lag h*/ +double nugget(double h); + + +/*power covariance value for lag h and exponent alpha*/ +double power(double h,double alpha); + + +/*generates uniform deviates between 0 and 1*/ +/*idum: seed */ +double ran2(long *idum, long *idum2, long *iy, long *iv); + + + +/*calculates bt.b */ +/* b : vector, bi, i = [0...n-1] */ +/* n : length of b */ +/*returns the scalar product of b*/ +double scal_vec(double *b,int n); + + +/*solves the set of n linear equations Cx = D */ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* D : right-hand side vector, Di avec i = [0...n-1]*/ +/* n : dimension of matrix Cij */ +/* */ +/* The solution vector is returned in D */ +/* CONJUGATE GRADIENT method */ +void solve3(double *C, double *D, int n); + + +/*sorts an array [0...n-1] into ascending order using */ +/*shell */ +void sort(float n, float *arr); + + +/*spherical covariance value for lag h*/ +double spherical(double h); + + +/*stable covariance value for lag h and exponent alpha*/ +double stable(double h, double alpha); + + +/*conversion of log mean and variance to nor*/ +void statlog2nor(struct statistic_mod *pstat); + + +/*tries factor */ +/*pnum: number to be decomposed */ +/*fact: suggested factor */ +/*pmaxfac: memory to keep the greatest factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac); + + +/*calculates the integrale of an approximate function*/ +/*for the Gaussian function over an interval defined */ +/*by lim_inf and lim_sup */ +/*lim_inf: lower bound of the considered interval */ +/*lim_sup: upper bound of the considered interval */ +double trun1(double lim_inf, double lim_sup); + + +/*draws a truncated gaussian variable between lim_inf*/ +/*and lim_sup */ +/*idum: seed */ +double trungasdev(long *idum,double lim_inf,double lim_sup,long *idum2, long *iy, long iv[NTAB]); + +/* tb1.b2 */ +/* b1 : vector */ +/* b2 : vector */ +/* n : length of b1 and b2, bi, i = [0...n-1]*/ +/*returns the norm the product tb1.b2 */ +double vec_vec(double *b1, double *b2,int n); + + +/*turns the volume fractions into Gaussian thresholds */ +/*facies: structure defined above */ +/*thresholds: output threshold vector fot i = [0...n-1]*/ +/*where n is the number of facies-1 */ +/*USES normal*/ +void vf2gthres(struct statfacies_mod facies,float *thresholds); + +void polint(float xa[],float ya[],int n,float x, float *y,float *dy); + + + +#endif diff --git a/fftma_module/gen/LIBFFTMA/length.c b/fftma_module/gen/LIBFFTMA/length.c new file mode 100755 index 0000000..c2dfc8b --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/length.c @@ -0,0 +1,39 @@ +#include + +/* compute the length for one dimension*/ +int length(int N, int i, double *scf, double *ap, double D, int Nvari) +{ + int maxfactor(int n); + double temp1, temp2; + int n, j, k, nmax; + int nlimit = 13; + + if (N == 1) { + n = 1; + } else { + + for (k = 0; k < Nvari; k++) { + temp1 = fabs(ap[9*k+i])*scf[3*k]*scf[3*k]; + for (j = 1; j <3; j++) { + temp2 = fabs(ap[9*k+3*j+i])*scf[3*k+j]*scf[3*k+j]; + if (temp2 > temp1) + temp1 = temp2; + } + } + temp1 = sqrt(temp1); + temp1 /= (double)D; + if ((double)N/temp1 < 2.) { + n = N+(int)(2*temp1); + } else { + n = N+(int)temp1; + } + if ((n % 2) != 0) + n = n+1; + nmax = maxfactor(n); + while (nmax > nlimit) { + n += 2; + nmax = maxfactor(n); + } + } + return (n); +} diff --git a/fftma_module/gen/LIBFFTMA/makefileFFTMA_debug.lib b/fftma_module/gen/LIBFFTMA/makefileFFTMA_debug.lib new file mode 100755 index 0000000..98f92c5 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/makefileFFTMA_debug.lib @@ -0,0 +1,36 @@ +# +######################################################################## +# +# Makefile for library +# +######################################################################## +# + +INCLUDE = -I./ +LIBS = -lm -L./ +# CCFLAGS = -fast +ifeq (${ARCH},sun) + CC = cc + CCFLAGS = -g +endif +ifeq (${ARCH},linux) + CC = gcc + CCFLAGS = -g +endif + +LIB = libFFTMA_debug_${ARCH}.a + +NOBJS= gammf.o FFTMA.o addstat.o axes.o cgrid.o covariance.o fourt.o length.o maxfactor.o test_fact.o cov_value.o generate.o gasdev.o ran2.o stable.o gaussian.o power.o cubic.o spherical.o nugget.o exponential.o cardsin.o nor2log.o + + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/LIBFFTMA/maxfactor.c b/fftma_module/gen/LIBFFTMA/maxfactor.c new file mode 100755 index 0000000..842cd8b --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/maxfactor.c @@ -0,0 +1,35 @@ +#include "genlib.h" + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n) +{ + int test_fact(int *pnum, int fact, int *pmaxfac); + int lnum, fact; + int maxfac; + + maxfac = 1; + lnum = n; + + if ( lnum != 0 && lnum != 1 ) { + fact = 2; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 3; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 5; + for (;;) { + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 2; + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 4; + } + } + } + if ( lnum != 1 ) { + if (lnum > maxfac) + maxfac = lnum; + } + } + return (maxfac); +} diff --git a/fftma_module/gen/LIBFFTMA/nor2log.c b/fftma_module/gen/LIBFFTMA/nor2log.c new file mode 100755 index 0000000..44b6568 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/nor2log.c @@ -0,0 +1,78 @@ +#include +#include +#include "geostat.h" + + +/*TURNS NORMAL NUMBERS INTO LOGNORMAL NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* normal numbers */ +/*typelog: --> 3: lognormal (natural) */ +/* --> 4: lognormal (log10) */ +/*output: */ +/*realout: structure defining a realization - */ +/* lognormal numbers */ + +void nor2log(struct realization_mod *realin, int typelog, struct realization_mod *realout) +{ + + int i; + double coeff; + + + coeff = log(10.0); + + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("No memory available"); + return; + } + } + (*realout).n = (*realin).n; + + + switch ((*realin).code) { + case 0: + case 1: + case 2: + (*realout).code = typelog; + break; + case 6: + case 7: + if (typelog == 3) { + (*realout).code = 8; + } else if (typelog == 4) { + (*realout).code = 9; + } + break; + default: + printf("Input is not normal in nor2log"); + return; + break; + } + + + /*anamorphose*/ + for (i = 0; i < (*realin).n; i++) { + switch (typelog) { + case 3: + /*natural logarithm*/ + (*realout).vector[i] = exp((*realin).vector[i]); + break; + case 4: + /*log10*/ + (*realout).vector[i] = exp((*realin).vector[i]*coeff); + break; + default: + printf("Unexpected case in nor2log"); + return; + break; + } + } + + return; +} diff --git a/fftma_module/gen/LIBFFTMA/nugget.c b/fftma_module/gen/LIBFFTMA/nugget.c new file mode 100755 index 0000000..cda4929 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/nugget.c @@ -0,0 +1,14 @@ +#include +#include +#include "genlib.h" + + +/*nugget covariance function*/ +double nugget(double h) +{ + if (h == 0) { + return (1.); + } else { + return(0.); + } +} diff --git a/fftma_module/gen/LIBFFTMA/power.c b/fftma_module/gen/LIBFFTMA/power.c new file mode 100755 index 0000000..88281f6 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/power.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*power covariance function*/ +double power(double h, double alpha) +{ + return(pow(h,alpha)); +} diff --git a/fftma_module/gen/LIBFFTMA/ran2.c b/fftma_module/gen/LIBFFTMA/ran2.c new file mode 100755 index 0000000..8075f4f --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/ran2.c @@ -0,0 +1,50 @@ +#include "genlib.h" + +#define IM1 2147483563 +#define IM2 2147483399 +#define AM (1.0/IM1) +#define IMM1 (IM1-1) +#define IA1 40014 +#define IA2 40692 +#define IQ1 53668 +#define IQ2 52774 +#define IR1 12211 +#define IR2 3791 +#define NTAB 32 +#define NDIV (1+IMM1/NTAB) +#define EPS 1.2e-7 +#define RNMX (1.0-EPS) + +double ran2(long *idum, long *idum2, long *iy, long iv[NTAB]) + +{ + int j; + long k; + double temp; + + if (*idum <= 0) { + if (-(*idum) < 1) *idum = 1; + else *idum = -(*idum); + *idum2 = (*idum); + for (j = NTAB+7; j >= 0; j--) { + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + if (j < NTAB) iv[j] = *idum; + } + *iy = iv[0]; + } + + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + k = *idum2/IQ2; + *idum2 = IA2*(*idum2-k*IQ2)-k*IR2; + if (*idum2 < 0) *idum2 += IM2; + j = (*iy)/NDIV; + *iy = iv[j]-(*idum2); + iv[j] = *idum; + if (*iy < 1) (*iy) += IMM1; + if ((temp = AM*(*iy)) > RNMX) return (RNMX); + else return (temp); +} diff --git a/fftma_module/gen/LIBFFTMA/spherical.c b/fftma_module/gen/LIBFFTMA/spherical.c new file mode 100755 index 0000000..a36e492 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/spherical.c @@ -0,0 +1,17 @@ +#include +#include +#include "genlib.h" + + +/*spherical covariance function*/ +double spherical(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-1.5*(double)h+0.5*(double)(h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/LIBFFTMA/stable.c b/fftma_module/gen/LIBFFTMA/stable.c new file mode 100755 index 0000000..45c5a29 --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/stable.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*stable covariance function*/ +double stable(double h, double alpha) +{ + return(exp(-3.*(double)pow(h,alpha))); +} diff --git a/fftma_module/gen/LIBFFTMA/test_fact.c b/fftma_module/gen/LIBFFTMA/test_fact.c new file mode 100755 index 0000000..d2456ee --- /dev/null +++ b/fftma_module/gen/LIBFFTMA/test_fact.c @@ -0,0 +1,26 @@ +#include "genlib.h" + +/*tries factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac) +{ + int power, t; + + power = 0; + while ( ( t = *pnum / fact ) * fact == *pnum ) { + ++power; + *pnum = t; + } + + if ( power != 0 ) { + if (fact > *pmaxfac) + *pmaxfac = fact; + } + + if ( t > fact ) { + return (1); + } + + return (0); +} + + diff --git a/fftma_module/gen/LIB_FFTMA2/._.DS_Store b/fftma_module/gen/LIB_FFTMA2/._.DS_Store new file mode 100755 index 0000000..c9474ea Binary files /dev/null and b/fftma_module/gen/LIB_FFTMA2/._.DS_Store differ diff --git a/fftma_module/gen/LIB_FFTMA2/FFTMAmemoire.c b/fftma_module/gen/LIB_FFTMA2/FFTMAmemoire.c new file mode 100755 index 0000000..15d7f04 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/FFTMAmemoire.c @@ -0,0 +1,110 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + string variable; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); +/* testmemory(covar); */ + allouememoire(covar,'covar'); + + + + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/LIB_FFTMA2/Makefile.libFFTMA2 b/fftma_module/gen/LIB_FFTMA2/Makefile.libFFTMA2 new file mode 100755 index 0000000..09fc204 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/Makefile.libFFTMA2 @@ -0,0 +1,30 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +INTERFACE = ../include + +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CC = cc + CCFLAGS = + +LIB = libFFTMA2_${ARCH}.a + +NOBJS= kgeneration.o kgeneration2.o fftma2.o prebuild_gwn.o build_real.o addstat2.o clean_real.o + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/LIB_FFTMA2/addstat2.c b/fftma_module/gen/LIB_FFTMA2/addstat2.c new file mode 100755 index 0000000..3096d0f --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/addstat2.c @@ -0,0 +1,119 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + if ((*realout2).vector == NULL || (*realout2).n != (*realin).n) { + (*realout2).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout2).vector == NULL) + Error("No memory available"); + } + (*realout2).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + (*realout2).code = 2; + break; + case 6: + (*realout).code = 7; + (*realout2).code = 7; + break; + default: + (*realout).code = (*realin).code; + (*realout2).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + /* switch (stat.type) { */ +/* case 0: */ + + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + +/* break; */ +/* case 1: */ + /*lognormal (natural) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log(1.0+r); */ +/* break; */ +/* case 2: */ + /*lognormal (log10) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log10(1.0+r); */ +/* break; */ +/* default: */ +/* Error("Type not defined in addstat"); */ +/* break; */ +/* } */ + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]; + (*realout2).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/LIB_FFTMA2/build_real.c b/fftma_module/gen/LIB_FFTMA2/build_real.c new file mode 100755 index 0000000..4a0e186 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/build_real.c @@ -0,0 +1,45 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal) +{ + int i,j,k,maille1; + double temp; + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + ireal[maille1] *= temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/LIB_FFTMA2/clean_real.c b/fftma_module/gen/LIB_FFTMA2/clean_real.c new file mode 100755 index 0000000..d249b18 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/clean_real.c @@ -0,0 +1,43 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + /* Modif du 18 juin 2003 */ + /*(*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT;*/ + (*realout).vector[maille0] = vectorresult[maille1]; + } + } + } + + return; +} diff --git a/fftma_module/gen/LIB_FFTMA2/fftma2.c b/fftma_module/gen/LIB_FFTMA2/fftma2.c new file mode 100755 index 0000000..5977690 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/fftma2.c @@ -0,0 +1,105 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/LIB_FFTMA2/kgeneration.c b/fftma_module/gen/LIB_FFTMA2/kgeneration.c new file mode 100755 index 0000000..633e4c8 --- /dev/null +++ b/fftma_module/gen/LIB_FFTMA2/kgeneration.c @@ -0,0 +1,79 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i +#include +#include +#include +#include +#include +#include "geostat.h" + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver) + + { + int i,j,k,maille0,maille1; + int ntot; + + ntot=n[0]*n[1]*n[2]; + realization[0]=0.; + if (solver==1) + { + for (i=0;i +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _TOOLSFFTMA_H +#define _TOOLSFFTMA_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* kgeneration, FFTMA2, prebuild_gwn, build_real, addstat2, clean_real */ + + +/*FUNCTIONS*/ +/*----------*/ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y2, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise); + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) ; + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver); + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal); + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2); + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout); + +#endif // define _TOOLSFFTMA_H diff --git a/fftma_module/gen/LIB_FFTPSIM/._.DS_Store b/fftma_module/gen/LIB_FFTPSIM/._.DS_Store new file mode 100755 index 0000000..c9474ea Binary files /dev/null and b/fftma_module/gen/LIB_FFTPSIM/._.DS_Store differ diff --git a/fftma_module/gen/LIB_FFTPSIM/FFTPSim.c b/fftma_module/gen/LIB_FFTPSIM/FFTPSim.c new file mode 100755 index 0000000..0f65c29 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/FFTPSim.c @@ -0,0 +1,162 @@ +#include +#include +#include "geostat.h" +#include "toolsludo.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *covar,*realization,*pressure; + double *icovar,*ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + icovar = (double *) malloc(ntot * sizeof(double)); + testmemory(icovar); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,icovar,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + + prebuild_gwn(grid,n,realin,realization); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real(realin,n,grid,realization,realout); + clean_real(realin,n,grid,pressure,realout2); + clean_real(realin,n,grid,xvelocity,realout3); + clean_real(realin,n,grid,yvelocity,realout4); + clean_real(realin,n,grid,zvelocity,realout5); + + free(realization); + free(pressure); + free(xvelocity); + free(yvelocity); + free(zvelocity); + + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/FFTPressure.c b/fftma_module/gen/LIB_FFTPSIM/FFTPressure.c new file mode 100755 index 0000000..15ab392 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/FFTPressure.c @@ -0,0 +1,157 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization,*pressure; + double *ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + FILE *fp; +/* string nomfichier; */ + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + for (i=1;i<=NTOT;i++) + realization[i]=realization[i]/(double) NTOT; + + fp = fopen("realization.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + +/* nomfichier="pression.test"; */ + fp = fopen("pression.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",pressure[i]); + fclose(fp); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real2(realin,n,grid,solver,pressure,realout); + clean_real2(realin,n,grid,solver,xvelocity,realout2); + clean_real2(realin,n,grid,solver,yvelocity,realout3); + clean_real2(realin,n,grid,solver,zvelocity,realout4); + + /* free(realization); */ + /* free(pressure); */ + /* free(xvelocity); */ + /* free(yvelocity); */ + /* free(zvelocity); */ + + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/FFTtest.c b/fftma_module/gen/LIB_FFTPSIM/FFTtest.c new file mode 100755 index 0000000..9f88ee0 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/FFTtest.c @@ -0,0 +1,68 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM Test */ + +void FFTtest(int n[3],struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization; + double *ireal; + double ki,kj,kk; + FILE *fp; + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + fp = fopen("perm.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + fp = fopen("perm2.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/Makefile.libFFTPSim b/fftma_module/gen/LIB_FFTPSIM/Makefile.libFFTPSim new file mode 100755 index 0000000..49f4e7a --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/Makefile.libFFTPSim @@ -0,0 +1,34 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +#INTERFACE = ${BOSSE}/CODES/LIBS_C/Interface +#INTERFACE2= ${BOSSE}/CODES/Geostat/FFTPSim/Version_binaire2/src/Interface + +INTERFACE = ../include +#INTERFACE2= ../Interface + +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CCFLAGS = +CC = cc + +LIB = libFFTPSIM_${ARCH}.a + +NOBJS= pgeneration.o pgeneration2.o FFTPressure.o FFTtest.o build_pressure.o build_velocity.o total_pressure.o total_velocity.o clean_real2.o waveVectorCompute3D.o mat_vec.o derivReal.o + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/LIB_FFTPSIM/build_pressure.c b/fftma_module/gen/LIB_FFTPSIM/build_pressure.c new file mode 100755 index 0000000..b9ded34 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/build_pressure.c @@ -0,0 +1,66 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_pressure */ +/* build pressure in spectral domain */ + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure) +{ + int i,j,k,maille1; + double ki,kj,kk; + double coeff,temp,temp2; + + /* pressure calculation in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (n[0]==1) + { + ki=0.; + } + else + { + ki =(double)(i-1)/(double)(grid.NX*grid.DX); + } + if (n[1]==1) + { + kj=0.; + } + else + { + kj =(double)j/(double)(grid.NY*grid.DY); + } + if (n[2]==1) + { + kk=0.; + } + else + { + kk =(double)k/(double)(grid.NZ*grid.DZ); + } + + coeff = (gradient.x*ki+gradient.y*kj+gradient.z*kk)/(ki*ki+kj*kj+kk*kk); + temp = realization[maille1]; + temp2= ireal[maille1]; + if (maille1==1) + { + pressure[maille1] =0.; + ipressure[maille1]=0.; + } + else + { + pressure[maille1] =-1./(2*3.14)*coeff*temp2; + ipressure[maille1]= 1./(2*3.14)*coeff*temp; + } + } + } + } + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/build_velocity.c b/fftma_module/gen/LIB_FFTPSIM/build_velocity.c new file mode 100755 index 0000000..7511c4d --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/build_velocity.c @@ -0,0 +1,117 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_velocity */ +/* Build velocity in spectral domain */ + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction) +{ + int i,j,k,maille1; + int x,y,z; + double ki,kj,kk; + double coeff,temp,temp2; + double grad; + + /* x-direction velocity calculation in the spectral domain*/ + switch(direction) + { + case 1: + grad = gradient.x; + x=1; + y=0; + z=0; + break; + case 2: + grad = gradient.y; + x=0; + y=1; + z=0; + break; + case 3: + grad = gradient.z; + x=0; + y=0; + z=1; + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; +/* if (i +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real2.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + if (solver==1) + { + for ( k = 1; k <= NTOT;k++) + { + (*realout).vector[k-1] = vectorresult[k]/(double) NTOT; + } + } + else + { + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT; + } + } + } + } + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/derivReal.c b/fftma_module/gen/LIB_FFTPSIM/derivReal.c new file mode 100755 index 0000000..7e7e02b --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/derivReal.c @@ -0,0 +1,216 @@ +#include +#include +#include +#include "condor.h" +#include "geostat.h" + +/* Private functions */ +void normAxes(double *vec, double *normed); + + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario) { + + int n[3],i,j,k,maille,extMaille; + int NTOT,ntot,NMAX,nmax,NDIM; +// int NXYZ,nxyz; + double nDir[3]; + double *table,*workr,*worki,*realization,*waveVect; + + + int Ngrid; + double tmp; + double *ExtendedWaveVect; + +/* Test the input real*/ +/* if ((*Z).code != 1) { */ +/* printf("Realization should be Standard Normal\n"); */ +/* return; */ +/* } */ + + printf("grid.Nx = %d\n",(*grid).NX); + printf("grid.Ny = %d\n",(*grid).NY); + printf("grid.Nz = %d\n",(*grid).NZ); + + printf("vario.Nvario = %d\n",vario.Nvario); + for(i=0; i NMAX) NMAX = n[i]; + if (n[i] == 1) NDIM = NDIM-1; + } + nmax = NMAX+1; + + printf("NTOT = %d, ntot = %d, NMAX = %d\n",NTOT,ntot,NMAX); + +/* wave vector computation */ + normAxes(dir,nDir); + printf("Derivation direction (normed) %f %f %f\n",nDir[0],nDir[1],nDir[2]); + waveVect = (double *) malloc(Ngrid*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + waveVectorCompute3D((*grid).NX,(*grid).NY,(*grid).NZ,nDir,waveVect); + +/* memory allocation */ + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("derivReal.cpp: No memory availble for table\n"); + return; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + ExtendedWaveVect = (double *) malloc(ntot * sizeof(double)); + if (ExtendedWaveVect == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("derivReal.cpp: No memory available for workr\n"); + return; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("derivReal.cpp: No memory available for worki\n"); + return; + } + + extMaille =0; +/* organization of the extended realization */ + for (k=1;k<=n[2];k++) { + for (j=1;j<=n[1];j++) { + for (i=1;i<=n[0];i++) { + extMaille = i + ((j-1) + (((k-1) * n[1]) * n[0])); + if (i <= (*grid).NX && j <= (*grid).NY && k <= (*grid).NZ) { + maille = i-1 + ((j-1) + ((k-1) * (*grid).NY) * (*grid).NX); + realization[extMaille] = (*Z).vector[maille]; + ExtendedWaveVect[extMaille] = waveVect[maille]; + } else { + realization[extMaille] = 0.0; + ExtendedWaveVect[extMaille] = 0.0; + } + } + } + } + +/* forward fourier transform of the realization */ + fourt(realization,table,n,NDIM,1,0,workr,worki); + FILE *wave; + wave = fopen("/home/irsrvshare1/R03/UPS_FLEX/waveVector.eas","w"); + + for (i=1;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + /*save the delta-pressure realization*/ + writefile(filename[2],P); + + total_pressure(grid,pression,P); + + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + writefile(filename[3],P); + /*save the x-velocity realization*/ + writefile(filename[4],VX); + /*save the y-velocity realization*/ + writefile(filename[5],VY); + /*save the z-velocity realization*/ + writefile(filename[6],VZ); + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + /*save the pressure gradient realization*/ + writefile(filename[7],&GP); + + return; + } diff --git a/fftma_module/gen/LIB_FFTPSIM/pgeneration2.c b/fftma_module/gen/LIB_FFTPSIM/pgeneration2.c new file mode 100755 index 0000000..b81df82 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/pgeneration2.c @@ -0,0 +1,99 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + + /*save the delta-pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[2],P); + break; + case 1: + writefile_bin(filename[2],P); + break; + } + + total_pressure(grid,pression,P); + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[3],P); + break; + case 1: + writefile_bin(filename[3],P); + break; + } + + /*save the x-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[4],VX); + break; + case 1: + writefile_bin(filename[4],VX); + break; + } + + /*save the y-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[5],VY); + break; + case 1: + writefile_bin(filename[5],VY); + break; + } + /*save the z-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[6],VZ); + break; + case 1: + writefile_bin(filename[6],VZ); + break; + } + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + + /*save the pressure gradient realization*/ + switch (format_file) + { + case 0: + writefile(filename[7],&GP); + break; + case 1: + writefile_bin(filename[7],&GP); + break; + } + + return; + } diff --git a/fftma_module/gen/LIB_FFTPSIM/toolsFFTPSIM.h b/fftma_module/gen/LIB_FFTPSIM/toolsFFTPSIM.h new file mode 100755 index 0000000..41fd3e3 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/toolsFFTPSIM.h @@ -0,0 +1,59 @@ +#include +#include "geostat.h" +#include "pressure.h" + + +#ifndef _TOOLSFFTPSIM_H +#define _TOOLSFFTPSIM_H + +/* Create december, the 16th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* pgeneration, FFTPSim, FFTPressure, build_pressure, build_velocity,total_pressure,total_velocity, clean_real2 */ + +/*Functions */ +/*----------*/ + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver); + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file); + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5); + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4, int solver); + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure); + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction); + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression:: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout); + +/* total_velocity */ +/* Build total velocity in one direction */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout); + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout); + +void normAxes(double *vec, double *normed); +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*float dX, float dY, float dZ,*/ double nDir[3], double *waveVect); + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario); + +void mat_vec(double *C, double *x, double *b, int n); + + +#endif // define _TOOLSFFTPSIM_H diff --git a/fftma_module/gen/LIB_FFTPSIM/total_pressure.c b/fftma_module/gen/LIB_FFTPSIM/total_pressure.c new file mode 100755 index 0000000..24135c1 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/total_pressure.c @@ -0,0 +1,35 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,reference; + + reference=abs(gradient.x)*grid.NX*grid.DX+abs(gradient.y)*grid.NY*grid.DY+abs(gradient.z)*grid.NZ*grid.DZ; + /* pressure reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; +/* temp=reference+gradient.x*i*grid.DX+gradient.y*j*grid.DY+gradient.z*k*grid.DZ+(*realout).vector[maille1]; */ + temp=-gradient.x*(i+1)/grid.NX-gradient.y*(j+1)/grid.NY-gradient.z*(k+1)/grid.NZ+(*realout).vector[maille1]; + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/total_velocity.c b/fftma_module/gen/LIB_FFTPSIM/total_velocity.c new file mode 100755 index 0000000..63344c1 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/total_velocity.c @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_velocity */ +/* Build total velocity */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,grad; + switch(direction) + { + case 1: + grad = gradient.x/(grid.NX*grid.DX); + break; + case 2: + grad = gradient.y/(grid.NY*grid.DY);/* *grid.NY*grid.DY; */ + break; + case 3: + grad = gradient.z/(grid.NZ*grid.DZ); /* *grid.NZ*grid.DZ; */ + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + /* x velocity reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; + temp=mean*grad+(*realout).vector[maille1]; +/* temp=mean*grad; */ + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/LIB_FFTPSIM/waveVectorCompute3D.c b/fftma_module/gen/LIB_FFTPSIM/waveVectorCompute3D.c new file mode 100755 index 0000000..58e8342 --- /dev/null +++ b/fftma_module/gen/LIB_FFTPSIM/waveVectorCompute3D.c @@ -0,0 +1,156 @@ +//#include +//#include +#include +#include +#include +#include +#include +#include + +//using namespace std; + +/*Private functions */ +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*double dX, double dY, double dZ,*/ double nDir[3], double *waveVect) { + + int nTot; + double *vecX,*vecY,*vecZ; + double *waveVect3DX, *waveVect3DY, *waveVect3DZ; + + int i, j, k, maille; + + nTot = nX*nY*nZ; +// printf("nX = %d, nY = %d, nZ = %d, nTot = %d\n",nX,nY,nZ,nTot); +// printf("Entering waveVectorCompute3D\n"); + +/*Memory allocation */ + waveVect3DX = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DX == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DX\n"); + return; + } + waveVect3DY = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DY == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DY\n"); + return; + } + waveVect3DZ = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DZ == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DZ\n"); + return; + } + + vecX = (double *)malloc(nX * sizeof(double)); + if (vecX == NULL) { + printf("waveVectCompute.cpp : No memory available for vecX\n"); + return; + } + + vecY = (double *)malloc(nY * sizeof(double)); + if (vecY == NULL) { + printf("waveVectCompute.cpp : No memory available for vecY\n"); + return; + } + + vecZ = (double *)malloc(nZ * sizeof(double)); + if (vecZ == NULL) { + printf("waveVectCompute.cpp : No memory available for vecZ\n"); + return; + } + +// printf("memory allocation done.\n"); + + waveVectorCompute1D(nX,vecX); + waveVectorCompute1D(nY,vecY); + waveVectorCompute1D(nZ,vecZ); +// printf("waveVectorCompute1D: done!\n"); + + for(k = 0; k < nZ; k++) { +// printf("k=%d\n",k); + for(j = 0; j < nY; j++) { +// printf("j=%d: ",j); + for(i = 0; i < nX; i++) { + maille = i + (j + (k)*nY)*nX; +// waveVect3DX[maille] = vecX[i]/(nX*dX); +// waveVect3DY[maille] = vecY[j]/(nY*dY); +// waveVect3DZ[maille] = vecZ[k]/(nZ*dZ); + waveVect3DX[maille] = vecX[i]; + waveVect3DY[maille] = vecY[j]; + waveVect3DZ[maille] = vecZ[k]; +// printf("i=%d: %f ",i,vecZ[k]); + } +// printf("\n"); + } + } +// printf("waveVector3DX, Y and Z rearanged\n"); + free(vecX); + free(vecY); + free(vecZ); + if (waveVect == NULL) { + printf("allocate memory for waveVect\n"); + waveVect = (double *) malloc((nTot+1)*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + printf("after allocate memory for waveVect\n"); + } + + for (i=1;i<=nTot;i++) { + waveVect[i] = nDir[0]*waveVect3DX[i-1] + nDir[1]*waveVect3DY[i-1] + nDir[2]*waveVect3DZ[i-1]; +// printf("waveVect[%d] = %f\n",i,waveVect[i]); + } +// printf("waveVector rearanged\n"); + + free(waveVect3DX); + free(waveVect3DY); + free(waveVect3DZ); + +} + +void waveVectorCompute1D(int n,double *vec){ + + int midPoint,k; + + if(ceil(n/2) - floor(n/2) < 1.) { +// printf("coucou\n"); +/*n is even */ + midPoint = (int) floor(n/2); + vec[midPoint] = (double) midPoint; + } else { +/*n is odd */ + midPoint = (int) floor(n/2)-1; + vec[midPoint] = (double) midPoint+1; + } + for (k=1;k +#include +#include +#include +#include +#include + +void allouememoire(double *realint, string variable) +{ + + if (realint == NULL) { + printf("Testmemory.c: No memory available for %s\n",variable); + exit; + } + return; +} diff --git a/fftma_module/gen/LIB_IO/debuginput.c b/fftma_module/gen/LIB_IO/debuginput.c new file mode 100755 index 0000000..b9c3a45 --- /dev/null +++ b/fftma_module/gen/LIB_IO/debuginput.c @@ -0,0 +1,73 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "toolsIO.h" + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void debuginput(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite) +{ + int i; + + + /* debug du 8/7/2002 */ + printf("\n\n"); + + printf("Starting seed (integer): %d\n",(*seed)); + printf("Number of cells along the X axis: %d\n",(*grid).NX); + printf("Number of cells along the Y axis: %d\n",(*grid).NY); + printf("Number of cells along the Z axis: %d\n",(*grid).NZ); + printf("cell length along the X axis: %6.4f\n",(*grid).DX); + printf("cell length along the Y axis: %6.4f\n",(*grid).DY); + printf("cell length along the Z axis: %6.4f\n",(*grid).DZ); + printf("Number of structures for the variogram: %d\n",(*variogram).Nvario); + i=0; + printf("Weight: %6.4f\n",(*variogram).var[i]); + printf("Type of variogram: %d\n",(*variogram).vario[i]); + printf("Exponent: %6.4f\n",(*variogram).alpha[i]); + + printf("Mean of the output realization: %15.8f\n",(*stat).mean[0]); + printf("Variance of the output realization: %6.4f\n",(*stat).variance[0]); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : %d\n",(*stat).type); + + /*output files*/ + printf("output filename for permeability realization: %s\n", filename[1]); + printf("\n\n"); + if (*gwnwrite == 0) + { + printf("K field generation with Gaussian white noise!\n"); + printf("output filename for Gaussian white noise: %s\n",filename[0]); + } + printf("\n\n"); + if ((*Ksolver == 1) | (*Ksolver == 2)) + { + printf("P field generation: %d/n",*Ksolver); + printf("output filename for pressure realization: %s\n", filename[2]); + printf("output filename for pressure total realization: %s\n", filename[3]); + printf("output filename for x-velocity realization: %s\n", filename[4]); + printf("output filename for y-velocity realization: %s\n", filename[5]); + printf("output filename for z-velocity realization: %s\n", filename[6]); + printf("output filename for pressure gradient realization: %s\n", filename[7]); + + /*Pressure data*/ + printf("Pressure gradient in x direction: %6.4f\n",(*pression).x); + printf("Pressure gradient in y direction: %6.4f\n",(*pression).y); + printf("Pressure gradient in z direction: %6.4f\n",(*pression).z); + } + printf("\n\n"); + + return; +} diff --git a/fftma_module/gen/LIB_IO/inputdata.c b/fftma_module/gen/LIB_IO/inputdata.c new file mode 100755 index 0000000..259f1dd --- /dev/null +++ b/fftma_module/gen/LIB_IO/inputdata.c @@ -0,0 +1,122 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + + + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + int i,j; + + + /*seed*/ + printf("Starting seed (integer): \n"); + *seed = GetInteger(); + + /*Grid description*/ + printf("Number of cells along the X axis: \n"); + (*grid).NX = GetInteger(); + printf("Number of cells along the Y axis: \n"); + (*grid).NY = GetInteger(); + printf("Number of cells along the Z axis: \n"); + (*grid).NZ = GetInteger(); + printf("cell length along the X axis: \n"); + (*grid).DX = GetReal(); + printf("cell length along the Y axis: \n"); + (*grid).DY = GetReal(); + printf("cell length along the Z axis: \n"); + (*grid).DZ = GetReal(); + + /*output file*/ + printf("output filename for Gaussian white noise: \n"); + filename[0] = GetLine(); + + /*variogram description*/ + printf("Number of structures for the variogram: \n"); + (*variogram).Nvario = GetInteger(); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + printf("i %d\n",i); + printf("Weight: \n"); + (*variogram).var[i] = GetReal(); + printf("Type of variogram: \n"); + (*variogram).vario[i] = GetInteger(); + printf("Exponent: \n"); + (*variogram).alpha[i] = GetReal(); + printf("Correlation lengths (3): \n"); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]=GetReal(); + printf("Coordinates of the first two main axes (first axis first, then second): \n"); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = GetReal(); + } + + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + printf("Mean of the output realization: \n"); + (*stat).mean[0] = GetReal(); + printf("Variance of the output realization: \n"); + (*stat).variance[0] = GetReal(); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : \n"); + (*stat).type = GetInteger(); + + /*output file*/ + printf("output filename for permeability realization: \n"); + filename[1] = GetLine(); + + /*Pressure data*/ + printf("Macroscopic pressure gradient in x direction: \n"); + (*pression).x = GetReal(); + printf("Macroscopic pressure gradient in y direction: \n"); + (*pression).y = GetReal(); + printf("Macroscopic pressure gradient in z direction: \n"); + (*pression).z = GetReal(); + + + /*output pressure file*/ + printf("output filename for pressure realization: \n"); + filename[2] = GetLine(); + + /*output pressure totale file*/ + printf("output filename for total pressure realization: \n"); + filename[3] = GetLine(); + + /*output x-velocity file*/ + printf("output filename for x-velocity realization: \n"); + filename[4] = GetLine(); + /*output y-velocity file*/ + printf("output filename for y-velocity realization: \n"); + filename[5] = GetLine(); + /*output z-velocity file*/ + printf("output filename for z-velocity realization: \n"); + filename[6] = GetLine(); + + return; +} diff --git a/fftma_module/gen/LIB_IO/inputfiledata.c b/fftma_module/gen/LIB_IO/inputfiledata.c new file mode 100755 index 0000000..404d482 --- /dev/null +++ b/fftma_module/gen/LIB_IO/inputfiledata.c @@ -0,0 +1,71 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + FILE *fp; + int i,j; + + fp=fopen(inputfile,"r"); + if(fp== NULL) + { + printf("Erreur d'ouverture du fichier\n"); + exit(0); + } + *seed=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + filename[0] = ReadLine(fp); + (*variogram).Nvario = atoi(ReadLine(fp)); + + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + (*pression).x = atof(ReadLine(fp)); + (*pression).y = atof(ReadLine(fp)); + (*pression).z = atof(ReadLine(fp)); + filename[2] = ReadLine(fp); + filename[3] = ReadLine(fp); + filename[4] = ReadLine(fp); + filename[5] = ReadLine(fp); + filename[6] = ReadLine(fp); + fclose(fp); + return; +} diff --git a/fftma_module/gen/LIB_IO/pressure.h b/fftma_module/gen/LIB_IO/pressure.h new file mode 100755 index 0000000..826da7e --- /dev/null +++ b/fftma_module/gen/LIB_IO/pressure.h @@ -0,0 +1,21 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _PRESSURE_H +#define _PRESSURE_H + +/*STRUCTURES*/ +/*----------*/ + +/* pressure_mod */ +/* x: macroscopic gradient value in x direction */ +/* y: macroscopic gradient value in x direction */ +/* z: macroscopic gradient value in x direction */ +struct pressure_mod { + double x,y,z; +}; + + +#endif // define _PRESSURE_H diff --git a/fftma_module/gen/LIB_IO/readdata.c b/fftma_module/gen/LIB_IO/readdata.c new file mode 100755 index 0000000..3a70123 --- /dev/null +++ b/fftma_module/gen/LIB_IO/readdata.c @@ -0,0 +1,204 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + *Psolver=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*readfile */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double prout; + + /*read the permeability realization*/ + + + fp = fopen(filename, "r"); + + for (i=0;i<(*realin).n;i++) + { + fread(&prout,sizeof(double),1,fp); + printf("Prout: %15.10f\n",prout); + } + + fclose(fp); + return; +} diff --git a/fftma_module/gen/LIB_IO/testmemory.c b/fftma_module/gen/LIB_IO/testmemory.c new file mode 100755 index 0000000..7cbd10e --- /dev/null +++ b/fftma_module/gen/LIB_IO/testmemory.c @@ -0,0 +1,15 @@ +#include +#include +#include +#include +#include +#include + +void testmemory(double *realint) +{ + if (realint == NULL) { + printf("Testmemory.c: No memory available \n"); + exit; + } + return; +} diff --git a/fftma_module/gen/LIB_IO/testopenfile.c b/fftma_module/gen/LIB_IO/testopenfile.c new file mode 100755 index 0000000..dee13a8 --- /dev/null +++ b/fftma_module/gen/LIB_IO/testopenfile.c @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include + +void testopenfile(FILE *fp) +{ + if (fp == NULL) + { + printf("Erreur d'ouverture de fichier\n"); + exit(0); + } + return; +} diff --git a/fftma_module/gen/LIB_IO/toolsIO.h b/fftma_module/gen/LIB_IO/toolsIO.h new file mode 100755 index 0000000..e6a6eb9 --- /dev/null +++ b/fftma_module/gen/LIB_IO/toolsIO.h @@ -0,0 +1,93 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "pressure.h" + +#ifndef _TOOLSIO_H +#define _TOOLSIO_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* writefile,writefile_bin,readfile_bin,inputdata,inputfiledata,readdata,debuginput */ +/* testmemory, testopenfile */ + + +/*FUNCTIONS*/ +/*----------*/ + +/* Lecture dans un fichier */ + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +/* void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,struct realization_mod *Kfield, char *argv[]); */ + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +/* readfile_bin */ +/* */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin); + + +/* Writefile */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile( string filename, struct realization_mod *realin); + +/* Writefile_bin */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin( string filename, struct realization_mod *realin); + + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ +void debuginput(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite); + +/* Allocation test */ +void testmemory(double *realint); + +/* Test open file */ +void testopenfile(FILE *fp); + +#endif // define _TOOLSIO_H diff --git a/fftma_module/gen/LIB_IO/writefile.c b/fftma_module/gen/LIB_IO/writefile.c new file mode 100755 index 0000000..dbe3dd0 --- /dev/null +++ b/fftma_module/gen/LIB_IO/writefile.c @@ -0,0 +1,32 @@ +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + /* string filename;*/ + /*struct realization_mod *realin;*/ + + + /*save the permeability realization*/ + fp = fopen(filename, "w"); +/* printf("writefile.c : (*realin).vector[0] %f\n",(*realin).vector[0]); */ +/* (*realin).vector[0]=1.1; */ + for (i=0;i<(*realin).n;i++) + fprintf(fp,"%15.10f\n",(*realin).vector[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/LIB_IO/writefile_bin.c b/fftma_module/gen/LIB_IO/writefile_bin.c new file mode 100755 index 0000000..8df2da8 --- /dev/null +++ b/fftma_module/gen/LIB_IO/writefile_bin.c @@ -0,0 +1,33 @@ +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double *prout; + + /*save the permeability realization*/ + fp = fopen(filename, "w"); + + for (i=0;i<(*realin).n;i++) + { + prout=(*realin).vector; + fwrite(&prout[i],sizeof(double),1,fp); + } + + fclose(fp); + return; +} diff --git a/fftma_module/gen/LIB_PY-API/Py_getvalues.c b/fftma_module/gen/LIB_PY-API/Py_getvalues.c new file mode 100755 index 0000000..cef5b17 --- /dev/null +++ b/fftma_module/gen/LIB_PY-API/Py_getvalues.c @@ -0,0 +1,111 @@ +#include +#include +#include +#include +#include +#include +#include +#include "Py_py-api.h" +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +#if PY_MAJOR_VERSION >= 3 + #define PyIntObject PyLongObject + #define PyInt_Type PyLong_Type + #define PyInt_Check(op) PyLong_Check(op) + #define PyInt_CheckExact(op) PyLong_CheckExact(op) + #define PyInt_FromString PyLong_FromString + #define PyInt_FromUnicode PyLong_FromUnicode + #define PyInt_FromLong PyLong_FromLong + #define PyInt_FromSize_t PyLong_FromSize_t + #define PyInt_FromSsize_t PyLong_FromSsize_t + #define PyInt_AsLong PyLong_AsLong + #define PyInt_AS_LONG PyLong_AS_LONG + #define PyInt_AsSsize_t PyLong_AsSsize_t + #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask + #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask + #define PyNumber_Int PyNumber_Long +#endif + +#if PY_MAJOR_VERSION >= 3 + #define PyBoolObject PyLongObject +#endif + +#if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY + #ifndef PyUnicode_InternFromString + #define PyUnicode_InternFromString(s) PyUnicode_FromString(s) + #endif +#endif + + +int Py_getvalues(PyObject* args, long* seed,struct grid_mod* grid,struct vario_mod* variogram,struct statistic_mod* stat) +{ + int i, varioNargs=12, j=0; + PyObject* listvario; + PyObject* vgr; + //char* gwnfilename; + + + stat->nblock_mean=1; + stat->nblock_var=1; + stat->mean=(double*)malloc(stat->nblock_mean * sizeof(double)); + if (stat->mean == NULL) return 0; + stat->variance=(double*)malloc(stat->nblock_var * sizeof(double)); + if (stat->variance == NULL) return 0; + + + if(!PyArg_ParseTuple(args, "iiidddlO!ddi", /*"iiidddslO!ddi",*/ + &(grid->NX), + &(grid->NY), + &(grid->NZ), + &(grid->DX), + &(grid->DY), + &(grid->DZ), + /*gwnfilename,*/ + seed, + &PyList_Type, &listvario, + stat->mean+0, + stat->variance+0, + &(stat->type))) return 0; + + + variogram->Nvario=PyList_Size(listvario); + + variogram->var=(double*)malloc(variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + variogram->vario=(int*)malloc(variogram->Nvario*sizeof(int)); + if(variogram->vario==NULL) return 0; + variogram->alpha=(double*)malloc(variogram->Nvario*sizeof(double)); + if(variogram->alpha==NULL) return 0; + variogram->scf=(double*)malloc(3*variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + variogram->ap=(double*)malloc(9*variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + for(i=0;iNvario;i++) + { + vgr=PyList_GetItem(listvario,i); + if(PyTuple_Size(vgr)!=12) return 0; + (variogram->var)[i]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->vario)[i]=(int)PyInt_AsLong(PyTuple_GetItem(vgr,j++)); + (variogram->alpha)[i]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+0]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+1]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+2]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+0]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+1]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+2]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+3]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+4]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+5]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + } + + + + + + + return 1; +} diff --git a/fftma_module/gen/LIB_PY-API/Py_kgeneration.c b/fftma_module/gen/LIB_PY-API/Py_kgeneration.c new file mode 100755 index 0000000..dc7dbfd --- /dev/null +++ b/fftma_module/gen/LIB_PY-API/Py_kgeneration.c @@ -0,0 +1,60 @@ +#include +#include +#include +#include +#include +#include +#include +#include "Py_py-api.h" +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void Py_kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3]) + { + int i,N; + int typelog; + + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + + + + + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + // if (*gwnwrite == 0) + // { + // writefile(filename[0],Z); + // } + + + + /*FFTMA*/ + FFTMA2(variogram,grid,n,Z,Y); + + /*add the statistics*/ + if (stat.mean[0] != 0 || stat.variance[0]!= 1) + addstat2(Y,stat,Y1,Y); + + /* make a log normal realization */ + if (stat.type==1 || stat.type==2){ + + typelog=stat.type+2; + /* nor2log(Y1,typelog,Y1); */ + nor2log(Y,typelog,Y); + } + + return; + } diff --git a/fftma_module/gen/LIB_PY-API/Py_py-api.h b/fftma_module/gen/LIB_PY-API/Py_py-api.h new file mode 100644 index 0000000..b224b2e --- /dev/null +++ b/fftma_module/gen/LIB_PY-API/Py_py-api.h @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +int Py_getvalues(PyObject*, long*, struct grid_mod*, struct vario_mod*, struct statistic_mod*); +void Py_kgeneration(long,struct grid_mod,struct statistic_mod,struct vario_mod,struct realization_mod*,struct realization_mod*,struct realization_mod*, int [3]); diff --git a/fftma_module/gen/build/lib.linux-x86_64-3.6/FFTMA.cpython-36m-x86_64-linux-gnu.so b/fftma_module/gen/build/lib.linux-x86_64-3.6/FFTMA.cpython-36m-x86_64-linux-gnu.so new file mode 100755 index 0000000..ca87dd8 Binary files /dev/null and b/fftma_module/gen/build/lib.linux-x86_64-3.6/FFTMA.cpython-36m-x86_64-linux-gnu.so differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTPressure.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTPressure.o new file mode 100644 index 0000000..9faad66 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTPressure.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTtest.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTtest.o new file mode 100644 index 0000000..f68ba20 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/FFTtest.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_getvalues.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_getvalues.o new file mode 100644 index 0000000..dfff176 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_getvalues.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_kgeneration.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_kgeneration.o new file mode 100644 index 0000000..c93e2c8 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/Py_kgeneration.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat.o new file mode 100644 index 0000000..96fa97e Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat2.o new file mode 100644 index 0000000..d4a4c68 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/addstat2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/axes.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/axes.o new file mode 100644 index 0000000..5ef814d Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/axes.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_pressure.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_pressure.o new file mode 100644 index 0000000..0967a56 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_pressure.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_real.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_real.o new file mode 100644 index 0000000..20851d6 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_real.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_velocity.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_velocity.o new file mode 100644 index 0000000..18c91b7 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/build_velocity.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cardsin.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cardsin.o new file mode 100644 index 0000000..484c311 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cardsin.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cgrid.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cgrid.o new file mode 100644 index 0000000..5250330 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cgrid.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real.o new file mode 100644 index 0000000..3b77606 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real2.o new file mode 100644 index 0000000..69a6676 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/clean_real2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cov_value.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cov_value.o new file mode 100644 index 0000000..9e6b0ee Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cov_value.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/covariance.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/covariance.o new file mode 100644 index 0000000..bb78913 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/covariance.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cubic.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cubic.o new file mode 100644 index 0000000..a0383b9 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/cubic.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/debuginput.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/debuginput.o new file mode 100644 index 0000000..6d63346 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/debuginput.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/derivReal.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/derivReal.o new file mode 100644 index 0000000..0d063a9 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/derivReal.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/exponential.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/exponential.o new file mode 100644 index 0000000..0aa8aac Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/exponential.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma.o new file mode 100644 index 0000000..3ee7f1a Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma2.o new file mode 100644 index 0000000..85b7ea6 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fftma2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fourt.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fourt.o new file mode 100644 index 0000000..92de492 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/fourt.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gammf.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gammf.o new file mode 100644 index 0000000..3c66eba Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gammf.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gasdev.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gasdev.o new file mode 100644 index 0000000..8d9da11 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gasdev.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gaussian.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gaussian.o new file mode 100644 index 0000000..b0f4bf0 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/gaussian.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/generate.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/generate.o new file mode 100644 index 0000000..548c404 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/generate.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/genlib.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/genlib.o new file mode 100644 index 0000000..eb7331c Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/genlib.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputdata.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputdata.o new file mode 100644 index 0000000..e518067 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputdata.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputfiledata.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputfiledata.o new file mode 100644 index 0000000..cd5e546 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/inputfiledata.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration.o new file mode 100644 index 0000000..ea66405 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration2.o new file mode 100644 index 0000000..7c8b16b Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/kgeneration2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/length.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/length.o new file mode 100644 index 0000000..e77bd97 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/length.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/mat_vec.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/mat_vec.o new file mode 100644 index 0000000..45bbab5 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/mat_vec.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/maxfactor.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/maxfactor.o new file mode 100644 index 0000000..08a19ff Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/maxfactor.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nor2log.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nor2log.o new file mode 100644 index 0000000..c1fe5e0 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nor2log.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nugget.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nugget.o new file mode 100644 index 0000000..1baae46 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/nugget.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration.o new file mode 100644 index 0000000..4cccb8f Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration2.o new file mode 100644 index 0000000..3f42a5e Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/pgeneration2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/power.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/power.o new file mode 100644 index 0000000..c98827d Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/power.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/prebuild_gwn.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/prebuild_gwn.o new file mode 100644 index 0000000..411b45d Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/prebuild_gwn.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/ran2.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/ran2.o new file mode 100644 index 0000000..c76e644 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/ran2.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/random.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/random.o new file mode 100644 index 0000000..ab39b08 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/random.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata.o new file mode 100644 index 0000000..e3c75bb Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata3.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata3.o new file mode 100644 index 0000000..c96c7a0 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readdata3.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readfile_bin.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readfile_bin.o new file mode 100644 index 0000000..7f86c07 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/readfile_bin.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/scanadt.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/scanadt.o new file mode 100644 index 0000000..ca90531 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/scanadt.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/simpio.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/simpio.o new file mode 100644 index 0000000..6bfdd63 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/simpio.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/spherical.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/spherical.o new file mode 100644 index 0000000..c887f71 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/spherical.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stable.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stable.o new file mode 100644 index 0000000..5d686a3 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stable.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stack.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stack.o new file mode 100644 index 0000000..3e01d62 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/stack.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/strlib.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/strlib.o new file mode 100644 index 0000000..385abbd Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/strlib.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/symtab.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/symtab.o new file mode 100644 index 0000000..4ca5131 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/symtab.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/test_fact.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/test_fact.o new file mode 100644 index 0000000..f60755f Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/test_fact.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testmemory.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testmemory.o new file mode 100644 index 0000000..fe534a4 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testmemory.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testopenfile.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testopenfile.o new file mode 100644 index 0000000..33bca26 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/testopenfile.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_pressure.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_pressure.o new file mode 100644 index 0000000..140ce91 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_pressure.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_velocity.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_velocity.o new file mode 100644 index 0000000..476e41c Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/total_velocity.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/waveVectorCompute3D.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/waveVectorCompute3D.o new file mode 100644 index 0000000..156fe64 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/waveVectorCompute3D.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile.o new file mode 100644 index 0000000..9ff738d Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile_bin.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile_bin.o new file mode 100644 index 0000000..cc5b8f4 Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/lib_src/writefile_bin.o differ diff --git a/fftma_module/gen/build/temp.linux-x86_64-3.6/moduleFFTMA.o b/fftma_module/gen/build/temp.linux-x86_64-3.6/moduleFFTMA.o new file mode 100644 index 0000000..92bbe8c Binary files /dev/null and b/fftma_module/gen/build/temp.linux-x86_64-3.6/moduleFFTMA.o differ diff --git a/fftma_module/gen/include/Py_py-api.h b/fftma_module/gen/include/Py_py-api.h new file mode 100644 index 0000000..b224b2e --- /dev/null +++ b/fftma_module/gen/include/Py_py-api.h @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +int Py_getvalues(PyObject*, long*, struct grid_mod*, struct vario_mod*, struct statistic_mod*); +void Py_kgeneration(long,struct grid_mod,struct statistic_mod,struct vario_mod,struct realization_mod*,struct realization_mod*,struct realization_mod*, int [3]); diff --git a/fftma_module/gen/include/autoscan.log b/fftma_module/gen/include/autoscan.log new file mode 100755 index 0000000..e69de29 diff --git a/fftma_module/gen/include/condor.h b/fftma_module/gen/include/condor.h new file mode 100755 index 0000000..22c6696 --- /dev/null +++ b/fftma_module/gen/include/condor.h @@ -0,0 +1,442 @@ +#include "geostat.h" + +#ifndef _CONDOR_H_ +#define _CONDOR_H_ + + + +/*=======================================================*/ +/*FUNCTIONS*/ +/*---------*/ + + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zero mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ +void addstat(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout); + + +/*condit */ +/*conditioning of a Gaussian realization using */ +/*the primal kriging approach */ +/*inversion method = CONJUGATE GRADIENTS */ +/*NB: The realization and the well data are */ +/*reduced to the standard Gaussian N(0,1) */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*realin: structure defining the input realization */ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void condit(int k,struct welldata_mod well,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout); + + +/*d_kriging */ +/*interpolation from ponctual data with simple dual */ +/*kriging. d_kriging is used to interpolate standard */ +/*Gaussian data only */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void d_kriging(int k,struct welldata_mod well,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realout); + + +/*dual_condit */ +/*conditioning of a Gaussian realization using */ +/*the dual kriging approach */ +/*inversion method = CONJUGATE GRADIENTS */ +/*NB: The realization and the well data are */ +/*reduced to the standard Gaussian N(0,1) */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*realin: structure defining the input realization */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void dual_condit(int k,struct welldata_mod well,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout); + + +/*dual_condit_gen */ +/*conditioning of a Gaussian realization using */ +/*the dual kriging approach */ +/*considered cases : Gaussian data */ +/* Uniform data */ +/* Log */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*wellin: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*realin: structure defining the input realization */ +/*stat : structure defining the statistical data */ +/*OUTPUT */ +/*realout: structure defining the output realization */ + +void dual_condit_gen(int k,struct welldata_mod wellin,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat, struct realization_mod *realout); + + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ +void FFTMA(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*PLUS GRADIENT CALCULATIONS - GRADIENTS ARE */ +/*CALCULATED FOR THE GRADUAL DEFORMATION PARAMETERS */ +/* */ +/*INPUT: */ +/*------- */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*DZoverDRHO: gradients calculated durin the gradual */ +/* deformation process */ +/* */ +/*OUTPUT: */ +/*------- */ +/*realout: structure defining a realization - */ +/*DYoverDRHO : structure with the output gradients */ +void FFTMA_gradient(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct gradients_mod *DZoverDRHO,struct realization_mod *realout,struct gradients_mod *DYoverDRHO); + + +/* GENERATION OF A GAUSSIAN WHITE NOISE VECTOR */ +/*input: */ +/* seed: seed */ +/* n: number of components in the vector */ +/*output: */ +/* realization: structure defining the realization*/ +void generate(long *seed, int n, struct realization_mod *realization); + +void ikrig(int option, struct statfacies_mod facies, int kk,struct welldata_mod data, struct variotable_mod variogram,struct grid_mod grid,float *krigout); + + +/*kriging */ +/*interpolation from ponctual data with simple */ +/*kriging. kriging is used to interpolate standard */ +/*Gaussian data only */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void kriging(int k,struct welldata_mod data,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realout); + + +/*CHOLESKY SIMULATION TECHNIQUE - LUSIM */ +/*appropriate for regular grids and small number */ +/*of points */ +/*input: */ +/*variogram: structure defining the variogram model */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ +void LUSIM(struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout); + + +void nor2any(struct cdf_mod *pcumulf,struct realization_mod *realin,struct realization_mod *realout); + +/*TURNS NORMAL NUMBERS INTO LOGNORMAL NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* normal numbers */ +/*typelog: --> 3: lognormal (natural) */ +/* --> 4: lognormal (log10) */ +/*output: */ +/*realout: structure defining a realization - */ +/* lognormal numbers */ +void nor2log(struct realization_mod *realin, int typelog, struct realization_mod *realout); + + +/*TURNS NORMAL NUMBERS INTO UNIFORM NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zero mean and unit variance */ +/*output: */ +/*realout: structure defining a realization - */ +/* uniform numbers */ +void nor2unif(struct realization_mod *realin,struct realization_mod *realout); + + +/*o_kriging */ +/*interpolation from ponctual data with ordinary kriging */ +/*o_kriging is used to interpolate standard Gaussian data*/ +/*only */ +/*INPUT */ +/*k: measurement type or rank */ +/*variogram: structure describing the variogram model */ +/*data: structure with the well data */ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the kriged realization */ +void o_kriging(int k,struct vario_mod variogram,struct welldata_mod data,struct grid_mod grid,struct realization_mod *realout); + + +/*od_kriging */ +/*interpolation from ponctual data with ordinary dual*/ +/*kriging. od_kriging is used to interpolate */ +/*Gaussian data only */ +/*inversion method = CONJUGATE GRADIENTS */ +/*INPUT */ +/*k: measurement type */ +/*well: structure with the well data */ +/*variogram: structure describing the variogram model*/ +/*grid: structure defining the grid */ +/*OUTPUT */ +/*realout: structure defining the output realization */ +void od_kriging(int k,struct welldata_mod well,struct vario_mod variogram,struct grid_mod grid,struct realization_mod *realout); + + +/*PLURIGAUSSIAN METHOD */ +/*Starting from two independent Gaussian realizations Y1*/ +/*and Y2 with zero mean and unit variance, but possibly */ +/*different variogram models, a categorial realization is */ +/*built. */ +/*Truncation is performed on the basis of a mask with the */ +/*x-axis associated to Y1 and the y-axis associated to Y2 */ +/*This truncation may be stationary or non stationary */ +/*The mask consists of lines perpendicular to the Y1 and */ +/*Y2 axes. They define rectangular subregions attributed */ +/*to categories i = [1...ncat] */ +/*INPUT: */ +/*facies: structure defining the facies proportions in the*/ +/* whole reservoir model */ +/*ineq: structure defining the mask for truncation */ +/*Y1: first starting Gaussian realization */ +/*Y2: second starting realization - same length as Y1 */ +/*OUTPUT: */ +/*Y: output realization */ +void plurigau(struct statfacies_mod facies,struct inequalities_mod ineq,struct realization_mod *Y1, struct realization_mod *Y2, struct realization_mod *Y); + + +/*tr_kriging */ +/*kriging with an external drift */ +/*The trend is limited to a 2-term function */ +/*m(u) = a0+a1y(u) where y(u) is a secondary */ +/*external variable (e.g., seismic) */ +/*INPUT: */ +/*k: measurement type or rank */ +/*variogram: structure describing the variogram */ +/* model */ +/*data: structure with the well data */ +/*grid: structure defining the grid */ +/*y: secondary external variable */ +/*OUTPUT: */ +/*realout: kriged realization */ +void tr_kriging(int k, struct vario_mod variogram,struct welldata_mod data,struct grid_mod grid,struct realization_mod *Y,struct realization_mod *realout); + + +/*truncat */ +/*TRUNCATES A STANDARD GAUSSIAN REALIZATION */ +/*WITH THE TRUNCATED GAUSSIAN METHOD */ +/*truncation may be stationary or nonstationary*/ +/*INPUT: */ +/*facies: description of the facies proportions*/ +/*thresholds: may be an input if they have been*/ +/* previously computed */ +/*realin: structure defining a realization - */ +/* must be a standard normal */ +/*OUTPUT: */ +/*realout: structure defining a realization - */ +/*thresholds: Gaussian thresholds corresponding*/ +/* to the facies volume fractions if*/ +void truncat(struct statfacies_mod facies,struct realization_mod *realin,struct realization_mod *realout, struct statfacies_mod *thresholds); + + +/*TURNS UNIFORM NUMBERS INTO NORMAL NUMBERS*/ +/*INPUT: */ +/*realin: structure defining a realization - */ +/* uniform numbers */ +/*OUTPUT: */ +/*realout: structure defining a realization - */ +/* must have zero mean and unit variance */ +void unif2nor(struct realization_mod *realin,struct realization_mod *realout); + + +/*Wany2nor */ +/*converts any kind of continuous data to Gaussian data*/ +/*INPUT: */ +/*k: type of measurement */ +/*wellin: structure with the input well data */ +/*seed: seed */ +/*OUTPUT: */ +/*wellout: structure with the output well data */ +/*pcumulf: structure describing the experimental */ +/* cumulative distribution */ +void Wany2nor(int k, struct welldata_mod wellin, long *seed,struct welldata_mod *wellout, struct cdf_mod *pcumulf); + + +/*Wfac2nor0 */ +/*turns the facies well measurements into Gaussian data */ +/*intervals only are respected - spatial variability is */ +/*disregarded */ +/*USES vf2thres, deflimit,trungasdev */ +/*This step is required before performing kriging */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2nor0(int k,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout); + + +/*Wfac2nor1 */ +/*turns the facies well measurements into Gaussian data */ +/*Proceeds in 2 steps */ +/* 1- builds a realization Y = LZ (variability ensured) */ +/* 2- proposes successively local changes for Z to */ +/* respect the intervals-Metropoils-Hastings approach */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*variogram: structure defining the variogram model */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2nor1(int k,struct vario_mod variogram,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout); + + +/*Wfac2norPG0 */ +/*turns the facies well measurements into Gaussian data */ +/*intervals only are respected - spatial variability is */ +/*disregarded */ +/*method developed for pluriGaussian realizations */ +/*stationary and nonstationary truncation */ +/*This step is required before performing kriging */ +/*INPUT: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*idreal: identification of the starting realization */ +/* = 1 for realization 1 */ +/* = 2 for realization 2 */ +/*ineq: structure defining the mask for truncation */ +/*OUTPUT: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wfac2norPG0(int k,struct inequalities_mod ineq,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,int idreal,struct welldata_mod *wellout); + + +/*Wfac2norPG1 */ +/*turns the facies well measurements into Gaussian data */ +/*Proceeds in 2 steps */ +/* 1- builds a realization Y = LZ (variability ensured) */ +/* 2- proposes successively local changes for Z to */ +/* respect the intervals-Metropoils-Hastings approach */ +/*method developed for pluriGaussian realizations */ +/*STATIONARY TRUNCATION */ +/*INPUT: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 5 --> facies */ +/*grid: structure defining the grid */ +/*facies: structure defining the facies proportions */ +/*seed: seed */ +/*ineq: structure describing the truncation mask */ +/*variogram1: structure describing the variogram model */ +/* for realization Y1 */ +/*variogram2: structure describing the variogram model */ +/* for realization Y2 */ +/*ineq: structure defining the mask for truncation */ +/*OUTPUT: */ +/*wellout1: structure with converted well data for */ +/*realization 1 - the kth vector */ +/*wellout2: structure with converted well data for */ +/*realization 2 - the kth vector */ +void Wfac2norPG1(int k,struct inequalities_mod ineq,struct vario_mod variogram1,struct vario_mod variogram2,struct grid_mod grid,struct welldata_mod wellin,struct statfacies_mod facies,long *seed,struct welldata_mod *wellout1,struct welldata_mod *wellout2); + + +/*Wlog2nor */ +/*turns the log well measurements into std Gaussian data*/ +/*This step is required before performing kriging */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/* code = 3 --> natural log */ +/* code = 4 --> logarithm 10 */ +/*grid: structure defining the grid */ +/*stat: structure defining the statistics */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wlog2nor(int k, struct welldata_mod wellin,struct grid_mod grid,struct statistic_mod stat,struct welldata_mod *wellout); + + +/*Wnor2nor */ +/*converts Well Normal numbers to the standard Gaussian */ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/*grid: structure defining the grid */ +/*stat: structure defining the statistics */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wnor2nor(int k, struct welldata_mod wellin,struct grid_mod grid,struct statistic_mod stat,struct welldata_mod *wellout); + + +/*Wunif2nor */ +/*converts Well uniform numbers to the standard Gaussian*/ +/*input: */ +/*k: type measurement, may be 1,2,3 ... or ntype */ +/*wellin: structure defining well data */ +/*output: */ +/*wellout: structure defining well data - the kth vector*/ +/*of measures are converted to standard normal data */ +void Wunif2nor(int k, struct welldata_mod wellin,struct welldata_mod *wellout); + + + +#endif // define _CONDOR_H_ diff --git a/fftma_module/gen/include/configure.scan b/fftma_module/gen/include/configure.scan new file mode 100755 index 0000000..7c520e7 --- /dev/null +++ b/fftma_module/gen/include/configure.scan @@ -0,0 +1,23 @@ +# -*- Autoconf -*- +# Process this file with autoconf to produce a configure script. + +AC_PREREQ(2.59) +AC_INIT(FULL-PACKAGE-NAME, VERSION, BUG-REPORT-ADDRESS) +AC_CONFIG_SRCDIR([condor.h]) +AC_CONFIG_HEADER([config.h]) + +# Checks for programs. +AC_PROG_CC + +# Checks for libraries. + +# Checks for header files. +AC_HEADER_STDC +AC_CHECK_HEADERS([stddef.h stdlib.h string.h]) + +# Checks for typedefs, structures, and compiler characteristics. +AC_HEADER_STDBOOL +AC_TYPE_SIZE_T + +# Checks for library functions. +AC_OUTPUT diff --git a/fftma_module/gen/include/genlib.h b/fftma_module/gen/include/genlib.h new file mode 100755 index 0000000..4298ca7 --- /dev/null +++ b/fftma_module/gen/include/genlib.h @@ -0,0 +1,163 @@ +/* + * File: genlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file contains several definitions that form the + * core of a general-purpose ANSI C library developed by Eric + * Roberts. The goal of this library is to provide a basic + * set of tools and conventions that increase the readability + * of C programs, particularly as they are used in a teaching + * environment. + * + * The basic definitions provided by genlib.h are: + * + * 1. Declarations for several new "primitive" types + * (most importantly bool and string) that are + * used throughout the other libraries and + * applications as fundamental types. + * + * 2. A new set of functions for memory allocation. + * + * 3. A function for error handling. + */ + +#ifndef _genlib_h +#define _genlib_h + +#include +#include +#include + +/* Section 1 -- Define new "primitive" types */ + +/* + * Type: bool + * ---------- + * This type has two values, FALSE and TRUE, which are equal to 0 + * and 1, respectively. Most of the advantage of defining this type + * comes from readability because it allows the programmer to + * provide documentation that a variable will take on only one of + * these two values. Designing a portable representation, however, + * is surprisingly hard, because many libraries and some compilers + * define these names. The definitions are usually compatible but + * may still be flagged as errors. + */ + +#ifdef THINK_C + typedef int bool; +#else +# ifdef TRUE +# ifndef bool +# define bool int +# endif +# else +# ifdef bool +# define FALSE 0 +# define TRUE 1 +# else +// typedef enum {FALSE, TRUE} bool; +# endif +# endif +#endif + +/* + * Type: string + * ------------ + * The type string is identical to the type char *, which is + * traditionally used in C programs. The main point of defining a + * new type is to improve program readability. At the abstraction + * levels at which the type string is used, it is usually not + * important to take the string apart into its component characters. + * Declaring it as a string emphasizes this atomicity. + */ + +typedef char *string; + +/* + * Constant: UNDEFINED + * ------------------- + * Besides NULL, the only other constant of pointer type is + * UNDEFINED, which is used in certain packages as a special + * sentinel to indicate an undefined pointer value. In many + * such contexts, NULL is a legitimate data value and is + * therefore inappropriate as a sentinel. + */ + +#define UNDEFINED ((void *) undefined_object) + +extern char undefined_object[]; + +/* Section 2 -- Memory allocation */ + +/* + * General notes: + * -------------- + * These functions provide a common interface for memory + * allocation. All functions in the library that allocate + * memory do so using GetBlock and FreeBlock. Even though + * the ANSI standard defines malloc and free for the same + * purpose, using GetBlock and FreeBlock provides greater + * compatibility with non-ANSI implementations, automatic + * out-of-memory error detection, and the possibility of + * substituting a garbage-collecting allocator. + */ + +/* + * Function: GetBlock + * Usage: ptr = (type) GetBlock(nbytes); + * ------------------------------------- + * GetBlock allocates a block of memory of the given size. If + * no memory is available, GetBlock generates an error. + */ + +void *GetBlock(size_t nbytes); + +/* + * Function: FreeBlock + * Usage: FreeBlock(ptr); + * ---------------------- + * FreeBlock frees the memory associated with ptr, which must + * have been allocated using GetBlock, New, or NewArray. + */ + +void FreeBlock(void *ptr); + +/* + * Macro: New + * Usage: p = New(pointer-type); + * ----------------------------- + * The New pseudofunction allocates enough space to hold an + * object of the type to which pointer-type points and returns + * a pointer to the newly allocated pointer. Note that + * "New" is different from the "new" operator used in C++; + * the former takes a pointer type and the latter takes the + * target type. + */ + +#define New(type) ((type) GetBlock(sizeof *((type) NULL))) + +/* + * Macro: NewArray + * Usage: p = NewArray(n, element-type); + * ------------------------------------- + * NewArray allocates enough space to hold an array of n + * values of the specified element type. + */ + +#define NewArray(n, type) ((type *) GetBlock((n) * sizeof(type))) + +/* Section 3 -- Basic error handling */ + +/* + * Function: Error + * Usage: Error(msg, ...) + * ---------------------- + * Error generates an error string, expanding % constructions + * appearing in the error message string just as printf does. + * After printing the error message, the program terminates. + */ + +void Error(string msg, ...); + +#endif diff --git a/fftma_module/gen/include/geostat.h b/fftma_module/gen/include/geostat.h new file mode 100755 index 0000000..5d48919 --- /dev/null +++ b/fftma_module/gen/include/geostat.h @@ -0,0 +1,690 @@ +#include +#include +#include +#include + + +#ifndef _GEOSTAT_H +#define _GEOSTAT_H + +#define NTAB 32 + +/* Modified january, the 22th 2004 */ +/* from float to double */ + +/* List of structures: */ +/* ------------------- */ + +/* vario_mod */ +/* variotable_mod*/ +/* grid_mod */ +/* welldata_mod */ +/* statfacies_mod */ +/* inequalities_mod */ +/* statistic_mod */ +/* grad_mod */ +/* gradients_mod */ +/* cdf_mod */ +/* realization_mod */ + + +/* List of functions: */ +/* ------------------ */ + +/* axes, cardsin, choldc, coordinates */ +/* covariance, cov_matrix, cov_value, */ +/* cubic, cutspectr, deflimit, dual_kri */ +/* exponential, fourt, funtrun1, G, gammf */ +/* gammln, gammp, gasdev, gaussian, gcf, */ +/* gen_cov_matrix, Ginv, gradual, cgrid, */ +/* gser, invtrun1, krig_stat, length, */ +/* LtimeZ, mat_vec, maxfactor, metrop, norm */ +/* normal, nugget, power, ran2, scal_vect, */ +/* solve3, sort, spherical, stable, statlog2nor */ +/* test_fract, trun1, trungasdev,vec_vec, */ +/* vf2gthres,polint */ + + + + +/*STRUCTURES*/ +/*----------*/ +/*variogram */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct vario_mod { + int Nvario; + int *vario; + double *alpha; + double *ap; + double *scf; + double *var; +}; + + + +/*variogram table */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct variotable_mod { + int number_of_variograms; + int *Nvario; + int *vario; + float *alpha; + float *ap; + float *scf; + float *var; +}; + + + + + + +/*grid */ +/*NX: number of gridblocks along the X axis*/ +/*NY: number of gridblocks along the Y axis*/ +/*NZ: number of gridblocks along the Z axis*/ +/*DX: gridblock length along the X axis */ +/*DY: gridblock length along the Y axis */ +/*DZ: gridblock length along the Z axis */ +/*Xo: X-cell number of the origin cell */ +/*Yo: Y-cell number of the origin cell */ +/*Zo: Z-cell number of the origin cell */ +struct grid_mod { + int NX, NY, NZ; + double DX,DY,DZ; + double Xo,Yo,Zo; +}; + + +/*well data */ +/*nwell: number of wells */ +/*n: number of measurement points per well */ +/* i = [0...nwell-1] */ +/*ntype: number of measurement types */ +/*code: status of the measurements i=[0...ntype-1] */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: uniform */ +/* --> 7: any */ +/*x: X-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*y: Y-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*z: Z-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*measure: values of the measurements */ +/* same kind of indexation, but repeated per type of */ +/* measurement */ +/* type 1 : */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/* type 2 : */ +/* i=[sum(n[k])... sum(n[k])+n[0]-1 ... 2*(sum(n[k])-1)]*/ +struct welldata_mod { + int nwell; + int *n; + int ntype; + int *code; + float *x; + float *y; + float *z; + float *measure; +}; + + + +/*volume fractions for facies */ +/*ncat: number of facies */ +/*nblock: number of gridblocks with different */ +/* volume fractions */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*vf: volume fractions for the first ncat-1 facies*/ +/* i = [0...ncat-2]*nblock */ +struct statfacies_mod { + int ncat; + int nblock; + float *vf; +}; + + +/*inequalities for truncated plurigaussian realizations*/ +/*only two basic realizations Y1 and Y2 are considered */ +/*Y1 and Y2 are independent */ +/*nsY1: number of unknown thresholds for Y1 */ +/*nsY2: number of unknown thresholds for Y2 */ +/*thresholds: vector with the thresholds and -10 and 10*/ +/* the output values are the Gaussian */ +/* thresholds */ +/* i = [0 ... n+1], n = nsY1+nsY2 */ +/* thresholds[n] = -10,thresholds[n+1] = 10 */ +/* given at the beginning */ +/*address_sY1: successive upper and lower bounds for */ +/* the different facies for Y1 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY1 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +/*address_sY2: successive upper and lower bounds for */ +/* the different facies for Y2 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY2 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +struct inequalities_mod { + int nsY1; + int nsY2; + float *thresholds; + int *address_sY1; + int *address_sY2; +}; + + +/*statistical data */ +/*type --> 0 : normal */ +/* --> 1 : natural log */ +/* --> 2 : log 10 */ +/*nblock_mean: number of gridblocks with different */ +/* means */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*mean: mean of the variable i = [0...nblock_mean] */ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, MEAN IS LOG MEAN ! */ +/*nblock_var: number of gridblocks with different */ +/* variances */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*variance: variance of the variable i = [0...nblock_var]*/ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, VAR IS LOG VAR ! */ +struct statistic_mod { + int type; + int nblock_mean; + double *mean; + int nblock_var; + double *variance; +}; + + +/*gradual deformation parameters */ +/*Nadded: number of complementary realizations */ +/*NZONES: number of subregions */ +/*rho: gradual deformation parameters */ +/*rho[NZONES*(0...Nadded)] */ +/*cellini[NZONES*(0...2)] lower cell bound for */ +/*for subregions along axes X,Y,Z */ +/*cellfin[NZONES*(0...2)] upper cell bound for */ +/*for subregions along axes X,Y,Z */ +struct grad_mod { + int Nadded, NZONES; + float *rho; + int *cellini, *cellfin; +}; + + +/*gradient structures */ +/*Nparam : number of parameters for which gradients are */ +/* required */ +/*Ncells : number of cells for which gradients are */ +/* calculated */ +/*grad : vector with the calculated gradients */ +/* dimension = Nparam*Ncells */ +/* this vector is organized as */ +/* 0 1...Ncells-1 for the first parameter followed*/ +/* Ncells....2*Ncells-1 for the second parameter */ +/* and so on */ +struct gradients_mod { + int Nparam,Ncells; + float *grad; +}; + + + +/*description of discretized cumulative distributions */ +/*n: number of points */ +/*x: values along the x axis i = [0...n-1] */ +/*fx: corresponding values for the cumulative */ +/* distribution i = [0...n-1] */ +struct cdf_mod { + int n; + float *x; + float *fx; +}; + + +/*realization */ +/*n: number of components */ +/*code: status of the realization */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: conditional standard Normal */ +/* --> 7: conditional non standard Normal */ +/* --> 8: conditional lognormal (neperien) */ +/* --> 9: conditional lognormal (log10) */ +/* --> 10: conditional facies */ +/* --> 11: uniform numbers */ +/* --> 12: conditional uniform numbers */ +/* --> 13: unconditional any type */ +/* --> 14: conditional any type */ +/*vector: realization vector i = [0...n-1] */ +struct realization_mod { + int n; + int code; + double *vector; +}; + +/*=====================================================*/ + +/*FUNCTIONS*/ +/*---------*/ + + +/*normalization of the anostropy axes */ +/*ap: anisotropy axes */ +/*scf: correlation lengths */ +/* The returned normalized axes are in ap */ +void axes(double *ap, double *scf, int N); + + +/*cardsin covariance value for lag h*/ +double cardsin(double h); + + +/*Cholesky decomposition of matrix C */ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, 0 <= i <= n */ +/* n : dimension of matrix Cij */ +/* */ +/* C is turned into the lower triangular cholesky matrix*/ +void choldc(double *C, int n); + + +/*computes the coordinates of a given cell */ +/*as numbers of cells along the X,Y and Z axes*/ +/*maille = i[0]+1+i[1]*NX+i[2]*NX*NY */ +/*input: */ +/*maille: number of the cell to identify */ +/*grid: structure defining the grid */ +/*output: */ +/*i: vector with the coordinates */ +void coordinates(int maille, int i[3],struct grid_mod grid); + + +/*builds the sampled covariance function */ +/*dimensions are even */ +/*covar: covariance array, vector of size*/ +/*1+NX*NY*NZ, covar[0] is a dead cell */ +/*variogram: structure defined above */ +/*grid: structure defined above */ +/*n: number of gridblocks along X,Y and Z*/ +void covariance(double *covar,struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*computation of the covariance matrix for the well data*/ +/*well coordinates are given as a number of cells */ +/*The dimension of C is given by well.nwell */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +/*grid: structure defined above */ +void cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, struct grid_mod grid); + + +/*calculation of the covariance value for a distance h */ +/*defined by i,j,k */ +/*available variogram model: */ +/* 1 -> exponential */ +/* 2 -> gaussian */ +/* 3 -> spherical */ +/* 4 -> cardsin */ +/* 5 -> stable */ +/* 6 -> gamma */ +/* 7 -> cubic */ +/* 8 -> nugget */ +/* 9 -> power */ +/*variogram: variogram with the structure defined above*/ +/*di: distance along the X axis */ +/*dj: distance along the Y axis */ +/*dk: distance along the Z axis */ +/* The returned value is the computed covariance value */ +double cov_value(struct vario_mod variogram,double di,double dj,double dk); + +/*cubic covariance value for lag h*/ +double cubic(double h); + + +/*truncation of the power spectrum to remove */ +/*high frequencies - isotropic case */ +/*covar: power spectrum */ +/*kx: number of cells to save along the x-axis */ +/*ky: number of cells to save along the y-axis */ +/*kz: number of cells to save along the z-axis */ +/*n[3]: number of cells along the X, Y and Z axes*/ +void cutspectr(float *covar, int kx, int ky, int kz, int n[3]); + + +/*defines the threshold interval for a facies x*/ +/*lim_inf: lower bound */ +/*lim_sup: upper bound */ +/*x: facies */ +/*thresholds: Gaussian threshold vector */ +/*facies: structure defined above */ +/*nblock: gridcell number of point x */ +void deflimit(double *plim_inf, double *plim_sup, float x, float *thresholds, struct statfacies_mod facies,int nblock); + + +/*kriges the realization considering weights */ +/*realin: input realization */ +/*variogram: structure defining the variogram */ +/*k: type of measure */ +/*well: structure defining the well data */ +/*grid: structure defined above */ +/*D: weight vector of length Ndata, Di, i = 0...Ndata-1*/ +/*The kriged realization is stored in realout */ +void dual_kri(struct realization_mod *realin, struct vario_mod variogram,struct welldata_mod well, struct grid_mod grid, double *D,struct realization_mod *realout); + + + +/*exponential covariance value for lag h*/ +double exponential(double h); + + +/*Fast Fourier Transform - Cooley-Tukey algorithm */ +/*datar: real part vector - to be transformed */ +/*datai: imaginary part vector - to be transformed */ +/*nn: number of gridblocks along the X,Y and Z axes */ +/*ndim: number of dimensions */ +/*ifrwd: non-zero for forward transform, 0 for inverse*/ +/*icplx: non-zero for complex data, 0 for real */ +/*workr: utility real part vector for storage */ +/*worki: utility imaginary part vector for storage */ +/*The transformed data are returned in datar and datai*/ +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx,double *workr,double *worki); + + +/*calculates F(x) = (1/a)*exp(-x*x/2)*/ +double funtrun1(double x); + + +/*cumulative standard normal value*/ +float G(float x); + + +/*gamma covariance value for lag h and exponent alpha*/ +double gammf(double h, double alpha); + + +/*returns the value ln(G(x))*/ +float gammln(float xx); + + +/*incomplete gamma fnction*/ +float gammp(float a, float x); + + +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran1(idum) as the source */ +/*of uniform deviates */ +/*idum: seed */ +double gasdev(long *idum, long *idum2, long *iy, long *iv, int *iset); + +/*gaussian covariance value for lag h*/ +double gaussian(double h); + + +/*incomplete gamma function evaluated by its continued */ +/*fraction represented as gammcf, also returns ln(G(a))*/ +/*as gln */ +void gcf(float *gammcf, float a, float x, float *gln); + + +/*computation of the covariance matrix for the well data*/ +/*well coordinates have no specific unit */ +/*The dimension of C is given by n */ +/*C defines the correlation between the first n wells */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +void gen_cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, int n); + + +/*Ginv */ +/*Computes the inverse of the standard normal cumulative*/ +/*distribution function with a numerical approximation */ +/*from Statistical Computing,by W.J. Kennedy, Jr. and */ +/*James E. Gentle, 1980, p. 95. */ +/*input : */ +/*p: cumulative probability value */ +float Ginv(float p); + + +/*gradual combination of 1 realization + Nadded */ +/*complementary realizations */ +/*rho: gradual deformation parameters */ +/*rho[0...NZONES*Nadded-1] */ +/*rangement des vecteurs colonnes les uns apres */ +/*les autres */ +/*Zo: starting realization */ +/*Zo[0...n] */ +/*Z: complementary realizations all stored */ +/*Z[0...n-1 n...2n-1 ...(Nadded-1)n...Nadded.n-1]*/ +/*sequentially in a single vector */ +/*Nadded: number of complementary realizations */ +/*n: number of components per realization */ +/*NZONES: number of subregions */ +/*grid: grid definition */ +void gradual(struct grad_mod grad,float *Zo,float *Z,float *Zfinal,int n,struct grid_mod grid); + + +/*computes the size of the underlying grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*incomplete gamma function evaluated by its series*/ +/*representation as gamser, also returns ln(G(a)) */ +/*as gln */ +void gser(float *gamser, float a, float x, float *gln); + + +/*calculates x so that x = invF(u) */ +/*F is the cumulative density function for the */ +/*function approximating the Gaussian function */ +/*u: uniform deviate between 0 and 1 */ +/*lim_inf: lower bound of the considered interval*/ +/*lim_sup: upper bound of the considered interval*/ +/*C: normalizing constant */ +double invtrun1(double u, double lim_inf, double lim_sup, double C); + + +/*computes the kriging mean and variance*/ +/*for the vector bi, i = [0...n-1] */ +void krig_stat(float *b, int n, struct vario_mod variogram, struct welldata_mod well, float *mean, float *var); + + +/* computes the number of gridblocks for one dimension*/ +/*N: initial number of gridblocks */ +/*i: considered direction */ +/*scf: correlation length */ +/*ap: normalized anisotropy axes */ +int length(int N, int i, double *scf, double *ap, double D, int Nvari); + +/*calculates L.Z/ +/* L : lower triangular matrix recorded */ +/* (per raws) as a vector with only components */ +/* Lij so that j <= i, i = [0...n-1] */ +/* Z : vector, Zi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Lij */ +/* */ +/* The solution vector is returned in b */ +void LtimeZ(double *L, float *Z, float *b, int n); + + +/*calculates C.x/ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* x : vector, xi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Cij */ +/* */ +/* The result vector is returned in b */ +void mat_vec(double *C, double *x, double *b, int n); + + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n); + +/*metrop returns a boolean varible that issues a */ +/*verdict on whether to accept a reconfiguration */ +/*defined by the probability ratio "ratio". */ +/*If ratio >= 1, metrop = 1(true), while if ratio < 1, */ +/*metrop is only true with probability "ratio" */ +int metrop(double ratio,long *idum,long *idum2, long *iy, long *iv); + + +/*2-norm of vector b */ +/* b : vector */ +/* n : length of b, bi, i = [0...n-1]*/ +/*returns the norm of b */ +double norm(double *b,int n); + + +/*value of g(x) where g is the normal function*/ +double normal(double x); + + +/*nugget covariance value for lag h*/ +double nugget(double h); + + +/*power covariance value for lag h and exponent alpha*/ +double power(double h,double alpha); + + +/*generates uniform deviates between 0 and 1*/ +/*idum: seed */ +double ran2(long *idum, long *idum2, long *iy, long *iv); + + + +/*calculates bt.b */ +/* b : vector, bi, i = [0...n-1] */ +/* n : length of b */ +/*returns the scalar product of b*/ +double scal_vec(double *b,int n); + + +/*solves the set of n linear equations Cx = D */ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* D : right-hand side vector, Di avec i = [0...n-1]*/ +/* n : dimension of matrix Cij */ +/* */ +/* The solution vector is returned in D */ +/* CONJUGATE GRADIENT method */ +void solve3(double *C, double *D, int n); + + +/*sorts an array [0...n-1] into ascending order using */ +/*shell */ +void sort(float n, float *arr); + + +/*spherical covariance value for lag h*/ +double spherical(double h); + + +/*stable covariance value for lag h and exponent alpha*/ +double stable(double h, double alpha); + + +/*conversion of log mean and variance to nor*/ +void statlog2nor(struct statistic_mod *pstat); + + +/*tries factor */ +/*pnum: number to be decomposed */ +/*fact: suggested factor */ +/*pmaxfac: memory to keep the greatest factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac); + + +/*calculates the integrale of an approximate function*/ +/*for the Gaussian function over an interval defined */ +/*by lim_inf and lim_sup */ +/*lim_inf: lower bound of the considered interval */ +/*lim_sup: upper bound of the considered interval */ +double trun1(double lim_inf, double lim_sup); + + +/*draws a truncated gaussian variable between lim_inf*/ +/*and lim_sup */ +/*idum: seed */ +double trungasdev(long *idum,double lim_inf,double lim_sup,long *idum2, long *iy, long iv[NTAB]); + +/* tb1.b2 */ +/* b1 : vector */ +/* b2 : vector */ +/* n : length of b1 and b2, bi, i = [0...n-1]*/ +/*returns the norm the product tb1.b2 */ +double vec_vec(double *b1, double *b2,int n); + + +/*turns the volume fractions into Gaussian thresholds */ +/*facies: structure defined above */ +/*thresholds: output threshold vector fot i = [0...n-1]*/ +/*where n is the number of facies-1 */ +/*USES normal*/ +void vf2gthres(struct statfacies_mod facies,float *thresholds); + +void polint(float xa[],float ya[],int n,float x, float *y,float *dy); + + + +#endif diff --git a/fftma_module/gen/include/pressure.h b/fftma_module/gen/include/pressure.h new file mode 100755 index 0000000..826da7e --- /dev/null +++ b/fftma_module/gen/include/pressure.h @@ -0,0 +1,21 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _PRESSURE_H +#define _PRESSURE_H + +/*STRUCTURES*/ +/*----------*/ + +/* pressure_mod */ +/* x: macroscopic gradient value in x direction */ +/* y: macroscopic gradient value in x direction */ +/* z: macroscopic gradient value in x direction */ +struct pressure_mod { + double x,y,z; +}; + + +#endif // define _PRESSURE_H diff --git a/fftma_module/gen/include/random.h b/fftma_module/gen/include/random.h new file mode 100755 index 0000000..881af5f --- /dev/null +++ b/fftma_module/gen/include/random.h @@ -0,0 +1,73 @@ +/* + * File: random.h + * Version: 1.0 + * Last modified on Fri Jul 22 16:44:36 1994 by eroberts + * ----------------------------------------------------- + * This interface provides several functions for generating + * pseudo-random numbers. + */ + +#ifndef _random_h +#define _random_h + +#include "genlib.h" +#include + +/* + * Constant: RAND_MAX + * ------------------ + * Unfortunately, several libraries that supposedly conform to + * the ANSI standard do not define RAND_MAX in . To + * reduce portability problems, this interface defines RAND_MAX + * to be the largest positive integer if it is undefined. + */ + +#ifndef RAND_MAX +# define RAND_MAX ((int) ((unsigned) ~0 >> 1)) +#endif + +/* + * Function: Randomize + * Usage: Randomize(); + * ------------------- + * This function sets the random seed so that the random sequence + * is unpredictable. During the debugging phase, it is best not + * to call this function, so that program behavior is repeatable. + */ + +void Randomize(void); + +/* + * Function: RandomInteger + * Usage: n = RandomInteger(low, high); + * ------------------------------------ + * This function returns a random integer in the range low to high, + * inclusive. + */ + +int RandomInteger(int low, int high); + +/* + * Function: RandomReal + * Usage: d = RandomReal(low, high); + * --------------------------------- + * This function returns a random real number in the half-open + * interval [low .. high), meaning that the result is always + * greater than or equal to low but strictly less than high. + */ + +double RandomReal(double low, double high); + +/* + * Function: RandomChance + * Usage: if (RandomChance(p)) . . . + * --------------------------------- + * The RandomChance function returns TRUE with the probability + * indicated by p, which should be a floating-point number between + * 0 (meaning never) and 1 (meaning always). For example, calling + * RandomChance(.30) returns TRUE 30 percent of the time. + */ + +bool RandomChance(double p); + +#endif diff --git a/fftma_module/gen/include/scanadt.h b/fftma_module/gen/include/scanadt.h new file mode 100755 index 0000000..1da09c3 --- /dev/null +++ b/fftma_module/gen/include/scanadt.h @@ -0,0 +1,159 @@ +/* + * File: scanadt.h + * --------------- + * This file is the interface to a module that exports an abstract + * data type to facilitate dividing a string into logical units + * called "tokens," which are either + * + * 1. Strings of consecutive letters and digits representing words + * 2. One-character strings representing punctuation or separators + * + * To use this package, you must first create an instance of a + * scannerADT by calling + * + * scanner = NewScanner(); + * + * All other calls to the scanner package take this variable as their + * first argument to identify a particular instance of the abstract + * scanner type. + * + * You initialize the scanner to hold a particular string by calling + * + * SetScannerString(scanner, str); + * + * where str is the string from which tokens should be read. To + * retrieve each individual token, you make the following call: + * + * token = ReadToken(scanner); + * + * To determine whether any tokens remain to be read, you can call + * the predicate function MoreTokensExist(scanner). The ReadToken + * function returns the empty string after the last token is read. + * + * The following code fragment serves as an idiom for processing + * each token in the string inputString: + * + * scanner = NewScanner(); + * SetScannerString(scanner, inputString); + * while (MoreTokensExist(scanner)) { + * token = ReadToken(scanner); + * . . . process the token . . . + * } + * + * This version of scanadt.h also supports the following extensions, + * which are documented later in the interface: + * + * SaveToken + * SetScannerSpaceOption + */ + +#ifndef _scanadt_h +#define _scanadt_h + +#include "genlib.h" + +/* + * Type: scannerADT + * ---------------- + * This type is the abstract type used to represent a single instance + * of a scanner. As with any abstract type, the details of the + * internal representation are hidden from the client. + */ + +typedef struct scannerCDT *scannerADT; + +/* + * Function: NewScanner + * Usage: scanner = NewScanner(); + * ------------------------------ + * This function creates a new scanner instance. All other functions + * in this interface take this scanner value as their first argument + * so that they can identify what particular instance of the scanner + * is in use. This design makes it possible for clients to have more + * than one scanner process active at the same time. + */ + +scannerADT NewScanner(void); + +/* + * Function: FreeScanner + * Usage: FreeScanner(scanner); + * ---------------------------- + * This function frees the storage associated with scanner. + */ + +void FreeScanner(scannerADT scanner); + +/* + * Function: SetScannerString + * Usage: SetScannerString(scanner, str); + * -------------------------------------- + * This function initializes the scanner so that it will start + * extracting tokens from the string str. + */ + +void SetScannerString(scannerADT scanner, string str); + +/* + * Function: ReadToken + * Usage: token = ReadToken(scanner); + * ---------------------------------- + * This function returns the next token from scanner. If + * ReadToken is called when no tokens are available, it returns + * the empty string. The token returned by ReadToken is always + * allocated in the heap, which means that clients can call + * FreeBlock when the token is no longer needed. + */ + +string ReadToken(scannerADT scanner); + +/* + * Function: MoreTokensExist + * Usage: if (MoreTokensExist(scanner)) . . . + * ------------------------------------------ + * This function returns TRUE as long as there are additional + * tokens for the scanner to read. + */ + +bool MoreTokensExist(scannerADT scanner); + +/* + * Function: SaveToken + * Usage: SaveToken(scanner, token); + * --------------------------------- + * This function stores the token in the scanner data structure + * in such a way that the next time ReadToken is called, it will + * return that token without reading any additional characters + * from the input. + */ + +void SaveToken(scannerADT scanner, string token); + +/* + * Functions: SetScannerSpaceOption, GetScannerSpaceOption + * Usage: SetScannerSpaceOption(scanner, option); + * option = GetScannerSpaceOption(scanner); + * ----------------------------------------------- + * The SetScannerSpaceOption function controls whether the scanner + * ignores whitespace characters or treats them as valid tokens. + * By default, the ReadToken function treats whitespace characters, + * such as spaces and tabs, just like any other punctuation mark. + * If, however, you call + * + * SetScannerSpaceOption(scanner, IgnoreSpaces); + * + * the scanner will skip over any white space before reading a token. + * You can restore the original behavior by calling + * + * SetScannerSpaceOption(scanner, PreserveSpaces); + * + * The GetScannerSpaceOption function returns the current setting + * of this option. + */ + +typedef enum { PreserveSpaces, IgnoreSpaces } spaceOptionT; + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option); +spaceOptionT GetScannerSpaceOption(scannerADT scanner); + +#endif diff --git a/fftma_module/gen/include/simpio.h b/fftma_module/gen/include/simpio.h new file mode 100755 index 0000000..ca1efc9 --- /dev/null +++ b/fftma_module/gen/include/simpio.h @@ -0,0 +1,75 @@ +/* + * File: simpio.h + * Version: 1.0 + * Last modified on Wed Apr 27 07:29:13 1994 by eroberts + * ----------------------------------------------------- + * This interface provides access to a simple package of + * functions that simplify the reading of input data. + */ + +#ifndef _simpio_h +#define _simpio_h + +#include "genlib.h" + +/* + * Function: GetInteger + * Usage: i = GetInteger(); + * ------------------------ + * GetInteger reads a line of text from standard input and scans + * it as an integer. The integer value is returned. If an + * integer cannot be scanned or if more characters follow the + * number, the user is given a chance to retry. + */ + +int GetInteger(void); + +/* + * Function: GetLong + * Usage: l = GetLong(); + * --------------------- + * GetLong reads a line of text from standard input and scans + * it as a long integer. The value is returned as a long. + * If an integer cannot be scanned or if more characters follow + * the number, the user is given a chance to retry. + */ + +long GetLong(void); + +/* + * Function: GetReal + * Usage: x = GetReal(); + * --------------------- + * GetReal reads a line of text from standard input and scans + * it as a double. If the number cannot be scanned or if extra + * characters follow after the number ends, the user is given + * a chance to reenter the value. + */ + +double GetReal(void); + +/* + * Function: GetLine + * Usage: s = GetLine(); + * --------------------- + * GetLine reads a line of text from standard input and returns + * the line as a string. The newline character that terminates + * the input is not stored as part of the string. + */ + +string GetLine(void); + +/* + * Function: ReadLine + * Usage: s = ReadLine(infile); + * ---------------------------- + * ReadLine reads a line of text from the input file and + * returns the line as a string. The newline character + * that terminates the input is not stored as part of the + * string. The ReadLine function returns NULL if infile + * is at the end-of-file position. + */ + +string ReadLine(FILE *infile); + +#endif diff --git a/fftma_module/gen/include/stack.h b/fftma_module/gen/include/stack.h new file mode 100755 index 0000000..2f765d1 --- /dev/null +++ b/fftma_module/gen/include/stack.h @@ -0,0 +1,115 @@ +/* + * File: stack.h + * ------------- + * This interface defines an abstraction for stacks. In any + * single application that uses this interface, the values in + * the stack are constrained to a single type, although it + * is easy to change that type by changing the definition of + * stackElementT in this interface. + */ + +#ifndef _stack_h +#define _stack_h + +#include "genlib.h" + +/* + * Type: stackElementT + * ------------------- + * The type stackElementT is used in this interface to indicate + * the type of values that can be stored in the stack. Here the + * stack is used to store values of type double, but that can + * be changed by editing this definition line. + */ + +typedef void *stackElementT; + +/* + * Type: stackADT + * -------------- + * The type stackADT represents the abstract type used to store + * the elements that have been pushed. Because stackADT is + * defined only as a pointer to a concrete structure that is not + * itself defined in the interface, clients have no access to + * the underlying fields. + */ + +typedef struct stackCDT *stackADT; + +/* + * Function: NewStack + * Usage: stack = NewStack(); + * -------------------------- + * This function allocates and returns a new stack, which is + * initially empty. + */ + +stackADT NewStack(void); + +/* + * Function: FreeStack + * Usage: FreeStack(stack); + * ------------------------ + * This function frees the storage associated with the stack. + */ + +void FreeStack(stackADT stack); + +/* + * Function: Push + * Usage: Push(stack, element); + * ---------------------------- + * This function pushes the specified element onto the stack. + */ + +void Push(stackADT stack, stackElementT element); + +/* + * Function: Pop + * Usage: element = Pop(stack); + * ---------------------------- + * This function pops the top element from the stack and returns + * that value. The first value popped is always the last one + * that was pushed. If the stack is empty when Pop is called, + * the function calls Error with an appropriate message. + */ + +stackElementT Pop(stackADT stack); + +/* + * Functions: StackIsEmpty, StackIsFull + * Usage: if (StackIsEmpty(stack)) . . . + * if (StackIsFull(stack)) . . . + * ------------------------------------- + * This functions test whether the stack is empty or full. + */ + +bool StackIsEmpty(stackADT stack); +bool StackIsFull(stackADT stack); + +/* + * Function: StackDepth + * Usage: depth = StackDepth(stack); + * --------------------------------- + * This function returns the number of elements currently pushed + * on the stack. + */ + +int StackDepth(stackADT stack); + +/* + * Function: GetStackElement + * Usage: element = GetStackElement(stack, index); + * ----------------------------------------------- + * This function returns the element at the specified index in + * the stack, where the top of the stack is defined as index 0. + * For example, calling GetStackElement(stack, 0) returns the top + * element on the stack without removing it. If the caller tries + * to select an out-of-range element, GetStackElement calls Error. + * Note: This function is not a fundamental stack operation and + * is instead provided principally to facilitate debugging. + */ + +stackElementT GetStackElement(stackADT stack, int index); + +#endif diff --git a/fftma_module/gen/include/strlib.h b/fftma_module/gen/include/strlib.h new file mode 100755 index 0000000..796d1d4 --- /dev/null +++ b/fftma_module/gen/include/strlib.h @@ -0,0 +1,243 @@ +/* + * File: strlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:40 1994 by eroberts + * ----------------------------------------------------- + * The strlib.h file defines the interface for a simple + * string library. In the context of this package, strings + * are considered to be an abstract data type, which means + * that the client relies only on the operations defined for + * the type and not on the underlying representation. + */ + +/* + * Cautionary note: + * ---------------- + * Although this interface provides an extremely convenient + * abstraction for working with strings, it is not appropriate + * for all applications. In this interface, the functions that + * return string values (such as Concat and SubString) do so + * by allocating new memory. Over time, a program that uses + * this package will consume increasing amounts of memory + * and eventually exhaust the available supply. If you are + * writing a program that runs for a short time and stops, + * the fact that the package consumes memory is not a problem. + * If, however, you are writing an application that must run + * for an extended period of time, using this package requires + * that you make some provision for freeing any allocated + * storage. + */ + +#ifndef _strlib_h +#define _strlib_h + +#include "genlib.h" + +/* Section 1 -- Basic string operations */ + +/* + * Function: Concat + * Usage: s = Concat(s1, s2); + * -------------------------- + * This function concatenates two strings by joining them end + * to end. For example, Concat("ABC", "DE") returns the string + * "ABCDE". + */ + +string Concat(string s1, string s2); + +/* + * Function: IthChar + * Usage: ch = IthChar(s, i); + * -------------------------- + * This function returns the character at position i in the + * string s. It is included in the library to make the type + * string a true abstract type in the sense that all of the + * necessary operations can be invoked using functions. Calling + * IthChar(s, i) is like selecting s[i], except that IthChar + * checks to see if i is within the range of legal index + * positions, which extend from 0 to StringLength(s). + * IthChar(s, StringLength(s)) returns the null character + * at the end of the string. + */ + +char IthChar(string s, int i); + +/* + * Function: SubString + * Usage: t = SubString(s, p1, p2); + * -------------------------------- + * SubString returns a copy of the substring of s consisting + * of the characters between index positions p1 and p2, + * inclusive. The following special cases apply: + * + * 1. If p1 is less than 0, it is assumed to be 0. + * 2. If p2 is greater than the index of the last string + * position, which is StringLength(s) - 1, then p2 is + * set equal to StringLength(s) - 1. + * 3. If p2 < p1, SubString returns the empty string. + */ + +string SubString(string s, int p1, int p2); + +/* + * Function: CharToString + * Usage: s = CharToString(ch); + * ---------------------------- + * This function takes a single character and returns a + * one-character string consisting of that character. The + * CharToString function is useful, for example, if you + * need to concatenate a string and a character. Since + * Concat requires two strings, you must first convert + * the character into a string. + */ + +string CharToString(char ch); + +/* + * Function: StringLength + * Usage: len = StringLength(s); + * ----------------------------- + * This function returns the length of s. + */ + +int StringLength(string s); + +/* + * Function: CopyString + * Usage: newstr = CopyString(s); + * ------------------------------ + * CopyString copies the string s into dynamically allocated + * storage and returns the new string. This function is not + * ordinarily required if this package is used on its own, + * but is often necessary when you are working with more than + * one string package. + */ + +string CopyString(string s); + +/* Section 2 -- String comparison functions */ + +/* + * Function: StringEqual + * Usage: if (StringEqual(s1, s2)) ... + * ----------------------------------- + * This function returns TRUE if the strings s1 and s2 are + * equal. For the strings to be considered equal, every + * character in one string must precisely match the + * corresponding character in the other. Uppercase and + * lowercase characters are considered to be different. + */ + +bool StringEqual(string s1, string s2); + +/* + * Function: StringCompare + * Usage: if (StringCompare(s1, s2) < 0) ... + * ----------------------------------------- + * This function returns a number less than 0 if string s1 + * comes before s2 in alphabetical order, 0 if they are equal, + * and a number greater than 0 if s1 comes after s2. The + * ordering is determined by the internal representation used + * for characters, which is usually ASCII. + */ + +int StringCompare(string s1, string s2); + +/* Section 3 -- Search functions */ + +/* + * Function: FindChar + * Usage: p = FindChar(ch, text, start); + * ------------------------------------- + * Beginning at position start in the string text, this + * function searches for the character ch and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindChar(char ch, string text, int start); + +/* + * Function: FindString + * Usage: p = FindString(str, text, start); + * ---------------------------------------- + * Beginning at position start in the string text, this + * function searches for the string str and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindString(string str, string text, int start); + +/* Section 4 -- Case-conversion functions */ + +/* + * Function: ConvertToLowerCase + * Usage: s = ConvertToLowerCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to lower case. + */ + +string ConvertToLowerCase(string s); + +/* + * Function: ConvertToUpperCase + * Usage: s = ConvertToUpperCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to upper case. + */ + +string ConvertToUpperCase(string s); + +/* Section 5 -- Functions for converting numbers to strings */ + +/* + * Function: IntegerToString + * Usage: s = IntegerToString(n); + * ------------------------------ + * This function converts an integer into the corresponding + * string of digits. For example, IntegerToString(123) + * returns "123" as a string. + */ + +string IntegerToString(int n); + +/* + * Function: StringToInteger + * Usage: n = StringToInteger(s); + * ------------------------------ + * This function converts a string of digits into an integer. + * If the string is not a legal integer or contains extraneous + * characters, StringToInteger signals an error condition. + */ + +int StringToInteger(string s); + +/* + * Function: RealToString + * Usage: s = RealToString(d); + * --------------------------- + * This function converts a floating-point number into the + * corresponding string form. For example, calling + * RealToString(23.45) returns "23.45". The conversion is + * the same as that used for "%G" format in printf. + */ + +string RealToString(double d); + +/* + * Function: StringToReal + * Usage: d = StringToReal(s); + * --------------------------- + * This function converts a string representing a real number + * into its corresponding value. If the string is not a + * legal floating-point number or if it contains extraneous + * characters, StringToReal signals an error condition. + */ + +double StringToReal(string s); + +#endif diff --git a/fftma_module/gen/include/symtab.h b/fftma_module/gen/include/symtab.h new file mode 100755 index 0000000..c83c307 --- /dev/null +++ b/fftma_module/gen/include/symtab.h @@ -0,0 +1,85 @@ +/* + * File: symtab.h + * -------------- + * This interface exports a simple symbol table abstraction. + */ + +#ifndef _symtab_h +#define _symtab_h + +#include "genlib.h" + +/* + * Type: symtabADT + * --------------- + * This type is the ADT used to represent a symbol table. + */ + +typedef struct symtabCDT *symtabADT; + +/* + * Type: symtabFnT + * --------------- + * This type defines the class of functions that can be used to + * map over the entries in a symbol table. + */ + +typedef void (*symtabFnT)(string key, void *value, + void *clientData); + +/* Exported entries */ + +/* + * Function: NewSymbolTable + * Usage: table = NewSymbolTable(); + * -------------------------------- + * This function allocates a new symbol table with no entries. + */ + +symtabADT NewSymbolTable(void); + +/* + * Function: FreeSymbolTable + * Usage: FreeSymbolTable(table); + * ------------------------------ + * This function frees the storage associated with the symbol table. + */ + +void FreeSymbolTable(symtabADT table); + +/* + * Function: Enter + * Usage: Enter(table, key, value); + * -------------------------------- + * This function associates key with value in the symbol table. + * Each call to Enter supersedes any previous definition for key. + */ + +void Enter(symtabADT table, string key, void *value); + +/* + * Function: Lookup + * Usage: value = Lookup(table, key); + * ---------------------------------- + * This function returns the value associated with key in the symbol + * table, or UNDEFINED, if no such value exists. + */ + +void *Lookup(symtabADT table, string key); + +/* + * Function: MapSymbolTable + * Usage: MapSymbolTable(fn, table, clientData); + * --------------------------------------------- + * This function goes through every entry in the symbol table + * and calls the function fn, passing it the following arguments: + * the current key, its associated value, and the clientData + * pointer. The clientData pointer allows the client to pass + * additional state information to the function fn, if necessary. + * If no clientData argument is required, this value should be NULL. + */ + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData); + +#endif diff --git a/fftma_module/gen/include/toolsFFTMA.h b/fftma_module/gen/include/toolsFFTMA.h new file mode 100755 index 0000000..32d5535 --- /dev/null +++ b/fftma_module/gen/include/toolsFFTMA.h @@ -0,0 +1,82 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _TOOLSFFTMA_H +#define _TOOLSFFTMA_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* kgeneration, FFTMA2, prebuild_gwn, build_real, addstat2, clean_real */ + + +/*FUNCTIONS*/ +/*----------*/ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y2, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise); + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) ; + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver); + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal); + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2); + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout); + +#endif // define _TOOLSFFTMA_H diff --git a/fftma_module/gen/include/toolsFFTPSIM.h b/fftma_module/gen/include/toolsFFTPSIM.h new file mode 100755 index 0000000..27f0a8c --- /dev/null +++ b/fftma_module/gen/include/toolsFFTPSIM.h @@ -0,0 +1,62 @@ +#include +#include "geostat.h" +#include "pressure.h" + + +#ifndef _TOOLSFFTPSIM_H +#define _TOOLSFFTPSIM_H + +/* Create december, the 16th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* pgeneration, FFTPSim, FFTPressure, build_pressure, build_velocity,total_pressure,total_velocity, clean_real2 */ + +/*Functions */ +/*----------*/ + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver); + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat, + struct vario_mod variogram,string filename[8],struct pressure_mod pression, + struct realization_mod *Y,struct realization_mod *P, + struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file); + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5); + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4, int solver); + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure); + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction); + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression:: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout); + +/* total_velocity */ +/* Build total velocity in one direction */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout); + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout); + +void normAxes(double *vec, double *normed); +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*float dX, float dY, float dZ,*/ double nDir[3], double *waveVect); + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario); + +void mat_vec(double *C, double *x, double *b, int n); + + +#endif // define _TOOLSFFTPSIM_H diff --git a/fftma_module/gen/include/toolsIO.h b/fftma_module/gen/include/toolsIO.h new file mode 100755 index 0000000..e6a6eb9 --- /dev/null +++ b/fftma_module/gen/include/toolsIO.h @@ -0,0 +1,93 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "pressure.h" + +#ifndef _TOOLSIO_H +#define _TOOLSIO_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* writefile,writefile_bin,readfile_bin,inputdata,inputfiledata,readdata,debuginput */ +/* testmemory, testopenfile */ + + +/*FUNCTIONS*/ +/*----------*/ + +/* Lecture dans un fichier */ + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +/* void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,struct realization_mod *Kfield, char *argv[]); */ + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +/* readfile_bin */ +/* */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin); + + +/* Writefile */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile( string filename, struct realization_mod *realin); + +/* Writefile_bin */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin( string filename, struct realization_mod *realin); + + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ +void debuginput(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite); + +/* Allocation test */ +void testmemory(double *realint); + +/* Test open file */ +void testopenfile(FILE *fp); + +#endif // define _TOOLSIO_H diff --git a/fftma_module/gen/lib_src/FFTMAmemoire.c b/fftma_module/gen/lib_src/FFTMAmemoire.c new file mode 100755 index 0000000..15d7f04 --- /dev/null +++ b/fftma_module/gen/lib_src/FFTMAmemoire.c @@ -0,0 +1,110 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + string variable; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); +/* testmemory(covar); */ + allouememoire(covar,'covar'); + + + + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/lib_src/FFTPSim.c b/fftma_module/gen/lib_src/FFTPSim.c new file mode 100755 index 0000000..0f65c29 --- /dev/null +++ b/fftma_module/gen/lib_src/FFTPSim.c @@ -0,0 +1,162 @@ +#include +#include +#include "geostat.h" +#include "toolsludo.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *covar,*realization,*pressure; + double *icovar,*ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + icovar = (double *) malloc(ntot * sizeof(double)); + testmemory(icovar); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,icovar,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + + prebuild_gwn(grid,n,realin,realization); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real(realin,n,grid,realization,realout); + clean_real(realin,n,grid,pressure,realout2); + clean_real(realin,n,grid,xvelocity,realout3); + clean_real(realin,n,grid,yvelocity,realout4); + clean_real(realin,n,grid,zvelocity,realout5); + + free(realization); + free(pressure); + free(xvelocity); + free(yvelocity); + free(zvelocity); + + return; +} diff --git a/fftma_module/gen/lib_src/FFTPressure.c b/fftma_module/gen/lib_src/FFTPressure.c new file mode 100755 index 0000000..15ab392 --- /dev/null +++ b/fftma_module/gen/lib_src/FFTPressure.c @@ -0,0 +1,157 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization,*pressure; + double *ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + FILE *fp; +/* string nomfichier; */ + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + for (i=1;i<=NTOT;i++) + realization[i]=realization[i]/(double) NTOT; + + fp = fopen("realization.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + +/* nomfichier="pression.test"; */ + fp = fopen("pression.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",pressure[i]); + fclose(fp); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real2(realin,n,grid,solver,pressure,realout); + clean_real2(realin,n,grid,solver,xvelocity,realout2); + clean_real2(realin,n,grid,solver,yvelocity,realout3); + clean_real2(realin,n,grid,solver,zvelocity,realout4); + + /* free(realization); */ + /* free(pressure); */ + /* free(xvelocity); */ + /* free(yvelocity); */ + /* free(zvelocity); */ + + return; +} diff --git a/fftma_module/gen/lib_src/FFTtest.c b/fftma_module/gen/lib_src/FFTtest.c new file mode 100755 index 0000000..9f88ee0 --- /dev/null +++ b/fftma_module/gen/lib_src/FFTtest.c @@ -0,0 +1,68 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM Test */ + +void FFTtest(int n[3],struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization; + double *ireal; + double ki,kj,kk; + FILE *fp; + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + fp = fopen("perm.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + fp = fopen("perm2.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/lib_src/Makefile.libCS106X b/fftma_module/gen/lib_src/Makefile.libCS106X new file mode 100755 index 0000000..ccef6b8 --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile.libCS106X @@ -0,0 +1,13 @@ +CC = cc +CCFLAG = + +LIB = libCS106X_${ARCH}.a +%.o: %.c + $(CC) $(CCFLAG) -c $< + + +$(LIB) : genlib.o random.o simpio.o strlib.o symtab.o scanadt.o stack.o + ar r $@ $? + +clean : + rm *.o diff --git a/fftma_module/gen/lib_src/Makefile.libFFTMA b/fftma_module/gen/lib_src/Makefile.libFFTMA new file mode 100755 index 0000000..a492b20 --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile.libFFTMA @@ -0,0 +1,30 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +INTERFACE = ../include +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CC = cc +CCFLAGS = + +LIB = libFFTMA_${ARCH}.a + +NOBJS= gammf.o fftma.o addstat.o axes.o cgrid.o covariance.o fourt.o length.o maxfactor.o test_fact.o cov_value.o generate.o gasdev.o ran2.o stable.o gaussian.o power.o cubic.o spherical.o nugget.o exponential.o cardsin.o nor2log.o + + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/lib_src/Makefile.libFFTMA2 b/fftma_module/gen/lib_src/Makefile.libFFTMA2 new file mode 100755 index 0000000..09fc204 --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile.libFFTMA2 @@ -0,0 +1,30 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +INTERFACE = ../include + +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CC = cc + CCFLAGS = + +LIB = libFFTMA2_${ARCH}.a + +NOBJS= kgeneration.o kgeneration2.o fftma2.o prebuild_gwn.o build_real.o addstat2.o clean_real.o + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/lib_src/Makefile.libFFTPSim b/fftma_module/gen/lib_src/Makefile.libFFTPSim new file mode 100755 index 0000000..49f4e7a --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile.libFFTPSim @@ -0,0 +1,34 @@ + +######################################################################## +# +# Makefile for library +# +######################################################################## + + +#INTERFACE = ${BOSSE}/CODES/LIBS_C/Interface +#INTERFACE2= ${BOSSE}/CODES/Geostat/FFTPSim/Version_binaire2/src/Interface + +INTERFACE = ../include +#INTERFACE2= ../Interface + +INCLUDE = -I${INTERFACE} +LIBS = -lm -L../lib +CCFLAGS = +CC = cc + +LIB = libFFTPSIM_${ARCH}.a + +NOBJS= pgeneration.o pgeneration2.o FFTPressure.o FFTtest.o build_pressure.o build_velocity.o total_pressure.o total_velocity.o clean_real2.o waveVectorCompute3D.o mat_vec.o derivReal.o + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/lib_src/Makefile.libIO b/fftma_module/gen/lib_src/Makefile.libIO new file mode 100755 index 0000000..6c4b2af --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile.libIO @@ -0,0 +1,31 @@ +# +######################################################################## +# +# Makefile for library +# +######################################################################## +# + +#INTERFACE = ${BOSSE}/CODES/LIBS_C/Interface +INTERFACE = ../include + +INCLUDE = -I${INTERFACE} +CC = cc +CCFLAGS = + + +LIB = libIO_${ARCH}.a + +NOBJS= inputdata.o inputfiledata.o debuginput.o readdata.o readfile_bin.o writefile.o writefile_bin.o testmemory.o testopenfile.o readdata2.o readdata3.o + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/lib_src/Makefile_debug b/fftma_module/gen/lib_src/Makefile_debug new file mode 100755 index 0000000..0ecafef --- /dev/null +++ b/fftma_module/gen/lib_src/Makefile_debug @@ -0,0 +1,21 @@ +# CC = gcc +# CCFLAG = + +ifeq (${ARCH},sun) + CC = cc + CCFLAG = -g +endif +ifeq (${ARCH},linux) + CC = gcc + CCFLAG = -g +endif +LIB = libCS106X_debug_${ARCH}.a +%.o: %.c + $(CC) $(CCFLAG) -c $< + + +$(LIB) : genlib.o random.o simpio.o strlib.o symtab.o scanadt.o stack.o + ar r $@ $? + +clean : + rm *.o diff --git a/fftma_module/gen/lib_src/Py_getvalues.c b/fftma_module/gen/lib_src/Py_getvalues.c new file mode 100755 index 0000000..cef5b17 --- /dev/null +++ b/fftma_module/gen/lib_src/Py_getvalues.c @@ -0,0 +1,111 @@ +#include +#include +#include +#include +#include +#include +#include +#include "Py_py-api.h" +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +#if PY_MAJOR_VERSION >= 3 + #define PyIntObject PyLongObject + #define PyInt_Type PyLong_Type + #define PyInt_Check(op) PyLong_Check(op) + #define PyInt_CheckExact(op) PyLong_CheckExact(op) + #define PyInt_FromString PyLong_FromString + #define PyInt_FromUnicode PyLong_FromUnicode + #define PyInt_FromLong PyLong_FromLong + #define PyInt_FromSize_t PyLong_FromSize_t + #define PyInt_FromSsize_t PyLong_FromSsize_t + #define PyInt_AsLong PyLong_AsLong + #define PyInt_AS_LONG PyLong_AS_LONG + #define PyInt_AsSsize_t PyLong_AsSsize_t + #define PyInt_AsUnsignedLongMask PyLong_AsUnsignedLongMask + #define PyInt_AsUnsignedLongLongMask PyLong_AsUnsignedLongLongMask + #define PyNumber_Int PyNumber_Long +#endif + +#if PY_MAJOR_VERSION >= 3 + #define PyBoolObject PyLongObject +#endif + +#if PY_MAJOR_VERSION >= 3 && CYTHON_COMPILING_IN_PYPY + #ifndef PyUnicode_InternFromString + #define PyUnicode_InternFromString(s) PyUnicode_FromString(s) + #endif +#endif + + +int Py_getvalues(PyObject* args, long* seed,struct grid_mod* grid,struct vario_mod* variogram,struct statistic_mod* stat) +{ + int i, varioNargs=12, j=0; + PyObject* listvario; + PyObject* vgr; + //char* gwnfilename; + + + stat->nblock_mean=1; + stat->nblock_var=1; + stat->mean=(double*)malloc(stat->nblock_mean * sizeof(double)); + if (stat->mean == NULL) return 0; + stat->variance=(double*)malloc(stat->nblock_var * sizeof(double)); + if (stat->variance == NULL) return 0; + + + if(!PyArg_ParseTuple(args, "iiidddlO!ddi", /*"iiidddslO!ddi",*/ + &(grid->NX), + &(grid->NY), + &(grid->NZ), + &(grid->DX), + &(grid->DY), + &(grid->DZ), + /*gwnfilename,*/ + seed, + &PyList_Type, &listvario, + stat->mean+0, + stat->variance+0, + &(stat->type))) return 0; + + + variogram->Nvario=PyList_Size(listvario); + + variogram->var=(double*)malloc(variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + variogram->vario=(int*)malloc(variogram->Nvario*sizeof(int)); + if(variogram->vario==NULL) return 0; + variogram->alpha=(double*)malloc(variogram->Nvario*sizeof(double)); + if(variogram->alpha==NULL) return 0; + variogram->scf=(double*)malloc(3*variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + variogram->ap=(double*)malloc(9*variogram->Nvario*sizeof(double)); + if(variogram->var==NULL) return 0; + for(i=0;iNvario;i++) + { + vgr=PyList_GetItem(listvario,i); + if(PyTuple_Size(vgr)!=12) return 0; + (variogram->var)[i]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->vario)[i]=(int)PyInt_AsLong(PyTuple_GetItem(vgr,j++)); + (variogram->alpha)[i]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+0]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+1]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->scf)[i*3+2]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+0]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+1]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+2]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+3]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+4]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + (variogram->ap)[i*9+5]=PyFloat_AsDouble(PyTuple_GetItem(vgr,j++)); + } + + + + + + + return 1; +} diff --git a/fftma_module/gen/lib_src/Py_kgeneration.c b/fftma_module/gen/lib_src/Py_kgeneration.c new file mode 100755 index 0000000..dc7dbfd --- /dev/null +++ b/fftma_module/gen/lib_src/Py_kgeneration.c @@ -0,0 +1,60 @@ +#include +#include +#include +#include +#include +#include +#include +#include "Py_py-api.h" +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void Py_kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3]) + { + int i,N; + int typelog; + + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + + + + + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + // if (*gwnwrite == 0) + // { + // writefile(filename[0],Z); + // } + + + + /*FFTMA*/ + FFTMA2(variogram,grid,n,Z,Y); + + /*add the statistics*/ + if (stat.mean[0] != 0 || stat.variance[0]!= 1) + addstat2(Y,stat,Y1,Y); + + /* make a log normal realization */ + if (stat.type==1 || stat.type==2){ + + typelog=stat.type+2; + /* nor2log(Y1,typelog,Y1); */ + nor2log(Y,typelog,Y); + } + + return; + } diff --git a/fftma_module/gen/lib_src/Py_py-api.h b/fftma_module/gen/lib_src/Py_py-api.h new file mode 100644 index 0000000..b224b2e --- /dev/null +++ b/fftma_module/gen/lib_src/Py_py-api.h @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +int Py_getvalues(PyObject*, long*, struct grid_mod*, struct vario_mod*, struct statistic_mod*); +void Py_kgeneration(long,struct grid_mod,struct statistic_mod,struct vario_mod,struct realization_mod*,struct realization_mod*,struct realization_mod*, int [3]); diff --git a/fftma_module/gen/lib_src/addstat.c b/fftma_module/gen/lib_src/addstat.c new file mode 100755 index 0000000..ffcb781 --- /dev/null +++ b/fftma_module/gen/lib_src/addstat.c @@ -0,0 +1,106 @@ +#include +#include +#include "geostat.h" +#include "genlib.h" + + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ +void addstat(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + break; + case 6: + (*realout).code = 7; + break; + default: + (*realout).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + switch (stat.type) { + case 0: + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + break; + case 1: + /*lognormal (natural) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log(1.0+r); + break; + case 2: + /*lognormal (log10) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log10(1.0+r); + break; + default: + Error("Type not defined in addstat"); + break; + } + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/lib_src/addstat2.c b/fftma_module/gen/lib_src/addstat2.c new file mode 100755 index 0000000..3096d0f --- /dev/null +++ b/fftma_module/gen/lib_src/addstat2.c @@ -0,0 +1,119 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + if ((*realout2).vector == NULL || (*realout2).n != (*realin).n) { + (*realout2).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout2).vector == NULL) + Error("No memory available"); + } + (*realout2).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + (*realout2).code = 2; + break; + case 6: + (*realout).code = 7; + (*realout2).code = 7; + break; + default: + (*realout).code = (*realin).code; + (*realout2).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + /* switch (stat.type) { */ +/* case 0: */ + + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + +/* break; */ +/* case 1: */ + /*lognormal (natural) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log(1.0+r); */ +/* break; */ +/* case 2: */ + /*lognormal (log10) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log10(1.0+r); */ +/* break; */ +/* default: */ +/* Error("Type not defined in addstat"); */ +/* break; */ +/* } */ + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]; + (*realout2).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/lib_src/allouememoire.c b/fftma_module/gen/lib_src/allouememoire.c new file mode 100755 index 0000000..78f6975 --- /dev/null +++ b/fftma_module/gen/lib_src/allouememoire.c @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include + +void allouememoire(double *realint, string variable) +{ + + if (realint == NULL) { + printf("Testmemory.c: No memory available for %s\n",variable); + exit; + } + return; +} diff --git a/fftma_module/gen/lib_src/axes.c b/fftma_module/gen/lib_src/axes.c new file mode 100755 index 0000000..b9e8351 --- /dev/null +++ b/fftma_module/gen/lib_src/axes.c @@ -0,0 +1,41 @@ +#include +#include + +/*normalizes anisotropy axes*/ +void axes(double *ap,double *scf,int N) +{ + double sclpdt, r, eps = 1.E-6; + int i,j,k; + + + for (k = 0; k < N; k++) { + + r = sqrt(ap[9*k]*ap[9*k]+ap[9*k+1]*ap[9*k+1]+ap[9*k+2]*ap[9*k+2]); + ap[9*k] /= r; + ap[9*k+1] /= r; + ap[9*k+2] /= r; + sclpdt = ap[9*k]*ap[9*k+3]+ap[9*k+1]*ap[9*k+4]+ap[9*k+2]*ap[9*k+5]; + if (sclpdt > eps) { + printf("Non orthogonal axes"); + exit; + } else { + r = sqrt(ap[9*k+3]*ap[9*k+3]+ap[9*k+4]*ap[9*k+4]+ap[9*k+5]*ap[9*k+5]); + ap[9*k+3] /= r; + ap[9*k+4] /= r; + ap[9*k+5] /= r; + ap[9*k+6] = ap[9*k+1]*ap[9*k+5]-ap[9*k+2]*ap[9*k+4]; + ap[9*k+7] = ap[9*k+2]*ap[9*k+3]-ap[9*k]*ap[9*k+5]; + ap[9*k+8] = ap[9*k]*ap[9*k+4]-ap[9*k+1]*ap[9*k+3]; + for (i=0; i<3; i++) { + for (j=0; j<3; j++) { + if (scf[3*k+j] == 0.) + scf[3*k+j] = 1.; + ap[9*k+3*j+i] /= scf[3*k+j]; + } + } + } + + } + return; +} + diff --git a/fftma_module/gen/lib_src/build_pressure.c b/fftma_module/gen/lib_src/build_pressure.c new file mode 100755 index 0000000..b9ded34 --- /dev/null +++ b/fftma_module/gen/lib_src/build_pressure.c @@ -0,0 +1,66 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_pressure */ +/* build pressure in spectral domain */ + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure) +{ + int i,j,k,maille1; + double ki,kj,kk; + double coeff,temp,temp2; + + /* pressure calculation in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (n[0]==1) + { + ki=0.; + } + else + { + ki =(double)(i-1)/(double)(grid.NX*grid.DX); + } + if (n[1]==1) + { + kj=0.; + } + else + { + kj =(double)j/(double)(grid.NY*grid.DY); + } + if (n[2]==1) + { + kk=0.; + } + else + { + kk =(double)k/(double)(grid.NZ*grid.DZ); + } + + coeff = (gradient.x*ki+gradient.y*kj+gradient.z*kk)/(ki*ki+kj*kj+kk*kk); + temp = realization[maille1]; + temp2= ireal[maille1]; + if (maille1==1) + { + pressure[maille1] =0.; + ipressure[maille1]=0.; + } + else + { + pressure[maille1] =-1./(2*3.14)*coeff*temp2; + ipressure[maille1]= 1./(2*3.14)*coeff*temp; + } + } + } + } + return; +} diff --git a/fftma_module/gen/lib_src/build_real.c b/fftma_module/gen/lib_src/build_real.c new file mode 100755 index 0000000..4a0e186 --- /dev/null +++ b/fftma_module/gen/lib_src/build_real.c @@ -0,0 +1,45 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal) +{ + int i,j,k,maille1; + double temp; + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + ireal[maille1] *= temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/lib_src/build_velocity.c b/fftma_module/gen/lib_src/build_velocity.c new file mode 100755 index 0000000..7511c4d --- /dev/null +++ b/fftma_module/gen/lib_src/build_velocity.c @@ -0,0 +1,117 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_velocity */ +/* Build velocity in spectral domain */ + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction) +{ + int i,j,k,maille1; + int x,y,z; + double ki,kj,kk; + double coeff,temp,temp2; + double grad; + + /* x-direction velocity calculation in the spectral domain*/ + switch(direction) + { + case 1: + grad = gradient.x; + x=1; + y=0; + z=0; + break; + case 2: + grad = gradient.y; + x=0; + y=1; + z=0; + break; + case 3: + grad = gradient.z; + x=0; + y=0; + z=1; + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; +/* if (i +#include +#include "genlib.h" + +/*cardsin covariance function*/ +double cardsin(double h) +{ + float delta = 20.371; + double z; + + if (h != 0) { + z = (double)(h*delta); + z = sin(z)/z; + } else { + z = 1.; + } + return(z); +} diff --git a/fftma_module/gen/lib_src/cgrid.c b/fftma_module/gen/lib_src/cgrid.c new file mode 100755 index 0000000..19baee0 --- /dev/null +++ b/fftma_module/gen/lib_src/cgrid.c @@ -0,0 +1,43 @@ +#include +#include "geostat.h" + + +/*computes the size of the grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]) +{ + int i,N; + double D; + + if (n == NULL || n[0] == 0 || n[1] == 0 || n[2] == 0) { + for (i = 0; i<3; i++) { + switch (i) { + case 0: + N = grid.NX; + D = grid.DX; + break; + case 1: + N = grid.NY; + D = grid.DY; + break; + case 2: + N = grid.NZ; + D = grid.DZ; + break; + } + n[i] = length(N,i,variogram.scf,variogram.ap,D,variogram.Nvario); + } + } else { + if ((n[0] +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + /* Modif du 18 juin 2003 */ + /*(*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT;*/ + (*realout).vector[maille0] = vectorresult[maille1]; + } + } + } + + return; +} diff --git a/fftma_module/gen/lib_src/clean_real2.c b/fftma_module/gen/lib_src/clean_real2.c new file mode 100755 index 0000000..058be88 --- /dev/null +++ b/fftma_module/gen/lib_src/clean_real2.c @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real2.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + if (solver==1) + { + for ( k = 1; k <= NTOT;k++) + { + (*realout).vector[k-1] = vectorresult[k]/(double) NTOT; + } + } + else + { + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT; + } + } + } + } + return; +} diff --git a/fftma_module/gen/lib_src/cov_value.c b/fftma_module/gen/lib_src/cov_value.c new file mode 100755 index 0000000..e7baf5d --- /dev/null +++ b/fftma_module/gen/lib_src/cov_value.c @@ -0,0 +1,55 @@ +#include +#include "geostat.h" +#include "genlib.h" + +/*selection of model covariance*/ +double cov_value(struct vario_mod variogram,double di,double dj,double dk) +{ + double hx,hy,hz,h; + double cov; + int k; + + + cov = 0.; + + for (k = 0; k < variogram.Nvario; k++) { + + hx = di*variogram.ap[9*k]+dj*variogram.ap[9*k+1]+dk*variogram.ap[9*k+2]; + hy = di*variogram.ap[9*k+3]+dj*variogram.ap[9*k+4]+dk*variogram.ap[9*k+5]; + hz = di*variogram.ap[9*k+6]+dj*variogram.ap[9*k+7]+dk*variogram.ap[9*k+8]; + h = sqrt(hx*hx+hy*hy+hz*hz); + + + switch (variogram.vario[k]) { + case 1: + cov += variogram.var[k]*exponential(h); + break; + case 2: + cov += variogram.var[k]*gaussian(h); + break; + case 3: + cov += variogram.var[k]*spherical(h); + break; + case 4: + cov += variogram.var[k]*cardsin(h); + break; + case 5: + cov += variogram.var[k]*stable(h,variogram.alpha[k]); + break; + case 6: + cov += variogram.var[k]*gammf(h,variogram.alpha[k]); + break; + case 7: + cov += variogram.var[k]*cubic(h); + break; + case 8: + cov += variogram.var[k]*nugget(h); + break; + case 9: + cov += variogram.var[k]*power(h,variogram.alpha[k]); + break; + } + } + + return (cov); +} diff --git a/fftma_module/gen/lib_src/covariance.c b/fftma_module/gen/lib_src/covariance.c new file mode 100755 index 0000000..4678b2a --- /dev/null +++ b/fftma_module/gen/lib_src/covariance.c @@ -0,0 +1,90 @@ +#include "geostat.h" + +/*builds the sampled covariance function*/ +/*dimensions are even*/ +void covariance(double *covar, struct vario_mod variogram, struct grid_mod mesh, int n[3]) + +{ + int i,j,k,maille,n2[3],symmetric; + double di,dj,dk; + + + for (i=0;i<3;i++) + n2[i] = n[i]/2; + + for (i=0; i<= n2[0]; i++) { + for (j=0; j<= n2[1]; j++) { + for (k=0; k<= n2[2]; k++) { + + + /*area 1*/ + maille = 1+i+n[0]*(j+n[1]*k); + di = (double)i*mesh.DX; + dj = (double)j*mesh.DY; + dk = (double)k*mesh.DZ; + covar[maille] = (double)cov_value(variogram,di,dj,dk); + + + if (k > 0 && k 0 && j 0 && i 0 && i 0 && k 0 && j 0 && i 0 && j < n2[1]) { + /*area 5*/ + di = -(double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+(n[0]-i)+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && j < n2[1]) { + /*area 3*/ + di = (double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+i+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && i +#include +#include "genlib.h" + + +/*cubic covariance function*/ +double cubic(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-7.*(double)(h*h)+(35./4.)*(double)(h*h*h)-3.5*(double)(h*h*h*h*h)+.75*(double)(h*h*h*h*h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/lib_src/debuginput.c b/fftma_module/gen/lib_src/debuginput.c new file mode 100755 index 0000000..b9c3a45 --- /dev/null +++ b/fftma_module/gen/lib_src/debuginput.c @@ -0,0 +1,73 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "toolsIO.h" + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void debuginput(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite) +{ + int i; + + + /* debug du 8/7/2002 */ + printf("\n\n"); + + printf("Starting seed (integer): %d\n",(*seed)); + printf("Number of cells along the X axis: %d\n",(*grid).NX); + printf("Number of cells along the Y axis: %d\n",(*grid).NY); + printf("Number of cells along the Z axis: %d\n",(*grid).NZ); + printf("cell length along the X axis: %6.4f\n",(*grid).DX); + printf("cell length along the Y axis: %6.4f\n",(*grid).DY); + printf("cell length along the Z axis: %6.4f\n",(*grid).DZ); + printf("Number of structures for the variogram: %d\n",(*variogram).Nvario); + i=0; + printf("Weight: %6.4f\n",(*variogram).var[i]); + printf("Type of variogram: %d\n",(*variogram).vario[i]); + printf("Exponent: %6.4f\n",(*variogram).alpha[i]); + + printf("Mean of the output realization: %15.8f\n",(*stat).mean[0]); + printf("Variance of the output realization: %6.4f\n",(*stat).variance[0]); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : %d\n",(*stat).type); + + /*output files*/ + printf("output filename for permeability realization: %s\n", filename[1]); + printf("\n\n"); + if (*gwnwrite == 0) + { + printf("K field generation with Gaussian white noise!\n"); + printf("output filename for Gaussian white noise: %s\n",filename[0]); + } + printf("\n\n"); + if ((*Ksolver == 1) | (*Ksolver == 2)) + { + printf("P field generation: %d/n",*Ksolver); + printf("output filename for pressure realization: %s\n", filename[2]); + printf("output filename for pressure total realization: %s\n", filename[3]); + printf("output filename for x-velocity realization: %s\n", filename[4]); + printf("output filename for y-velocity realization: %s\n", filename[5]); + printf("output filename for z-velocity realization: %s\n", filename[6]); + printf("output filename for pressure gradient realization: %s\n", filename[7]); + + /*Pressure data*/ + printf("Pressure gradient in x direction: %6.4f\n",(*pression).x); + printf("Pressure gradient in y direction: %6.4f\n",(*pression).y); + printf("Pressure gradient in z direction: %6.4f\n",(*pression).z); + } + printf("\n\n"); + + return; +} diff --git a/fftma_module/gen/lib_src/derivReal.c b/fftma_module/gen/lib_src/derivReal.c new file mode 100755 index 0000000..7e7e02b --- /dev/null +++ b/fftma_module/gen/lib_src/derivReal.c @@ -0,0 +1,216 @@ +#include +#include +#include +#include "condor.h" +#include "geostat.h" + +/* Private functions */ +void normAxes(double *vec, double *normed); + + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario) { + + int n[3],i,j,k,maille,extMaille; + int NTOT,ntot,NMAX,nmax,NDIM; +// int NXYZ,nxyz; + double nDir[3]; + double *table,*workr,*worki,*realization,*waveVect; + + + int Ngrid; + double tmp; + double *ExtendedWaveVect; + +/* Test the input real*/ +/* if ((*Z).code != 1) { */ +/* printf("Realization should be Standard Normal\n"); */ +/* return; */ +/* } */ + + printf("grid.Nx = %d\n",(*grid).NX); + printf("grid.Ny = %d\n",(*grid).NY); + printf("grid.Nz = %d\n",(*grid).NZ); + + printf("vario.Nvario = %d\n",vario.Nvario); + for(i=0; i NMAX) NMAX = n[i]; + if (n[i] == 1) NDIM = NDIM-1; + } + nmax = NMAX+1; + + printf("NTOT = %d, ntot = %d, NMAX = %d\n",NTOT,ntot,NMAX); + +/* wave vector computation */ + normAxes(dir,nDir); + printf("Derivation direction (normed) %f %f %f\n",nDir[0],nDir[1],nDir[2]); + waveVect = (double *) malloc(Ngrid*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + waveVectorCompute3D((*grid).NX,(*grid).NY,(*grid).NZ,nDir,waveVect); + +/* memory allocation */ + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("derivReal.cpp: No memory availble for table\n"); + return; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + ExtendedWaveVect = (double *) malloc(ntot * sizeof(double)); + if (ExtendedWaveVect == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("derivReal.cpp: No memory available for workr\n"); + return; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("derivReal.cpp: No memory available for worki\n"); + return; + } + + extMaille =0; +/* organization of the extended realization */ + for (k=1;k<=n[2];k++) { + for (j=1;j<=n[1];j++) { + for (i=1;i<=n[0];i++) { + extMaille = i + ((j-1) + (((k-1) * n[1]) * n[0])); + if (i <= (*grid).NX && j <= (*grid).NY && k <= (*grid).NZ) { + maille = i-1 + ((j-1) + ((k-1) * (*grid).NY) * (*grid).NX); + realization[extMaille] = (*Z).vector[maille]; + ExtendedWaveVect[extMaille] = waveVect[maille]; + } else { + realization[extMaille] = 0.0; + ExtendedWaveVect[extMaille] = 0.0; + } + } + } + } + +/* forward fourier transform of the realization */ + fourt(realization,table,n,NDIM,1,0,workr,worki); + FILE *wave; + wave = fopen("/home/irsrvshare1/R03/UPS_FLEX/waveVector.eas","w"); + + for (i=1;i +#include +#include "genlib.h" + +/*exponential covariance function*/ +double exponential(double h) +{ + return (exp(-3.*(double)h)); +} diff --git a/fftma_module/gen/lib_src/fftma.c b/fftma_module/gen/lib_src/fftma.c new file mode 100755 index 0000000..3daa08f --- /dev/null +++ b/fftma_module/gen/lib_src/fftma.c @@ -0,0 +1,185 @@ + +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + + + +void FFTMA(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *table,*covar,*workr,*worki,*realization,temp; + + + /*test over the input realization*/ + /*if ((*realin).code != 0) { + printf("Input realizations in FFTMA must be Gaussian white noises"); + exit; + }*/ + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + if (covar == NULL) { + printf("FFTMA.c: No memory available for covar"); + exit; + } + + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("FFTMA.c: No memory available for table"); + exit; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("FFTMA.c: No memory available for realization"); + exit; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("FFTMA.c: No memory available for workr"); + exit; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("FFTMA.c: No memory available for worki"); + exit; + } + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + + /*power spectrum*/ + fourt(covar,table,n,NDIM,1,0,workr,worki); + + + /*organization of the input Gaussian white noise*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (i <= grid.NX && j <= grid.NY && k <= grid.NZ) { + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + realization[maille1] = (*realin).vector[maille0]; + } else { + realization[maille1] = 0.; + } + } + } + } + + + /*forward fourier transform of the GWN*/ + fourt(realization,table,n,NDIM,1,0,workr,worki); + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + table[maille1] *= temp; + } + } + } + + + free(covar); + + + /*backward fourier transform*/ + fourt(realization,table,n,NDIM,0,1,workr,worki); + + + free(table); + free(workr); + free(worki); + + + /*output realization*/ + + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("FFTMA.c: No memory available"); + exit; + } + } + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = realization[maille1]; + } + } + } + + + free(realization); + + + return; +} + + + + diff --git a/fftma_module/gen/lib_src/fftma2.c b/fftma_module/gen/lib_src/fftma2.c new file mode 100755 index 0000000..5977690 --- /dev/null +++ b/fftma_module/gen/lib_src/fftma2.c @@ -0,0 +1,105 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/lib_src/fourt.c b/fftma_module/gen/lib_src/fourt.c new file mode 100755 index 0000000..fe80035 --- /dev/null +++ b/fftma_module/gen/lib_src/fourt.c @@ -0,0 +1,591 @@ +#include +#include + +/*fast fourier transform */ +/* THE COOLEY-TUKEY FAST FOURIER TRANSFORM */ +/* EVALUATES COMPLEX FOURIER SERIES FOR COMPLEX OR REAL FUNCTIONS. */ +/* THAT IS, IT COMPUTES */ +/* FTRAN(J1,J2,...)=SUM(DATA(I1,I2,...)*W1**(I1-1)*(J1-1) */ +/* *W2**(I2-1)*(J2-1)*...), */ +/* WHERE W1=EXP(-2*PI*SQRT(-1)/NN(1)), W2=EXP(-2*PI*SQRT(-1)/NN(2)), */ +/* ETC. AND I1 AND J1 RUN FROM 1 TO NN(1), I2 AND J2 RUN FROM 1 TO */ +/* NN(2), ETC. THERE IS NO LIMIT ON THE DIMENSIONALITY (NUMBER OF */ +/* SUBSCRIPTS) OF THE ARRAY OF DATA. THE PROGRAM WILL PERFORM */ +/* A THREE-DIMENSIONAL FOURIER TRANSFORM AS EASILY AS A ONE-DIMEN- */ +/* SIONAL ONE, THO IN A PROPORTIONATELY GREATER TIME. AN INVERSE */ +/* TRANSFORM CAN BE PERFORMED, IN WHICH THE SIGN IN THE EXPONENTIALS */ +/* IS +, INSTEAD OF -. IF AN INVERSE TRANSFORM IS PERFORMED UPON */ +/* AN ARRAY OF TRANSFORMED DATA, THE ORIGINAL DATA WILL REAPPEAR, */ +/* MULTIPLIED BY NN(1)*NN(2)*... THE ARRAY OF INPUT DATA MAY BE */ +/* REAL OR COMPLEX, AT THE PROGRAMMERS OPTION, WITH A SAVING OF */ +/* ABOUT THIRTY PER CENT IN RUNNING TIME FOR REAL OVER COMPLEX. */ +/* (FOR FASTEST TRANSFORM OF REAL DATA, NN(1) SHOULD BE EVEN.) */ +/* THE TRANSFORM VALUES ARE ALWAYS COMPLEX, AND ARE RETURNED IN THE */ +/* ORIGINAL ARRAY OF DATA, REPLACING THE INPUT DATA. THE LENGTH */ +/* OF EACH DIMENSION OF THE DATA ARRAY MAY BE ANY INTEGER. THE */ +/* PROGRAM RUNS FASTER ON COMPOSITE INTEGERS THAN ON PRIMES, AND IS */ +/* PARTICULARLY FAST ON NUMBERS RICH IN FACTORS OF TWO. */ +/* TIMING IS IN FACT GIVEN BY THE FOLLOWING FORMULA. LET NTOT BE THE */ +/* TOTAL NUMBER OF POINTS (REAL OR COMPLEX) IN THE DATA ARRAY, THAT */ +/* IS, NTOT=NN(1)*NN(2)*... DECOMPOSE NTOT INTO ITS PRIME FACTORS, */ +/* SUCH AS 2**K2 * 3**K3 * 5**K5 * ... LET SUM2 BE THE SUM OF ALL */ +/* THE FACTORS OF TWO IN NTOT, THAT IS, SUM2 = 2*K2. LET SUMF BE */ +/* THE SUM OF ALL OTHER FACTORS OF NTOT, THAT IS, SUMF = 3*K3+5*K5+.. */ +/* THE TIME TAKEN BY A MULTIDIMENSIONAL TRANSFORM ON THESE NTOT DATA */ +/* IS T = T0 + T1*NTOT + T2*NTOT*SUM2 + T3*NTOT*SUMF. FOR THE PAR- */ +/* TICULAR IMPLEMENTATION FORTRAN 32 ON THE CDC 3300 (FLOATING POINT */ +/* ADD TIME = SIX MICROSECONDS), */ +/* T = 3000 + 600*NTOT + 50*NTOT*SUM2 + 175*NTOT*SUMF MICROSECONDS */ +/* ON COMPLEX DATA. */ +/* IMPLEMENTATION OF THE DEFINITION BY SUMMATION WILL RUN IN A TIME */ +/* PROPORTIONAL TO NTOT**2. FOR HIGHLY COMPOSITE NTOT, THE SAVINGS */ +/* OFFERED BY COOLEY-TUKEY CAN BE DRAMATIC. A MATRIX 100 BY 100 WILL */ +/* BE TRANSFORMED IN TIME PROPORTIONAL TO 10000*(2+2+2+2+5+5+5+5) = */ +/* 280,000 (ASSUMING T2 AND T3 TO BE ROUGHLY COMPARABLE) VERSUS */ +/* 10000**2 = 100,000,000 FOR THE STRAIGHTFORWARD TECHNIQUE. */ +/* THE COOLEY-TUKEY ALGORITHM PLACES TWO RESTRICTIONS UPON THE */ +/* NATURE OF THE DATA BEYOND THE USUAL RESTRICTION THAT */ +/* THE DATA FROM ONE CYCLE OF A PERIODIC FUNCTION. THEY ARE-- */ +/* 1. THE NUMBER OF INPUT DATA AND THE NUMBER OF TRANSFORM VALUES */ +/* MUST BE THE SAME. */ +/* 2. CONSIDERING THE DATA TO BE IN THE TIME DOMAIN, */ +/* THEY MUST BE EQUI-SPACED AT INTERVALS OF DT. FURTHER, THE TRANS- */ +/* FORM VALUES, CONSIDERED TO BE IN FREQUENCY SPACE, WILL BE EQUI- */ +/* SPACED FROM 0 TO 2*PI*(NN(I)-1)/(NN(I)*DT) AT INTERVALS OF */ +/* 2*PI/(NN(I)*DT) FOR EACH DIMENSION OF LENGTH NN(I). OF COURSE, */ +/* DT NEED NOT BE THE SAME FOR EVERY DIMENSION. */ + +/* THE CALLING SEQUENCE IS-- */ +/* CALL FOURT(DATAR,DATAI,NN,NDIM,IFRWD,ICPLX,WORKR,WORKI) */ + +/* DATAR AND DATAI ARE THE ARRAYS USED TO HOLD THE REAL AND IMAGINARY */ +/* PARTS OF THE INPUT DATA ON INPUT AND THE TRANSFORM VALUES ON */ +/* OUTPUT. THEY ARE FLOATING POINT ARRAYS, MULTIDIMENSIONAL WITH */ +/* IDENTICAL DIMENSIONALITY AND EXTENT. THE EXTENT OF EACH DIMENSION */ +/* IS GIVEN IN THE INTEGER ARRAY NN, OF LENGTH NDIM. THAT IS, */ +/* NDIM IS THE DIMENSIONALITY OF THE ARRAYS DATAR AND DATAI. */ +/* IFRWD IS AN INTEGER USED TO INDICATE THE DIRECTION OF THE FOURIER */ +/* TRANSFORM. IT IS NON-ZERO TO INDICATE A FORWARD TRANSFORM */ +/* (EXPONENTIAL SIGN IS -) AND ZERO TO INDICATE AN INVERSE TRANSFORM */ +/* (SIGN IS +). ICPLX IS AN INTEGER TO INDICATE WHETHER THE DATA */ +/* ARE REAL OR COMPLEX. IT IS NON-ZERO FOR COMPLEX, ZERO FOR REAL. */ +/* IF IT IS ZERO (REAL) THE CONTENTS OF ARRAY DATAI WILL BE ASSUMED */ +/* TO BE ZERO, AND NEED NOT BE EXPLICITLY SET TO ZERO. AS EXPLAINED */ +/* ABOVE, THE TRANSFORM RESULTS ARE ALWAYS COMPLEX AND ARE STORED */ +/* IN DATAR AND DATAI ON RETURN. WORKR AND WORKI ARE ARRAYS USED */ +/* FOR WORKING STORAGE. THEY ARE NOT NECESSARY IF ALL THE DIMENSIONS */ +/* OF THE DATA ARE POWERS OF TWO. IN THIS CASE, THE ARRAYS MAY BE */ +/* REPLACED BY THE NUMBER 0 IN THE CALLING SEQUENCE. THUS, USE OF */ +/* POWERS OF TWO CAN FREE A GOOD DEAL OF STORAGE. IF ANY DIMENSION */ +/* IS NOT A POWER OF TWO, THESE ARRAYS MUST BE SUPPLIED. THEY ARE */ +/* FLOATING POINT, ONE DIMENSIONAL OF LENGTH EQUAL TO THE LARGEST */ +/* ARRAY DIMENSION, THAT IS, TO THE LARGEST VALUE OF NN(I). */ +/* WORKR AND WORKI, IF SUPPLIED, MUST NOT BE THE SAME ARRAYS AS DATAR */ +/* OR DATAI. ALL SUBSCRIPTS OF ALL ARRAYS BEGIN AT 1. */ + +/* THERE ARE NO ERROR MESSAGES OR ERROR HALTS IN THIS PROGRAM. THE */ +/* PROGRAM RETURNS IMMEDIATELY IF NDIM OR ANY NN(I) IS LESS THAN ONE. */ + +/* PROGRAM MODIFIED FROM A SUBROUTINE OF BRENNER */ +/* 10-06-2000, MLR */ + + +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx, double *workr,double *worki) +{ + int ifact[21],ntot,idim,np1,n,np2,m,ntwo,iff,idiv,iquot,irem,inon2,non2p,np0,nprev,icase,ifmin,i,j,jmax,np2hf,i2,i1max,i3,j3,i1,ifp1,ifp2,i2max,i1rng,istep,imin,imax,mmax,mmin,mstep,j1,j2max,j2,jmin,j3max,nhalf; + double theta,wstpr,wstpi,wminr,wmini,wr,wi,wtemp,thetm,wmstr,wmsti,twowr,sr,si,oldsr,oldsi,stmpr,stmpi,tempr,tempi,difi,difr,sumr,sumi,TWOPI = 6.283185307179586476925286766559; + + ntot = 1; + for (idim = 0; idim < ndim; idim++) { + ntot *= nn[idim]; + } + + /*main loop for each dimension*/ + np1 = 1; + for (idim = 1; idim <= ndim; idim++) { + n = nn[idim-1]; + np2 = np1*n; + + if (n < 1) { + goto L920; + } else if (n == 1) { + goto L900; + } + + /*is n a power of 2 and if not, what are its factors*/ + m = n; + ntwo = np1; + iff = 1; + idiv = 2; + + L10: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L50; + if (irem == 0) { + ntwo *= 2; + ifact[iff] = idiv; + iff++; + m= iquot; + goto L10; + } + idiv = 3; + inon2 = iff; + + L30: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L60; + if (irem == 0) { + ifact[iff] = idiv; + iff++; + m = iquot; + goto L30; + } + + idiv += 2; + goto L30; + + L50: + inon2 = iff; + if (irem != 0) + goto L60; + ntwo *= 2; + goto L70; + + L60: + ifact[iff] = m; + + L70: + non2p = np2/ntwo; + + + /*SEPARATE FOUR CASES-- + 1. COMPLEX TRANSFORM + 2. REAL TRANSFORM FOR THE 2ND, 3RD, ETC. DIMENSION. METHOD: TRANSFORM HALF THE DATA, SUPPLYING THE OTHER HALF BY CONJUGATE SYMMETRY. + 3. REAL TRANSFORM FOR THE 1ST DIMENSION, N ODD. METHOD: SET THE IMAGINARY PARTS TO ZERO. + 4. REAL TRANSFORM FOR THE 1ST DIMENSION, N EVEN. METHOD: TRANSFORM A COMPLEX ARRAY OF LENGTH N/2 WHOSE REAL PARTS ARE THE EVEN NUMBERED REAL VALUES AND WHOSE IMAGINARY PARTS ARE THE ODD-NUMBERED REAL VALUES. UNSCRAMBLE AND SUPPLY THE SECOND HALF BY CONJUGATE SYMMETRY. */ + + icase = 1; + ifmin = 1; + if (icplx != 0) + goto L100; + icase = 2; + if (idim > 1) + goto L100; + icase = 3; + if (ntwo <= np1) + goto L100; + icase = 4; + ifmin = 2; + ntwo /= 2; + n /= 2; + np2 /= 2; + ntot /= 2; + i = 1; + for (j = 1; j <= ntot; j++) { + datar[j] = datar[i]; + datai[j] = datar[i+1]; + i += 2; + } + + /*shuffle data by bit reversal, since n = 2^k. As the shuffling can be done by simple interchange, no working array is needed*/ + L100: + if (non2p > 1) + goto L200; + np2hf = np2/2; + j = 1; + for (i2 = 1; i2 <= np2; i2 += np1) { + if (j >= i2) + goto L130; + i1max = i2+np1-1; + for (i1 = i2; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j3 = j+i3-i2; + tempr = datar[i3]; + tempi = datai[i3]; + datar[i3] = datar[j3]; + datai[i3] = datai[j3]; + datar[j3] = tempr; + datai[j3] = tempi; + } + } + + L130: + m = np2hf; + + L140: + if (j <= m) { + j += m; + } else { + j -= m; + m /= 2; + if (m >= np1) + goto L140; + } + + } + goto L300; + + /*shuffle data by digit reversal for general n*/ + L200: + for (i1 = 1; i1 <= np1; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j = i3; + for (i = 1; i <= n; i++) { + if (icase != 3) { + workr[i] = datar[j]; + worki[i] = datai[j]; + } else { + workr[i] = datar[j]; + worki[i] = 0.; + } + ifp2 = np2; + iff = ifmin; + L250: + ifp1 = ifp2/ifact[iff]; + j += ifp1; + if (j >= i3+ifp2) { + j -= ifp2; + ifp2 = ifp1; + iff += 1; + if (ifp2 > np1) + goto L250; + } + } + i2max = i3+np2-np1; + i = 1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + datar[i2] = workr[i]; + datai[i2] = worki[i]; + i++; + } + + } + } + + /*special case-- W=1*/ + L300: + i1rng = np1; + if (icase == 2) + i1rng = np0*(1+nprev/2); + if (ntwo <= np1) + goto L600; + for (i1 = 1; i1 <= i1rng; i1++) { + imin = np1+i1; + istep = 2*np1; + goto L330; + + L310: + j = i1; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]; + tempi = datai[i]; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] = datar[j]+tempr; + datai[j] = datai[j]+tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + + L330: + if (istep <= ntwo) + goto L310; + + /*special case-- W = -sqrt(-1)*/ + imin = 3*np1+i1; + istep = 4*np1; + goto L420; + + L400: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + if (ifrwd != 0) { + tempr = datai[i]; + tempi = -datar[i]; + } else { + tempr = -datai[i]; + tempi = datar[i]; + } + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + + imin = 2*imin-i1; + istep *= 2; + + L420: + if (istep <= ntwo) + goto L400; + } + + /*main loop for factors of 2. W=EXP(-2*PI*SQRT(-1)*m/mmax) */ + theta = -TWOPI/8.; + wstpr = 0.; + wstpi = -1.; + if (ifrwd == 0) { + theta = -theta; + wstpi = 1.; + } + mmax = 8*np1; + goto L540; + + L500: + wminr = cos(theta); + wmini = sin(theta); + wr = wminr; + wi = wmini; + mmin = mmax/2+np1; + mstep = np1*2; + for (m = mmin; m <= mmax; m += mstep) { + for (i1 = 1; i1 <= i1rng; i1++) { + istep = mmax; + imin = m+i1; + L510: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]*wr-datai[i]*wi; + tempi = datar[i]*wi+datai[i]*wr; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + if (istep <= ntwo) + goto L510; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + wstpr = wminr; + wstpi = wmini; + theta /= 2.; + mmax += mmax; + L540: + if (mmax <= ntwo) + goto L500; + + /*main loop for factors not equal to 2-- W=EXP(-2*PI*SQRT(-1)*(j2-i3)/ifp2)*/ + L600: + if (non2p <= 1) + goto L700; + ifp1 = ntwo; + iff = inon2; + L610: + ifp2 = ifact[iff]*ifp1; + theta = -TWOPI/ (double)ifact[iff]; + if (ifrwd == 0) + theta = -theta; + thetm = theta/ (double)(ifp1/np1); + wstpr = cos(theta); + wstpi = sin(theta); + wmstr = cos(thetm); + wmsti = sin(thetm); + wminr = 1.; + wmini = 0.; + + for (j1 = 1; j1 <= ifp1; j1 += np1) { + i1max = j1+i1rng-1; + for (i1 = j1; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + i = 1; + wr = wminr; + wi = wmini; + j2max = i3+ifp2-ifp1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + twowr = 2.*wr; + jmin = i3; + j3max = j2+np2-ifp2; + for (j3 = j2 ; j3 <= j3max; j3 += ifp2) { + j = jmin+ifp2-ifp1; + sr = datar[j]; + si = datai[j]; + oldsr = 0.; + oldsi = 0.; + j -= ifp1; + L620: + stmpr = sr; + stmpi = si; + sr = twowr*sr-oldsr+datar[j]; + si = twowr*si-oldsi+datai[j]; + oldsr = stmpr; + oldsi = stmpi; + j -= ifp1; + if (j > jmin) + goto L620; + workr[i] = wr*sr-wi*si-oldsr+datar[j]; + worki[i] = wi*sr+wr*si-oldsi+datai[j]; + jmin += ifp2; + i++; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + i = 1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + j3max = j2+np2-ifp2; + for (j3 = j2; j3 <= j3max; j3 += ifp2) { + datar[j3] = workr[i]; + datai[j3] = worki[i]; + i++; + } + } + } + } + wtemp = wminr*wmsti; + wminr = wminr*wmstr-wmini*wmsti; + wmini = wmini*wmstr+wtemp; + } + iff++; + ifp1 = ifp2; + if (ifp1 < np2) + goto L610; + + /*complete a real transform in the 1st dimension, n even, by conjugate symmetries*/ + L700: + switch (icase) { + case 1: + goto L900; + break; + case 2: + goto L800; + break; + case 3: + goto L900; + break; + } + + nhalf = n; + n += n; + theta = -TWOPI/ (double) n; + if (ifrwd == 0) + theta = -theta; + wstpr = cos(theta); + wstpi = sin(theta); + wr = wstpr; + wi = wstpi; + imin = 2; + jmin = nhalf; + goto L725; + L710: + j = jmin; + for (i = imin; i <= ntot; i += np2) { + sumr = (datar[i]+datar[j])/2.; + sumi = (datai[i]+datai[j])/2.; + difr = (datar[i]-datar[j])/2.; + difi = (datai[i]-datai[j])/2.; + tempr = wr*sumi+wi*difr; + tempi = wi*sumi-wr*difr; + datar[i] = sumr+tempr; + datai[i] = difi+tempi; + datar[j] = sumr-tempr; + datai[j] = tempi-difi; + j += np2; + } + imin++; + jmin--; + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + L725: + if (imin < jmin) { + goto L710; + } else if (imin > jmin) { + goto L740; + } + if (ifrwd == 0) + goto L740; + for (i = imin; i <= ntot; i += np2) { + datai[i] = -datai[i]; + } + L740: + np2 *= 2; + ntot *= 2; + j = ntot+1; + imax = ntot/2+1; + L745: + imin = imax-nhalf; + i = imin; + goto L755; + L750: + datar[j] = datar[i]; + datai[j] = -datai[i]; + L755: + i++; + j--; + if (i < imax) + goto L750; + datar[j] = datar[imin]-datai[imin]; + datai[j] = 0.; + if (i >= j) { + goto L780; + } else { + goto L770; + } + L765: + datar[j] = datar[i]; + datai[j] = datai[i]; + L770: + i--; + j--; + if (i > imin) + goto L765; + datar[j] = datar[imin]+datai[imin]; + datai[j] = 0.; + imax = imin; + goto L745; + L780: + datar[1] += datai[1]; + datai[1] = 0.; + goto L900; + + /*complete a real transform for the 2nd, 3rd, ... dimension by conjugate symmetries*/ + L800: + if (nprev <= 2) + goto L900; + for (i3 = 1; i3 <= ntot; i3 += np2) { + i2max = i3+np2-np1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + imax = i2+np1-1; + imin = i2+i1rng; + jmax = 2*i3+np1-imin; + if (i2 > i3) + jmax += np2; + if (idim > 2) { + j = jmax+np0; + for (i = imin; i <= imax; i++) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j--; + } + } + j = jmax; + for (i = imin; i <= imax; i += np0) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j -= np0; + } + } + } + + /*end of loop on each dimension*/ + L900: + np0 = np1; + np1 = np2; + nprev = n; + } + L920: + return; +} diff --git a/fftma_module/gen/lib_src/gammf.c b/fftma_module/gen/lib_src/gammf.c new file mode 100755 index 0000000..97ff3f9 --- /dev/null +++ b/fftma_module/gen/lib_src/gammf.c @@ -0,0 +1,16 @@ +#include +#include +#include "genlib.h" + + +/*gamma covariance function*/ +double gammf(double h, double alpha) +{ + float delta; + double z; + + delta = pow(20.,1./alpha)-1.; + z = 1./(double)(pow(1.+h*delta,alpha)); + return(z); +} + diff --git a/fftma_module/gen/lib_src/gasdev.c b/fftma_module/gen/lib_src/gasdev.c new file mode 100755 index 0000000..a25dfa2 --- /dev/null +++ b/fftma_module/gen/lib_src/gasdev.c @@ -0,0 +1,31 @@ +#include +#include "genlib.h" + +#define NTAB 32 + +double gasdev(long *idum,long *idum2, long *iy, long iv[NTAB]) +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran2(idum) as the source */ +/*of uniform deviates */ +{ + double ran2(long *idum,long *idum2, long *iy, long iv[NTAB]); + static int iset = 0; + static double gset; + double fac,rsq,v1,v2; + + if (iset == 0) { + do { + v1 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + v2 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + rsq = v1*v1+v2*v2; + } while (rsq >= 1.0 || rsq == 0.0); + + fac = sqrt(-2.0*log(rsq)/rsq); + gset = v1*fac; + iset = 1; + return (v2*fac); + } else { + iset = 0; + return (gset); + } +} diff --git a/fftma_module/gen/lib_src/gaussian.c b/fftma_module/gen/lib_src/gaussian.c new file mode 100755 index 0000000..5ef9911 --- /dev/null +++ b/fftma_module/gen/lib_src/gaussian.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*gaussian covariance function*/ +double gaussian(double h) +{ + return (exp(-3.*(double)(h*h))); +} diff --git a/fftma_module/gen/lib_src/generate.c b/fftma_module/gen/lib_src/generate.c new file mode 100755 index 0000000..46869d3 --- /dev/null +++ b/fftma_module/gen/lib_src/generate.c @@ -0,0 +1,43 @@ +#include +#include +#include "geostat.h" + + +/* GENERATION OF A GAUSSIAN WHITE NOISE VECTOR */ +/*input: */ +/* seed: seed */ +/* n: number of components in the vector */ +/*output: */ +/* realization: structure defining the realization*/ + +void generate(long *seed, int n, struct realization_mod *realization) +{ + int i; + long idum2 = 123456789,iy = 0; + long *iv; + int iset =0; + + iv = (long *) malloc(NTAB * sizeof(long)); + + /*negative seed*/ + if (*seed > 0.0) + *seed = -(*seed); + + /*realization definition*/ + (*realization).n = n; + (*realization).code = 0; + (*realization).vector = (double *) malloc(n * sizeof(double)); + if ((*realization).vector == NULL) { + printf("No memory available in generate"); + exit; + } + + /*Gaussian white noise generation*/ + for (i=0; i < n; i++) + (*realization).vector[i] = gasdev(seed,&idum2,&iy,iv,&iset); + + return; +} + + + diff --git a/fftma_module/gen/lib_src/genlib.c b/fftma_module/gen/lib_src/genlib.c new file mode 100755 index 0000000..1a106f6 --- /dev/null +++ b/fftma_module/gen/lib_src/genlib.c @@ -0,0 +1,63 @@ +/* + * File: genlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file implements the general C library package. See the + * interface description in genlib.h for details. + */ + +#include +#include +#include +#include + +#include "genlib.h" + +/* + * Constants: + * ---------- + * ErrorExitStatus -- Status value used in exit call + */ + +#define ErrorExitStatus 1 + +/* Section 1 -- Define new "primitive" types */ + +/* + * Constant: UNDEFINED + * ------------------- + * This entry defines the target of the UNDEFINED constant. + */ + +char undefined_object[] = "UNDEFINED"; + +/* Section 2 -- Memory allocation */ + +void *GetBlock(size_t nbytes) +{ + void *result; + + result = malloc(nbytes); + if (result == NULL) Error("No memory available"); + return (result); +} + +void FreeBlock(void *ptr) +{ + free(ptr); +} + +/* Section 3 -- Basic error handling */ + +void Error(string msg, ...) +{ + va_list args; + + va_start(args, msg); + fprintf(stderr, "Error: "); + vfprintf(stderr, msg, args); + fprintf(stderr, "\n"); + va_end(args); + exit(ErrorExitStatus); +} diff --git a/fftma_module/gen/lib_src/genlib.h b/fftma_module/gen/lib_src/genlib.h new file mode 100755 index 0000000..f5a490f --- /dev/null +++ b/fftma_module/gen/lib_src/genlib.h @@ -0,0 +1,163 @@ +/* + * File: genlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file contains several definitions that form the + * core of a general-purpose ANSI C library developed by Eric + * Roberts. The goal of this library is to provide a basic + * set of tools and conventions that increase the readability + * of C programs, particularly as they are used in a teaching + * environment. + * + * The basic definitions provided by genlib.h are: + * + * 1. Declarations for several new "primitive" types + * (most importantly bool and string) that are + * used throughout the other libraries and + * applications as fundamental types. + * + * 2. A new set of functions for memory allocation. + * + * 3. A function for error handling. + */ + +#ifndef _genlib_h +#define _genlib_h + +#include +#include +#include + +/* Section 1 -- Define new "primitive" types */ + +/* + * Type: bool + * ---------- + * This type has two values, FALSE and TRUE, which are equal to 0 + * and 1, respectively. Most of the advantage of defining this type + * comes from readability because it allows the programmer to + * provide documentation that a variable will take on only one of + * these two values. Designing a portable representation, however, + * is surprisingly hard, because many libraries and some compilers + * define these names. The definitions are usually compatible but + * may still be flagged as errors. + */ + +#ifdef THINK_C + typedef int bool; +#else +# ifdef TRUE +# ifndef bool +# define bool int +# endif +# else +# ifdef bool +# define FALSE 0 +# define TRUE 1 +# else + typedef enum {FALSE, TRUE} bool; +# endif +# endif +#endif + +/* + * Type: string + * ------------ + * The type string is identical to the type char *, which is + * traditionally used in C programs. The main point of defining a + * new type is to improve program readability. At the abstraction + * levels at which the type string is used, it is usually not + * important to take the string apart into its component characters. + * Declaring it as a string emphasizes this atomicity. + */ + +typedef char *string; + +/* + * Constant: UNDEFINED + * ------------------- + * Besides NULL, the only other constant of pointer type is + * UNDEFINED, which is used in certain packages as a special + * sentinel to indicate an undefined pointer value. In many + * such contexts, NULL is a legitimate data value and is + * therefore inappropriate as a sentinel. + */ + +#define UNDEFINED ((void *) undefined_object) + +extern char undefined_object[]; + +/* Section 2 -- Memory allocation */ + +/* + * General notes: + * -------------- + * These functions provide a common interface for memory + * allocation. All functions in the library that allocate + * memory do so using GetBlock and FreeBlock. Even though + * the ANSI standard defines malloc and free for the same + * purpose, using GetBlock and FreeBlock provides greater + * compatibility with non-ANSI implementations, automatic + * out-of-memory error detection, and the possibility of + * substituting a garbage-collecting allocator. + */ + +/* + * Function: GetBlock + * Usage: ptr = (type) GetBlock(nbytes); + * ------------------------------------- + * GetBlock allocates a block of memory of the given size. If + * no memory is available, GetBlock generates an error. + */ + +void *GetBlock(size_t nbytes); + +/* + * Function: FreeBlock + * Usage: FreeBlock(ptr); + * ---------------------- + * FreeBlock frees the memory associated with ptr, which must + * have been allocated using GetBlock, New, or NewArray. + */ + +void FreeBlock(void *ptr); + +/* + * Macro: New + * Usage: p = New(pointer-type); + * ----------------------------- + * The New pseudofunction allocates enough space to hold an + * object of the type to which pointer-type points and returns + * a pointer to the newly allocated pointer. Note that + * "New" is different from the "new" operator used in C++; + * the former takes a pointer type and the latter takes the + * target type. + */ + +#define New(type) ((type) GetBlock(sizeof *((type) NULL))) + +/* + * Macro: NewArray + * Usage: p = NewArray(n, element-type); + * ------------------------------------- + * NewArray allocates enough space to hold an array of n + * values of the specified element type. + */ + +#define NewArray(n, type) ((type *) GetBlock((n) * sizeof(type))) + +/* Section 3 -- Basic error handling */ + +/* + * Function: Error + * Usage: Error(msg, ...) + * ---------------------- + * Error generates an error string, expanding % constructions + * appearing in the error message string just as printf does. + * After printing the error message, the program terminates. + */ + +void Error(string msg, ...); + +#endif diff --git a/fftma_module/gen/lib_src/geostat.h b/fftma_module/gen/lib_src/geostat.h new file mode 100755 index 0000000..3f36ecf --- /dev/null +++ b/fftma_module/gen/lib_src/geostat.h @@ -0,0 +1,689 @@ +#include +#include +#include +#include + + +#ifndef _GEOSTAT_H +#define _GEOSTAT_H + +#define NTAB 32 + +/* Modified january, the 22th 2004 */ +/* from float to double */ + +/* List of structures: */ +/* ------------------- */ + +/* vario_mod */ +/* variotable_mod*/ +/* grid_mod */ +/* welldata_mod */ +/* statfacies_mod */ +/* inequalities_mod */ +/* statistic_mod */ +/* grad_mod */ +/* gradients_mod */ +/* cdf_mod */ +/* realization_mod */ + + +/* List of functions: */ +/* ------------------ */ + +/* axes, cardsin, choldc, coordinates */ +/* covariance, cov_matrix, cov_value, */ +/* cubic, cutspectr, deflimit, dual_kri */ +/* exponential, fourt, funtrun1, G, gammf */ +/* gammln, gammp, gasdev, gaussian, gcf, */ +/* gen_cov_matrix, Ginv, gradual, cgrid, */ +/* gser, invtrun1, krig_stat, length, */ +/* LtimeZ, mat_vec, maxfactor, metrop, norm */ +/* normal, nugget, power, ran2, scal_vect, */ +/* solve3, sort, spherical, stable, statlog2nor */ +/* test_fract, trun1, trungasdev,vec_vec, */ +/* vf2gthres,polint */ + + + + +/*STRUCTURES*/ +/*----------*/ +/*variogram */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct vario_mod { + int Nvario; + int *vario; + double *alpha; + double *ap; + double *scf; + double *var; +}; + + + +/*variogram table */ +/*Nvario: number of combined variogram models */ +/*vario: model of variogram per variogram model */ +/* 1 --> exponential */ +/* 2 --> gaussian */ +/* 3 --> spherical */ +/* 4 --> cardsin */ +/* 5 --> stable */ +/* 6 --> gamma */ +/* 7 --> cubic */ +/* 8 --> nugget */ +/* 9 --> power */ +/*alpha: exponent for the stable and gamma variogram */ +/* per variogram model */ +/*ap: anisotropy axes per variogram model */ +/*scf: correlation lengths per variogram model */ +/*var: normalized variance per variogram model(sum = 1)*/ +struct variotable_mod { + int number_of_variograms; + int *Nvario; + int *vario; + float *alpha; + float *ap; + float *scf; + float *var; +}; + + + + +/*grid */ +/*NX: number of gridblocks along the X axis*/ +/*NY: number of gridblocks along the Y axis*/ +/*NZ: number of gridblocks along the Z axis*/ +/*DX: gridblock length along the X axis */ +/*DY: gridblock length along the Y axis */ +/*DZ: gridblock length along the Z axis */ +/*Xo: X-cell number of the origin cell */ +/*Yo: Y-cell number of the origin cell */ +/*Zo: Z-cell number of the origin cell */ +struct grid_mod { + int NX, NY, NZ; + double DX,DY,DZ; + double Xo,Yo,Zo; +}; + + +/*well data */ +/*nwell: number of wells */ +/*n: number of measurement points per well */ +/* i = [0...nwell-1] */ +/*ntype: number of measurement types */ +/*code: status of the measurements i=[0...ntype-1] */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: uniform */ +/* --> 7: any */ +/*x: X-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*y: Y-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*z: Z-coordinates of the measurements */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/*measure: values of the measurements */ +/* same kind of indexation, but repeated per type of */ +/* measurement */ +/* type 1 : */ +/* i = [0 ... n[0]-1 n[0] ... n[0]+n[1]-1...sum(n[k])-1]*/ +/* type 2 : */ +/* i=[sum(n[k])... sum(n[k])+n[0]-1 ... 2*(sum(n[k])-1)]*/ + +struct welldata_mod { + int nwell; + int *n; + int ntype; + int *code; + float *x; + float *y; + float *z; + float *measure; +}; + + + +/*volume fractions for facies */ +/*ncat: number of facies */ +/*nblock: number of gridblocks with different */ +/* volume fractions */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*vf: volume fractions for the first ncat-1 facies*/ +/* i = [0...ncat-2]*nblock */ +struct statfacies_mod { + int ncat; + int nblock; + float *vf; +}; + + +/*inequalities for truncated plurigaussian realizations*/ +/*only two basic realizations Y1 and Y2 are considered */ +/*Y1 and Y2 are independent */ +/*nsY1: number of unknown thresholds for Y1 */ +/*nsY2: number of unknown thresholds for Y2 */ +/*thresholds: vector with the thresholds and -10 and 10*/ +/* the output values are the Gaussian */ +/* thresholds */ +/* i = [0 ... n+1], n = nsY1+nsY2 */ +/* thresholds[n] = -10,thresholds[n+1] = 10 */ +/* given at the beginning */ +/*address_sY1: successive upper and lower bounds for */ +/* the different facies for Y1 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY1 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +/*address_sY2: successive upper and lower bounds for */ +/* the different facies for Y2 */ +/* i = [0 ... 2*ncat-1] */ +/* the values in address_sY2 are integers */ +/* ranging from 0 to n+1 with n = nsY1+nsY2*/ +struct inequalities_mod { + int nsY1; + int nsY2; + float *thresholds; + int *address_sY1; + int *address_sY2; +}; + + +/*statistical data */ +/*type --> 0 : normal */ +/* --> 1 : natural log */ +/* --> 2 : log 10 */ +/*nblock_mean: number of gridblocks with different */ +/* means */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*mean: mean of the variable i = [0...nblock_mean] */ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, MEAN IS LOG MEAN ! */ +/*nblock_var: number of gridblocks with different */ +/* variances */ +/* = 1 --> stationary case */ +/* = NX*NY*NZ --> nonstationary case */ +/*variance: variance of the variable i = [0...nblock_var]*/ +/* DHF CHANGE: FOR TYPE 1 AND TYPE 2, VAR IS LOG VAR ! */ +struct statistic_mod { + int type; + int nblock_mean; + double *mean; + int nblock_var; + double *variance; +}; + + +/*gradual deformation parameters */ +/*Nadded: number of complementary realizations */ +/*NZONES: number of subregions */ +/*rho: gradual deformation parameters */ +/*rho[NZONES*(0...Nadded)] */ +/*cellini[NZONES*(0...2)] lower cell bound for */ +/*for subregions along axes X,Y,Z */ +/*cellfin[NZONES*(0...2)] upper cell bound for */ +/*for subregions along axes X,Y,Z */ +struct grad_mod { + int Nadded, NZONES; + float *rho; + int *cellini, *cellfin; +}; + + +/*gradient structures */ +/*Nparam : number of parameters for which gradients are */ +/* required */ +/*Ncells : number of cells for which gradients are */ +/* calculated */ +/*grad : vector with the calculated gradients */ +/* dimension = Nparam*Ncells */ +/* this vector is organized as */ +/* 0 1...Ncells-1 for the first parameter followed*/ +/* Ncells....2*Ncells-1 for the second parameter */ +/* and so on */ +struct gradients_mod { + int Nparam,Ncells; + float *grad; +}; + + + +/*description of discretized cumulative distributions */ +/*n: number of points */ +/*x: values along the x axis i = [0...n-1] */ +/*fx: corresponding values for the cumulative */ +/* distribution i = [0...n-1] */ +struct cdf_mod { + int n; + float *x; + float *fx; +}; + + +/*realization */ +/*n: number of components */ +/*code: status of the realization */ +/* --> 0 : Gaussian white noise */ +/* --> 1: standard Normal */ +/* --> 2: non standard Normal */ +/* --> 3: lognormal (neperien) */ +/* --> 4: lognormal (log10) */ +/* --> 5: facies */ +/* --> 6: conditional standard Normal */ +/* --> 7: conditional non standard Normal */ +/* --> 8: conditional lognormal (neperien) */ +/* --> 9: conditional lognormal (log10) */ +/* --> 10: conditional facies */ +/* --> 11: uniform numbers */ +/* --> 12: conditional uniform numbers */ +/* --> 13: unconditional any type */ +/* --> 14: conditional any type */ +/*vector: realization vector i = [0...n-1] */ +struct realization_mod { + int n; + int code; + double *vector; +}; + +/*=====================================================*/ + +/*FUNCTIONS*/ +/*---------*/ + + +/*normalization of the anostropy axes */ +/*ap: anisotropy axes */ +/*scf: correlation lengths */ +/* The returned normalized axes are in ap */ +void axes(double *ap, double *scf, int N); + + +/*cardsin covariance value for lag h*/ +double cardsin(double h); + + +/*Cholesky decomposition of matrix C */ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, 0 <= i <= n */ +/* n : dimension of matrix Cij */ +/* */ +/* C is turned into the lower triangular cholesky matrix*/ +void choldc(double *C, int n); + + +/*computes the coordinates of a given cell */ +/*as numbers of cells along the X,Y and Z axes*/ +/*maille = i[0]+1+i[1]*NX+i[2]*NX*NY */ +/*input: */ +/*maille: number of the cell to identify */ +/*grid: structure defining the grid */ +/*output: */ +/*i: vector with the coordinates */ +void coordinates(int maille, int i[3],struct grid_mod grid); + + +/*builds the sampled covariance function */ +/*dimensions are even */ +/*covar: covariance array, vector of size*/ +/*1+NX*NY*NZ, covar[0] is a dead cell */ +/*variogram: structure defined above */ +/*grid: structure defined above */ +/*n: number of gridblocks along X,Y and Z*/ +void covariance(double *covar,struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*computation of the covariance matrix for the well data*/ +/*well coordinates are given as a number of cells */ +/*The dimension of C is given by well.nwell */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +/*grid: structure defined above */ +void cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, struct grid_mod grid); + + +/*calculation of the covariance value for a distance h */ +/*defined by i,j,k */ +/*available variogram model: */ +/* 1 -> exponential */ +/* 2 -> gaussian */ +/* 3 -> spherical */ +/* 4 -> cardsin */ +/* 5 -> stable */ +/* 6 -> gamma */ +/* 7 -> cubic */ +/* 8 -> nugget */ +/* 9 -> power */ +/*variogram: variogram with the structure defined above*/ +/*di: distance along the X axis */ +/*dj: distance along the Y axis */ +/*dk: distance along the Z axis */ +/* The returned value is the computed covariance value */ +double cov_value(struct vario_mod variogram,double di,double dj,double dk); + +/*cubic covariance value for lag h*/ +double cubic(double h); + + +/*truncation of the power spectrum to remove */ +/*high frequencies - isotropic case */ +/*covar: power spectrum */ +/*kx: number of cells to save along the x-axis */ +/*ky: number of cells to save along the y-axis */ +/*kz: number of cells to save along the z-axis */ +/*n[3]: number of cells along the X, Y and Z axes*/ +void cutspectr(float *covar, int kx, int ky, int kz, int n[3]); + + +/*defines the threshold interval for a facies x*/ +/*lim_inf: lower bound */ +/*lim_sup: upper bound */ +/*x: facies */ +/*thresholds: Gaussian threshold vector */ +/*facies: structure defined above */ +/*nblock: gridcell number of point x */ +void deflimit(double *plim_inf, double *plim_sup, float x, float *thresholds, struct statfacies_mod facies,int nblock); + + +/*kriges the realization considering weights */ +/*realin: input realization */ +/*variogram: structure defining the variogram */ +/*k: type of measure */ +/*well: structure defining the well data */ +/*grid: structure defined above */ +/*D: weight vector of length Ndata, Di, i = 0...Ndata-1*/ +/*The kriged realization is stored in realout */ +void dual_kri(struct realization_mod *realin, struct vario_mod variogram,struct welldata_mod well, struct grid_mod grid, double *D,struct realization_mod *realout); + + + +/*exponential covariance value for lag h*/ +double exponential(double h); + + +/*Fast Fourier Transform - Cooley-Tukey algorithm */ +/*datar: real part vector - to be transformed */ +/*datai: imaginary part vector - to be transformed */ +/*nn: number of gridblocks along the X,Y and Z axes */ +/*ndim: number of dimensions */ +/*ifrwd: non-zero for forward transform, 0 for inverse*/ +/*icplx: non-zero for complex data, 0 for real */ +/*workr: utility real part vector for storage */ +/*worki: utility imaginary part vector for storage */ +/*The transformed data are returned in datar and datai*/ +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx,double *workr,double *worki); + + +/*calculates F(x) = (1/a)*exp(-x*x/2)*/ +double funtrun1(double x); + + +/*cumulative standard normal value*/ +float G(float x); + + +/*gamma covariance value for lag h and exponent alpha*/ +double gammf(double h, double alpha); + + +/*returns the value ln(G(x))*/ +float gammln(float xx); + + +/*incomplete gamma fnction*/ +float gammp(float a, float x); + + +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran1(idum) as the source */ +/*of uniform deviates */ +/*idum: seed */ +double gasdev(long *idum, long *idum2, long *iy, long *iv, int *iset); + +/*gaussian covariance value for lag h*/ +double gaussian(double h); + + +/*incomplete gamma function evaluated by its continued */ +/*fraction represented as gammcf, also returns ln(G(a))*/ +/*as gln */ +void gcf(float *gammcf, float a, float x, float *gln); + + +/*computation of the covariance matrix for the well data*/ +/*well coordinates have no specific unit */ +/*The dimension of C is given by n */ +/*C defines the correlation between the first n wells */ +/*C is recorded as a vector so that */ +/*C[k] = Cij with i = [0...nwell-1], j = [0...nwell-1] */ +/*and k = j+i(i+1)/2 */ +/*variogram: structure defined above */ +/*well: structure defined above */ +void gen_cov_matrix(double *C, struct vario_mod variogram, struct welldata_mod well, int n); + + +/*Ginv */ +/*Computes the inverse of the standard normal cumulative*/ +/*distribution function with a numerical approximation */ +/*from Statistical Computing,by W.J. Kennedy, Jr. and */ +/*James E. Gentle, 1980, p. 95. */ +/*input : */ +/*p: cumulative probability value */ +float Ginv(float p); + + +/*gradual combination of 1 realization + Nadded */ +/*complementary realizations */ +/*rho: gradual deformation parameters */ +/*rho[0...NZONES*Nadded-1] */ +/*rangement des vecteurs colonnes les uns apres */ +/*les autres */ +/*Zo: starting realization */ +/*Zo[0...n] */ +/*Z: complementary realizations all stored */ +/*Z[0...n-1 n...2n-1 ...(Nadded-1)n...Nadded.n-1]*/ +/*sequentially in a single vector */ +/*Nadded: number of complementary realizations */ +/*n: number of components per realization */ +/*NZONES: number of subregions */ +/*grid: grid definition */ +void gradual(struct grad_mod grad,float *Zo,float *Z,float *Zfinal,int n,struct grid_mod grid); + + +/*computes the size of the underlying grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]); + +/*incomplete gamma function evaluated by its series*/ +/*representation as gamser, also returns ln(G(a)) */ +/*as gln */ +void gser(float *gamser, float a, float x, float *gln); + + +/*calculates x so that x = invF(u) */ +/*F is the cumulative density function for the */ +/*function approximating the Gaussian function */ +/*u: uniform deviate between 0 and 1 */ +/*lim_inf: lower bound of the considered interval*/ +/*lim_sup: upper bound of the considered interval*/ +/*C: normalizing constant */ +double invtrun1(double u, double lim_inf, double lim_sup, double C); + + +/*computes the kriging mean and variance*/ +/*for the vector bi, i = [0...n-1] */ +void krig_stat(float *b, int n, struct vario_mod variogram, struct welldata_mod well, float *mean, float *var); + + +/* computes the number of gridblocks for one dimension*/ +/*N: initial number of gridblocks */ +/*i: considered direction */ +/*scf: correlation length */ +/*ap: normalized anisotropy axes */ +int length(int N, int i, double *scf, double *ap, double D, int Nvari); + +/*calculates L.Z/ +/* L : lower triangular matrix recorded */ +/* (per raws) as a vector with only components */ +/* Lij so that j <= i, i = [0...n-1] */ +/* Z : vector, Zi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Lij */ +/* */ +/* The solution vector is returned in b */ +void LtimeZ(double *L, float *Z, float *b, int n); + + +/*calculates C.x/ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* x : vector, xi avec i = [0...n-1] */ +/* b : vector, bi avec i = [0...n-1] */ +/* n : dimension of matrix Cij */ +/* */ +/* The result vector is returned in b */ +void mat_vec(double *C, double *x, double *b, int n); + + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n); + +/*metrop returns a boolean varible that issues a */ +/*verdict on whether to accept a reconfiguration */ +/*defined by the probability ratio "ratio". */ +/*If ratio >= 1, metrop = 1(true), while if ratio < 1, */ +/*metrop is only true with probability "ratio" */ +int metrop(double ratio,long *idum,long *idum2, long *iy, long *iv); + + +/*2-norm of vector b */ +/* b : vector */ +/* n : length of b, bi, i = [0...n-1]*/ +/*returns the norm of b */ +double norm(double *b,int n); + + +/*value of g(x) where g is the normal function*/ +double normal(double x); + + +/*nugget covariance value for lag h*/ +double nugget(double h); + + +/*power covariance value for lag h and exponent alpha*/ +double power(double h,double alpha); + + +/*generates uniform deviates between 0 and 1*/ +/*idum: seed */ +double ran2(long *idum, long *idum2, long *iy, long *iv); + + + +/*calculates bt.b */ +/* b : vector, bi, i = [0...n-1] */ +/* n : length of b */ +/*returns the scalar product of b*/ +double scal_vec(double *b,int n); + + +/*solves the set of n linear equations Cx = D */ +/* C : symmetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1] */ +/* D : right-hand side vector, Di avec i = [0...n-1]*/ +/* n : dimension of matrix Cij */ +/* */ +/* The solution vector is returned in D */ +/* CONJUGATE GRADIENT method */ +void solve3(double *C, double *D, int n); + + +/*sorts an array [0...n-1] into ascending order using */ +/*shell */ +void sort(float n, float *arr); + + +/*spherical covariance value for lag h*/ +double spherical(double h); + + +/*stable covariance value for lag h and exponent alpha*/ +double stable(double h, double alpha); + + +/*conversion of log mean and variance to nor*/ +void statlog2nor(struct statistic_mod *pstat); + + +/*tries factor */ +/*pnum: number to be decomposed */ +/*fact: suggested factor */ +/*pmaxfac: memory to keep the greatest factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac); + + +/*calculates the integrale of an approximate function*/ +/*for the Gaussian function over an interval defined */ +/*by lim_inf and lim_sup */ +/*lim_inf: lower bound of the considered interval */ +/*lim_sup: upper bound of the considered interval */ +double trun1(double lim_inf, double lim_sup); + + +/*draws a truncated gaussian variable between lim_inf*/ +/*and lim_sup */ +/*idum: seed */ +double trungasdev(long *idum,double lim_inf,double lim_sup,long *idum2, long *iy, long iv[NTAB]); + +/* tb1.b2 */ +/* b1 : vector */ +/* b2 : vector */ +/* n : length of b1 and b2, bi, i = [0...n-1]*/ +/*returns the norm the product tb1.b2 */ +double vec_vec(double *b1, double *b2,int n); + + +/*turns the volume fractions into Gaussian thresholds */ +/*facies: structure defined above */ +/*thresholds: output threshold vector fot i = [0...n-1]*/ +/*where n is the number of facies-1 */ +/*USES normal*/ +void vf2gthres(struct statfacies_mod facies,float *thresholds); + +void polint(float xa[],float ya[],int n,float x, float *y,float *dy); + + + +#endif diff --git a/fftma_module/gen/lib_src/inputdata.c b/fftma_module/gen/lib_src/inputdata.c new file mode 100755 index 0000000..259f1dd --- /dev/null +++ b/fftma_module/gen/lib_src/inputdata.c @@ -0,0 +1,122 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + + + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + int i,j; + + + /*seed*/ + printf("Starting seed (integer): \n"); + *seed = GetInteger(); + + /*Grid description*/ + printf("Number of cells along the X axis: \n"); + (*grid).NX = GetInteger(); + printf("Number of cells along the Y axis: \n"); + (*grid).NY = GetInteger(); + printf("Number of cells along the Z axis: \n"); + (*grid).NZ = GetInteger(); + printf("cell length along the X axis: \n"); + (*grid).DX = GetReal(); + printf("cell length along the Y axis: \n"); + (*grid).DY = GetReal(); + printf("cell length along the Z axis: \n"); + (*grid).DZ = GetReal(); + + /*output file*/ + printf("output filename for Gaussian white noise: \n"); + filename[0] = GetLine(); + + /*variogram description*/ + printf("Number of structures for the variogram: \n"); + (*variogram).Nvario = GetInteger(); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + printf("i %d\n",i); + printf("Weight: \n"); + (*variogram).var[i] = GetReal(); + printf("Type of variogram: \n"); + (*variogram).vario[i] = GetInteger(); + printf("Exponent: \n"); + (*variogram).alpha[i] = GetReal(); + printf("Correlation lengths (3): \n"); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]=GetReal(); + printf("Coordinates of the first two main axes (first axis first, then second): \n"); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = GetReal(); + } + + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + printf("Mean of the output realization: \n"); + (*stat).mean[0] = GetReal(); + printf("Variance of the output realization: \n"); + (*stat).variance[0] = GetReal(); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : \n"); + (*stat).type = GetInteger(); + + /*output file*/ + printf("output filename for permeability realization: \n"); + filename[1] = GetLine(); + + /*Pressure data*/ + printf("Macroscopic pressure gradient in x direction: \n"); + (*pression).x = GetReal(); + printf("Macroscopic pressure gradient in y direction: \n"); + (*pression).y = GetReal(); + printf("Macroscopic pressure gradient in z direction: \n"); + (*pression).z = GetReal(); + + + /*output pressure file*/ + printf("output filename for pressure realization: \n"); + filename[2] = GetLine(); + + /*output pressure totale file*/ + printf("output filename for total pressure realization: \n"); + filename[3] = GetLine(); + + /*output x-velocity file*/ + printf("output filename for x-velocity realization: \n"); + filename[4] = GetLine(); + /*output y-velocity file*/ + printf("output filename for y-velocity realization: \n"); + filename[5] = GetLine(); + /*output z-velocity file*/ + printf("output filename for z-velocity realization: \n"); + filename[6] = GetLine(); + + return; +} diff --git a/fftma_module/gen/lib_src/inputfiledata.c b/fftma_module/gen/lib_src/inputfiledata.c new file mode 100755 index 0000000..404d482 --- /dev/null +++ b/fftma_module/gen/lib_src/inputfiledata.c @@ -0,0 +1,71 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + FILE *fp; + int i,j; + + fp=fopen(inputfile,"r"); + if(fp== NULL) + { + printf("Erreur d'ouverture du fichier\n"); + exit(0); + } + *seed=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + filename[0] = ReadLine(fp); + (*variogram).Nvario = atoi(ReadLine(fp)); + + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + (*pression).x = atof(ReadLine(fp)); + (*pression).y = atof(ReadLine(fp)); + (*pression).z = atof(ReadLine(fp)); + filename[2] = ReadLine(fp); + filename[3] = ReadLine(fp); + filename[4] = ReadLine(fp); + filename[5] = ReadLine(fp); + filename[6] = ReadLine(fp); + fclose(fp); + return; +} diff --git a/fftma_module/gen/lib_src/kgeneration.c b/fftma_module/gen/lib_src/kgeneration.c new file mode 100755 index 0000000..633e4c8 --- /dev/null +++ b/fftma_module/gen/lib_src/kgeneration.c @@ -0,0 +1,79 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i + +/* compute the length for one dimension*/ +int length(int N, int i, double *scf, double *ap, double D, int Nvari) +{ + int maxfactor(int n); + double temp1, temp2; + int n, j, k, nmax; + int nlimit = 13; + + if (N == 1) { + n = 1; + } else { + + for (k = 0; k < Nvari; k++) { + temp1 = fabs(ap[9*k+i])*scf[3*k]*scf[3*k]; + for (j = 1; j <3; j++) { + temp2 = fabs(ap[9*k+3*j+i])*scf[3*k+j]*scf[3*k+j]; + if (temp2 > temp1) + temp1 = temp2; + } + } + temp1 = sqrt(temp1); + temp1 /= (double)D; + if ((double)N/temp1 < 2.) { + n = N+(int)(2*temp1); + } else { + n = N+(int)temp1; + } + if ((n % 2) != 0) + n = n+1; + nmax = maxfactor(n); + while (nmax > nlimit) { + n += 2; + nmax = maxfactor(n); + } + } + return (n); +} diff --git a/fftma_module/gen/lib_src/makefileFFTMA_debug.lib b/fftma_module/gen/lib_src/makefileFFTMA_debug.lib new file mode 100755 index 0000000..98f92c5 --- /dev/null +++ b/fftma_module/gen/lib_src/makefileFFTMA_debug.lib @@ -0,0 +1,36 @@ +# +######################################################################## +# +# Makefile for library +# +######################################################################## +# + +INCLUDE = -I./ +LIBS = -lm -L./ +# CCFLAGS = -fast +ifeq (${ARCH},sun) + CC = cc + CCFLAGS = -g +endif +ifeq (${ARCH},linux) + CC = gcc + CCFLAGS = -g +endif + +LIB = libFFTMA_debug_${ARCH}.a + +NOBJS= gammf.o FFTMA.o addstat.o axes.o cgrid.o covariance.o fourt.o length.o maxfactor.o test_fact.o cov_value.o generate.o gasdev.o ran2.o stable.o gaussian.o power.o cubic.o spherical.o nugget.o exponential.o cardsin.o nor2log.o + + +.c.o: + ${CC} $(INCLUDE) $(CCFLAGS) -c $< + +# LIBRARY +$(LIB) : $(NOBJS) + ar cr $(LIB) $(NOBJS) + ranlib $(LIB) + +clean : + rm *.o + diff --git a/fftma_module/gen/lib_src/mat_vec.c b/fftma_module/gen/lib_src/mat_vec.c new file mode 100755 index 0000000..831121b --- /dev/null +++ b/fftma_module/gen/lib_src/mat_vec.c @@ -0,0 +1,33 @@ +/*calculates C.x/ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1]*/ +/* x : vector, xi avec i = [0...n-1]*/ +/* b : vector, bi avec i = [0...n-1]*/ +/* n : dimension of matrix Cij*/ +/* */ +/* The solution vector is returned in b*/ + +void mat_vec(double *C, double *x, double *b, int n) + +{ + int i,k,l; + double temp; + + for (i = 0; i < n; i++) { + temp = 0.; + + for (k = 0; k < n; k++) { + if ( k <= i ) { + l = k+i*(i+1)/2; + } else { + l = i+k*(k+1)/2; + } + temp += C[l]*x[k]; + } + + b[i] = temp; + } + + return; +} diff --git a/fftma_module/gen/lib_src/maxfactor.c b/fftma_module/gen/lib_src/maxfactor.c new file mode 100755 index 0000000..842cd8b --- /dev/null +++ b/fftma_module/gen/lib_src/maxfactor.c @@ -0,0 +1,35 @@ +#include "genlib.h" + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n) +{ + int test_fact(int *pnum, int fact, int *pmaxfac); + int lnum, fact; + int maxfac; + + maxfac = 1; + lnum = n; + + if ( lnum != 0 && lnum != 1 ) { + fact = 2; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 3; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 5; + for (;;) { + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 2; + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 4; + } + } + } + if ( lnum != 1 ) { + if (lnum > maxfac) + maxfac = lnum; + } + } + return (maxfac); +} diff --git a/fftma_module/gen/lib_src/nor2log.c b/fftma_module/gen/lib_src/nor2log.c new file mode 100755 index 0000000..44b6568 --- /dev/null +++ b/fftma_module/gen/lib_src/nor2log.c @@ -0,0 +1,78 @@ +#include +#include +#include "geostat.h" + + +/*TURNS NORMAL NUMBERS INTO LOGNORMAL NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* normal numbers */ +/*typelog: --> 3: lognormal (natural) */ +/* --> 4: lognormal (log10) */ +/*output: */ +/*realout: structure defining a realization - */ +/* lognormal numbers */ + +void nor2log(struct realization_mod *realin, int typelog, struct realization_mod *realout) +{ + + int i; + double coeff; + + + coeff = log(10.0); + + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("No memory available"); + return; + } + } + (*realout).n = (*realin).n; + + + switch ((*realin).code) { + case 0: + case 1: + case 2: + (*realout).code = typelog; + break; + case 6: + case 7: + if (typelog == 3) { + (*realout).code = 8; + } else if (typelog == 4) { + (*realout).code = 9; + } + break; + default: + printf("Input is not normal in nor2log"); + return; + break; + } + + + /*anamorphose*/ + for (i = 0; i < (*realin).n; i++) { + switch (typelog) { + case 3: + /*natural logarithm*/ + (*realout).vector[i] = exp((*realin).vector[i]); + break; + case 4: + /*log10*/ + (*realout).vector[i] = exp((*realin).vector[i]*coeff); + break; + default: + printf("Unexpected case in nor2log"); + return; + break; + } + } + + return; +} diff --git a/fftma_module/gen/lib_src/nugget.c b/fftma_module/gen/lib_src/nugget.c new file mode 100755 index 0000000..cda4929 --- /dev/null +++ b/fftma_module/gen/lib_src/nugget.c @@ -0,0 +1,14 @@ +#include +#include +#include "genlib.h" + + +/*nugget covariance function*/ +double nugget(double h) +{ + if (h == 0) { + return (1.); + } else { + return(0.); + } +} diff --git a/fftma_module/gen/lib_src/pgeneration.c b/fftma_module/gen/lib_src/pgeneration.c new file mode 100755 index 0000000..18e1abb --- /dev/null +++ b/fftma_module/gen/lib_src/pgeneration.c @@ -0,0 +1,48 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + /*save the delta-pressure realization*/ + writefile(filename[2],P); + + total_pressure(grid,pression,P); + + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + writefile(filename[3],P); + /*save the x-velocity realization*/ + writefile(filename[4],VX); + /*save the y-velocity realization*/ + writefile(filename[5],VY); + /*save the z-velocity realization*/ + writefile(filename[6],VZ); + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + /*save the pressure gradient realization*/ + writefile(filename[7],&GP); + + return; + } diff --git a/fftma_module/gen/lib_src/pgeneration2.c b/fftma_module/gen/lib_src/pgeneration2.c new file mode 100755 index 0000000..b81df82 --- /dev/null +++ b/fftma_module/gen/lib_src/pgeneration2.c @@ -0,0 +1,99 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + + /*save the delta-pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[2],P); + break; + case 1: + writefile_bin(filename[2],P); + break; + } + + total_pressure(grid,pression,P); + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[3],P); + break; + case 1: + writefile_bin(filename[3],P); + break; + } + + /*save the x-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[4],VX); + break; + case 1: + writefile_bin(filename[4],VX); + break; + } + + /*save the y-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[5],VY); + break; + case 1: + writefile_bin(filename[5],VY); + break; + } + /*save the z-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[6],VZ); + break; + case 1: + writefile_bin(filename[6],VZ); + break; + } + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + + /*save the pressure gradient realization*/ + switch (format_file) + { + case 0: + writefile(filename[7],&GP); + break; + case 1: + writefile_bin(filename[7],&GP); + break; + } + + return; + } diff --git a/fftma_module/gen/lib_src/power.c b/fftma_module/gen/lib_src/power.c new file mode 100755 index 0000000..88281f6 --- /dev/null +++ b/fftma_module/gen/lib_src/power.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*power covariance function*/ +double power(double h, double alpha) +{ + return(pow(h,alpha)); +} diff --git a/fftma_module/gen/lib_src/prebuild_gwn.c b/fftma_module/gen/lib_src/prebuild_gwn.c new file mode 100755 index 0000000..447e9e7 --- /dev/null +++ b/fftma_module/gen/lib_src/prebuild_gwn.c @@ -0,0 +1,54 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver) + + { + int i,j,k,maille0,maille1; + int ntot; + + ntot=n[0]*n[1]*n[2]; + realization[0]=0.; + if (solver==1) + { + for (i=0;i +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _PRESSURE_H +#define _PRESSURE_H + +/*STRUCTURES*/ +/*----------*/ + +/* pressure_mod */ +/* x: macroscopic gradient value in x direction */ +/* y: macroscopic gradient value in x direction */ +/* z: macroscopic gradient value in x direction */ +struct pressure_mod { + double x,y,z; +}; + + +#endif // define _PRESSURE_H diff --git a/fftma_module/gen/lib_src/ran2.c b/fftma_module/gen/lib_src/ran2.c new file mode 100755 index 0000000..8075f4f --- /dev/null +++ b/fftma_module/gen/lib_src/ran2.c @@ -0,0 +1,50 @@ +#include "genlib.h" + +#define IM1 2147483563 +#define IM2 2147483399 +#define AM (1.0/IM1) +#define IMM1 (IM1-1) +#define IA1 40014 +#define IA2 40692 +#define IQ1 53668 +#define IQ2 52774 +#define IR1 12211 +#define IR2 3791 +#define NTAB 32 +#define NDIV (1+IMM1/NTAB) +#define EPS 1.2e-7 +#define RNMX (1.0-EPS) + +double ran2(long *idum, long *idum2, long *iy, long iv[NTAB]) + +{ + int j; + long k; + double temp; + + if (*idum <= 0) { + if (-(*idum) < 1) *idum = 1; + else *idum = -(*idum); + *idum2 = (*idum); + for (j = NTAB+7; j >= 0; j--) { + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + if (j < NTAB) iv[j] = *idum; + } + *iy = iv[0]; + } + + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + k = *idum2/IQ2; + *idum2 = IA2*(*idum2-k*IQ2)-k*IR2; + if (*idum2 < 0) *idum2 += IM2; + j = (*iy)/NDIV; + *iy = iv[j]-(*idum2); + iv[j] = *idum; + if (*iy < 1) (*iy) += IMM1; + if ((temp = AM*(*iy)) > RNMX) return (RNMX); + else return (temp); +} diff --git a/fftma_module/gen/lib_src/random.c b/fftma_module/gen/lib_src/random.c new file mode 100755 index 0000000..696312d --- /dev/null +++ b/fftma_module/gen/lib_src/random.c @@ -0,0 +1,77 @@ +/* + * File: random.c + * Version: 1.0 + * Last modified on Mon Sep 13 10:42:45 1993 by eroberts + * ----------------------------------------------------- + * This file implements the random.h interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "random.h" + +/* + * Function: Randomize + * ------------------- + * This function operates by setting the random number + * seed to the current time. The srand function is + * provided by the library and requires an + * integer argument. The time function is provided + * by . + */ + +void Randomize(void) +{ + srand((int) time(NULL)); +} + +/* + * Function: RandomInteger + * ----------------------- + * This function first obtains a random integer in + * the range [0..RAND_MAX] by applying four steps: + * (1) Generate a real number between 0 and 1. + * (2) Scale it to the appropriate range size. + * (3) Truncate the value to an integer. + * (4) Translate it to the appropriate starting point. + */ + +int RandomInteger(int low, int high) +{ + int k; + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + k = (int) (d * (high - low + 1)); + return (low + k); +} + +/* + * Function: RandomReal + * -------------------- + * The implementation of RandomReal is similar to that + * of RandomInteger, without the truncation step. + */ + +double RandomReal(double low, double high) +{ + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + return (low + d * (high - low)); +} + +/* + * Function: RandomChance + * ---------------------- + * This function uses RandomReal to generate a number + * between 0 and 100, which it then compares to p. + */ + +bool RandomChance(double p) +{ + return (RandomReal(0, 1) < p); +} diff --git a/fftma_module/gen/lib_src/random.h b/fftma_module/gen/lib_src/random.h new file mode 100755 index 0000000..881af5f --- /dev/null +++ b/fftma_module/gen/lib_src/random.h @@ -0,0 +1,73 @@ +/* + * File: random.h + * Version: 1.0 + * Last modified on Fri Jul 22 16:44:36 1994 by eroberts + * ----------------------------------------------------- + * This interface provides several functions for generating + * pseudo-random numbers. + */ + +#ifndef _random_h +#define _random_h + +#include "genlib.h" +#include + +/* + * Constant: RAND_MAX + * ------------------ + * Unfortunately, several libraries that supposedly conform to + * the ANSI standard do not define RAND_MAX in . To + * reduce portability problems, this interface defines RAND_MAX + * to be the largest positive integer if it is undefined. + */ + +#ifndef RAND_MAX +# define RAND_MAX ((int) ((unsigned) ~0 >> 1)) +#endif + +/* + * Function: Randomize + * Usage: Randomize(); + * ------------------- + * This function sets the random seed so that the random sequence + * is unpredictable. During the debugging phase, it is best not + * to call this function, so that program behavior is repeatable. + */ + +void Randomize(void); + +/* + * Function: RandomInteger + * Usage: n = RandomInteger(low, high); + * ------------------------------------ + * This function returns a random integer in the range low to high, + * inclusive. + */ + +int RandomInteger(int low, int high); + +/* + * Function: RandomReal + * Usage: d = RandomReal(low, high); + * --------------------------------- + * This function returns a random real number in the half-open + * interval [low .. high), meaning that the result is always + * greater than or equal to low but strictly less than high. + */ + +double RandomReal(double low, double high); + +/* + * Function: RandomChance + * Usage: if (RandomChance(p)) . . . + * --------------------------------- + * The RandomChance function returns TRUE with the probability + * indicated by p, which should be a floating-point number between + * 0 (meaning never) and 1 (meaning always). For example, calling + * RandomChance(.30) returns TRUE 30 percent of the time. + */ + +bool RandomChance(double p); + +#endif diff --git a/fftma_module/gen/lib_src/readdata.c b/fftma_module/gen/lib_src/readdata.c new file mode 100755 index 0000000..3a70123 --- /dev/null +++ b/fftma_module/gen/lib_src/readdata.c @@ -0,0 +1,204 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + *Psolver=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*readfile */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double prout; + + /*read the permeability realization*/ + + + fp = fopen(filename, "r"); + + for (i=0;i<(*realin).n;i++) + { + fread(&prout,sizeof(double),1,fp); + printf("Prout: %15.10f\n",prout); + } + + fclose(fp); + return; +} diff --git a/fftma_module/gen/lib_src/scanadt.c b/fftma_module/gen/lib_src/scanadt.c new file mode 100755 index 0000000..bd887c5 --- /dev/null +++ b/fftma_module/gen/lib_src/scanadt.c @@ -0,0 +1,162 @@ +/* + * File: scanadt.c + * --------------- + * This file implements the scanadt.h interface. + */ + +#include +#include +#include "genlib.h" +#include "strlib.h" +#include "scanadt.h" + +/* + * Type: scannerCDT + * ---------------- + * This structure is the concrete representation of the type + * scannerADT, which is exported by this interface. Its purpose + * is to maintain the state of the scanner between calls. The + * details of the representation are invisible to the client, + * but consist of the following fields: + * + * str -- Copy of string passed to SetScannerString + * len -- Length of string, saved for efficiency + * cp -- Current character position in the string + * savedToken -- String saved by SaveToken (NULL indicates none) + * spaceOption -- Setting of the space option extension + */ + +struct scannerCDT { + string str; + int len; + int cp; + string savedToken; + spaceOptionT spaceOption; +}; + +/* Private function prototypes */ + +static void SkipSpaces(scannerADT scanner); +static int ScanToEndOfIdentifier(scannerADT scanner); + +/* Exported entries */ + +scannerADT NewScanner(void) +{ + scannerADT scanner; + + scanner = New(scannerADT); + scanner->str = NULL; + scanner->spaceOption = PreserveSpaces; + return (scanner); +} + +void FreeScanner(scannerADT scanner) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + FreeBlock(scanner); +} + +void SetScannerString(scannerADT scanner, string str) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + scanner->str = CopyString(str); + scanner->len = StringLength(str); + scanner->cp = 0; + scanner->savedToken = NULL; +} + +string ReadToken(scannerADT scanner) +{ + char ch; + string token; + int start, finish; + + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + token = scanner->savedToken; + scanner->savedToken = NULL; + return (token); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + start = finish = scanner->cp; + if (start >= scanner->len) return (CopyString("")); + ch = scanner->str[scanner->cp]; + if (isalnum(ch)) { + finish = ScanToEndOfIdentifier(scanner); + } else { + scanner->cp++; + } + return (SubString(scanner->str, start, finish)); +} + +bool MoreTokensExist(scannerADT scanner) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + return (!StringEqual(scanner->savedToken, "")); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + return (scanner->cp < scanner->len); +} + +void SaveToken(scannerADT scanner, string token) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + Error("Token has already been saved"); + } + scanner->savedToken = token; +} + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option) +{ + scanner->spaceOption = option; +} + +spaceOptionT GetScannerSpaceOption(scannerADT scanner) +{ + return (scanner->spaceOption); +} + +/* Private functions */ + +/* + * Function: SkipSpaces + * Usage: SkipSpaces(scanner); + * --------------------------- + * This function advances the position of the scanner until the + * current character is not a whitespace character. + */ + +static void SkipSpaces(scannerADT scanner) +{ + while (isspace(scanner->str[scanner->cp])) { + scanner->cp++; + } +} + +/* + * Function: ScanToEndOfIdentifier + * Usage: finish = ScanToEndOfIdentifier(scanner); + * ----------------------------------------------- + * This function advances the position of the scanner until it + * reaches the end of a sequence of letters or digits that make + * up an identifier. The return value is the index of the last + * character in the identifier; the value of the stored index + * cp is the first character after that. + */ + +static int ScanToEndOfIdentifier(scannerADT scanner) +{ + while (isalnum(scanner->str[scanner->cp])) { + scanner->cp++; + } + return (scanner->cp - 1); +} diff --git a/fftma_module/gen/lib_src/scanadt.h b/fftma_module/gen/lib_src/scanadt.h new file mode 100755 index 0000000..1da09c3 --- /dev/null +++ b/fftma_module/gen/lib_src/scanadt.h @@ -0,0 +1,159 @@ +/* + * File: scanadt.h + * --------------- + * This file is the interface to a module that exports an abstract + * data type to facilitate dividing a string into logical units + * called "tokens," which are either + * + * 1. Strings of consecutive letters and digits representing words + * 2. One-character strings representing punctuation or separators + * + * To use this package, you must first create an instance of a + * scannerADT by calling + * + * scanner = NewScanner(); + * + * All other calls to the scanner package take this variable as their + * first argument to identify a particular instance of the abstract + * scanner type. + * + * You initialize the scanner to hold a particular string by calling + * + * SetScannerString(scanner, str); + * + * where str is the string from which tokens should be read. To + * retrieve each individual token, you make the following call: + * + * token = ReadToken(scanner); + * + * To determine whether any tokens remain to be read, you can call + * the predicate function MoreTokensExist(scanner). The ReadToken + * function returns the empty string after the last token is read. + * + * The following code fragment serves as an idiom for processing + * each token in the string inputString: + * + * scanner = NewScanner(); + * SetScannerString(scanner, inputString); + * while (MoreTokensExist(scanner)) { + * token = ReadToken(scanner); + * . . . process the token . . . + * } + * + * This version of scanadt.h also supports the following extensions, + * which are documented later in the interface: + * + * SaveToken + * SetScannerSpaceOption + */ + +#ifndef _scanadt_h +#define _scanadt_h + +#include "genlib.h" + +/* + * Type: scannerADT + * ---------------- + * This type is the abstract type used to represent a single instance + * of a scanner. As with any abstract type, the details of the + * internal representation are hidden from the client. + */ + +typedef struct scannerCDT *scannerADT; + +/* + * Function: NewScanner + * Usage: scanner = NewScanner(); + * ------------------------------ + * This function creates a new scanner instance. All other functions + * in this interface take this scanner value as their first argument + * so that they can identify what particular instance of the scanner + * is in use. This design makes it possible for clients to have more + * than one scanner process active at the same time. + */ + +scannerADT NewScanner(void); + +/* + * Function: FreeScanner + * Usage: FreeScanner(scanner); + * ---------------------------- + * This function frees the storage associated with scanner. + */ + +void FreeScanner(scannerADT scanner); + +/* + * Function: SetScannerString + * Usage: SetScannerString(scanner, str); + * -------------------------------------- + * This function initializes the scanner so that it will start + * extracting tokens from the string str. + */ + +void SetScannerString(scannerADT scanner, string str); + +/* + * Function: ReadToken + * Usage: token = ReadToken(scanner); + * ---------------------------------- + * This function returns the next token from scanner. If + * ReadToken is called when no tokens are available, it returns + * the empty string. The token returned by ReadToken is always + * allocated in the heap, which means that clients can call + * FreeBlock when the token is no longer needed. + */ + +string ReadToken(scannerADT scanner); + +/* + * Function: MoreTokensExist + * Usage: if (MoreTokensExist(scanner)) . . . + * ------------------------------------------ + * This function returns TRUE as long as there are additional + * tokens for the scanner to read. + */ + +bool MoreTokensExist(scannerADT scanner); + +/* + * Function: SaveToken + * Usage: SaveToken(scanner, token); + * --------------------------------- + * This function stores the token in the scanner data structure + * in such a way that the next time ReadToken is called, it will + * return that token without reading any additional characters + * from the input. + */ + +void SaveToken(scannerADT scanner, string token); + +/* + * Functions: SetScannerSpaceOption, GetScannerSpaceOption + * Usage: SetScannerSpaceOption(scanner, option); + * option = GetScannerSpaceOption(scanner); + * ----------------------------------------------- + * The SetScannerSpaceOption function controls whether the scanner + * ignores whitespace characters or treats them as valid tokens. + * By default, the ReadToken function treats whitespace characters, + * such as spaces and tabs, just like any other punctuation mark. + * If, however, you call + * + * SetScannerSpaceOption(scanner, IgnoreSpaces); + * + * the scanner will skip over any white space before reading a token. + * You can restore the original behavior by calling + * + * SetScannerSpaceOption(scanner, PreserveSpaces); + * + * The GetScannerSpaceOption function returns the current setting + * of this option. + */ + +typedef enum { PreserveSpaces, IgnoreSpaces } spaceOptionT; + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option); +spaceOptionT GetScannerSpaceOption(scannerADT scanner); + +#endif diff --git a/fftma_module/gen/lib_src/simpio.c b/fftma_module/gen/lib_src/simpio.c new file mode 100755 index 0000000..02e4025 --- /dev/null +++ b/fftma_module/gen/lib_src/simpio.c @@ -0,0 +1,157 @@ +/* + * File: simpio.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the simpio.h interface. + */ + +#include +#include + +#include "genlib.h" +#include "strlib.h" +#include "simpio.h" + +/* + * Constants: + * ---------- + * InitialBufferSize -- Initial buffer size for ReadLine + */ + +#define InitialBufferSize 120 + +/* Exported entries */ + +/* + * Functions: GetInteger, GetLong, GetReal + * --------------------------------------- + * These functions first read a line and then call sscanf to + * translate the number. Reading an entire line is essential to + * good error recovery, because the characters after the point of + * error would otherwise remain in the input buffer and confuse + * subsequent input operations. The sscanf line allows white space + * before and after the number but no other extraneous characters. + */ + +int GetInteger(void) +{ + string line; + int value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %d %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +long GetLong(void) +{ + string line; + long value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %ld %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +double GetReal(void) +{ + string line; + double value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %lf %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter a real number\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +/* + * Function: GetLine + * ----------------- + * This function is a simple wrapper; all the work is done by + * ReadLine. + */ + +string GetLine(void) +{ + return (ReadLine(stdin)); +} + +/* + * Function: ReadLine + * ------------------ + * This function operates by reading characters from the file + * into a dynamically allocated buffer. If the buffer becomes + * full before the end of the line is reached, a new buffer + * twice the size of the previous one is allocated. + */ + +string ReadLine(FILE *infile) +{ + string line, nline; + int n, ch, size; + + n = 0; + size = InitialBufferSize; + line = GetBlock(size + 1); + while ((ch = getc(infile)) != '\n' && ch != EOF) { + if (n == size) { + size *= 2; + nline = (string) GetBlock(size + 1); + strncpy(nline, line, n); + FreeBlock(line); + line = nline; + } + line[n++] = ch; + } + if (n == 0 && ch == EOF) { + FreeBlock(line); + return (NULL); + } + line[n] = '\0'; + nline = (string) GetBlock(n + 1); + strcpy(nline, line); + FreeBlock(line); + return (nline); +} diff --git a/fftma_module/gen/lib_src/simpio.h b/fftma_module/gen/lib_src/simpio.h new file mode 100755 index 0000000..ca1efc9 --- /dev/null +++ b/fftma_module/gen/lib_src/simpio.h @@ -0,0 +1,75 @@ +/* + * File: simpio.h + * Version: 1.0 + * Last modified on Wed Apr 27 07:29:13 1994 by eroberts + * ----------------------------------------------------- + * This interface provides access to a simple package of + * functions that simplify the reading of input data. + */ + +#ifndef _simpio_h +#define _simpio_h + +#include "genlib.h" + +/* + * Function: GetInteger + * Usage: i = GetInteger(); + * ------------------------ + * GetInteger reads a line of text from standard input and scans + * it as an integer. The integer value is returned. If an + * integer cannot be scanned or if more characters follow the + * number, the user is given a chance to retry. + */ + +int GetInteger(void); + +/* + * Function: GetLong + * Usage: l = GetLong(); + * --------------------- + * GetLong reads a line of text from standard input and scans + * it as a long integer. The value is returned as a long. + * If an integer cannot be scanned or if more characters follow + * the number, the user is given a chance to retry. + */ + +long GetLong(void); + +/* + * Function: GetReal + * Usage: x = GetReal(); + * --------------------- + * GetReal reads a line of text from standard input and scans + * it as a double. If the number cannot be scanned or if extra + * characters follow after the number ends, the user is given + * a chance to reenter the value. + */ + +double GetReal(void); + +/* + * Function: GetLine + * Usage: s = GetLine(); + * --------------------- + * GetLine reads a line of text from standard input and returns + * the line as a string. The newline character that terminates + * the input is not stored as part of the string. + */ + +string GetLine(void); + +/* + * Function: ReadLine + * Usage: s = ReadLine(infile); + * ---------------------------- + * ReadLine reads a line of text from the input file and + * returns the line as a string. The newline character + * that terminates the input is not stored as part of the + * string. The ReadLine function returns NULL if infile + * is at the end-of-file position. + */ + +string ReadLine(FILE *infile); + +#endif diff --git a/fftma_module/gen/lib_src/spherical.c b/fftma_module/gen/lib_src/spherical.c new file mode 100755 index 0000000..a36e492 --- /dev/null +++ b/fftma_module/gen/lib_src/spherical.c @@ -0,0 +1,17 @@ +#include +#include +#include "genlib.h" + + +/*spherical covariance function*/ +double spherical(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-1.5*(double)h+0.5*(double)(h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/lib_src/stable.c b/fftma_module/gen/lib_src/stable.c new file mode 100755 index 0000000..45c5a29 --- /dev/null +++ b/fftma_module/gen/lib_src/stable.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*stable covariance function*/ +double stable(double h, double alpha) +{ + return(exp(-3.*(double)pow(h,alpha))); +} diff --git a/fftma_module/gen/lib_src/stack.c b/fftma_module/gen/lib_src/stack.c new file mode 100755 index 0000000..8bd5ee4 --- /dev/null +++ b/fftma_module/gen/lib_src/stack.c @@ -0,0 +1,122 @@ +/* + * File: stack.c + * ------------- + * This file implements the stack.h interface. Note that the + * implementation is independent of the type of value stored + * in the stack. That type is defined by the interface as + * the type name stackElementT. + */ + +#include +#include "genlib.h" +#include "stack.h" + +/* + * Constant: InitialStackSize + * -------------------------- + * This constant defines the initial size of the stack array. + * Any positive value will work correctly, although changing + * this parameter can affect performance. Making this value + * larger postpones the first reallocation but causes stacks + * to consume more memory. + */ + +#define InitialStackSize 100 + +/* + * Type: stackCDT + * -------------- + * The type stackCDT is the concrete representation of the type + * stackADT defined by the interface. In this implementation, + * the elements are stored in a dynamic array that doubles in + * size if the old stack becomes full. + */ + +struct stackCDT { + stackElementT *elements; + int count; + int size; +}; + +/* Private function prototypes */ + +static void ExpandStack(stackADT stack); + +/* Exported entries */ + +stackADT NewStack(void) +{ + stackADT stack; + + stack = New(stackADT); + stack->elements = NewArray(InitialStackSize, stackElementT); + stack->count = 0; + stack->size = InitialStackSize; + return (stack); +} + +void FreeStack(stackADT stack) +{ + FreeBlock(stack->elements); + FreeBlock(stack); +} + +void Push(stackADT stack, stackElementT element) +{ + if (stack->count == stack->size) ExpandStack(stack); + stack->elements[stack->count++] = element; +} + +stackElementT Pop(stackADT stack) +{ + if (StackIsEmpty(stack)) Error("Pop of an empty stack"); + return (stack->elements[--stack->count]); +} + +bool StackIsEmpty(stackADT stack) +{ + return (stack->count == 0); +} + +bool StackIsFull(stackADT stack) +{ + return (FALSE); +} + +int StackDepth(stackADT stack) +{ + return (stack->count); +} + +stackElementT GetStackElement(stackADT stack, int index) +{ + if (index < 0 || index >= stack->count) { + Error("Non-existent stack element"); + } + return (stack->elements[stack->count - index - 1]); +} + +/* Private functions */ + +/* Function: ExpandStack + * Usage: ExpandStack(stack); + * -------------------------- + * This function expands a full stack by doubling the size of its + * dynamic array, copying the old elements to the new array, and + * then freeing the old array storage. + */ + +static void ExpandStack(stackADT stack) +{ + stackElementT *array; + int i, newSize; + + newSize = stack->size * 2; + array = NewArray(newSize, stackElementT); + for (i = 0; i < stack->size; i++) { + array[i] = stack->elements[i]; + } + FreeBlock(stack->elements); + stack->elements = array; + stack->size = newSize; +} diff --git a/fftma_module/gen/lib_src/stack.h b/fftma_module/gen/lib_src/stack.h new file mode 100755 index 0000000..2f765d1 --- /dev/null +++ b/fftma_module/gen/lib_src/stack.h @@ -0,0 +1,115 @@ +/* + * File: stack.h + * ------------- + * This interface defines an abstraction for stacks. In any + * single application that uses this interface, the values in + * the stack are constrained to a single type, although it + * is easy to change that type by changing the definition of + * stackElementT in this interface. + */ + +#ifndef _stack_h +#define _stack_h + +#include "genlib.h" + +/* + * Type: stackElementT + * ------------------- + * The type stackElementT is used in this interface to indicate + * the type of values that can be stored in the stack. Here the + * stack is used to store values of type double, but that can + * be changed by editing this definition line. + */ + +typedef void *stackElementT; + +/* + * Type: stackADT + * -------------- + * The type stackADT represents the abstract type used to store + * the elements that have been pushed. Because stackADT is + * defined only as a pointer to a concrete structure that is not + * itself defined in the interface, clients have no access to + * the underlying fields. + */ + +typedef struct stackCDT *stackADT; + +/* + * Function: NewStack + * Usage: stack = NewStack(); + * -------------------------- + * This function allocates and returns a new stack, which is + * initially empty. + */ + +stackADT NewStack(void); + +/* + * Function: FreeStack + * Usage: FreeStack(stack); + * ------------------------ + * This function frees the storage associated with the stack. + */ + +void FreeStack(stackADT stack); + +/* + * Function: Push + * Usage: Push(stack, element); + * ---------------------------- + * This function pushes the specified element onto the stack. + */ + +void Push(stackADT stack, stackElementT element); + +/* + * Function: Pop + * Usage: element = Pop(stack); + * ---------------------------- + * This function pops the top element from the stack and returns + * that value. The first value popped is always the last one + * that was pushed. If the stack is empty when Pop is called, + * the function calls Error with an appropriate message. + */ + +stackElementT Pop(stackADT stack); + +/* + * Functions: StackIsEmpty, StackIsFull + * Usage: if (StackIsEmpty(stack)) . . . + * if (StackIsFull(stack)) . . . + * ------------------------------------- + * This functions test whether the stack is empty or full. + */ + +bool StackIsEmpty(stackADT stack); +bool StackIsFull(stackADT stack); + +/* + * Function: StackDepth + * Usage: depth = StackDepth(stack); + * --------------------------------- + * This function returns the number of elements currently pushed + * on the stack. + */ + +int StackDepth(stackADT stack); + +/* + * Function: GetStackElement + * Usage: element = GetStackElement(stack, index); + * ----------------------------------------------- + * This function returns the element at the specified index in + * the stack, where the top of the stack is defined as index 0. + * For example, calling GetStackElement(stack, 0) returns the top + * element on the stack without removing it. If the caller tries + * to select an out-of-range element, GetStackElement calls Error. + * Note: This function is not a fundamental stack operation and + * is instead provided principally to facilitate debugging. + */ + +stackElementT GetStackElement(stackADT stack, int index); + +#endif diff --git a/fftma_module/gen/lib_src/strlib.c b/fftma_module/gen/lib_src/strlib.c new file mode 100755 index 0000000..6f00938 --- /dev/null +++ b/fftma_module/gen/lib_src/strlib.c @@ -0,0 +1,246 @@ +/* + * File: strlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the strlib.h interface. + */ + +/* + * General implementation notes: + * ----------------------------- + * This module implements the strlib library by mapping all + * functions into the appropriate calls to the ANSI + * interface. The implementations of the individual functions + * are all quite simple and do not require individual comments. + * For descriptions of the behavior of each function, see the + * interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "strlib.h" + +/* + * Constant: MaxDigits + * ------------------- + * This constant must be larger than the maximum + * number of digits that can appear in a number. + */ + +#define MaxDigits 30 + +/* Private function prototypes */ + +static string CreateString(int len); + +/* Section 1 -- Basic string operations */ + +string Concat(string s1, string s2) +{ + string s; + int len1, len2; + + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to Concat"); + } + len1 = strlen(s1); + len2 = strlen(s2); + s = CreateString(len1 + len2); + strcpy(s, s1); + strcpy(s + len1, s2); + return (s); +} + +char IthChar(string s, int i) +{ + int len; + + if (s == NULL) Error("NULL string passed to IthChar"); + len = strlen(s); + if (i < 0 || i > len) { + Error("Index outside of string range in IthChar"); + } + return (s[i]); +} + +string SubString(string s, int p1, int p2) +{ + int len; + string result; + + if (s == NULL) Error("NULL string passed to SubString"); + len = strlen(s); + if (p1 < 0) p1 = 0; + if (p2 >= len) p2 = len - 1; + len = p2 - p1 + 1; + if (len < 0) len = 0; + result = CreateString(len); + strncpy(result, s + p1, len); + result[len] = '\0'; + return (result); +} + +string CharToString(char ch) +{ + string result; + + result = CreateString(1); + result[0] = ch; + result[1] = '\0'; + return (result); +} + +int StringLength(string s) +{ + if (s == NULL) Error("NULL string passed to StringLength"); + return (strlen(s)); +} + +string CopyString(string s) +{ + string newstr; + + if (s == NULL) Error("NULL string passed to CopyString"); + newstr = CreateString(strlen(s)); + strcpy(newstr, s); + return (newstr); +} + +/* Section 2 -- String comparison functions */ + +bool StringEqual(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringEqual"); + } + return (strcmp(s1, s2) == 0); +} + +int StringCompare(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringCompare"); + } + return (strcmp(s1, s2)); +} + +/* Section 3 -- Search functions */ + +int FindChar(char ch, string text, int start) +{ + char *cptr; + + if (text == NULL) Error("NULL string passed to FindChar"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strchr(text + start, ch); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +int FindString(string str, string text, int start) +{ + char *cptr; + + if (str == NULL) Error("NULL pattern string in FindString"); + if (text == NULL) Error("NULL text string in FindString"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strstr(text + start, str); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +/* Section 4 -- Case-conversion functions */ + +string ConvertToLowerCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToLowerCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = tolower(s[i]); + result[i] = '\0'; + return (result); +} + +string ConvertToUpperCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToUpperCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = toupper(s[i]); + result[i] = '\0'; + return (result); +} + +/* Section 5 -- Functions for converting numbers to strings */ + +string IntegerToString(int n) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%d", n); + return (CopyString(buffer)); +} + +int StringToInteger(string s) +{ + int result; + char dummy; + + if (s == NULL) { + Error("NULL string passed to StringToInteger"); + } + if (sscanf(s, " %d %c", &result, &dummy) != 1) { + Error("StringToInteger called on illegal number %s", s); + } + return (result); +} + +string RealToString(double d) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%G", d); + return (CopyString(buffer)); +} + +double StringToReal(string s) +{ + double result; + char dummy; + + if (s == NULL) Error("NULL string passed to StringToReal"); + if (sscanf(s, " %lg %c", &result, &dummy) != 1) { + Error("StringToReal called on illegal number %s", s); + } + return (result); +} + +/* Private functions */ + +/* + * Function: CreateString + * Usage: s = CreateString(len); + * ----------------------------- + * This function dynamically allocates space for a string of + * len characters, leaving room for the null character at the + * end. + */ + +static string CreateString(int len) +{ + return ((string) GetBlock(len + 1)); +} diff --git a/fftma_module/gen/lib_src/strlib.h b/fftma_module/gen/lib_src/strlib.h new file mode 100755 index 0000000..796d1d4 --- /dev/null +++ b/fftma_module/gen/lib_src/strlib.h @@ -0,0 +1,243 @@ +/* + * File: strlib.h + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:40 1994 by eroberts + * ----------------------------------------------------- + * The strlib.h file defines the interface for a simple + * string library. In the context of this package, strings + * are considered to be an abstract data type, which means + * that the client relies only on the operations defined for + * the type and not on the underlying representation. + */ + +/* + * Cautionary note: + * ---------------- + * Although this interface provides an extremely convenient + * abstraction for working with strings, it is not appropriate + * for all applications. In this interface, the functions that + * return string values (such as Concat and SubString) do so + * by allocating new memory. Over time, a program that uses + * this package will consume increasing amounts of memory + * and eventually exhaust the available supply. If you are + * writing a program that runs for a short time and stops, + * the fact that the package consumes memory is not a problem. + * If, however, you are writing an application that must run + * for an extended period of time, using this package requires + * that you make some provision for freeing any allocated + * storage. + */ + +#ifndef _strlib_h +#define _strlib_h + +#include "genlib.h" + +/* Section 1 -- Basic string operations */ + +/* + * Function: Concat + * Usage: s = Concat(s1, s2); + * -------------------------- + * This function concatenates two strings by joining them end + * to end. For example, Concat("ABC", "DE") returns the string + * "ABCDE". + */ + +string Concat(string s1, string s2); + +/* + * Function: IthChar + * Usage: ch = IthChar(s, i); + * -------------------------- + * This function returns the character at position i in the + * string s. It is included in the library to make the type + * string a true abstract type in the sense that all of the + * necessary operations can be invoked using functions. Calling + * IthChar(s, i) is like selecting s[i], except that IthChar + * checks to see if i is within the range of legal index + * positions, which extend from 0 to StringLength(s). + * IthChar(s, StringLength(s)) returns the null character + * at the end of the string. + */ + +char IthChar(string s, int i); + +/* + * Function: SubString + * Usage: t = SubString(s, p1, p2); + * -------------------------------- + * SubString returns a copy of the substring of s consisting + * of the characters between index positions p1 and p2, + * inclusive. The following special cases apply: + * + * 1. If p1 is less than 0, it is assumed to be 0. + * 2. If p2 is greater than the index of the last string + * position, which is StringLength(s) - 1, then p2 is + * set equal to StringLength(s) - 1. + * 3. If p2 < p1, SubString returns the empty string. + */ + +string SubString(string s, int p1, int p2); + +/* + * Function: CharToString + * Usage: s = CharToString(ch); + * ---------------------------- + * This function takes a single character and returns a + * one-character string consisting of that character. The + * CharToString function is useful, for example, if you + * need to concatenate a string and a character. Since + * Concat requires two strings, you must first convert + * the character into a string. + */ + +string CharToString(char ch); + +/* + * Function: StringLength + * Usage: len = StringLength(s); + * ----------------------------- + * This function returns the length of s. + */ + +int StringLength(string s); + +/* + * Function: CopyString + * Usage: newstr = CopyString(s); + * ------------------------------ + * CopyString copies the string s into dynamically allocated + * storage and returns the new string. This function is not + * ordinarily required if this package is used on its own, + * but is often necessary when you are working with more than + * one string package. + */ + +string CopyString(string s); + +/* Section 2 -- String comparison functions */ + +/* + * Function: StringEqual + * Usage: if (StringEqual(s1, s2)) ... + * ----------------------------------- + * This function returns TRUE if the strings s1 and s2 are + * equal. For the strings to be considered equal, every + * character in one string must precisely match the + * corresponding character in the other. Uppercase and + * lowercase characters are considered to be different. + */ + +bool StringEqual(string s1, string s2); + +/* + * Function: StringCompare + * Usage: if (StringCompare(s1, s2) < 0) ... + * ----------------------------------------- + * This function returns a number less than 0 if string s1 + * comes before s2 in alphabetical order, 0 if they are equal, + * and a number greater than 0 if s1 comes after s2. The + * ordering is determined by the internal representation used + * for characters, which is usually ASCII. + */ + +int StringCompare(string s1, string s2); + +/* Section 3 -- Search functions */ + +/* + * Function: FindChar + * Usage: p = FindChar(ch, text, start); + * ------------------------------------- + * Beginning at position start in the string text, this + * function searches for the character ch and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindChar(char ch, string text, int start); + +/* + * Function: FindString + * Usage: p = FindString(str, text, start); + * ---------------------------------------- + * Beginning at position start in the string text, this + * function searches for the string str and returns the + * first index at which it appears or -1 if no match is + * found. + */ + +int FindString(string str, string text, int start); + +/* Section 4 -- Case-conversion functions */ + +/* + * Function: ConvertToLowerCase + * Usage: s = ConvertToLowerCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to lower case. + */ + +string ConvertToLowerCase(string s); + +/* + * Function: ConvertToUpperCase + * Usage: s = ConvertToUpperCase(s); + * --------------------------------- + * This function returns a new string with all + * alphabetic characters converted to upper case. + */ + +string ConvertToUpperCase(string s); + +/* Section 5 -- Functions for converting numbers to strings */ + +/* + * Function: IntegerToString + * Usage: s = IntegerToString(n); + * ------------------------------ + * This function converts an integer into the corresponding + * string of digits. For example, IntegerToString(123) + * returns "123" as a string. + */ + +string IntegerToString(int n); + +/* + * Function: StringToInteger + * Usage: n = StringToInteger(s); + * ------------------------------ + * This function converts a string of digits into an integer. + * If the string is not a legal integer or contains extraneous + * characters, StringToInteger signals an error condition. + */ + +int StringToInteger(string s); + +/* + * Function: RealToString + * Usage: s = RealToString(d); + * --------------------------- + * This function converts a floating-point number into the + * corresponding string form. For example, calling + * RealToString(23.45) returns "23.45". The conversion is + * the same as that used for "%G" format in printf. + */ + +string RealToString(double d); + +/* + * Function: StringToReal + * Usage: d = StringToReal(s); + * --------------------------- + * This function converts a string representing a real number + * into its corresponding value. If the string is not a + * legal floating-point number or if it contains extraneous + * characters, StringToReal signals an error condition. + */ + +double StringToReal(string s); + +#endif diff --git a/fftma_module/gen/lib_src/symtab.c b/fftma_module/gen/lib_src/symtab.c new file mode 100755 index 0000000..6e27a10 --- /dev/null +++ b/fftma_module/gen/lib_src/symtab.c @@ -0,0 +1,180 @@ +/* + * File: symtab.c + * -------------- + * This file implements the symbol table abstraction. + */ + +#include +#include "genlib.h" +#include "strlib.h" +#include "symtab.h" + +/* + * Constants + * --------- + * NBuckets -- Number of buckets in the hash table + */ + +#define NBuckets 101 + +/* + * Type: cellT + * ----------- + * This type defines a linked list cell for the symbol table. + */ + +typedef struct cellT { + string key; + void *value; + struct cellT *link; +} cellT; + +/* + * Type: symtabCDT + * --------------- + * This type defines the underlying concrete representation for a + * symtabADT. These details are not relevant to and therefore + * not exported to the client. In this implementation, the + * underlying structure is a hash table organized as an array of + * "buckets," in which each bucket is a linked list of elements + * that share the same hash code. + */ + +struct symtabCDT { + cellT *buckets[NBuckets]; +}; + +/* Private function declarations */ + +static void FreeBucketChain(cellT *cp); +static cellT *FindCell(cellT *cp, string s); +static int Hash(string s, int nBuckets); + +/* Public entries */ + +symtabADT NewSymbolTable(void) +{ + symtabADT table; + int i; + + table = New(symtabADT); + for (i = 0; i < NBuckets; i++) { + table->buckets[i] = NULL; + } + return (table); +} + +void FreeSymbolTable(symtabADT table) +{ + int i; + + for (i = 0; i < NBuckets; i++) { + FreeBucketChain(table->buckets[i]); + } + FreeBlock(table); +} + +void Enter(symtabADT table, string key, void *value) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) { + cp = New(cellT *); + cp->key = CopyString(key); + cp->link = table->buckets[bucket]; + table->buckets[bucket] = cp; + } + cp->value = value; +} + +void *Lookup(symtabADT table, string key) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) return(UNDEFINED); + return (cp->value); +} + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData) +{ + int i; + cellT *cp; + + for (i = 0; i < NBuckets; i++) { + for (cp = table->buckets[i]; cp != NULL; cp = cp->link) { + fn(cp->key, cp->value, clientData); + } + } +} + +/* Private functions */ + +/* + * Function: FreeBucketChain + * Usage: FreeBucketChain(cp); + * --------------------------- + * This function takes a chain pointer and frees all the cells + * in that chain. Because the package makes copies of the keys, + * this function must free the string storage as well. + */ + +static void FreeBucketChain(cellT *cp) +{ + cellT *next; + + while (cp != NULL) { + next = cp->link; + FreeBlock(cp->key); + FreeBlock(cp); + cp = next; + } +} + +/* + * Function: FindCell + * Usage: cp = FindCell(cp, key); + * ------------------------------ + * This function finds a cell in the chain beginning at cp that + * matches key. If a match is found, a pointer to that cell is + * returned. If no match is found, the function returns NULL. + */ + +static cellT *FindCell(cellT *cp, string key) +{ + while (cp != NULL && !StringEqual(cp->key, key)) { + cp = cp->link; + } + return (cp); +} + +/* + * Function: Hash + * Usage: bucket = Hash(key, nBuckets); + * ------------------------------------ + * This function takes the key and uses it to derive a hash code, + * which is an integer in the range [0, nBuckets - 1]. The hash + * code is computed using a method called linear congruence. The + * choice of the value for Multiplier can have a significant effect + * on the performance of the algorithm, but not on its correctness. + */ + +#define Multiplier -1664117991L + +static int Hash(string s, int nBuckets) +{ + int i; + unsigned long hashcode; + + hashcode = 0; + for (i = 0; s[i] != '\0'; i++) { + hashcode = hashcode * Multiplier + s[i]; + } + return (hashcode % nBuckets); +} diff --git a/fftma_module/gen/lib_src/symtab.h b/fftma_module/gen/lib_src/symtab.h new file mode 100755 index 0000000..c83c307 --- /dev/null +++ b/fftma_module/gen/lib_src/symtab.h @@ -0,0 +1,85 @@ +/* + * File: symtab.h + * -------------- + * This interface exports a simple symbol table abstraction. + */ + +#ifndef _symtab_h +#define _symtab_h + +#include "genlib.h" + +/* + * Type: symtabADT + * --------------- + * This type is the ADT used to represent a symbol table. + */ + +typedef struct symtabCDT *symtabADT; + +/* + * Type: symtabFnT + * --------------- + * This type defines the class of functions that can be used to + * map over the entries in a symbol table. + */ + +typedef void (*symtabFnT)(string key, void *value, + void *clientData); + +/* Exported entries */ + +/* + * Function: NewSymbolTable + * Usage: table = NewSymbolTable(); + * -------------------------------- + * This function allocates a new symbol table with no entries. + */ + +symtabADT NewSymbolTable(void); + +/* + * Function: FreeSymbolTable + * Usage: FreeSymbolTable(table); + * ------------------------------ + * This function frees the storage associated with the symbol table. + */ + +void FreeSymbolTable(symtabADT table); + +/* + * Function: Enter + * Usage: Enter(table, key, value); + * -------------------------------- + * This function associates key with value in the symbol table. + * Each call to Enter supersedes any previous definition for key. + */ + +void Enter(symtabADT table, string key, void *value); + +/* + * Function: Lookup + * Usage: value = Lookup(table, key); + * ---------------------------------- + * This function returns the value associated with key in the symbol + * table, or UNDEFINED, if no such value exists. + */ + +void *Lookup(symtabADT table, string key); + +/* + * Function: MapSymbolTable + * Usage: MapSymbolTable(fn, table, clientData); + * --------------------------------------------- + * This function goes through every entry in the symbol table + * and calls the function fn, passing it the following arguments: + * the current key, its associated value, and the clientData + * pointer. The clientData pointer allows the client to pass + * additional state information to the function fn, if necessary. + * If no clientData argument is required, this value should be NULL. + */ + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData); + +#endif diff --git a/fftma_module/gen/lib_src/test_fact.c b/fftma_module/gen/lib_src/test_fact.c new file mode 100755 index 0000000..d2456ee --- /dev/null +++ b/fftma_module/gen/lib_src/test_fact.c @@ -0,0 +1,26 @@ +#include "genlib.h" + +/*tries factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac) +{ + int power, t; + + power = 0; + while ( ( t = *pnum / fact ) * fact == *pnum ) { + ++power; + *pnum = t; + } + + if ( power != 0 ) { + if (fact > *pmaxfac) + *pmaxfac = fact; + } + + if ( t > fact ) { + return (1); + } + + return (0); +} + + diff --git a/fftma_module/gen/lib_src/testmemory.c b/fftma_module/gen/lib_src/testmemory.c new file mode 100755 index 0000000..7cbd10e --- /dev/null +++ b/fftma_module/gen/lib_src/testmemory.c @@ -0,0 +1,15 @@ +#include +#include +#include +#include +#include +#include + +void testmemory(double *realint) +{ + if (realint == NULL) { + printf("Testmemory.c: No memory available \n"); + exit; + } + return; +} diff --git a/fftma_module/gen/lib_src/testopenfile.c b/fftma_module/gen/lib_src/testopenfile.c new file mode 100755 index 0000000..dee13a8 --- /dev/null +++ b/fftma_module/gen/lib_src/testopenfile.c @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include + +void testopenfile(FILE *fp) +{ + if (fp == NULL) + { + printf("Erreur d'ouverture de fichier\n"); + exit(0); + } + return; +} diff --git a/fftma_module/gen/lib_src/toolsFFTMA.h b/fftma_module/gen/lib_src/toolsFFTMA.h new file mode 100755 index 0000000..32d5535 --- /dev/null +++ b/fftma_module/gen/lib_src/toolsFFTMA.h @@ -0,0 +1,82 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +#ifndef _TOOLSFFTMA_H +#define _TOOLSFFTMA_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* kgeneration, FFTMA2, prebuild_gwn, build_real, addstat2, clean_real */ + + +/*FUNCTIONS*/ +/*----------*/ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y2, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise); + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) ; + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout); + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver); + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal); + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2); + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout); + +#endif // define _TOOLSFFTMA_H diff --git a/fftma_module/gen/lib_src/toolsFFTPSIM.h b/fftma_module/gen/lib_src/toolsFFTPSIM.h new file mode 100755 index 0000000..41fd3e3 --- /dev/null +++ b/fftma_module/gen/lib_src/toolsFFTPSIM.h @@ -0,0 +1,59 @@ +#include +#include "geostat.h" +#include "pressure.h" + + +#ifndef _TOOLSFFTPSIM_H +#define _TOOLSFFTPSIM_H + +/* Create december, the 16th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* pgeneration, FFTPSim, FFTPressure, build_pressure, build_velocity,total_pressure,total_velocity, clean_real2 */ + +/*Functions */ +/*----------*/ + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver); + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[8],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file); + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5); + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4, int solver); + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure); + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction); + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression:: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout); + +/* total_velocity */ +/* Build total velocity in one direction */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout); + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout); + +void normAxes(double *vec, double *normed); +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*float dX, float dY, float dZ,*/ double nDir[3], double *waveVect); + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario); + +void mat_vec(double *C, double *x, double *b, int n); + + +#endif // define _TOOLSFFTPSIM_H diff --git a/fftma_module/gen/lib_src/toolsIO.h b/fftma_module/gen/lib_src/toolsIO.h new file mode 100755 index 0000000..e6a6eb9 --- /dev/null +++ b/fftma_module/gen/lib_src/toolsIO.h @@ -0,0 +1,93 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "pressure.h" + +#ifndef _TOOLSIO_H +#define _TOOLSIO_H + +/* Create december, the 16th 2002 */ +/* Modified december, the 9th 2002 */ + +/* List of functions: */ +/* ------------------ */ +/* writefile,writefile_bin,readfile_bin,inputdata,inputfiledata,readdata,debuginput */ +/* testmemory, testopenfile */ + + +/*FUNCTIONS*/ +/*----------*/ + +/* Lecture dans un fichier */ + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression); + +/* void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,struct realization_mod *Kfield, char *argv[]); */ + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]); + +/* readfile_bin */ +/* */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin); + + +/* Writefile */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile( string filename, struct realization_mod *realin); + +/* Writefile_bin */ +/* */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin( string filename, struct realization_mod *realin); + + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ +void debuginput(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite); + +/* Allocation test */ +void testmemory(double *realint); + +/* Test open file */ +void testopenfile(FILE *fp); + +#endif // define _TOOLSIO_H diff --git a/fftma_module/gen/lib_src/total_pressure.c b/fftma_module/gen/lib_src/total_pressure.c new file mode 100755 index 0000000..24135c1 --- /dev/null +++ b/fftma_module/gen/lib_src/total_pressure.c @@ -0,0 +1,35 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,reference; + + reference=abs(gradient.x)*grid.NX*grid.DX+abs(gradient.y)*grid.NY*grid.DY+abs(gradient.z)*grid.NZ*grid.DZ; + /* pressure reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; +/* temp=reference+gradient.x*i*grid.DX+gradient.y*j*grid.DY+gradient.z*k*grid.DZ+(*realout).vector[maille1]; */ + temp=-gradient.x*(i+1)/grid.NX-gradient.y*(j+1)/grid.NY-gradient.z*(k+1)/grid.NZ+(*realout).vector[maille1]; + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/lib_src/total_velocity.c b/fftma_module/gen/lib_src/total_velocity.c new file mode 100755 index 0000000..63344c1 --- /dev/null +++ b/fftma_module/gen/lib_src/total_velocity.c @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_velocity */ +/* Build total velocity */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,grad; + switch(direction) + { + case 1: + grad = gradient.x/(grid.NX*grid.DX); + break; + case 2: + grad = gradient.y/(grid.NY*grid.DY);/* *grid.NY*grid.DY; */ + break; + case 3: + grad = gradient.z/(grid.NZ*grid.DZ); /* *grid.NZ*grid.DZ; */ + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + /* x velocity reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; + temp=mean*grad+(*realout).vector[maille1]; +/* temp=mean*grad; */ + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/lib_src/waveVectorCompute3D.c b/fftma_module/gen/lib_src/waveVectorCompute3D.c new file mode 100755 index 0000000..58e8342 --- /dev/null +++ b/fftma_module/gen/lib_src/waveVectorCompute3D.c @@ -0,0 +1,156 @@ +//#include +//#include +#include +#include +#include +#include +#include +#include + +//using namespace std; + +/*Private functions */ +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*double dX, double dY, double dZ,*/ double nDir[3], double *waveVect) { + + int nTot; + double *vecX,*vecY,*vecZ; + double *waveVect3DX, *waveVect3DY, *waveVect3DZ; + + int i, j, k, maille; + + nTot = nX*nY*nZ; +// printf("nX = %d, nY = %d, nZ = %d, nTot = %d\n",nX,nY,nZ,nTot); +// printf("Entering waveVectorCompute3D\n"); + +/*Memory allocation */ + waveVect3DX = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DX == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DX\n"); + return; + } + waveVect3DY = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DY == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DY\n"); + return; + } + waveVect3DZ = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DZ == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DZ\n"); + return; + } + + vecX = (double *)malloc(nX * sizeof(double)); + if (vecX == NULL) { + printf("waveVectCompute.cpp : No memory available for vecX\n"); + return; + } + + vecY = (double *)malloc(nY * sizeof(double)); + if (vecY == NULL) { + printf("waveVectCompute.cpp : No memory available for vecY\n"); + return; + } + + vecZ = (double *)malloc(nZ * sizeof(double)); + if (vecZ == NULL) { + printf("waveVectCompute.cpp : No memory available for vecZ\n"); + return; + } + +// printf("memory allocation done.\n"); + + waveVectorCompute1D(nX,vecX); + waveVectorCompute1D(nY,vecY); + waveVectorCompute1D(nZ,vecZ); +// printf("waveVectorCompute1D: done!\n"); + + for(k = 0; k < nZ; k++) { +// printf("k=%d\n",k); + for(j = 0; j < nY; j++) { +// printf("j=%d: ",j); + for(i = 0; i < nX; i++) { + maille = i + (j + (k)*nY)*nX; +// waveVect3DX[maille] = vecX[i]/(nX*dX); +// waveVect3DY[maille] = vecY[j]/(nY*dY); +// waveVect3DZ[maille] = vecZ[k]/(nZ*dZ); + waveVect3DX[maille] = vecX[i]; + waveVect3DY[maille] = vecY[j]; + waveVect3DZ[maille] = vecZ[k]; +// printf("i=%d: %f ",i,vecZ[k]); + } +// printf("\n"); + } + } +// printf("waveVector3DX, Y and Z rearanged\n"); + free(vecX); + free(vecY); + free(vecZ); + if (waveVect == NULL) { + printf("allocate memory for waveVect\n"); + waveVect = (double *) malloc((nTot+1)*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + printf("after allocate memory for waveVect\n"); + } + + for (i=1;i<=nTot;i++) { + waveVect[i] = nDir[0]*waveVect3DX[i-1] + nDir[1]*waveVect3DY[i-1] + nDir[2]*waveVect3DZ[i-1]; +// printf("waveVect[%d] = %f\n",i,waveVect[i]); + } +// printf("waveVector rearanged\n"); + + free(waveVect3DX); + free(waveVect3DY); + free(waveVect3DZ); + +} + +void waveVectorCompute1D(int n,double *vec){ + + int midPoint,k; + + if(ceil(n/2) - floor(n/2) < 1.) { +// printf("coucou\n"); +/*n is even */ + midPoint = (int) floor(n/2); + vec[midPoint] = (double) midPoint; + } else { +/*n is odd */ + midPoint = (int) floor(n/2)-1; + vec[midPoint] = (double) midPoint+1; + } + for (k=1;k +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + /* string filename;*/ + /*struct realization_mod *realin;*/ + + + /*save the permeability realization*/ + fp = fopen(filename, "w"); +/* printf("writefile.c : (*realin).vector[0] %f\n",(*realin).vector[0]); */ +/* (*realin).vector[0]=1.1; */ + for (i=0;i<(*realin).n;i++) + fprintf(fp,"%15.10f\n",(*realin).vector[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/lib_src/writefile_bin.c b/fftma_module/gen/lib_src/writefile_bin.c new file mode 100755 index 0000000..8df2da8 --- /dev/null +++ b/fftma_module/gen/lib_src/writefile_bin.c @@ -0,0 +1,33 @@ +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double *prout; + + /*save the permeability realization*/ + fp = fopen(filename, "w"); + + for (i=0;i<(*realin).n;i++) + { + prout=(*realin).vector; + fwrite(&prout[i],sizeof(double),1,fp); + } + + fclose(fp); + return; +} diff --git a/fftma_module/gen/moduleFFTMA.c b/fftma_module/gen/moduleFFTMA.c new file mode 100755 index 0000000..b68dfd2 --- /dev/null +++ b/fftma_module/gen/moduleFFTMA.c @@ -0,0 +1,75 @@ +#include +#include +#include +#include +#include +#include +#include +#include +#include "Py_py-api.h" +#include "genlib.h" +#include "simpio.h" +#include "condor.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" +#include "pressure.h" +#include "toolsFFTPSIM.h" +#define NDIMENSIONS 3 + +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +static PyObject* genFunc(PyObject* self, PyObject* args) +{ + int n[3]; + struct realization_mod Z,Y,Y1; + struct grid_mod grid; + struct vario_mod variogram; + long seed; + struct statistic_mod stat; + PyObject* out_array; + npy_intp out_dims[NPY_MAXDIMS]; + + + if(!Py_getvalues(args, &seed, &grid, &variogram, &stat)) return NULL; + Py_kgeneration(seed,grid,stat,variogram,&Z,&Y,&Y1,n); + + out_dims[0]=grid.NZ; + out_dims[1]=grid.NY; + out_dims[2]=grid.NX; + + + + out_array = PyArray_SimpleNewFromData(NDIMENSIONS,out_dims,NPY_DOUBLE,Y.vector); + if (out_array == NULL) + return NULL; + + PyArray_ENABLEFLAGS(out_array, NPY_ARRAY_OWNDATA); + + return out_array; + +} + + +static PyMethodDef FFTMAMethods[]= +{ + {"gen", genFunc, METH_VARARGS, "Generates a permeability 3D field."}, + {NULL, NULL, 0, NULL} +}; + +static struct PyModuleDef cFFTMADef = +{ + PyModuleDef_HEAD_INIT, + "FFTMA", "", + -1, + FFTMAMethods +}; + +PyMODINIT_FUNC +PyInit_FFTMA(void) +{ + import_array(); + return PyModule_Create(&cFFTMADef); +} diff --git a/fftma_module/gen/setup.py b/fftma_module/gen/setup.py new file mode 100644 index 0000000..57b742c --- /dev/null +++ b/fftma_module/gen/setup.py @@ -0,0 +1,10 @@ +from distutils.core import setup, Extension + + +module_FFTMA = Extension('FFTMA', include_dirs = ['./include'],sources=["moduleFFTMA.c","./lib_src/Py_getvalues.c","./lib_src/Py_kgeneration.c","./lib_src/genlib.c","./lib_src/random.c","./lib_src/simpio.c","./lib_src/strlib.c","./lib_src/symtab.c","./lib_src/scanadt.c","./lib_src/stack.c","./lib_src/gammf.c","./lib_src/fftma.c","./lib_src/addstat.c","./lib_src/axes.c","./lib_src/cgrid.c","./lib_src/covariance.c","./lib_src/fourt.c","./lib_src/length.c","./lib_src/maxfactor.c","./lib_src/test_fact.c","./lib_src/cov_value.c","./lib_src/generate.c","./lib_src/gasdev.c","./lib_src/ran2.c","./lib_src/stable.c","./lib_src/gaussian.c","./lib_src/power.c","./lib_src/cubic.c","./lib_src/spherical.c","./lib_src/nugget.c","./lib_src/exponential.c","./lib_src/cardsin.c","./lib_src/nor2log.c","./lib_src/kgeneration.c","./lib_src/kgeneration2.c","./lib_src/fftma2.c","./lib_src/prebuild_gwn.c","./lib_src/build_real.c","./lib_src/addstat2.c","./lib_src/clean_real.c","./lib_src/pgeneration.c","./lib_src/pgeneration2.c","./lib_src/FFTPressure.c","./lib_src/FFTtest.c","./lib_src/build_pressure.c","./lib_src/build_velocity.c","./lib_src/total_pressure.c","./lib_src/total_velocity.c","./lib_src/clean_real2.c","./lib_src/waveVectorCompute3D.c","./lib_src/mat_vec.c","./lib_src/derivReal.c","./lib_src/inputdata.c","./lib_src/inputfiledata.c","./lib_src/debuginput.c","./lib_src/readdata.c","./lib_src/readfile_bin.c","./lib_src/writefile.c","./lib_src/writefile_bin.c","./lib_src/testmemory.c","./lib_src/testopenfile.c","./lib_src/readdata3.c"]) + + + + + +setup(ext_modules=[module_FFTMA]) diff --git a/fftma_module/gen/sources/._.DS_Store b/fftma_module/gen/sources/._.DS_Store new file mode 100755 index 0000000..c9474ea Binary files /dev/null and b/fftma_module/gen/sources/._.DS_Store differ diff --git a/fftma_module/gen/sources/FFTMAmemoire.c b/fftma_module/gen/sources/FFTMAmemoire.c new file mode 100755 index 0000000..15d7f04 --- /dev/null +++ b/fftma_module/gen/sources/FFTMAmemoire.c @@ -0,0 +1,110 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + string variable; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); +/* testmemory(covar); */ + allouememoire(covar,'covar'); + + + + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/sources/FFTPSim.c b/fftma_module/gen/sources/FFTPSim.c new file mode 100755 index 0000000..0f65c29 --- /dev/null +++ b/fftma_module/gen/sources/FFTPSim.c @@ -0,0 +1,162 @@ +#include +#include +#include "geostat.h" +#include "toolsludo.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPSim(struct vario_mod variogram,struct statistic_mod stat,struct grid_mod grid,int n[3],struct realization_mod *realin,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,struct realization_mod *realout5) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *covar,*realization,*pressure; + double *icovar,*ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + icovar = (double *) malloc(ntot * sizeof(double)); + testmemory(icovar); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,icovar,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + + prebuild_gwn(grid,n,realin,realization); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real(realin,n,grid,realization,realout); + clean_real(realin,n,grid,pressure,realout2); + clean_real(realin,n,grid,xvelocity,realout3); + clean_real(realin,n,grid,yvelocity,realout4); + clean_real(realin,n,grid,zvelocity,realout5); + + free(realization); + free(pressure); + free(xvelocity); + free(yvelocity); + free(zvelocity); + + return; +} diff --git a/fftma_module/gen/sources/FFTPressure.c b/fftma_module/gen/sources/FFTPressure.c new file mode 100755 index 0000000..15ab392 --- /dev/null +++ b/fftma_module/gen/sources/FFTPressure.c @@ -0,0 +1,157 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + +/*FAST FOURIER TRANSFORM Pressure Simulation */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*gradient: macroscopic gradient pression vector */ +/*output: */ +/*realout: structure defining a realization - */ +/*realout2: structure defining a pressure field */ +/*realout3: structure defining a xvelocity field */ +/*realout4: structure defining a yvelocity field */ +/*realout5: structure defining a zvelocity field */ + + +void FFTPressure(int n[3],struct grid_mod grid,struct realization_mod *realin,struct statistic_mod stat,struct pressure_mod gradient,struct realization_mod *realout,struct realization_mod *realout2,struct realization_mod *realout3,struct realization_mod *realout4,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization,*pressure; + double *ireal,*ipressure; + double *xvelocity,*ixvelocity,*yvelocity,*iyvelocity,*zvelocity,*izvelocity; + double ki,kj,kk; + FILE *fp; +/* string nomfichier; */ + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + pressure = (double *) malloc(ntot * sizeof(double)); + testmemory(pressure); + + ipressure = (double *) malloc(ntot * sizeof(double)); + testmemory(ipressure); + + xvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(xvelocity); + + ixvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(ixvelocity); + + yvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(yvelocity); + + iyvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(iyvelocity); + + zvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(zvelocity); + + izvelocity = (double *) malloc(ntot * sizeof(double)); + testmemory(izvelocity); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* pressure calculation in the spectral domain*/ + + build_pressure(n,grid,gradient,realization,ireal,pressure,ipressure); + + build_velocity(n,grid,stat,gradient,realization,ireal,xvelocity,ixvelocity,1); + build_velocity(n,grid,stat,gradient,realization,ireal,yvelocity,iyvelocity,2); + build_velocity(n,grid,stat,gradient,realization,ireal,zvelocity,izvelocity,3); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + fourt(pressure,ipressure,n,NDIM,0,1,workr,worki); + fourt(xvelocity,ixvelocity,n,NDIM,0,1,workr,worki); + fourt(yvelocity,iyvelocity,n,NDIM,0,1,workr,worki); + fourt(zvelocity,izvelocity,n,NDIM,0,1,workr,worki); + + free(ireal); + free(ipressure); + free(ixvelocity); + free(iyvelocity); + free(izvelocity); + free(workr); + free(worki); + + for (i=1;i<=NTOT;i++) + realization[i]=realization[i]/(double) NTOT; + + fp = fopen("realization.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + +/* nomfichier="pression.test"; */ + fp = fopen("pression.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",pressure[i]); + fclose(fp); + + /*output realization*/ + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + clean_real2(realin,n,grid,solver,pressure,realout); + clean_real2(realin,n,grid,solver,xvelocity,realout2); + clean_real2(realin,n,grid,solver,yvelocity,realout3); + clean_real2(realin,n,grid,solver,zvelocity,realout4); + + /* free(realization); */ + /* free(pressure); */ + /* free(xvelocity); */ + /* free(yvelocity); */ + /* free(zvelocity); */ + + return; +} diff --git a/fftma_module/gen/sources/FFTtest.c b/fftma_module/gen/sources/FFTtest.c new file mode 100755 index 0000000..9f88ee0 --- /dev/null +++ b/fftma_module/gen/sources/FFTtest.c @@ -0,0 +1,68 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM Test */ + +void FFTtest(int n[3],struct grid_mod grid,struct realization_mod *realin,struct realization_mod *realout,int solver) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *workr,*worki,temp,temp2,coeff; + double *realization; + double *ireal; + double ki,kj,kk; + FILE *fp; + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*organization of the realization*/ + prebuild_gwn(grid,n,realin,realization,solver); + + fp = fopen("perm.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + fp = fopen("perm2.test", "w"); + for (i=1;i<=NTOT;i++) + fprintf(fp,"%f\n",realization[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/sources/addstat.c b/fftma_module/gen/sources/addstat.c new file mode 100755 index 0000000..ffcb781 --- /dev/null +++ b/fftma_module/gen/sources/addstat.c @@ -0,0 +1,106 @@ +#include +#include +#include "geostat.h" +#include "genlib.h" + + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ +void addstat(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + break; + case 6: + (*realout).code = 7; + break; + default: + (*realout).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + switch (stat.type) { + case 0: + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + break; + case 1: + /*lognormal (natural) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log(1.0+r); + break; + case 2: + /*lognormal (log10) case*/ + r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; + r *= r; + moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); + var = (double)log10(1.0+r); + break; + default: + Error("Type not defined in addstat"); + break; + } + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/sources/addstat2.c b/fftma_module/gen/sources/addstat2.c new file mode 100755 index 0000000..3096d0f --- /dev/null +++ b/fftma_module/gen/sources/addstat2.c @@ -0,0 +1,119 @@ +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*addstat */ +/*adds mean and variance effects to the N(0,1) realization*/ +/*input: */ +/*realin: structure defining a realization - */ +/* must have zeio mean and unit variance */ +/*stat: structure defining the mean and variance */ +/*output: */ +/*realout: structure defining a realization - */ + +void addstat2(struct realization_mod *realin,struct statistic_mod stat ,struct realization_mod *realout,struct realization_mod *realout2) + +{ + + int i,nblockm,nblockv; + double r,moy,var; + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + Error("No memory available"); + } + (*realout).n = (*realin).n; + + if ((*realout2).vector == NULL || (*realout2).n != (*realin).n) { + (*realout2).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout2).vector == NULL) + Error("No memory available"); + } + (*realout2).n = (*realin).n; + + + /*test over the input realization*/ + switch ((*realin).code) { + case 0: + case 1: + (*realout).code = 2; + (*realout2).code = 2; + break; + case 6: + (*realout).code = 7; + (*realout2).code = 7; + break; + default: + (*realout).code = (*realin).code; + (*realout2).code = (*realin).code; + break; + } + + for (i = 0; i < (*realin).n; i++) { + + + /*mean*/ + switch (stat.nblock_mean) { + case 1: + /*stationary case*/ + nblockm = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockm = i+1; + break; + } + + + /*variance*/ + switch (stat.nblock_var) { + case 1: + /*stationary case*/ + nblockv = 1; + break; + default: + /*number of the cell - nonstationary case*/ + nblockv = i+1; + break; + } + + + /* switch (stat.type) { */ +/* case 0: */ + + /*normal case*/ + moy = stat.mean[nblockm-1]; + var = stat.variance[nblockv-1]; + +/* break; */ +/* case 1: */ + /*lognormal (natural) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log(1.0+r); */ +/* break; */ +/* case 2: */ + /*lognormal (log10) case*/ +/* r = (double)sqrt(stat.variance[nblockv-1])/stat.mean[nblockm-1]; */ +/* r *= r; */ +/* moy = (double)log10(stat.mean[nblockm-1]/sqrt(1.0+r)); */ +/* var = (double)log10(1.0+r); */ +/* break; */ +/* default: */ +/* Error("Type not defined in addstat"); */ +/* break; */ +/* } */ + + + + (*realout).vector[i] = (double)sqrt(var)*(*realin).vector[i]; + (*realout2).vector[i] = (double)sqrt(var)*(*realin).vector[i]+moy; + } + + return; +} diff --git a/fftma_module/gen/sources/allouememoire.c b/fftma_module/gen/sources/allouememoire.c new file mode 100755 index 0000000..78f6975 --- /dev/null +++ b/fftma_module/gen/sources/allouememoire.c @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include + +void allouememoire(double *realint, string variable) +{ + + if (realint == NULL) { + printf("Testmemory.c: No memory available for %s\n",variable); + exit; + } + return; +} diff --git a/fftma_module/gen/sources/autoscan.log b/fftma_module/gen/sources/autoscan.log new file mode 100755 index 0000000..accbebb --- /dev/null +++ b/fftma_module/gen/sources/autoscan.log @@ -0,0 +1,140 @@ +autoscan: warning: missing AC_CHECK_FUNCS([floor]) wanted by: + waveVectorCompute3D.c:116 + waveVectorCompute3D.c:119 + waveVectorCompute3D.c:123 +autoscan: warning: missing AC_CHECK_FUNCS([pow]) wanted by: + gammf.c:12 + gammf.c:13 + power.c:9 + stable.c:9 +autoscan: warning: missing AC_CHECK_FUNCS([strchr]) wanted by: + strlib.c:140 +autoscan: warning: missing AC_CHECK_FUNCS([strstr]) wanted by: + strlib.c:153 +autoscan: warning: missing AC_FUNC_MALLOC wanted by: + addstat.c:25 + addstat2.c:25 + addstat2.c:32 + clean_real.c:20 + clean_real2.c:20 + derivReal.c:83 + derivReal.c:91 + derivReal.c:97 + derivReal.c:103 + derivReal.c:109 + derivReal.c:115 + derivReal.c:165 + derivReal.c:205 + FFTMA.c:65 + FFTMA.c:71 + FFTMA.c:77 + FFTMA.c:83 + FFTMA.c:89 + FFTMA.c:158 + FFTMA2.c:54 + FFTMA2.c:57 + FFTMA2.c:60 + FFTMA2.c:63 + FFTMA2.c:66 + FFTMAmemoire.c:55 + FFTMAmemoire.c:62 + FFTMAmemoire.c:65 + FFTMAmemoire.c:68 + FFTMAmemoire.c:71 + FFTPressure.c:62 + FFTPressure.c:65 + FFTPressure.c:68 + FFTPressure.c:71 + FFTPressure.c:74 + FFTPressure.c:77 + FFTPressure.c:80 + FFTPressure.c:83 + FFTPressure.c:86 + FFTPressure.c:89 + FFTPressure.c:92 + FFTPressure.c:95 + FFTPSim.c:63 + FFTPSim.c:66 + FFTPSim.c:69 + FFTPSim.c:72 + FFTPSim.c:75 + FFTPSim.c:78 + FFTPSim.c:81 + FFTPSim.c:84 + FFTPSim.c:87 + FFTPSim.c:90 + FFTPSim.c:93 + FFTPSim.c:96 + FFTPSim.c:99 + FFTPSim.c:102 + FFTtest.c:37 + FFTtest.c:40 + FFTtest.c:43 + FFTtest.c:46 + generate.c:20 + generate.c:29 + genlib.c:41 + inputdata.c:53 + inputdata.c:54 + inputdata.c:55 + inputdata.c:56 + inputdata.c:57 + inputdata.c:77 + inputdata.c:80 + inputfiledata.c:32 + inputfiledata.c:33 + inputfiledata.c:34 + inputfiledata.c:35 + inputfiledata.c:36 + inputfiledata.c:49 + inputfiledata.c:52 + kgeneration.c:41 + kgeneration2.c:41 + nor2log.c:29 + pgeneration.c:37 + pgeneration2.c:79 + readdata.c:62 + readdata.c:63 + readdata.c:64 + readdata.c:65 + readdata.c:66 + readdata.c:79 + readdata.c:82 + readdata.c:109 + readdata.c:145 + readdata.c:194 + readdata2.c:63 + readdata2.c:64 + readdata2.c:65 + readdata2.c:66 + readdata2.c:67 + readdata2.c:80 + readdata2.c:83 + readdata2.c:110 + readdata2.c:146 + readdata2.c:195 + readdata3.c:64 + readdata3.c:65 + readdata3.c:66 + readdata3.c:67 + readdata3.c:68 + readdata3.c:81 + readdata3.c:84 + readdata3.c:111 + readdata3.c:147 + readdata3.c:196 + waveVectorCompute3D.c:28 + waveVectorCompute3D.c:33 + waveVectorCompute3D.c:38 + waveVectorCompute3D.c:44 + waveVectorCompute3D.c:50 + waveVectorCompute3D.c:56 + waveVectorCompute3D.c:92 +autoscan: warning: missing AC_HEADER_STDBOOL wanted by: + random.c:74 + scanadt.c:95 + stack.c:76 + stack.c:81 + strlib.c:115 +autoscan: warning: missing AC_PREREQ wanted by: + autoscan diff --git a/fftma_module/gen/sources/axes.c b/fftma_module/gen/sources/axes.c new file mode 100755 index 0000000..b9e8351 --- /dev/null +++ b/fftma_module/gen/sources/axes.c @@ -0,0 +1,41 @@ +#include +#include + +/*normalizes anisotropy axes*/ +void axes(double *ap,double *scf,int N) +{ + double sclpdt, r, eps = 1.E-6; + int i,j,k; + + + for (k = 0; k < N; k++) { + + r = sqrt(ap[9*k]*ap[9*k]+ap[9*k+1]*ap[9*k+1]+ap[9*k+2]*ap[9*k+2]); + ap[9*k] /= r; + ap[9*k+1] /= r; + ap[9*k+2] /= r; + sclpdt = ap[9*k]*ap[9*k+3]+ap[9*k+1]*ap[9*k+4]+ap[9*k+2]*ap[9*k+5]; + if (sclpdt > eps) { + printf("Non orthogonal axes"); + exit; + } else { + r = sqrt(ap[9*k+3]*ap[9*k+3]+ap[9*k+4]*ap[9*k+4]+ap[9*k+5]*ap[9*k+5]); + ap[9*k+3] /= r; + ap[9*k+4] /= r; + ap[9*k+5] /= r; + ap[9*k+6] = ap[9*k+1]*ap[9*k+5]-ap[9*k+2]*ap[9*k+4]; + ap[9*k+7] = ap[9*k+2]*ap[9*k+3]-ap[9*k]*ap[9*k+5]; + ap[9*k+8] = ap[9*k]*ap[9*k+4]-ap[9*k+1]*ap[9*k+3]; + for (i=0; i<3; i++) { + for (j=0; j<3; j++) { + if (scf[3*k+j] == 0.) + scf[3*k+j] = 1.; + ap[9*k+3*j+i] /= scf[3*k+j]; + } + } + } + + } + return; +} + diff --git a/fftma_module/gen/sources/build_pressure.c b/fftma_module/gen/sources/build_pressure.c new file mode 100755 index 0000000..b9ded34 --- /dev/null +++ b/fftma_module/gen/sources/build_pressure.c @@ -0,0 +1,66 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_pressure */ +/* build pressure in spectral domain */ + +void build_pressure(int n[3],struct grid_mod grid,struct pressure_mod gradient,double *realization,double *ireal,double *pressure,double *ipressure) +{ + int i,j,k,maille1; + double ki,kj,kk; + double coeff,temp,temp2; + + /* pressure calculation in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (n[0]==1) + { + ki=0.; + } + else + { + ki =(double)(i-1)/(double)(grid.NX*grid.DX); + } + if (n[1]==1) + { + kj=0.; + } + else + { + kj =(double)j/(double)(grid.NY*grid.DY); + } + if (n[2]==1) + { + kk=0.; + } + else + { + kk =(double)k/(double)(grid.NZ*grid.DZ); + } + + coeff = (gradient.x*ki+gradient.y*kj+gradient.z*kk)/(ki*ki+kj*kj+kk*kk); + temp = realization[maille1]; + temp2= ireal[maille1]; + if (maille1==1) + { + pressure[maille1] =0.; + ipressure[maille1]=0.; + } + else + { + pressure[maille1] =-1./(2*3.14)*coeff*temp2; + ipressure[maille1]= 1./(2*3.14)*coeff*temp; + } + } + } + } + return; +} diff --git a/fftma_module/gen/sources/build_real.c b/fftma_module/gen/sources/build_real.c new file mode 100755 index 0000000..4a0e186 --- /dev/null +++ b/fftma_module/gen/sources/build_real.c @@ -0,0 +1,45 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +/* build_real */ +/* build a realization in the spectral domain */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*covar: vector defining the covariance in spectral domain */ +/*realization: vector defining the real part */ +/*ireal: vector defining the i-part */ + +void build_real(int n[3],int NTOT,double *covar,double *realization,double *ireal) +{ + int i,j,k,maille1; + double temp; + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + ireal[maille1] *= temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/sources/build_velocity.c b/fftma_module/gen/sources/build_velocity.c new file mode 100755 index 0000000..7511c4d --- /dev/null +++ b/fftma_module/gen/sources/build_velocity.c @@ -0,0 +1,117 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + +/* Build_velocity */ +/* Build velocity in spectral domain */ + +void build_velocity(int n[3],struct grid_mod grid,struct statistic_mod stat,struct pressure_mod gradient,double *realization,double *ireal,double *xvelocity,double *ixvelocity,int direction) +{ + int i,j,k,maille1; + int x,y,z; + double ki,kj,kk; + double coeff,temp,temp2; + double grad; + + /* x-direction velocity calculation in the spectral domain*/ + switch(direction) + { + case 1: + grad = gradient.x; + x=1; + y=0; + z=0; + break; + case 2: + grad = gradient.y; + x=0; + y=1; + z=0; + break; + case 3: + grad = gradient.z; + x=0; + y=0; + z=1; + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; +/* if (i +#include +#include "genlib.h" + +/*cardsin covariance function*/ +double cardsin(double h) +{ + float delta = 20.371; + double z; + + if (h != 0) { + z = (double)(h*delta); + z = sin(z)/z; + } else { + z = 1.; + } + return(z); +} diff --git a/fftma_module/gen/sources/cgrid.c b/fftma_module/gen/sources/cgrid.c new file mode 100755 index 0000000..19baee0 --- /dev/null +++ b/fftma_module/gen/sources/cgrid.c @@ -0,0 +1,43 @@ +#include +#include "geostat.h" + + +/*computes the size of the grid for FFTs*/ +/*input: */ +/*variogram: structure defining the variogram model*/ +/*grid: structure defining the actual grid */ +/*output: */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +void cgrid(struct vario_mod variogram, struct grid_mod grid, int n[3]) +{ + int i,N; + double D; + + if (n == NULL || n[0] == 0 || n[1] == 0 || n[2] == 0) { + for (i = 0; i<3; i++) { + switch (i) { + case 0: + N = grid.NX; + D = grid.DX; + break; + case 1: + N = grid.NY; + D = grid.DY; + break; + case 2: + N = grid.NZ; + D = grid.DZ; + break; + } + n[i] = length(N,i,variogram.scf,variogram.ap,D,variogram.Nvario); + } + } else { + if ((n[0] +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real(struct realization_mod *realin,int n[3],struct grid_mod grid,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + /* Modif du 18 juin 2003 */ + /*(*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT;*/ + (*realout).vector[maille0] = vectorresult[maille1]; + } + } + } + + return; +} diff --git a/fftma_module/gen/sources/clean_real2.c b/fftma_module/gen/sources/clean_real2.c new file mode 100755 index 0000000..058be88 --- /dev/null +++ b/fftma_module/gen/sources/clean_real2.c @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +void clean_real2(struct realization_mod *realin,int n[3],struct grid_mod grid,int solver,double *vectorresult,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double NTOT; + + NTOT=n[0]*n[1]*n[2]; + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + + if ((*realout).vector == NULL || (*realout).n != (*realin).n) + { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) + { + printf("Clean_real2.c: No memory available\n"); + exit; + } + } + + (*realout).n = (*realin).n; + (*realout).code = 1; + if (solver==1) + { + for ( k = 1; k <= NTOT;k++) + { + (*realout).vector[k-1] = vectorresult[k]/(double) NTOT; + } + } + else + { + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = vectorresult[maille1]/(double) NTOT; + } + } + } + } + return; +} diff --git a/fftma_module/gen/sources/cov_value.c b/fftma_module/gen/sources/cov_value.c new file mode 100755 index 0000000..e7baf5d --- /dev/null +++ b/fftma_module/gen/sources/cov_value.c @@ -0,0 +1,55 @@ +#include +#include "geostat.h" +#include "genlib.h" + +/*selection of model covariance*/ +double cov_value(struct vario_mod variogram,double di,double dj,double dk) +{ + double hx,hy,hz,h; + double cov; + int k; + + + cov = 0.; + + for (k = 0; k < variogram.Nvario; k++) { + + hx = di*variogram.ap[9*k]+dj*variogram.ap[9*k+1]+dk*variogram.ap[9*k+2]; + hy = di*variogram.ap[9*k+3]+dj*variogram.ap[9*k+4]+dk*variogram.ap[9*k+5]; + hz = di*variogram.ap[9*k+6]+dj*variogram.ap[9*k+7]+dk*variogram.ap[9*k+8]; + h = sqrt(hx*hx+hy*hy+hz*hz); + + + switch (variogram.vario[k]) { + case 1: + cov += variogram.var[k]*exponential(h); + break; + case 2: + cov += variogram.var[k]*gaussian(h); + break; + case 3: + cov += variogram.var[k]*spherical(h); + break; + case 4: + cov += variogram.var[k]*cardsin(h); + break; + case 5: + cov += variogram.var[k]*stable(h,variogram.alpha[k]); + break; + case 6: + cov += variogram.var[k]*gammf(h,variogram.alpha[k]); + break; + case 7: + cov += variogram.var[k]*cubic(h); + break; + case 8: + cov += variogram.var[k]*nugget(h); + break; + case 9: + cov += variogram.var[k]*power(h,variogram.alpha[k]); + break; + } + } + + return (cov); +} diff --git a/fftma_module/gen/sources/covariance.c b/fftma_module/gen/sources/covariance.c new file mode 100755 index 0000000..46ca138 --- /dev/null +++ b/fftma_module/gen/sources/covariance.c @@ -0,0 +1,90 @@ +#include "geostat.h" + +/*builds the sampled covariance function*/ +/*dimensions are even*/ +void covariance(double *covar, struct vario_mod variogram, struct grid_mod mesh, int n[3]) + +{ + int i,j,k,maille,n2[3],symmetric; + double di,dj,dk; + + + for (i=0;i<3;i++) + n2[i] = n[i]/2; + + for (i=0; i<= n2[0]; i++) { + for (j=0; j<= n2[1]; j++) { + for (k=0; k<= n2[2]; k++) { + + + /*area 1*/ + maille = 1+i+n[0]*(j+n[1]*k); + di = (double)i*mesh.DX; + dj = (double)j*mesh.DY; + dk = (double)k*mesh.DZ; + covar[maille] = (double)cov_value(variogram,di,dj,dk); + + + if (k > 0 && k 0 && j 0 && i 0 && i 0 && k 0 && j 0 && i 0 && j < n2[1]) { + /*area 5*/ + di = -(double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+(n[0]-i)+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && j < n2[1]) { + /*area 3*/ + di = (double)i*mesh.DX; + dj = -(double)j*mesh.DY; + dk = (double)k*mesh.DZ; + maille = 1+i+n[0]*(n[1]-j+n[1]*k); + covar[maille] = (double)cov_value(variogram,di,dj,dk); + } + + + if (k > 0 && k 0 && i +#include +#include "genlib.h" + + +/*cubic covariance function*/ +double cubic(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-7.*(double)(h*h)+(35./4.)*(double)(h*h*h)-3.5*(double)(h*h*h*h*h)+.75*(double)(h*h*h*h*h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/sources/debuginput.c b/fftma_module/gen/sources/debuginput.c new file mode 100755 index 0000000..b9c3a45 --- /dev/null +++ b/fftma_module/gen/sources/debuginput.c @@ -0,0 +1,73 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" +#include "toolsIO.h" + + +/* DebugInput */ +/* */ +/* Display the input data */ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void debuginput(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite) +{ + int i; + + + /* debug du 8/7/2002 */ + printf("\n\n"); + + printf("Starting seed (integer): %d\n",(*seed)); + printf("Number of cells along the X axis: %d\n",(*grid).NX); + printf("Number of cells along the Y axis: %d\n",(*grid).NY); + printf("Number of cells along the Z axis: %d\n",(*grid).NZ); + printf("cell length along the X axis: %6.4f\n",(*grid).DX); + printf("cell length along the Y axis: %6.4f\n",(*grid).DY); + printf("cell length along the Z axis: %6.4f\n",(*grid).DZ); + printf("Number of structures for the variogram: %d\n",(*variogram).Nvario); + i=0; + printf("Weight: %6.4f\n",(*variogram).var[i]); + printf("Type of variogram: %d\n",(*variogram).vario[i]); + printf("Exponent: %6.4f\n",(*variogram).alpha[i]); + + printf("Mean of the output realization: %15.8f\n",(*stat).mean[0]); + printf("Variance of the output realization: %6.4f\n",(*stat).variance[0]); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : %d\n",(*stat).type); + + /*output files*/ + printf("output filename for permeability realization: %s\n", filename[1]); + printf("\n\n"); + if (*gwnwrite == 0) + { + printf("K field generation with Gaussian white noise!\n"); + printf("output filename for Gaussian white noise: %s\n",filename[0]); + } + printf("\n\n"); + if ((*Ksolver == 1) | (*Ksolver == 2)) + { + printf("P field generation: %d/n",*Ksolver); + printf("output filename for pressure realization: %s\n", filename[2]); + printf("output filename for pressure total realization: %s\n", filename[3]); + printf("output filename for x-velocity realization: %s\n", filename[4]); + printf("output filename for y-velocity realization: %s\n", filename[5]); + printf("output filename for z-velocity realization: %s\n", filename[6]); + printf("output filename for pressure gradient realization: %s\n", filename[7]); + + /*Pressure data*/ + printf("Pressure gradient in x direction: %6.4f\n",(*pression).x); + printf("Pressure gradient in y direction: %6.4f\n",(*pression).y); + printf("Pressure gradient in z direction: %6.4f\n",(*pression).z); + } + printf("\n\n"); + + return; +} diff --git a/fftma_module/gen/sources/derivReal.c b/fftma_module/gen/sources/derivReal.c new file mode 100755 index 0000000..7e7e02b --- /dev/null +++ b/fftma_module/gen/sources/derivReal.c @@ -0,0 +1,216 @@ +#include +#include +#include +#include "condor.h" +#include "geostat.h" + +/* Private functions */ +void normAxes(double *vec, double *normed); + + +void derivReal(struct realization_mod *Z, struct realization_mod *dZ, double *dir, struct grid_mod *grid, struct vario_mod vario) { + + int n[3],i,j,k,maille,extMaille; + int NTOT,ntot,NMAX,nmax,NDIM; +// int NXYZ,nxyz; + double nDir[3]; + double *table,*workr,*worki,*realization,*waveVect; + + + int Ngrid; + double tmp; + double *ExtendedWaveVect; + +/* Test the input real*/ +/* if ((*Z).code != 1) { */ +/* printf("Realization should be Standard Normal\n"); */ +/* return; */ +/* } */ + + printf("grid.Nx = %d\n",(*grid).NX); + printf("grid.Ny = %d\n",(*grid).NY); + printf("grid.Nz = %d\n",(*grid).NZ); + + printf("vario.Nvario = %d\n",vario.Nvario); + for(i=0; i NMAX) NMAX = n[i]; + if (n[i] == 1) NDIM = NDIM-1; + } + nmax = NMAX+1; + + printf("NTOT = %d, ntot = %d, NMAX = %d\n",NTOT,ntot,NMAX); + +/* wave vector computation */ + normAxes(dir,nDir); + printf("Derivation direction (normed) %f %f %f\n",nDir[0],nDir[1],nDir[2]); + waveVect = (double *) malloc(Ngrid*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + waveVectorCompute3D((*grid).NX,(*grid).NY,(*grid).NZ,nDir,waveVect); + +/* memory allocation */ + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("derivReal.cpp: No memory availble for table\n"); + return; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + ExtendedWaveVect = (double *) malloc(ntot * sizeof(double)); + if (ExtendedWaveVect == NULL) { + printf("derivReal.cpp: No memory availble for realization\n"); + return; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("derivReal.cpp: No memory available for workr\n"); + return; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("derivReal.cpp: No memory available for worki\n"); + return; + } + + extMaille =0; +/* organization of the extended realization */ + for (k=1;k<=n[2];k++) { + for (j=1;j<=n[1];j++) { + for (i=1;i<=n[0];i++) { + extMaille = i + ((j-1) + (((k-1) * n[1]) * n[0])); + if (i <= (*grid).NX && j <= (*grid).NY && k <= (*grid).NZ) { + maille = i-1 + ((j-1) + ((k-1) * (*grid).NY) * (*grid).NX); + realization[extMaille] = (*Z).vector[maille]; + ExtendedWaveVect[extMaille] = waveVect[maille]; + } else { + realization[extMaille] = 0.0; + ExtendedWaveVect[extMaille] = 0.0; + } + } + } + } + +/* forward fourier transform of the realization */ + fourt(realization,table,n,NDIM,1,0,workr,worki); + FILE *wave; + wave = fopen("/home/irsrvshare1/R03/UPS_FLEX/waveVector.eas","w"); + + for (i=1;i +#include +#include "genlib.h" + +/*exponential covariance function*/ +double exponential(double h) +{ + return (exp(-3.*(double)h)); +} diff --git a/fftma_module/gen/sources/fftma.c b/fftma_module/gen/sources/fftma.c new file mode 100755 index 0000000..64f941e --- /dev/null +++ b/fftma_module/gen/sources/fftma.c @@ -0,0 +1,185 @@ + +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + + + +void FFTMA(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) + +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + double *table,*covar,*workr,*worki,*realization,temp; + + + /*test over the input realization*/ + /*if ((*realin).code != 0) { + printf("Input realizations in FFTMA must be Gaussian white noises"); + exit; + }*/ + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + if (covar == NULL) { + printf("FFTMA.c: No memory available for covar"); + exit; + } + + table = (double *) malloc(ntot * sizeof(double)); + if (table == NULL) { + printf("FFTMA.c: No memory available for table"); + exit; + } + + realization = (double *) malloc(ntot * sizeof(double)); + if (realization == NULL) { + printf("FFTMA.c: No memory available for realization"); + exit; + } + + workr = (double *) malloc(nmax * sizeof(double)); + if (workr == NULL) { + printf("FFTMA.c: No memory available for workr"); + exit; + } + + worki = (double *) malloc(nmax * sizeof(double)); + if (worki == NULL) { + printf("FFTMA.c: No memory available for worki"); + exit; + } + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + + /*power spectrum*/ + fourt(covar,table,n,NDIM,1,0,workr,worki); + + + /*organization of the input Gaussian white noise*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + if (i <= grid.NX && j <= grid.NY && k <= grid.NZ) { + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + realization[maille1] = (*realin).vector[maille0]; + } else { + realization[maille1] = 0.; + } + } + } + } + + + /*forward fourier transform of the GWN*/ + fourt(realization,table,n,NDIM,1,0,workr,worki); + + + /*decomposition and multiplication in the spectral domain*/ + for ( k = 1; k <= n[2]; k++) { + for (j = 1; j <= n[1]; j++) { + for (i = 1; i <= n[0]; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + temp = covar[maille1]; + if (temp > 0.) { + temp = sqrt(temp)/(double) NTOT; + } else if (temp < 0.) { + temp = sqrt(-temp)/(double) NTOT; + } + realization[maille1] *= temp; + table[maille1] *= temp; + } + } + } + + + free(covar); + + + /*backward fourier transform*/ + fourt(realization,table,n,NDIM,0,1,workr,worki); + + + free(table); + free(workr); + free(worki); + + + /*output realization*/ + + /*is the output realization already allocated?*/ + /*if not, memory allocation*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("FFTMA.c: No memory available"); + exit; + } + } + (*realout).n = (*realin).n; + (*realout).code = 1; + for ( k = 1; k <= grid.NZ; k++) { + for (j = 1; j <= grid.NY; j++) { + for (i = 1; i <= grid.NX; i++) { + maille1 = i+(j-1+(k-1)*n[1])*n[0]; + maille0 = i-1+(j-1+(k-1)*grid.NY)*grid.NX; + (*realout).vector[maille0] = realization[maille1]; + } + } + } + + + free(realization); + + + return; +} + + + + diff --git a/fftma_module/gen/sources/fftma2.c b/fftma_module/gen/sources/fftma2.c new file mode 100755 index 0000000..5977690 --- /dev/null +++ b/fftma_module/gen/sources/fftma2.c @@ -0,0 +1,105 @@ +#include +#include +#include +#include "geostat.h" + + +/*FAST FOURIER TRANSFORM MOVING AVERAGE METHOD */ +/*Turns a Gaussian white noise vector into a */ +/*spatially correlated vector */ +/*input: */ +/*variogram: structure defining the variogram */ +/* model */ +/*grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*output: */ +/*realout: structure defining a realization - */ + +void FFTMA2(struct vario_mod variogram,struct grid_mod grid,int n[3],struct realization_mod *realin,struct realization_mod *realout) +{ + int NTOT,i,j,k,NMAX,NDIM,ntot,nmax,NXYZ,nxyz,maille0,maille1; + int solver; + double temp; + double *ireal,*covar,*workr,*worki,*realization; + + /*covariance axis normalization*/ + axes(variogram.ap,variogram.scf,variogram.Nvario); + + /*pseudo-grid definition*/ + cgrid(variogram,grid,n); + + /*constant definition*/ + NTOT = n[0]*n[1]*n[2]; + ntot = NTOT+1; + NMAX = n[0]; + NDIM = 3; + for (i=1;i<3;i++) { + if (n[i] > NMAX) + NMAX = n[i]; + if (n[i] == 1) + NDIM--; + } + nmax = NMAX+1; + NXYZ = grid.NX*grid.NY*grid.NZ; + nxyz = NXYZ+1; + + /*array initialization*/ + covar = (double *) malloc(ntot * sizeof(double)); + testmemory(covar); + + ireal = (double *) malloc(ntot * sizeof(double)); + testmemory(ireal); + + realization = (double *) malloc(ntot * sizeof(double)); + testmemory(realization); + + workr = (double *) malloc(nmax * sizeof(double)); + testmemory(workr); + + worki = (double *) malloc(nmax * sizeof(double)); + testmemory(worki); + + /*covariance function creation*/ + covariance(covar,variogram,grid,n); + + /*power spectrum*/ + fourt(covar,ireal,n,NDIM,1,0,workr,worki); + + /*organization of the input Gaussian white noise*/ + solver=0; + prebuild_gwn(grid,n,realin,realization,solver); + + /*forward fourier transform of the GWN*/ + fourt(realization,ireal,n,NDIM,1,0,workr,worki); + + /* build realization in spectral domain */ + build_real(n,NTOT,covar,realization,ireal); + + free(covar); + + /*backward fourier transform*/ + fourt(realization,ireal,n,NDIM,0,1,workr,worki); + + + free(ireal); + free(workr); + free(worki); + + /*output realization*/ + clean_real(realin,n,grid,realization,realout); + + free(realization); + + return; +} + + + + diff --git a/fftma_module/gen/sources/fourt.c b/fftma_module/gen/sources/fourt.c new file mode 100755 index 0000000..fe80035 --- /dev/null +++ b/fftma_module/gen/sources/fourt.c @@ -0,0 +1,591 @@ +#include +#include + +/*fast fourier transform */ +/* THE COOLEY-TUKEY FAST FOURIER TRANSFORM */ +/* EVALUATES COMPLEX FOURIER SERIES FOR COMPLEX OR REAL FUNCTIONS. */ +/* THAT IS, IT COMPUTES */ +/* FTRAN(J1,J2,...)=SUM(DATA(I1,I2,...)*W1**(I1-1)*(J1-1) */ +/* *W2**(I2-1)*(J2-1)*...), */ +/* WHERE W1=EXP(-2*PI*SQRT(-1)/NN(1)), W2=EXP(-2*PI*SQRT(-1)/NN(2)), */ +/* ETC. AND I1 AND J1 RUN FROM 1 TO NN(1), I2 AND J2 RUN FROM 1 TO */ +/* NN(2), ETC. THERE IS NO LIMIT ON THE DIMENSIONALITY (NUMBER OF */ +/* SUBSCRIPTS) OF THE ARRAY OF DATA. THE PROGRAM WILL PERFORM */ +/* A THREE-DIMENSIONAL FOURIER TRANSFORM AS EASILY AS A ONE-DIMEN- */ +/* SIONAL ONE, THO IN A PROPORTIONATELY GREATER TIME. AN INVERSE */ +/* TRANSFORM CAN BE PERFORMED, IN WHICH THE SIGN IN THE EXPONENTIALS */ +/* IS +, INSTEAD OF -. IF AN INVERSE TRANSFORM IS PERFORMED UPON */ +/* AN ARRAY OF TRANSFORMED DATA, THE ORIGINAL DATA WILL REAPPEAR, */ +/* MULTIPLIED BY NN(1)*NN(2)*... THE ARRAY OF INPUT DATA MAY BE */ +/* REAL OR COMPLEX, AT THE PROGRAMMERS OPTION, WITH A SAVING OF */ +/* ABOUT THIRTY PER CENT IN RUNNING TIME FOR REAL OVER COMPLEX. */ +/* (FOR FASTEST TRANSFORM OF REAL DATA, NN(1) SHOULD BE EVEN.) */ +/* THE TRANSFORM VALUES ARE ALWAYS COMPLEX, AND ARE RETURNED IN THE */ +/* ORIGINAL ARRAY OF DATA, REPLACING THE INPUT DATA. THE LENGTH */ +/* OF EACH DIMENSION OF THE DATA ARRAY MAY BE ANY INTEGER. THE */ +/* PROGRAM RUNS FASTER ON COMPOSITE INTEGERS THAN ON PRIMES, AND IS */ +/* PARTICULARLY FAST ON NUMBERS RICH IN FACTORS OF TWO. */ +/* TIMING IS IN FACT GIVEN BY THE FOLLOWING FORMULA. LET NTOT BE THE */ +/* TOTAL NUMBER OF POINTS (REAL OR COMPLEX) IN THE DATA ARRAY, THAT */ +/* IS, NTOT=NN(1)*NN(2)*... DECOMPOSE NTOT INTO ITS PRIME FACTORS, */ +/* SUCH AS 2**K2 * 3**K3 * 5**K5 * ... LET SUM2 BE THE SUM OF ALL */ +/* THE FACTORS OF TWO IN NTOT, THAT IS, SUM2 = 2*K2. LET SUMF BE */ +/* THE SUM OF ALL OTHER FACTORS OF NTOT, THAT IS, SUMF = 3*K3+5*K5+.. */ +/* THE TIME TAKEN BY A MULTIDIMENSIONAL TRANSFORM ON THESE NTOT DATA */ +/* IS T = T0 + T1*NTOT + T2*NTOT*SUM2 + T3*NTOT*SUMF. FOR THE PAR- */ +/* TICULAR IMPLEMENTATION FORTRAN 32 ON THE CDC 3300 (FLOATING POINT */ +/* ADD TIME = SIX MICROSECONDS), */ +/* T = 3000 + 600*NTOT + 50*NTOT*SUM2 + 175*NTOT*SUMF MICROSECONDS */ +/* ON COMPLEX DATA. */ +/* IMPLEMENTATION OF THE DEFINITION BY SUMMATION WILL RUN IN A TIME */ +/* PROPORTIONAL TO NTOT**2. FOR HIGHLY COMPOSITE NTOT, THE SAVINGS */ +/* OFFERED BY COOLEY-TUKEY CAN BE DRAMATIC. A MATRIX 100 BY 100 WILL */ +/* BE TRANSFORMED IN TIME PROPORTIONAL TO 10000*(2+2+2+2+5+5+5+5) = */ +/* 280,000 (ASSUMING T2 AND T3 TO BE ROUGHLY COMPARABLE) VERSUS */ +/* 10000**2 = 100,000,000 FOR THE STRAIGHTFORWARD TECHNIQUE. */ +/* THE COOLEY-TUKEY ALGORITHM PLACES TWO RESTRICTIONS UPON THE */ +/* NATURE OF THE DATA BEYOND THE USUAL RESTRICTION THAT */ +/* THE DATA FROM ONE CYCLE OF A PERIODIC FUNCTION. THEY ARE-- */ +/* 1. THE NUMBER OF INPUT DATA AND THE NUMBER OF TRANSFORM VALUES */ +/* MUST BE THE SAME. */ +/* 2. CONSIDERING THE DATA TO BE IN THE TIME DOMAIN, */ +/* THEY MUST BE EQUI-SPACED AT INTERVALS OF DT. FURTHER, THE TRANS- */ +/* FORM VALUES, CONSIDERED TO BE IN FREQUENCY SPACE, WILL BE EQUI- */ +/* SPACED FROM 0 TO 2*PI*(NN(I)-1)/(NN(I)*DT) AT INTERVALS OF */ +/* 2*PI/(NN(I)*DT) FOR EACH DIMENSION OF LENGTH NN(I). OF COURSE, */ +/* DT NEED NOT BE THE SAME FOR EVERY DIMENSION. */ + +/* THE CALLING SEQUENCE IS-- */ +/* CALL FOURT(DATAR,DATAI,NN,NDIM,IFRWD,ICPLX,WORKR,WORKI) */ + +/* DATAR AND DATAI ARE THE ARRAYS USED TO HOLD THE REAL AND IMAGINARY */ +/* PARTS OF THE INPUT DATA ON INPUT AND THE TRANSFORM VALUES ON */ +/* OUTPUT. THEY ARE FLOATING POINT ARRAYS, MULTIDIMENSIONAL WITH */ +/* IDENTICAL DIMENSIONALITY AND EXTENT. THE EXTENT OF EACH DIMENSION */ +/* IS GIVEN IN THE INTEGER ARRAY NN, OF LENGTH NDIM. THAT IS, */ +/* NDIM IS THE DIMENSIONALITY OF THE ARRAYS DATAR AND DATAI. */ +/* IFRWD IS AN INTEGER USED TO INDICATE THE DIRECTION OF THE FOURIER */ +/* TRANSFORM. IT IS NON-ZERO TO INDICATE A FORWARD TRANSFORM */ +/* (EXPONENTIAL SIGN IS -) AND ZERO TO INDICATE AN INVERSE TRANSFORM */ +/* (SIGN IS +). ICPLX IS AN INTEGER TO INDICATE WHETHER THE DATA */ +/* ARE REAL OR COMPLEX. IT IS NON-ZERO FOR COMPLEX, ZERO FOR REAL. */ +/* IF IT IS ZERO (REAL) THE CONTENTS OF ARRAY DATAI WILL BE ASSUMED */ +/* TO BE ZERO, AND NEED NOT BE EXPLICITLY SET TO ZERO. AS EXPLAINED */ +/* ABOVE, THE TRANSFORM RESULTS ARE ALWAYS COMPLEX AND ARE STORED */ +/* IN DATAR AND DATAI ON RETURN. WORKR AND WORKI ARE ARRAYS USED */ +/* FOR WORKING STORAGE. THEY ARE NOT NECESSARY IF ALL THE DIMENSIONS */ +/* OF THE DATA ARE POWERS OF TWO. IN THIS CASE, THE ARRAYS MAY BE */ +/* REPLACED BY THE NUMBER 0 IN THE CALLING SEQUENCE. THUS, USE OF */ +/* POWERS OF TWO CAN FREE A GOOD DEAL OF STORAGE. IF ANY DIMENSION */ +/* IS NOT A POWER OF TWO, THESE ARRAYS MUST BE SUPPLIED. THEY ARE */ +/* FLOATING POINT, ONE DIMENSIONAL OF LENGTH EQUAL TO THE LARGEST */ +/* ARRAY DIMENSION, THAT IS, TO THE LARGEST VALUE OF NN(I). */ +/* WORKR AND WORKI, IF SUPPLIED, MUST NOT BE THE SAME ARRAYS AS DATAR */ +/* OR DATAI. ALL SUBSCRIPTS OF ALL ARRAYS BEGIN AT 1. */ + +/* THERE ARE NO ERROR MESSAGES OR ERROR HALTS IN THIS PROGRAM. THE */ +/* PROGRAM RETURNS IMMEDIATELY IF NDIM OR ANY NN(I) IS LESS THAN ONE. */ + +/* PROGRAM MODIFIED FROM A SUBROUTINE OF BRENNER */ +/* 10-06-2000, MLR */ + + +void fourt(double *datar,double *datai, int nn[3], int ndim, int ifrwd, int icplx, double *workr,double *worki) +{ + int ifact[21],ntot,idim,np1,n,np2,m,ntwo,iff,idiv,iquot,irem,inon2,non2p,np0,nprev,icase,ifmin,i,j,jmax,np2hf,i2,i1max,i3,j3,i1,ifp1,ifp2,i2max,i1rng,istep,imin,imax,mmax,mmin,mstep,j1,j2max,j2,jmin,j3max,nhalf; + double theta,wstpr,wstpi,wminr,wmini,wr,wi,wtemp,thetm,wmstr,wmsti,twowr,sr,si,oldsr,oldsi,stmpr,stmpi,tempr,tempi,difi,difr,sumr,sumi,TWOPI = 6.283185307179586476925286766559; + + ntot = 1; + for (idim = 0; idim < ndim; idim++) { + ntot *= nn[idim]; + } + + /*main loop for each dimension*/ + np1 = 1; + for (idim = 1; idim <= ndim; idim++) { + n = nn[idim-1]; + np2 = np1*n; + + if (n < 1) { + goto L920; + } else if (n == 1) { + goto L900; + } + + /*is n a power of 2 and if not, what are its factors*/ + m = n; + ntwo = np1; + iff = 1; + idiv = 2; + + L10: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L50; + if (irem == 0) { + ntwo *= 2; + ifact[iff] = idiv; + iff++; + m= iquot; + goto L10; + } + idiv = 3; + inon2 = iff; + + L30: + iquot = m/idiv; + irem = m-idiv*iquot; + if (iquot < idiv) + goto L60; + if (irem == 0) { + ifact[iff] = idiv; + iff++; + m = iquot; + goto L30; + } + + idiv += 2; + goto L30; + + L50: + inon2 = iff; + if (irem != 0) + goto L60; + ntwo *= 2; + goto L70; + + L60: + ifact[iff] = m; + + L70: + non2p = np2/ntwo; + + + /*SEPARATE FOUR CASES-- + 1. COMPLEX TRANSFORM + 2. REAL TRANSFORM FOR THE 2ND, 3RD, ETC. DIMENSION. METHOD: TRANSFORM HALF THE DATA, SUPPLYING THE OTHER HALF BY CONJUGATE SYMMETRY. + 3. REAL TRANSFORM FOR THE 1ST DIMENSION, N ODD. METHOD: SET THE IMAGINARY PARTS TO ZERO. + 4. REAL TRANSFORM FOR THE 1ST DIMENSION, N EVEN. METHOD: TRANSFORM A COMPLEX ARRAY OF LENGTH N/2 WHOSE REAL PARTS ARE THE EVEN NUMBERED REAL VALUES AND WHOSE IMAGINARY PARTS ARE THE ODD-NUMBERED REAL VALUES. UNSCRAMBLE AND SUPPLY THE SECOND HALF BY CONJUGATE SYMMETRY. */ + + icase = 1; + ifmin = 1; + if (icplx != 0) + goto L100; + icase = 2; + if (idim > 1) + goto L100; + icase = 3; + if (ntwo <= np1) + goto L100; + icase = 4; + ifmin = 2; + ntwo /= 2; + n /= 2; + np2 /= 2; + ntot /= 2; + i = 1; + for (j = 1; j <= ntot; j++) { + datar[j] = datar[i]; + datai[j] = datar[i+1]; + i += 2; + } + + /*shuffle data by bit reversal, since n = 2^k. As the shuffling can be done by simple interchange, no working array is needed*/ + L100: + if (non2p > 1) + goto L200; + np2hf = np2/2; + j = 1; + for (i2 = 1; i2 <= np2; i2 += np1) { + if (j >= i2) + goto L130; + i1max = i2+np1-1; + for (i1 = i2; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j3 = j+i3-i2; + tempr = datar[i3]; + tempi = datai[i3]; + datar[i3] = datar[j3]; + datai[i3] = datai[j3]; + datar[j3] = tempr; + datai[j3] = tempi; + } + } + + L130: + m = np2hf; + + L140: + if (j <= m) { + j += m; + } else { + j -= m; + m /= 2; + if (m >= np1) + goto L140; + } + + } + goto L300; + + /*shuffle data by digit reversal for general n*/ + L200: + for (i1 = 1; i1 <= np1; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + j = i3; + for (i = 1; i <= n; i++) { + if (icase != 3) { + workr[i] = datar[j]; + worki[i] = datai[j]; + } else { + workr[i] = datar[j]; + worki[i] = 0.; + } + ifp2 = np2; + iff = ifmin; + L250: + ifp1 = ifp2/ifact[iff]; + j += ifp1; + if (j >= i3+ifp2) { + j -= ifp2; + ifp2 = ifp1; + iff += 1; + if (ifp2 > np1) + goto L250; + } + } + i2max = i3+np2-np1; + i = 1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + datar[i2] = workr[i]; + datai[i2] = worki[i]; + i++; + } + + } + } + + /*special case-- W=1*/ + L300: + i1rng = np1; + if (icase == 2) + i1rng = np0*(1+nprev/2); + if (ntwo <= np1) + goto L600; + for (i1 = 1; i1 <= i1rng; i1++) { + imin = np1+i1; + istep = 2*np1; + goto L330; + + L310: + j = i1; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]; + tempi = datai[i]; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] = datar[j]+tempr; + datai[j] = datai[j]+tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + + L330: + if (istep <= ntwo) + goto L310; + + /*special case-- W = -sqrt(-1)*/ + imin = 3*np1+i1; + istep = 4*np1; + goto L420; + + L400: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + if (ifrwd != 0) { + tempr = datai[i]; + tempi = -datar[i]; + } else { + tempr = -datai[i]; + tempi = datar[i]; + } + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + + imin = 2*imin-i1; + istep *= 2; + + L420: + if (istep <= ntwo) + goto L400; + } + + /*main loop for factors of 2. W=EXP(-2*PI*SQRT(-1)*m/mmax) */ + theta = -TWOPI/8.; + wstpr = 0.; + wstpi = -1.; + if (ifrwd == 0) { + theta = -theta; + wstpi = 1.; + } + mmax = 8*np1; + goto L540; + + L500: + wminr = cos(theta); + wmini = sin(theta); + wr = wminr; + wi = wmini; + mmin = mmax/2+np1; + mstep = np1*2; + for (m = mmin; m <= mmax; m += mstep) { + for (i1 = 1; i1 <= i1rng; i1++) { + istep = mmax; + imin = m+i1; + L510: + j = imin-istep/2; + for (i = imin; i <= ntot; i += istep) { + tempr = datar[i]*wr-datai[i]*wi; + tempi = datar[i]*wi+datai[i]*wr; + datar[i] = datar[j]-tempr; + datai[i] = datai[j]-tempi; + datar[j] += tempr; + datai[j] += tempi; + j += istep; + } + imin = 2*imin-i1; + istep *= 2; + if (istep <= ntwo) + goto L510; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + wstpr = wminr; + wstpi = wmini; + theta /= 2.; + mmax += mmax; + L540: + if (mmax <= ntwo) + goto L500; + + /*main loop for factors not equal to 2-- W=EXP(-2*PI*SQRT(-1)*(j2-i3)/ifp2)*/ + L600: + if (non2p <= 1) + goto L700; + ifp1 = ntwo; + iff = inon2; + L610: + ifp2 = ifact[iff]*ifp1; + theta = -TWOPI/ (double)ifact[iff]; + if (ifrwd == 0) + theta = -theta; + thetm = theta/ (double)(ifp1/np1); + wstpr = cos(theta); + wstpi = sin(theta); + wmstr = cos(thetm); + wmsti = sin(thetm); + wminr = 1.; + wmini = 0.; + + for (j1 = 1; j1 <= ifp1; j1 += np1) { + i1max = j1+i1rng-1; + for (i1 = j1; i1 <= i1max; i1++) { + for (i3 = i1; i3 <= ntot; i3 += np2) { + i = 1; + wr = wminr; + wi = wmini; + j2max = i3+ifp2-ifp1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + twowr = 2.*wr; + jmin = i3; + j3max = j2+np2-ifp2; + for (j3 = j2 ; j3 <= j3max; j3 += ifp2) { + j = jmin+ifp2-ifp1; + sr = datar[j]; + si = datai[j]; + oldsr = 0.; + oldsi = 0.; + j -= ifp1; + L620: + stmpr = sr; + stmpi = si; + sr = twowr*sr-oldsr+datar[j]; + si = twowr*si-oldsi+datai[j]; + oldsr = stmpr; + oldsi = stmpi; + j -= ifp1; + if (j > jmin) + goto L620; + workr[i] = wr*sr-wi*si-oldsr+datar[j]; + worki[i] = wi*sr+wr*si-oldsi+datai[j]; + jmin += ifp2; + i++; + } + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + } + i = 1; + for (j2 = i3; j2 <= j2max; j2 += ifp1) { + j3max = j2+np2-ifp2; + for (j3 = j2; j3 <= j3max; j3 += ifp2) { + datar[j3] = workr[i]; + datai[j3] = worki[i]; + i++; + } + } + } + } + wtemp = wminr*wmsti; + wminr = wminr*wmstr-wmini*wmsti; + wmini = wmini*wmstr+wtemp; + } + iff++; + ifp1 = ifp2; + if (ifp1 < np2) + goto L610; + + /*complete a real transform in the 1st dimension, n even, by conjugate symmetries*/ + L700: + switch (icase) { + case 1: + goto L900; + break; + case 2: + goto L800; + break; + case 3: + goto L900; + break; + } + + nhalf = n; + n += n; + theta = -TWOPI/ (double) n; + if (ifrwd == 0) + theta = -theta; + wstpr = cos(theta); + wstpi = sin(theta); + wr = wstpr; + wi = wstpi; + imin = 2; + jmin = nhalf; + goto L725; + L710: + j = jmin; + for (i = imin; i <= ntot; i += np2) { + sumr = (datar[i]+datar[j])/2.; + sumi = (datai[i]+datai[j])/2.; + difr = (datar[i]-datar[j])/2.; + difi = (datai[i]-datai[j])/2.; + tempr = wr*sumi+wi*difr; + tempi = wi*sumi-wr*difr; + datar[i] = sumr+tempr; + datai[i] = difi+tempi; + datar[j] = sumr-tempr; + datai[j] = tempi-difi; + j += np2; + } + imin++; + jmin--; + wtemp = wr*wstpi; + wr = wr*wstpr-wi*wstpi; + wi = wi*wstpr+wtemp; + L725: + if (imin < jmin) { + goto L710; + } else if (imin > jmin) { + goto L740; + } + if (ifrwd == 0) + goto L740; + for (i = imin; i <= ntot; i += np2) { + datai[i] = -datai[i]; + } + L740: + np2 *= 2; + ntot *= 2; + j = ntot+1; + imax = ntot/2+1; + L745: + imin = imax-nhalf; + i = imin; + goto L755; + L750: + datar[j] = datar[i]; + datai[j] = -datai[i]; + L755: + i++; + j--; + if (i < imax) + goto L750; + datar[j] = datar[imin]-datai[imin]; + datai[j] = 0.; + if (i >= j) { + goto L780; + } else { + goto L770; + } + L765: + datar[j] = datar[i]; + datai[j] = datai[i]; + L770: + i--; + j--; + if (i > imin) + goto L765; + datar[j] = datar[imin]+datai[imin]; + datai[j] = 0.; + imax = imin; + goto L745; + L780: + datar[1] += datai[1]; + datai[1] = 0.; + goto L900; + + /*complete a real transform for the 2nd, 3rd, ... dimension by conjugate symmetries*/ + L800: + if (nprev <= 2) + goto L900; + for (i3 = 1; i3 <= ntot; i3 += np2) { + i2max = i3+np2-np1; + for (i2 = i3; i2 <= i2max; i2 += np1) { + imax = i2+np1-1; + imin = i2+i1rng; + jmax = 2*i3+np1-imin; + if (i2 > i3) + jmax += np2; + if (idim > 2) { + j = jmax+np0; + for (i = imin; i <= imax; i++) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j--; + } + } + j = jmax; + for (i = imin; i <= imax; i += np0) { + datar[i] = datar[j]; + datai[i] = -datai[j]; + j -= np0; + } + } + } + + /*end of loop on each dimension*/ + L900: + np0 = np1; + np1 = np2; + nprev = n; + } + L920: + return; +} diff --git a/fftma_module/gen/sources/gammf.c b/fftma_module/gen/sources/gammf.c new file mode 100755 index 0000000..97ff3f9 --- /dev/null +++ b/fftma_module/gen/sources/gammf.c @@ -0,0 +1,16 @@ +#include +#include +#include "genlib.h" + + +/*gamma covariance function*/ +double gammf(double h, double alpha) +{ + float delta; + double z; + + delta = pow(20.,1./alpha)-1.; + z = 1./(double)(pow(1.+h*delta,alpha)); + return(z); +} + diff --git a/fftma_module/gen/sources/gasdev.c b/fftma_module/gen/sources/gasdev.c new file mode 100755 index 0000000..a25dfa2 --- /dev/null +++ b/fftma_module/gen/sources/gasdev.c @@ -0,0 +1,31 @@ +#include +#include "genlib.h" + +#define NTAB 32 + +double gasdev(long *idum,long *idum2, long *iy, long iv[NTAB]) +/*returns a normally distributed deviate with 0 mean*/ +/*and unit variance, using ran2(idum) as the source */ +/*of uniform deviates */ +{ + double ran2(long *idum,long *idum2, long *iy, long iv[NTAB]); + static int iset = 0; + static double gset; + double fac,rsq,v1,v2; + + if (iset == 0) { + do { + v1 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + v2 = 2.0*ran2(idum,idum2,iy,iv)-1.0; + rsq = v1*v1+v2*v2; + } while (rsq >= 1.0 || rsq == 0.0); + + fac = sqrt(-2.0*log(rsq)/rsq); + gset = v1*fac; + iset = 1; + return (v2*fac); + } else { + iset = 0; + return (gset); + } +} diff --git a/fftma_module/gen/sources/gaussian.c b/fftma_module/gen/sources/gaussian.c new file mode 100755 index 0000000..5ef9911 --- /dev/null +++ b/fftma_module/gen/sources/gaussian.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*gaussian covariance function*/ +double gaussian(double h) +{ + return (exp(-3.*(double)(h*h))); +} diff --git a/fftma_module/gen/sources/generate.c b/fftma_module/gen/sources/generate.c new file mode 100755 index 0000000..46869d3 --- /dev/null +++ b/fftma_module/gen/sources/generate.c @@ -0,0 +1,43 @@ +#include +#include +#include "geostat.h" + + +/* GENERATION OF A GAUSSIAN WHITE NOISE VECTOR */ +/*input: */ +/* seed: seed */ +/* n: number of components in the vector */ +/*output: */ +/* realization: structure defining the realization*/ + +void generate(long *seed, int n, struct realization_mod *realization) +{ + int i; + long idum2 = 123456789,iy = 0; + long *iv; + int iset =0; + + iv = (long *) malloc(NTAB * sizeof(long)); + + /*negative seed*/ + if (*seed > 0.0) + *seed = -(*seed); + + /*realization definition*/ + (*realization).n = n; + (*realization).code = 0; + (*realization).vector = (double *) malloc(n * sizeof(double)); + if ((*realization).vector == NULL) { + printf("No memory available in generate"); + exit; + } + + /*Gaussian white noise generation*/ + for (i=0; i < n; i++) + (*realization).vector[i] = gasdev(seed,&idum2,&iy,iv,&iset); + + return; +} + + + diff --git a/fftma_module/gen/sources/genlib.c b/fftma_module/gen/sources/genlib.c new file mode 100755 index 0000000..1a106f6 --- /dev/null +++ b/fftma_module/gen/sources/genlib.c @@ -0,0 +1,63 @@ +/* + * File: genlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 15:45:52 1994 by eroberts + * ----------------------------------------------------- + * This file implements the general C library package. See the + * interface description in genlib.h for details. + */ + +#include +#include +#include +#include + +#include "genlib.h" + +/* + * Constants: + * ---------- + * ErrorExitStatus -- Status value used in exit call + */ + +#define ErrorExitStatus 1 + +/* Section 1 -- Define new "primitive" types */ + +/* + * Constant: UNDEFINED + * ------------------- + * This entry defines the target of the UNDEFINED constant. + */ + +char undefined_object[] = "UNDEFINED"; + +/* Section 2 -- Memory allocation */ + +void *GetBlock(size_t nbytes) +{ + void *result; + + result = malloc(nbytes); + if (result == NULL) Error("No memory available"); + return (result); +} + +void FreeBlock(void *ptr) +{ + free(ptr); +} + +/* Section 3 -- Basic error handling */ + +void Error(string msg, ...) +{ + va_list args; + + va_start(args, msg); + fprintf(stderr, "Error: "); + vfprintf(stderr, msg, args); + fprintf(stderr, "\n"); + va_end(args); + exit(ErrorExitStatus); +} diff --git a/fftma_module/gen/sources/inputdata.c b/fftma_module/gen/sources/inputdata.c new file mode 100755 index 0000000..259f1dd --- /dev/null +++ b/fftma_module/gen/sources/inputdata.c @@ -0,0 +1,122 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + + + +/* Inputdata */ +/* */ +/* input data needed for realizations*/ +/* seed: seed */ +/* grid: structure defining the actual grid */ +/* filename: name of files */ +/* variogram: struture defining the variogram model */ +/* stat: struture defining the mean and the variance of permeability realization */ +/* pression: structure defining the gradient pressure */ + +void inputdata(long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + int i,j; + + + /*seed*/ + printf("Starting seed (integer): \n"); + *seed = GetInteger(); + + /*Grid description*/ + printf("Number of cells along the X axis: \n"); + (*grid).NX = GetInteger(); + printf("Number of cells along the Y axis: \n"); + (*grid).NY = GetInteger(); + printf("Number of cells along the Z axis: \n"); + (*grid).NZ = GetInteger(); + printf("cell length along the X axis: \n"); + (*grid).DX = GetReal(); + printf("cell length along the Y axis: \n"); + (*grid).DY = GetReal(); + printf("cell length along the Z axis: \n"); + (*grid).DZ = GetReal(); + + /*output file*/ + printf("output filename for Gaussian white noise: \n"); + filename[0] = GetLine(); + + /*variogram description*/ + printf("Number of structures for the variogram: \n"); + (*variogram).Nvario = GetInteger(); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + printf("i %d\n",i); + printf("Weight: \n"); + (*variogram).var[i] = GetReal(); + printf("Type of variogram: \n"); + (*variogram).vario[i] = GetInteger(); + printf("Exponent: \n"); + (*variogram).alpha[i] = GetReal(); + printf("Correlation lengths (3): \n"); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]=GetReal(); + printf("Coordinates of the first two main axes (first axis first, then second): \n"); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = GetReal(); + } + + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + printf("Mean of the output realization: \n"); + (*stat).mean[0] = GetReal(); + printf("Variance of the output realization: \n"); + (*stat).variance[0] = GetReal(); + printf("Structure of the field (0-normal case 1-lognormal case 2-log10 case) : \n"); + (*stat).type = GetInteger(); + + /*output file*/ + printf("output filename for permeability realization: \n"); + filename[1] = GetLine(); + + /*Pressure data*/ + printf("Macroscopic pressure gradient in x direction: \n"); + (*pression).x = GetReal(); + printf("Macroscopic pressure gradient in y direction: \n"); + (*pression).y = GetReal(); + printf("Macroscopic pressure gradient in z direction: \n"); + (*pression).z = GetReal(); + + + /*output pressure file*/ + printf("output filename for pressure realization: \n"); + filename[2] = GetLine(); + + /*output pressure totale file*/ + printf("output filename for total pressure realization: \n"); + filename[3] = GetLine(); + + /*output x-velocity file*/ + printf("output filename for x-velocity realization: \n"); + filename[4] = GetLine(); + /*output y-velocity file*/ + printf("output filename for y-velocity realization: \n"); + filename[5] = GetLine(); + /*output z-velocity file*/ + printf("output filename for z-velocity realization: \n"); + filename[6] = GetLine(); + + return; +} diff --git a/fftma_module/gen/sources/inputfiledata.c b/fftma_module/gen/sources/inputfiledata.c new file mode 100755 index 0000000..404d482 --- /dev/null +++ b/fftma_module/gen/sources/inputfiledata.c @@ -0,0 +1,71 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" + +void inputfiledata(string inputfile,long *seed,struct grid_mod *grid,string filename[7],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression) +{ + FILE *fp; + int i,j; + + fp=fopen(inputfile,"r"); + if(fp== NULL) + { + printf("Erreur d'ouverture du fichier\n"); + exit(0); + } + *seed=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + filename[0] = ReadLine(fp); + (*variogram).Nvario = atoi(ReadLine(fp)); + + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + (*pression).x = atof(ReadLine(fp)); + (*pression).y = atof(ReadLine(fp)); + (*pression).z = atof(ReadLine(fp)); + filename[2] = ReadLine(fp); + filename[3] = ReadLine(fp); + filename[4] = ReadLine(fp); + filename[5] = ReadLine(fp); + filename[6] = ReadLine(fp); + fclose(fp); + return; +} diff --git a/fftma_module/gen/sources/kgeneration.c b/fftma_module/gen/sources/kgeneration.c new file mode 100755 index 0000000..633e4c8 --- /dev/null +++ b/fftma_module/gen/sources/kgeneration.c @@ -0,0 +1,79 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "toolsIO.h" +#include "toolsFFTMA.h" + +/* kgeneration */ +/* Z is the GWN with 0-mean and 1-variance */ +/* Y1 is the realization with 0-mean and variance wanted */ +/* Y is the realization with mean and variance wanted */ + +void kgeneration2(long seed,struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct realization_mod *Z,struct realization_mod *Y,struct realization_mod *Y1, int n[3], int *genere, int *gwnwrite, struct realization_mod *gwnoise,int *format_file) + { + int i,N; + int typelog; + string file1,file2; + + /*generate Gaussian white noise*/ + N = grid.NX*grid.NY*grid.NZ; + n[0] = 0; + n[1] = 0; + n[2] = 0; + printf("\n\n\n"); + + switch (*genere) + { + case 0: + generate(&seed,N,Z); + /*save the Gaussian white noise file*/ + if (*gwnwrite == 0) + { + writefile(filename[0],Z); + } + break; + case 1: + (*Z).vector=(double *) malloc(N*sizeof(double)); + (*Z).n = N; + for (i=0;i + +/* compute the length for one dimension*/ +int length(int N, int i, double *scf, double *ap, double D, int Nvari) +{ + int maxfactor(int n); + double temp1, temp2; + int n, j, k, nmax; + int nlimit = 13; + + if (N == 1) { + n = 1; + } else { + + for (k = 0; k < Nvari; k++) { + temp1 = fabs(ap[9*k+i])*scf[3*k]*scf[3*k]; + for (j = 1; j <3; j++) { + temp2 = fabs(ap[9*k+3*j+i])*scf[3*k+j]*scf[3*k+j]; + if (temp2 > temp1) + temp1 = temp2; + } + } + temp1 = sqrt(temp1); + temp1 /= (double)D; + if ((double)N/temp1 < 2.) { + n = N+(int)(2*temp1); + } else { + n = N+(int)temp1; + } + if ((n % 2) != 0) + n = n+1; + nmax = maxfactor(n); + while (nmax > nlimit) { + n += 2; + nmax = maxfactor(n); + } + } + return (n); +} diff --git a/fftma_module/gen/sources/mat_vec.c b/fftma_module/gen/sources/mat_vec.c new file mode 100755 index 0000000..831121b --- /dev/null +++ b/fftma_module/gen/sources/mat_vec.c @@ -0,0 +1,33 @@ +/*calculates C.x/ +/* C : symetric positive-definite matrix recorded */ +/* (per raws) as a vector with only components */ +/* Cij so that j <= i, i = [0...n-1]*/ +/* x : vector, xi avec i = [0...n-1]*/ +/* b : vector, bi avec i = [0...n-1]*/ +/* n : dimension of matrix Cij*/ +/* */ +/* The solution vector is returned in b*/ + +void mat_vec(double *C, double *x, double *b, int n) + +{ + int i,k,l; + double temp; + + for (i = 0; i < n; i++) { + temp = 0.; + + for (k = 0; k < n; k++) { + if ( k <= i ) { + l = k+i*(i+1)/2; + } else { + l = i+k*(k+1)/2; + } + temp += C[l]*x[k]; + } + + b[i] = temp; + } + + return; +} diff --git a/fftma_module/gen/sources/maxfactor.c b/fftma_module/gen/sources/maxfactor.c new file mode 100755 index 0000000..842cd8b --- /dev/null +++ b/fftma_module/gen/sources/maxfactor.c @@ -0,0 +1,35 @@ +#include "genlib.h" + +/*determines the greatest prime factor of an integer*/ +int maxfactor(int n) +{ + int test_fact(int *pnum, int fact, int *pmaxfac); + int lnum, fact; + int maxfac; + + maxfac = 1; + lnum = n; + + if ( lnum != 0 && lnum != 1 ) { + fact = 2; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 3; + if ( test_fact( &lnum, fact,&maxfac)) { + fact = 5; + for (;;) { + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 2; + if (!test_fact( &lnum, fact,&maxfac)) + break; + fact += 4; + } + } + } + if ( lnum != 1 ) { + if (lnum > maxfac) + maxfac = lnum; + } + } + return (maxfac); +} diff --git a/fftma_module/gen/sources/nor2log.c b/fftma_module/gen/sources/nor2log.c new file mode 100755 index 0000000..44b6568 --- /dev/null +++ b/fftma_module/gen/sources/nor2log.c @@ -0,0 +1,78 @@ +#include +#include +#include "geostat.h" + + +/*TURNS NORMAL NUMBERS INTO LOGNORMAL NUMBERS */ +/*input: */ +/*realin: structure defining a realization - */ +/* normal numbers */ +/*typelog: --> 3: lognormal (natural) */ +/* --> 4: lognormal (log10) */ +/*output: */ +/*realout: structure defining a realization - */ +/* lognormal numbers */ + +void nor2log(struct realization_mod *realin, int typelog, struct realization_mod *realout) +{ + + int i; + double coeff; + + + coeff = log(10.0); + + + /*Is the output realization allocated ?*/ + /*is its length equal to realin.n?*/ + if ((*realout).vector == NULL || (*realout).n != (*realin).n) { + (*realout).vector = (double *) malloc((*realin).n * sizeof(double)); + if ((*realout).vector == NULL) { + printf("No memory available"); + return; + } + } + (*realout).n = (*realin).n; + + + switch ((*realin).code) { + case 0: + case 1: + case 2: + (*realout).code = typelog; + break; + case 6: + case 7: + if (typelog == 3) { + (*realout).code = 8; + } else if (typelog == 4) { + (*realout).code = 9; + } + break; + default: + printf("Input is not normal in nor2log"); + return; + break; + } + + + /*anamorphose*/ + for (i = 0; i < (*realin).n; i++) { + switch (typelog) { + case 3: + /*natural logarithm*/ + (*realout).vector[i] = exp((*realin).vector[i]); + break; + case 4: + /*log10*/ + (*realout).vector[i] = exp((*realin).vector[i]*coeff); + break; + default: + printf("Unexpected case in nor2log"); + return; + break; + } + } + + return; +} diff --git a/fftma_module/gen/sources/nugget.c b/fftma_module/gen/sources/nugget.c new file mode 100755 index 0000000..cda4929 --- /dev/null +++ b/fftma_module/gen/sources/nugget.c @@ -0,0 +1,14 @@ +#include +#include +#include "genlib.h" + + +/*nugget covariance function*/ +double nugget(double h) +{ + if (h == 0) { + return (1.); + } else { + return(0.); + } +} diff --git a/fftma_module/gen/sources/pgeneration.c b/fftma_module/gen/sources/pgeneration.c new file mode 100755 index 0000000..18e1abb --- /dev/null +++ b/fftma_module/gen/sources/pgeneration.c @@ -0,0 +1,48 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7],struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P,struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + /*save the delta-pressure realization*/ + writefile(filename[2],P); + + total_pressure(grid,pression,P); + + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + writefile(filename[3],P); + /*save the x-velocity realization*/ + writefile(filename[4],VX); + /*save the y-velocity realization*/ + writefile(filename[5],VY); + /*save the z-velocity realization*/ + writefile(filename[6],VZ); + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + /*save the pressure gradient realization*/ + writefile(filename[7],&GP); + + return; + } diff --git a/fftma_module/gen/sources/pgeneration2.c b/fftma_module/gen/sources/pgeneration2.c new file mode 100755 index 0000000..323e45e --- /dev/null +++ b/fftma_module/gen/sources/pgeneration2.c @@ -0,0 +1,101 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + +void pgeneration2(int n[3],struct grid_mod grid,struct statistic_mod stat,struct vario_mod variogram,string filename[7], + struct pressure_mod pression,struct realization_mod *Y,struct realization_mod *P, + struct realization_mod *VX,struct realization_mod *VY,struct realization_mod *VZ, int solver, int format_file) + { + int i,ntot; + struct realization_mod GP; + + FFTPressure(n,grid,Y,stat,pression,P,VX,VY,VZ,solver); + + /*save the delta-pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[2],P); + break; + case 1: + writefile_bin(filename[2],P); + break; + } + + total_pressure(grid,pression,P); + total_velocity(grid,stat.mean[0],1,pression,VX); + total_velocity(grid,stat.mean[0],2,pression,VY); + total_velocity(grid,stat.mean[0],3,pression,VZ); + + /*save the total pressure realization*/ + switch (format_file) + { + case 0: + writefile(filename[3],P); + break; + case 1: + writefile_bin(filename[3],P); + break; + } + + /*save the x-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[4],VX); + break; + case 1: + writefile_bin(filename[4],VX); + break; + } + + /*save the y-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[5],VY); + break; + case 1: + writefile_bin(filename[5],VY); + break; + } + /*save the z-velocity realization*/ + switch (format_file) + { + case 0: + writefile(filename[6],VZ); + break; + case 1: + writefile_bin(filename[6],VZ); + break; + } + + ntot=grid.NX*grid.NY*grid.NZ; + GP.vector = (double *) malloc(ntot * sizeof(double)); + testmemory(GP.vector); + GP.n= ntot-1; + for (i = 0; i < ntot-1; i++) + { + GP.vector[i]=(*P).vector[i]-(*P).vector[i-1]; + } + + /*save the pressure gradient realization*/ + switch (format_file) + { + case 0: + writefile(filename[7],&GP); + break; + case 1: + writefile_bin(filename[7],&GP); + break; + } + + return; + } diff --git a/fftma_module/gen/sources/power.c b/fftma_module/gen/sources/power.c new file mode 100755 index 0000000..88281f6 --- /dev/null +++ b/fftma_module/gen/sources/power.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*power covariance function*/ +double power(double h, double alpha) +{ + return(pow(h,alpha)); +} diff --git a/fftma_module/gen/sources/prebuild_gwn.c b/fftma_module/gen/sources/prebuild_gwn.c new file mode 100755 index 0000000..447e9e7 --- /dev/null +++ b/fftma_module/gen/sources/prebuild_gwn.c @@ -0,0 +1,54 @@ +#include +#include +#include +#include +#include +#include +#include "geostat.h" + +/* prebuild_gwn */ +/* Produce a first construction in real space of the Gaussian white noise */ +/* grid: structure defining the grid */ +/*n: vector with the number of cells along the */ +/* X, Y and Z axes for the underlying grid */ +/* i = [0 1 2] */ +/* --> 0 0 0 : n will be computed and */ +/* updated as output */ +/* --> nx ny nz: these dimensions are used */ +/*realin: structure defining a realization - */ +/* must be a Gaussian white noise */ +/*realization: structure defining a realization*/ + +void prebuild_gwn(struct grid_mod grid,int n[3],struct realization_mod *realin,double *realization,int solver) + + { + int i,j,k,maille0,maille1; + int ntot; + + ntot=n[0]*n[1]*n[2]; + realization[0]=0.; + if (solver==1) + { + for (i=0;i= 0; j--) { + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + if (j < NTAB) iv[j] = *idum; + } + *iy = iv[0]; + } + + k = (*idum)/IQ1; + *idum = IA1*(*idum-k*IQ1)-k*IR1; + if (*idum < 0) *idum += IM1; + k = *idum2/IQ2; + *idum2 = IA2*(*idum2-k*IQ2)-k*IR2; + if (*idum2 < 0) *idum2 += IM2; + j = (*iy)/NDIV; + *iy = iv[j]-(*idum2); + iv[j] = *idum; + if (*iy < 1) (*iy) += IMM1; + if ((temp = AM*(*iy)) > RNMX) return (RNMX); + else return (temp); +} diff --git a/fftma_module/gen/sources/random.c b/fftma_module/gen/sources/random.c new file mode 100755 index 0000000..696312d --- /dev/null +++ b/fftma_module/gen/sources/random.c @@ -0,0 +1,77 @@ +/* + * File: random.c + * Version: 1.0 + * Last modified on Mon Sep 13 10:42:45 1993 by eroberts + * ----------------------------------------------------- + * This file implements the random.h interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "random.h" + +/* + * Function: Randomize + * ------------------- + * This function operates by setting the random number + * seed to the current time. The srand function is + * provided by the library and requires an + * integer argument. The time function is provided + * by . + */ + +void Randomize(void) +{ + srand((int) time(NULL)); +} + +/* + * Function: RandomInteger + * ----------------------- + * This function first obtains a random integer in + * the range [0..RAND_MAX] by applying four steps: + * (1) Generate a real number between 0 and 1. + * (2) Scale it to the appropriate range size. + * (3) Truncate the value to an integer. + * (4) Translate it to the appropriate starting point. + */ + +int RandomInteger(int low, int high) +{ + int k; + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + k = (int) (d * (high - low + 1)); + return (low + k); +} + +/* + * Function: RandomReal + * -------------------- + * The implementation of RandomReal is similar to that + * of RandomInteger, without the truncation step. + */ + +double RandomReal(double low, double high) +{ + double d; + + d = (double) rand() / ((double) RAND_MAX + 1); + return (low + d * (high - low)); +} + +/* + * Function: RandomChance + * ---------------------- + * This function uses RandomReal to generate a number + * between 0 and 100, which it then compares to p. + */ + +bool RandomChance(double p) +{ + return (RandomReal(0, 1) < p); +} diff --git a/fftma_module/gen/sources/readdata.c b/fftma_module/gen/sources/readdata.c new file mode 100755 index 0000000..3a70123 --- /dev/null +++ b/fftma_module/gen/sources/readdata.c @@ -0,0 +1,204 @@ +#include +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata2(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include "genlib.h" +#include "simpio.h" +#include "geostat.h" +#include "pressure.h" +#include "toolsIO.h" + + +void readdata3(long *seed,struct grid_mod *grid,string filename[8],struct vario_mod *variogram,struct statistic_mod *stat,struct pressure_mod *pression,int *Ksolver,int *genere, int *gwnwrite, int *format_file,int *Psolver, struct realization_mod *Kfield,struct realization_mod *gwnoise, char *argv[]) +{ + FILE *fp; + int i,j,n; + char *file1,*file2,*file3,*file4,*file5; + char *prog=argv[0]; + double tmp; + + file1=argv[1]; + file2=argv[2]; + + /* Ouverture du fichier de données principal */ + + if ((fp=fopen(file1,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file1); + exit(1); + } + else + { + *Ksolver = atoi(ReadLine(fp)); + *genere = atoi(ReadLine(fp)); + *gwnwrite = atoi(ReadLine(fp)); + if (*gwnwrite==0) + { + filename[0] = ReadLine(fp); + } + *format_file=atoi(ReadLine(fp)); + *Psolver=atoi(ReadLine(fp)); + (*grid).NX = atoi(ReadLine(fp)); + (*grid).NY = atoi(ReadLine(fp)); + (*grid).NZ = atoi(ReadLine(fp)); + (*grid).DX = atof(ReadLine(fp)); + (*grid).DY = atof(ReadLine(fp)); + (*grid).DZ = atof(ReadLine(fp)); + + fclose(fp); + } + n=(*grid).NX*(*grid).NY*(*grid).NZ; + +/* Ouverture du fichier de données sur le champ de perméabilité */ + + if ((fp=fopen(file2,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file2); + exit(1); + } + else + { + *seed=atoi(ReadLine(fp)); + (*variogram).Nvario = atoi(ReadLine(fp)); + (*variogram).vario = (int *) malloc((*variogram).Nvario * sizeof(int)); + (*variogram).alpha = (double *) malloc((*variogram).Nvario * sizeof(double)); + (*variogram).ap = (double *) malloc(9*(*variogram).Nvario * sizeof(double)); + (*variogram).scf = (double *) malloc(3*(*variogram).Nvario * sizeof(double)); + (*variogram).var = (double *) malloc((*variogram).Nvario * sizeof(double)); + for (i= 0; i < (*variogram).Nvario; i++) { + (*variogram).var[i] = atof(ReadLine(fp)); + (*variogram).vario[i] = atoi(ReadLine(fp)); + (*variogram).alpha[i] = atof(ReadLine(fp)); + for (j = 0; j < 3; j++) + (*variogram).scf[i*3+j]= atof(ReadLine(fp)); + for (j = 0; j < 6; j++) + (*variogram).ap[i*9+j] = atof(ReadLine(fp)); + } + /*statistical data*/ + (*stat).nblock_mean = 1; + (*stat).nblock_var = 1; + (*stat).mean = (double *)malloc((*stat).nblock_mean * sizeof(double)); + if ((*stat).mean == NULL) + Error("No memory available"); + (*stat).variance = (double *)malloc((*stat).nblock_var * sizeof(double)); + if ((*stat).variance == NULL) + Error("No memory available"); + + (*stat).mean[0] = atof(ReadLine(fp)); + (*stat).variance[0] = atof(ReadLine(fp)); + (*stat).type = atoi(ReadLine(fp)); + + filename[1] = ReadLine(fp); + fclose(fp); + } + + switch (*Ksolver) + { + case 0: + /* Ouverture du fichier contenant le gaussian white noise */ + if (*genere == 1) + { + file3=argv[3]; + if ((fp=fopen(file3,"r")) == NULL) + { + fprintf(stderr,"%s :impossible d'ouvrir %s\n",prog, file3); + exit(1); + } + else + { + /* Ouverture du champ de permeabilite K */ + (*gwnoise).vector = (double *) malloc(n * sizeof(double)); + for (i=0;i +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*readfile */ +/* read in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void readfile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double prout; + + /*read the permeability realization*/ + + + fp = fopen(filename, "r"); + + for (i=0;i<(*realin).n;i++) + { + fread(&prout,sizeof(double),1,fp); + printf("Prout: %15.10f\n",prout); + } + + fclose(fp); + return; +} diff --git a/fftma_module/gen/sources/scanadt.c b/fftma_module/gen/sources/scanadt.c new file mode 100755 index 0000000..bd887c5 --- /dev/null +++ b/fftma_module/gen/sources/scanadt.c @@ -0,0 +1,162 @@ +/* + * File: scanadt.c + * --------------- + * This file implements the scanadt.h interface. + */ + +#include +#include +#include "genlib.h" +#include "strlib.h" +#include "scanadt.h" + +/* + * Type: scannerCDT + * ---------------- + * This structure is the concrete representation of the type + * scannerADT, which is exported by this interface. Its purpose + * is to maintain the state of the scanner between calls. The + * details of the representation are invisible to the client, + * but consist of the following fields: + * + * str -- Copy of string passed to SetScannerString + * len -- Length of string, saved for efficiency + * cp -- Current character position in the string + * savedToken -- String saved by SaveToken (NULL indicates none) + * spaceOption -- Setting of the space option extension + */ + +struct scannerCDT { + string str; + int len; + int cp; + string savedToken; + spaceOptionT spaceOption; +}; + +/* Private function prototypes */ + +static void SkipSpaces(scannerADT scanner); +static int ScanToEndOfIdentifier(scannerADT scanner); + +/* Exported entries */ + +scannerADT NewScanner(void) +{ + scannerADT scanner; + + scanner = New(scannerADT); + scanner->str = NULL; + scanner->spaceOption = PreserveSpaces; + return (scanner); +} + +void FreeScanner(scannerADT scanner) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + FreeBlock(scanner); +} + +void SetScannerString(scannerADT scanner, string str) +{ + if (scanner->str != NULL) FreeBlock(scanner->str); + scanner->str = CopyString(str); + scanner->len = StringLength(str); + scanner->cp = 0; + scanner->savedToken = NULL; +} + +string ReadToken(scannerADT scanner) +{ + char ch; + string token; + int start, finish; + + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + token = scanner->savedToken; + scanner->savedToken = NULL; + return (token); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + start = finish = scanner->cp; + if (start >= scanner->len) return (CopyString("")); + ch = scanner->str[scanner->cp]; + if (isalnum(ch)) { + finish = ScanToEndOfIdentifier(scanner); + } else { + scanner->cp++; + } + return (SubString(scanner->str, start, finish)); +} + +bool MoreTokensExist(scannerADT scanner) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + return (!StringEqual(scanner->savedToken, "")); + } + if (scanner->spaceOption == IgnoreSpaces) SkipSpaces(scanner); + return (scanner->cp < scanner->len); +} + +void SaveToken(scannerADT scanner, string token) +{ + if (scanner->str == NULL) { + Error("SetScannerString has not been called"); + } + if (scanner->savedToken != NULL) { + Error("Token has already been saved"); + } + scanner->savedToken = token; +} + +void SetScannerSpaceOption(scannerADT scanner, spaceOptionT option) +{ + scanner->spaceOption = option; +} + +spaceOptionT GetScannerSpaceOption(scannerADT scanner) +{ + return (scanner->spaceOption); +} + +/* Private functions */ + +/* + * Function: SkipSpaces + * Usage: SkipSpaces(scanner); + * --------------------------- + * This function advances the position of the scanner until the + * current character is not a whitespace character. + */ + +static void SkipSpaces(scannerADT scanner) +{ + while (isspace(scanner->str[scanner->cp])) { + scanner->cp++; + } +} + +/* + * Function: ScanToEndOfIdentifier + * Usage: finish = ScanToEndOfIdentifier(scanner); + * ----------------------------------------------- + * This function advances the position of the scanner until it + * reaches the end of a sequence of letters or digits that make + * up an identifier. The return value is the index of the last + * character in the identifier; the value of the stored index + * cp is the first character after that. + */ + +static int ScanToEndOfIdentifier(scannerADT scanner) +{ + while (isalnum(scanner->str[scanner->cp])) { + scanner->cp++; + } + return (scanner->cp - 1); +} diff --git a/fftma_module/gen/sources/simpio.c b/fftma_module/gen/sources/simpio.c new file mode 100755 index 0000000..02e4025 --- /dev/null +++ b/fftma_module/gen/sources/simpio.c @@ -0,0 +1,157 @@ +/* + * File: simpio.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the simpio.h interface. + */ + +#include +#include + +#include "genlib.h" +#include "strlib.h" +#include "simpio.h" + +/* + * Constants: + * ---------- + * InitialBufferSize -- Initial buffer size for ReadLine + */ + +#define InitialBufferSize 120 + +/* Exported entries */ + +/* + * Functions: GetInteger, GetLong, GetReal + * --------------------------------------- + * These functions first read a line and then call sscanf to + * translate the number. Reading an entire line is essential to + * good error recovery, because the characters after the point of + * error would otherwise remain in the input buffer and confuse + * subsequent input operations. The sscanf line allows white space + * before and after the number but no other extraneous characters. + */ + +int GetInteger(void) +{ + string line; + int value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %d %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +long GetLong(void) +{ + string line; + long value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %ld %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter an integer\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +double GetReal(void) +{ + string line; + double value; + char termch; + + while (TRUE) { + line = GetLine(); + switch (sscanf(line, " %lf %c", &value, &termch)) { + case 1: + FreeBlock(line); + return (value); + case 2: + printf("Unexpected character: '%c'\n", termch); + break; + default: + printf("Please enter a real number\n"); + break; + } + FreeBlock(line); + printf("Retry: "); + } +} + +/* + * Function: GetLine + * ----------------- + * This function is a simple wrapper; all the work is done by + * ReadLine. + */ + +string GetLine(void) +{ + return (ReadLine(stdin)); +} + +/* + * Function: ReadLine + * ------------------ + * This function operates by reading characters from the file + * into a dynamically allocated buffer. If the buffer becomes + * full before the end of the line is reached, a new buffer + * twice the size of the previous one is allocated. + */ + +string ReadLine(FILE *infile) +{ + string line, nline; + int n, ch, size; + + n = 0; + size = InitialBufferSize; + line = GetBlock(size + 1); + while ((ch = getc(infile)) != '\n' && ch != EOF) { + if (n == size) { + size *= 2; + nline = (string) GetBlock(size + 1); + strncpy(nline, line, n); + FreeBlock(line); + line = nline; + } + line[n++] = ch; + } + if (n == 0 && ch == EOF) { + FreeBlock(line); + return (NULL); + } + line[n] = '\0'; + nline = (string) GetBlock(n + 1); + strcpy(nline, line); + FreeBlock(line); + return (nline); +} diff --git a/fftma_module/gen/sources/spherical.c b/fftma_module/gen/sources/spherical.c new file mode 100755 index 0000000..a36e492 --- /dev/null +++ b/fftma_module/gen/sources/spherical.c @@ -0,0 +1,17 @@ +#include +#include +#include "genlib.h" + + +/*spherical covariance function*/ +double spherical(double h) +{ + double z; + + if (h >= 1.) { + z = 0.; + } else { + z = 1.-1.5*(double)h+0.5*(double)(h*h*h); + } + return (z); +} diff --git a/fftma_module/gen/sources/stable.c b/fftma_module/gen/sources/stable.c new file mode 100755 index 0000000..45c5a29 --- /dev/null +++ b/fftma_module/gen/sources/stable.c @@ -0,0 +1,10 @@ +#include +#include +#include "genlib.h" + + +/*stable covariance function*/ +double stable(double h, double alpha) +{ + return(exp(-3.*(double)pow(h,alpha))); +} diff --git a/fftma_module/gen/sources/stack.c b/fftma_module/gen/sources/stack.c new file mode 100755 index 0000000..8bd5ee4 --- /dev/null +++ b/fftma_module/gen/sources/stack.c @@ -0,0 +1,122 @@ +/* + * File: stack.c + * ------------- + * This file implements the stack.h interface. Note that the + * implementation is independent of the type of value stored + * in the stack. That type is defined by the interface as + * the type name stackElementT. + */ + +#include +#include "genlib.h" +#include "stack.h" + +/* + * Constant: InitialStackSize + * -------------------------- + * This constant defines the initial size of the stack array. + * Any positive value will work correctly, although changing + * this parameter can affect performance. Making this value + * larger postpones the first reallocation but causes stacks + * to consume more memory. + */ + +#define InitialStackSize 100 + +/* + * Type: stackCDT + * -------------- + * The type stackCDT is the concrete representation of the type + * stackADT defined by the interface. In this implementation, + * the elements are stored in a dynamic array that doubles in + * size if the old stack becomes full. + */ + +struct stackCDT { + stackElementT *elements; + int count; + int size; +}; + +/* Private function prototypes */ + +static void ExpandStack(stackADT stack); + +/* Exported entries */ + +stackADT NewStack(void) +{ + stackADT stack; + + stack = New(stackADT); + stack->elements = NewArray(InitialStackSize, stackElementT); + stack->count = 0; + stack->size = InitialStackSize; + return (stack); +} + +void FreeStack(stackADT stack) +{ + FreeBlock(stack->elements); + FreeBlock(stack); +} + +void Push(stackADT stack, stackElementT element) +{ + if (stack->count == stack->size) ExpandStack(stack); + stack->elements[stack->count++] = element; +} + +stackElementT Pop(stackADT stack) +{ + if (StackIsEmpty(stack)) Error("Pop of an empty stack"); + return (stack->elements[--stack->count]); +} + +bool StackIsEmpty(stackADT stack) +{ + return (stack->count == 0); +} + +bool StackIsFull(stackADT stack) +{ + return (FALSE); +} + +int StackDepth(stackADT stack) +{ + return (stack->count); +} + +stackElementT GetStackElement(stackADT stack, int index) +{ + if (index < 0 || index >= stack->count) { + Error("Non-existent stack element"); + } + return (stack->elements[stack->count - index - 1]); +} + +/* Private functions */ + +/* Function: ExpandStack + * Usage: ExpandStack(stack); + * -------------------------- + * This function expands a full stack by doubling the size of its + * dynamic array, copying the old elements to the new array, and + * then freeing the old array storage. + */ + +static void ExpandStack(stackADT stack) +{ + stackElementT *array; + int i, newSize; + + newSize = stack->size * 2; + array = NewArray(newSize, stackElementT); + for (i = 0; i < stack->size; i++) { + array[i] = stack->elements[i]; + } + FreeBlock(stack->elements); + stack->elements = array; + stack->size = newSize; +} diff --git a/fftma_module/gen/sources/strlib.c b/fftma_module/gen/sources/strlib.c new file mode 100755 index 0000000..6f00938 --- /dev/null +++ b/fftma_module/gen/sources/strlib.c @@ -0,0 +1,246 @@ +/* + * File: strlib.c + * Version: 1.0 + * Last modified on Fri Jul 15 14:10:41 1994 by eroberts + * ----------------------------------------------------- + * This file implements the strlib.h interface. + */ + +/* + * General implementation notes: + * ----------------------------- + * This module implements the strlib library by mapping all + * functions into the appropriate calls to the ANSI + * interface. The implementations of the individual functions + * are all quite simple and do not require individual comments. + * For descriptions of the behavior of each function, see the + * interface. + */ + +#include +#include +#include + +#include "genlib.h" +#include "strlib.h" + +/* + * Constant: MaxDigits + * ------------------- + * This constant must be larger than the maximum + * number of digits that can appear in a number. + */ + +#define MaxDigits 30 + +/* Private function prototypes */ + +static string CreateString(int len); + +/* Section 1 -- Basic string operations */ + +string Concat(string s1, string s2) +{ + string s; + int len1, len2; + + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to Concat"); + } + len1 = strlen(s1); + len2 = strlen(s2); + s = CreateString(len1 + len2); + strcpy(s, s1); + strcpy(s + len1, s2); + return (s); +} + +char IthChar(string s, int i) +{ + int len; + + if (s == NULL) Error("NULL string passed to IthChar"); + len = strlen(s); + if (i < 0 || i > len) { + Error("Index outside of string range in IthChar"); + } + return (s[i]); +} + +string SubString(string s, int p1, int p2) +{ + int len; + string result; + + if (s == NULL) Error("NULL string passed to SubString"); + len = strlen(s); + if (p1 < 0) p1 = 0; + if (p2 >= len) p2 = len - 1; + len = p2 - p1 + 1; + if (len < 0) len = 0; + result = CreateString(len); + strncpy(result, s + p1, len); + result[len] = '\0'; + return (result); +} + +string CharToString(char ch) +{ + string result; + + result = CreateString(1); + result[0] = ch; + result[1] = '\0'; + return (result); +} + +int StringLength(string s) +{ + if (s == NULL) Error("NULL string passed to StringLength"); + return (strlen(s)); +} + +string CopyString(string s) +{ + string newstr; + + if (s == NULL) Error("NULL string passed to CopyString"); + newstr = CreateString(strlen(s)); + strcpy(newstr, s); + return (newstr); +} + +/* Section 2 -- String comparison functions */ + +bool StringEqual(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringEqual"); + } + return (strcmp(s1, s2) == 0); +} + +int StringCompare(string s1, string s2) +{ + if (s1 == NULL || s2 == NULL) { + Error("NULL string passed to StringCompare"); + } + return (strcmp(s1, s2)); +} + +/* Section 3 -- Search functions */ + +int FindChar(char ch, string text, int start) +{ + char *cptr; + + if (text == NULL) Error("NULL string passed to FindChar"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strchr(text + start, ch); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +int FindString(string str, string text, int start) +{ + char *cptr; + + if (str == NULL) Error("NULL pattern string in FindString"); + if (text == NULL) Error("NULL text string in FindString"); + if (start < 0) start = 0; + if (start > strlen(text)) return (-1); + cptr = strstr(text + start, str); + if (cptr == NULL) return (-1); + return ((int) (cptr - text)); +} + +/* Section 4 -- Case-conversion functions */ + +string ConvertToLowerCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToLowerCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = tolower(s[i]); + result[i] = '\0'; + return (result); +} + +string ConvertToUpperCase(string s) +{ + string result; + int i; + + if (s == NULL) { + Error("NULL string passed to ConvertToUpperCase"); + } + result = CreateString(strlen(s)); + for (i = 0; s[i] != '\0'; i++) result[i] = toupper(s[i]); + result[i] = '\0'; + return (result); +} + +/* Section 5 -- Functions for converting numbers to strings */ + +string IntegerToString(int n) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%d", n); + return (CopyString(buffer)); +} + +int StringToInteger(string s) +{ + int result; + char dummy; + + if (s == NULL) { + Error("NULL string passed to StringToInteger"); + } + if (sscanf(s, " %d %c", &result, &dummy) != 1) { + Error("StringToInteger called on illegal number %s", s); + } + return (result); +} + +string RealToString(double d) +{ + char buffer[MaxDigits]; + + sprintf(buffer, "%G", d); + return (CopyString(buffer)); +} + +double StringToReal(string s) +{ + double result; + char dummy; + + if (s == NULL) Error("NULL string passed to StringToReal"); + if (sscanf(s, " %lg %c", &result, &dummy) != 1) { + Error("StringToReal called on illegal number %s", s); + } + return (result); +} + +/* Private functions */ + +/* + * Function: CreateString + * Usage: s = CreateString(len); + * ----------------------------- + * This function dynamically allocates space for a string of + * len characters, leaving room for the null character at the + * end. + */ + +static string CreateString(int len) +{ + return ((string) GetBlock(len + 1)); +} diff --git a/fftma_module/gen/sources/symtab.c b/fftma_module/gen/sources/symtab.c new file mode 100755 index 0000000..6e27a10 --- /dev/null +++ b/fftma_module/gen/sources/symtab.c @@ -0,0 +1,180 @@ +/* + * File: symtab.c + * -------------- + * This file implements the symbol table abstraction. + */ + +#include +#include "genlib.h" +#include "strlib.h" +#include "symtab.h" + +/* + * Constants + * --------- + * NBuckets -- Number of buckets in the hash table + */ + +#define NBuckets 101 + +/* + * Type: cellT + * ----------- + * This type defines a linked list cell for the symbol table. + */ + +typedef struct cellT { + string key; + void *value; + struct cellT *link; +} cellT; + +/* + * Type: symtabCDT + * --------------- + * This type defines the underlying concrete representation for a + * symtabADT. These details are not relevant to and therefore + * not exported to the client. In this implementation, the + * underlying structure is a hash table organized as an array of + * "buckets," in which each bucket is a linked list of elements + * that share the same hash code. + */ + +struct symtabCDT { + cellT *buckets[NBuckets]; +}; + +/* Private function declarations */ + +static void FreeBucketChain(cellT *cp); +static cellT *FindCell(cellT *cp, string s); +static int Hash(string s, int nBuckets); + +/* Public entries */ + +symtabADT NewSymbolTable(void) +{ + symtabADT table; + int i; + + table = New(symtabADT); + for (i = 0; i < NBuckets; i++) { + table->buckets[i] = NULL; + } + return (table); +} + +void FreeSymbolTable(symtabADT table) +{ + int i; + + for (i = 0; i < NBuckets; i++) { + FreeBucketChain(table->buckets[i]); + } + FreeBlock(table); +} + +void Enter(symtabADT table, string key, void *value) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) { + cp = New(cellT *); + cp->key = CopyString(key); + cp->link = table->buckets[bucket]; + table->buckets[bucket] = cp; + } + cp->value = value; +} + +void *Lookup(symtabADT table, string key) +{ + int bucket; + cellT *cp; + + bucket = Hash(key, NBuckets); + cp = FindCell(table->buckets[bucket], key); + if (cp == NULL) return(UNDEFINED); + return (cp->value); +} + +void MapSymbolTable(symtabFnT fn, symtabADT table, + void *clientData) +{ + int i; + cellT *cp; + + for (i = 0; i < NBuckets; i++) { + for (cp = table->buckets[i]; cp != NULL; cp = cp->link) { + fn(cp->key, cp->value, clientData); + } + } +} + +/* Private functions */ + +/* + * Function: FreeBucketChain + * Usage: FreeBucketChain(cp); + * --------------------------- + * This function takes a chain pointer and frees all the cells + * in that chain. Because the package makes copies of the keys, + * this function must free the string storage as well. + */ + +static void FreeBucketChain(cellT *cp) +{ + cellT *next; + + while (cp != NULL) { + next = cp->link; + FreeBlock(cp->key); + FreeBlock(cp); + cp = next; + } +} + +/* + * Function: FindCell + * Usage: cp = FindCell(cp, key); + * ------------------------------ + * This function finds a cell in the chain beginning at cp that + * matches key. If a match is found, a pointer to that cell is + * returned. If no match is found, the function returns NULL. + */ + +static cellT *FindCell(cellT *cp, string key) +{ + while (cp != NULL && !StringEqual(cp->key, key)) { + cp = cp->link; + } + return (cp); +} + +/* + * Function: Hash + * Usage: bucket = Hash(key, nBuckets); + * ------------------------------------ + * This function takes the key and uses it to derive a hash code, + * which is an integer in the range [0, nBuckets - 1]. The hash + * code is computed using a method called linear congruence. The + * choice of the value for Multiplier can have a significant effect + * on the performance of the algorithm, but not on its correctness. + */ + +#define Multiplier -1664117991L + +static int Hash(string s, int nBuckets) +{ + int i; + unsigned long hashcode; + + hashcode = 0; + for (i = 0; s[i] != '\0'; i++) { + hashcode = hashcode * Multiplier + s[i]; + } + return (hashcode % nBuckets); +} diff --git a/fftma_module/gen/sources/test_fact.c b/fftma_module/gen/sources/test_fact.c new file mode 100755 index 0000000..d2456ee --- /dev/null +++ b/fftma_module/gen/sources/test_fact.c @@ -0,0 +1,26 @@ +#include "genlib.h" + +/*tries factor*/ +int test_fact(int *pnum, int fact, int *pmaxfac) +{ + int power, t; + + power = 0; + while ( ( t = *pnum / fact ) * fact == *pnum ) { + ++power; + *pnum = t; + } + + if ( power != 0 ) { + if (fact > *pmaxfac) + *pmaxfac = fact; + } + + if ( t > fact ) { + return (1); + } + + return (0); +} + + diff --git a/fftma_module/gen/sources/testmemory.c b/fftma_module/gen/sources/testmemory.c new file mode 100755 index 0000000..7cbd10e --- /dev/null +++ b/fftma_module/gen/sources/testmemory.c @@ -0,0 +1,15 @@ +#include +#include +#include +#include +#include +#include + +void testmemory(double *realint) +{ + if (realint == NULL) { + printf("Testmemory.c: No memory available \n"); + exit; + } + return; +} diff --git a/fftma_module/gen/sources/testopenfile.c b/fftma_module/gen/sources/testopenfile.c new file mode 100755 index 0000000..dee13a8 --- /dev/null +++ b/fftma_module/gen/sources/testopenfile.c @@ -0,0 +1,16 @@ +#include +#include +#include +#include +#include +#include + +void testopenfile(FILE *fp) +{ + if (fp == NULL) + { + printf("Erreur d'ouverture de fichier\n"); + exit(0); + } + return; +} diff --git a/fftma_module/gen/sources/total_pressure.c b/fftma_module/gen/sources/total_pressure.c new file mode 100755 index 0000000..24135c1 --- /dev/null +++ b/fftma_module/gen/sources/total_pressure.c @@ -0,0 +1,35 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_pressure */ +/* Build total pressure */ +/* grid: structure defining the grid */ +/* pression: structure defining the gradient pressure */ +/* realout: structure defining a realization */ + +void total_pressure(struct grid_mod grid,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,reference; + + reference=abs(gradient.x)*grid.NX*grid.DX+abs(gradient.y)*grid.NY*grid.DY+abs(gradient.z)*grid.NZ*grid.DZ; + /* pressure reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; +/* temp=reference+gradient.x*i*grid.DX+gradient.y*j*grid.DY+gradient.z*k*grid.DZ+(*realout).vector[maille1]; */ + temp=-gradient.x*(i+1)/grid.NX-gradient.y*(j+1)/grid.NY-gradient.z*(k+1)/grid.NZ+(*realout).vector[maille1]; + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/sources/total_velocity.c b/fftma_module/gen/sources/total_velocity.c new file mode 100755 index 0000000..63344c1 --- /dev/null +++ b/fftma_module/gen/sources/total_velocity.c @@ -0,0 +1,50 @@ +#include +#include +#include +#include +#include "geostat.h" +#include "pressure.h" + + + +/* total_velocity */ +/* Build total velocity */ +/* grid: structure defining the grid */ +/* mean: permeability mean */ +/* dgradient: macroscopic pressure gradient in wanted direction */ +/* realout: structure defining a X velocity realization */ + +void total_velocity(struct grid_mod grid,double mean,int direction,struct pressure_mod gradient,struct realization_mod *realout) +{ + int i,j,k,maille0,maille1; + double temp,grad; + switch(direction) + { + case 1: + grad = gradient.x/(grid.NX*grid.DX); + break; + case 2: + grad = gradient.y/(grid.NY*grid.DY);/* *grid.NY*grid.DY; */ + break; + case 3: + grad = gradient.z/(grid.NZ*grid.DZ); /* *grid.NZ*grid.DZ; */ + break; + default : + printf("build_velocity.c: wrong velocity direction!!! direction: %d\n",direction); + break; + } + + /* x velocity reconstruction */ + for ( k = 0; k < grid.NZ; k++) { + for (j = 0; j < grid.NY; j++) { + for (i = 0; i < grid.NX; i++) { + maille1 = i+(j+k*grid.NY)*grid.NX; + temp=mean*grad+(*realout).vector[maille1]; +/* temp=mean*grad; */ + (*realout).vector[maille1]=temp; + } + } + } + + return; +} diff --git a/fftma_module/gen/sources/waveVectorCompute3D.c b/fftma_module/gen/sources/waveVectorCompute3D.c new file mode 100755 index 0000000..58e8342 --- /dev/null +++ b/fftma_module/gen/sources/waveVectorCompute3D.c @@ -0,0 +1,156 @@ +//#include +//#include +#include +#include +#include +#include +#include +#include + +//using namespace std; + +/*Private functions */ +void waveVectorCompute1D(int n,double *vec); + +void waveVectorCompute3D(int nX,int nY, int nZ, /*double dX, double dY, double dZ,*/ double nDir[3], double *waveVect) { + + int nTot; + double *vecX,*vecY,*vecZ; + double *waveVect3DX, *waveVect3DY, *waveVect3DZ; + + int i, j, k, maille; + + nTot = nX*nY*nZ; +// printf("nX = %d, nY = %d, nZ = %d, nTot = %d\n",nX,nY,nZ,nTot); +// printf("Entering waveVectorCompute3D\n"); + +/*Memory allocation */ + waveVect3DX = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DX == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DX\n"); + return; + } + waveVect3DY = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DY == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DY\n"); + return; + } + waveVect3DZ = (double *)malloc(nTot * sizeof(double)); + if (waveVect3DZ == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect3DZ\n"); + return; + } + + vecX = (double *)malloc(nX * sizeof(double)); + if (vecX == NULL) { + printf("waveVectCompute.cpp : No memory available for vecX\n"); + return; + } + + vecY = (double *)malloc(nY * sizeof(double)); + if (vecY == NULL) { + printf("waveVectCompute.cpp : No memory available for vecY\n"); + return; + } + + vecZ = (double *)malloc(nZ * sizeof(double)); + if (vecZ == NULL) { + printf("waveVectCompute.cpp : No memory available for vecZ\n"); + return; + } + +// printf("memory allocation done.\n"); + + waveVectorCompute1D(nX,vecX); + waveVectorCompute1D(nY,vecY); + waveVectorCompute1D(nZ,vecZ); +// printf("waveVectorCompute1D: done!\n"); + + for(k = 0; k < nZ; k++) { +// printf("k=%d\n",k); + for(j = 0; j < nY; j++) { +// printf("j=%d: ",j); + for(i = 0; i < nX; i++) { + maille = i + (j + (k)*nY)*nX; +// waveVect3DX[maille] = vecX[i]/(nX*dX); +// waveVect3DY[maille] = vecY[j]/(nY*dY); +// waveVect3DZ[maille] = vecZ[k]/(nZ*dZ); + waveVect3DX[maille] = vecX[i]; + waveVect3DY[maille] = vecY[j]; + waveVect3DZ[maille] = vecZ[k]; +// printf("i=%d: %f ",i,vecZ[k]); + } +// printf("\n"); + } + } +// printf("waveVector3DX, Y and Z rearanged\n"); + free(vecX); + free(vecY); + free(vecZ); + if (waveVect == NULL) { + printf("allocate memory for waveVect\n"); + waveVect = (double *) malloc((nTot+1)*sizeof(double)); + if (waveVect == NULL) { + printf("waveVectCompute.cpp : No memory available for waveVect\n"); + return; + } + printf("after allocate memory for waveVect\n"); + } + + for (i=1;i<=nTot;i++) { + waveVect[i] = nDir[0]*waveVect3DX[i-1] + nDir[1]*waveVect3DY[i-1] + nDir[2]*waveVect3DZ[i-1]; +// printf("waveVect[%d] = %f\n",i,waveVect[i]); + } +// printf("waveVector rearanged\n"); + + free(waveVect3DX); + free(waveVect3DY); + free(waveVect3DZ); + +} + +void waveVectorCompute1D(int n,double *vec){ + + int midPoint,k; + + if(ceil(n/2) - floor(n/2) < 1.) { +// printf("coucou\n"); +/*n is even */ + midPoint = (int) floor(n/2); + vec[midPoint] = (double) midPoint; + } else { +/*n is odd */ + midPoint = (int) floor(n/2)-1; + vec[midPoint] = (double) midPoint+1; + } + for (k=1;k +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + /* string filename;*/ + /*struct realization_mod *realin;*/ + + + /*save the permeability realization*/ + fp = fopen(filename, "w"); +/* printf("writefile.c : (*realin).vector[0] %f\n",(*realin).vector[0]); */ +/* (*realin).vector[0]=1.1; */ + for (i=0;i<(*realin).n;i++) + fprintf(fp,"%15.10f\n",(*realin).vector[i]); + fclose(fp); + return; +} diff --git a/fftma_module/gen/sources/writefile_bin.c b/fftma_module/gen/sources/writefile_bin.c new file mode 100755 index 0000000..8df2da8 --- /dev/null +++ b/fftma_module/gen/sources/writefile_bin.c @@ -0,0 +1,33 @@ +#include +#include +#include +#include +#include +#include +#include "genlib.h" +#include "geostat.h" + +/*writefile */ +/* write in the file "filename" the vector values of a */ +/* realization_mod variable */ +/* filename: explicit */ +/* realin: structure defining a realization */ + +void writefile_bin(string filename, struct realization_mod *realin) +{ + FILE *fp; + int i; + double *prout; + + /*save the permeability realization*/ + fp = fopen(filename, "w"); + + for (i=0;i<(*realin).n;i++) + { + prout=(*realin).vector; + fwrite(&prout[i],sizeof(double),1,fp); + } + + fclose(fp); + return; +} diff --git a/fftma_module/ref/FINALrefine.c b/fftma_module/ref/FINALrefine.c new file mode 100644 index 0000000..27fbcb9 --- /dev/null +++ b/fftma_module/ref/FINALrefine.c @@ -0,0 +1,200 @@ +/* Wrap an array refinement function using the Numpy-C-API. */ + +#include +#include +#define NDIM 3 + + +///// +/* +int refine(double** in_dataptr, NpyIter* in_iter, NpyIter_IterNextFunc* in_iternext, long nz, long ny, long nx, long rz, long ry, long rx, double* r) +{ + long x, y, z, cur, curnextlayerx, curlayery, curnextlayery, curlayerz, curnextlayerz; + cur=0; + + clock_t ti, tf; + ti=clock(); + + for(z=0;z np.ndarray, np.dtype(' +#include + +#define NBDIM 3 + +/* wrapped refine function */ +static PyObject* refine(PyObject* self, PyObject* args) +{ + PyArrayObject* in_array; + int rx, ry, rz; + PyObject* out_array; + NpyIter* in_iter; + NpyIter* out_iter; + NpyIter_IterNextFunc* in_iternext; + NpyIter_IterNextFunc* out_iternext; + + /* parse single numpy array argument */ + if (!PyArg_ParseTuple(args, "O!iii", &PyArray_Type, &in_array, &rz, &ry, &rx)) + return NULL; + if (PyArray_NDIM(in_array) != NBDIM) + return NULL; + + PyArray_Descr out_descr; + out_descr=*PyArray_DESCR(in_array); + + + + /* construct the output array, like the input array */ + out_array = PyArray_NewFromDescr(&PyArray_Type, out_descr, NBDIM, dims, NULL, data, NPY_ARRAY_OWNDATA, NULL); + if (out_array == NULL) + return NULL; + + /* create the iterators */ + in_iter = NpyIter_New(in_array, NPY_ITER_READONLY, NPY_KEEPORDER, NPY_NO_CASTING, NULL); + if (in_iter == NULL) + goto fail; + + out_iter = NpyIter_New((PyArrayObject*)out_array, NPY_ITER_READWRITE, NPY_KEEPORDER, NPY_NO_CASTING, NULL); + if (out_iter == NULL) { + NpyIter_Deallocate(in_iter); + goto fail; + } + + in_iternext = NpyIter_GetIterNext(in_iter, NULL); + out_iternext = NpyIter_GetIterNext(out_iter, NULL); + if (in_iternext == NULL || out_iternext == NULL) { + NpyIter_Deallocate(in_iter); + NpyIter_Deallocate(out_iter); + goto fail; + } + + + + double** in_dataptr = (double**) NpyIter_GetDataPtrArray(in_iter); + double** out_dataptr = (double**) NpyIter_GetDataPtrArray(out_iter); + + /* iterate over the arrays */ + do { + **out_dataptr = cos(**in_dataptr); + } while(in_iternext(in_iter) && out_iternext(out_iter)); + + /* clean up and return the result */ + NpyIter_Deallocate(in_iter); + NpyIter_Deallocate(out_iter); + Py_INCREF(out_array); + return out_array; + + /* in case bad things happen */ + fail: + Py_XDECREF(out_array); + return NULL; +} + +/* define functions in module */ +static PyMethodDef RefineMethods[] = +{ + {"refine", refine, METH_VARARGS, "Refines a numpy array"}, + {NULL, NULL, 0, NULL} +}; + +static struct PyModuleDef crefineDef = +{ + PyModuleDef_HEAD_INIT, + "refine", "", + -1, + RefineMethods +}; + + +import_array(); +PyMODINIT_FUNC +PyInit_refine(void) +{ + return PyModule_Create(&crefineDef); +} + diff --git a/fftma_module/ref/refine.c b/fftma_module/ref/refine.c new file mode 100644 index 0000000..123ee5f --- /dev/null +++ b/fftma_module/ref/refine.c @@ -0,0 +1,96 @@ +#include +#include +#include +#include + + +int refine(double* array, long nx, long ny, long nz, int rx, int ry, int rz, double* r)//////, FILE* pf) +{ + long x, y, z, curr=0, cura=0, curraux=0, currnext=0, curraux2=0, currnext2=0; + int i, j, k; + ///////double* r=(double*)malloc(sizeof(double)*nz*nx*ny*rz*rx*ry); + ///////if(r==(double*)NULL) puts("not enough memory output"); + /////////////////npywheader(rx*nx, ry*ny, rz*nz, pf); + + + + clock_t t1, t2; + t1=clock(); + + + + for(z=0;z +#include +#include +#include + + +int refine(double* array, long nx, long ny, long nz, long rx, long ry, long rz, double* r) +{ + long x, y, z, cur, cura, curnextlayerx, curlayery, curnextlayery, curlayerz, curnextlayerz; +// double* r=(double*)malloc(sizeof(double)*nx*rx*ny*ry*nz*rz); +// if(r==(double*)NULL) return NULL; + cur=0; + cura=0; + int i, rxint=(int)rx; + + clock_t t1, t2; + t1=clock(); + + + for(z=0;z> $HOME/.bashrc - -echo "export LD_LIBRARY_PATH=\$LD_LIBRARY_PATH:\$HOME/opt/openmpi/lib" >> $HOME/.bashrc - -source ~/.$1rc - -cd .. - -# install miniconda - -curl https://repo.anaconda.com/miniconda/Miniconda3-py39_4.10.3-Linux-x86_64.sh --output Miniconda3-py39_4.10.3-Linux-x86_64.sh - -bash Miniconda3-py39_4.10.3-Linux-x86_64.sh -b - -source ~/.$1rc - -# create python 2.7 environment - -conda init $1 - -source ~/.$1rc - -conda create -n py2_7 python=2.7 -conda activate py2_7 - -pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose - -# setup petsc - -git clone https://gitlab.com/petsc/petsc - -cd petsc - -git checkout maint-3.8 -./configure --with-cc=mpicc --with-cxx=mpicxx --with-fc=mpif90 --download-fblaslapack --with-debugging=0 COPTFLAGS='-O3 -march=native -mtune=native' CXXOPTFLAGS='-O3 -march=native -mtune=native' FOPTFLAGS='-O3 -march=native -mtune=native' - -make PETSC_DIR=$WORKSPACE/petsc PETSC_ARCH=arch-linux2-c-opt all - -make PETSC_DIR=$WORKSPACE/petsc PETSC_ARCH=arch-linux-c-opt check - -cd .. +sudo apt install openmpi-bin # setup petsc4py -git clone https://Icolecchio@bitbucket.org/petsc/petsc4py.git -cd petsc4py -git checkout maint-3.8 -export PETSC_DIR=$WORKSPACE/petsc -python setup.py build -python setup.py install --user -python setup.py test \ No newline at end of file +export PETSC_CONFIGURE_OPTIONS="--download-fblaslapack --download-chaco --download-hdf5" +pip3 install petsc petsc4py \ No newline at end of file diff --git a/script_install_py2.sh b/script_install_py2.sh new file mode 100755 index 0000000..179d18c --- /dev/null +++ b/script_install_py2.sh @@ -0,0 +1,71 @@ +#!/bin/bash + +export WORKSPACE=$(pwd) + +# gfortran + +sudo apt install build-essential +sudo apt install gfortran +gsettings set org.gnome.nautilus.preferences default-folder-viewer 'list-view' + +# install open mpi 2.1.1 + +curl https://download.open-mpi.org/release/open-mpi/v2.1/openmpi-2.1.1.tar.bz2 --output openmpi-2.1.1.tar.bz2 +tar -jxf openmpi-2.1.1.tar.bz2 +cd openmpi-2.1.1 + +./configure --prefix=$HOME/opt/openmpi +make all +make install + +echo "export PATH=\$PATH:\$HOME/opt/openmpi/bin" >> $HOME/.bashrc + +echo "export LD_LIBRARY_PATH=\$LD_LIBRARY_PATH:\$HOME/opt/openmpi/lib" >> $HOME/.bashrc + +source ~/.$1rc + +cd .. + +# install miniconda + +curl https://repo.anaconda.com/miniconda/Miniconda3-py39_4.10.3-Linux-x86_64.sh --output Miniconda3-py39_4.10.3-Linux-x86_64.sh + +bash Miniconda3-py39_4.10.3-Linux-x86_64.sh -b + +source ~/.$1rc + +# create python 2.7 environment + +conda init $1 + +source ~/.$1rc + +conda create -n py2_7 python=2.7 +conda activate py2_7 + +pip install --user numpy scipy matplotlib ipython jupyter pandas sympy nose + +# setup petsc + +git clone https://gitlab.com/petsc/petsc + +cd petsc + +git checkout maint-3.8 +./configure --with-cc=mpicc --with-cxx=mpicxx --with-fc=mpif90 --download-fblaslapack --with-debugging=0 COPTFLAGS='-O3 -march=native -mtune=native' CXXOPTFLAGS='-O3 -march=native -mtune=native' FOPTFLAGS='-O3 -march=native -mtune=native' + +make PETSC_DIR=$WORKSPACE/petsc PETSC_ARCH=arch-linux2-c-opt all + +make PETSC_DIR=$WORKSPACE/petsc PETSC_ARCH=arch-linux-c-opt check + +cd .. + +# setup petsc4py + +git clone https://Icolecchio@bitbucket.org/petsc/petsc4py.git +cd petsc4py +git checkout maint-3.8 +export PETSC_DIR=$WORKSPACE/petsc +python setup.py build +python setup.py install --user +python setup.py test \ No newline at end of file diff --git a/test_loop/0/Cmap.npy b/test_loop/0/Cmap.npy new file mode 100644 index 0000000..4210604 Binary files /dev/null and b/test_loop/0/Cmap.npy differ diff --git a/test_loop/0/ConnSummary.txt b/test_loop/0/ConnSummary.txt new file mode 100644 index 0000000..31a8452 --- /dev/null +++ b/test_loop/0/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.437680244445800781e-01 +8.036789380314167675e-01 +4.117019413334135902e-02 diff --git a/test_loop/0/ConnectivityMetrics/16.npy b/test_loop/0/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..215fa24 Binary files /dev/null and b/test_loop/0/ConnectivityMetrics/16.npy differ diff --git a/test_loop/0/ConnectivityMetrics/4.npy b/test_loop/0/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..11989c4 Binary files /dev/null and b/test_loop/0/ConnectivityMetrics/4.npy differ diff --git a/test_loop/0/ConnectivityMetrics/8.npy b/test_loop/0/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..0d226a4 Binary files /dev/null and b/test_loop/0/ConnectivityMetrics/8.npy differ diff --git a/test_loop/0/D.npy b/test_loop/0/D.npy new file mode 100644 index 0000000..ffde285 Binary files /dev/null and b/test_loop/0/D.npy differ diff --git a/test_loop/0/GenParams.txt b/test_loop/0/GenParams.txt new file mode 100644 index 0000000..77f3c8f --- /dev/null +++ b/test_loop/0/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.421949386596679688e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/0/GlobalConnectivityMetrics/16.npy b/test_loop/0/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..215fa24 Binary files /dev/null and b/test_loop/0/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/0/GlobalConnectivityMetrics/4.npy b/test_loop/0/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..ffb9ae4 Binary files /dev/null and b/test_loop/0/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/0/GlobalConnectivityMetrics/8.npy b/test_loop/0/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..0b40d1c Binary files /dev/null and b/test_loop/0/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/0/KpostProcess/Kd1.npy b/test_loop/0/KpostProcess/Kd1.npy new file mode 100644 index 0000000..c5bdbd2 Binary files /dev/null and b/test_loop/0/KpostProcess/Kd1.npy differ diff --git a/test_loop/0/KpostProcess/Kd16.npy b/test_loop/0/KpostProcess/Kd16.npy new file mode 100644 index 0000000..0184a59 Binary files /dev/null and b/test_loop/0/KpostProcess/Kd16.npy differ diff --git a/test_loop/0/KpostProcess/Kd2.npy b/test_loop/0/KpostProcess/Kd2.npy new file mode 100644 index 0000000..85932a4 Binary files /dev/null and b/test_loop/0/KpostProcess/Kd2.npy differ diff --git a/test_loop/0/KpostProcess/Kd4.npy b/test_loop/0/KpostProcess/Kd4.npy new file mode 100644 index 0000000..ca38d28 Binary files /dev/null and b/test_loop/0/KpostProcess/Kd4.npy differ diff --git a/test_loop/0/KpostProcess/Kd8.npy b/test_loop/0/KpostProcess/Kd8.npy new file mode 100644 index 0000000..4e63985 Binary files /dev/null and b/test_loop/0/KpostProcess/Kd8.npy differ diff --git a/test_loop/0/KpostProcess/Kperm2.npy b/test_loop/0/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..87918f5 Binary files /dev/null and b/test_loop/0/KpostProcess/Kperm2.npy differ diff --git a/test_loop/0/KpostProcess/Kperm4.npy b/test_loop/0/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..87918f5 Binary files /dev/null and b/test_loop/0/KpostProcess/Kperm4.npy differ diff --git a/test_loop/0/KpostProcess/Kperm8.npy b/test_loop/0/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..87918f5 Binary files /dev/null and b/test_loop/0/KpostProcess/Kperm8.npy differ diff --git a/test_loop/0/KpostProcess/Kv1.npy b/test_loop/0/KpostProcess/Kv1.npy new file mode 100644 index 0000000..2a763f8 Binary files /dev/null and b/test_loop/0/KpostProcess/Kv1.npy differ diff --git a/test_loop/0/KpostProcess/Kv16.npy b/test_loop/0/KpostProcess/Kv16.npy new file mode 100644 index 0000000..22572f8 Binary files /dev/null and b/test_loop/0/KpostProcess/Kv16.npy differ diff --git a/test_loop/0/KpostProcess/Kv2.npy b/test_loop/0/KpostProcess/Kv2.npy new file mode 100644 index 0000000..18bcd08 Binary files /dev/null and b/test_loop/0/KpostProcess/Kv2.npy differ diff --git a/test_loop/0/KpostProcess/Kv4.npy b/test_loop/0/KpostProcess/Kv4.npy new file mode 100644 index 0000000..2ab2fc8 Binary files /dev/null and b/test_loop/0/KpostProcess/Kv4.npy differ diff --git a/test_loop/0/KpostProcess/Kv8.npy b/test_loop/0/KpostProcess/Kv8.npy new file mode 100644 index 0000000..77ecd44 Binary files /dev/null and b/test_loop/0/KpostProcess/Kv8.npy differ diff --git a/test_loop/0/P.npy b/test_loop/0/P.npy new file mode 100644 index 0000000..62caf9c Binary files /dev/null and b/test_loop/0/P.npy differ diff --git a/test_loop/0/PosKeffSummary.txt b/test_loop/0/PosKeffSummary.txt new file mode 100644 index 0000000..435d4b0 --- /dev/null +++ b/test_loop/0/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.044456438450047153e-02 +2.093990598307741979e-02 +1.699991226196289062e-01 +8.312436538256562021e-03 diff --git a/test_loop/0/RunTimes.out b/test_loop/0/RunTimes.out new file mode 100644 index 0000000..8306085 --- /dev/null +++ b/test_loop/0/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.322577953339 +Solver: 0.312026023865 +Keff: 0.02097657095221267 +N_cores: 1 diff --git a/test_loop/0/SolverRes.txt b/test_loop/0/SolverRes.txt new file mode 100644 index 0000000..929fa72 --- /dev/null +++ b/test_loop/0/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.097657095221266976e-02 +2.000000000000000000e+00 +6.346039772033691406e-01 +1.000000000000000000e+00 diff --git a/test_loop/0/V.npy b/test_loop/0/V.npy new file mode 100644 index 0000000..4423d0d Binary files /dev/null and b/test_loop/0/V.npy differ diff --git a/test_loop/0/connec.out b/test_loop/0/connec.out new file mode 100644 index 0000000..e6ae057 --- /dev/null +++ b/test_loop/0/connec.out @@ -0,0 +1,4 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.00000000 diff --git a/test_loop/0/k.npy b/test_loop/0/k.npy new file mode 100644 index 0000000..0228264 Binary files /dev/null and b/test_loop/0/k.npy differ diff --git a/test_loop/0/lc.txt b/test_loop/0/lc.txt new file mode 100644 index 0000000..314dc31 --- /dev/null +++ b/test_loop/0/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.617108983572631331e+00 +4.617108983572631331e+00 +5.221092552049793944e+00 diff --git a/test_loop/0/tkperm_sub.txt b/test_loop/0/tkperm_sub.txt new file mode 100644 index 0000000..03fb9d3 --- /dev/null +++ b/test_loop/0/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.433069229125976562e-01 +1.709461212158203125e-04 +1.268386840820312500e-04 diff --git a/test_loop/1/Cmap.npy b/test_loop/1/Cmap.npy new file mode 100644 index 0000000..571d269 Binary files /dev/null and b/test_loop/1/Cmap.npy differ diff --git a/test_loop/1/ConnSummary.txt b/test_loop/1/ConnSummary.txt new file mode 100644 index 0000000..91a19cb --- /dev/null +++ b/test_loop/1/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.130840301513671875e-01 +8.103774673900496772e-01 +3.892242871984301356e-02 diff --git a/test_loop/1/ConnectivityMetrics/16.npy b/test_loop/1/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d6496f5 Binary files /dev/null and b/test_loop/1/ConnectivityMetrics/16.npy differ diff --git a/test_loop/1/ConnectivityMetrics/4.npy b/test_loop/1/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..595b57b Binary files /dev/null and b/test_loop/1/ConnectivityMetrics/4.npy differ diff --git a/test_loop/1/ConnectivityMetrics/8.npy b/test_loop/1/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6d74727 Binary files /dev/null and b/test_loop/1/ConnectivityMetrics/8.npy differ diff --git a/test_loop/1/D.npy b/test_loop/1/D.npy new file mode 100644 index 0000000..6764c62 Binary files /dev/null and b/test_loop/1/D.npy differ diff --git a/test_loop/1/GenParams.txt b/test_loop/1/GenParams.txt new file mode 100644 index 0000000..2203a50 --- /dev/null +++ b/test_loop/1/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.468057632446289062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/1/GlobalConnectivityMetrics/16.npy b/test_loop/1/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d6496f5 Binary files /dev/null and b/test_loop/1/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/1/GlobalConnectivityMetrics/4.npy b/test_loop/1/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..ba2a9b5 Binary files /dev/null and b/test_loop/1/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/1/GlobalConnectivityMetrics/8.npy b/test_loop/1/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..e85d5cf Binary files /dev/null and b/test_loop/1/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/1/KpostProcess/Kd16.npy b/test_loop/1/KpostProcess/Kd16.npy new file mode 100644 index 0000000..76397c4 Binary files /dev/null and b/test_loop/1/KpostProcess/Kd16.npy differ diff --git a/test_loop/1/KpostProcess/Kd4.npy b/test_loop/1/KpostProcess/Kd4.npy new file mode 100644 index 0000000..4eb5cf0 Binary files /dev/null and b/test_loop/1/KpostProcess/Kd4.npy differ diff --git a/test_loop/1/KpostProcess/Kd8.npy b/test_loop/1/KpostProcess/Kd8.npy new file mode 100644 index 0000000..a54c9d9 Binary files /dev/null and b/test_loop/1/KpostProcess/Kd8.npy differ diff --git a/test_loop/1/KpostProcess/Kperm4.npy b/test_loop/1/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..6d4b6bf Binary files /dev/null and b/test_loop/1/KpostProcess/Kperm4.npy differ diff --git a/test_loop/1/KpostProcess/Kperm8.npy b/test_loop/1/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..6d4b6bf Binary files /dev/null and b/test_loop/1/KpostProcess/Kperm8.npy differ diff --git a/test_loop/1/KpostProcess/Kv16.npy b/test_loop/1/KpostProcess/Kv16.npy new file mode 100644 index 0000000..12e9405 Binary files /dev/null and b/test_loop/1/KpostProcess/Kv16.npy differ diff --git a/test_loop/1/KpostProcess/Kv4.npy b/test_loop/1/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d57955a Binary files /dev/null and b/test_loop/1/KpostProcess/Kv4.npy differ diff --git a/test_loop/1/KpostProcess/Kv8.npy b/test_loop/1/KpostProcess/Kv8.npy new file mode 100644 index 0000000..42e7aee Binary files /dev/null and b/test_loop/1/KpostProcess/Kv8.npy differ diff --git a/test_loop/1/P.npy b/test_loop/1/P.npy new file mode 100644 index 0000000..84dc218 Binary files /dev/null and b/test_loop/1/P.npy differ diff --git a/test_loop/1/PosKeffSummary.txt b/test_loop/1/PosKeffSummary.txt new file mode 100644 index 0000000..6abccf8 --- /dev/null +++ b/test_loop/1/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.226209553813355765e-02 +2.286500870826872062e-02 +4.626035690307617188e-03 +3.054682265629026228e-01 diff --git a/test_loop/1/RunTimes.out b/test_loop/1/RunTimes.out new file mode 100644 index 0000000..1725923 --- /dev/null +++ b/test_loop/1/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.324597120285 +Solver: 0.276505947113 +Keff: 0.022595141113124082 +N_cores: 1 diff --git a/test_loop/1/SolverRes.txt b/test_loop/1/SolverRes.txt new file mode 100644 index 0000000..6421ed6 --- /dev/null +++ b/test_loop/1/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.259514111312408216e-02 +2.000000000000000000e+00 +6.011030673980712891e-01 +1.000000000000000000e+00 diff --git a/test_loop/1/V.npy b/test_loop/1/V.npy new file mode 100644 index 0000000..f2a34cc Binary files /dev/null and b/test_loop/1/V.npy differ diff --git a/test_loop/1/connec.out b/test_loop/1/connec.out new file mode 100644 index 0000000..f511dc2 --- /dev/null +++ b/test_loop/1/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.125000000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/1/k.npy b/test_loop/1/k.npy new file mode 100644 index 0000000..bd2116d Binary files /dev/null and b/test_loop/1/k.npy differ diff --git a/test_loop/1/lc.txt b/test_loop/1/lc.txt new file mode 100644 index 0000000..1ef4537 --- /dev/null +++ b/test_loop/1/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +8.214006169837110960e+00 +8.214006169837110960e+00 +2.860537317826781223e+00 diff --git a/test_loop/1/tkperm_sub.txt b/test_loop/1/tkperm_sub.txt new file mode 100644 index 0000000..7203fb5 --- /dev/null +++ b/test_loop/1/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.183081150054931641e-01 +1.590251922607421875e-04 diff --git a/test_loop/10/Cmap.npy b/test_loop/10/Cmap.npy new file mode 100644 index 0000000..6ac1c94 Binary files /dev/null and b/test_loop/10/Cmap.npy differ diff --git a/test_loop/10/ConnSummary.txt b/test_loop/10/ConnSummary.txt new file mode 100644 index 0000000..188d0a3 --- /dev/null +++ b/test_loop/10/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.578839778900146484e-01 +8.596443918313970700e-01 +2.408955804327898159e-02 diff --git a/test_loop/10/ConnectivityMetrics/16.npy b/test_loop/10/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c0a28e2 Binary files /dev/null and b/test_loop/10/ConnectivityMetrics/16.npy differ diff --git a/test_loop/10/ConnectivityMetrics/4.npy b/test_loop/10/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..7d7dda3 Binary files /dev/null and b/test_loop/10/ConnectivityMetrics/4.npy differ diff --git a/test_loop/10/ConnectivityMetrics/8.npy b/test_loop/10/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..588b1f6 Binary files /dev/null and b/test_loop/10/ConnectivityMetrics/8.npy differ diff --git a/test_loop/10/D.npy b/test_loop/10/D.npy new file mode 100644 index 0000000..deb36ad Binary files /dev/null and b/test_loop/10/D.npy differ diff --git a/test_loop/10/GenParams.txt b/test_loop/10/GenParams.txt new file mode 100644 index 0000000..d6dea7e --- /dev/null +++ b/test_loop/10/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +1.008915901184082031e-02 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/10/GlobalConnectivityMetrics/16.npy b/test_loop/10/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c0a28e2 Binary files /dev/null and b/test_loop/10/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/10/GlobalConnectivityMetrics/4.npy b/test_loop/10/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..4f0e5fa Binary files /dev/null and b/test_loop/10/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/10/GlobalConnectivityMetrics/8.npy b/test_loop/10/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..fd75484 Binary files /dev/null and b/test_loop/10/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/10/KpostProcess/Kd1.npy b/test_loop/10/KpostProcess/Kd1.npy new file mode 100644 index 0000000..3b25cc7 Binary files /dev/null and b/test_loop/10/KpostProcess/Kd1.npy differ diff --git a/test_loop/10/KpostProcess/Kd16.npy b/test_loop/10/KpostProcess/Kd16.npy new file mode 100644 index 0000000..478e2b0 Binary files /dev/null and b/test_loop/10/KpostProcess/Kd16.npy differ diff --git a/test_loop/10/KpostProcess/Kd2.npy b/test_loop/10/KpostProcess/Kd2.npy new file mode 100644 index 0000000..927dce8 Binary files /dev/null and b/test_loop/10/KpostProcess/Kd2.npy differ diff --git a/test_loop/10/KpostProcess/Kd4.npy b/test_loop/10/KpostProcess/Kd4.npy new file mode 100644 index 0000000..f757ead Binary files /dev/null and b/test_loop/10/KpostProcess/Kd4.npy differ diff --git a/test_loop/10/KpostProcess/Kd8.npy b/test_loop/10/KpostProcess/Kd8.npy new file mode 100644 index 0000000..4c5ec00 Binary files /dev/null and b/test_loop/10/KpostProcess/Kd8.npy differ diff --git a/test_loop/10/KpostProcess/Kperm2.npy b/test_loop/10/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..c45fe31 Binary files /dev/null and b/test_loop/10/KpostProcess/Kperm2.npy differ diff --git a/test_loop/10/KpostProcess/Kperm4.npy b/test_loop/10/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..c45fe31 Binary files /dev/null and b/test_loop/10/KpostProcess/Kperm4.npy differ diff --git a/test_loop/10/KpostProcess/Kperm8.npy b/test_loop/10/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..c45fe31 Binary files /dev/null and b/test_loop/10/KpostProcess/Kperm8.npy differ diff --git a/test_loop/10/KpostProcess/Kv1.npy b/test_loop/10/KpostProcess/Kv1.npy new file mode 100644 index 0000000..0733027 Binary files /dev/null and b/test_loop/10/KpostProcess/Kv1.npy differ diff --git a/test_loop/10/KpostProcess/Kv16.npy b/test_loop/10/KpostProcess/Kv16.npy new file mode 100644 index 0000000..cdd645f Binary files /dev/null and b/test_loop/10/KpostProcess/Kv16.npy differ diff --git a/test_loop/10/KpostProcess/Kv2.npy b/test_loop/10/KpostProcess/Kv2.npy new file mode 100644 index 0000000..fe98b47 Binary files /dev/null and b/test_loop/10/KpostProcess/Kv2.npy differ diff --git a/test_loop/10/KpostProcess/Kv4.npy b/test_loop/10/KpostProcess/Kv4.npy new file mode 100644 index 0000000..6ebffb9 Binary files /dev/null and b/test_loop/10/KpostProcess/Kv4.npy differ diff --git a/test_loop/10/KpostProcess/Kv8.npy b/test_loop/10/KpostProcess/Kv8.npy new file mode 100644 index 0000000..48604e1 Binary files /dev/null and b/test_loop/10/KpostProcess/Kv8.npy differ diff --git a/test_loop/10/P.npy b/test_loop/10/P.npy new file mode 100644 index 0000000..8d78723 Binary files /dev/null and b/test_loop/10/P.npy differ diff --git a/test_loop/10/PosKeffSummary.txt b/test_loop/10/PosKeffSummary.txt new file mode 100644 index 0000000..079b72b --- /dev/null +++ b/test_loop/10/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.053728556426364898e-02 +4.123944443032588614e-02 +1.776230335235595703e-01 +6.186535660834491246e-03 diff --git a/test_loop/10/RunTimes.out b/test_loop/10/RunTimes.out new file mode 100644 index 0000000..55ab250 --- /dev/null +++ b/test_loop/10/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.356295824051 +Solver: 0.41558098793 +Keff: 0.041274959938125966 +N_cores: 1 diff --git a/test_loop/10/SolverRes.txt b/test_loop/10/SolverRes.txt new file mode 100644 index 0000000..ecad0e4 --- /dev/null +++ b/test_loop/10/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.127495993812596575e-02 +2.000000000000000000e+00 +7.718768119812011719e-01 +1.000000000000000000e+00 diff --git a/test_loop/10/V.npy b/test_loop/10/V.npy new file mode 100644 index 0000000..44c7bcb Binary files /dev/null and b/test_loop/10/V.npy differ diff --git a/test_loop/10/connec.out b/test_loop/10/connec.out new file mode 100644 index 0000000..cd959e2 --- /dev/null +++ b/test_loop/10/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 4.68750000E-02 + NCC : 1 diff --git a/test_loop/10/k.npy b/test_loop/10/k.npy new file mode 100644 index 0000000..1f72b8a Binary files /dev/null and b/test_loop/10/k.npy differ diff --git a/test_loop/10/lc.txt b/test_loop/10/lc.txt new file mode 100644 index 0000000..b6d17f0 --- /dev/null +++ b/test_loop/10/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.352424369794015924e+00 +4.352424369794015924e+00 +4.765940439307880361e+00 diff --git a/test_loop/10/tkperm_sub.txt b/test_loop/10/tkperm_sub.txt new file mode 100644 index 0000000..910977b --- /dev/null +++ b/test_loop/10/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.613311290740966797e-01 +2.298355102539062500e-04 +1.931190490722656250e-04 diff --git a/test_loop/11/Cmap.npy b/test_loop/11/Cmap.npy new file mode 100644 index 0000000..8c4c0df Binary files /dev/null and b/test_loop/11/Cmap.npy differ diff --git a/test_loop/11/ConnSummary.txt b/test_loop/11/ConnSummary.txt new file mode 100644 index 0000000..eb7aad1 --- /dev/null +++ b/test_loop/11/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.674479961395263672e-01 +7.637536920737787449e-01 +5.005919049035024299e-02 diff --git a/test_loop/11/ConnectivityMetrics/16.npy b/test_loop/11/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d908c22 Binary files /dev/null and b/test_loop/11/ConnectivityMetrics/16.npy differ diff --git a/test_loop/11/ConnectivityMetrics/4.npy b/test_loop/11/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..2ea3627 Binary files /dev/null and b/test_loop/11/ConnectivityMetrics/4.npy differ diff --git a/test_loop/11/ConnectivityMetrics/8.npy b/test_loop/11/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..42eff37 Binary files /dev/null and b/test_loop/11/ConnectivityMetrics/8.npy differ diff --git a/test_loop/11/D.npy b/test_loop/11/D.npy new file mode 100644 index 0000000..9461df1 Binary files /dev/null and b/test_loop/11/D.npy differ diff --git a/test_loop/11/GenParams.txt b/test_loop/11/GenParams.txt new file mode 100644 index 0000000..7295ac1 --- /dev/null +++ b/test_loop/11/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +3.853082656860351562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/11/GlobalConnectivityMetrics/16.npy b/test_loop/11/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d908c22 Binary files /dev/null and b/test_loop/11/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/11/GlobalConnectivityMetrics/4.npy b/test_loop/11/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..1bd2d42 Binary files /dev/null and b/test_loop/11/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/11/GlobalConnectivityMetrics/8.npy b/test_loop/11/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..b8d675a Binary files /dev/null and b/test_loop/11/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/11/KpostProcess/Kd16.npy b/test_loop/11/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f1030c1 Binary files /dev/null and b/test_loop/11/KpostProcess/Kd16.npy differ diff --git a/test_loop/11/KpostProcess/Kd4.npy b/test_loop/11/KpostProcess/Kd4.npy new file mode 100644 index 0000000..5336917 Binary files /dev/null and b/test_loop/11/KpostProcess/Kd4.npy differ diff --git a/test_loop/11/KpostProcess/Kd8.npy b/test_loop/11/KpostProcess/Kd8.npy new file mode 100644 index 0000000..1b96187 Binary files /dev/null and b/test_loop/11/KpostProcess/Kd8.npy differ diff --git a/test_loop/11/KpostProcess/Kperm4.npy b/test_loop/11/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..a46420b Binary files /dev/null and b/test_loop/11/KpostProcess/Kperm4.npy differ diff --git a/test_loop/11/KpostProcess/Kperm8.npy b/test_loop/11/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..a46420b Binary files /dev/null and b/test_loop/11/KpostProcess/Kperm8.npy differ diff --git a/test_loop/11/KpostProcess/Kv16.npy b/test_loop/11/KpostProcess/Kv16.npy new file mode 100644 index 0000000..227e350 Binary files /dev/null and b/test_loop/11/KpostProcess/Kv16.npy differ diff --git a/test_loop/11/KpostProcess/Kv4.npy b/test_loop/11/KpostProcess/Kv4.npy new file mode 100644 index 0000000..e3b3e1e Binary files /dev/null and b/test_loop/11/KpostProcess/Kv4.npy differ diff --git a/test_loop/11/KpostProcess/Kv8.npy b/test_loop/11/KpostProcess/Kv8.npy new file mode 100644 index 0000000..2ce181e Binary files /dev/null and b/test_loop/11/KpostProcess/Kv8.npy differ diff --git a/test_loop/11/P.npy b/test_loop/11/P.npy new file mode 100644 index 0000000..c28fb70 Binary files /dev/null and b/test_loop/11/P.npy differ diff --git a/test_loop/11/PosKeffSummary.txt b/test_loop/11/PosKeffSummary.txt new file mode 100644 index 0000000..19a4596 --- /dev/null +++ b/test_loop/11/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +9.103683601582237550e-01 +9.244440950626500175e-01 +1.816105842590332031e-02 +7.505284024523124764e-02 diff --git a/test_loop/11/RunTimes.out b/test_loop/11/RunTimes.out new file mode 100644 index 0000000..70bac7b --- /dev/null +++ b/test_loop/11/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.34684586525 +Solver: 0.225963115692 +Keff: 0.9245601203597474 +N_cores: 1 diff --git a/test_loop/11/SolverRes.txt b/test_loop/11/SolverRes.txt new file mode 100644 index 0000000..7d9a3c1 --- /dev/null +++ b/test_loop/11/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +9.245601203597474393e-01 +2.000000000000000000e+00 +5.728089809417724609e-01 +1.000000000000000000e+00 diff --git a/test_loop/11/V.npy b/test_loop/11/V.npy new file mode 100644 index 0000000..3cec81e Binary files /dev/null and b/test_loop/11/V.npy differ diff --git a/test_loop/11/connec.out b/test_loop/11/connec.out new file mode 100644 index 0000000..720a3df --- /dev/null +++ b/test_loop/11/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.328125000 + NCC : 1 + NCC : 2 diff --git a/test_loop/11/k.npy b/test_loop/11/k.npy new file mode 100644 index 0000000..712deca Binary files /dev/null and b/test_loop/11/k.npy differ diff --git a/test_loop/11/lc.txt b/test_loop/11/lc.txt new file mode 100644 index 0000000..5e3c837 --- /dev/null +++ b/test_loop/11/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.581774128037922722e+00 +7.581774128037922722e+00 +2.866897123671480863e+00 diff --git a/test_loop/11/tkperm_sub.txt b/test_loop/11/tkperm_sub.txt new file mode 100644 index 0000000..e6c7527 --- /dev/null +++ b/test_loop/11/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.232449531555175781e-01 +2.279281616210937500e-04 diff --git a/test_loop/12/Cmap.npy b/test_loop/12/Cmap.npy new file mode 100644 index 0000000..5933838 Binary files /dev/null and b/test_loop/12/Cmap.npy differ diff --git a/test_loop/12/ConnSummary.txt b/test_loop/12/ConnSummary.txt new file mode 100644 index 0000000..20f61c0 --- /dev/null +++ b/test_loop/12/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.307199954986572266e-01 +8.581042865659089802e-01 +2.811813651476346987e-02 diff --git a/test_loop/12/ConnectivityMetrics/16.npy b/test_loop/12/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..fc7b0c1 Binary files /dev/null and b/test_loop/12/ConnectivityMetrics/16.npy differ diff --git a/test_loop/12/ConnectivityMetrics/4.npy b/test_loop/12/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..e8311c1 Binary files /dev/null and b/test_loop/12/ConnectivityMetrics/4.npy differ diff --git a/test_loop/12/ConnectivityMetrics/8.npy b/test_loop/12/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..a8177b0 Binary files /dev/null and b/test_loop/12/ConnectivityMetrics/8.npy differ diff --git a/test_loop/12/D.npy b/test_loop/12/D.npy new file mode 100644 index 0000000..9660cf2 Binary files /dev/null and b/test_loop/12/D.npy differ diff --git a/test_loop/12/GenParams.txt b/test_loop/12/GenParams.txt new file mode 100644 index 0000000..76e85d4 --- /dev/null +++ b/test_loop/12/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.083156585693359375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/12/GlobalConnectivityMetrics/16.npy b/test_loop/12/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..fc7b0c1 Binary files /dev/null and b/test_loop/12/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/12/GlobalConnectivityMetrics/4.npy b/test_loop/12/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..fc5ced6 Binary files /dev/null and b/test_loop/12/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/12/GlobalConnectivityMetrics/8.npy b/test_loop/12/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..097e006 Binary files /dev/null and b/test_loop/12/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/12/KpostProcess/Kd1.npy b/test_loop/12/KpostProcess/Kd1.npy new file mode 100644 index 0000000..8fe1f01 Binary files /dev/null and b/test_loop/12/KpostProcess/Kd1.npy differ diff --git a/test_loop/12/KpostProcess/Kd16.npy b/test_loop/12/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c66d831 Binary files /dev/null and b/test_loop/12/KpostProcess/Kd16.npy differ diff --git a/test_loop/12/KpostProcess/Kd2.npy b/test_loop/12/KpostProcess/Kd2.npy new file mode 100644 index 0000000..4746881 Binary files /dev/null and b/test_loop/12/KpostProcess/Kd2.npy differ diff --git a/test_loop/12/KpostProcess/Kd4.npy b/test_loop/12/KpostProcess/Kd4.npy new file mode 100644 index 0000000..9e8c8f3 Binary files /dev/null and b/test_loop/12/KpostProcess/Kd4.npy differ diff --git a/test_loop/12/KpostProcess/Kd8.npy b/test_loop/12/KpostProcess/Kd8.npy new file mode 100644 index 0000000..fd510a4 Binary files /dev/null and b/test_loop/12/KpostProcess/Kd8.npy differ diff --git a/test_loop/12/KpostProcess/Kperm2.npy b/test_loop/12/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..1e01cba Binary files /dev/null and b/test_loop/12/KpostProcess/Kperm2.npy differ diff --git a/test_loop/12/KpostProcess/Kperm4.npy b/test_loop/12/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..1e01cba Binary files /dev/null and b/test_loop/12/KpostProcess/Kperm4.npy differ diff --git a/test_loop/12/KpostProcess/Kperm8.npy b/test_loop/12/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..1e01cba Binary files /dev/null and b/test_loop/12/KpostProcess/Kperm8.npy differ diff --git a/test_loop/12/KpostProcess/Kv1.npy b/test_loop/12/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6a01597 Binary files /dev/null and b/test_loop/12/KpostProcess/Kv1.npy differ diff --git a/test_loop/12/KpostProcess/Kv16.npy b/test_loop/12/KpostProcess/Kv16.npy new file mode 100644 index 0000000..b2d7bac Binary files /dev/null and b/test_loop/12/KpostProcess/Kv16.npy differ diff --git a/test_loop/12/KpostProcess/Kv2.npy b/test_loop/12/KpostProcess/Kv2.npy new file mode 100644 index 0000000..7e40c5a Binary files /dev/null and b/test_loop/12/KpostProcess/Kv2.npy differ diff --git a/test_loop/12/KpostProcess/Kv4.npy b/test_loop/12/KpostProcess/Kv4.npy new file mode 100644 index 0000000..f06821e Binary files /dev/null and b/test_loop/12/KpostProcess/Kv4.npy differ diff --git a/test_loop/12/KpostProcess/Kv8.npy b/test_loop/12/KpostProcess/Kv8.npy new file mode 100644 index 0000000..6c587fc Binary files /dev/null and b/test_loop/12/KpostProcess/Kv8.npy differ diff --git a/test_loop/12/P.npy b/test_loop/12/P.npy new file mode 100644 index 0000000..142a947 Binary files /dev/null and b/test_loop/12/P.npy differ diff --git a/test_loop/12/PosKeffSummary.txt b/test_loop/12/PosKeffSummary.txt new file mode 100644 index 0000000..49920b1 --- /dev/null +++ b/test_loop/12/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.674498924941631467e-02 +4.674099963782440970e-02 +1.617228984832763672e-01 +8.978129630039140274e-03 diff --git a/test_loop/12/RunTimes.out b/test_loop/12/RunTimes.out new file mode 100644 index 0000000..84001a0 --- /dev/null +++ b/test_loop/12/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.331274986267 +Solver: 0.23725104332 +Keff: 0.046272579920370364 +N_cores: 1 diff --git a/test_loop/12/SolverRes.txt b/test_loop/12/SolverRes.txt new file mode 100644 index 0000000..dd60a41 --- /dev/null +++ b/test_loop/12/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.627257992037036444e-02 +2.000000000000000000e+00 +5.685260295867919922e-01 +1.000000000000000000e+00 diff --git a/test_loop/12/V.npy b/test_loop/12/V.npy new file mode 100644 index 0000000..08dfc47 Binary files /dev/null and b/test_loop/12/V.npy differ diff --git a/test_loop/12/connec.out b/test_loop/12/connec.out new file mode 100644 index 0000000..cd959e2 --- /dev/null +++ b/test_loop/12/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 4.68750000E-02 + NCC : 1 diff --git a/test_loop/12/k.npy b/test_loop/12/k.npy new file mode 100644 index 0000000..2f55434 Binary files /dev/null and b/test_loop/12/k.npy differ diff --git a/test_loop/12/lc.txt b/test_loop/12/lc.txt new file mode 100644 index 0000000..a9a6fb1 --- /dev/null +++ b/test_loop/12/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.317402518148261592e+00 +4.317402518148261592e+00 +5.023737915709022950e+00 diff --git a/test_loop/12/tkperm_sub.txt b/test_loop/12/tkperm_sub.txt new file mode 100644 index 0000000..18b7ef5 --- /dev/null +++ b/test_loop/12/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.214949607849121094e-01 +2.470016479492187500e-04 +2.050399780273437500e-04 diff --git a/test_loop/13/Cmap.npy b/test_loop/13/Cmap.npy new file mode 100644 index 0000000..b0508a5 Binary files /dev/null and b/test_loop/13/Cmap.npy differ diff --git a/test_loop/13/ConnSummary.txt b/test_loop/13/ConnSummary.txt new file mode 100644 index 0000000..e54f99f --- /dev/null +++ b/test_loop/13/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.620529174804687500e-01 +8.043244916236435005e-01 +4.654014329364661307e-02 diff --git a/test_loop/13/ConnectivityMetrics/16.npy b/test_loop/13/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..f5c3412 Binary files /dev/null and b/test_loop/13/ConnectivityMetrics/16.npy differ diff --git a/test_loop/13/ConnectivityMetrics/4.npy b/test_loop/13/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1565172 Binary files /dev/null and b/test_loop/13/ConnectivityMetrics/4.npy differ diff --git a/test_loop/13/ConnectivityMetrics/8.npy b/test_loop/13/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..1652fdc Binary files /dev/null and b/test_loop/13/ConnectivityMetrics/8.npy differ diff --git a/test_loop/13/D.npy b/test_loop/13/D.npy new file mode 100644 index 0000000..f4ac2cf Binary files /dev/null and b/test_loop/13/D.npy differ diff --git a/test_loop/13/GenParams.txt b/test_loop/13/GenParams.txt new file mode 100644 index 0000000..e9a9255 --- /dev/null +++ b/test_loop/13/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.236936569213867188e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/13/GlobalConnectivityMetrics/16.npy b/test_loop/13/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..f5c3412 Binary files /dev/null and b/test_loop/13/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/13/GlobalConnectivityMetrics/4.npy b/test_loop/13/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..424f8e8 Binary files /dev/null and b/test_loop/13/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/13/GlobalConnectivityMetrics/8.npy b/test_loop/13/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..8dd7188 Binary files /dev/null and b/test_loop/13/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/13/KpostProcess/Kd16.npy b/test_loop/13/KpostProcess/Kd16.npy new file mode 100644 index 0000000..13a687a Binary files /dev/null and b/test_loop/13/KpostProcess/Kd16.npy differ diff --git a/test_loop/13/KpostProcess/Kd4.npy b/test_loop/13/KpostProcess/Kd4.npy new file mode 100644 index 0000000..e952031 Binary files /dev/null and b/test_loop/13/KpostProcess/Kd4.npy differ diff --git a/test_loop/13/KpostProcess/Kd8.npy b/test_loop/13/KpostProcess/Kd8.npy new file mode 100644 index 0000000..bac63c9 Binary files /dev/null and b/test_loop/13/KpostProcess/Kd8.npy differ diff --git a/test_loop/13/KpostProcess/Kperm4.npy b/test_loop/13/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e503dc7 Binary files /dev/null and b/test_loop/13/KpostProcess/Kperm4.npy differ diff --git a/test_loop/13/KpostProcess/Kperm8.npy b/test_loop/13/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e503dc7 Binary files /dev/null and b/test_loop/13/KpostProcess/Kperm8.npy differ diff --git a/test_loop/13/KpostProcess/Kv16.npy b/test_loop/13/KpostProcess/Kv16.npy new file mode 100644 index 0000000..7c9a713 Binary files /dev/null and b/test_loop/13/KpostProcess/Kv16.npy differ diff --git a/test_loop/13/KpostProcess/Kv4.npy b/test_loop/13/KpostProcess/Kv4.npy new file mode 100644 index 0000000..9bbfe2c Binary files /dev/null and b/test_loop/13/KpostProcess/Kv4.npy differ diff --git a/test_loop/13/KpostProcess/Kv8.npy b/test_loop/13/KpostProcess/Kv8.npy new file mode 100644 index 0000000..4c7c7a4 Binary files /dev/null and b/test_loop/13/KpostProcess/Kv8.npy differ diff --git a/test_loop/13/P.npy b/test_loop/13/P.npy new file mode 100644 index 0000000..03cadf8 Binary files /dev/null and b/test_loop/13/P.npy differ diff --git a/test_loop/13/PosKeffSummary.txt b/test_loop/13/PosKeffSummary.txt new file mode 100644 index 0000000..a6e6d93 --- /dev/null +++ b/test_loop/13/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.223391250863907320e+00 +2.258737353845124751e+00 +6.484985351562500000e-03 +2.095588235294117696e-01 diff --git a/test_loop/13/RunTimes.out b/test_loop/13/RunTimes.out new file mode 100644 index 0000000..a0830db --- /dev/null +++ b/test_loop/13/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.315760850906 +Solver: 0.251914978027 +Keff: 2.2586182230925695 +N_cores: 1 diff --git a/test_loop/13/SolverRes.txt b/test_loop/13/SolverRes.txt new file mode 100644 index 0000000..a84fd65 --- /dev/null +++ b/test_loop/13/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.258618223092569544e+00 +2.000000000000000000e+00 +5.676758289337158203e-01 +1.000000000000000000e+00 diff --git a/test_loop/13/V.npy b/test_loop/13/V.npy new file mode 100644 index 0000000..0cda0b1 Binary files /dev/null and b/test_loop/13/V.npy differ diff --git a/test_loop/13/connec.out b/test_loop/13/connec.out new file mode 100644 index 0000000..d597e95 --- /dev/null +++ b/test_loop/13/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.375000000 + NCC : 1 + NCC : 2 diff --git a/test_loop/13/k.npy b/test_loop/13/k.npy new file mode 100644 index 0000000..051b712 Binary files /dev/null and b/test_loop/13/k.npy differ diff --git a/test_loop/13/lc.txt b/test_loop/13/lc.txt new file mode 100644 index 0000000..5fa2fc9 --- /dev/null +++ b/test_loop/13/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.494473114871352593e+00 +7.494473114871352593e+00 +2.859699856546241925e+00 diff --git a/test_loop/13/tkperm_sub.txt b/test_loop/13/tkperm_sub.txt new file mode 100644 index 0000000..8dd50a5 --- /dev/null +++ b/test_loop/13/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.850810527801513672e-01 +2.100467681884765625e-04 diff --git a/test_loop/14/Cmap.npy b/test_loop/14/Cmap.npy new file mode 100644 index 0000000..83c9656 Binary files /dev/null and b/test_loop/14/Cmap.npy differ diff --git a/test_loop/14/ConnSummary.txt b/test_loop/14/ConnSummary.txt new file mode 100644 index 0000000..4e422eb --- /dev/null +++ b/test_loop/14/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.718919754028320312e-01 +7.605678318378693570e-01 +4.554861177001566508e-02 diff --git a/test_loop/14/ConnectivityMetrics/16.npy b/test_loop/14/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..33df0c1 Binary files /dev/null and b/test_loop/14/ConnectivityMetrics/16.npy differ diff --git a/test_loop/14/ConnectivityMetrics/4.npy b/test_loop/14/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..f12aad1 Binary files /dev/null and b/test_loop/14/ConnectivityMetrics/4.npy differ diff --git a/test_loop/14/ConnectivityMetrics/8.npy b/test_loop/14/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b2eb44a Binary files /dev/null and b/test_loop/14/ConnectivityMetrics/8.npy differ diff --git a/test_loop/14/D.npy b/test_loop/14/D.npy new file mode 100644 index 0000000..1013485 Binary files /dev/null and b/test_loop/14/D.npy differ diff --git a/test_loop/14/GenParams.txt b/test_loop/14/GenParams.txt new file mode 100644 index 0000000..daee820 --- /dev/null +++ b/test_loop/14/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.470109939575195312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/14/GlobalConnectivityMetrics/16.npy b/test_loop/14/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..33df0c1 Binary files /dev/null and b/test_loop/14/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/14/GlobalConnectivityMetrics/4.npy b/test_loop/14/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..dcff259 Binary files /dev/null and b/test_loop/14/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/14/GlobalConnectivityMetrics/8.npy b/test_loop/14/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..6b06dbc Binary files /dev/null and b/test_loop/14/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/14/KpostProcess/Kd1.npy b/test_loop/14/KpostProcess/Kd1.npy new file mode 100644 index 0000000..3b8f170 Binary files /dev/null and b/test_loop/14/KpostProcess/Kd1.npy differ diff --git a/test_loop/14/KpostProcess/Kd16.npy b/test_loop/14/KpostProcess/Kd16.npy new file mode 100644 index 0000000..59b4ae7 Binary files /dev/null and b/test_loop/14/KpostProcess/Kd16.npy differ diff --git a/test_loop/14/KpostProcess/Kd2.npy b/test_loop/14/KpostProcess/Kd2.npy new file mode 100644 index 0000000..33ea544 Binary files /dev/null and b/test_loop/14/KpostProcess/Kd2.npy differ diff --git a/test_loop/14/KpostProcess/Kd4.npy b/test_loop/14/KpostProcess/Kd4.npy new file mode 100644 index 0000000..8797049 Binary files /dev/null and b/test_loop/14/KpostProcess/Kd4.npy differ diff --git a/test_loop/14/KpostProcess/Kd8.npy b/test_loop/14/KpostProcess/Kd8.npy new file mode 100644 index 0000000..54db99b Binary files /dev/null and b/test_loop/14/KpostProcess/Kd8.npy differ diff --git a/test_loop/14/KpostProcess/Kperm2.npy b/test_loop/14/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..cf5766a Binary files /dev/null and b/test_loop/14/KpostProcess/Kperm2.npy differ diff --git a/test_loop/14/KpostProcess/Kperm4.npy b/test_loop/14/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..cf5766a Binary files /dev/null and b/test_loop/14/KpostProcess/Kperm4.npy differ diff --git a/test_loop/14/KpostProcess/Kperm8.npy b/test_loop/14/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..cf5766a Binary files /dev/null and b/test_loop/14/KpostProcess/Kperm8.npy differ diff --git a/test_loop/14/KpostProcess/Kv1.npy b/test_loop/14/KpostProcess/Kv1.npy new file mode 100644 index 0000000..975bf0e Binary files /dev/null and b/test_loop/14/KpostProcess/Kv1.npy differ diff --git a/test_loop/14/KpostProcess/Kv16.npy b/test_loop/14/KpostProcess/Kv16.npy new file mode 100644 index 0000000..c05fd0a Binary files /dev/null and b/test_loop/14/KpostProcess/Kv16.npy differ diff --git a/test_loop/14/KpostProcess/Kv2.npy b/test_loop/14/KpostProcess/Kv2.npy new file mode 100644 index 0000000..8fb925d Binary files /dev/null and b/test_loop/14/KpostProcess/Kv2.npy differ diff --git a/test_loop/14/KpostProcess/Kv4.npy b/test_loop/14/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0139a57 Binary files /dev/null and b/test_loop/14/KpostProcess/Kv4.npy differ diff --git a/test_loop/14/KpostProcess/Kv8.npy b/test_loop/14/KpostProcess/Kv8.npy new file mode 100644 index 0000000..341c97c Binary files /dev/null and b/test_loop/14/KpostProcess/Kv8.npy differ diff --git a/test_loop/14/P.npy b/test_loop/14/P.npy new file mode 100644 index 0000000..e5371ef Binary files /dev/null and b/test_loop/14/P.npy differ diff --git a/test_loop/14/PosKeffSummary.txt b/test_loop/14/PosKeffSummary.txt new file mode 100644 index 0000000..7ac6c3d --- /dev/null +++ b/test_loop/14/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.586578949992615506e+00 +1.590789619061978133e+00 +1.883020401000976562e-01 +1.162578691206336834e-02 diff --git a/test_loop/14/RunTimes.out b/test_loop/14/RunTimes.out new file mode 100644 index 0000000..f2cbcf2 --- /dev/null +++ b/test_loop/14/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.311022996902 +Solver: 0.270413160324 +Keff: 1.5907445613011477 +N_cores: 1 diff --git a/test_loop/14/SolverRes.txt b/test_loop/14/SolverRes.txt new file mode 100644 index 0000000..2311877 --- /dev/null +++ b/test_loop/14/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.590744561301147719e+00 +2.000000000000000000e+00 +5.814361572265625000e-01 +1.000000000000000000e+00 diff --git a/test_loop/14/V.npy b/test_loop/14/V.npy new file mode 100644 index 0000000..39cd2d3 Binary files /dev/null and b/test_loop/14/V.npy differ diff --git a/test_loop/14/connec.out b/test_loop/14/connec.out new file mode 100644 index 0000000..cd959e2 --- /dev/null +++ b/test_loop/14/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 4.68750000E-02 + NCC : 1 diff --git a/test_loop/14/k.npy b/test_loop/14/k.npy new file mode 100644 index 0000000..a3f0a60 Binary files /dev/null and b/test_loop/14/k.npy differ diff --git a/test_loop/14/lc.txt b/test_loop/14/lc.txt new file mode 100644 index 0000000..e9e51be --- /dev/null +++ b/test_loop/14/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.286429984355704548e+00 +4.286429984355704548e+00 +4.874703958120725211e+00 diff --git a/test_loop/14/tkperm_sub.txt b/test_loop/14/tkperm_sub.txt new file mode 100644 index 0000000..5de9e27 --- /dev/null +++ b/test_loop/14/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.145399570465087891e-01 +1.780986785888671875e-04 +1.890659332275390625e-04 diff --git a/test_loop/15/Cmap.npy b/test_loop/15/Cmap.npy new file mode 100644 index 0000000..c4e0a91 Binary files /dev/null and b/test_loop/15/Cmap.npy differ diff --git a/test_loop/15/ConnSummary.txt b/test_loop/15/ConnSummary.txt new file mode 100644 index 0000000..1cb6899 --- /dev/null +++ b/test_loop/15/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.811820030212402344e-01 +7.762664430636997404e-01 +5.822278305288609151e-02 diff --git a/test_loop/15/ConnectivityMetrics/16.npy b/test_loop/15/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..b78bde3 Binary files /dev/null and b/test_loop/15/ConnectivityMetrics/16.npy differ diff --git a/test_loop/15/ConnectivityMetrics/4.npy b/test_loop/15/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1a7427b Binary files /dev/null and b/test_loop/15/ConnectivityMetrics/4.npy differ diff --git a/test_loop/15/ConnectivityMetrics/8.npy b/test_loop/15/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..288c85c Binary files /dev/null and b/test_loop/15/ConnectivityMetrics/8.npy differ diff --git a/test_loop/15/D.npy b/test_loop/15/D.npy new file mode 100644 index 0000000..be24ca7 Binary files /dev/null and b/test_loop/15/D.npy differ diff --git a/test_loop/15/GenParams.txt b/test_loop/15/GenParams.txt new file mode 100644 index 0000000..c4ea72f --- /dev/null +++ b/test_loop/15/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.282951354980468750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/15/GlobalConnectivityMetrics/16.npy b/test_loop/15/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..b78bde3 Binary files /dev/null and b/test_loop/15/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/15/GlobalConnectivityMetrics/4.npy b/test_loop/15/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..9d7f8a6 Binary files /dev/null and b/test_loop/15/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/15/GlobalConnectivityMetrics/8.npy b/test_loop/15/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..54736ad Binary files /dev/null and b/test_loop/15/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/15/KpostProcess/Kd16.npy b/test_loop/15/KpostProcess/Kd16.npy new file mode 100644 index 0000000..8c611c4 Binary files /dev/null and b/test_loop/15/KpostProcess/Kd16.npy differ diff --git a/test_loop/15/KpostProcess/Kd4.npy b/test_loop/15/KpostProcess/Kd4.npy new file mode 100644 index 0000000..3002389 Binary files /dev/null and b/test_loop/15/KpostProcess/Kd4.npy differ diff --git a/test_loop/15/KpostProcess/Kd8.npy b/test_loop/15/KpostProcess/Kd8.npy new file mode 100644 index 0000000..85e1f17 Binary files /dev/null and b/test_loop/15/KpostProcess/Kd8.npy differ diff --git a/test_loop/15/KpostProcess/Kperm4.npy b/test_loop/15/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9eaf0a0 Binary files /dev/null and b/test_loop/15/KpostProcess/Kperm4.npy differ diff --git a/test_loop/15/KpostProcess/Kperm8.npy b/test_loop/15/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9eaf0a0 Binary files /dev/null and b/test_loop/15/KpostProcess/Kperm8.npy differ diff --git a/test_loop/15/KpostProcess/Kv16.npy b/test_loop/15/KpostProcess/Kv16.npy new file mode 100644 index 0000000..ca7eb1f Binary files /dev/null and b/test_loop/15/KpostProcess/Kv16.npy differ diff --git a/test_loop/15/KpostProcess/Kv4.npy b/test_loop/15/KpostProcess/Kv4.npy new file mode 100644 index 0000000..c6dc5b7 Binary files /dev/null and b/test_loop/15/KpostProcess/Kv4.npy differ diff --git a/test_loop/15/KpostProcess/Kv8.npy b/test_loop/15/KpostProcess/Kv8.npy new file mode 100644 index 0000000..f23556e Binary files /dev/null and b/test_loop/15/KpostProcess/Kv8.npy differ diff --git a/test_loop/15/P.npy b/test_loop/15/P.npy new file mode 100644 index 0000000..0cef9f7 Binary files /dev/null and b/test_loop/15/P.npy differ diff --git a/test_loop/15/PosKeffSummary.txt b/test_loop/15/PosKeffSummary.txt new file mode 100644 index 0000000..c61f020 --- /dev/null +++ b/test_loop/15/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.346139908696601051e+00 +3.428634750292091304e+00 +4.215002059936523438e-03 +2.448102268227840828e-01 diff --git a/test_loop/15/RunTimes.out b/test_loop/15/RunTimes.out new file mode 100644 index 0000000..846606e --- /dev/null +++ b/test_loop/15/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.37110710144 +Solver: 0.266657829285 +Keff: 3.4302157486250464 +N_cores: 1 diff --git a/test_loop/15/SolverRes.txt b/test_loop/15/SolverRes.txt new file mode 100644 index 0000000..259d8ac --- /dev/null +++ b/test_loop/15/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.430215748625046412e+00 +2.000000000000000000e+00 +6.377649307250976562e-01 +1.000000000000000000e+00 diff --git a/test_loop/15/V.npy b/test_loop/15/V.npy new file mode 100644 index 0000000..e3adbb8 Binary files /dev/null and b/test_loop/15/V.npy differ diff --git a/test_loop/15/connec.out b/test_loop/15/connec.out new file mode 100644 index 0000000..d597e95 --- /dev/null +++ b/test_loop/15/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.375000000 + NCC : 1 + NCC : 2 diff --git a/test_loop/15/k.npy b/test_loop/15/k.npy new file mode 100644 index 0000000..cd1379b Binary files /dev/null and b/test_loop/15/k.npy differ diff --git a/test_loop/15/lc.txt b/test_loop/15/lc.txt new file mode 100644 index 0000000..48b470f --- /dev/null +++ b/test_loop/15/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.416441649806322367e+00 +7.416441649806322367e+00 +2.976870277557966293e+00 diff --git a/test_loop/15/tkperm_sub.txt b/test_loop/15/tkperm_sub.txt new file mode 100644 index 0000000..e1ac690 --- /dev/null +++ b/test_loop/15/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.577630519866943359e-01 +1.640319824218750000e-04 diff --git a/test_loop/16/Cmap.npy b/test_loop/16/Cmap.npy new file mode 100644 index 0000000..6b049d2 Binary files /dev/null and b/test_loop/16/Cmap.npy differ diff --git a/test_loop/16/ConnSummary.txt b/test_loop/16/ConnSummary.txt new file mode 100644 index 0000000..be4cb3e --- /dev/null +++ b/test_loop/16/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.528249740600585938e-01 +8.371223556485571926e-01 +3.576893418598914298e-02 diff --git a/test_loop/16/ConnectivityMetrics/16.npy b/test_loop/16/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..2418995 Binary files /dev/null and b/test_loop/16/ConnectivityMetrics/16.npy differ diff --git a/test_loop/16/ConnectivityMetrics/4.npy b/test_loop/16/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..5eaef03 Binary files /dev/null and b/test_loop/16/ConnectivityMetrics/4.npy differ diff --git a/test_loop/16/ConnectivityMetrics/8.npy b/test_loop/16/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..875bbd3 Binary files /dev/null and b/test_loop/16/ConnectivityMetrics/8.npy differ diff --git a/test_loop/16/D.npy b/test_loop/16/D.npy new file mode 100644 index 0000000..1d6eb0f Binary files /dev/null and b/test_loop/16/D.npy differ diff --git a/test_loop/16/GenParams.txt b/test_loop/16/GenParams.txt new file mode 100644 index 0000000..395c399 --- /dev/null +++ b/test_loop/16/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.295038223266601562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/16/GlobalConnectivityMetrics/16.npy b/test_loop/16/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..2418995 Binary files /dev/null and b/test_loop/16/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/16/GlobalConnectivityMetrics/4.npy b/test_loop/16/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..81cc83c Binary files /dev/null and b/test_loop/16/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/16/GlobalConnectivityMetrics/8.npy b/test_loop/16/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..a918858 Binary files /dev/null and b/test_loop/16/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/16/KpostProcess/Kd1.npy b/test_loop/16/KpostProcess/Kd1.npy new file mode 100644 index 0000000..9f44b40 Binary files /dev/null and b/test_loop/16/KpostProcess/Kd1.npy differ diff --git a/test_loop/16/KpostProcess/Kd16.npy b/test_loop/16/KpostProcess/Kd16.npy new file mode 100644 index 0000000..da3a8f8 Binary files /dev/null and b/test_loop/16/KpostProcess/Kd16.npy differ diff --git a/test_loop/16/KpostProcess/Kd2.npy b/test_loop/16/KpostProcess/Kd2.npy new file mode 100644 index 0000000..b391e09 Binary files /dev/null and b/test_loop/16/KpostProcess/Kd2.npy differ diff --git a/test_loop/16/KpostProcess/Kd4.npy b/test_loop/16/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7b441dd Binary files /dev/null and b/test_loop/16/KpostProcess/Kd4.npy differ diff --git a/test_loop/16/KpostProcess/Kd8.npy b/test_loop/16/KpostProcess/Kd8.npy new file mode 100644 index 0000000..64ea8f9 Binary files /dev/null and b/test_loop/16/KpostProcess/Kd8.npy differ diff --git a/test_loop/16/KpostProcess/Kperm2.npy b/test_loop/16/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..231f406 Binary files /dev/null and b/test_loop/16/KpostProcess/Kperm2.npy differ diff --git a/test_loop/16/KpostProcess/Kperm4.npy b/test_loop/16/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..231f406 Binary files /dev/null and b/test_loop/16/KpostProcess/Kperm4.npy differ diff --git a/test_loop/16/KpostProcess/Kperm8.npy b/test_loop/16/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..231f406 Binary files /dev/null and b/test_loop/16/KpostProcess/Kperm8.npy differ diff --git a/test_loop/16/KpostProcess/Kv1.npy b/test_loop/16/KpostProcess/Kv1.npy new file mode 100644 index 0000000..722b7d6 Binary files /dev/null and b/test_loop/16/KpostProcess/Kv1.npy differ diff --git a/test_loop/16/KpostProcess/Kv16.npy b/test_loop/16/KpostProcess/Kv16.npy new file mode 100644 index 0000000..bd70f15 Binary files /dev/null and b/test_loop/16/KpostProcess/Kv16.npy differ diff --git a/test_loop/16/KpostProcess/Kv2.npy b/test_loop/16/KpostProcess/Kv2.npy new file mode 100644 index 0000000..1f60f4e Binary files /dev/null and b/test_loop/16/KpostProcess/Kv2.npy differ diff --git a/test_loop/16/KpostProcess/Kv4.npy b/test_loop/16/KpostProcess/Kv4.npy new file mode 100644 index 0000000..a5f6b9f Binary files /dev/null and b/test_loop/16/KpostProcess/Kv4.npy differ diff --git a/test_loop/16/KpostProcess/Kv8.npy b/test_loop/16/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c9698df Binary files /dev/null and b/test_loop/16/KpostProcess/Kv8.npy differ diff --git a/test_loop/16/P.npy b/test_loop/16/P.npy new file mode 100644 index 0000000..fdc0e09 Binary files /dev/null and b/test_loop/16/P.npy differ diff --git a/test_loop/16/PosKeffSummary.txt b/test_loop/16/PosKeffSummary.txt new file mode 100644 index 0000000..6415434 --- /dev/null +++ b/test_loop/16/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.330902706030813398e+00 +2.368178342674446490e+00 +1.847989559173583984e-01 +6.931981943044988707e-03 diff --git a/test_loop/16/RunTimes.out b/test_loop/16/RunTimes.out new file mode 100644 index 0000000..dff07cd --- /dev/null +++ b/test_loop/16/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.312026023865 +Solver: 0.280194044113 +Keff: 2.368080989410771 +N_cores: 1 diff --git a/test_loop/16/SolverRes.txt b/test_loop/16/SolverRes.txt new file mode 100644 index 0000000..791954d --- /dev/null +++ b/test_loop/16/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.368080989410771053e+00 +2.000000000000000000e+00 +5.922200679779052734e-01 +1.000000000000000000e+00 diff --git a/test_loop/16/V.npy b/test_loop/16/V.npy new file mode 100644 index 0000000..fd6342c Binary files /dev/null and b/test_loop/16/V.npy differ diff --git a/test_loop/16/connec.out b/test_loop/16/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/16/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/16/k.npy b/test_loop/16/k.npy new file mode 100644 index 0000000..5368030 Binary files /dev/null and b/test_loop/16/k.npy differ diff --git a/test_loop/16/lc.txt b/test_loop/16/lc.txt new file mode 100644 index 0000000..78e42fa --- /dev/null +++ b/test_loop/16/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.258652366754715146e+00 +4.258652366754715146e+00 +4.863013012662428913e+00 diff --git a/test_loop/16/tkperm_sub.txt b/test_loop/16/tkperm_sub.txt new file mode 100644 index 0000000..3953360 --- /dev/null +++ b/test_loop/16/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.685049057006835938e-01 +2.079010009765625000e-04 +1.678466796875000000e-04 diff --git a/test_loop/17/Cmap.npy b/test_loop/17/Cmap.npy new file mode 100644 index 0000000..55f840e Binary files /dev/null and b/test_loop/17/Cmap.npy differ diff --git a/test_loop/17/ConnSummary.txt b/test_loop/17/ConnSummary.txt new file mode 100644 index 0000000..e7cd23d --- /dev/null +++ b/test_loop/17/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.325211048126220703e-01 +8.325302831943774962e-01 +3.271329153173017229e-02 diff --git a/test_loop/17/ConnectivityMetrics/16.npy b/test_loop/17/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..73393fd Binary files /dev/null and b/test_loop/17/ConnectivityMetrics/16.npy differ diff --git a/test_loop/17/ConnectivityMetrics/4.npy b/test_loop/17/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..f9f00f1 Binary files /dev/null and b/test_loop/17/ConnectivityMetrics/4.npy differ diff --git a/test_loop/17/ConnectivityMetrics/8.npy b/test_loop/17/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..f84da45 Binary files /dev/null and b/test_loop/17/ConnectivityMetrics/8.npy differ diff --git a/test_loop/17/D.npy b/test_loop/17/D.npy new file mode 100644 index 0000000..2944286 Binary files /dev/null and b/test_loop/17/D.npy differ diff --git a/test_loop/17/GenParams.txt b/test_loop/17/GenParams.txt new file mode 100644 index 0000000..bba8ca9 --- /dev/null +++ b/test_loop/17/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.838083267211914062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/17/GlobalConnectivityMetrics/16.npy b/test_loop/17/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..73393fd Binary files /dev/null and b/test_loop/17/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/17/GlobalConnectivityMetrics/4.npy b/test_loop/17/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..de65894 Binary files /dev/null and b/test_loop/17/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/17/GlobalConnectivityMetrics/8.npy b/test_loop/17/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..7267954 Binary files /dev/null and b/test_loop/17/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/17/KpostProcess/Kd16.npy b/test_loop/17/KpostProcess/Kd16.npy new file mode 100644 index 0000000..35a2b36 Binary files /dev/null and b/test_loop/17/KpostProcess/Kd16.npy differ diff --git a/test_loop/17/KpostProcess/Kd4.npy b/test_loop/17/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0b61c77 Binary files /dev/null and b/test_loop/17/KpostProcess/Kd4.npy differ diff --git a/test_loop/17/KpostProcess/Kd8.npy b/test_loop/17/KpostProcess/Kd8.npy new file mode 100644 index 0000000..45981f0 Binary files /dev/null and b/test_loop/17/KpostProcess/Kd8.npy differ diff --git a/test_loop/17/KpostProcess/Kperm4.npy b/test_loop/17/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..ad182f8 Binary files /dev/null and b/test_loop/17/KpostProcess/Kperm4.npy differ diff --git a/test_loop/17/KpostProcess/Kperm8.npy b/test_loop/17/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..ad182f8 Binary files /dev/null and b/test_loop/17/KpostProcess/Kperm8.npy differ diff --git a/test_loop/17/KpostProcess/Kv16.npy b/test_loop/17/KpostProcess/Kv16.npy new file mode 100644 index 0000000..76809e3 Binary files /dev/null and b/test_loop/17/KpostProcess/Kv16.npy differ diff --git a/test_loop/17/KpostProcess/Kv4.npy b/test_loop/17/KpostProcess/Kv4.npy new file mode 100644 index 0000000..b1cae2f Binary files /dev/null and b/test_loop/17/KpostProcess/Kv4.npy differ diff --git a/test_loop/17/KpostProcess/Kv8.npy b/test_loop/17/KpostProcess/Kv8.npy new file mode 100644 index 0000000..97e250c Binary files /dev/null and b/test_loop/17/KpostProcess/Kv8.npy differ diff --git a/test_loop/17/P.npy b/test_loop/17/P.npy new file mode 100644 index 0000000..f16fa1f Binary files /dev/null and b/test_loop/17/P.npy differ diff --git a/test_loop/17/PosKeffSummary.txt b/test_loop/17/PosKeffSummary.txt new file mode 100644 index 0000000..c7f57f4 --- /dev/null +++ b/test_loop/17/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.736031632024231275e+00 +3.827780345534863571e+00 +7.292985916137695312e-03 +2.635587956454935044e-01 diff --git a/test_loop/17/RunTimes.out b/test_loop/17/RunTimes.out new file mode 100644 index 0000000..86b03b7 --- /dev/null +++ b/test_loop/17/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.328058958054 +Solver: 0.281773090363 +Keff: 3.8277900828882094 +N_cores: 1 diff --git a/test_loop/17/SolverRes.txt b/test_loop/17/SolverRes.txt new file mode 100644 index 0000000..6d6a2c0 --- /dev/null +++ b/test_loop/17/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.827790082888209433e+00 +2.000000000000000000e+00 +6.098320484161376953e-01 +1.000000000000000000e+00 diff --git a/test_loop/17/V.npy b/test_loop/17/V.npy new file mode 100644 index 0000000..3b81f1d Binary files /dev/null and b/test_loop/17/V.npy differ diff --git a/test_loop/17/connec.out b/test_loop/17/connec.out new file mode 100644 index 0000000..980fced --- /dev/null +++ b/test_loop/17/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.421875000 + NCC : 1 + NCC : 2 diff --git a/test_loop/17/k.npy b/test_loop/17/k.npy new file mode 100644 index 0000000..eb935a2 Binary files /dev/null and b/test_loop/17/k.npy differ diff --git a/test_loop/17/lc.txt b/test_loop/17/lc.txt new file mode 100644 index 0000000..f1d1f28 --- /dev/null +++ b/test_loop/17/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.345876270997490742e+00 +7.345876270997490742e+00 +2.949784629415706405e+00 diff --git a/test_loop/17/tkperm_sub.txt b/test_loop/17/tkperm_sub.txt new file mode 100644 index 0000000..4f8412e --- /dev/null +++ b/test_loop/17/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.641227722167968750e-01 +1.451969146728515625e-03 diff --git a/test_loop/18/Cmap.npy b/test_loop/18/Cmap.npy new file mode 100644 index 0000000..9f32fc4 Binary files /dev/null and b/test_loop/18/Cmap.npy differ diff --git a/test_loop/18/ConnSummary.txt b/test_loop/18/ConnSummary.txt new file mode 100644 index 0000000..ea7b715 --- /dev/null +++ b/test_loop/18/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +6.569190025329589844e-01 +8.570890909869568475e-01 +3.007093918015996820e-02 diff --git a/test_loop/18/ConnectivityMetrics/16.npy b/test_loop/18/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..9205e1d Binary files /dev/null and b/test_loop/18/ConnectivityMetrics/16.npy differ diff --git a/test_loop/18/ConnectivityMetrics/4.npy b/test_loop/18/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..950c06b Binary files /dev/null and b/test_loop/18/ConnectivityMetrics/4.npy differ diff --git a/test_loop/18/ConnectivityMetrics/8.npy b/test_loop/18/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..7465faf Binary files /dev/null and b/test_loop/18/ConnectivityMetrics/8.npy differ diff --git a/test_loop/18/D.npy b/test_loop/18/D.npy new file mode 100644 index 0000000..7b53938 Binary files /dev/null and b/test_loop/18/D.npy differ diff --git a/test_loop/18/GenParams.txt b/test_loop/18/GenParams.txt new file mode 100644 index 0000000..1f4f7e1 --- /dev/null +++ b/test_loop/18/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +3.866910934448242188e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/18/GlobalConnectivityMetrics/16.npy b/test_loop/18/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..9205e1d Binary files /dev/null and b/test_loop/18/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/18/GlobalConnectivityMetrics/4.npy b/test_loop/18/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..2e120e0 Binary files /dev/null and b/test_loop/18/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/18/GlobalConnectivityMetrics/8.npy b/test_loop/18/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..6fd1e99 Binary files /dev/null and b/test_loop/18/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/18/KpostProcess/Kd1.npy b/test_loop/18/KpostProcess/Kd1.npy new file mode 100644 index 0000000..7e1ac63 Binary files /dev/null and b/test_loop/18/KpostProcess/Kd1.npy differ diff --git a/test_loop/18/KpostProcess/Kd16.npy b/test_loop/18/KpostProcess/Kd16.npy new file mode 100644 index 0000000..cf3b91d Binary files /dev/null and b/test_loop/18/KpostProcess/Kd16.npy differ diff --git a/test_loop/18/KpostProcess/Kd2.npy b/test_loop/18/KpostProcess/Kd2.npy new file mode 100644 index 0000000..a52a605 Binary files /dev/null and b/test_loop/18/KpostProcess/Kd2.npy differ diff --git a/test_loop/18/KpostProcess/Kd4.npy b/test_loop/18/KpostProcess/Kd4.npy new file mode 100644 index 0000000..304e5e0 Binary files /dev/null and b/test_loop/18/KpostProcess/Kd4.npy differ diff --git a/test_loop/18/KpostProcess/Kd8.npy b/test_loop/18/KpostProcess/Kd8.npy new file mode 100644 index 0000000..f7925c5 Binary files /dev/null and b/test_loop/18/KpostProcess/Kd8.npy differ diff --git a/test_loop/18/KpostProcess/Kperm2.npy b/test_loop/18/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..00d967d Binary files /dev/null and b/test_loop/18/KpostProcess/Kperm2.npy differ diff --git a/test_loop/18/KpostProcess/Kperm4.npy b/test_loop/18/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..00d967d Binary files /dev/null and b/test_loop/18/KpostProcess/Kperm4.npy differ diff --git a/test_loop/18/KpostProcess/Kperm8.npy b/test_loop/18/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..00d967d Binary files /dev/null and b/test_loop/18/KpostProcess/Kperm8.npy differ diff --git a/test_loop/18/KpostProcess/Kv1.npy b/test_loop/18/KpostProcess/Kv1.npy new file mode 100644 index 0000000..22b7eb7 Binary files /dev/null and b/test_loop/18/KpostProcess/Kv1.npy differ diff --git a/test_loop/18/KpostProcess/Kv16.npy b/test_loop/18/KpostProcess/Kv16.npy new file mode 100644 index 0000000..905934f Binary files /dev/null and b/test_loop/18/KpostProcess/Kv16.npy differ diff --git a/test_loop/18/KpostProcess/Kv2.npy b/test_loop/18/KpostProcess/Kv2.npy new file mode 100644 index 0000000..49fa590 Binary files /dev/null and b/test_loop/18/KpostProcess/Kv2.npy differ diff --git a/test_loop/18/KpostProcess/Kv4.npy b/test_loop/18/KpostProcess/Kv4.npy new file mode 100644 index 0000000..cca57a6 Binary files /dev/null and b/test_loop/18/KpostProcess/Kv4.npy differ diff --git a/test_loop/18/KpostProcess/Kv8.npy b/test_loop/18/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0560caf Binary files /dev/null and b/test_loop/18/KpostProcess/Kv8.npy differ diff --git a/test_loop/18/P.npy b/test_loop/18/P.npy new file mode 100644 index 0000000..9119ba2 Binary files /dev/null and b/test_loop/18/P.npy differ diff --git a/test_loop/18/PosKeffSummary.txt b/test_loop/18/PosKeffSummary.txt new file mode 100644 index 0000000..3d2f81d --- /dev/null +++ b/test_loop/18/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.840469475550702505e+00 +3.029133165366474145e+00 +1.974399089813232422e-01 +5.211786171860943381e-03 diff --git a/test_loop/18/RunTimes.out b/test_loop/18/RunTimes.out new file mode 100644 index 0000000..39f5390 --- /dev/null +++ b/test_loop/18/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.300705909729 +Solver: 0.179495096207 +Keff: 3.0287434893510863 +N_cores: 1 diff --git a/test_loop/18/SolverRes.txt b/test_loop/18/SolverRes.txt new file mode 100644 index 0000000..dda5780 --- /dev/null +++ b/test_loop/18/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.028743489351086282e+00 +2.000000000000000000e+00 +4.802010059356689453e-01 +1.000000000000000000e+00 diff --git a/test_loop/18/V.npy b/test_loop/18/V.npy new file mode 100644 index 0000000..ccad123 Binary files /dev/null and b/test_loop/18/V.npy differ diff --git a/test_loop/18/connec.out b/test_loop/18/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/18/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/18/k.npy b/test_loop/18/k.npy new file mode 100644 index 0000000..e6923c6 Binary files /dev/null and b/test_loop/18/k.npy differ diff --git a/test_loop/18/lc.txt b/test_loop/18/lc.txt new file mode 100644 index 0000000..97efdbc --- /dev/null +++ b/test_loop/18/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.234176642848941796e+00 +4.234176642848941796e+00 +4.500123630600001867e+00 diff --git a/test_loop/18/tkperm_sub.txt b/test_loop/18/tkperm_sub.txt new file mode 100644 index 0000000..2fd55e6 --- /dev/null +++ b/test_loop/18/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.811099529266357422e-01 +2.279281616210937500e-04 +1.311302185058593750e-04 diff --git a/test_loop/19/Cmap.npy b/test_loop/19/Cmap.npy new file mode 100644 index 0000000..8697238 Binary files /dev/null and b/test_loop/19/Cmap.npy differ diff --git a/test_loop/19/ConnSummary.txt b/test_loop/19/ConnSummary.txt new file mode 100644 index 0000000..9ffed0d --- /dev/null +++ b/test_loop/19/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.932540416717529297e-01 +8.284440596643561916e-01 +3.477389420689730448e-02 diff --git a/test_loop/19/ConnectivityMetrics/16.npy b/test_loop/19/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..a1cd290 Binary files /dev/null and b/test_loop/19/ConnectivityMetrics/16.npy differ diff --git a/test_loop/19/ConnectivityMetrics/4.npy b/test_loop/19/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..6b8a82b Binary files /dev/null and b/test_loop/19/ConnectivityMetrics/4.npy differ diff --git a/test_loop/19/ConnectivityMetrics/8.npy b/test_loop/19/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..f5d4434 Binary files /dev/null and b/test_loop/19/ConnectivityMetrics/8.npy differ diff --git a/test_loop/19/D.npy b/test_loop/19/D.npy new file mode 100644 index 0000000..2ffa735 Binary files /dev/null and b/test_loop/19/D.npy differ diff --git a/test_loop/19/GenParams.txt b/test_loop/19/GenParams.txt new file mode 100644 index 0000000..01553aa --- /dev/null +++ b/test_loop/19/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.168033599853515625e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/19/GlobalConnectivityMetrics/16.npy b/test_loop/19/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..a1cd290 Binary files /dev/null and b/test_loop/19/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/19/GlobalConnectivityMetrics/4.npy b/test_loop/19/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..52b39c4 Binary files /dev/null and b/test_loop/19/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/19/GlobalConnectivityMetrics/8.npy b/test_loop/19/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..c16a086 Binary files /dev/null and b/test_loop/19/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/19/KpostProcess/Kd16.npy b/test_loop/19/KpostProcess/Kd16.npy new file mode 100644 index 0000000..ae228d3 Binary files /dev/null and b/test_loop/19/KpostProcess/Kd16.npy differ diff --git a/test_loop/19/KpostProcess/Kd4.npy b/test_loop/19/KpostProcess/Kd4.npy new file mode 100644 index 0000000..38541a8 Binary files /dev/null and b/test_loop/19/KpostProcess/Kd4.npy differ diff --git a/test_loop/19/KpostProcess/Kd8.npy b/test_loop/19/KpostProcess/Kd8.npy new file mode 100644 index 0000000..e6c0af3 Binary files /dev/null and b/test_loop/19/KpostProcess/Kd8.npy differ diff --git a/test_loop/19/KpostProcess/Kperm4.npy b/test_loop/19/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e5f70a6 Binary files /dev/null and b/test_loop/19/KpostProcess/Kperm4.npy differ diff --git a/test_loop/19/KpostProcess/Kperm8.npy b/test_loop/19/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e5f70a6 Binary files /dev/null and b/test_loop/19/KpostProcess/Kperm8.npy differ diff --git a/test_loop/19/KpostProcess/Kv16.npy b/test_loop/19/KpostProcess/Kv16.npy new file mode 100644 index 0000000..51a63ac Binary files /dev/null and b/test_loop/19/KpostProcess/Kv16.npy differ diff --git a/test_loop/19/KpostProcess/Kv4.npy b/test_loop/19/KpostProcess/Kv4.npy new file mode 100644 index 0000000..7306210 Binary files /dev/null and b/test_loop/19/KpostProcess/Kv4.npy differ diff --git a/test_loop/19/KpostProcess/Kv8.npy b/test_loop/19/KpostProcess/Kv8.npy new file mode 100644 index 0000000..23cd6ee Binary files /dev/null and b/test_loop/19/KpostProcess/Kv8.npy differ diff --git a/test_loop/19/P.npy b/test_loop/19/P.npy new file mode 100644 index 0000000..61a38e3 Binary files /dev/null and b/test_loop/19/P.npy differ diff --git a/test_loop/19/PosKeffSummary.txt b/test_loop/19/PosKeffSummary.txt new file mode 100644 index 0000000..d115450 --- /dev/null +++ b/test_loop/19/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.116015969211159309e+00 +4.216583586106365189e+00 +4.341840744018554688e-03 +2.390313546757454333e-01 diff --git a/test_loop/19/RunTimes.out b/test_loop/19/RunTimes.out new file mode 100644 index 0000000..dc36b8a --- /dev/null +++ b/test_loop/19/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.294747114182 +Solver: 0.257308959961 +Keff: 4.216838944790215 +N_cores: 1 diff --git a/test_loop/19/SolverRes.txt b/test_loop/19/SolverRes.txt new file mode 100644 index 0000000..1863b76 --- /dev/null +++ b/test_loop/19/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.216838944790215038e+00 +2.000000000000000000e+00 +5.520560741424560547e-01 +1.000000000000000000e+00 diff --git a/test_loop/19/V.npy b/test_loop/19/V.npy new file mode 100644 index 0000000..c31df3e Binary files /dev/null and b/test_loop/19/V.npy differ diff --git a/test_loop/19/connec.out b/test_loop/19/connec.out new file mode 100644 index 0000000..b0caef4 --- /dev/null +++ b/test_loop/19/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.437500000 + NCC : 1 + NCC : 2 diff --git a/test_loop/19/k.npy b/test_loop/19/k.npy new file mode 100644 index 0000000..90db459 Binary files /dev/null and b/test_loop/19/k.npy differ diff --git a/test_loop/19/lc.txt b/test_loop/19/lc.txt new file mode 100644 index 0000000..7264fbc --- /dev/null +++ b/test_loop/19/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.283284973338549406e+00 +7.283284973338549406e+00 +3.057188747110188842e+00 diff --git a/test_loop/19/tkperm_sub.txt b/test_loop/19/tkperm_sub.txt new file mode 100644 index 0000000..e2cba0a --- /dev/null +++ b/test_loop/19/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.121778964996337891e-01 +1.630783081054687500e-04 diff --git a/test_loop/2/Cmap.npy b/test_loop/2/Cmap.npy new file mode 100644 index 0000000..9320593 Binary files /dev/null and b/test_loop/2/Cmap.npy differ diff --git a/test_loop/2/ConnSummary.txt b/test_loop/2/ConnSummary.txt new file mode 100644 index 0000000..f5e0441 --- /dev/null +++ b/test_loop/2/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.177031517028808594e-01 +8.458807037090733116e-01 +2.570700250117867111e-02 diff --git a/test_loop/2/ConnectivityMetrics/16.npy b/test_loop/2/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..594645f Binary files /dev/null and b/test_loop/2/ConnectivityMetrics/16.npy differ diff --git a/test_loop/2/ConnectivityMetrics/4.npy b/test_loop/2/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..f4c5d2c Binary files /dev/null and b/test_loop/2/ConnectivityMetrics/4.npy differ diff --git a/test_loop/2/ConnectivityMetrics/8.npy b/test_loop/2/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..ef22579 Binary files /dev/null and b/test_loop/2/ConnectivityMetrics/8.npy differ diff --git a/test_loop/2/D.npy b/test_loop/2/D.npy new file mode 100644 index 0000000..d8617b7 Binary files /dev/null and b/test_loop/2/D.npy differ diff --git a/test_loop/2/GenParams.txt b/test_loop/2/GenParams.txt new file mode 100644 index 0000000..29a4fc3 --- /dev/null +++ b/test_loop/2/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.601095199584960938e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/2/GlobalConnectivityMetrics/16.npy b/test_loop/2/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..594645f Binary files /dev/null and b/test_loop/2/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/2/GlobalConnectivityMetrics/4.npy b/test_loop/2/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..239a364 Binary files /dev/null and b/test_loop/2/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/2/GlobalConnectivityMetrics/8.npy b/test_loop/2/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..32f729b Binary files /dev/null and b/test_loop/2/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/2/KpostProcess/Kd1.npy b/test_loop/2/KpostProcess/Kd1.npy new file mode 100644 index 0000000..7bb1e65 Binary files /dev/null and b/test_loop/2/KpostProcess/Kd1.npy differ diff --git a/test_loop/2/KpostProcess/Kd16.npy b/test_loop/2/KpostProcess/Kd16.npy new file mode 100644 index 0000000..ea92cca Binary files /dev/null and b/test_loop/2/KpostProcess/Kd16.npy differ diff --git a/test_loop/2/KpostProcess/Kd2.npy b/test_loop/2/KpostProcess/Kd2.npy new file mode 100644 index 0000000..77893aa Binary files /dev/null and b/test_loop/2/KpostProcess/Kd2.npy differ diff --git a/test_loop/2/KpostProcess/Kd4.npy b/test_loop/2/KpostProcess/Kd4.npy new file mode 100644 index 0000000..936053e Binary files /dev/null and b/test_loop/2/KpostProcess/Kd4.npy differ diff --git a/test_loop/2/KpostProcess/Kd8.npy b/test_loop/2/KpostProcess/Kd8.npy new file mode 100644 index 0000000..775c3af Binary files /dev/null and b/test_loop/2/KpostProcess/Kd8.npy differ diff --git a/test_loop/2/KpostProcess/Kperm2.npy b/test_loop/2/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..a0e5a92 Binary files /dev/null and b/test_loop/2/KpostProcess/Kperm2.npy differ diff --git a/test_loop/2/KpostProcess/Kperm4.npy b/test_loop/2/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..a0e5a92 Binary files /dev/null and b/test_loop/2/KpostProcess/Kperm4.npy differ diff --git a/test_loop/2/KpostProcess/Kperm8.npy b/test_loop/2/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..a0e5a92 Binary files /dev/null and b/test_loop/2/KpostProcess/Kperm8.npy differ diff --git a/test_loop/2/KpostProcess/Kv1.npy b/test_loop/2/KpostProcess/Kv1.npy new file mode 100644 index 0000000..e49bbe6 Binary files /dev/null and b/test_loop/2/KpostProcess/Kv1.npy differ diff --git a/test_loop/2/KpostProcess/Kv16.npy b/test_loop/2/KpostProcess/Kv16.npy new file mode 100644 index 0000000..19f5c67 Binary files /dev/null and b/test_loop/2/KpostProcess/Kv16.npy differ diff --git a/test_loop/2/KpostProcess/Kv2.npy b/test_loop/2/KpostProcess/Kv2.npy new file mode 100644 index 0000000..7b81463 Binary files /dev/null and b/test_loop/2/KpostProcess/Kv2.npy differ diff --git a/test_loop/2/KpostProcess/Kv4.npy b/test_loop/2/KpostProcess/Kv4.npy new file mode 100644 index 0000000..7fc1fb1 Binary files /dev/null and b/test_loop/2/KpostProcess/Kv4.npy differ diff --git a/test_loop/2/KpostProcess/Kv8.npy b/test_loop/2/KpostProcess/Kv8.npy new file mode 100644 index 0000000..759c04b Binary files /dev/null and b/test_loop/2/KpostProcess/Kv8.npy differ diff --git a/test_loop/2/P.npy b/test_loop/2/P.npy new file mode 100644 index 0000000..13ff639 Binary files /dev/null and b/test_loop/2/P.npy differ diff --git a/test_loop/2/PosKeffSummary.txt b/test_loop/2/PosKeffSummary.txt new file mode 100644 index 0000000..cbd6872 --- /dev/null +++ b/test_loop/2/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.780651389780233046e-02 +2.800099901878502426e-02 +1.765549182891845703e-01 +9.323115357347828286e-03 diff --git a/test_loop/2/RunTimes.out b/test_loop/2/RunTimes.out new file mode 100644 index 0000000..cacddb6 --- /dev/null +++ b/test_loop/2/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.330264091492 +Solver: 0.309885025024 +Keff: 0.027767712326296226 +N_cores: 1 diff --git a/test_loop/2/SolverRes.txt b/test_loop/2/SolverRes.txt new file mode 100644 index 0000000..6ceaf61 --- /dev/null +++ b/test_loop/2/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.776771232629622610e-02 +2.000000000000000000e+00 +6.401491165161132812e-01 +1.000000000000000000e+00 diff --git a/test_loop/2/V.npy b/test_loop/2/V.npy new file mode 100644 index 0000000..4e64391 Binary files /dev/null and b/test_loop/2/V.npy differ diff --git a/test_loop/2/connec.out b/test_loop/2/connec.out new file mode 100644 index 0000000..e6ae057 --- /dev/null +++ b/test_loop/2/connec.out @@ -0,0 +1,4 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.00000000 diff --git a/test_loop/2/k.npy b/test_loop/2/k.npy new file mode 100644 index 0000000..5303889 Binary files /dev/null and b/test_loop/2/k.npy differ diff --git a/test_loop/2/lc.txt b/test_loop/2/lc.txt new file mode 100644 index 0000000..968af62 --- /dev/null +++ b/test_loop/2/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.548715591709491690e+00 +4.548715591709491690e+00 +5.111303556544476656e+00 diff --git a/test_loop/2/tkperm_sub.txt b/test_loop/2/tkperm_sub.txt new file mode 100644 index 0000000..551b013 --- /dev/null +++ b/test_loop/2/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.056310653686523438e-01 +2.069473266601562500e-04 +1.690387725830078125e-04 diff --git a/test_loop/20/Cmap.npy b/test_loop/20/Cmap.npy new file mode 100644 index 0000000..da61f99 Binary files /dev/null and b/test_loop/20/Cmap.npy differ diff --git a/test_loop/20/ConnSummary.txt b/test_loop/20/ConnSummary.txt new file mode 100644 index 0000000..11e0aa5 --- /dev/null +++ b/test_loop/20/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.943290710449218750e-01 +8.100845498253862464e-01 +4.100158651846262658e-02 diff --git a/test_loop/20/ConnectivityMetrics/16.npy b/test_loop/20/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8d60179 Binary files /dev/null and b/test_loop/20/ConnectivityMetrics/16.npy differ diff --git a/test_loop/20/ConnectivityMetrics/4.npy b/test_loop/20/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..42d67d7 Binary files /dev/null and b/test_loop/20/ConnectivityMetrics/4.npy differ diff --git a/test_loop/20/ConnectivityMetrics/8.npy b/test_loop/20/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..65581b1 Binary files /dev/null and b/test_loop/20/ConnectivityMetrics/8.npy differ diff --git a/test_loop/20/D.npy b/test_loop/20/D.npy new file mode 100644 index 0000000..6b65334 Binary files /dev/null and b/test_loop/20/D.npy differ diff --git a/test_loop/20/GenParams.txt b/test_loop/20/GenParams.txt new file mode 100644 index 0000000..5db58d5 --- /dev/null +++ b/test_loop/20/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.778146743774414062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/20/GlobalConnectivityMetrics/16.npy b/test_loop/20/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8d60179 Binary files /dev/null and b/test_loop/20/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/20/GlobalConnectivityMetrics/4.npy b/test_loop/20/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..45ed5ab Binary files /dev/null and b/test_loop/20/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/20/GlobalConnectivityMetrics/8.npy b/test_loop/20/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..1ec054b Binary files /dev/null and b/test_loop/20/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/20/KpostProcess/Kd1.npy b/test_loop/20/KpostProcess/Kd1.npy new file mode 100644 index 0000000..93a97f0 Binary files /dev/null and b/test_loop/20/KpostProcess/Kd1.npy differ diff --git a/test_loop/20/KpostProcess/Kd16.npy b/test_loop/20/KpostProcess/Kd16.npy new file mode 100644 index 0000000..5f337bc Binary files /dev/null and b/test_loop/20/KpostProcess/Kd16.npy differ diff --git a/test_loop/20/KpostProcess/Kd2.npy b/test_loop/20/KpostProcess/Kd2.npy new file mode 100644 index 0000000..24bb52e Binary files /dev/null and b/test_loop/20/KpostProcess/Kd2.npy differ diff --git a/test_loop/20/KpostProcess/Kd4.npy b/test_loop/20/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7410d26 Binary files /dev/null and b/test_loop/20/KpostProcess/Kd4.npy differ diff --git a/test_loop/20/KpostProcess/Kd8.npy b/test_loop/20/KpostProcess/Kd8.npy new file mode 100644 index 0000000..3b3e0a8 Binary files /dev/null and b/test_loop/20/KpostProcess/Kd8.npy differ diff --git a/test_loop/20/KpostProcess/Kperm2.npy b/test_loop/20/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..eed27f1 Binary files /dev/null and b/test_loop/20/KpostProcess/Kperm2.npy differ diff --git a/test_loop/20/KpostProcess/Kperm4.npy b/test_loop/20/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..eed27f1 Binary files /dev/null and b/test_loop/20/KpostProcess/Kperm4.npy differ diff --git a/test_loop/20/KpostProcess/Kperm8.npy b/test_loop/20/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..eed27f1 Binary files /dev/null and b/test_loop/20/KpostProcess/Kperm8.npy differ diff --git a/test_loop/20/KpostProcess/Kv1.npy b/test_loop/20/KpostProcess/Kv1.npy new file mode 100644 index 0000000..f363182 Binary files /dev/null and b/test_loop/20/KpostProcess/Kv1.npy differ diff --git a/test_loop/20/KpostProcess/Kv16.npy b/test_loop/20/KpostProcess/Kv16.npy new file mode 100644 index 0000000..abb6977 Binary files /dev/null and b/test_loop/20/KpostProcess/Kv16.npy differ diff --git a/test_loop/20/KpostProcess/Kv2.npy b/test_loop/20/KpostProcess/Kv2.npy new file mode 100644 index 0000000..12c3e99 Binary files /dev/null and b/test_loop/20/KpostProcess/Kv2.npy differ diff --git a/test_loop/20/KpostProcess/Kv4.npy b/test_loop/20/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d4b8650 Binary files /dev/null and b/test_loop/20/KpostProcess/Kv4.npy differ diff --git a/test_loop/20/KpostProcess/Kv8.npy b/test_loop/20/KpostProcess/Kv8.npy new file mode 100644 index 0000000..085e99a Binary files /dev/null and b/test_loop/20/KpostProcess/Kv8.npy differ diff --git a/test_loop/20/P.npy b/test_loop/20/P.npy new file mode 100644 index 0000000..a4289e1 Binary files /dev/null and b/test_loop/20/P.npy differ diff --git a/test_loop/20/PosKeffSummary.txt b/test_loop/20/PosKeffSummary.txt new file mode 100644 index 0000000..9367352 --- /dev/null +++ b/test_loop/20/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.318170073975072132e+00 +3.521362874923578357e+00 +2.113888263702392578e-01 +6.187480896744861937e-03 diff --git a/test_loop/20/RunTimes.out b/test_loop/20/RunTimes.out new file mode 100644 index 0000000..4b77a0c --- /dev/null +++ b/test_loop/20/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.305746078491 +Solver: 0.203965902328 +Keff: 3.5215640465831264 +N_cores: 1 diff --git a/test_loop/20/SolverRes.txt b/test_loop/20/SolverRes.txt new file mode 100644 index 0000000..de132d0 --- /dev/null +++ b/test_loop/20/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.521564046583126384e+00 +2.000000000000000000e+00 +5.097119808197021484e-01 +1.000000000000000000e+00 diff --git a/test_loop/20/V.npy b/test_loop/20/V.npy new file mode 100644 index 0000000..d79666c Binary files /dev/null and b/test_loop/20/V.npy differ diff --git a/test_loop/20/connec.out b/test_loop/20/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/20/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/20/k.npy b/test_loop/20/k.npy new file mode 100644 index 0000000..59361b2 Binary files /dev/null and b/test_loop/20/k.npy differ diff --git a/test_loop/20/lc.txt b/test_loop/20/lc.txt new file mode 100644 index 0000000..09db763 --- /dev/null +++ b/test_loop/20/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.213669353844622378e+00 +4.213669353844622378e+00 +4.562437569264046644e+00 diff --git a/test_loop/20/tkperm_sub.txt b/test_loop/20/tkperm_sub.txt new file mode 100644 index 0000000..1cf2a52 --- /dev/null +++ b/test_loop/20/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.405100345611572266e-01 +2.200603485107421875e-04 +1.769065856933593750e-04 diff --git a/test_loop/21/Cmap.npy b/test_loop/21/Cmap.npy new file mode 100644 index 0000000..21076ca Binary files /dev/null and b/test_loop/21/Cmap.npy differ diff --git a/test_loop/21/ConnSummary.txt b/test_loop/21/ConnSummary.txt new file mode 100644 index 0000000..9750d9b --- /dev/null +++ b/test_loop/21/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.486970901489257812e-01 +8.249017519920593955e-01 +3.769556614019762414e-02 diff --git a/test_loop/21/ConnectivityMetrics/16.npy b/test_loop/21/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d05377b Binary files /dev/null and b/test_loop/21/ConnectivityMetrics/16.npy differ diff --git a/test_loop/21/ConnectivityMetrics/4.npy b/test_loop/21/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..8e2c478 Binary files /dev/null and b/test_loop/21/ConnectivityMetrics/4.npy differ diff --git a/test_loop/21/ConnectivityMetrics/8.npy b/test_loop/21/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..70ce654 Binary files /dev/null and b/test_loop/21/ConnectivityMetrics/8.npy differ diff --git a/test_loop/21/D.npy b/test_loop/21/D.npy new file mode 100644 index 0000000..4574136 Binary files /dev/null and b/test_loop/21/D.npy differ diff --git a/test_loop/21/GenParams.txt b/test_loop/21/GenParams.txt new file mode 100644 index 0000000..047ef54 --- /dev/null +++ b/test_loop/21/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.165887832641601562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/21/GlobalConnectivityMetrics/16.npy b/test_loop/21/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d05377b Binary files /dev/null and b/test_loop/21/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/21/GlobalConnectivityMetrics/4.npy b/test_loop/21/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..08e6d56 Binary files /dev/null and b/test_loop/21/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/21/GlobalConnectivityMetrics/8.npy b/test_loop/21/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..87f333c Binary files /dev/null and b/test_loop/21/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/21/KpostProcess/Kd16.npy b/test_loop/21/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f863db5 Binary files /dev/null and b/test_loop/21/KpostProcess/Kd16.npy differ diff --git a/test_loop/21/KpostProcess/Kd4.npy b/test_loop/21/KpostProcess/Kd4.npy new file mode 100644 index 0000000..801cb47 Binary files /dev/null and b/test_loop/21/KpostProcess/Kd4.npy differ diff --git a/test_loop/21/KpostProcess/Kd8.npy b/test_loop/21/KpostProcess/Kd8.npy new file mode 100644 index 0000000..a05fbe6 Binary files /dev/null and b/test_loop/21/KpostProcess/Kd8.npy differ diff --git a/test_loop/21/KpostProcess/Kperm4.npy b/test_loop/21/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..f4164af Binary files /dev/null and b/test_loop/21/KpostProcess/Kperm4.npy differ diff --git a/test_loop/21/KpostProcess/Kperm8.npy b/test_loop/21/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..f4164af Binary files /dev/null and b/test_loop/21/KpostProcess/Kperm8.npy differ diff --git a/test_loop/21/KpostProcess/Kv16.npy b/test_loop/21/KpostProcess/Kv16.npy new file mode 100644 index 0000000..c1d7de8 Binary files /dev/null and b/test_loop/21/KpostProcess/Kv16.npy differ diff --git a/test_loop/21/KpostProcess/Kv4.npy b/test_loop/21/KpostProcess/Kv4.npy new file mode 100644 index 0000000..42a0d46 Binary files /dev/null and b/test_loop/21/KpostProcess/Kv4.npy differ diff --git a/test_loop/21/KpostProcess/Kv8.npy b/test_loop/21/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ce31e44 Binary files /dev/null and b/test_loop/21/KpostProcess/Kv8.npy differ diff --git a/test_loop/21/P.npy b/test_loop/21/P.npy new file mode 100644 index 0000000..332adf1 Binary files /dev/null and b/test_loop/21/P.npy differ diff --git a/test_loop/21/PosKeffSummary.txt b/test_loop/21/PosKeffSummary.txt new file mode 100644 index 0000000..571dc72 --- /dev/null +++ b/test_loop/21/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +5.223337183801639583e+00 +5.400001271506680744e+00 +4.417896270751953125e-03 +2.394495412844036830e-01 diff --git a/test_loop/21/RunTimes.out b/test_loop/21/RunTimes.out new file mode 100644 index 0000000..35340b4 --- /dev/null +++ b/test_loop/21/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.292833805084 +Solver: 0.216209173203 +Keff: 5.399988548047985 +N_cores: 1 diff --git a/test_loop/21/SolverRes.txt b/test_loop/21/SolverRes.txt new file mode 100644 index 0000000..dfba613 --- /dev/null +++ b/test_loop/21/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.399988548047985226e+00 +2.000000000000000000e+00 +5.090429782867431641e-01 +1.000000000000000000e+00 diff --git a/test_loop/21/V.npy b/test_loop/21/V.npy new file mode 100644 index 0000000..57588e4 Binary files /dev/null and b/test_loop/21/V.npy differ diff --git a/test_loop/21/connec.out b/test_loop/21/connec.out new file mode 100644 index 0000000..b1cd94c --- /dev/null +++ b/test_loop/21/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.468750000 + NCC : 1 diff --git a/test_loop/21/k.npy b/test_loop/21/k.npy new file mode 100644 index 0000000..6697eee Binary files /dev/null and b/test_loop/21/k.npy differ diff --git a/test_loop/21/lc.txt b/test_loop/21/lc.txt new file mode 100644 index 0000000..dde5680 --- /dev/null +++ b/test_loop/21/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.230566865725824854e+00 +7.230566865725824854e+00 +3.181674730547931595e+00 diff --git a/test_loop/21/tkperm_sub.txt b/test_loop/21/tkperm_sub.txt new file mode 100644 index 0000000..6bcb442 --- /dev/null +++ b/test_loop/21/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.249590396881103516e-01 +1.699924468994140625e-04 diff --git a/test_loop/22/Cmap.npy b/test_loop/22/Cmap.npy new file mode 100644 index 0000000..5ac087d Binary files /dev/null and b/test_loop/22/Cmap.npy differ diff --git a/test_loop/22/ConnSummary.txt b/test_loop/22/ConnSummary.txt new file mode 100644 index 0000000..d785c4b --- /dev/null +++ b/test_loop/22/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.867429733276367188e-01 +7.633535924700276531e-01 +5.274429011710721205e-02 diff --git a/test_loop/22/ConnectivityMetrics/16.npy b/test_loop/22/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..beb0279 Binary files /dev/null and b/test_loop/22/ConnectivityMetrics/16.npy differ diff --git a/test_loop/22/ConnectivityMetrics/4.npy b/test_loop/22/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..48948d8 Binary files /dev/null and b/test_loop/22/ConnectivityMetrics/4.npy differ diff --git a/test_loop/22/ConnectivityMetrics/8.npy b/test_loop/22/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..5bbeffa Binary files /dev/null and b/test_loop/22/ConnectivityMetrics/8.npy differ diff --git a/test_loop/22/D.npy b/test_loop/22/D.npy new file mode 100644 index 0000000..1a321bb Binary files /dev/null and b/test_loop/22/D.npy differ diff --git a/test_loop/22/GenParams.txt b/test_loop/22/GenParams.txt new file mode 100644 index 0000000..dc1c513 --- /dev/null +++ b/test_loop/22/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.052162170410156250e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/22/GlobalConnectivityMetrics/16.npy b/test_loop/22/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..beb0279 Binary files /dev/null and b/test_loop/22/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/22/GlobalConnectivityMetrics/4.npy b/test_loop/22/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..7278de9 Binary files /dev/null and b/test_loop/22/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/22/GlobalConnectivityMetrics/8.npy b/test_loop/22/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..17f273c Binary files /dev/null and b/test_loop/22/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/22/KpostProcess/Kd1.npy b/test_loop/22/KpostProcess/Kd1.npy new file mode 100644 index 0000000..c1036b0 Binary files /dev/null and b/test_loop/22/KpostProcess/Kd1.npy differ diff --git a/test_loop/22/KpostProcess/Kd16.npy b/test_loop/22/KpostProcess/Kd16.npy new file mode 100644 index 0000000..11d03e9 Binary files /dev/null and b/test_loop/22/KpostProcess/Kd16.npy differ diff --git a/test_loop/22/KpostProcess/Kd2.npy b/test_loop/22/KpostProcess/Kd2.npy new file mode 100644 index 0000000..baf5e79 Binary files /dev/null and b/test_loop/22/KpostProcess/Kd2.npy differ diff --git a/test_loop/22/KpostProcess/Kd4.npy b/test_loop/22/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7908b3a Binary files /dev/null and b/test_loop/22/KpostProcess/Kd4.npy differ diff --git a/test_loop/22/KpostProcess/Kd8.npy b/test_loop/22/KpostProcess/Kd8.npy new file mode 100644 index 0000000..b2d5fe2 Binary files /dev/null and b/test_loop/22/KpostProcess/Kd8.npy differ diff --git a/test_loop/22/KpostProcess/Kperm2.npy b/test_loop/22/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..2987ed0 Binary files /dev/null and b/test_loop/22/KpostProcess/Kperm2.npy differ diff --git a/test_loop/22/KpostProcess/Kperm4.npy b/test_loop/22/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..2987ed0 Binary files /dev/null and b/test_loop/22/KpostProcess/Kperm4.npy differ diff --git a/test_loop/22/KpostProcess/Kperm8.npy b/test_loop/22/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..2987ed0 Binary files /dev/null and b/test_loop/22/KpostProcess/Kperm8.npy differ diff --git a/test_loop/22/KpostProcess/Kv1.npy b/test_loop/22/KpostProcess/Kv1.npy new file mode 100644 index 0000000..96ccd32 Binary files /dev/null and b/test_loop/22/KpostProcess/Kv1.npy differ diff --git a/test_loop/22/KpostProcess/Kv16.npy b/test_loop/22/KpostProcess/Kv16.npy new file mode 100644 index 0000000..322a967 Binary files /dev/null and b/test_loop/22/KpostProcess/Kv16.npy differ diff --git a/test_loop/22/KpostProcess/Kv2.npy b/test_loop/22/KpostProcess/Kv2.npy new file mode 100644 index 0000000..0c234cd Binary files /dev/null and b/test_loop/22/KpostProcess/Kv2.npy differ diff --git a/test_loop/22/KpostProcess/Kv4.npy b/test_loop/22/KpostProcess/Kv4.npy new file mode 100644 index 0000000..29dfaef Binary files /dev/null and b/test_loop/22/KpostProcess/Kv4.npy differ diff --git a/test_loop/22/KpostProcess/Kv8.npy b/test_loop/22/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a26a96f Binary files /dev/null and b/test_loop/22/KpostProcess/Kv8.npy differ diff --git a/test_loop/22/P.npy b/test_loop/22/P.npy new file mode 100644 index 0000000..0396e9b Binary files /dev/null and b/test_loop/22/P.npy differ diff --git a/test_loop/22/PosKeffSummary.txt b/test_loop/22/PosKeffSummary.txt new file mode 100644 index 0000000..e5d6488 --- /dev/null +++ b/test_loop/22/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.610211447807544438e+00 +3.822847054322470406e+00 +2.046940326690673828e-01 +5.632759458108971967e-03 diff --git a/test_loop/22/RunTimes.out b/test_loop/22/RunTimes.out new file mode 100644 index 0000000..091f743 --- /dev/null +++ b/test_loop/22/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.328737974167 +Solver: 0.191603183746 +Keff: 3.8229349453430563 +N_cores: 1 diff --git a/test_loop/22/SolverRes.txt b/test_loop/22/SolverRes.txt new file mode 100644 index 0000000..8c5a202 --- /dev/null +++ b/test_loop/22/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.822934945343056334e+00 +2.000000000000000000e+00 +5.203411579132080078e-01 +1.000000000000000000e+00 diff --git a/test_loop/22/V.npy b/test_loop/22/V.npy new file mode 100644 index 0000000..54f4ee9 Binary files /dev/null and b/test_loop/22/V.npy differ diff --git a/test_loop/22/connec.out b/test_loop/22/connec.out new file mode 100644 index 0000000..e85dac7 --- /dev/null +++ b/test_loop/22/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.125000000 + NCC : 1 + NCC : 2 diff --git a/test_loop/22/k.npy b/test_loop/22/k.npy new file mode 100644 index 0000000..2448370 Binary files /dev/null and b/test_loop/22/k.npy differ diff --git a/test_loop/22/lc.txt b/test_loop/22/lc.txt new file mode 100644 index 0000000..dca9741 --- /dev/null +++ b/test_loop/22/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.195903555961134401e+00 +4.195903555961134401e+00 +4.460092578291017240e+00 diff --git a/test_loop/22/tkperm_sub.txt b/test_loop/22/tkperm_sub.txt new file mode 100644 index 0000000..37a347a --- /dev/null +++ b/test_loop/22/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.731981754302978516e-01 +1.659393310546875000e-04 +1.270771026611328125e-04 diff --git a/test_loop/23/Cmap.npy b/test_loop/23/Cmap.npy new file mode 100644 index 0000000..6871ee0 Binary files /dev/null and b/test_loop/23/Cmap.npy differ diff --git a/test_loop/23/ConnSummary.txt b/test_loop/23/ConnSummary.txt new file mode 100644 index 0000000..f84b7ab --- /dev/null +++ b/test_loop/23/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.169829845428466797e-01 +7.774359676365132366e-01 +4.585479153049627776e-02 diff --git a/test_loop/23/ConnectivityMetrics/16.npy b/test_loop/23/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..e046a9b Binary files /dev/null and b/test_loop/23/ConnectivityMetrics/16.npy differ diff --git a/test_loop/23/ConnectivityMetrics/4.npy b/test_loop/23/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..c68a5d3 Binary files /dev/null and b/test_loop/23/ConnectivityMetrics/4.npy differ diff --git a/test_loop/23/ConnectivityMetrics/8.npy b/test_loop/23/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e586b58 Binary files /dev/null and b/test_loop/23/ConnectivityMetrics/8.npy differ diff --git a/test_loop/23/D.npy b/test_loop/23/D.npy new file mode 100644 index 0000000..643ac86 Binary files /dev/null and b/test_loop/23/D.npy differ diff --git a/test_loop/23/GenParams.txt b/test_loop/23/GenParams.txt new file mode 100644 index 0000000..28c1570 --- /dev/null +++ b/test_loop/23/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.084037780761718750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/23/GlobalConnectivityMetrics/16.npy b/test_loop/23/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..e046a9b Binary files /dev/null and b/test_loop/23/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/23/GlobalConnectivityMetrics/4.npy b/test_loop/23/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..90295cf Binary files /dev/null and b/test_loop/23/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/23/GlobalConnectivityMetrics/8.npy b/test_loop/23/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..7f4440d Binary files /dev/null and b/test_loop/23/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/23/KpostProcess/Kd16.npy b/test_loop/23/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2283d70 Binary files /dev/null and b/test_loop/23/KpostProcess/Kd16.npy differ diff --git a/test_loop/23/KpostProcess/Kd4.npy b/test_loop/23/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0d20620 Binary files /dev/null and b/test_loop/23/KpostProcess/Kd4.npy differ diff --git a/test_loop/23/KpostProcess/Kd8.npy b/test_loop/23/KpostProcess/Kd8.npy new file mode 100644 index 0000000..64e15cd Binary files /dev/null and b/test_loop/23/KpostProcess/Kd8.npy differ diff --git a/test_loop/23/KpostProcess/Kperm4.npy b/test_loop/23/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..407e5d2 Binary files /dev/null and b/test_loop/23/KpostProcess/Kperm4.npy differ diff --git a/test_loop/23/KpostProcess/Kperm8.npy b/test_loop/23/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..407e5d2 Binary files /dev/null and b/test_loop/23/KpostProcess/Kperm8.npy differ diff --git a/test_loop/23/KpostProcess/Kv16.npy b/test_loop/23/KpostProcess/Kv16.npy new file mode 100644 index 0000000..4f71347 Binary files /dev/null and b/test_loop/23/KpostProcess/Kv16.npy differ diff --git a/test_loop/23/KpostProcess/Kv4.npy b/test_loop/23/KpostProcess/Kv4.npy new file mode 100644 index 0000000..8cd0047 Binary files /dev/null and b/test_loop/23/KpostProcess/Kv4.npy differ diff --git a/test_loop/23/KpostProcess/Kv8.npy b/test_loop/23/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0c370e8 Binary files /dev/null and b/test_loop/23/KpostProcess/Kv8.npy differ diff --git a/test_loop/23/P.npy b/test_loop/23/P.npy new file mode 100644 index 0000000..0bfd74a Binary files /dev/null and b/test_loop/23/P.npy differ diff --git a/test_loop/23/PosKeffSummary.txt b/test_loop/23/PosKeffSummary.txt new file mode 100644 index 0000000..b56a121 --- /dev/null +++ b/test_loop/23/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +6.793193606387053940e+00 +7.112767702460046415e+00 +4.696130752563476562e-03 +2.581103721378890103e-01 diff --git a/test_loop/23/RunTimes.out b/test_loop/23/RunTimes.out new file mode 100644 index 0000000..27ea79f --- /dev/null +++ b/test_loop/23/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.299846887589 +Solver: 0.197432041168 +Keff: 7.112840205858071 +N_cores: 1 diff --git a/test_loop/23/SolverRes.txt b/test_loop/23/SolverRes.txt new file mode 100644 index 0000000..edfdacb --- /dev/null +++ b/test_loop/23/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +7.112840205858071307e+00 +2.000000000000000000e+00 +4.972789287567138672e-01 +1.000000000000000000e+00 diff --git a/test_loop/23/V.npy b/test_loop/23/V.npy new file mode 100644 index 0000000..6c8c38e Binary files /dev/null and b/test_loop/23/V.npy differ diff --git a/test_loop/23/connec.out b/test_loop/23/connec.out new file mode 100644 index 0000000..467ee7e --- /dev/null +++ b/test_loop/23/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.484375000 + NCC : 1 diff --git a/test_loop/23/k.npy b/test_loop/23/k.npy new file mode 100644 index 0000000..0238e2a Binary files /dev/null and b/test_loop/23/k.npy differ diff --git a/test_loop/23/lc.txt b/test_loop/23/lc.txt new file mode 100644 index 0000000..ea812d3 --- /dev/null +++ b/test_loop/23/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.184607846732529168e+00 +7.184607846732529168e+00 +3.096100384860840826e+00 diff --git a/test_loop/23/tkperm_sub.txt b/test_loop/23/tkperm_sub.txt new file mode 100644 index 0000000..4fea053 --- /dev/null +++ b/test_loop/23/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.926877975463867188e-01 +1.828670501708984375e-04 diff --git a/test_loop/24/Cmap.npy b/test_loop/24/Cmap.npy new file mode 100644 index 0000000..651ad14 Binary files /dev/null and b/test_loop/24/Cmap.npy differ diff --git a/test_loop/24/ConnSummary.txt b/test_loop/24/ConnSummary.txt new file mode 100644 index 0000000..f920c43 --- /dev/null +++ b/test_loop/24/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.333819389343261719e-01 +8.253147061952488261e-01 +3.258095286626026127e-02 diff --git a/test_loop/24/ConnectivityMetrics/16.npy b/test_loop/24/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d5388c2 Binary files /dev/null and b/test_loop/24/ConnectivityMetrics/16.npy differ diff --git a/test_loop/24/ConnectivityMetrics/4.npy b/test_loop/24/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..40f4eb4 Binary files /dev/null and b/test_loop/24/ConnectivityMetrics/4.npy differ diff --git a/test_loop/24/ConnectivityMetrics/8.npy b/test_loop/24/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..775b5a7 Binary files /dev/null and b/test_loop/24/ConnectivityMetrics/8.npy differ diff --git a/test_loop/24/D.npy b/test_loop/24/D.npy new file mode 100644 index 0000000..9845201 Binary files /dev/null and b/test_loop/24/D.npy differ diff --git a/test_loop/24/GenParams.txt b/test_loop/24/GenParams.txt new file mode 100644 index 0000000..36f8e2b --- /dev/null +++ b/test_loop/24/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.083871841430664062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/24/GlobalConnectivityMetrics/16.npy b/test_loop/24/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d5388c2 Binary files /dev/null and b/test_loop/24/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/24/GlobalConnectivityMetrics/4.npy b/test_loop/24/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..d64520d Binary files /dev/null and b/test_loop/24/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/24/GlobalConnectivityMetrics/8.npy b/test_loop/24/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..d7ce4fc Binary files /dev/null and b/test_loop/24/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/24/KpostProcess/Kd1.npy b/test_loop/24/KpostProcess/Kd1.npy new file mode 100644 index 0000000..8b0269a Binary files /dev/null and b/test_loop/24/KpostProcess/Kd1.npy differ diff --git a/test_loop/24/KpostProcess/Kd16.npy b/test_loop/24/KpostProcess/Kd16.npy new file mode 100644 index 0000000..92d6e3f Binary files /dev/null and b/test_loop/24/KpostProcess/Kd16.npy differ diff --git a/test_loop/24/KpostProcess/Kd2.npy b/test_loop/24/KpostProcess/Kd2.npy new file mode 100644 index 0000000..5879dab Binary files /dev/null and b/test_loop/24/KpostProcess/Kd2.npy differ diff --git a/test_loop/24/KpostProcess/Kd4.npy b/test_loop/24/KpostProcess/Kd4.npy new file mode 100644 index 0000000..aa7f1fc Binary files /dev/null and b/test_loop/24/KpostProcess/Kd4.npy differ diff --git a/test_loop/24/KpostProcess/Kd8.npy b/test_loop/24/KpostProcess/Kd8.npy new file mode 100644 index 0000000..e51afa1 Binary files /dev/null and b/test_loop/24/KpostProcess/Kd8.npy differ diff --git a/test_loop/24/KpostProcess/Kperm2.npy b/test_loop/24/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..9db21a0 Binary files /dev/null and b/test_loop/24/KpostProcess/Kperm2.npy differ diff --git a/test_loop/24/KpostProcess/Kperm4.npy b/test_loop/24/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9db21a0 Binary files /dev/null and b/test_loop/24/KpostProcess/Kperm4.npy differ diff --git a/test_loop/24/KpostProcess/Kperm8.npy b/test_loop/24/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9db21a0 Binary files /dev/null and b/test_loop/24/KpostProcess/Kperm8.npy differ diff --git a/test_loop/24/KpostProcess/Kv1.npy b/test_loop/24/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6bfa24a Binary files /dev/null and b/test_loop/24/KpostProcess/Kv1.npy differ diff --git a/test_loop/24/KpostProcess/Kv16.npy b/test_loop/24/KpostProcess/Kv16.npy new file mode 100644 index 0000000..edda3f5 Binary files /dev/null and b/test_loop/24/KpostProcess/Kv16.npy differ diff --git a/test_loop/24/KpostProcess/Kv2.npy b/test_loop/24/KpostProcess/Kv2.npy new file mode 100644 index 0000000..fb8d125 Binary files /dev/null and b/test_loop/24/KpostProcess/Kv2.npy differ diff --git a/test_loop/24/KpostProcess/Kv4.npy b/test_loop/24/KpostProcess/Kv4.npy new file mode 100644 index 0000000..21c8e63 Binary files /dev/null and b/test_loop/24/KpostProcess/Kv4.npy differ diff --git a/test_loop/24/KpostProcess/Kv8.npy b/test_loop/24/KpostProcess/Kv8.npy new file mode 100644 index 0000000..7d23d07 Binary files /dev/null and b/test_loop/24/KpostProcess/Kv8.npy differ diff --git a/test_loop/24/P.npy b/test_loop/24/P.npy new file mode 100644 index 0000000..c492636 Binary files /dev/null and b/test_loop/24/P.npy differ diff --git a/test_loop/24/PosKeffSummary.txt b/test_loop/24/PosKeffSummary.txt new file mode 100644 index 0000000..b34d0ba --- /dev/null +++ b/test_loop/24/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.945694976130147857e+00 +4.179984274101517627e+00 +1.507849693298339844e-01 +6.818059635885256355e-03 diff --git a/test_loop/24/RunTimes.out b/test_loop/24/RunTimes.out new file mode 100644 index 0000000..6374775 --- /dev/null +++ b/test_loop/24/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.335078001022 +Solver: 0.184311151505 +Keff: 4.180023112298359 +N_cores: 1 diff --git a/test_loop/24/SolverRes.txt b/test_loop/24/SolverRes.txt new file mode 100644 index 0000000..f3cde1f --- /dev/null +++ b/test_loop/24/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.180023112298359322e+00 +2.000000000000000000e+00 +5.193891525268554688e-01 +1.000000000000000000e+00 diff --git a/test_loop/24/V.npy b/test_loop/24/V.npy new file mode 100644 index 0000000..3dbabe2 Binary files /dev/null and b/test_loop/24/V.npy differ diff --git a/test_loop/24/connec.out b/test_loop/24/connec.out new file mode 100644 index 0000000..e85dac7 --- /dev/null +++ b/test_loop/24/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.125000000 + NCC : 1 + NCC : 2 diff --git a/test_loop/24/k.npy b/test_loop/24/k.npy new file mode 100644 index 0000000..cbaa4ed Binary files /dev/null and b/test_loop/24/k.npy differ diff --git a/test_loop/24/lc.txt b/test_loop/24/lc.txt new file mode 100644 index 0000000..6048343 --- /dev/null +++ b/test_loop/24/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.181123011001311340e+00 +4.181123011001311340e+00 +4.476904459339429820e+00 diff --git a/test_loop/24/tkperm_sub.txt b/test_loop/24/tkperm_sub.txt new file mode 100644 index 0000000..94a02dd --- /dev/null +++ b/test_loop/24/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.848531246185302734e-01 +1.609325408935546875e-04 +1.239776611328125000e-04 diff --git a/test_loop/25/Cmap.npy b/test_loop/25/Cmap.npy new file mode 100644 index 0000000..a6baed8 Binary files /dev/null and b/test_loop/25/Cmap.npy differ diff --git a/test_loop/25/ConnSummary.txt b/test_loop/25/ConnSummary.txt new file mode 100644 index 0000000..e976386 --- /dev/null +++ b/test_loop/25/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.155301094055175781e-01 +8.081913156884599214e-01 +3.700706195746176347e-02 diff --git a/test_loop/25/ConnectivityMetrics/16.npy b/test_loop/25/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..673b75a Binary files /dev/null and b/test_loop/25/ConnectivityMetrics/16.npy differ diff --git a/test_loop/25/ConnectivityMetrics/4.npy b/test_loop/25/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..229e4d7 Binary files /dev/null and b/test_loop/25/ConnectivityMetrics/4.npy differ diff --git a/test_loop/25/ConnectivityMetrics/8.npy b/test_loop/25/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b1ffc73 Binary files /dev/null and b/test_loop/25/ConnectivityMetrics/8.npy differ diff --git a/test_loop/25/D.npy b/test_loop/25/D.npy new file mode 100644 index 0000000..9563c3d Binary files /dev/null and b/test_loop/25/D.npy differ diff --git a/test_loop/25/GenParams.txt b/test_loop/25/GenParams.txt new file mode 100644 index 0000000..0d09290 --- /dev/null +++ b/test_loop/25/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.165887832641601562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/25/GlobalConnectivityMetrics/16.npy b/test_loop/25/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..673b75a Binary files /dev/null and b/test_loop/25/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/25/GlobalConnectivityMetrics/4.npy b/test_loop/25/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..726cf87 Binary files /dev/null and b/test_loop/25/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/25/GlobalConnectivityMetrics/8.npy b/test_loop/25/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..da05704 Binary files /dev/null and b/test_loop/25/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/25/KpostProcess/Kd16.npy b/test_loop/25/KpostProcess/Kd16.npy new file mode 100644 index 0000000..5cc467f Binary files /dev/null and b/test_loop/25/KpostProcess/Kd16.npy differ diff --git a/test_loop/25/KpostProcess/Kd4.npy b/test_loop/25/KpostProcess/Kd4.npy new file mode 100644 index 0000000..2e2d159 Binary files /dev/null and b/test_loop/25/KpostProcess/Kd4.npy differ diff --git a/test_loop/25/KpostProcess/Kd8.npy b/test_loop/25/KpostProcess/Kd8.npy new file mode 100644 index 0000000..cbe3630 Binary files /dev/null and b/test_loop/25/KpostProcess/Kd8.npy differ diff --git a/test_loop/25/KpostProcess/Kperm4.npy b/test_loop/25/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..09eb0f0 Binary files /dev/null and b/test_loop/25/KpostProcess/Kperm4.npy differ diff --git a/test_loop/25/KpostProcess/Kperm8.npy b/test_loop/25/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..09eb0f0 Binary files /dev/null and b/test_loop/25/KpostProcess/Kperm8.npy differ diff --git a/test_loop/25/KpostProcess/Kv16.npy b/test_loop/25/KpostProcess/Kv16.npy new file mode 100644 index 0000000..e84c2cc Binary files /dev/null and b/test_loop/25/KpostProcess/Kv16.npy differ diff --git a/test_loop/25/KpostProcess/Kv4.npy b/test_loop/25/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d72499f Binary files /dev/null and b/test_loop/25/KpostProcess/Kv4.npy differ diff --git a/test_loop/25/KpostProcess/Kv8.npy b/test_loop/25/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9010ec3 Binary files /dev/null and b/test_loop/25/KpostProcess/Kv8.npy differ diff --git a/test_loop/25/P.npy b/test_loop/25/P.npy new file mode 100644 index 0000000..47a5a56 Binary files /dev/null and b/test_loop/25/P.npy differ diff --git a/test_loop/25/PosKeffSummary.txt b/test_loop/25/PosKeffSummary.txt new file mode 100644 index 0000000..1f9d38d --- /dev/null +++ b/test_loop/25/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.002680479887810527e+01 +1.022966889162428217e+01 +6.247043609619140625e-03 +1.807113960766353611e-01 diff --git a/test_loop/25/RunTimes.out b/test_loop/25/RunTimes.out new file mode 100644 index 0000000..144fef1 --- /dev/null +++ b/test_loop/25/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.29595208168 +Solver: 0.228224992752 +Keff: 10.230055415399981 +N_cores: 1 diff --git a/test_loop/25/SolverRes.txt b/test_loop/25/SolverRes.txt new file mode 100644 index 0000000..f9d091f --- /dev/null +++ b/test_loop/25/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.023005541539998120e+01 +2.000000000000000000e+00 +5.241770744323730469e-01 +1.000000000000000000e+00 diff --git a/test_loop/25/V.npy b/test_loop/25/V.npy new file mode 100644 index 0000000..03f182c Binary files /dev/null and b/test_loop/25/V.npy differ diff --git a/test_loop/25/connec.out b/test_loop/25/connec.out new file mode 100644 index 0000000..36e6eee --- /dev/null +++ b/test_loop/25/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.515625000 + NCC : 1 diff --git a/test_loop/25/k.npy b/test_loop/25/k.npy new file mode 100644 index 0000000..0286e3c Binary files /dev/null and b/test_loop/25/k.npy differ diff --git a/test_loop/25/lc.txt b/test_loop/25/lc.txt new file mode 100644 index 0000000..38a7524 --- /dev/null +++ b/test_loop/25/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.146337794163541091e+00 +7.146337794163541091e+00 +3.194064555092543500e+00 diff --git a/test_loop/25/tkperm_sub.txt b/test_loop/25/tkperm_sub.txt new file mode 100644 index 0000000..2deda79 --- /dev/null +++ b/test_loop/25/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.149991035461425781e-01 +1.730918884277343750e-04 diff --git a/test_loop/26/Cmap.npy b/test_loop/26/Cmap.npy new file mode 100644 index 0000000..88fed35 Binary files /dev/null and b/test_loop/26/Cmap.npy differ diff --git a/test_loop/26/ConnSummary.txt b/test_loop/26/ConnSummary.txt new file mode 100644 index 0000000..00a7766 --- /dev/null +++ b/test_loop/26/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.475680351257324219e-01 +8.277919009799658001e-01 +3.217780692355498573e-02 diff --git a/test_loop/26/ConnectivityMetrics/16.npy b/test_loop/26/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7305c37 Binary files /dev/null and b/test_loop/26/ConnectivityMetrics/16.npy differ diff --git a/test_loop/26/ConnectivityMetrics/4.npy b/test_loop/26/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..5892d36 Binary files /dev/null and b/test_loop/26/ConnectivityMetrics/4.npy differ diff --git a/test_loop/26/ConnectivityMetrics/8.npy b/test_loop/26/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..df8c147 Binary files /dev/null and b/test_loop/26/ConnectivityMetrics/8.npy differ diff --git a/test_loop/26/D.npy b/test_loop/26/D.npy new file mode 100644 index 0000000..dbfbcca Binary files /dev/null and b/test_loop/26/D.npy differ diff --git a/test_loop/26/GenParams.txt b/test_loop/26/GenParams.txt new file mode 100644 index 0000000..937374b --- /dev/null +++ b/test_loop/26/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.756212234497070312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/26/GlobalConnectivityMetrics/16.npy b/test_loop/26/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7305c37 Binary files /dev/null and b/test_loop/26/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/26/GlobalConnectivityMetrics/4.npy b/test_loop/26/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..fc11567 Binary files /dev/null and b/test_loop/26/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/26/GlobalConnectivityMetrics/8.npy b/test_loop/26/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..0911457 Binary files /dev/null and b/test_loop/26/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/26/KpostProcess/Kd1.npy b/test_loop/26/KpostProcess/Kd1.npy new file mode 100644 index 0000000..5f56105 Binary files /dev/null and b/test_loop/26/KpostProcess/Kd1.npy differ diff --git a/test_loop/26/KpostProcess/Kd16.npy b/test_loop/26/KpostProcess/Kd16.npy new file mode 100644 index 0000000..05b7068 Binary files /dev/null and b/test_loop/26/KpostProcess/Kd16.npy differ diff --git a/test_loop/26/KpostProcess/Kd2.npy b/test_loop/26/KpostProcess/Kd2.npy new file mode 100644 index 0000000..8fef1dd Binary files /dev/null and b/test_loop/26/KpostProcess/Kd2.npy differ diff --git a/test_loop/26/KpostProcess/Kd4.npy b/test_loop/26/KpostProcess/Kd4.npy new file mode 100644 index 0000000..506a2ec Binary files /dev/null and b/test_loop/26/KpostProcess/Kd4.npy differ diff --git a/test_loop/26/KpostProcess/Kd8.npy b/test_loop/26/KpostProcess/Kd8.npy new file mode 100644 index 0000000..6587ff0 Binary files /dev/null and b/test_loop/26/KpostProcess/Kd8.npy differ diff --git a/test_loop/26/KpostProcess/Kperm2.npy b/test_loop/26/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..c409bcc Binary files /dev/null and b/test_loop/26/KpostProcess/Kperm2.npy differ diff --git a/test_loop/26/KpostProcess/Kperm4.npy b/test_loop/26/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..c409bcc Binary files /dev/null and b/test_loop/26/KpostProcess/Kperm4.npy differ diff --git a/test_loop/26/KpostProcess/Kperm8.npy b/test_loop/26/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..c409bcc Binary files /dev/null and b/test_loop/26/KpostProcess/Kperm8.npy differ diff --git a/test_loop/26/KpostProcess/Kv1.npy b/test_loop/26/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6f6059d Binary files /dev/null and b/test_loop/26/KpostProcess/Kv1.npy differ diff --git a/test_loop/26/KpostProcess/Kv16.npy b/test_loop/26/KpostProcess/Kv16.npy new file mode 100644 index 0000000..5f3c366 Binary files /dev/null and b/test_loop/26/KpostProcess/Kv16.npy differ diff --git a/test_loop/26/KpostProcess/Kv2.npy b/test_loop/26/KpostProcess/Kv2.npy new file mode 100644 index 0000000..0cdb411 Binary files /dev/null and b/test_loop/26/KpostProcess/Kv2.npy differ diff --git a/test_loop/26/KpostProcess/Kv4.npy b/test_loop/26/KpostProcess/Kv4.npy new file mode 100644 index 0000000..721926e Binary files /dev/null and b/test_loop/26/KpostProcess/Kv4.npy differ diff --git a/test_loop/26/KpostProcess/Kv8.npy b/test_loop/26/KpostProcess/Kv8.npy new file mode 100644 index 0000000..514fb35 Binary files /dev/null and b/test_loop/26/KpostProcess/Kv8.npy differ diff --git a/test_loop/26/P.npy b/test_loop/26/P.npy new file mode 100644 index 0000000..d576887 Binary files /dev/null and b/test_loop/26/P.npy differ diff --git a/test_loop/26/PosKeffSummary.txt b/test_loop/26/PosKeffSummary.txt new file mode 100644 index 0000000..88eb36c --- /dev/null +++ b/test_loop/26/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +7.051240634322968326e+00 +7.129459477715172078e+00 +1.689040660858154297e-01 +6.448015696570609870e-03 diff --git a/test_loop/26/RunTimes.out b/test_loop/26/RunTimes.out new file mode 100644 index 0000000..0600673 --- /dev/null +++ b/test_loop/26/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.29544210434 +Solver: 0.219120979309 +Keff: 7.129436312848993 +N_cores: 1 diff --git a/test_loop/26/SolverRes.txt b/test_loop/26/SolverRes.txt new file mode 100644 index 0000000..5814e0e --- /dev/null +++ b/test_loop/26/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +7.129436312848993040e+00 +2.000000000000000000e+00 +5.145630836486816406e-01 +1.000000000000000000e+00 diff --git a/test_loop/26/V.npy b/test_loop/26/V.npy new file mode 100644 index 0000000..95af75a Binary files /dev/null and b/test_loop/26/V.npy differ diff --git a/test_loop/26/connec.out b/test_loop/26/connec.out new file mode 100644 index 0000000..e85dac7 --- /dev/null +++ b/test_loop/26/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.125000000 + NCC : 1 + NCC : 2 diff --git a/test_loop/26/k.npy b/test_loop/26/k.npy new file mode 100644 index 0000000..e03b1e2 Binary files /dev/null and b/test_loop/26/k.npy differ diff --git a/test_loop/26/lc.txt b/test_loop/26/lc.txt new file mode 100644 index 0000000..92dfba9 --- /dev/null +++ b/test_loop/26/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.167695717809476008e+00 +4.167695717809476008e+00 +4.468232677758933846e+00 diff --git a/test_loop/26/tkperm_sub.txt b/test_loop/26/tkperm_sub.txt new file mode 100644 index 0000000..17588e5 --- /dev/null +++ b/test_loop/26/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.963028430938720703e-01 +1.559257507324218750e-04 +1.251697540283203125e-04 diff --git a/test_loop/27/Cmap.npy b/test_loop/27/Cmap.npy new file mode 100644 index 0000000..f006d60 Binary files /dev/null and b/test_loop/27/Cmap.npy differ diff --git a/test_loop/27/ConnSummary.txt b/test_loop/27/ConnSummary.txt new file mode 100644 index 0000000..41e4518 --- /dev/null +++ b/test_loop/27/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.530439376831054688e-01 +7.811450770548846734e-01 +5.022934379677129746e-02 diff --git a/test_loop/27/ConnectivityMetrics/16.npy b/test_loop/27/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..1b561fe Binary files /dev/null and b/test_loop/27/ConnectivityMetrics/16.npy differ diff --git a/test_loop/27/ConnectivityMetrics/4.npy b/test_loop/27/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..a2922f8 Binary files /dev/null and b/test_loop/27/ConnectivityMetrics/4.npy differ diff --git a/test_loop/27/ConnectivityMetrics/8.npy b/test_loop/27/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..a1cdf83 Binary files /dev/null and b/test_loop/27/ConnectivityMetrics/8.npy differ diff --git a/test_loop/27/D.npy b/test_loop/27/D.npy new file mode 100644 index 0000000..72c41bb Binary files /dev/null and b/test_loop/27/D.npy differ diff --git a/test_loop/27/GenParams.txt b/test_loop/27/GenParams.txt new file mode 100644 index 0000000..ee6e0da --- /dev/null +++ b/test_loop/27/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +3.919124603271484375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/27/GlobalConnectivityMetrics/16.npy b/test_loop/27/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..1b561fe Binary files /dev/null and b/test_loop/27/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/27/GlobalConnectivityMetrics/4.npy b/test_loop/27/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..63856e4 Binary files /dev/null and b/test_loop/27/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/27/GlobalConnectivityMetrics/8.npy b/test_loop/27/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..8f7374a Binary files /dev/null and b/test_loop/27/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/27/KpostProcess/Kd16.npy b/test_loop/27/KpostProcess/Kd16.npy new file mode 100644 index 0000000..67ed5a4 Binary files /dev/null and b/test_loop/27/KpostProcess/Kd16.npy differ diff --git a/test_loop/27/KpostProcess/Kd4.npy b/test_loop/27/KpostProcess/Kd4.npy new file mode 100644 index 0000000..b7e3205 Binary files /dev/null and b/test_loop/27/KpostProcess/Kd4.npy differ diff --git a/test_loop/27/KpostProcess/Kd8.npy b/test_loop/27/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2a4c529 Binary files /dev/null and b/test_loop/27/KpostProcess/Kd8.npy differ diff --git a/test_loop/27/KpostProcess/Kperm4.npy b/test_loop/27/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..6ecee6f Binary files /dev/null and b/test_loop/27/KpostProcess/Kperm4.npy differ diff --git a/test_loop/27/KpostProcess/Kperm8.npy b/test_loop/27/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..6ecee6f Binary files /dev/null and b/test_loop/27/KpostProcess/Kperm8.npy differ diff --git a/test_loop/27/KpostProcess/Kv16.npy b/test_loop/27/KpostProcess/Kv16.npy new file mode 100644 index 0000000..13ba485 Binary files /dev/null and b/test_loop/27/KpostProcess/Kv16.npy differ diff --git a/test_loop/27/KpostProcess/Kv4.npy b/test_loop/27/KpostProcess/Kv4.npy new file mode 100644 index 0000000..1310c74 Binary files /dev/null and b/test_loop/27/KpostProcess/Kv4.npy differ diff --git a/test_loop/27/KpostProcess/Kv8.npy b/test_loop/27/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a34f0c8 Binary files /dev/null and b/test_loop/27/KpostProcess/Kv8.npy differ diff --git a/test_loop/27/P.npy b/test_loop/27/P.npy new file mode 100644 index 0000000..cae9c3f Binary files /dev/null and b/test_loop/27/P.npy differ diff --git a/test_loop/27/PosKeffSummary.txt b/test_loop/27/PosKeffSummary.txt new file mode 100644 index 0000000..988552f --- /dev/null +++ b/test_loop/27/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.104369196896397831e+01 +1.141446872271811230e+01 +4.496097564697265625e-03 +2.361862339590624638e-01 diff --git a/test_loop/27/RunTimes.out b/test_loop/27/RunTimes.out new file mode 100644 index 0000000..be11aac --- /dev/null +++ b/test_loop/27/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.330250024796 +Solver: 0.174524068832 +Keff: 11.414562190530749 +N_cores: 1 diff --git a/test_loop/27/SolverRes.txt b/test_loop/27/SolverRes.txt new file mode 100644 index 0000000..bdf590a --- /dev/null +++ b/test_loop/27/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.141456219053074861e+01 +2.000000000000000000e+00 +5.047740936279296875e-01 +1.000000000000000000e+00 diff --git a/test_loop/27/V.npy b/test_loop/27/V.npy new file mode 100644 index 0000000..c87d0dd Binary files /dev/null and b/test_loop/27/V.npy differ diff --git a/test_loop/27/connec.out b/test_loop/27/connec.out new file mode 100644 index 0000000..2744c0d --- /dev/null +++ b/test_loop/27/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.593750000 + NCC : 1 + NCC : 2 diff --git a/test_loop/27/k.npy b/test_loop/27/k.npy new file mode 100644 index 0000000..f5565c0 Binary files /dev/null and b/test_loop/27/k.npy differ diff --git a/test_loop/27/lc.txt b/test_loop/27/lc.txt new file mode 100644 index 0000000..4298953 --- /dev/null +++ b/test_loop/27/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.111477064122327718e+00 +7.111477064122327718e+00 +3.337277924195318768e+00 diff --git a/test_loop/27/tkperm_sub.txt b/test_loop/27/tkperm_sub.txt new file mode 100644 index 0000000..f9808dd --- /dev/null +++ b/test_loop/27/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.158888816833496094e-01 +2.079010009765625000e-04 diff --git a/test_loop/28/Cmap.npy b/test_loop/28/Cmap.npy new file mode 100644 index 0000000..76de57f Binary files /dev/null and b/test_loop/28/Cmap.npy differ diff --git a/test_loop/28/ConnSummary.txt b/test_loop/28/ConnSummary.txt new file mode 100644 index 0000000..c07a5aa --- /dev/null +++ b/test_loop/28/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.367771148681640625e-01 +8.273580003231483238e-01 +3.390764944518923768e-02 diff --git a/test_loop/28/ConnectivityMetrics/16.npy b/test_loop/28/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..0637213 Binary files /dev/null and b/test_loop/28/ConnectivityMetrics/16.npy differ diff --git a/test_loop/28/ConnectivityMetrics/4.npy b/test_loop/28/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..69ff4c9 Binary files /dev/null and b/test_loop/28/ConnectivityMetrics/4.npy differ diff --git a/test_loop/28/ConnectivityMetrics/8.npy b/test_loop/28/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..67f11b8 Binary files /dev/null and b/test_loop/28/ConnectivityMetrics/8.npy differ diff --git a/test_loop/28/D.npy b/test_loop/28/D.npy new file mode 100644 index 0000000..8fa20e7 Binary files /dev/null and b/test_loop/28/D.npy differ diff --git a/test_loop/28/GenParams.txt b/test_loop/28/GenParams.txt new file mode 100644 index 0000000..3d63d23 --- /dev/null +++ b/test_loop/28/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.163026809692382812e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/28/GlobalConnectivityMetrics/16.npy b/test_loop/28/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..0637213 Binary files /dev/null and b/test_loop/28/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/28/GlobalConnectivityMetrics/4.npy b/test_loop/28/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..970dab2 Binary files /dev/null and b/test_loop/28/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/28/GlobalConnectivityMetrics/8.npy b/test_loop/28/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..f45fea1 Binary files /dev/null and b/test_loop/28/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/28/KpostProcess/Kd1.npy b/test_loop/28/KpostProcess/Kd1.npy new file mode 100644 index 0000000..f96484e Binary files /dev/null and b/test_loop/28/KpostProcess/Kd1.npy differ diff --git a/test_loop/28/KpostProcess/Kd16.npy b/test_loop/28/KpostProcess/Kd16.npy new file mode 100644 index 0000000..15e3f58 Binary files /dev/null and b/test_loop/28/KpostProcess/Kd16.npy differ diff --git a/test_loop/28/KpostProcess/Kd2.npy b/test_loop/28/KpostProcess/Kd2.npy new file mode 100644 index 0000000..8514892 Binary files /dev/null and b/test_loop/28/KpostProcess/Kd2.npy differ diff --git a/test_loop/28/KpostProcess/Kd4.npy b/test_loop/28/KpostProcess/Kd4.npy new file mode 100644 index 0000000..8767135 Binary files /dev/null and b/test_loop/28/KpostProcess/Kd4.npy differ diff --git a/test_loop/28/KpostProcess/Kd8.npy b/test_loop/28/KpostProcess/Kd8.npy new file mode 100644 index 0000000..0576e7a Binary files /dev/null and b/test_loop/28/KpostProcess/Kd8.npy differ diff --git a/test_loop/28/KpostProcess/Kperm2.npy b/test_loop/28/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..0b9be9b Binary files /dev/null and b/test_loop/28/KpostProcess/Kperm2.npy differ diff --git a/test_loop/28/KpostProcess/Kperm4.npy b/test_loop/28/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..0b9be9b Binary files /dev/null and b/test_loop/28/KpostProcess/Kperm4.npy differ diff --git a/test_loop/28/KpostProcess/Kperm8.npy b/test_loop/28/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..0b9be9b Binary files /dev/null and b/test_loop/28/KpostProcess/Kperm8.npy differ diff --git a/test_loop/28/KpostProcess/Kv1.npy b/test_loop/28/KpostProcess/Kv1.npy new file mode 100644 index 0000000..3d00369 Binary files /dev/null and b/test_loop/28/KpostProcess/Kv1.npy differ diff --git a/test_loop/28/KpostProcess/Kv16.npy b/test_loop/28/KpostProcess/Kv16.npy new file mode 100644 index 0000000..97d78e7 Binary files /dev/null and b/test_loop/28/KpostProcess/Kv16.npy differ diff --git a/test_loop/28/KpostProcess/Kv2.npy b/test_loop/28/KpostProcess/Kv2.npy new file mode 100644 index 0000000..78ed34b Binary files /dev/null and b/test_loop/28/KpostProcess/Kv2.npy differ diff --git a/test_loop/28/KpostProcess/Kv4.npy b/test_loop/28/KpostProcess/Kv4.npy new file mode 100644 index 0000000..7299151 Binary files /dev/null and b/test_loop/28/KpostProcess/Kv4.npy differ diff --git a/test_loop/28/KpostProcess/Kv8.npy b/test_loop/28/KpostProcess/Kv8.npy new file mode 100644 index 0000000..fc9bec5 Binary files /dev/null and b/test_loop/28/KpostProcess/Kv8.npy differ diff --git a/test_loop/28/P.npy b/test_loop/28/P.npy new file mode 100644 index 0000000..f9fb579 Binary files /dev/null and b/test_loop/28/P.npy differ diff --git a/test_loop/28/PosKeffSummary.txt b/test_loop/28/PosKeffSummary.txt new file mode 100644 index 0000000..b269a2a --- /dev/null +++ b/test_loop/28/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +7.596144056711763959e+00 +7.659117508444766464e+00 +2.010400295257568359e-01 +6.739616922213934047e-03 diff --git a/test_loop/28/RunTimes.out b/test_loop/28/RunTimes.out new file mode 100644 index 0000000..240b341 --- /dev/null +++ b/test_loop/28/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.328583955765 +Solver: 0.179651021957 +Keff: 7.659295095545988 +N_cores: 1 diff --git a/test_loop/28/SolverRes.txt b/test_loop/28/SolverRes.txt new file mode 100644 index 0000000..36520d1 --- /dev/null +++ b/test_loop/28/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +7.659295095545988197e+00 +2.000000000000000000e+00 +5.082349777221679688e-01 +1.000000000000000000e+00 diff --git a/test_loop/28/V.npy b/test_loop/28/V.npy new file mode 100644 index 0000000..c91a970 Binary files /dev/null and b/test_loop/28/V.npy differ diff --git a/test_loop/28/connec.out b/test_loop/28/connec.out new file mode 100644 index 0000000..a047cb8 --- /dev/null +++ b/test_loop/28/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.171875000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/28/k.npy b/test_loop/28/k.npy new file mode 100644 index 0000000..3adc976 Binary files /dev/null and b/test_loop/28/k.npy differ diff --git a/test_loop/28/lc.txt b/test_loop/28/lc.txt new file mode 100644 index 0000000..5de7d1d --- /dev/null +++ b/test_loop/28/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.157444155384425244e+00 +4.157444155384425244e+00 +4.333305485579058924e+00 diff --git a/test_loop/28/tkperm_sub.txt b/test_loop/28/tkperm_sub.txt new file mode 100644 index 0000000..2cb44f4 --- /dev/null +++ b/test_loop/28/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.457249641418457031e-01 +2.081394195556640625e-04 +1.671314239501953125e-04 diff --git a/test_loop/29/Cmap.npy b/test_loop/29/Cmap.npy new file mode 100644 index 0000000..000bf95 Binary files /dev/null and b/test_loop/29/Cmap.npy differ diff --git a/test_loop/29/ConnSummary.txt b/test_loop/29/ConnSummary.txt new file mode 100644 index 0000000..855b415 --- /dev/null +++ b/test_loop/29/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.451368808746337891e-01 +7.831292842197029591e-01 +3.581491963644879012e-02 diff --git a/test_loop/29/ConnectivityMetrics/16.npy b/test_loop/29/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7467865 Binary files /dev/null and b/test_loop/29/ConnectivityMetrics/16.npy differ diff --git a/test_loop/29/ConnectivityMetrics/4.npy b/test_loop/29/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..d44cf1b Binary files /dev/null and b/test_loop/29/ConnectivityMetrics/4.npy differ diff --git a/test_loop/29/ConnectivityMetrics/8.npy b/test_loop/29/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..bef1315 Binary files /dev/null and b/test_loop/29/ConnectivityMetrics/8.npy differ diff --git a/test_loop/29/D.npy b/test_loop/29/D.npy new file mode 100644 index 0000000..10d1c22 Binary files /dev/null and b/test_loop/29/D.npy differ diff --git a/test_loop/29/GenParams.txt b/test_loop/29/GenParams.txt new file mode 100644 index 0000000..4f1cd47 --- /dev/null +++ b/test_loop/29/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.721164703369140625e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/29/GlobalConnectivityMetrics/16.npy b/test_loop/29/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7467865 Binary files /dev/null and b/test_loop/29/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/29/GlobalConnectivityMetrics/4.npy b/test_loop/29/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..9a7642e Binary files /dev/null and b/test_loop/29/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/29/GlobalConnectivityMetrics/8.npy b/test_loop/29/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..726674f Binary files /dev/null and b/test_loop/29/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/29/KpostProcess/Kd16.npy b/test_loop/29/KpostProcess/Kd16.npy new file mode 100644 index 0000000..40fab9d Binary files /dev/null and b/test_loop/29/KpostProcess/Kd16.npy differ diff --git a/test_loop/29/KpostProcess/Kd4.npy b/test_loop/29/KpostProcess/Kd4.npy new file mode 100644 index 0000000..d498b7a Binary files /dev/null and b/test_loop/29/KpostProcess/Kd4.npy differ diff --git a/test_loop/29/KpostProcess/Kd8.npy b/test_loop/29/KpostProcess/Kd8.npy new file mode 100644 index 0000000..a6fedb2 Binary files /dev/null and b/test_loop/29/KpostProcess/Kd8.npy differ diff --git a/test_loop/29/KpostProcess/Kperm4.npy b/test_loop/29/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..b982777 Binary files /dev/null and b/test_loop/29/KpostProcess/Kperm4.npy differ diff --git a/test_loop/29/KpostProcess/Kperm8.npy b/test_loop/29/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..b982777 Binary files /dev/null and b/test_loop/29/KpostProcess/Kperm8.npy differ diff --git a/test_loop/29/KpostProcess/Kv16.npy b/test_loop/29/KpostProcess/Kv16.npy new file mode 100644 index 0000000..3aa8254 Binary files /dev/null and b/test_loop/29/KpostProcess/Kv16.npy differ diff --git a/test_loop/29/KpostProcess/Kv4.npy b/test_loop/29/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0aad298 Binary files /dev/null and b/test_loop/29/KpostProcess/Kv4.npy differ diff --git a/test_loop/29/KpostProcess/Kv8.npy b/test_loop/29/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0af7b1b Binary files /dev/null and b/test_loop/29/KpostProcess/Kv8.npy differ diff --git a/test_loop/29/P.npy b/test_loop/29/P.npy new file mode 100644 index 0000000..0f34541 Binary files /dev/null and b/test_loop/29/P.npy differ diff --git a/test_loop/29/PosKeffSummary.txt b/test_loop/29/PosKeffSummary.txt new file mode 100644 index 0000000..ed69ec8 --- /dev/null +++ b/test_loop/29/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.246275408812187635e+01 +1.276313403629116650e+01 +4.431962966918945312e-03 +2.547743289041906611e-01 diff --git a/test_loop/29/RunTimes.out b/test_loop/29/RunTimes.out new file mode 100644 index 0000000..dc3e395 --- /dev/null +++ b/test_loop/29/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.306303977966 +Solver: 0.183084964752 +Keff: 12.763205477276985 +N_cores: 1 diff --git a/test_loop/29/SolverRes.txt b/test_loop/29/SolverRes.txt new file mode 100644 index 0000000..70c141e --- /dev/null +++ b/test_loop/29/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.276320547727698518e+01 +2.000000000000000000e+00 +4.893889427185058594e-01 +1.000000000000000000e+00 diff --git a/test_loop/29/V.npy b/test_loop/29/V.npy new file mode 100644 index 0000000..108688e Binary files /dev/null and b/test_loop/29/V.npy differ diff --git a/test_loop/29/connec.out b/test_loop/29/connec.out new file mode 100644 index 0000000..0212456 --- /dev/null +++ b/test_loop/29/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.609375000 + NCC : 1 + NCC : 2 diff --git a/test_loop/29/k.npy b/test_loop/29/k.npy new file mode 100644 index 0000000..4dff767 Binary files /dev/null and b/test_loop/29/k.npy differ diff --git a/test_loop/29/lc.txt b/test_loop/29/lc.txt new file mode 100644 index 0000000..55f1ea2 --- /dev/null +++ b/test_loop/29/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.084803347463729750e+00 +7.084803347463729750e+00 +3.360398281748228744e+00 diff --git a/test_loop/29/tkperm_sub.txt b/test_loop/29/tkperm_sub.txt new file mode 100644 index 0000000..e103094 --- /dev/null +++ b/test_loop/29/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.914110660552978516e-01 +1.649856567382812500e-04 diff --git a/test_loop/3/Cmap.npy b/test_loop/3/Cmap.npy new file mode 100644 index 0000000..0ca8e4c Binary files /dev/null and b/test_loop/3/Cmap.npy differ diff --git a/test_loop/3/ConnSummary.txt b/test_loop/3/ConnSummary.txt new file mode 100644 index 0000000..a4dcf7a --- /dev/null +++ b/test_loop/3/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.863340854644775391e-01 +9.037431005381323379e-01 +1.934275992201322375e-02 diff --git a/test_loop/3/ConnectivityMetrics/16.npy b/test_loop/3/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..ab42ad6 Binary files /dev/null and b/test_loop/3/ConnectivityMetrics/16.npy differ diff --git a/test_loop/3/ConnectivityMetrics/4.npy b/test_loop/3/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..a7a2ab3 Binary files /dev/null and b/test_loop/3/ConnectivityMetrics/4.npy differ diff --git a/test_loop/3/ConnectivityMetrics/8.npy b/test_loop/3/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..35d1c7a Binary files /dev/null and b/test_loop/3/ConnectivityMetrics/8.npy differ diff --git a/test_loop/3/D.npy b/test_loop/3/D.npy new file mode 100644 index 0000000..b40ecac Binary files /dev/null and b/test_loop/3/D.npy differ diff --git a/test_loop/3/GenParams.txt b/test_loop/3/GenParams.txt new file mode 100644 index 0000000..41c31a3 --- /dev/null +++ b/test_loop/3/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +3.851890563964843750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/3/GlobalConnectivityMetrics/16.npy b/test_loop/3/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..ab42ad6 Binary files /dev/null and b/test_loop/3/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/3/GlobalConnectivityMetrics/4.npy b/test_loop/3/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..308cf50 Binary files /dev/null and b/test_loop/3/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/3/GlobalConnectivityMetrics/8.npy b/test_loop/3/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..93443db Binary files /dev/null and b/test_loop/3/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/3/KpostProcess/Kd16.npy b/test_loop/3/KpostProcess/Kd16.npy new file mode 100644 index 0000000..d0b9a46 Binary files /dev/null and b/test_loop/3/KpostProcess/Kd16.npy differ diff --git a/test_loop/3/KpostProcess/Kd4.npy b/test_loop/3/KpostProcess/Kd4.npy new file mode 100644 index 0000000..225e835 Binary files /dev/null and b/test_loop/3/KpostProcess/Kd4.npy differ diff --git a/test_loop/3/KpostProcess/Kd8.npy b/test_loop/3/KpostProcess/Kd8.npy new file mode 100644 index 0000000..f5949e9 Binary files /dev/null and b/test_loop/3/KpostProcess/Kd8.npy differ diff --git a/test_loop/3/KpostProcess/Kperm4.npy b/test_loop/3/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..1607e03 Binary files /dev/null and b/test_loop/3/KpostProcess/Kperm4.npy differ diff --git a/test_loop/3/KpostProcess/Kperm8.npy b/test_loop/3/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..1607e03 Binary files /dev/null and b/test_loop/3/KpostProcess/Kperm8.npy differ diff --git a/test_loop/3/KpostProcess/Kv16.npy b/test_loop/3/KpostProcess/Kv16.npy new file mode 100644 index 0000000..be5eb25 Binary files /dev/null and b/test_loop/3/KpostProcess/Kv16.npy differ diff --git a/test_loop/3/KpostProcess/Kv4.npy b/test_loop/3/KpostProcess/Kv4.npy new file mode 100644 index 0000000..8c2346e Binary files /dev/null and b/test_loop/3/KpostProcess/Kv4.npy differ diff --git a/test_loop/3/KpostProcess/Kv8.npy b/test_loop/3/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0150bcd Binary files /dev/null and b/test_loop/3/KpostProcess/Kv8.npy differ diff --git a/test_loop/3/P.npy b/test_loop/3/P.npy new file mode 100644 index 0000000..89c8181 Binary files /dev/null and b/test_loop/3/P.npy differ diff --git a/test_loop/3/PosKeffSummary.txt b/test_loop/3/PosKeffSummary.txt new file mode 100644 index 0000000..56e1372 --- /dev/null +++ b/test_loop/3/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.390320975860645708e-02 +2.425135285972233878e-02 +7.822990417480468750e-03 +1.798427404608070324e-01 diff --git a/test_loop/3/RunTimes.out b/test_loop/3/RunTimes.out new file mode 100644 index 0000000..9613c53 --- /dev/null +++ b/test_loop/3/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.31564283371 +Solver: 0.208812236786 +Keff: 0.024288313662818257 +N_cores: 1 diff --git a/test_loop/3/SolverRes.txt b/test_loop/3/SolverRes.txt new file mode 100644 index 0000000..6d965d2 --- /dev/null +++ b/test_loop/3/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.428831366281825749e-02 +2.000000000000000000e+00 +5.244550704956054688e-01 +1.000000000000000000e+00 diff --git a/test_loop/3/V.npy b/test_loop/3/V.npy new file mode 100644 index 0000000..6e5ccde Binary files /dev/null and b/test_loop/3/V.npy differ diff --git a/test_loop/3/connec.out b/test_loop/3/connec.out new file mode 100644 index 0000000..f511dc2 --- /dev/null +++ b/test_loop/3/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.125000000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/3/k.npy b/test_loop/3/k.npy new file mode 100644 index 0000000..50078ca Binary files /dev/null and b/test_loop/3/k.npy differ diff --git a/test_loop/3/lc.txt b/test_loop/3/lc.txt new file mode 100644 index 0000000..3a1a2ef --- /dev/null +++ b/test_loop/3/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +8.057869322738843820e+00 +8.057869322738843820e+00 +2.756341990128622577e+00 diff --git a/test_loop/3/tkperm_sub.txt b/test_loop/3/tkperm_sub.txt new file mode 100644 index 0000000..37a4fd4 --- /dev/null +++ b/test_loop/3/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.482868671417236328e-01 +2.439022064208984375e-04 diff --git a/test_loop/30/Cmap.npy b/test_loop/30/Cmap.npy new file mode 100644 index 0000000..80e04af Binary files /dev/null and b/test_loop/30/Cmap.npy differ diff --git a/test_loop/30/ConnSummary.txt b/test_loop/30/ConnSummary.txt new file mode 100644 index 0000000..e77c740 --- /dev/null +++ b/test_loop/30/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.243599414825439453e-01 +8.173012174189808743e-01 +4.268264126493356153e-02 diff --git a/test_loop/30/ConnectivityMetrics/16.npy b/test_loop/30/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..0b34761 Binary files /dev/null and b/test_loop/30/ConnectivityMetrics/16.npy differ diff --git a/test_loop/30/ConnectivityMetrics/4.npy b/test_loop/30/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..4f25cfd Binary files /dev/null and b/test_loop/30/ConnectivityMetrics/4.npy differ diff --git a/test_loop/30/ConnectivityMetrics/8.npy b/test_loop/30/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..177d42a Binary files /dev/null and b/test_loop/30/ConnectivityMetrics/8.npy differ diff --git a/test_loop/30/D.npy b/test_loop/30/D.npy new file mode 100644 index 0000000..c0b9859 Binary files /dev/null and b/test_loop/30/D.npy differ diff --git a/test_loop/30/GenParams.txt b/test_loop/30/GenParams.txt new file mode 100644 index 0000000..0089749 --- /dev/null +++ b/test_loop/30/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.939006805419921875e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/30/GlobalConnectivityMetrics/16.npy b/test_loop/30/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..0b34761 Binary files /dev/null and b/test_loop/30/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/30/GlobalConnectivityMetrics/4.npy b/test_loop/30/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..7523023 Binary files /dev/null and b/test_loop/30/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/30/GlobalConnectivityMetrics/8.npy b/test_loop/30/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..45af17d Binary files /dev/null and b/test_loop/30/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/30/KpostProcess/Kd1.npy b/test_loop/30/KpostProcess/Kd1.npy new file mode 100644 index 0000000..8d8bf05 Binary files /dev/null and b/test_loop/30/KpostProcess/Kd1.npy differ diff --git a/test_loop/30/KpostProcess/Kd16.npy b/test_loop/30/KpostProcess/Kd16.npy new file mode 100644 index 0000000..4b2b35d Binary files /dev/null and b/test_loop/30/KpostProcess/Kd16.npy differ diff --git a/test_loop/30/KpostProcess/Kd2.npy b/test_loop/30/KpostProcess/Kd2.npy new file mode 100644 index 0000000..ae186f7 Binary files /dev/null and b/test_loop/30/KpostProcess/Kd2.npy differ diff --git a/test_loop/30/KpostProcess/Kd4.npy b/test_loop/30/KpostProcess/Kd4.npy new file mode 100644 index 0000000..22c8b18 Binary files /dev/null and b/test_loop/30/KpostProcess/Kd4.npy differ diff --git a/test_loop/30/KpostProcess/Kd8.npy b/test_loop/30/KpostProcess/Kd8.npy new file mode 100644 index 0000000..fd26724 Binary files /dev/null and b/test_loop/30/KpostProcess/Kd8.npy differ diff --git a/test_loop/30/KpostProcess/Kperm2.npy b/test_loop/30/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..5881c4f Binary files /dev/null and b/test_loop/30/KpostProcess/Kperm2.npy differ diff --git a/test_loop/30/KpostProcess/Kperm4.npy b/test_loop/30/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..5881c4f Binary files /dev/null and b/test_loop/30/KpostProcess/Kperm4.npy differ diff --git a/test_loop/30/KpostProcess/Kperm8.npy b/test_loop/30/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..5881c4f Binary files /dev/null and b/test_loop/30/KpostProcess/Kperm8.npy differ diff --git a/test_loop/30/KpostProcess/Kv1.npy b/test_loop/30/KpostProcess/Kv1.npy new file mode 100644 index 0000000..01197ac Binary files /dev/null and b/test_loop/30/KpostProcess/Kv1.npy differ diff --git a/test_loop/30/KpostProcess/Kv16.npy b/test_loop/30/KpostProcess/Kv16.npy new file mode 100644 index 0000000..54c2168 Binary files /dev/null and b/test_loop/30/KpostProcess/Kv16.npy differ diff --git a/test_loop/30/KpostProcess/Kv2.npy b/test_loop/30/KpostProcess/Kv2.npy new file mode 100644 index 0000000..4b88e18 Binary files /dev/null and b/test_loop/30/KpostProcess/Kv2.npy differ diff --git a/test_loop/30/KpostProcess/Kv4.npy b/test_loop/30/KpostProcess/Kv4.npy new file mode 100644 index 0000000..06e842c Binary files /dev/null and b/test_loop/30/KpostProcess/Kv4.npy differ diff --git a/test_loop/30/KpostProcess/Kv8.npy b/test_loop/30/KpostProcess/Kv8.npy new file mode 100644 index 0000000..538de9b Binary files /dev/null and b/test_loop/30/KpostProcess/Kv8.npy differ diff --git a/test_loop/30/P.npy b/test_loop/30/P.npy new file mode 100644 index 0000000..cd9704a Binary files /dev/null and b/test_loop/30/P.npy differ diff --git a/test_loop/30/PosKeffSummary.txt b/test_loop/30/PosKeffSummary.txt new file mode 100644 index 0000000..bcacc9b --- /dev/null +++ b/test_loop/30/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.428062152645457987e-02 +1.428178949857758853e-02 +1.528880596160888672e-01 +6.802243711199374918e-03 diff --git a/test_loop/30/RunTimes.out b/test_loop/30/RunTimes.out new file mode 100644 index 0000000..af5eb44 --- /dev/null +++ b/test_loop/30/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.32647895813 +Solver: 0.165733098984 +Keff: 0.014293949051807756 +N_cores: 1 diff --git a/test_loop/30/SolverRes.txt b/test_loop/30/SolverRes.txt new file mode 100644 index 0000000..2486155 --- /dev/null +++ b/test_loop/30/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.429394905180775624e-02 +2.000000000000000000e+00 +4.922120571136474609e-01 +1.000000000000000000e+00 diff --git a/test_loop/30/V.npy b/test_loop/30/V.npy new file mode 100644 index 0000000..b1fa5b8 Binary files /dev/null and b/test_loop/30/V.npy differ diff --git a/test_loop/30/connec.out b/test_loop/30/connec.out new file mode 100644 index 0000000..dae61fe --- /dev/null +++ b/test_loop/30/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.140625000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/30/k.npy b/test_loop/30/k.npy new file mode 100644 index 0000000..248c94c Binary files /dev/null and b/test_loop/30/k.npy differ diff --git a/test_loop/30/lc.txt b/test_loop/30/lc.txt new file mode 100644 index 0000000..f880351 --- /dev/null +++ b/test_loop/30/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.627408011694312151e+00 +3.640425652750334695e+00 +1.135028111467740297e+00 diff --git a/test_loop/30/tkperm_sub.txt b/test_loop/30/tkperm_sub.txt new file mode 100644 index 0000000..a9272fa --- /dev/null +++ b/test_loop/30/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.838191032409667969e-01 +1.659393310546875000e-04 +1.349449157714843750e-04 diff --git a/test_loop/31/Cmap.npy b/test_loop/31/Cmap.npy new file mode 100644 index 0000000..7d2283b Binary files /dev/null and b/test_loop/31/Cmap.npy differ diff --git a/test_loop/31/ConnSummary.txt b/test_loop/31/ConnSummary.txt new file mode 100644 index 0000000..8b706c2 --- /dev/null +++ b/test_loop/31/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.669719696044921875e-01 +8.186834391031138081e-01 +3.614688745783502244e-02 diff --git a/test_loop/31/ConnectivityMetrics/16.npy b/test_loop/31/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..71843dc Binary files /dev/null and b/test_loop/31/ConnectivityMetrics/16.npy differ diff --git a/test_loop/31/ConnectivityMetrics/4.npy b/test_loop/31/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..6da5d23 Binary files /dev/null and b/test_loop/31/ConnectivityMetrics/4.npy differ diff --git a/test_loop/31/ConnectivityMetrics/8.npy b/test_loop/31/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..0052216 Binary files /dev/null and b/test_loop/31/ConnectivityMetrics/8.npy differ diff --git a/test_loop/31/D.npy b/test_loop/31/D.npy new file mode 100644 index 0000000..6a8ee95 Binary files /dev/null and b/test_loop/31/D.npy differ diff --git a/test_loop/31/GenParams.txt b/test_loop/31/GenParams.txt new file mode 100644 index 0000000..049231a --- /dev/null +++ b/test_loop/31/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +7.677078247070312500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/31/GlobalConnectivityMetrics/16.npy b/test_loop/31/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..71843dc Binary files /dev/null and b/test_loop/31/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/31/GlobalConnectivityMetrics/4.npy b/test_loop/31/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..17e205c Binary files /dev/null and b/test_loop/31/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/31/GlobalConnectivityMetrics/8.npy b/test_loop/31/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..9335d4a Binary files /dev/null and b/test_loop/31/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/31/KpostProcess/Kd16.npy b/test_loop/31/KpostProcess/Kd16.npy new file mode 100644 index 0000000..06afbb7 Binary files /dev/null and b/test_loop/31/KpostProcess/Kd16.npy differ diff --git a/test_loop/31/KpostProcess/Kd4.npy b/test_loop/31/KpostProcess/Kd4.npy new file mode 100644 index 0000000..fb1b5ce Binary files /dev/null and b/test_loop/31/KpostProcess/Kd4.npy differ diff --git a/test_loop/31/KpostProcess/Kd8.npy b/test_loop/31/KpostProcess/Kd8.npy new file mode 100644 index 0000000..255e227 Binary files /dev/null and b/test_loop/31/KpostProcess/Kd8.npy differ diff --git a/test_loop/31/KpostProcess/Kperm4.npy b/test_loop/31/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..7ca6467 Binary files /dev/null and b/test_loop/31/KpostProcess/Kperm4.npy differ diff --git a/test_loop/31/KpostProcess/Kperm8.npy b/test_loop/31/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..7ca6467 Binary files /dev/null and b/test_loop/31/KpostProcess/Kperm8.npy differ diff --git a/test_loop/31/KpostProcess/Kv16.npy b/test_loop/31/KpostProcess/Kv16.npy new file mode 100644 index 0000000..4b220cd Binary files /dev/null and b/test_loop/31/KpostProcess/Kv16.npy differ diff --git a/test_loop/31/KpostProcess/Kv4.npy b/test_loop/31/KpostProcess/Kv4.npy new file mode 100644 index 0000000..6115bee Binary files /dev/null and b/test_loop/31/KpostProcess/Kv4.npy differ diff --git a/test_loop/31/KpostProcess/Kv8.npy b/test_loop/31/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9ddc02a Binary files /dev/null and b/test_loop/31/KpostProcess/Kv8.npy differ diff --git a/test_loop/31/P.npy b/test_loop/31/P.npy new file mode 100644 index 0000000..665fb28 Binary files /dev/null and b/test_loop/31/P.npy differ diff --git a/test_loop/31/PosKeffSummary.txt b/test_loop/31/PosKeffSummary.txt new file mode 100644 index 0000000..f869d84 --- /dev/null +++ b/test_loop/31/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.606952453980115339e-02 +1.609059949150508373e-02 +4.322052001953125000e-03 +2.420013239187996379e-01 diff --git a/test_loop/31/RunTimes.out b/test_loop/31/RunTimes.out new file mode 100644 index 0000000..4bdf8d3 --- /dev/null +++ b/test_loop/31/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.293178081512 +Solver: 0.204036951065 +Keff: 0.016046798147627984 +N_cores: 1 diff --git a/test_loop/31/SolverRes.txt b/test_loop/31/SolverRes.txt new file mode 100644 index 0000000..a4ee838 --- /dev/null +++ b/test_loop/31/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.604679814762798376e-02 +2.000000000000000000e+00 +4.972150325775146484e-01 +1.000000000000000000e+00 diff --git a/test_loop/31/V.npy b/test_loop/31/V.npy new file mode 100644 index 0000000..7d0dd91 Binary files /dev/null and b/test_loop/31/V.npy differ diff --git a/test_loop/31/connec.out b/test_loop/31/connec.out new file mode 100644 index 0000000..7cce5a0 --- /dev/null +++ b/test_loop/31/connec.out @@ -0,0 +1,11 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.218750000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 + NCC : 7 diff --git a/test_loop/31/k.npy b/test_loop/31/k.npy new file mode 100644 index 0000000..8ff4c62 Binary files /dev/null and b/test_loop/31/k.npy differ diff --git a/test_loop/31/lc.txt b/test_loop/31/lc.txt new file mode 100644 index 0000000..d3ea509 --- /dev/null +++ b/test_loop/31/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.360540829547397834e+01 +9.883389154005863375e+00 +1.247488326455123531e+00 diff --git a/test_loop/31/tkperm_sub.txt b/test_loop/31/tkperm_sub.txt new file mode 100644 index 0000000..3862b82 --- /dev/null +++ b/test_loop/31/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.198709487915039062e-01 +1.599788665771484375e-04 diff --git a/test_loop/32/Cmap.npy b/test_loop/32/Cmap.npy new file mode 100644 index 0000000..549b540 Binary files /dev/null and b/test_loop/32/Cmap.npy differ diff --git a/test_loop/32/ConnSummary.txt b/test_loop/32/ConnSummary.txt new file mode 100644 index 0000000..1ba3162 --- /dev/null +++ b/test_loop/32/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.709588050842285156e-01 +7.824564853841535772e-01 +4.806435317119069767e-02 diff --git a/test_loop/32/ConnectivityMetrics/16.npy b/test_loop/32/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..cee51e7 Binary files /dev/null and b/test_loop/32/ConnectivityMetrics/16.npy differ diff --git a/test_loop/32/ConnectivityMetrics/4.npy b/test_loop/32/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..b210698 Binary files /dev/null and b/test_loop/32/ConnectivityMetrics/4.npy differ diff --git a/test_loop/32/ConnectivityMetrics/8.npy b/test_loop/32/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..456ff6a Binary files /dev/null and b/test_loop/32/ConnectivityMetrics/8.npy differ diff --git a/test_loop/32/D.npy b/test_loop/32/D.npy new file mode 100644 index 0000000..c054ef0 Binary files /dev/null and b/test_loop/32/D.npy differ diff --git a/test_loop/32/GenParams.txt b/test_loop/32/GenParams.txt new file mode 100644 index 0000000..c48e694 --- /dev/null +++ b/test_loop/32/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.386041641235351562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/32/GlobalConnectivityMetrics/16.npy b/test_loop/32/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..cee51e7 Binary files /dev/null and b/test_loop/32/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/32/GlobalConnectivityMetrics/4.npy b/test_loop/32/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..6bf0cf8 Binary files /dev/null and b/test_loop/32/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/32/GlobalConnectivityMetrics/8.npy b/test_loop/32/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..0933b8f Binary files /dev/null and b/test_loop/32/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/32/KpostProcess/Kd1.npy b/test_loop/32/KpostProcess/Kd1.npy new file mode 100644 index 0000000..2003fb7 Binary files /dev/null and b/test_loop/32/KpostProcess/Kd1.npy differ diff --git a/test_loop/32/KpostProcess/Kd16.npy b/test_loop/32/KpostProcess/Kd16.npy new file mode 100644 index 0000000..9e30927 Binary files /dev/null and b/test_loop/32/KpostProcess/Kd16.npy differ diff --git a/test_loop/32/KpostProcess/Kd2.npy b/test_loop/32/KpostProcess/Kd2.npy new file mode 100644 index 0000000..1fe2fa5 Binary files /dev/null and b/test_loop/32/KpostProcess/Kd2.npy differ diff --git a/test_loop/32/KpostProcess/Kd4.npy b/test_loop/32/KpostProcess/Kd4.npy new file mode 100644 index 0000000..6f8a312 Binary files /dev/null and b/test_loop/32/KpostProcess/Kd4.npy differ diff --git a/test_loop/32/KpostProcess/Kd8.npy b/test_loop/32/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2a17ae7 Binary files /dev/null and b/test_loop/32/KpostProcess/Kd8.npy differ diff --git a/test_loop/32/KpostProcess/Kperm2.npy b/test_loop/32/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..880a209 Binary files /dev/null and b/test_loop/32/KpostProcess/Kperm2.npy differ diff --git a/test_loop/32/KpostProcess/Kperm4.npy b/test_loop/32/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..880a209 Binary files /dev/null and b/test_loop/32/KpostProcess/Kperm4.npy differ diff --git a/test_loop/32/KpostProcess/Kperm8.npy b/test_loop/32/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..880a209 Binary files /dev/null and b/test_loop/32/KpostProcess/Kperm8.npy differ diff --git a/test_loop/32/KpostProcess/Kv1.npy b/test_loop/32/KpostProcess/Kv1.npy new file mode 100644 index 0000000..325b826 Binary files /dev/null and b/test_loop/32/KpostProcess/Kv1.npy differ diff --git a/test_loop/32/KpostProcess/Kv16.npy b/test_loop/32/KpostProcess/Kv16.npy new file mode 100644 index 0000000..c489f01 Binary files /dev/null and b/test_loop/32/KpostProcess/Kv16.npy differ diff --git a/test_loop/32/KpostProcess/Kv2.npy b/test_loop/32/KpostProcess/Kv2.npy new file mode 100644 index 0000000..d346770 Binary files /dev/null and b/test_loop/32/KpostProcess/Kv2.npy differ diff --git a/test_loop/32/KpostProcess/Kv4.npy b/test_loop/32/KpostProcess/Kv4.npy new file mode 100644 index 0000000..65f8d0a Binary files /dev/null and b/test_loop/32/KpostProcess/Kv4.npy differ diff --git a/test_loop/32/KpostProcess/Kv8.npy b/test_loop/32/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9c94152 Binary files /dev/null and b/test_loop/32/KpostProcess/Kv8.npy differ diff --git a/test_loop/32/P.npy b/test_loop/32/P.npy new file mode 100644 index 0000000..dfc0835 Binary files /dev/null and b/test_loop/32/P.npy differ diff --git a/test_loop/32/PosKeffSummary.txt b/test_loop/32/PosKeffSummary.txt new file mode 100644 index 0000000..cc82f4f --- /dev/null +++ b/test_loop/32/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.572214853115866395e-02 +1.573629663026363673e-02 +1.816599369049072266e-01 +6.808961895799783837e-03 diff --git a/test_loop/32/RunTimes.out b/test_loop/32/RunTimes.out new file mode 100644 index 0000000..293e325 --- /dev/null +++ b/test_loop/32/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.301299095154 +Solver: 0.219955921173 +Keff: 0.015733832915285885 +N_cores: 1 diff --git a/test_loop/32/SolverRes.txt b/test_loop/32/SolverRes.txt new file mode 100644 index 0000000..c893bcb --- /dev/null +++ b/test_loop/32/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.573383291528588496e-02 +2.000000000000000000e+00 +5.212550163269042969e-01 +1.000000000000000000e+00 diff --git a/test_loop/32/V.npy b/test_loop/32/V.npy new file mode 100644 index 0000000..c6f28f6 Binary files /dev/null and b/test_loop/32/V.npy differ diff --git a/test_loop/32/connec.out b/test_loop/32/connec.out new file mode 100644 index 0000000..3ae9123 --- /dev/null +++ b/test_loop/32/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.156250000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/32/k.npy b/test_loop/32/k.npy new file mode 100644 index 0000000..c329b36 Binary files /dev/null and b/test_loop/32/k.npy differ diff --git a/test_loop/32/lc.txt b/test_loop/32/lc.txt new file mode 100644 index 0000000..1180b70 --- /dev/null +++ b/test_loop/32/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.655024958130629997e+00 +3.655633087824805116e+00 +1.357474662419331901e+00 diff --git a/test_loop/32/tkperm_sub.txt b/test_loop/32/tkperm_sub.txt new file mode 100644 index 0000000..9c5906a --- /dev/null +++ b/test_loop/32/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.681248664855957031e-01 +2.200603485107421875e-04 +1.800060272216796875e-04 diff --git a/test_loop/33/Cmap.npy b/test_loop/33/Cmap.npy new file mode 100644 index 0000000..8479b01 Binary files /dev/null and b/test_loop/33/Cmap.npy differ diff --git a/test_loop/33/ConnSummary.txt b/test_loop/33/ConnSummary.txt new file mode 100644 index 0000000..b19c0fd --- /dev/null +++ b/test_loop/33/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.937560558319091797e-01 +8.240808744530926377e-01 +2.955098666658940651e-02 diff --git a/test_loop/33/ConnectivityMetrics/16.npy b/test_loop/33/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..e99f4aa Binary files /dev/null and b/test_loop/33/ConnectivityMetrics/16.npy differ diff --git a/test_loop/33/ConnectivityMetrics/4.npy b/test_loop/33/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..c10a79f Binary files /dev/null and b/test_loop/33/ConnectivityMetrics/4.npy differ diff --git a/test_loop/33/ConnectivityMetrics/8.npy b/test_loop/33/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..9374c73 Binary files /dev/null and b/test_loop/33/ConnectivityMetrics/8.npy differ diff --git a/test_loop/33/D.npy b/test_loop/33/D.npy new file mode 100644 index 0000000..03f3125 Binary files /dev/null and b/test_loop/33/D.npy differ diff --git a/test_loop/33/GenParams.txt b/test_loop/33/GenParams.txt new file mode 100644 index 0000000..623245b --- /dev/null +++ b/test_loop/33/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.172895431518554688e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/33/GlobalConnectivityMetrics/16.npy b/test_loop/33/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..e99f4aa Binary files /dev/null and b/test_loop/33/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/33/GlobalConnectivityMetrics/4.npy b/test_loop/33/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..62bdbdd Binary files /dev/null and b/test_loop/33/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/33/GlobalConnectivityMetrics/8.npy b/test_loop/33/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..1f144b3 Binary files /dev/null and b/test_loop/33/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/33/KpostProcess/Kd16.npy b/test_loop/33/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c5437d9 Binary files /dev/null and b/test_loop/33/KpostProcess/Kd16.npy differ diff --git a/test_loop/33/KpostProcess/Kd4.npy b/test_loop/33/KpostProcess/Kd4.npy new file mode 100644 index 0000000..90faa8b Binary files /dev/null and b/test_loop/33/KpostProcess/Kd4.npy differ diff --git a/test_loop/33/KpostProcess/Kd8.npy b/test_loop/33/KpostProcess/Kd8.npy new file mode 100644 index 0000000..f57fb7f Binary files /dev/null and b/test_loop/33/KpostProcess/Kd8.npy differ diff --git a/test_loop/33/KpostProcess/Kperm4.npy b/test_loop/33/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9be8433 Binary files /dev/null and b/test_loop/33/KpostProcess/Kperm4.npy differ diff --git a/test_loop/33/KpostProcess/Kperm8.npy b/test_loop/33/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9be8433 Binary files /dev/null and b/test_loop/33/KpostProcess/Kperm8.npy differ diff --git a/test_loop/33/KpostProcess/Kv16.npy b/test_loop/33/KpostProcess/Kv16.npy new file mode 100644 index 0000000..98872a0 Binary files /dev/null and b/test_loop/33/KpostProcess/Kv16.npy differ diff --git a/test_loop/33/KpostProcess/Kv4.npy b/test_loop/33/KpostProcess/Kv4.npy new file mode 100644 index 0000000..da83c74 Binary files /dev/null and b/test_loop/33/KpostProcess/Kv4.npy differ diff --git a/test_loop/33/KpostProcess/Kv8.npy b/test_loop/33/KpostProcess/Kv8.npy new file mode 100644 index 0000000..464376f Binary files /dev/null and b/test_loop/33/KpostProcess/Kv8.npy differ diff --git a/test_loop/33/P.npy b/test_loop/33/P.npy new file mode 100644 index 0000000..7226a2e Binary files /dev/null and b/test_loop/33/P.npy differ diff --git a/test_loop/33/PosKeffSummary.txt b/test_loop/33/PosKeffSummary.txt new file mode 100644 index 0000000..5a70f8f --- /dev/null +++ b/test_loop/33/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.907247494312485150e-02 +1.917288384562248690e-02 +4.393100738525390625e-03 +2.376533159665689676e-01 diff --git a/test_loop/33/RunTimes.out b/test_loop/33/RunTimes.out new file mode 100644 index 0000000..0f33dbd --- /dev/null +++ b/test_loop/33/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.301681995392 +Solver: 0.265547037125 +Keff: 0.019142214361650554 +N_cores: 1 diff --git a/test_loop/33/SolverRes.txt b/test_loop/33/SolverRes.txt new file mode 100644 index 0000000..12d4fe3 --- /dev/null +++ b/test_loop/33/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.914221436165055440e-02 +2.000000000000000000e+00 +5.672290325164794922e-01 +1.000000000000000000e+00 diff --git a/test_loop/33/V.npy b/test_loop/33/V.npy new file mode 100644 index 0000000..0042574 Binary files /dev/null and b/test_loop/33/V.npy differ diff --git a/test_loop/33/connec.out b/test_loop/33/connec.out new file mode 100644 index 0000000..603cca0 --- /dev/null +++ b/test_loop/33/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.265625000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/33/k.npy b/test_loop/33/k.npy new file mode 100644 index 0000000..bac5ccf Binary files /dev/null and b/test_loop/33/k.npy differ diff --git a/test_loop/33/lc.txt b/test_loop/33/lc.txt new file mode 100644 index 0000000..c0e7446 --- /dev/null +++ b/test_loop/33/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.381456691940186232e+01 +9.431467448581878799e+00 +1.359457288659324359e+00 diff --git a/test_loop/33/tkperm_sub.txt b/test_loop/33/tkperm_sub.txt new file mode 100644 index 0000000..33cc699 --- /dev/null +++ b/test_loop/33/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.161959648132324219e-01 +1.618862152099609375e-04 diff --git a/test_loop/34/Cmap.npy b/test_loop/34/Cmap.npy new file mode 100644 index 0000000..029d26f Binary files /dev/null and b/test_loop/34/Cmap.npy differ diff --git a/test_loop/34/ConnSummary.txt b/test_loop/34/ConnSummary.txt new file mode 100644 index 0000000..c7ba36d --- /dev/null +++ b/test_loop/34/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.990630149841308594e-01 +7.896138106708222582e-01 +5.143649359695245254e-02 diff --git a/test_loop/34/ConnectivityMetrics/16.npy b/test_loop/34/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..ad8b27a Binary files /dev/null and b/test_loop/34/ConnectivityMetrics/16.npy differ diff --git a/test_loop/34/ConnectivityMetrics/4.npy b/test_loop/34/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..cd1cbdf Binary files /dev/null and b/test_loop/34/ConnectivityMetrics/4.npy differ diff --git a/test_loop/34/ConnectivityMetrics/8.npy b/test_loop/34/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..37947f3 Binary files /dev/null and b/test_loop/34/ConnectivityMetrics/8.npy differ diff --git a/test_loop/34/D.npy b/test_loop/34/D.npy new file mode 100644 index 0000000..da50ac9 Binary files /dev/null and b/test_loop/34/D.npy differ diff --git a/test_loop/34/GenParams.txt b/test_loop/34/GenParams.txt new file mode 100644 index 0000000..8ebcd51 --- /dev/null +++ b/test_loop/34/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.017923355102539062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/34/GlobalConnectivityMetrics/16.npy b/test_loop/34/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..ad8b27a Binary files /dev/null and b/test_loop/34/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/34/GlobalConnectivityMetrics/4.npy b/test_loop/34/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..4ee3ba5 Binary files /dev/null and b/test_loop/34/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/34/GlobalConnectivityMetrics/8.npy b/test_loop/34/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..80cdf32 Binary files /dev/null and b/test_loop/34/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/34/KpostProcess/Kd1.npy b/test_loop/34/KpostProcess/Kd1.npy new file mode 100644 index 0000000..d5fa157 Binary files /dev/null and b/test_loop/34/KpostProcess/Kd1.npy differ diff --git a/test_loop/34/KpostProcess/Kd16.npy b/test_loop/34/KpostProcess/Kd16.npy new file mode 100644 index 0000000..940e88c Binary files /dev/null and b/test_loop/34/KpostProcess/Kd16.npy differ diff --git a/test_loop/34/KpostProcess/Kd2.npy b/test_loop/34/KpostProcess/Kd2.npy new file mode 100644 index 0000000..cb603fa Binary files /dev/null and b/test_loop/34/KpostProcess/Kd2.npy differ diff --git a/test_loop/34/KpostProcess/Kd4.npy b/test_loop/34/KpostProcess/Kd4.npy new file mode 100644 index 0000000..29b0291 Binary files /dev/null and b/test_loop/34/KpostProcess/Kd4.npy differ diff --git a/test_loop/34/KpostProcess/Kd8.npy b/test_loop/34/KpostProcess/Kd8.npy new file mode 100644 index 0000000..00f6299 Binary files /dev/null and b/test_loop/34/KpostProcess/Kd8.npy differ diff --git a/test_loop/34/KpostProcess/Kperm2.npy b/test_loop/34/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..b7ef8d1 Binary files /dev/null and b/test_loop/34/KpostProcess/Kperm2.npy differ diff --git a/test_loop/34/KpostProcess/Kperm4.npy b/test_loop/34/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..b7ef8d1 Binary files /dev/null and b/test_loop/34/KpostProcess/Kperm4.npy differ diff --git a/test_loop/34/KpostProcess/Kperm8.npy b/test_loop/34/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..b7ef8d1 Binary files /dev/null and b/test_loop/34/KpostProcess/Kperm8.npy differ diff --git a/test_loop/34/KpostProcess/Kv1.npy b/test_loop/34/KpostProcess/Kv1.npy new file mode 100644 index 0000000..b4e46e0 Binary files /dev/null and b/test_loop/34/KpostProcess/Kv1.npy differ diff --git a/test_loop/34/KpostProcess/Kv16.npy b/test_loop/34/KpostProcess/Kv16.npy new file mode 100644 index 0000000..5d568e6 Binary files /dev/null and b/test_loop/34/KpostProcess/Kv16.npy differ diff --git a/test_loop/34/KpostProcess/Kv2.npy b/test_loop/34/KpostProcess/Kv2.npy new file mode 100644 index 0000000..eec3594 Binary files /dev/null and b/test_loop/34/KpostProcess/Kv2.npy differ diff --git a/test_loop/34/KpostProcess/Kv4.npy b/test_loop/34/KpostProcess/Kv4.npy new file mode 100644 index 0000000..f7e17e6 Binary files /dev/null and b/test_loop/34/KpostProcess/Kv4.npy differ diff --git a/test_loop/34/KpostProcess/Kv8.npy b/test_loop/34/KpostProcess/Kv8.npy new file mode 100644 index 0000000..4fe6239 Binary files /dev/null and b/test_loop/34/KpostProcess/Kv8.npy differ diff --git a/test_loop/34/P.npy b/test_loop/34/P.npy new file mode 100644 index 0000000..550f502 Binary files /dev/null and b/test_loop/34/P.npy differ diff --git a/test_loop/34/PosKeffSummary.txt b/test_loop/34/PosKeffSummary.txt new file mode 100644 index 0000000..438b2bd --- /dev/null +++ b/test_loop/34/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.762234522407476675e-02 +1.766229816574675995e-02 +2.323110103607177734e-01 +5.182766940720435686e-03 diff --git a/test_loop/34/RunTimes.out b/test_loop/34/RunTimes.out new file mode 100644 index 0000000..9b96b49 --- /dev/null +++ b/test_loop/34/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.293883085251 +Solver: 0.2262570858 +Keff: 0.017641722705048286 +N_cores: 1 diff --git a/test_loop/34/SolverRes.txt b/test_loop/34/SolverRes.txt new file mode 100644 index 0000000..b21103a --- /dev/null +++ b/test_loop/34/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.764172270504828569e-02 +2.000000000000000000e+00 +5.201401710510253906e-01 +1.000000000000000000e+00 diff --git a/test_loop/34/V.npy b/test_loop/34/V.npy new file mode 100644 index 0000000..30319bc Binary files /dev/null and b/test_loop/34/V.npy differ diff --git a/test_loop/34/connec.out b/test_loop/34/connec.out new file mode 100644 index 0000000..e611c06 --- /dev/null +++ b/test_loop/34/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.171875000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/34/k.npy b/test_loop/34/k.npy new file mode 100644 index 0000000..493a6b9 Binary files /dev/null and b/test_loop/34/k.npy differ diff --git a/test_loop/34/lc.txt b/test_loop/34/lc.txt new file mode 100644 index 0000000..5fb902b --- /dev/null +++ b/test_loop/34/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.678650207123230764e+00 +3.677825126993925053e+00 +1.433528281623152711e+00 diff --git a/test_loop/34/tkperm_sub.txt b/test_loop/34/tkperm_sub.txt new file mode 100644 index 0000000..ce0aed6 --- /dev/null +++ b/test_loop/34/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.706929683685302734e-01 +1.618862152099609375e-04 +1.249313354492187500e-04 diff --git a/test_loop/35/Cmap.npy b/test_loop/35/Cmap.npy new file mode 100644 index 0000000..f230dd9 Binary files /dev/null and b/test_loop/35/Cmap.npy differ diff --git a/test_loop/35/ConnSummary.txt b/test_loop/35/ConnSummary.txt new file mode 100644 index 0000000..9749e22 --- /dev/null +++ b/test_loop/35/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.659219741821289062e-01 +7.643648503897606528e-01 +5.420097107874181919e-02 diff --git a/test_loop/35/ConnectivityMetrics/16.npy b/test_loop/35/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..80e04bb Binary files /dev/null and b/test_loop/35/ConnectivityMetrics/16.npy differ diff --git a/test_loop/35/ConnectivityMetrics/4.npy b/test_loop/35/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..eb527e9 Binary files /dev/null and b/test_loop/35/ConnectivityMetrics/4.npy differ diff --git a/test_loop/35/ConnectivityMetrics/8.npy b/test_loop/35/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..406d1a6 Binary files /dev/null and b/test_loop/35/ConnectivityMetrics/8.npy differ diff --git a/test_loop/35/D.npy b/test_loop/35/D.npy new file mode 100644 index 0000000..f9a6bd9 Binary files /dev/null and b/test_loop/35/D.npy differ diff --git a/test_loop/35/GenParams.txt b/test_loop/35/GenParams.txt new file mode 100644 index 0000000..528c93b --- /dev/null +++ b/test_loop/35/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.893945693969726562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/35/GlobalConnectivityMetrics/16.npy b/test_loop/35/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..80e04bb Binary files /dev/null and b/test_loop/35/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/35/GlobalConnectivityMetrics/4.npy b/test_loop/35/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..fad2c6b Binary files /dev/null and b/test_loop/35/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/35/GlobalConnectivityMetrics/8.npy b/test_loop/35/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..83e5869 Binary files /dev/null and b/test_loop/35/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/35/KpostProcess/Kd16.npy b/test_loop/35/KpostProcess/Kd16.npy new file mode 100644 index 0000000..e6777f0 Binary files /dev/null and b/test_loop/35/KpostProcess/Kd16.npy differ diff --git a/test_loop/35/KpostProcess/Kd4.npy b/test_loop/35/KpostProcess/Kd4.npy new file mode 100644 index 0000000..4ccdb58 Binary files /dev/null and b/test_loop/35/KpostProcess/Kd4.npy differ diff --git a/test_loop/35/KpostProcess/Kd8.npy b/test_loop/35/KpostProcess/Kd8.npy new file mode 100644 index 0000000..65be19e Binary files /dev/null and b/test_loop/35/KpostProcess/Kd8.npy differ diff --git a/test_loop/35/KpostProcess/Kperm4.npy b/test_loop/35/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..b39c828 Binary files /dev/null and b/test_loop/35/KpostProcess/Kperm4.npy differ diff --git a/test_loop/35/KpostProcess/Kperm8.npy b/test_loop/35/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..b39c828 Binary files /dev/null and b/test_loop/35/KpostProcess/Kperm8.npy differ diff --git a/test_loop/35/KpostProcess/Kv16.npy b/test_loop/35/KpostProcess/Kv16.npy new file mode 100644 index 0000000..f3c67e0 Binary files /dev/null and b/test_loop/35/KpostProcess/Kv16.npy differ diff --git a/test_loop/35/KpostProcess/Kv4.npy b/test_loop/35/KpostProcess/Kv4.npy new file mode 100644 index 0000000..35a8f29 Binary files /dev/null and b/test_loop/35/KpostProcess/Kv4.npy differ diff --git a/test_loop/35/KpostProcess/Kv8.npy b/test_loop/35/KpostProcess/Kv8.npy new file mode 100644 index 0000000..d045831 Binary files /dev/null and b/test_loop/35/KpostProcess/Kv8.npy differ diff --git a/test_loop/35/P.npy b/test_loop/35/P.npy new file mode 100644 index 0000000..0a654a6 Binary files /dev/null and b/test_loop/35/P.npy differ diff --git a/test_loop/35/PosKeffSummary.txt b/test_loop/35/PosKeffSummary.txt new file mode 100644 index 0000000..a3ef839 --- /dev/null +++ b/test_loop/35/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.475199326102178049e-02 +2.497648860926790504e-02 +2.752685546875000000e-02 +4.347370426829268442e-01 diff --git a/test_loop/35/RunTimes.out b/test_loop/35/RunTimes.out new file mode 100644 index 0000000..5fc08c1 --- /dev/null +++ b/test_loop/35/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.311148166656 +Solver: 0.280251979828 +Keff: 0.025005376191717766 +N_cores: 1 diff --git a/test_loop/35/SolverRes.txt b/test_loop/35/SolverRes.txt new file mode 100644 index 0000000..1039f94 --- /dev/null +++ b/test_loop/35/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.500537619171776596e-02 +2.000000000000000000e+00 +5.914001464843750000e-01 +1.000000000000000000e+00 diff --git a/test_loop/35/V.npy b/test_loop/35/V.npy new file mode 100644 index 0000000..3338427 Binary files /dev/null and b/test_loop/35/V.npy differ diff --git a/test_loop/35/connec.out b/test_loop/35/connec.out new file mode 100644 index 0000000..9fa6221 --- /dev/null +++ b/test_loop/35/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.296875000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/35/k.npy b/test_loop/35/k.npy new file mode 100644 index 0000000..7ff9887 Binary files /dev/null and b/test_loop/35/k.npy differ diff --git a/test_loop/35/lc.txt b/test_loop/35/lc.txt new file mode 100644 index 0000000..27714cd --- /dev/null +++ b/test_loop/35/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.399773950371937303e+01 +9.502260981460807443e+00 +1.446159468177543150e+00 diff --git a/test_loop/35/tkperm_sub.txt b/test_loop/35/tkperm_sub.txt new file mode 100644 index 0000000..a37f3bf --- /dev/null +++ b/test_loop/35/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.152500629425048828e-01 +2.081394195556640625e-04 diff --git a/test_loop/36/Cmap.npy b/test_loop/36/Cmap.npy new file mode 100644 index 0000000..ed93d65 Binary files /dev/null and b/test_loop/36/Cmap.npy differ diff --git a/test_loop/36/ConnSummary.txt b/test_loop/36/ConnSummary.txt new file mode 100644 index 0000000..ed7d8f3 --- /dev/null +++ b/test_loop/36/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.855450630187988281e-01 +7.709704660592177072e-01 +5.114346604211642694e-02 diff --git a/test_loop/36/ConnectivityMetrics/16.npy b/test_loop/36/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..0e9e750 Binary files /dev/null and b/test_loop/36/ConnectivityMetrics/16.npy differ diff --git a/test_loop/36/ConnectivityMetrics/4.npy b/test_loop/36/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1f73488 Binary files /dev/null and b/test_loop/36/ConnectivityMetrics/4.npy differ diff --git a/test_loop/36/ConnectivityMetrics/8.npy b/test_loop/36/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e22c72e Binary files /dev/null and b/test_loop/36/ConnectivityMetrics/8.npy differ diff --git a/test_loop/36/D.npy b/test_loop/36/D.npy new file mode 100644 index 0000000..a99a19e Binary files /dev/null and b/test_loop/36/D.npy differ diff --git a/test_loop/36/GenParams.txt b/test_loop/36/GenParams.txt new file mode 100644 index 0000000..3921ed4 --- /dev/null +++ b/test_loop/36/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.032943725585937500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/36/GlobalConnectivityMetrics/16.npy b/test_loop/36/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..0e9e750 Binary files /dev/null and b/test_loop/36/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/36/GlobalConnectivityMetrics/4.npy b/test_loop/36/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..786acc4 Binary files /dev/null and b/test_loop/36/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/36/GlobalConnectivityMetrics/8.npy b/test_loop/36/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..d6ef5fe Binary files /dev/null and b/test_loop/36/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/36/KpostProcess/Kd1.npy b/test_loop/36/KpostProcess/Kd1.npy new file mode 100644 index 0000000..ad4c48e Binary files /dev/null and b/test_loop/36/KpostProcess/Kd1.npy differ diff --git a/test_loop/36/KpostProcess/Kd16.npy b/test_loop/36/KpostProcess/Kd16.npy new file mode 100644 index 0000000..bc977fc Binary files /dev/null and b/test_loop/36/KpostProcess/Kd16.npy differ diff --git a/test_loop/36/KpostProcess/Kd2.npy b/test_loop/36/KpostProcess/Kd2.npy new file mode 100644 index 0000000..51b15b6 Binary files /dev/null and b/test_loop/36/KpostProcess/Kd2.npy differ diff --git a/test_loop/36/KpostProcess/Kd4.npy b/test_loop/36/KpostProcess/Kd4.npy new file mode 100644 index 0000000..43ccc38 Binary files /dev/null and b/test_loop/36/KpostProcess/Kd4.npy differ diff --git a/test_loop/36/KpostProcess/Kd8.npy b/test_loop/36/KpostProcess/Kd8.npy new file mode 100644 index 0000000..5fc4fbb Binary files /dev/null and b/test_loop/36/KpostProcess/Kd8.npy differ diff --git a/test_loop/36/KpostProcess/Kperm2.npy b/test_loop/36/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..e17264f Binary files /dev/null and b/test_loop/36/KpostProcess/Kperm2.npy differ diff --git a/test_loop/36/KpostProcess/Kperm4.npy b/test_loop/36/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e17264f Binary files /dev/null and b/test_loop/36/KpostProcess/Kperm4.npy differ diff --git a/test_loop/36/KpostProcess/Kperm8.npy b/test_loop/36/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e17264f Binary files /dev/null and b/test_loop/36/KpostProcess/Kperm8.npy differ diff --git a/test_loop/36/KpostProcess/Kv1.npy b/test_loop/36/KpostProcess/Kv1.npy new file mode 100644 index 0000000..9775656 Binary files /dev/null and b/test_loop/36/KpostProcess/Kv1.npy differ diff --git a/test_loop/36/KpostProcess/Kv16.npy b/test_loop/36/KpostProcess/Kv16.npy new file mode 100644 index 0000000..5f3f823 Binary files /dev/null and b/test_loop/36/KpostProcess/Kv16.npy differ diff --git a/test_loop/36/KpostProcess/Kv2.npy b/test_loop/36/KpostProcess/Kv2.npy new file mode 100644 index 0000000..93791bb Binary files /dev/null and b/test_loop/36/KpostProcess/Kv2.npy differ diff --git a/test_loop/36/KpostProcess/Kv4.npy b/test_loop/36/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0c9a6c1 Binary files /dev/null and b/test_loop/36/KpostProcess/Kv4.npy differ diff --git a/test_loop/36/KpostProcess/Kv8.npy b/test_loop/36/KpostProcess/Kv8.npy new file mode 100644 index 0000000..2bf990e Binary files /dev/null and b/test_loop/36/KpostProcess/Kv8.npy differ diff --git a/test_loop/36/P.npy b/test_loop/36/P.npy new file mode 100644 index 0000000..c1b534d Binary files /dev/null and b/test_loop/36/P.npy differ diff --git a/test_loop/36/PosKeffSummary.txt b/test_loop/36/PosKeffSummary.txt new file mode 100644 index 0000000..9b9ed0e --- /dev/null +++ b/test_loop/36/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.826061588700853194e-02 +2.905670657113251440e-02 +1.804909706115722656e-01 +5.828007724884219122e-03 diff --git a/test_loop/36/RunTimes.out b/test_loop/36/RunTimes.out new file mode 100644 index 0000000..d4f6d6f --- /dev/null +++ b/test_loop/36/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.302750825882 +Solver: 0.2837870121 +Keff: 0.029037759235579684 +N_cores: 1 diff --git a/test_loop/36/SolverRes.txt b/test_loop/36/SolverRes.txt new file mode 100644 index 0000000..0277ebf --- /dev/null +++ b/test_loop/36/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.903775923557968403e-02 +2.000000000000000000e+00 +5.865378379821777344e-01 +1.000000000000000000e+00 diff --git a/test_loop/36/V.npy b/test_loop/36/V.npy new file mode 100644 index 0000000..383989a Binary files /dev/null and b/test_loop/36/V.npy differ diff --git a/test_loop/36/connec.out b/test_loop/36/connec.out new file mode 100644 index 0000000..d0db918 --- /dev/null +++ b/test_loop/36/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.187500000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/36/k.npy b/test_loop/36/k.npy new file mode 100644 index 0000000..acac4bb Binary files /dev/null and b/test_loop/36/k.npy differ diff --git a/test_loop/36/lc.txt b/test_loop/36/lc.txt new file mode 100644 index 0000000..54e159a --- /dev/null +++ b/test_loop/36/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.699291118701554915e+00 +3.658395506771861871e+00 +1.593606144104852795e+00 diff --git a/test_loop/36/tkperm_sub.txt b/test_loop/36/tkperm_sub.txt new file mode 100644 index 0000000..8b9edd5 --- /dev/null +++ b/test_loop/36/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.902111053466796875e-01 +1.640319824218750000e-04 +1.261234283447265625e-04 diff --git a/test_loop/37/Cmap.npy b/test_loop/37/Cmap.npy new file mode 100644 index 0000000..a42530f Binary files /dev/null and b/test_loop/37/Cmap.npy differ diff --git a/test_loop/37/ConnSummary.txt b/test_loop/37/ConnSummary.txt new file mode 100644 index 0000000..d9ccccc --- /dev/null +++ b/test_loop/37/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.841669559478759766e-01 +7.996627595011025491e-01 +4.636219033794179017e-02 diff --git a/test_loop/37/ConnectivityMetrics/16.npy b/test_loop/37/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..9be2adb Binary files /dev/null and b/test_loop/37/ConnectivityMetrics/16.npy differ diff --git a/test_loop/37/ConnectivityMetrics/4.npy b/test_loop/37/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..f1b20df Binary files /dev/null and b/test_loop/37/ConnectivityMetrics/4.npy differ diff --git a/test_loop/37/ConnectivityMetrics/8.npy b/test_loop/37/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..d7b5b60 Binary files /dev/null and b/test_loop/37/ConnectivityMetrics/8.npy differ diff --git a/test_loop/37/D.npy b/test_loop/37/D.npy new file mode 100644 index 0000000..99a5b10 Binary files /dev/null and b/test_loop/37/D.npy differ diff --git a/test_loop/37/GenParams.txt b/test_loop/37/GenParams.txt new file mode 100644 index 0000000..e6c2b57 --- /dev/null +++ b/test_loop/37/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +8.329868316650390625e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/37/GlobalConnectivityMetrics/16.npy b/test_loop/37/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..9be2adb Binary files /dev/null and b/test_loop/37/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/37/GlobalConnectivityMetrics/4.npy b/test_loop/37/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..3315e4c Binary files /dev/null and b/test_loop/37/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/37/GlobalConnectivityMetrics/8.npy b/test_loop/37/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..0a36e53 Binary files /dev/null and b/test_loop/37/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/37/KpostProcess/Kd16.npy b/test_loop/37/KpostProcess/Kd16.npy new file mode 100644 index 0000000..d155cd7 Binary files /dev/null and b/test_loop/37/KpostProcess/Kd16.npy differ diff --git a/test_loop/37/KpostProcess/Kd4.npy b/test_loop/37/KpostProcess/Kd4.npy new file mode 100644 index 0000000..8757ced Binary files /dev/null and b/test_loop/37/KpostProcess/Kd4.npy differ diff --git a/test_loop/37/KpostProcess/Kd8.npy b/test_loop/37/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2bef9e4 Binary files /dev/null and b/test_loop/37/KpostProcess/Kd8.npy differ diff --git a/test_loop/37/KpostProcess/Kperm4.npy b/test_loop/37/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..809f366 Binary files /dev/null and b/test_loop/37/KpostProcess/Kperm4.npy differ diff --git a/test_loop/37/KpostProcess/Kperm8.npy b/test_loop/37/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..809f366 Binary files /dev/null and b/test_loop/37/KpostProcess/Kperm8.npy differ diff --git a/test_loop/37/KpostProcess/Kv16.npy b/test_loop/37/KpostProcess/Kv16.npy new file mode 100644 index 0000000..1bb2187 Binary files /dev/null and b/test_loop/37/KpostProcess/Kv16.npy differ diff --git a/test_loop/37/KpostProcess/Kv4.npy b/test_loop/37/KpostProcess/Kv4.npy new file mode 100644 index 0000000..a6b9d69 Binary files /dev/null and b/test_loop/37/KpostProcess/Kv4.npy differ diff --git a/test_loop/37/KpostProcess/Kv8.npy b/test_loop/37/KpostProcess/Kv8.npy new file mode 100644 index 0000000..448104e Binary files /dev/null and b/test_loop/37/KpostProcess/Kv8.npy differ diff --git a/test_loop/37/P.npy b/test_loop/37/P.npy new file mode 100644 index 0000000..efde5f7 Binary files /dev/null and b/test_loop/37/P.npy differ diff --git a/test_loop/37/PosKeffSummary.txt b/test_loop/37/PosKeffSummary.txt new file mode 100644 index 0000000..c8ad4f4 --- /dev/null +++ b/test_loop/37/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.980400056664002983e-01 +3.999099468681396319e-01 +4.374027252197265625e-03 +2.398342963043715304e-01 diff --git a/test_loop/37/RunTimes.out b/test_loop/37/RunTimes.out new file mode 100644 index 0000000..d29d4b4 --- /dev/null +++ b/test_loop/37/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.290327072144 +Solver: 0.425755977631 +Keff: 0.39985371564689903 +N_cores: 1 diff --git a/test_loop/37/SolverRes.txt b/test_loop/37/SolverRes.txt new file mode 100644 index 0000000..c1c0a01 --- /dev/null +++ b/test_loop/37/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.998537156468990328e-01 +2.000000000000000000e+00 +7.160830497741699219e-01 +1.000000000000000000e+00 diff --git a/test_loop/37/V.npy b/test_loop/37/V.npy new file mode 100644 index 0000000..aef07e1 Binary files /dev/null and b/test_loop/37/V.npy differ diff --git a/test_loop/37/connec.out b/test_loop/37/connec.out new file mode 100644 index 0000000..94419c2 --- /dev/null +++ b/test_loop/37/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.312500000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/37/k.npy b/test_loop/37/k.npy new file mode 100644 index 0000000..3cc07a2 Binary files /dev/null and b/test_loop/37/k.npy differ diff --git a/test_loop/37/lc.txt b/test_loop/37/lc.txt new file mode 100644 index 0000000..fc56b15 --- /dev/null +++ b/test_loop/37/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.415678302322890048e+01 +9.621193182666280208e+00 +1.683279998120695620e+00 diff --git a/test_loop/37/tkperm_sub.txt b/test_loop/37/tkperm_sub.txt new file mode 100644 index 0000000..f11c391 --- /dev/null +++ b/test_loop/37/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.116078376770019531e-01 +1.590251922607421875e-04 diff --git a/test_loop/38/Cmap.npy b/test_loop/38/Cmap.npy new file mode 100644 index 0000000..bdd78b0 Binary files /dev/null and b/test_loop/38/Cmap.npy differ diff --git a/test_loop/38/ConnSummary.txt b/test_loop/38/ConnSummary.txt new file mode 100644 index 0000000..c0ee5d1 --- /dev/null +++ b/test_loop/38/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.713150024414062500e-01 +7.610221598964432843e-01 +5.126659167026238750e-02 diff --git a/test_loop/38/ConnectivityMetrics/16.npy b/test_loop/38/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..bb6f8ff Binary files /dev/null and b/test_loop/38/ConnectivityMetrics/16.npy differ diff --git a/test_loop/38/ConnectivityMetrics/4.npy b/test_loop/38/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..7749319 Binary files /dev/null and b/test_loop/38/ConnectivityMetrics/4.npy differ diff --git a/test_loop/38/ConnectivityMetrics/8.npy b/test_loop/38/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b32e081 Binary files /dev/null and b/test_loop/38/ConnectivityMetrics/8.npy differ diff --git a/test_loop/38/D.npy b/test_loop/38/D.npy new file mode 100644 index 0000000..ef45507 Binary files /dev/null and b/test_loop/38/D.npy differ diff --git a/test_loop/38/GenParams.txt b/test_loop/38/GenParams.txt new file mode 100644 index 0000000..ccbdabb --- /dev/null +++ b/test_loop/38/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +7.488012313842773438e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/38/GlobalConnectivityMetrics/16.npy b/test_loop/38/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..bb6f8ff Binary files /dev/null and b/test_loop/38/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/38/GlobalConnectivityMetrics/4.npy b/test_loop/38/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..aeaf2cb Binary files /dev/null and b/test_loop/38/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/38/GlobalConnectivityMetrics/8.npy b/test_loop/38/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..47d535b Binary files /dev/null and b/test_loop/38/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/38/KpostProcess/Kd1.npy b/test_loop/38/KpostProcess/Kd1.npy new file mode 100644 index 0000000..59428e6 Binary files /dev/null and b/test_loop/38/KpostProcess/Kd1.npy differ diff --git a/test_loop/38/KpostProcess/Kd16.npy b/test_loop/38/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f521e73 Binary files /dev/null and b/test_loop/38/KpostProcess/Kd16.npy differ diff --git a/test_loop/38/KpostProcess/Kd2.npy b/test_loop/38/KpostProcess/Kd2.npy new file mode 100644 index 0000000..0fab3c6 Binary files /dev/null and b/test_loop/38/KpostProcess/Kd2.npy differ diff --git a/test_loop/38/KpostProcess/Kd4.npy b/test_loop/38/KpostProcess/Kd4.npy new file mode 100644 index 0000000..26315f7 Binary files /dev/null and b/test_loop/38/KpostProcess/Kd4.npy differ diff --git a/test_loop/38/KpostProcess/Kd8.npy b/test_loop/38/KpostProcess/Kd8.npy new file mode 100644 index 0000000..04a0e92 Binary files /dev/null and b/test_loop/38/KpostProcess/Kd8.npy differ diff --git a/test_loop/38/KpostProcess/Kperm2.npy b/test_loop/38/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..66b80cf Binary files /dev/null and b/test_loop/38/KpostProcess/Kperm2.npy differ diff --git a/test_loop/38/KpostProcess/Kperm4.npy b/test_loop/38/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..66b80cf Binary files /dev/null and b/test_loop/38/KpostProcess/Kperm4.npy differ diff --git a/test_loop/38/KpostProcess/Kperm8.npy b/test_loop/38/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..66b80cf Binary files /dev/null and b/test_loop/38/KpostProcess/Kperm8.npy differ diff --git a/test_loop/38/KpostProcess/Kv1.npy b/test_loop/38/KpostProcess/Kv1.npy new file mode 100644 index 0000000..f28ec7f Binary files /dev/null and b/test_loop/38/KpostProcess/Kv1.npy differ diff --git a/test_loop/38/KpostProcess/Kv16.npy b/test_loop/38/KpostProcess/Kv16.npy new file mode 100644 index 0000000..93a57df Binary files /dev/null and b/test_loop/38/KpostProcess/Kv16.npy differ diff --git a/test_loop/38/KpostProcess/Kv2.npy b/test_loop/38/KpostProcess/Kv2.npy new file mode 100644 index 0000000..ed930b0 Binary files /dev/null and b/test_loop/38/KpostProcess/Kv2.npy differ diff --git a/test_loop/38/KpostProcess/Kv4.npy b/test_loop/38/KpostProcess/Kv4.npy new file mode 100644 index 0000000..35378ab Binary files /dev/null and b/test_loop/38/KpostProcess/Kv4.npy differ diff --git a/test_loop/38/KpostProcess/Kv8.npy b/test_loop/38/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9a810e8 Binary files /dev/null and b/test_loop/38/KpostProcess/Kv8.npy differ diff --git a/test_loop/38/P.npy b/test_loop/38/P.npy new file mode 100644 index 0000000..dce70bd Binary files /dev/null and b/test_loop/38/P.npy differ diff --git a/test_loop/38/PosKeffSummary.txt b/test_loop/38/PosKeffSummary.txt new file mode 100644 index 0000000..87827d8 --- /dev/null +++ b/test_loop/38/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.224975848613904905e-02 +3.306383440022278575e-02 +2.584679126739501953e-01 +4.692401851132697865e-03 diff --git a/test_loop/38/RunTimes.out b/test_loop/38/RunTimes.out new file mode 100644 index 0000000..cf1a92d --- /dev/null +++ b/test_loop/38/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.301755905151 +Solver: 0.350469112396 +Keff: 0.03306673954095279 +N_cores: 1 diff --git a/test_loop/38/SolverRes.txt b/test_loop/38/SolverRes.txt new file mode 100644 index 0000000..83c0db3 --- /dev/null +++ b/test_loop/38/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.306673954095278728e-02 +2.000000000000000000e+00 +6.522250175476074219e-01 +1.000000000000000000e+00 diff --git a/test_loop/38/V.npy b/test_loop/38/V.npy new file mode 100644 index 0000000..6e7cab7 Binary files /dev/null and b/test_loop/38/V.npy differ diff --git a/test_loop/38/connec.out b/test_loop/38/connec.out new file mode 100644 index 0000000..e87bd8d --- /dev/null +++ b/test_loop/38/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.218750000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/38/k.npy b/test_loop/38/k.npy new file mode 100644 index 0000000..1c50a0b Binary files /dev/null and b/test_loop/38/k.npy differ diff --git a/test_loop/38/lc.txt b/test_loop/38/lc.txt new file mode 100644 index 0000000..a6c7172 --- /dev/null +++ b/test_loop/38/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.718589079395384189e+00 +3.666235952474473425e+00 +1.779642350865391798e+00 diff --git a/test_loop/38/tkperm_sub.txt b/test_loop/38/tkperm_sub.txt new file mode 100644 index 0000000..b09adc5 --- /dev/null +++ b/test_loop/38/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.841249942779541016e-01 +2.098083496093750000e-04 +1.668930053710937500e-04 diff --git a/test_loop/39/Cmap.npy b/test_loop/39/Cmap.npy new file mode 100644 index 0000000..24ce80b Binary files /dev/null and b/test_loop/39/Cmap.npy differ diff --git a/test_loop/39/ConnSummary.txt b/test_loop/39/ConnSummary.txt new file mode 100644 index 0000000..a77f3ec --- /dev/null +++ b/test_loop/39/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.831378459930419922e-01 +8.219723681139265992e-01 +3.510612521447848550e-02 diff --git a/test_loop/39/ConnectivityMetrics/16.npy b/test_loop/39/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..5121c39 Binary files /dev/null and b/test_loop/39/ConnectivityMetrics/16.npy differ diff --git a/test_loop/39/ConnectivityMetrics/4.npy b/test_loop/39/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..cb52869 Binary files /dev/null and b/test_loop/39/ConnectivityMetrics/4.npy differ diff --git a/test_loop/39/ConnectivityMetrics/8.npy b/test_loop/39/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..c193bec Binary files /dev/null and b/test_loop/39/ConnectivityMetrics/8.npy differ diff --git a/test_loop/39/D.npy b/test_loop/39/D.npy new file mode 100644 index 0000000..92a5457 Binary files /dev/null and b/test_loop/39/D.npy differ diff --git a/test_loop/39/GenParams.txt b/test_loop/39/GenParams.txt new file mode 100644 index 0000000..94f3df0 --- /dev/null +++ b/test_loop/39/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.855083465576171875e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/39/GlobalConnectivityMetrics/16.npy b/test_loop/39/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..5121c39 Binary files /dev/null and b/test_loop/39/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/39/GlobalConnectivityMetrics/4.npy b/test_loop/39/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..2c0f5e6 Binary files /dev/null and b/test_loop/39/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/39/GlobalConnectivityMetrics/8.npy b/test_loop/39/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..807a99e Binary files /dev/null and b/test_loop/39/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/39/KpostProcess/Kd16.npy b/test_loop/39/KpostProcess/Kd16.npy new file mode 100644 index 0000000..6ba3ee6 Binary files /dev/null and b/test_loop/39/KpostProcess/Kd16.npy differ diff --git a/test_loop/39/KpostProcess/Kd4.npy b/test_loop/39/KpostProcess/Kd4.npy new file mode 100644 index 0000000..52af0dd Binary files /dev/null and b/test_loop/39/KpostProcess/Kd4.npy differ diff --git a/test_loop/39/KpostProcess/Kd8.npy b/test_loop/39/KpostProcess/Kd8.npy new file mode 100644 index 0000000..232d76e Binary files /dev/null and b/test_loop/39/KpostProcess/Kd8.npy differ diff --git a/test_loop/39/KpostProcess/Kperm4.npy b/test_loop/39/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..fb0221d Binary files /dev/null and b/test_loop/39/KpostProcess/Kperm4.npy differ diff --git a/test_loop/39/KpostProcess/Kperm8.npy b/test_loop/39/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..fb0221d Binary files /dev/null and b/test_loop/39/KpostProcess/Kperm8.npy differ diff --git a/test_loop/39/KpostProcess/Kv16.npy b/test_loop/39/KpostProcess/Kv16.npy new file mode 100644 index 0000000..98051d4 Binary files /dev/null and b/test_loop/39/KpostProcess/Kv16.npy differ diff --git a/test_loop/39/KpostProcess/Kv4.npy b/test_loop/39/KpostProcess/Kv4.npy new file mode 100644 index 0000000..4485b48 Binary files /dev/null and b/test_loop/39/KpostProcess/Kv4.npy differ diff --git a/test_loop/39/KpostProcess/Kv8.npy b/test_loop/39/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a7e189a Binary files /dev/null and b/test_loop/39/KpostProcess/Kv8.npy differ diff --git a/test_loop/39/P.npy b/test_loop/39/P.npy new file mode 100644 index 0000000..a9e57ca Binary files /dev/null and b/test_loop/39/P.npy differ diff --git a/test_loop/39/PosKeffSummary.txt b/test_loop/39/PosKeffSummary.txt new file mode 100644 index 0000000..6300c3b --- /dev/null +++ b/test_loop/39/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +9.726174425900629972e-01 +9.836309553544616557e-01 +4.379034042358398438e-03 +2.413567811836445920e-01 diff --git a/test_loop/39/RunTimes.out b/test_loop/39/RunTimes.out new file mode 100644 index 0000000..d61347d --- /dev/null +++ b/test_loop/39/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.35759806633 +Solver: 0.392536878586 +Keff: 0.9836413821585651 +N_cores: 1 diff --git a/test_loop/39/SolverRes.txt b/test_loop/39/SolverRes.txt new file mode 100644 index 0000000..2ecff45 --- /dev/null +++ b/test_loop/39/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +9.836413821585651140e-01 +2.000000000000000000e+00 +7.501349449157714844e-01 +1.000000000000000000e+00 diff --git a/test_loop/39/V.npy b/test_loop/39/V.npy new file mode 100644 index 0000000..d50523b Binary files /dev/null and b/test_loop/39/V.npy differ diff --git a/test_loop/39/connec.out b/test_loop/39/connec.out new file mode 100644 index 0000000..c167337 --- /dev/null +++ b/test_loop/39/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.359375000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/39/k.npy b/test_loop/39/k.npy new file mode 100644 index 0000000..33a5d6a Binary files /dev/null and b/test_loop/39/k.npy differ diff --git a/test_loop/39/lc.txt b/test_loop/39/lc.txt new file mode 100644 index 0000000..d64bdd9 --- /dev/null +++ b/test_loop/39/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.429711070124135830e+01 +9.328127590383708423e+00 +1.813161684283152164e+00 diff --git a/test_loop/39/tkperm_sub.txt b/test_loop/39/tkperm_sub.txt new file mode 100644 index 0000000..339d32a --- /dev/null +++ b/test_loop/39/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.171219825744628906e-01 +1.590251922607421875e-04 diff --git a/test_loop/4/Cmap.npy b/test_loop/4/Cmap.npy new file mode 100644 index 0000000..e2cc1a9 Binary files /dev/null and b/test_loop/4/Cmap.npy differ diff --git a/test_loop/4/ConnSummary.txt b/test_loop/4/ConnSummary.txt new file mode 100644 index 0000000..41a5312 --- /dev/null +++ b/test_loop/4/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.566029071807861328e-01 +8.310364170378973236e-01 +3.433774531139579395e-02 diff --git a/test_loop/4/ConnectivityMetrics/16.npy b/test_loop/4/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..67b299f Binary files /dev/null and b/test_loop/4/ConnectivityMetrics/16.npy differ diff --git a/test_loop/4/ConnectivityMetrics/4.npy b/test_loop/4/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..fb3dde5 Binary files /dev/null and b/test_loop/4/ConnectivityMetrics/4.npy differ diff --git a/test_loop/4/ConnectivityMetrics/8.npy b/test_loop/4/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..1c86af9 Binary files /dev/null and b/test_loop/4/ConnectivityMetrics/8.npy differ diff --git a/test_loop/4/D.npy b/test_loop/4/D.npy new file mode 100644 index 0000000..8af7055 Binary files /dev/null and b/test_loop/4/D.npy differ diff --git a/test_loop/4/GenParams.txt b/test_loop/4/GenParams.txt new file mode 100644 index 0000000..77cfa7a --- /dev/null +++ b/test_loop/4/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.726099014282226562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/4/GlobalConnectivityMetrics/16.npy b/test_loop/4/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..67b299f Binary files /dev/null and b/test_loop/4/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/4/GlobalConnectivityMetrics/4.npy b/test_loop/4/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..ba38d9e Binary files /dev/null and b/test_loop/4/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/4/GlobalConnectivityMetrics/8.npy b/test_loop/4/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..dce97fe Binary files /dev/null and b/test_loop/4/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/4/KpostProcess/Kd1.npy b/test_loop/4/KpostProcess/Kd1.npy new file mode 100644 index 0000000..1ff2729 Binary files /dev/null and b/test_loop/4/KpostProcess/Kd1.npy differ diff --git a/test_loop/4/KpostProcess/Kd16.npy b/test_loop/4/KpostProcess/Kd16.npy new file mode 100644 index 0000000..3e3a627 Binary files /dev/null and b/test_loop/4/KpostProcess/Kd16.npy differ diff --git a/test_loop/4/KpostProcess/Kd2.npy b/test_loop/4/KpostProcess/Kd2.npy new file mode 100644 index 0000000..6eea433 Binary files /dev/null and b/test_loop/4/KpostProcess/Kd2.npy differ diff --git a/test_loop/4/KpostProcess/Kd4.npy b/test_loop/4/KpostProcess/Kd4.npy new file mode 100644 index 0000000..4f614c0 Binary files /dev/null and b/test_loop/4/KpostProcess/Kd4.npy differ diff --git a/test_loop/4/KpostProcess/Kd8.npy b/test_loop/4/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2a2d650 Binary files /dev/null and b/test_loop/4/KpostProcess/Kd8.npy differ diff --git a/test_loop/4/KpostProcess/Kperm2.npy b/test_loop/4/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..4e92b82 Binary files /dev/null and b/test_loop/4/KpostProcess/Kperm2.npy differ diff --git a/test_loop/4/KpostProcess/Kperm4.npy b/test_loop/4/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..4e92b82 Binary files /dev/null and b/test_loop/4/KpostProcess/Kperm4.npy differ diff --git a/test_loop/4/KpostProcess/Kperm8.npy b/test_loop/4/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..4e92b82 Binary files /dev/null and b/test_loop/4/KpostProcess/Kperm8.npy differ diff --git a/test_loop/4/KpostProcess/Kv1.npy b/test_loop/4/KpostProcess/Kv1.npy new file mode 100644 index 0000000..a0074ff Binary files /dev/null and b/test_loop/4/KpostProcess/Kv1.npy differ diff --git a/test_loop/4/KpostProcess/Kv16.npy b/test_loop/4/KpostProcess/Kv16.npy new file mode 100644 index 0000000..d28f1e4 Binary files /dev/null and b/test_loop/4/KpostProcess/Kv16.npy differ diff --git a/test_loop/4/KpostProcess/Kv2.npy b/test_loop/4/KpostProcess/Kv2.npy new file mode 100644 index 0000000..0dfefb6 Binary files /dev/null and b/test_loop/4/KpostProcess/Kv2.npy differ diff --git a/test_loop/4/KpostProcess/Kv4.npy b/test_loop/4/KpostProcess/Kv4.npy new file mode 100644 index 0000000..aca61cb Binary files /dev/null and b/test_loop/4/KpostProcess/Kv4.npy differ diff --git a/test_loop/4/KpostProcess/Kv8.npy b/test_loop/4/KpostProcess/Kv8.npy new file mode 100644 index 0000000..5975b4f Binary files /dev/null and b/test_loop/4/KpostProcess/Kv8.npy differ diff --git a/test_loop/4/P.npy b/test_loop/4/P.npy new file mode 100644 index 0000000..1058dd2 Binary files /dev/null and b/test_loop/4/P.npy differ diff --git a/test_loop/4/PosKeffSummary.txt b/test_loop/4/PosKeffSummary.txt new file mode 100644 index 0000000..fa5a43a --- /dev/null +++ b/test_loop/4/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.173863662335137809e-02 +3.228694827557729990e-02 +2.038719654083251953e-01 +7.033087319509624853e-03 diff --git a/test_loop/4/RunTimes.out b/test_loop/4/RunTimes.out new file mode 100644 index 0000000..73317df --- /dev/null +++ b/test_loop/4/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.299716949463 +Solver: 0.243232965469 +Keff: 0.03243914815041115 +N_cores: 1 diff --git a/test_loop/4/SolverRes.txt b/test_loop/4/SolverRes.txt new file mode 100644 index 0000000..0c52d6a --- /dev/null +++ b/test_loop/4/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.243914815041114980e-02 +2.000000000000000000e+00 +5.429499149322509766e-01 +1.000000000000000000e+00 diff --git a/test_loop/4/V.npy b/test_loop/4/V.npy new file mode 100644 index 0000000..60db872 Binary files /dev/null and b/test_loop/4/V.npy differ diff --git a/test_loop/4/connec.out b/test_loop/4/connec.out new file mode 100644 index 0000000..e6ae057 --- /dev/null +++ b/test_loop/4/connec.out @@ -0,0 +1,4 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.00000000 diff --git a/test_loop/4/k.npy b/test_loop/4/k.npy new file mode 100644 index 0000000..28a8126 Binary files /dev/null and b/test_loop/4/k.npy differ diff --git a/test_loop/4/lc.txt b/test_loop/4/lc.txt new file mode 100644 index 0000000..a69ec18 --- /dev/null +++ b/test_loop/4/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.489671950319371163e+00 +4.489671950319371163e+00 +5.102821860552319677e+00 diff --git a/test_loop/4/tkperm_sub.txt b/test_loop/4/tkperm_sub.txt new file mode 100644 index 0000000..b6fa65d --- /dev/null +++ b/test_loop/4/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.749670028686523438e-01 +2.281665802001953125e-04 +1.890659332275390625e-04 diff --git a/test_loop/40/Cmap.npy b/test_loop/40/Cmap.npy new file mode 100644 index 0000000..d2454c1 Binary files /dev/null and b/test_loop/40/Cmap.npy differ diff --git a/test_loop/40/ConnSummary.txt b/test_loop/40/ConnSummary.txt new file mode 100644 index 0000000..ed3cf48 --- /dev/null +++ b/test_loop/40/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.456448554992675781e-01 +7.868101884793785583e-01 +4.551859916433496911e-02 diff --git a/test_loop/40/ConnectivityMetrics/16.npy b/test_loop/40/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d11b993 Binary files /dev/null and b/test_loop/40/ConnectivityMetrics/16.npy differ diff --git a/test_loop/40/ConnectivityMetrics/4.npy b/test_loop/40/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..ae69ac0 Binary files /dev/null and b/test_loop/40/ConnectivityMetrics/4.npy differ diff --git a/test_loop/40/ConnectivityMetrics/8.npy b/test_loop/40/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..ff77e4e Binary files /dev/null and b/test_loop/40/ConnectivityMetrics/8.npy differ diff --git a/test_loop/40/D.npy b/test_loop/40/D.npy new file mode 100644 index 0000000..9a5dfa3 Binary files /dev/null and b/test_loop/40/D.npy differ diff --git a/test_loop/40/GenParams.txt b/test_loop/40/GenParams.txt new file mode 100644 index 0000000..422e51b --- /dev/null +++ b/test_loop/40/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +8.437871932983398438e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/40/GlobalConnectivityMetrics/16.npy b/test_loop/40/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d11b993 Binary files /dev/null and b/test_loop/40/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/40/GlobalConnectivityMetrics/4.npy b/test_loop/40/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..7b3eea3 Binary files /dev/null and b/test_loop/40/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/40/GlobalConnectivityMetrics/8.npy b/test_loop/40/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..7e9859b Binary files /dev/null and b/test_loop/40/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/40/KpostProcess/Kd1.npy b/test_loop/40/KpostProcess/Kd1.npy new file mode 100644 index 0000000..d739005 Binary files /dev/null and b/test_loop/40/KpostProcess/Kd1.npy differ diff --git a/test_loop/40/KpostProcess/Kd16.npy b/test_loop/40/KpostProcess/Kd16.npy new file mode 100644 index 0000000..60f7765 Binary files /dev/null and b/test_loop/40/KpostProcess/Kd16.npy differ diff --git a/test_loop/40/KpostProcess/Kd2.npy b/test_loop/40/KpostProcess/Kd2.npy new file mode 100644 index 0000000..31e3b6b Binary files /dev/null and b/test_loop/40/KpostProcess/Kd2.npy differ diff --git a/test_loop/40/KpostProcess/Kd4.npy b/test_loop/40/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7b922cf Binary files /dev/null and b/test_loop/40/KpostProcess/Kd4.npy differ diff --git a/test_loop/40/KpostProcess/Kd8.npy b/test_loop/40/KpostProcess/Kd8.npy new file mode 100644 index 0000000..30156ba Binary files /dev/null and b/test_loop/40/KpostProcess/Kd8.npy differ diff --git a/test_loop/40/KpostProcess/Kperm2.npy b/test_loop/40/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..030980e Binary files /dev/null and b/test_loop/40/KpostProcess/Kperm2.npy differ diff --git a/test_loop/40/KpostProcess/Kperm4.npy b/test_loop/40/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..030980e Binary files /dev/null and b/test_loop/40/KpostProcess/Kperm4.npy differ diff --git a/test_loop/40/KpostProcess/Kperm8.npy b/test_loop/40/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..030980e Binary files /dev/null and b/test_loop/40/KpostProcess/Kperm8.npy differ diff --git a/test_loop/40/KpostProcess/Kv1.npy b/test_loop/40/KpostProcess/Kv1.npy new file mode 100644 index 0000000..7696404 Binary files /dev/null and b/test_loop/40/KpostProcess/Kv1.npy differ diff --git a/test_loop/40/KpostProcess/Kv16.npy b/test_loop/40/KpostProcess/Kv16.npy new file mode 100644 index 0000000..25048a4 Binary files /dev/null and b/test_loop/40/KpostProcess/Kv16.npy differ diff --git a/test_loop/40/KpostProcess/Kv2.npy b/test_loop/40/KpostProcess/Kv2.npy new file mode 100644 index 0000000..838f468 Binary files /dev/null and b/test_loop/40/KpostProcess/Kv2.npy differ diff --git a/test_loop/40/KpostProcess/Kv4.npy b/test_loop/40/KpostProcess/Kv4.npy new file mode 100644 index 0000000..006d644 Binary files /dev/null and b/test_loop/40/KpostProcess/Kv4.npy differ diff --git a/test_loop/40/KpostProcess/Kv8.npy b/test_loop/40/KpostProcess/Kv8.npy new file mode 100644 index 0000000..2f984c7 Binary files /dev/null and b/test_loop/40/KpostProcess/Kv8.npy differ diff --git a/test_loop/40/P.npy b/test_loop/40/P.npy new file mode 100644 index 0000000..ca75ef9 Binary files /dev/null and b/test_loop/40/P.npy differ diff --git a/test_loop/40/PosKeffSummary.txt b/test_loop/40/PosKeffSummary.txt new file mode 100644 index 0000000..978fc01 --- /dev/null +++ b/test_loop/40/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.537587042510607904e-02 +3.623052761347813483e-02 +2.579200267791748047e-01 +4.036809192129747585e-03 diff --git a/test_loop/40/RunTimes.out b/test_loop/40/RunTimes.out new file mode 100644 index 0000000..e7bd325 --- /dev/null +++ b/test_loop/40/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.305963039398 +Solver: 0.317093133926 +Keff: 0.03614168014462385 +N_cores: 1 diff --git a/test_loop/40/SolverRes.txt b/test_loop/40/SolverRes.txt new file mode 100644 index 0000000..651e381 --- /dev/null +++ b/test_loop/40/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.614168014462385004e-02 +2.000000000000000000e+00 +6.230561733245849609e-01 +1.000000000000000000e+00 diff --git a/test_loop/40/V.npy b/test_loop/40/V.npy new file mode 100644 index 0000000..d2640ff Binary files /dev/null and b/test_loop/40/V.npy differ diff --git a/test_loop/40/connec.out b/test_loop/40/connec.out new file mode 100644 index 0000000..0633a1a --- /dev/null +++ b/test_loop/40/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.296875000 + NCC : 1 diff --git a/test_loop/40/k.npy b/test_loop/40/k.npy new file mode 100644 index 0000000..8b1d2be Binary files /dev/null and b/test_loop/40/k.npy differ diff --git a/test_loop/40/lc.txt b/test_loop/40/lc.txt new file mode 100644 index 0000000..cb6a802 --- /dev/null +++ b/test_loop/40/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.729682375559325358e+00 +3.585636736098190891e+00 +1.995459740653596770e+00 diff --git a/test_loop/40/tkperm_sub.txt b/test_loop/40/tkperm_sub.txt new file mode 100644 index 0000000..fe34d5a --- /dev/null +++ b/test_loop/40/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.856809139251708984e-01 +1.618862152099609375e-04 +1.270771026611328125e-04 diff --git a/test_loop/41/Cmap.npy b/test_loop/41/Cmap.npy new file mode 100644 index 0000000..6b7dcf2 Binary files /dev/null and b/test_loop/41/Cmap.npy differ diff --git a/test_loop/41/ConnSummary.txt b/test_loop/41/ConnSummary.txt new file mode 100644 index 0000000..6351542 --- /dev/null +++ b/test_loop/41/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.040541648864746094e-01 +7.337404394574698063e-01 +6.323913128139888040e-02 diff --git a/test_loop/41/ConnectivityMetrics/16.npy b/test_loop/41/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8b2b2f9 Binary files /dev/null and b/test_loop/41/ConnectivityMetrics/16.npy differ diff --git a/test_loop/41/ConnectivityMetrics/4.npy b/test_loop/41/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..b258548 Binary files /dev/null and b/test_loop/41/ConnectivityMetrics/4.npy differ diff --git a/test_loop/41/ConnectivityMetrics/8.npy b/test_loop/41/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..1f5cba1 Binary files /dev/null and b/test_loop/41/ConnectivityMetrics/8.npy differ diff --git a/test_loop/41/D.npy b/test_loop/41/D.npy new file mode 100644 index 0000000..50dfc5e Binary files /dev/null and b/test_loop/41/D.npy differ diff --git a/test_loop/41/GenParams.txt b/test_loop/41/GenParams.txt new file mode 100644 index 0000000..7d650c1 --- /dev/null +++ b/test_loop/41/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +7.659912109375000000e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/41/GlobalConnectivityMetrics/16.npy b/test_loop/41/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8b2b2f9 Binary files /dev/null and b/test_loop/41/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/41/GlobalConnectivityMetrics/4.npy b/test_loop/41/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..c32aada Binary files /dev/null and b/test_loop/41/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/41/GlobalConnectivityMetrics/8.npy b/test_loop/41/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..887d837 Binary files /dev/null and b/test_loop/41/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/41/KpostProcess/Kd16.npy b/test_loop/41/KpostProcess/Kd16.npy new file mode 100644 index 0000000..bb08117 Binary files /dev/null and b/test_loop/41/KpostProcess/Kd16.npy differ diff --git a/test_loop/41/KpostProcess/Kd4.npy b/test_loop/41/KpostProcess/Kd4.npy new file mode 100644 index 0000000..3cf2c42 Binary files /dev/null and b/test_loop/41/KpostProcess/Kd4.npy differ diff --git a/test_loop/41/KpostProcess/Kd8.npy b/test_loop/41/KpostProcess/Kd8.npy new file mode 100644 index 0000000..afc9caa Binary files /dev/null and b/test_loop/41/KpostProcess/Kd8.npy differ diff --git a/test_loop/41/KpostProcess/Kperm4.npy b/test_loop/41/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..6024e93 Binary files /dev/null and b/test_loop/41/KpostProcess/Kperm4.npy differ diff --git a/test_loop/41/KpostProcess/Kperm8.npy b/test_loop/41/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..6024e93 Binary files /dev/null and b/test_loop/41/KpostProcess/Kperm8.npy differ diff --git a/test_loop/41/KpostProcess/Kv16.npy b/test_loop/41/KpostProcess/Kv16.npy new file mode 100644 index 0000000..6887576 Binary files /dev/null and b/test_loop/41/KpostProcess/Kv16.npy differ diff --git a/test_loop/41/KpostProcess/Kv4.npy b/test_loop/41/KpostProcess/Kv4.npy new file mode 100644 index 0000000..95c1fe4 Binary files /dev/null and b/test_loop/41/KpostProcess/Kv4.npy differ diff --git a/test_loop/41/KpostProcess/Kv8.npy b/test_loop/41/KpostProcess/Kv8.npy new file mode 100644 index 0000000..07d200b Binary files /dev/null and b/test_loop/41/KpostProcess/Kv8.npy differ diff --git a/test_loop/41/P.npy b/test_loop/41/P.npy new file mode 100644 index 0000000..02bc9d2 Binary files /dev/null and b/test_loop/41/P.npy differ diff --git a/test_loop/41/PosKeffSummary.txt b/test_loop/41/PosKeffSummary.txt new file mode 100644 index 0000000..e51d10c --- /dev/null +++ b/test_loop/41/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.519774807542271233e+00 +1.550211390741914386e+00 +4.403114318847656250e-03 +2.416612518951700150e-01 diff --git a/test_loop/41/RunTimes.out b/test_loop/41/RunTimes.out new file mode 100644 index 0000000..5da82c0 --- /dev/null +++ b/test_loop/41/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.30540394783 +Solver: 0.365700960159 +Keff: 1.5502110076584863 +N_cores: 1 diff --git a/test_loop/41/SolverRes.txt b/test_loop/41/SolverRes.txt new file mode 100644 index 0000000..1baa239 --- /dev/null +++ b/test_loop/41/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.550211007658486295e+00 +2.000000000000000000e+00 +6.711049079895019531e-01 +1.000000000000000000e+00 diff --git a/test_loop/41/V.npy b/test_loop/41/V.npy new file mode 100644 index 0000000..eaa0d44 Binary files /dev/null and b/test_loop/41/V.npy differ diff --git a/test_loop/41/connec.out b/test_loop/41/connec.out new file mode 100644 index 0000000..c8963f3 --- /dev/null +++ b/test_loop/41/connec.out @@ -0,0 +1,10 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.375000000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 + NCC : 6 diff --git a/test_loop/41/k.npy b/test_loop/41/k.npy new file mode 100644 index 0000000..db9af7e Binary files /dev/null and b/test_loop/41/k.npy differ diff --git a/test_loop/41/lc.txt b/test_loop/41/lc.txt new file mode 100644 index 0000000..da90c97 --- /dev/null +++ b/test_loop/41/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.442879102259119861e+01 +9.508044043339692664e+00 +1.954847141444072234e+00 diff --git a/test_loop/41/tkperm_sub.txt b/test_loop/41/tkperm_sub.txt new file mode 100644 index 0000000..08b8252 --- /dev/null +++ b/test_loop/41/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.894660472869873047e-01 +1.749992370605468750e-04 diff --git a/test_loop/42/Cmap.npy b/test_loop/42/Cmap.npy new file mode 100644 index 0000000..decbafc Binary files /dev/null and b/test_loop/42/Cmap.npy differ diff --git a/test_loop/42/ConnSummary.txt b/test_loop/42/ConnSummary.txt new file mode 100644 index 0000000..8f485f8 --- /dev/null +++ b/test_loop/42/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.554480552673339844e-01 +8.008166653646492383e-01 +4.281333620635630749e-02 diff --git a/test_loop/42/ConnectivityMetrics/16.npy b/test_loop/42/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7d25b2c Binary files /dev/null and b/test_loop/42/ConnectivityMetrics/16.npy differ diff --git a/test_loop/42/ConnectivityMetrics/4.npy b/test_loop/42/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..6c5e377 Binary files /dev/null and b/test_loop/42/ConnectivityMetrics/4.npy differ diff --git a/test_loop/42/ConnectivityMetrics/8.npy b/test_loop/42/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e9599fd Binary files /dev/null and b/test_loop/42/ConnectivityMetrics/8.npy differ diff --git a/test_loop/42/D.npy b/test_loop/42/D.npy new file mode 100644 index 0000000..e61970b Binary files /dev/null and b/test_loop/42/D.npy differ diff --git a/test_loop/42/GenParams.txt b/test_loop/42/GenParams.txt new file mode 100644 index 0000000..ef17215 --- /dev/null +++ b/test_loop/42/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +8.096933364868164062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/42/GlobalConnectivityMetrics/16.npy b/test_loop/42/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7d25b2c Binary files /dev/null and b/test_loop/42/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/42/GlobalConnectivityMetrics/4.npy b/test_loop/42/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..db7bcbe Binary files /dev/null and b/test_loop/42/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/42/GlobalConnectivityMetrics/8.npy b/test_loop/42/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..69fd33f Binary files /dev/null and b/test_loop/42/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/42/KpostProcess/Kd1.npy b/test_loop/42/KpostProcess/Kd1.npy new file mode 100644 index 0000000..5d28ab0 Binary files /dev/null and b/test_loop/42/KpostProcess/Kd1.npy differ diff --git a/test_loop/42/KpostProcess/Kd16.npy b/test_loop/42/KpostProcess/Kd16.npy new file mode 100644 index 0000000..efdc9dc Binary files /dev/null and b/test_loop/42/KpostProcess/Kd16.npy differ diff --git a/test_loop/42/KpostProcess/Kd2.npy b/test_loop/42/KpostProcess/Kd2.npy new file mode 100644 index 0000000..96f3678 Binary files /dev/null and b/test_loop/42/KpostProcess/Kd2.npy differ diff --git a/test_loop/42/KpostProcess/Kd4.npy b/test_loop/42/KpostProcess/Kd4.npy new file mode 100644 index 0000000..9135398 Binary files /dev/null and b/test_loop/42/KpostProcess/Kd4.npy differ diff --git a/test_loop/42/KpostProcess/Kd8.npy b/test_loop/42/KpostProcess/Kd8.npy new file mode 100644 index 0000000..58ccd10 Binary files /dev/null and b/test_loop/42/KpostProcess/Kd8.npy differ diff --git a/test_loop/42/KpostProcess/Kperm2.npy b/test_loop/42/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..808d6c9 Binary files /dev/null and b/test_loop/42/KpostProcess/Kperm2.npy differ diff --git a/test_loop/42/KpostProcess/Kperm4.npy b/test_loop/42/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..808d6c9 Binary files /dev/null and b/test_loop/42/KpostProcess/Kperm4.npy differ diff --git a/test_loop/42/KpostProcess/Kperm8.npy b/test_loop/42/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..808d6c9 Binary files /dev/null and b/test_loop/42/KpostProcess/Kperm8.npy differ diff --git a/test_loop/42/KpostProcess/Kv1.npy b/test_loop/42/KpostProcess/Kv1.npy new file mode 100644 index 0000000..4ec3888 Binary files /dev/null and b/test_loop/42/KpostProcess/Kv1.npy differ diff --git a/test_loop/42/KpostProcess/Kv16.npy b/test_loop/42/KpostProcess/Kv16.npy new file mode 100644 index 0000000..d726214 Binary files /dev/null and b/test_loop/42/KpostProcess/Kv16.npy differ diff --git a/test_loop/42/KpostProcess/Kv2.npy b/test_loop/42/KpostProcess/Kv2.npy new file mode 100644 index 0000000..b727c41 Binary files /dev/null and b/test_loop/42/KpostProcess/Kv2.npy differ diff --git a/test_loop/42/KpostProcess/Kv4.npy b/test_loop/42/KpostProcess/Kv4.npy new file mode 100644 index 0000000..bdcf6f5 Binary files /dev/null and b/test_loop/42/KpostProcess/Kv4.npy differ diff --git a/test_loop/42/KpostProcess/Kv8.npy b/test_loop/42/KpostProcess/Kv8.npy new file mode 100644 index 0000000..affab12 Binary files /dev/null and b/test_loop/42/KpostProcess/Kv8.npy differ diff --git a/test_loop/42/P.npy b/test_loop/42/P.npy new file mode 100644 index 0000000..9914ef1 Binary files /dev/null and b/test_loop/42/P.npy differ diff --git a/test_loop/42/PosKeffSummary.txt b/test_loop/42/PosKeffSummary.txt new file mode 100644 index 0000000..bc1cd56 --- /dev/null +++ b/test_loop/42/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +5.456342507890619975e-02 +5.758712604026614001e-02 +2.131071090698242188e-01 +4.861070710958162455e-03 diff --git a/test_loop/42/RunTimes.out b/test_loop/42/RunTimes.out new file mode 100644 index 0000000..396c25f --- /dev/null +++ b/test_loop/42/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.28977394104 +Solver: 0.377934932709 +Keff: 0.05760839220023455 +N_cores: 1 diff --git a/test_loop/42/SolverRes.txt b/test_loop/42/SolverRes.txt new file mode 100644 index 0000000..17a575c --- /dev/null +++ b/test_loop/42/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.760839220023455248e-02 +2.000000000000000000e+00 +6.677088737487792969e-01 +1.000000000000000000e+00 diff --git a/test_loop/42/V.npy b/test_loop/42/V.npy new file mode 100644 index 0000000..3373f78 Binary files /dev/null and b/test_loop/42/V.npy differ diff --git a/test_loop/42/connec.out b/test_loop/42/connec.out new file mode 100644 index 0000000..c0d4e8e --- /dev/null +++ b/test_loop/42/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.312500000 + NCC : 1 diff --git a/test_loop/42/k.npy b/test_loop/42/k.npy new file mode 100644 index 0000000..64e1fcc Binary files /dev/null and b/test_loop/42/k.npy differ diff --git a/test_loop/42/lc.txt b/test_loop/42/lc.txt new file mode 100644 index 0000000..18f6dcc --- /dev/null +++ b/test_loop/42/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.739714021404311417e+00 +3.609805216431042574e+00 +2.173306128060184861e+00 diff --git a/test_loop/42/tkperm_sub.txt b/test_loop/42/tkperm_sub.txt new file mode 100644 index 0000000..9b18a2d --- /dev/null +++ b/test_loop/42/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.773410320281982422e-01 +1.630783081054687500e-04 +1.239776611328125000e-04 diff --git a/test_loop/43/Cmap.npy b/test_loop/43/Cmap.npy new file mode 100644 index 0000000..88e1365 Binary files /dev/null and b/test_loop/43/Cmap.npy differ diff --git a/test_loop/43/ConnSummary.txt b/test_loop/43/ConnSummary.txt new file mode 100644 index 0000000..c5ea73b --- /dev/null +++ b/test_loop/43/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.811719417572021484e-01 +8.197768132748627368e-01 +3.560529438292767135e-02 diff --git a/test_loop/43/ConnectivityMetrics/16.npy b/test_loop/43/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..e8701b0 Binary files /dev/null and b/test_loop/43/ConnectivityMetrics/16.npy differ diff --git a/test_loop/43/ConnectivityMetrics/4.npy b/test_loop/43/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..eb1f572 Binary files /dev/null and b/test_loop/43/ConnectivityMetrics/4.npy differ diff --git a/test_loop/43/ConnectivityMetrics/8.npy b/test_loop/43/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..8ac91d6 Binary files /dev/null and b/test_loop/43/ConnectivityMetrics/8.npy differ diff --git a/test_loop/43/D.npy b/test_loop/43/D.npy new file mode 100644 index 0000000..b56b207 Binary files /dev/null and b/test_loop/43/D.npy differ diff --git a/test_loop/43/GenParams.txt b/test_loop/43/GenParams.txt new file mode 100644 index 0000000..07631de --- /dev/null +++ b/test_loop/43/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.314039230346679688e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/43/GlobalConnectivityMetrics/16.npy b/test_loop/43/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..e8701b0 Binary files /dev/null and b/test_loop/43/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/43/GlobalConnectivityMetrics/4.npy b/test_loop/43/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..161e943 Binary files /dev/null and b/test_loop/43/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/43/GlobalConnectivityMetrics/8.npy b/test_loop/43/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..53d48ff Binary files /dev/null and b/test_loop/43/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/43/KpostProcess/Kd16.npy b/test_loop/43/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c8d12ff Binary files /dev/null and b/test_loop/43/KpostProcess/Kd16.npy differ diff --git a/test_loop/43/KpostProcess/Kd4.npy b/test_loop/43/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7f91be0 Binary files /dev/null and b/test_loop/43/KpostProcess/Kd4.npy differ diff --git a/test_loop/43/KpostProcess/Kd8.npy b/test_loop/43/KpostProcess/Kd8.npy new file mode 100644 index 0000000..7c7f6c4 Binary files /dev/null and b/test_loop/43/KpostProcess/Kd8.npy differ diff --git a/test_loop/43/KpostProcess/Kperm4.npy b/test_loop/43/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..dfe501c Binary files /dev/null and b/test_loop/43/KpostProcess/Kperm4.npy differ diff --git a/test_loop/43/KpostProcess/Kperm8.npy b/test_loop/43/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..dfe501c Binary files /dev/null and b/test_loop/43/KpostProcess/Kperm8.npy differ diff --git a/test_loop/43/KpostProcess/Kv16.npy b/test_loop/43/KpostProcess/Kv16.npy new file mode 100644 index 0000000..4c939e4 Binary files /dev/null and b/test_loop/43/KpostProcess/Kv16.npy differ diff --git a/test_loop/43/KpostProcess/Kv4.npy b/test_loop/43/KpostProcess/Kv4.npy new file mode 100644 index 0000000..4bc89b9 Binary files /dev/null and b/test_loop/43/KpostProcess/Kv4.npy differ diff --git a/test_loop/43/KpostProcess/Kv8.npy b/test_loop/43/KpostProcess/Kv8.npy new file mode 100644 index 0000000..d8a97e5 Binary files /dev/null and b/test_loop/43/KpostProcess/Kv8.npy differ diff --git a/test_loop/43/P.npy b/test_loop/43/P.npy new file mode 100644 index 0000000..9c26ade Binary files /dev/null and b/test_loop/43/P.npy differ diff --git a/test_loop/43/PosKeffSummary.txt b/test_loop/43/PosKeffSummary.txt new file mode 100644 index 0000000..6e1b310 --- /dev/null +++ b/test_loop/43/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.927225757224660940e+00 +2.105162467301547657e+00 +4.451036453247070312e-03 +2.358990840430660318e-01 diff --git a/test_loop/43/RunTimes.out b/test_loop/43/RunTimes.out new file mode 100644 index 0000000..70a3ac8 --- /dev/null +++ b/test_loop/43/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.295831918716 +Solver: 0.359425067902 +Keff: 2.1051510374723197 +N_cores: 1 diff --git a/test_loop/43/SolverRes.txt b/test_loop/43/SolverRes.txt new file mode 100644 index 0000000..9fde5fd --- /dev/null +++ b/test_loop/43/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.105151037472319686e+00 +2.000000000000000000e+00 +6.552569866180419922e-01 +1.000000000000000000e+00 diff --git a/test_loop/43/V.npy b/test_loop/43/V.npy new file mode 100644 index 0000000..5ab03c5 Binary files /dev/null and b/test_loop/43/V.npy differ diff --git a/test_loop/43/connec.out b/test_loop/43/connec.out new file mode 100644 index 0000000..c81c0db --- /dev/null +++ b/test_loop/43/connec.out @@ -0,0 +1,8 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.421875000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 diff --git a/test_loop/43/k.npy b/test_loop/43/k.npy new file mode 100644 index 0000000..75cabfd Binary files /dev/null and b/test_loop/43/k.npy differ diff --git a/test_loop/43/lc.txt b/test_loop/43/lc.txt new file mode 100644 index 0000000..ef57bfb --- /dev/null +++ b/test_loop/43/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +2.453926544954896372e+01 +9.358894255690520581e+00 +2.229287255195868234e+00 diff --git a/test_loop/43/tkperm_sub.txt b/test_loop/43/tkperm_sub.txt new file mode 100644 index 0000000..965cd30 --- /dev/null +++ b/test_loop/43/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.210599422454833984e-01 +1.649856567382812500e-04 diff --git a/test_loop/44/Cmap.npy b/test_loop/44/Cmap.npy new file mode 100644 index 0000000..cdb2ef6 Binary files /dev/null and b/test_loop/44/Cmap.npy differ diff --git a/test_loop/44/ConnSummary.txt b/test_loop/44/ConnSummary.txt new file mode 100644 index 0000000..5740e59 --- /dev/null +++ b/test_loop/44/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.058558940887451172e-01 +7.629013507154803753e-01 +5.636724328445975180e-02 diff --git a/test_loop/44/ConnectivityMetrics/16.npy b/test_loop/44/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..4d359e2 Binary files /dev/null and b/test_loop/44/ConnectivityMetrics/16.npy differ diff --git a/test_loop/44/ConnectivityMetrics/4.npy b/test_loop/44/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..27be557 Binary files /dev/null and b/test_loop/44/ConnectivityMetrics/4.npy differ diff --git a/test_loop/44/ConnectivityMetrics/8.npy b/test_loop/44/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6d05218 Binary files /dev/null and b/test_loop/44/ConnectivityMetrics/8.npy differ diff --git a/test_loop/44/D.npy b/test_loop/44/D.npy new file mode 100644 index 0000000..0fbd3b9 Binary files /dev/null and b/test_loop/44/D.npy differ diff --git a/test_loop/44/GenParams.txt b/test_loop/44/GenParams.txt new file mode 100644 index 0000000..813e8d6 --- /dev/null +++ b/test_loop/44/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.918025970458984375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/44/GlobalConnectivityMetrics/16.npy b/test_loop/44/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..4d359e2 Binary files /dev/null and b/test_loop/44/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/44/GlobalConnectivityMetrics/4.npy b/test_loop/44/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..5613d0d Binary files /dev/null and b/test_loop/44/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/44/GlobalConnectivityMetrics/8.npy b/test_loop/44/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..97b8bb2 Binary files /dev/null and b/test_loop/44/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/44/KpostProcess/Kd1.npy b/test_loop/44/KpostProcess/Kd1.npy new file mode 100644 index 0000000..57a6855 Binary files /dev/null and b/test_loop/44/KpostProcess/Kd1.npy differ diff --git a/test_loop/44/KpostProcess/Kd16.npy b/test_loop/44/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a025439 Binary files /dev/null and b/test_loop/44/KpostProcess/Kd16.npy differ diff --git a/test_loop/44/KpostProcess/Kd2.npy b/test_loop/44/KpostProcess/Kd2.npy new file mode 100644 index 0000000..c836de5 Binary files /dev/null and b/test_loop/44/KpostProcess/Kd2.npy differ diff --git a/test_loop/44/KpostProcess/Kd4.npy b/test_loop/44/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0bcad91 Binary files /dev/null and b/test_loop/44/KpostProcess/Kd4.npy differ diff --git a/test_loop/44/KpostProcess/Kd8.npy b/test_loop/44/KpostProcess/Kd8.npy new file mode 100644 index 0000000..df63734 Binary files /dev/null and b/test_loop/44/KpostProcess/Kd8.npy differ diff --git a/test_loop/44/KpostProcess/Kperm2.npy b/test_loop/44/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..0df1b29 Binary files /dev/null and b/test_loop/44/KpostProcess/Kperm2.npy differ diff --git a/test_loop/44/KpostProcess/Kperm4.npy b/test_loop/44/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..0df1b29 Binary files /dev/null and b/test_loop/44/KpostProcess/Kperm4.npy differ diff --git a/test_loop/44/KpostProcess/Kperm8.npy b/test_loop/44/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..0df1b29 Binary files /dev/null and b/test_loop/44/KpostProcess/Kperm8.npy differ diff --git a/test_loop/44/KpostProcess/Kv1.npy b/test_loop/44/KpostProcess/Kv1.npy new file mode 100644 index 0000000..caa8794 Binary files /dev/null and b/test_loop/44/KpostProcess/Kv1.npy differ diff --git a/test_loop/44/KpostProcess/Kv16.npy b/test_loop/44/KpostProcess/Kv16.npy new file mode 100644 index 0000000..35c53bd Binary files /dev/null and b/test_loop/44/KpostProcess/Kv16.npy differ diff --git a/test_loop/44/KpostProcess/Kv2.npy b/test_loop/44/KpostProcess/Kv2.npy new file mode 100644 index 0000000..55bb1fd Binary files /dev/null and b/test_loop/44/KpostProcess/Kv2.npy differ diff --git a/test_loop/44/KpostProcess/Kv4.npy b/test_loop/44/KpostProcess/Kv4.npy new file mode 100644 index 0000000..242ff8b Binary files /dev/null and b/test_loop/44/KpostProcess/Kv4.npy differ diff --git a/test_loop/44/KpostProcess/Kv8.npy b/test_loop/44/KpostProcess/Kv8.npy new file mode 100644 index 0000000..bf008d6 Binary files /dev/null and b/test_loop/44/KpostProcess/Kv8.npy differ diff --git a/test_loop/44/P.npy b/test_loop/44/P.npy new file mode 100644 index 0000000..b7e7ae0 Binary files /dev/null and b/test_loop/44/P.npy differ diff --git a/test_loop/44/PosKeffSummary.txt b/test_loop/44/PosKeffSummary.txt new file mode 100644 index 0000000..dfddd97 --- /dev/null +++ b/test_loop/44/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.169354234213150656e-01 +4.259325404265952297e-01 +2.003059387207031250e-01 +5.401454988668608764e-03 diff --git a/test_loop/44/RunTimes.out b/test_loop/44/RunTimes.out new file mode 100644 index 0000000..307406c --- /dev/null +++ b/test_loop/44/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.296988010406 +Solver: 0.378781795502 +Keff: 0.42591790748307456 +N_cores: 1 diff --git a/test_loop/44/SolverRes.txt b/test_loop/44/SolverRes.txt new file mode 100644 index 0000000..31cafe3 --- /dev/null +++ b/test_loop/44/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.259179074830745648e-01 +2.000000000000000000e+00 +6.757698059082031250e-01 +1.000000000000000000e+00 diff --git a/test_loop/44/V.npy b/test_loop/44/V.npy new file mode 100644 index 0000000..a2e572c Binary files /dev/null and b/test_loop/44/V.npy differ diff --git a/test_loop/44/connec.out b/test_loop/44/connec.out new file mode 100644 index 0000000..2e0d218 --- /dev/null +++ b/test_loop/44/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.343750000 + NCC : 1 diff --git a/test_loop/44/k.npy b/test_loop/44/k.npy new file mode 100644 index 0000000..fc2c40c Binary files /dev/null and b/test_loop/44/k.npy differ diff --git a/test_loop/44/lc.txt b/test_loop/44/lc.txt new file mode 100644 index 0000000..2f25a9f --- /dev/null +++ b/test_loop/44/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.210332111317066861e+00 +3.552192050324866290e+00 +1.905040280796568952e+00 diff --git a/test_loop/44/tkperm_sub.txt b/test_loop/44/tkperm_sub.txt new file mode 100644 index 0000000..ca5f1d2 --- /dev/null +++ b/test_loop/44/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.324710369110107422e-01 +1.711845397949218750e-04 +1.261234283447265625e-04 diff --git a/test_loop/45/Cmap.npy b/test_loop/45/Cmap.npy new file mode 100644 index 0000000..6453aee Binary files /dev/null and b/test_loop/45/Cmap.npy differ diff --git a/test_loop/45/ConnSummary.txt b/test_loop/45/ConnSummary.txt new file mode 100644 index 0000000..429598d --- /dev/null +++ b/test_loop/45/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.650110244750976562e-01 +8.666329370739142002e-01 +2.636984625044518082e-02 diff --git a/test_loop/45/ConnectivityMetrics/16.npy b/test_loop/45/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..20ee71e Binary files /dev/null and b/test_loop/45/ConnectivityMetrics/16.npy differ diff --git a/test_loop/45/ConnectivityMetrics/4.npy b/test_loop/45/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..5f69e8f Binary files /dev/null and b/test_loop/45/ConnectivityMetrics/4.npy differ diff --git a/test_loop/45/ConnectivityMetrics/8.npy b/test_loop/45/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..73bb7f6 Binary files /dev/null and b/test_loop/45/ConnectivityMetrics/8.npy differ diff --git a/test_loop/45/D.npy b/test_loop/45/D.npy new file mode 100644 index 0000000..06b5651 Binary files /dev/null and b/test_loop/45/D.npy differ diff --git a/test_loop/45/GenParams.txt b/test_loop/45/GenParams.txt new file mode 100644 index 0000000..a31dd24 --- /dev/null +++ b/test_loop/45/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.883050918579101562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/45/GlobalConnectivityMetrics/16.npy b/test_loop/45/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..20ee71e Binary files /dev/null and b/test_loop/45/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/45/GlobalConnectivityMetrics/4.npy b/test_loop/45/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..15917dc Binary files /dev/null and b/test_loop/45/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/45/GlobalConnectivityMetrics/8.npy b/test_loop/45/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..1b20c2a Binary files /dev/null and b/test_loop/45/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/45/KpostProcess/Kd16.npy b/test_loop/45/KpostProcess/Kd16.npy new file mode 100644 index 0000000..dc2addd Binary files /dev/null and b/test_loop/45/KpostProcess/Kd16.npy differ diff --git a/test_loop/45/KpostProcess/Kd4.npy b/test_loop/45/KpostProcess/Kd4.npy new file mode 100644 index 0000000..c37aeb6 Binary files /dev/null and b/test_loop/45/KpostProcess/Kd4.npy differ diff --git a/test_loop/45/KpostProcess/Kd8.npy b/test_loop/45/KpostProcess/Kd8.npy new file mode 100644 index 0000000..665e65b Binary files /dev/null and b/test_loop/45/KpostProcess/Kd8.npy differ diff --git a/test_loop/45/KpostProcess/Kperm4.npy b/test_loop/45/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..1743100 Binary files /dev/null and b/test_loop/45/KpostProcess/Kperm4.npy differ diff --git a/test_loop/45/KpostProcess/Kperm8.npy b/test_loop/45/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..1743100 Binary files /dev/null and b/test_loop/45/KpostProcess/Kperm8.npy differ diff --git a/test_loop/45/KpostProcess/Kv16.npy b/test_loop/45/KpostProcess/Kv16.npy new file mode 100644 index 0000000..ce829cc Binary files /dev/null and b/test_loop/45/KpostProcess/Kv16.npy differ diff --git a/test_loop/45/KpostProcess/Kv4.npy b/test_loop/45/KpostProcess/Kv4.npy new file mode 100644 index 0000000..35090a3 Binary files /dev/null and b/test_loop/45/KpostProcess/Kv4.npy differ diff --git a/test_loop/45/KpostProcess/Kv8.npy b/test_loop/45/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c783198 Binary files /dev/null and b/test_loop/45/KpostProcess/Kv8.npy differ diff --git a/test_loop/45/P.npy b/test_loop/45/P.npy new file mode 100644 index 0000000..3b07cb0 Binary files /dev/null and b/test_loop/45/P.npy differ diff --git a/test_loop/45/PosKeffSummary.txt b/test_loop/45/PosKeffSummary.txt new file mode 100644 index 0000000..90637a7 --- /dev/null +++ b/test_loop/45/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.051011755203576925e+00 +3.057380531162848136e+00 +4.421949386596679688e-03 +2.324365126435542217e-01 diff --git a/test_loop/45/RunTimes.out b/test_loop/45/RunTimes.out new file mode 100644 index 0000000..41f17e1 --- /dev/null +++ b/test_loop/45/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.353626966476 +Solver: 0.288952112198 +Keff: 3.057516607217327 +N_cores: 1 diff --git a/test_loop/45/SolverRes.txt b/test_loop/45/SolverRes.txt new file mode 100644 index 0000000..3b9fa77 --- /dev/null +++ b/test_loop/45/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.057516607217327209e+00 +2.000000000000000000e+00 +6.425790786743164062e-01 +1.000000000000000000e+00 diff --git a/test_loop/45/V.npy b/test_loop/45/V.npy new file mode 100644 index 0000000..03380ad Binary files /dev/null and b/test_loop/45/V.npy differ diff --git a/test_loop/45/connec.out b/test_loop/45/connec.out new file mode 100644 index 0000000..7b30bff --- /dev/null +++ b/test_loop/45/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.515625000 + NCC : 1 + NCC : 2 diff --git a/test_loop/45/k.npy b/test_loop/45/k.npy new file mode 100644 index 0000000..677ee20 Binary files /dev/null and b/test_loop/45/k.npy differ diff --git a/test_loop/45/lc.txt b/test_loop/45/lc.txt new file mode 100644 index 0000000..491a770 --- /dev/null +++ b/test_loop/45/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.562157142569886403e+01 +8.541551503424004821e+00 +2.464414237194115564e+00 diff --git a/test_loop/45/tkperm_sub.txt b/test_loop/45/tkperm_sub.txt new file mode 100644 index 0000000..26af17d --- /dev/null +++ b/test_loop/45/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.266730308532714844e-01 +1.659393310546875000e-04 diff --git a/test_loop/46/Cmap.npy b/test_loop/46/Cmap.npy new file mode 100644 index 0000000..7695260 Binary files /dev/null and b/test_loop/46/Cmap.npy differ diff --git a/test_loop/46/ConnSummary.txt b/test_loop/46/ConnSummary.txt new file mode 100644 index 0000000..79f2041 --- /dev/null +++ b/test_loop/46/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.271800518035888672e-01 +7.179480310293500089e-01 +6.635121611990246748e-02 diff --git a/test_loop/46/ConnectivityMetrics/16.npy b/test_loop/46/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8ce2aa7 Binary files /dev/null and b/test_loop/46/ConnectivityMetrics/16.npy differ diff --git a/test_loop/46/ConnectivityMetrics/4.npy b/test_loop/46/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..5f3e85c Binary files /dev/null and b/test_loop/46/ConnectivityMetrics/4.npy differ diff --git a/test_loop/46/ConnectivityMetrics/8.npy b/test_loop/46/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b993a92 Binary files /dev/null and b/test_loop/46/ConnectivityMetrics/8.npy differ diff --git a/test_loop/46/D.npy b/test_loop/46/D.npy new file mode 100644 index 0000000..c81278c Binary files /dev/null and b/test_loop/46/D.npy differ diff --git a/test_loop/46/GenParams.txt b/test_loop/46/GenParams.txt new file mode 100644 index 0000000..fa484bd --- /dev/null +++ b/test_loop/46/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.891084671020507812e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/46/GlobalConnectivityMetrics/16.npy b/test_loop/46/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8ce2aa7 Binary files /dev/null and b/test_loop/46/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/46/GlobalConnectivityMetrics/4.npy b/test_loop/46/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..b741622 Binary files /dev/null and b/test_loop/46/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/46/GlobalConnectivityMetrics/8.npy b/test_loop/46/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..6072b59 Binary files /dev/null and b/test_loop/46/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/46/KpostProcess/Kd1.npy b/test_loop/46/KpostProcess/Kd1.npy new file mode 100644 index 0000000..2ce63ed Binary files /dev/null and b/test_loop/46/KpostProcess/Kd1.npy differ diff --git a/test_loop/46/KpostProcess/Kd16.npy b/test_loop/46/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a317597 Binary files /dev/null and b/test_loop/46/KpostProcess/Kd16.npy differ diff --git a/test_loop/46/KpostProcess/Kd2.npy b/test_loop/46/KpostProcess/Kd2.npy new file mode 100644 index 0000000..eccaf45 Binary files /dev/null and b/test_loop/46/KpostProcess/Kd2.npy differ diff --git a/test_loop/46/KpostProcess/Kd4.npy b/test_loop/46/KpostProcess/Kd4.npy new file mode 100644 index 0000000..8ac0dd9 Binary files /dev/null and b/test_loop/46/KpostProcess/Kd4.npy differ diff --git a/test_loop/46/KpostProcess/Kd8.npy b/test_loop/46/KpostProcess/Kd8.npy new file mode 100644 index 0000000..1b2d949 Binary files /dev/null and b/test_loop/46/KpostProcess/Kd8.npy differ diff --git a/test_loop/46/KpostProcess/Kperm2.npy b/test_loop/46/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..88fb549 Binary files /dev/null and b/test_loop/46/KpostProcess/Kperm2.npy differ diff --git a/test_loop/46/KpostProcess/Kperm4.npy b/test_loop/46/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..88fb549 Binary files /dev/null and b/test_loop/46/KpostProcess/Kperm4.npy differ diff --git a/test_loop/46/KpostProcess/Kperm8.npy b/test_loop/46/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..88fb549 Binary files /dev/null and b/test_loop/46/KpostProcess/Kperm8.npy differ diff --git a/test_loop/46/KpostProcess/Kv1.npy b/test_loop/46/KpostProcess/Kv1.npy new file mode 100644 index 0000000..4ba8dbc Binary files /dev/null and b/test_loop/46/KpostProcess/Kv1.npy differ diff --git a/test_loop/46/KpostProcess/Kv16.npy b/test_loop/46/KpostProcess/Kv16.npy new file mode 100644 index 0000000..052ad00 Binary files /dev/null and b/test_loop/46/KpostProcess/Kv16.npy differ diff --git a/test_loop/46/KpostProcess/Kv2.npy b/test_loop/46/KpostProcess/Kv2.npy new file mode 100644 index 0000000..4c7391b Binary files /dev/null and b/test_loop/46/KpostProcess/Kv2.npy differ diff --git a/test_loop/46/KpostProcess/Kv4.npy b/test_loop/46/KpostProcess/Kv4.npy new file mode 100644 index 0000000..a61cb74 Binary files /dev/null and b/test_loop/46/KpostProcess/Kv4.npy differ diff --git a/test_loop/46/KpostProcess/Kv8.npy b/test_loop/46/KpostProcess/Kv8.npy new file mode 100644 index 0000000..fa55123 Binary files /dev/null and b/test_loop/46/KpostProcess/Kv8.npy differ diff --git a/test_loop/46/P.npy b/test_loop/46/P.npy new file mode 100644 index 0000000..d1cd8cf Binary files /dev/null and b/test_loop/46/P.npy differ diff --git a/test_loop/46/PosKeffSummary.txt b/test_loop/46/PosKeffSummary.txt new file mode 100644 index 0000000..d7c7a32 --- /dev/null +++ b/test_loop/46/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.638068421743901104e-01 +4.782261223550312024e-01 +1.947808265686035156e-01 +8.100664651088778853e-03 diff --git a/test_loop/46/RunTimes.out b/test_loop/46/RunTimes.out new file mode 100644 index 0000000..815cce2 --- /dev/null +++ b/test_loop/46/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.295572042465 +Solver: 0.348423957825 +Keff: 0.4782071654365643 +N_cores: 1 diff --git a/test_loop/46/SolverRes.txt b/test_loop/46/SolverRes.txt new file mode 100644 index 0000000..272a2ed --- /dev/null +++ b/test_loop/46/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.782071654365642743e-01 +2.000000000000000000e+00 +6.439960002899169922e-01 +1.000000000000000000e+00 diff --git a/test_loop/46/V.npy b/test_loop/46/V.npy new file mode 100644 index 0000000..2c6871f Binary files /dev/null and b/test_loop/46/V.npy differ diff --git a/test_loop/46/connec.out b/test_loop/46/connec.out new file mode 100644 index 0000000..cf87562 --- /dev/null +++ b/test_loop/46/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.390625000 + NCC : 1 diff --git a/test_loop/46/k.npy b/test_loop/46/k.npy new file mode 100644 index 0000000..0d366c6 Binary files /dev/null and b/test_loop/46/k.npy differ diff --git a/test_loop/46/lc.txt b/test_loop/46/lc.txt new file mode 100644 index 0000000..f73d685 --- /dev/null +++ b/test_loop/46/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.227403166681005686e+00 +3.490343912806162407e+00 +2.052039115726493890e+00 diff --git a/test_loop/46/tkperm_sub.txt b/test_loop/46/tkperm_sub.txt new file mode 100644 index 0000000..86d8e24 --- /dev/null +++ b/test_loop/46/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.350868701934814453e-01 +1.800060272216796875e-04 +1.320838928222656250e-04 diff --git a/test_loop/47/Cmap.npy b/test_loop/47/Cmap.npy new file mode 100644 index 0000000..5767948 Binary files /dev/null and b/test_loop/47/Cmap.npy differ diff --git a/test_loop/47/ConnSummary.txt b/test_loop/47/ConnSummary.txt new file mode 100644 index 0000000..82020d8 --- /dev/null +++ b/test_loop/47/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.363339900970458984e-01 +8.164624753754731179e-01 +3.670126682956602326e-02 diff --git a/test_loop/47/ConnectivityMetrics/16.npy b/test_loop/47/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..3b18600 Binary files /dev/null and b/test_loop/47/ConnectivityMetrics/16.npy differ diff --git a/test_loop/47/ConnectivityMetrics/4.npy b/test_loop/47/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..d0ff9d9 Binary files /dev/null and b/test_loop/47/ConnectivityMetrics/4.npy differ diff --git a/test_loop/47/ConnectivityMetrics/8.npy b/test_loop/47/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..86ec049 Binary files /dev/null and b/test_loop/47/ConnectivityMetrics/8.npy differ diff --git a/test_loop/47/D.npy b/test_loop/47/D.npy new file mode 100644 index 0000000..96f0456 Binary files /dev/null and b/test_loop/47/D.npy differ diff --git a/test_loop/47/GenParams.txt b/test_loop/47/GenParams.txt new file mode 100644 index 0000000..63fcb1a --- /dev/null +++ b/test_loop/47/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.334781646728515625e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/47/GlobalConnectivityMetrics/16.npy b/test_loop/47/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..3b18600 Binary files /dev/null and b/test_loop/47/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/47/GlobalConnectivityMetrics/4.npy b/test_loop/47/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..d1defaf Binary files /dev/null and b/test_loop/47/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/47/GlobalConnectivityMetrics/8.npy b/test_loop/47/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..b3ed590 Binary files /dev/null and b/test_loop/47/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/47/KpostProcess/Kd16.npy b/test_loop/47/KpostProcess/Kd16.npy new file mode 100644 index 0000000..0fcbe60 Binary files /dev/null and b/test_loop/47/KpostProcess/Kd16.npy differ diff --git a/test_loop/47/KpostProcess/Kd4.npy b/test_loop/47/KpostProcess/Kd4.npy new file mode 100644 index 0000000..193ecbf Binary files /dev/null and b/test_loop/47/KpostProcess/Kd4.npy differ diff --git a/test_loop/47/KpostProcess/Kd8.npy b/test_loop/47/KpostProcess/Kd8.npy new file mode 100644 index 0000000..f2a5e26 Binary files /dev/null and b/test_loop/47/KpostProcess/Kd8.npy differ diff --git a/test_loop/47/KpostProcess/Kperm4.npy b/test_loop/47/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..8705503 Binary files /dev/null and b/test_loop/47/KpostProcess/Kperm4.npy differ diff --git a/test_loop/47/KpostProcess/Kperm8.npy b/test_loop/47/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..8705503 Binary files /dev/null and b/test_loop/47/KpostProcess/Kperm8.npy differ diff --git a/test_loop/47/KpostProcess/Kv16.npy b/test_loop/47/KpostProcess/Kv16.npy new file mode 100644 index 0000000..b4140d0 Binary files /dev/null and b/test_loop/47/KpostProcess/Kv16.npy differ diff --git a/test_loop/47/KpostProcess/Kv4.npy b/test_loop/47/KpostProcess/Kv4.npy new file mode 100644 index 0000000..b7d0d55 Binary files /dev/null and b/test_loop/47/KpostProcess/Kv4.npy differ diff --git a/test_loop/47/KpostProcess/Kv8.npy b/test_loop/47/KpostProcess/Kv8.npy new file mode 100644 index 0000000..24632ab Binary files /dev/null and b/test_loop/47/KpostProcess/Kv8.npy differ diff --git a/test_loop/47/P.npy b/test_loop/47/P.npy new file mode 100644 index 0000000..d0025fc Binary files /dev/null and b/test_loop/47/P.npy differ diff --git a/test_loop/47/PosKeffSummary.txt b/test_loop/47/PosKeffSummary.txt new file mode 100644 index 0000000..e1dd508 --- /dev/null +++ b/test_loop/47/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.080902377415917215e+00 +4.153094979575763901e+00 +6.233930587768554688e-03 +2.054920258538264488e-01 diff --git a/test_loop/47/RunTimes.out b/test_loop/47/RunTimes.out new file mode 100644 index 0000000..1b5ff4a --- /dev/null +++ b/test_loop/47/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.294410943985 +Solver: 0.291568994522 +Keff: 4.153122199025282 +N_cores: 1 diff --git a/test_loop/47/SolverRes.txt b/test_loop/47/SolverRes.txt new file mode 100644 index 0000000..eae78c5 --- /dev/null +++ b/test_loop/47/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.153122199025282235e+00 +2.000000000000000000e+00 +5.859799385070800781e-01 +1.000000000000000000e+00 diff --git a/test_loop/47/V.npy b/test_loop/47/V.npy new file mode 100644 index 0000000..025b59f Binary files /dev/null and b/test_loop/47/V.npy differ diff --git a/test_loop/47/connec.out b/test_loop/47/connec.out new file mode 100644 index 0000000..7b30bff --- /dev/null +++ b/test_loop/47/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.515625000 + NCC : 1 + NCC : 2 diff --git a/test_loop/47/k.npy b/test_loop/47/k.npy new file mode 100644 index 0000000..b892605 Binary files /dev/null and b/test_loop/47/k.npy differ diff --git a/test_loop/47/lc.txt b/test_loop/47/lc.txt new file mode 100644 index 0000000..33e93a1 --- /dev/null +++ b/test_loop/47/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.575378092565453159e+01 +8.691453851628397231e+00 +2.499721879236810551e+00 diff --git a/test_loop/47/tkperm_sub.txt b/test_loop/47/tkperm_sub.txt new file mode 100644 index 0000000..5e8a764 --- /dev/null +++ b/test_loop/47/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.861169815063476562e-01 +2.100467681884765625e-04 diff --git a/test_loop/48/Cmap.npy b/test_loop/48/Cmap.npy new file mode 100644 index 0000000..962dc75 Binary files /dev/null and b/test_loop/48/Cmap.npy differ diff --git a/test_loop/48/ConnSummary.txt b/test_loop/48/ConnSummary.txt new file mode 100644 index 0000000..4bfa9cd --- /dev/null +++ b/test_loop/48/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.736700057983398438e-01 +8.300184827625085582e-01 +3.280287670708847969e-02 diff --git a/test_loop/48/ConnectivityMetrics/16.npy b/test_loop/48/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8174340 Binary files /dev/null and b/test_loop/48/ConnectivityMetrics/16.npy differ diff --git a/test_loop/48/ConnectivityMetrics/4.npy b/test_loop/48/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..f4cf4ce Binary files /dev/null and b/test_loop/48/ConnectivityMetrics/4.npy differ diff --git a/test_loop/48/ConnectivityMetrics/8.npy b/test_loop/48/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6bc3f46 Binary files /dev/null and b/test_loop/48/ConnectivityMetrics/8.npy differ diff --git a/test_loop/48/D.npy b/test_loop/48/D.npy new file mode 100644 index 0000000..a4757ec Binary files /dev/null and b/test_loop/48/D.npy differ diff --git a/test_loop/48/GenParams.txt b/test_loop/48/GenParams.txt new file mode 100644 index 0000000..bb5aedc --- /dev/null +++ b/test_loop/48/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.395101547241210938e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/48/GlobalConnectivityMetrics/16.npy b/test_loop/48/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8174340 Binary files /dev/null and b/test_loop/48/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/48/GlobalConnectivityMetrics/4.npy b/test_loop/48/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..726893a Binary files /dev/null and b/test_loop/48/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/48/GlobalConnectivityMetrics/8.npy b/test_loop/48/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..91556c9 Binary files /dev/null and b/test_loop/48/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/48/KpostProcess/Kd1.npy b/test_loop/48/KpostProcess/Kd1.npy new file mode 100644 index 0000000..f062d66 Binary files /dev/null and b/test_loop/48/KpostProcess/Kd1.npy differ diff --git a/test_loop/48/KpostProcess/Kd16.npy b/test_loop/48/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c71e9a1 Binary files /dev/null and b/test_loop/48/KpostProcess/Kd16.npy differ diff --git a/test_loop/48/KpostProcess/Kd2.npy b/test_loop/48/KpostProcess/Kd2.npy new file mode 100644 index 0000000..30b880a Binary files /dev/null and b/test_loop/48/KpostProcess/Kd2.npy differ diff --git a/test_loop/48/KpostProcess/Kd4.npy b/test_loop/48/KpostProcess/Kd4.npy new file mode 100644 index 0000000..ccda114 Binary files /dev/null and b/test_loop/48/KpostProcess/Kd4.npy differ diff --git a/test_loop/48/KpostProcess/Kd8.npy b/test_loop/48/KpostProcess/Kd8.npy new file mode 100644 index 0000000..9e09de9 Binary files /dev/null and b/test_loop/48/KpostProcess/Kd8.npy differ diff --git a/test_loop/48/KpostProcess/Kperm2.npy b/test_loop/48/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..c5cc43c Binary files /dev/null and b/test_loop/48/KpostProcess/Kperm2.npy differ diff --git a/test_loop/48/KpostProcess/Kperm4.npy b/test_loop/48/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..c5cc43c Binary files /dev/null and b/test_loop/48/KpostProcess/Kperm4.npy differ diff --git a/test_loop/48/KpostProcess/Kperm8.npy b/test_loop/48/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..c5cc43c Binary files /dev/null and b/test_loop/48/KpostProcess/Kperm8.npy differ diff --git a/test_loop/48/KpostProcess/Kv1.npy b/test_loop/48/KpostProcess/Kv1.npy new file mode 100644 index 0000000..c37e5ff Binary files /dev/null and b/test_loop/48/KpostProcess/Kv1.npy differ diff --git a/test_loop/48/KpostProcess/Kv16.npy b/test_loop/48/KpostProcess/Kv16.npy new file mode 100644 index 0000000..0cf0ea5 Binary files /dev/null and b/test_loop/48/KpostProcess/Kv16.npy differ diff --git a/test_loop/48/KpostProcess/Kv2.npy b/test_loop/48/KpostProcess/Kv2.npy new file mode 100644 index 0000000..0551118 Binary files /dev/null and b/test_loop/48/KpostProcess/Kv2.npy differ diff --git a/test_loop/48/KpostProcess/Kv4.npy b/test_loop/48/KpostProcess/Kv4.npy new file mode 100644 index 0000000..4da34eb Binary files /dev/null and b/test_loop/48/KpostProcess/Kv4.npy differ diff --git a/test_loop/48/KpostProcess/Kv8.npy b/test_loop/48/KpostProcess/Kv8.npy new file mode 100644 index 0000000..7b6ec31 Binary files /dev/null and b/test_loop/48/KpostProcess/Kv8.npy differ diff --git a/test_loop/48/P.npy b/test_loop/48/P.npy new file mode 100644 index 0000000..a96eff6 Binary files /dev/null and b/test_loop/48/P.npy differ diff --git a/test_loop/48/PosKeffSummary.txt b/test_loop/48/PosKeffSummary.txt new file mode 100644 index 0000000..e176476 --- /dev/null +++ b/test_loop/48/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.055813626020084328e+00 +1.087801533296977041e+00 +1.745641231536865234e-01 +9.366613173080205745e-03 diff --git a/test_loop/48/RunTimes.out b/test_loop/48/RunTimes.out new file mode 100644 index 0000000..fe47c23 --- /dev/null +++ b/test_loop/48/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.301966905594 +Solver: 0.292510986328 +Keff: 1.0878170248281955 +N_cores: 1 diff --git a/test_loop/48/SolverRes.txt b/test_loop/48/SolverRes.txt new file mode 100644 index 0000000..4a964a9 --- /dev/null +++ b/test_loop/48/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.087817024828195533e+00 +2.000000000000000000e+00 +5.944778919219970703e-01 +1.000000000000000000e+00 diff --git a/test_loop/48/V.npy b/test_loop/48/V.npy new file mode 100644 index 0000000..41d0f40 Binary files /dev/null and b/test_loop/48/V.npy differ diff --git a/test_loop/48/connec.out b/test_loop/48/connec.out new file mode 100644 index 0000000..0ff4ff3 --- /dev/null +++ b/test_loop/48/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.406250000 + NCC : 1 diff --git a/test_loop/48/k.npy b/test_loop/48/k.npy new file mode 100644 index 0000000..267514c Binary files /dev/null and b/test_loop/48/k.npy differ diff --git a/test_loop/48/lc.txt b/test_loop/48/lc.txt new file mode 100644 index 0000000..ece3c06 --- /dev/null +++ b/test_loop/48/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.242618010307302789e+00 +3.418681900013201158e+00 +2.068733842863161421e+00 diff --git a/test_loop/48/tkperm_sub.txt b/test_loop/48/tkperm_sub.txt new file mode 100644 index 0000000..02dea77 --- /dev/null +++ b/test_loop/48/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.555590152740478516e-01 +2.310276031494140625e-04 +2.360343933105468750e-04 diff --git a/test_loop/49/Cmap.npy b/test_loop/49/Cmap.npy new file mode 100644 index 0000000..789ff95 Binary files /dev/null and b/test_loop/49/Cmap.npy differ diff --git a/test_loop/49/ConnSummary.txt b/test_loop/49/ConnSummary.txt new file mode 100644 index 0000000..31912a6 --- /dev/null +++ b/test_loop/49/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.436690807342529297e-01 +8.145305212632927283e-01 +2.900343546585142790e-02 diff --git a/test_loop/49/ConnectivityMetrics/16.npy b/test_loop/49/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7c24a99 Binary files /dev/null and b/test_loop/49/ConnectivityMetrics/16.npy differ diff --git a/test_loop/49/ConnectivityMetrics/4.npy b/test_loop/49/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..e9bcdbb Binary files /dev/null and b/test_loop/49/ConnectivityMetrics/4.npy differ diff --git a/test_loop/49/ConnectivityMetrics/8.npy b/test_loop/49/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e5966ec Binary files /dev/null and b/test_loop/49/ConnectivityMetrics/8.npy differ diff --git a/test_loop/49/D.npy b/test_loop/49/D.npy new file mode 100644 index 0000000..941646b Binary files /dev/null and b/test_loop/49/D.npy differ diff --git a/test_loop/49/GenParams.txt b/test_loop/49/GenParams.txt new file mode 100644 index 0000000..a07f9d2 --- /dev/null +++ b/test_loop/49/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.003929138183593750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/49/GlobalConnectivityMetrics/16.npy b/test_loop/49/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7c24a99 Binary files /dev/null and b/test_loop/49/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/49/GlobalConnectivityMetrics/4.npy b/test_loop/49/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..4177f3c Binary files /dev/null and b/test_loop/49/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/49/GlobalConnectivityMetrics/8.npy b/test_loop/49/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..1d1f5be Binary files /dev/null and b/test_loop/49/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/49/KpostProcess/Kd16.npy b/test_loop/49/KpostProcess/Kd16.npy new file mode 100644 index 0000000..1a43345 Binary files /dev/null and b/test_loop/49/KpostProcess/Kd16.npy differ diff --git a/test_loop/49/KpostProcess/Kd4.npy b/test_loop/49/KpostProcess/Kd4.npy new file mode 100644 index 0000000..1d93559 Binary files /dev/null and b/test_loop/49/KpostProcess/Kd4.npy differ diff --git a/test_loop/49/KpostProcess/Kd8.npy b/test_loop/49/KpostProcess/Kd8.npy new file mode 100644 index 0000000..4314752 Binary files /dev/null and b/test_loop/49/KpostProcess/Kd8.npy differ diff --git a/test_loop/49/KpostProcess/Kperm4.npy b/test_loop/49/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..ce15848 Binary files /dev/null and b/test_loop/49/KpostProcess/Kperm4.npy differ diff --git a/test_loop/49/KpostProcess/Kperm8.npy b/test_loop/49/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..ce15848 Binary files /dev/null and b/test_loop/49/KpostProcess/Kperm8.npy differ diff --git a/test_loop/49/KpostProcess/Kv16.npy b/test_loop/49/KpostProcess/Kv16.npy new file mode 100644 index 0000000..00c2a07 Binary files /dev/null and b/test_loop/49/KpostProcess/Kv16.npy differ diff --git a/test_loop/49/KpostProcess/Kv4.npy b/test_loop/49/KpostProcess/Kv4.npy new file mode 100644 index 0000000..742cb7b Binary files /dev/null and b/test_loop/49/KpostProcess/Kv4.npy differ diff --git a/test_loop/49/KpostProcess/Kv8.npy b/test_loop/49/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9e12b5a Binary files /dev/null and b/test_loop/49/KpostProcess/Kv8.npy differ diff --git a/test_loop/49/P.npy b/test_loop/49/P.npy new file mode 100644 index 0000000..bf82ea2 Binary files /dev/null and b/test_loop/49/P.npy differ diff --git a/test_loop/49/PosKeffSummary.txt b/test_loop/49/PosKeffSummary.txt new file mode 100644 index 0000000..d1f19d8 --- /dev/null +++ b/test_loop/49/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +5.505128775491159310e+00 +5.617444132066980345e+00 +4.648923873901367188e-03 +2.617570131801630895e-01 diff --git a/test_loop/49/RunTimes.out b/test_loop/49/RunTimes.out new file mode 100644 index 0000000..8a53c2c --- /dev/null +++ b/test_loop/49/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.297055959702 +Solver: 0.209306001663 +Keff: 5.617606256872019 +N_cores: 1 diff --git a/test_loop/49/SolverRes.txt b/test_loop/49/SolverRes.txt new file mode 100644 index 0000000..457e46d --- /dev/null +++ b/test_loop/49/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.617606256872019088e+00 +2.000000000000000000e+00 +5.063619613647460938e-01 +1.000000000000000000e+00 diff --git a/test_loop/49/V.npy b/test_loop/49/V.npy new file mode 100644 index 0000000..a1d03a1 Binary files /dev/null and b/test_loop/49/V.npy differ diff --git a/test_loop/49/connec.out b/test_loop/49/connec.out new file mode 100644 index 0000000..3ae409e --- /dev/null +++ b/test_loop/49/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.531250000 + NCC : 1 diff --git a/test_loop/49/k.npy b/test_loop/49/k.npy new file mode 100644 index 0000000..4665132 Binary files /dev/null and b/test_loop/49/k.npy differ diff --git a/test_loop/49/lc.txt b/test_loop/49/lc.txt new file mode 100644 index 0000000..e125457 --- /dev/null +++ b/test_loop/49/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.587928286094737018e+01 +8.940950451995377080e+00 +2.405638922166544180e+00 diff --git a/test_loop/49/tkperm_sub.txt b/test_loop/49/tkperm_sub.txt new file mode 100644 index 0000000..da2cdff --- /dev/null +++ b/test_loop/49/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.145089149475097656e-01 +1.909732818603515625e-04 diff --git a/test_loop/5/Cmap.npy b/test_loop/5/Cmap.npy new file mode 100644 index 0000000..21eb8f7 Binary files /dev/null and b/test_loop/5/Cmap.npy differ diff --git a/test_loop/5/ConnSummary.txt b/test_loop/5/ConnSummary.txt new file mode 100644 index 0000000..48b2066 --- /dev/null +++ b/test_loop/5/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.219339847564697266e-01 +8.557531017434045761e-01 +2.894713650188959417e-02 diff --git a/test_loop/5/ConnectivityMetrics/16.npy b/test_loop/5/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..4ed9c98 Binary files /dev/null and b/test_loop/5/ConnectivityMetrics/16.npy differ diff --git a/test_loop/5/ConnectivityMetrics/4.npy b/test_loop/5/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..15435aa Binary files /dev/null and b/test_loop/5/ConnectivityMetrics/4.npy differ diff --git a/test_loop/5/ConnectivityMetrics/8.npy b/test_loop/5/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..67e5113 Binary files /dev/null and b/test_loop/5/ConnectivityMetrics/8.npy differ diff --git a/test_loop/5/D.npy b/test_loop/5/D.npy new file mode 100644 index 0000000..c600966 Binary files /dev/null and b/test_loop/5/D.npy differ diff --git a/test_loop/5/GenParams.txt b/test_loop/5/GenParams.txt new file mode 100644 index 0000000..d0449d2 --- /dev/null +++ b/test_loop/5/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.182981491088867188e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/5/GlobalConnectivityMetrics/16.npy b/test_loop/5/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..4ed9c98 Binary files /dev/null and b/test_loop/5/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/5/GlobalConnectivityMetrics/4.npy b/test_loop/5/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..e49bb2e Binary files /dev/null and b/test_loop/5/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/5/GlobalConnectivityMetrics/8.npy b/test_loop/5/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..619df15 Binary files /dev/null and b/test_loop/5/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/5/KpostProcess/Kd16.npy b/test_loop/5/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f7d9977 Binary files /dev/null and b/test_loop/5/KpostProcess/Kd16.npy differ diff --git a/test_loop/5/KpostProcess/Kd4.npy b/test_loop/5/KpostProcess/Kd4.npy new file mode 100644 index 0000000..e8c6d58 Binary files /dev/null and b/test_loop/5/KpostProcess/Kd4.npy differ diff --git a/test_loop/5/KpostProcess/Kd8.npy b/test_loop/5/KpostProcess/Kd8.npy new file mode 100644 index 0000000..ce5cc88 Binary files /dev/null and b/test_loop/5/KpostProcess/Kd8.npy differ diff --git a/test_loop/5/KpostProcess/Kperm4.npy b/test_loop/5/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e1b182d Binary files /dev/null and b/test_loop/5/KpostProcess/Kperm4.npy differ diff --git a/test_loop/5/KpostProcess/Kperm8.npy b/test_loop/5/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e1b182d Binary files /dev/null and b/test_loop/5/KpostProcess/Kperm8.npy differ diff --git a/test_loop/5/KpostProcess/Kv16.npy b/test_loop/5/KpostProcess/Kv16.npy new file mode 100644 index 0000000..06647ff Binary files /dev/null and b/test_loop/5/KpostProcess/Kv16.npy differ diff --git a/test_loop/5/KpostProcess/Kv4.npy b/test_loop/5/KpostProcess/Kv4.npy new file mode 100644 index 0000000..f01cf07 Binary files /dev/null and b/test_loop/5/KpostProcess/Kv4.npy differ diff --git a/test_loop/5/KpostProcess/Kv8.npy b/test_loop/5/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c8fe773 Binary files /dev/null and b/test_loop/5/KpostProcess/Kv8.npy differ diff --git a/test_loop/5/P.npy b/test_loop/5/P.npy new file mode 100644 index 0000000..8fafc8c Binary files /dev/null and b/test_loop/5/P.npy differ diff --git a/test_loop/5/PosKeffSummary.txt b/test_loop/5/PosKeffSummary.txt new file mode 100644 index 0000000..87873ec --- /dev/null +++ b/test_loop/5/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.802752239767988124e-02 +2.873606934256274850e-02 +4.594087600708007812e-03 +2.551248118739944948e-01 diff --git a/test_loop/5/RunTimes.out b/test_loop/5/RunTimes.out new file mode 100644 index 0000000..030bbfd --- /dev/null +++ b/test_loop/5/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.290570020676 +Solver: 0.246624946594 +Keff: 0.028823071532182984 +N_cores: 1 diff --git a/test_loop/5/SolverRes.txt b/test_loop/5/SolverRes.txt new file mode 100644 index 0000000..d6b9744 --- /dev/null +++ b/test_loop/5/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.882307153218298390e-02 +2.000000000000000000e+00 +5.371949672698974609e-01 +1.000000000000000000e+00 diff --git a/test_loop/5/V.npy b/test_loop/5/V.npy new file mode 100644 index 0000000..d953f76 Binary files /dev/null and b/test_loop/5/V.npy differ diff --git a/test_loop/5/connec.out b/test_loop/5/connec.out new file mode 100644 index 0000000..a047cb8 --- /dev/null +++ b/test_loop/5/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.171875000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/5/k.npy b/test_loop/5/k.npy new file mode 100644 index 0000000..39242e0 Binary files /dev/null and b/test_loop/5/k.npy differ diff --git a/test_loop/5/lc.txt b/test_loop/5/lc.txt new file mode 100644 index 0000000..9f10698 --- /dev/null +++ b/test_loop/5/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.915878494865971504e+00 +7.915878494865971504e+00 +2.775962449135307875e+00 diff --git a/test_loop/5/tkperm_sub.txt b/test_loop/5/tkperm_sub.txt new file mode 100644 index 0000000..9dd3fe2 --- /dev/null +++ b/test_loop/5/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.003369808197021484e-01 +1.659393310546875000e-04 diff --git a/test_loop/50/Cmap.npy b/test_loop/50/Cmap.npy new file mode 100644 index 0000000..5e3ac75 Binary files /dev/null and b/test_loop/50/Cmap.npy differ diff --git a/test_loop/50/ConnSummary.txt b/test_loop/50/ConnSummary.txt new file mode 100644 index 0000000..4e5c584 --- /dev/null +++ b/test_loop/50/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.082399368286132812e-01 +7.680384142964546967e-01 +4.322304486515084199e-02 diff --git a/test_loop/50/ConnectivityMetrics/16.npy b/test_loop/50/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..3d55dc2 Binary files /dev/null and b/test_loop/50/ConnectivityMetrics/16.npy differ diff --git a/test_loop/50/ConnectivityMetrics/4.npy b/test_loop/50/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..42fd4c0 Binary files /dev/null and b/test_loop/50/ConnectivityMetrics/4.npy differ diff --git a/test_loop/50/ConnectivityMetrics/8.npy b/test_loop/50/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..3783b96 Binary files /dev/null and b/test_loop/50/ConnectivityMetrics/8.npy differ diff --git a/test_loop/50/D.npy b/test_loop/50/D.npy new file mode 100644 index 0000000..ae3553f Binary files /dev/null and b/test_loop/50/D.npy differ diff --git a/test_loop/50/GenParams.txt b/test_loop/50/GenParams.txt new file mode 100644 index 0000000..7635565 --- /dev/null +++ b/test_loop/50/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.079030990600585938e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/50/GlobalConnectivityMetrics/16.npy b/test_loop/50/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..3d55dc2 Binary files /dev/null and b/test_loop/50/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/50/GlobalConnectivityMetrics/4.npy b/test_loop/50/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..b84a3fa Binary files /dev/null and b/test_loop/50/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/50/GlobalConnectivityMetrics/8.npy b/test_loop/50/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..2c40826 Binary files /dev/null and b/test_loop/50/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/50/KpostProcess/Kd1.npy b/test_loop/50/KpostProcess/Kd1.npy new file mode 100644 index 0000000..4688be4 Binary files /dev/null and b/test_loop/50/KpostProcess/Kd1.npy differ diff --git a/test_loop/50/KpostProcess/Kd16.npy b/test_loop/50/KpostProcess/Kd16.npy new file mode 100644 index 0000000..95c5ad9 Binary files /dev/null and b/test_loop/50/KpostProcess/Kd16.npy differ diff --git a/test_loop/50/KpostProcess/Kd2.npy b/test_loop/50/KpostProcess/Kd2.npy new file mode 100644 index 0000000..7373d54 Binary files /dev/null and b/test_loop/50/KpostProcess/Kd2.npy differ diff --git a/test_loop/50/KpostProcess/Kd4.npy b/test_loop/50/KpostProcess/Kd4.npy new file mode 100644 index 0000000..a3c520a Binary files /dev/null and b/test_loop/50/KpostProcess/Kd4.npy differ diff --git a/test_loop/50/KpostProcess/Kd8.npy b/test_loop/50/KpostProcess/Kd8.npy new file mode 100644 index 0000000..4df8635 Binary files /dev/null and b/test_loop/50/KpostProcess/Kd8.npy differ diff --git a/test_loop/50/KpostProcess/Kperm2.npy b/test_loop/50/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..5e395b0 Binary files /dev/null and b/test_loop/50/KpostProcess/Kperm2.npy differ diff --git a/test_loop/50/KpostProcess/Kperm4.npy b/test_loop/50/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..5e395b0 Binary files /dev/null and b/test_loop/50/KpostProcess/Kperm4.npy differ diff --git a/test_loop/50/KpostProcess/Kperm8.npy b/test_loop/50/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..5e395b0 Binary files /dev/null and b/test_loop/50/KpostProcess/Kperm8.npy differ diff --git a/test_loop/50/KpostProcess/Kv1.npy b/test_loop/50/KpostProcess/Kv1.npy new file mode 100644 index 0000000..7ed1ef8 Binary files /dev/null and b/test_loop/50/KpostProcess/Kv1.npy differ diff --git a/test_loop/50/KpostProcess/Kv16.npy b/test_loop/50/KpostProcess/Kv16.npy new file mode 100644 index 0000000..6e3edb9 Binary files /dev/null and b/test_loop/50/KpostProcess/Kv16.npy differ diff --git a/test_loop/50/KpostProcess/Kv2.npy b/test_loop/50/KpostProcess/Kv2.npy new file mode 100644 index 0000000..bc99aa8 Binary files /dev/null and b/test_loop/50/KpostProcess/Kv2.npy differ diff --git a/test_loop/50/KpostProcess/Kv4.npy b/test_loop/50/KpostProcess/Kv4.npy new file mode 100644 index 0000000..f7cd45d Binary files /dev/null and b/test_loop/50/KpostProcess/Kv4.npy differ diff --git a/test_loop/50/KpostProcess/Kv8.npy b/test_loop/50/KpostProcess/Kv8.npy new file mode 100644 index 0000000..398a6e1 Binary files /dev/null and b/test_loop/50/KpostProcess/Kv8.npy differ diff --git a/test_loop/50/P.npy b/test_loop/50/P.npy new file mode 100644 index 0000000..a7b340c Binary files /dev/null and b/test_loop/50/P.npy differ diff --git a/test_loop/50/PosKeffSummary.txt b/test_loop/50/PosKeffSummary.txt new file mode 100644 index 0000000..e77b499 --- /dev/null +++ b/test_loop/50/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.251083568365363163e+00 +1.253999293549240113e+00 +2.343549728393554688e-01 +4.671623144881357527e-03 diff --git a/test_loop/50/RunTimes.out b/test_loop/50/RunTimes.out new file mode 100644 index 0000000..47c27dd --- /dev/null +++ b/test_loop/50/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.305974960327 +Solver: 0.272930860519 +Keff: 1.2540450558872056 +N_cores: 1 diff --git a/test_loop/50/SolverRes.txt b/test_loop/50/SolverRes.txt new file mode 100644 index 0000000..bc45a6b --- /dev/null +++ b/test_loop/50/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.254045055887205606e+00 +2.000000000000000000e+00 +5.789058208465576172e-01 +1.000000000000000000e+00 diff --git a/test_loop/50/V.npy b/test_loop/50/V.npy new file mode 100644 index 0000000..a162d16 Binary files /dev/null and b/test_loop/50/V.npy differ diff --git a/test_loop/50/connec.out b/test_loop/50/connec.out new file mode 100644 index 0000000..0ff4ff3 --- /dev/null +++ b/test_loop/50/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.406250000 + NCC : 1 diff --git a/test_loop/50/k.npy b/test_loop/50/k.npy new file mode 100644 index 0000000..6f7344d Binary files /dev/null and b/test_loop/50/k.npy differ diff --git a/test_loop/50/lc.txt b/test_loop/50/lc.txt new file mode 100644 index 0000000..fc0c31b --- /dev/null +++ b/test_loop/50/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.256590076350274643e+00 +3.380768332149604483e+00 +2.083379339499964011e+00 diff --git a/test_loop/50/tkperm_sub.txt b/test_loop/50/tkperm_sub.txt new file mode 100644 index 0000000..0122260 --- /dev/null +++ b/test_loop/50/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.082230567932128906e-01 +1.618862152099609375e-04 +1.268386840820312500e-04 diff --git a/test_loop/51/Cmap.npy b/test_loop/51/Cmap.npy new file mode 100644 index 0000000..6d68248 Binary files /dev/null and b/test_loop/51/Cmap.npy differ diff --git a/test_loop/51/ConnSummary.txt b/test_loop/51/ConnSummary.txt new file mode 100644 index 0000000..fdfea34 --- /dev/null +++ b/test_loop/51/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.144350528717041016e-01 +7.702972196744954925e-01 +4.805262277326241560e-02 diff --git a/test_loop/51/ConnectivityMetrics/16.npy b/test_loop/51/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..3e50db1 Binary files /dev/null and b/test_loop/51/ConnectivityMetrics/16.npy differ diff --git a/test_loop/51/ConnectivityMetrics/4.npy b/test_loop/51/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..864c5c7 Binary files /dev/null and b/test_loop/51/ConnectivityMetrics/4.npy differ diff --git a/test_loop/51/ConnectivityMetrics/8.npy b/test_loop/51/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b92da2c Binary files /dev/null and b/test_loop/51/ConnectivityMetrics/8.npy differ diff --git a/test_loop/51/D.npy b/test_loop/51/D.npy new file mode 100644 index 0000000..916954e Binary files /dev/null and b/test_loop/51/D.npy differ diff --git a/test_loop/51/GenParams.txt b/test_loop/51/GenParams.txt new file mode 100644 index 0000000..e223a01 --- /dev/null +++ b/test_loop/51/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.690170288085937500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/51/GlobalConnectivityMetrics/16.npy b/test_loop/51/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..3e50db1 Binary files /dev/null and b/test_loop/51/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/51/GlobalConnectivityMetrics/4.npy b/test_loop/51/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..904649e Binary files /dev/null and b/test_loop/51/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/51/GlobalConnectivityMetrics/8.npy b/test_loop/51/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..595d31a Binary files /dev/null and b/test_loop/51/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/51/KpostProcess/Kd16.npy b/test_loop/51/KpostProcess/Kd16.npy new file mode 100644 index 0000000..e8b9f45 Binary files /dev/null and b/test_loop/51/KpostProcess/Kd16.npy differ diff --git a/test_loop/51/KpostProcess/Kd4.npy b/test_loop/51/KpostProcess/Kd4.npy new file mode 100644 index 0000000..2b0dd40 Binary files /dev/null and b/test_loop/51/KpostProcess/Kd4.npy differ diff --git a/test_loop/51/KpostProcess/Kd8.npy b/test_loop/51/KpostProcess/Kd8.npy new file mode 100644 index 0000000..65d07a1 Binary files /dev/null and b/test_loop/51/KpostProcess/Kd8.npy differ diff --git a/test_loop/51/KpostProcess/Kperm4.npy b/test_loop/51/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..48761ad Binary files /dev/null and b/test_loop/51/KpostProcess/Kperm4.npy differ diff --git a/test_loop/51/KpostProcess/Kperm8.npy b/test_loop/51/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..48761ad Binary files /dev/null and b/test_loop/51/KpostProcess/Kperm8.npy differ diff --git a/test_loop/51/KpostProcess/Kv16.npy b/test_loop/51/KpostProcess/Kv16.npy new file mode 100644 index 0000000..ea39b45 Binary files /dev/null and b/test_loop/51/KpostProcess/Kv16.npy differ diff --git a/test_loop/51/KpostProcess/Kv4.npy b/test_loop/51/KpostProcess/Kv4.npy new file mode 100644 index 0000000..9482378 Binary files /dev/null and b/test_loop/51/KpostProcess/Kv4.npy differ diff --git a/test_loop/51/KpostProcess/Kv8.npy b/test_loop/51/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c3363d4 Binary files /dev/null and b/test_loop/51/KpostProcess/Kv8.npy differ diff --git a/test_loop/51/P.npy b/test_loop/51/P.npy new file mode 100644 index 0000000..d3fe4f7 Binary files /dev/null and b/test_loop/51/P.npy differ diff --git a/test_loop/51/PosKeffSummary.txt b/test_loop/51/PosKeffSummary.txt new file mode 100644 index 0000000..7e9a3c3 --- /dev/null +++ b/test_loop/51/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +6.275129980426471299e+00 +6.398342746816656046e+00 +5.913972854614257812e-03 +2.654706712356380005e-01 diff --git a/test_loop/51/RunTimes.out b/test_loop/51/RunTimes.out new file mode 100644 index 0000000..51deba3 --- /dev/null +++ b/test_loop/51/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.393548965454 +Solver: 0.186748981476 +Keff: 6.398203553778103 +N_cores: 1 diff --git a/test_loop/51/SolverRes.txt b/test_loop/51/SolverRes.txt new file mode 100644 index 0000000..b75a4d6 --- /dev/null +++ b/test_loop/51/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +6.398203553778103014e+00 +2.000000000000000000e+00 +5.802979469299316406e-01 +1.000000000000000000e+00 diff --git a/test_loop/51/V.npy b/test_loop/51/V.npy new file mode 100644 index 0000000..d41463f Binary files /dev/null and b/test_loop/51/V.npy differ diff --git a/test_loop/51/connec.out b/test_loop/51/connec.out new file mode 100644 index 0000000..3ae409e --- /dev/null +++ b/test_loop/51/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.531250000 + NCC : 1 diff --git a/test_loop/51/k.npy b/test_loop/51/k.npy new file mode 100644 index 0000000..9b19eec Binary files /dev/null and b/test_loop/51/k.npy differ diff --git a/test_loop/51/lc.txt b/test_loop/51/lc.txt new file mode 100644 index 0000000..28234e8 --- /dev/null +++ b/test_loop/51/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.600153029760005907e+01 +8.827072532024386575e+00 +2.504146440327579271e+00 diff --git a/test_loop/51/tkperm_sub.txt b/test_loop/51/tkperm_sub.txt new file mode 100644 index 0000000..d5899bb --- /dev/null +++ b/test_loop/51/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.189589977264404297e-01 +1.759529113769531250e-04 diff --git a/test_loop/52/Cmap.npy b/test_loop/52/Cmap.npy new file mode 100644 index 0000000..b8452ac Binary files /dev/null and b/test_loop/52/Cmap.npy differ diff --git a/test_loop/52/ConnSummary.txt b/test_loop/52/ConnSummary.txt new file mode 100644 index 0000000..fb6dfac --- /dev/null +++ b/test_loop/52/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.443559646606445312e-01 +8.213572104622688386e-01 +3.033860510236274441e-02 diff --git a/test_loop/52/ConnectivityMetrics/16.npy b/test_loop/52/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..e7d5552 Binary files /dev/null and b/test_loop/52/ConnectivityMetrics/16.npy differ diff --git a/test_loop/52/ConnectivityMetrics/4.npy b/test_loop/52/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..e27fd7d Binary files /dev/null and b/test_loop/52/ConnectivityMetrics/4.npy differ diff --git a/test_loop/52/ConnectivityMetrics/8.npy b/test_loop/52/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e29da3d Binary files /dev/null and b/test_loop/52/ConnectivityMetrics/8.npy differ diff --git a/test_loop/52/D.npy b/test_loop/52/D.npy new file mode 100644 index 0000000..9555e32 Binary files /dev/null and b/test_loop/52/D.npy differ diff --git a/test_loop/52/GenParams.txt b/test_loop/52/GenParams.txt new file mode 100644 index 0000000..47f74ab --- /dev/null +++ b/test_loop/52/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.029916763305664062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/52/GlobalConnectivityMetrics/16.npy b/test_loop/52/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..e7d5552 Binary files /dev/null and b/test_loop/52/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/52/GlobalConnectivityMetrics/4.npy b/test_loop/52/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..3567a16 Binary files /dev/null and b/test_loop/52/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/52/GlobalConnectivityMetrics/8.npy b/test_loop/52/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..a88c2b0 Binary files /dev/null and b/test_loop/52/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/52/KpostProcess/Kd1.npy b/test_loop/52/KpostProcess/Kd1.npy new file mode 100644 index 0000000..d86d633 Binary files /dev/null and b/test_loop/52/KpostProcess/Kd1.npy differ diff --git a/test_loop/52/KpostProcess/Kd16.npy b/test_loop/52/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a839752 Binary files /dev/null and b/test_loop/52/KpostProcess/Kd16.npy differ diff --git a/test_loop/52/KpostProcess/Kd2.npy b/test_loop/52/KpostProcess/Kd2.npy new file mode 100644 index 0000000..12e089e Binary files /dev/null and b/test_loop/52/KpostProcess/Kd2.npy differ diff --git a/test_loop/52/KpostProcess/Kd4.npy b/test_loop/52/KpostProcess/Kd4.npy new file mode 100644 index 0000000..e32b102 Binary files /dev/null and b/test_loop/52/KpostProcess/Kd4.npy differ diff --git a/test_loop/52/KpostProcess/Kd8.npy b/test_loop/52/KpostProcess/Kd8.npy new file mode 100644 index 0000000..d71b011 Binary files /dev/null and b/test_loop/52/KpostProcess/Kd8.npy differ diff --git a/test_loop/52/KpostProcess/Kperm2.npy b/test_loop/52/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..f3ed0f8 Binary files /dev/null and b/test_loop/52/KpostProcess/Kperm2.npy differ diff --git a/test_loop/52/KpostProcess/Kperm4.npy b/test_loop/52/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..f3ed0f8 Binary files /dev/null and b/test_loop/52/KpostProcess/Kperm4.npy differ diff --git a/test_loop/52/KpostProcess/Kperm8.npy b/test_loop/52/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..f3ed0f8 Binary files /dev/null and b/test_loop/52/KpostProcess/Kperm8.npy differ diff --git a/test_loop/52/KpostProcess/Kv1.npy b/test_loop/52/KpostProcess/Kv1.npy new file mode 100644 index 0000000..872df0c Binary files /dev/null and b/test_loop/52/KpostProcess/Kv1.npy differ diff --git a/test_loop/52/KpostProcess/Kv16.npy b/test_loop/52/KpostProcess/Kv16.npy new file mode 100644 index 0000000..94e555d Binary files /dev/null and b/test_loop/52/KpostProcess/Kv16.npy differ diff --git a/test_loop/52/KpostProcess/Kv2.npy b/test_loop/52/KpostProcess/Kv2.npy new file mode 100644 index 0000000..3b5ba95 Binary files /dev/null and b/test_loop/52/KpostProcess/Kv2.npy differ diff --git a/test_loop/52/KpostProcess/Kv4.npy b/test_loop/52/KpostProcess/Kv4.npy new file mode 100644 index 0000000..35ddbbf Binary files /dev/null and b/test_loop/52/KpostProcess/Kv4.npy differ diff --git a/test_loop/52/KpostProcess/Kv8.npy b/test_loop/52/KpostProcess/Kv8.npy new file mode 100644 index 0000000..b20e82d Binary files /dev/null and b/test_loop/52/KpostProcess/Kv8.npy differ diff --git a/test_loop/52/P.npy b/test_loop/52/P.npy new file mode 100644 index 0000000..93d0237 Binary files /dev/null and b/test_loop/52/P.npy differ diff --git a/test_loop/52/PosKeffSummary.txt b/test_loop/52/PosKeffSummary.txt new file mode 100644 index 0000000..63c64e3 --- /dev/null +++ b/test_loop/52/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.544382836708332984e+00 +1.545735181668644431e+00 +2.282531261444091797e-01 +5.038841066554692813e-03 diff --git a/test_loop/52/RunTimes.out b/test_loop/52/RunTimes.out new file mode 100644 index 0000000..8d96926 --- /dev/null +++ b/test_loop/52/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.35654091835 +Solver: 0.255537986755 +Keff: 1.5456720172357694 +N_cores: 1 diff --git a/test_loop/52/SolverRes.txt b/test_loop/52/SolverRes.txt new file mode 100644 index 0000000..d86cb74 --- /dev/null +++ b/test_loop/52/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.545672017235769413e+00 +2.000000000000000000e+00 +6.120789051055908203e-01 +1.000000000000000000e+00 diff --git a/test_loop/52/V.npy b/test_loop/52/V.npy new file mode 100644 index 0000000..cf6d67c Binary files /dev/null and b/test_loop/52/V.npy differ diff --git a/test_loop/52/connec.out b/test_loop/52/connec.out new file mode 100644 index 0000000..8e7aaf8 --- /dev/null +++ b/test_loop/52/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.421875000 + NCC : 1 diff --git a/test_loop/52/k.npy b/test_loop/52/k.npy new file mode 100644 index 0000000..aac0e00 Binary files /dev/null and b/test_loop/52/k.npy differ diff --git a/test_loop/52/lc.txt b/test_loop/52/lc.txt new file mode 100644 index 0000000..72ead82 --- /dev/null +++ b/test_loop/52/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.269658164118864896e+00 +3.384809583751116957e+00 +2.121571796208965299e+00 diff --git a/test_loop/52/tkperm_sub.txt b/test_loop/52/tkperm_sub.txt new file mode 100644 index 0000000..4aaa9a4 --- /dev/null +++ b/test_loop/52/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.592149257659912109e-01 +1.881122589111328125e-04 +1.330375671386718750e-04 diff --git a/test_loop/53/Cmap.npy b/test_loop/53/Cmap.npy new file mode 100644 index 0000000..0d504a5 Binary files /dev/null and b/test_loop/53/Cmap.npy differ diff --git a/test_loop/53/ConnSummary.txt b/test_loop/53/ConnSummary.txt new file mode 100644 index 0000000..b060c8d --- /dev/null +++ b/test_loop/53/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.433120250701904297e-01 +7.951137361931449599e-01 +3.524415693545979167e-02 diff --git a/test_loop/53/ConnectivityMetrics/16.npy b/test_loop/53/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..3cc3aea Binary files /dev/null and b/test_loop/53/ConnectivityMetrics/16.npy differ diff --git a/test_loop/53/ConnectivityMetrics/4.npy b/test_loop/53/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1983ccd Binary files /dev/null and b/test_loop/53/ConnectivityMetrics/4.npy differ diff --git a/test_loop/53/ConnectivityMetrics/8.npy b/test_loop/53/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..aeaf56b Binary files /dev/null and b/test_loop/53/ConnectivityMetrics/8.npy differ diff --git a/test_loop/53/D.npy b/test_loop/53/D.npy new file mode 100644 index 0000000..02cefa2 Binary files /dev/null and b/test_loop/53/D.npy differ diff --git a/test_loop/53/GenParams.txt b/test_loop/53/GenParams.txt new file mode 100644 index 0000000..3330acc --- /dev/null +++ b/test_loop/53/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.758834838867187500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/53/GlobalConnectivityMetrics/16.npy b/test_loop/53/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..3cc3aea Binary files /dev/null and b/test_loop/53/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/53/GlobalConnectivityMetrics/4.npy b/test_loop/53/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..23321dd Binary files /dev/null and b/test_loop/53/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/53/GlobalConnectivityMetrics/8.npy b/test_loop/53/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..9f830c9 Binary files /dev/null and b/test_loop/53/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/53/KpostProcess/Kd16.npy b/test_loop/53/KpostProcess/Kd16.npy new file mode 100644 index 0000000..b6c2bcf Binary files /dev/null and b/test_loop/53/KpostProcess/Kd16.npy differ diff --git a/test_loop/53/KpostProcess/Kd4.npy b/test_loop/53/KpostProcess/Kd4.npy new file mode 100644 index 0000000..f242741 Binary files /dev/null and b/test_loop/53/KpostProcess/Kd4.npy differ diff --git a/test_loop/53/KpostProcess/Kd8.npy b/test_loop/53/KpostProcess/Kd8.npy new file mode 100644 index 0000000..67aca62 Binary files /dev/null and b/test_loop/53/KpostProcess/Kd8.npy differ diff --git a/test_loop/53/KpostProcess/Kperm4.npy b/test_loop/53/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..d34b668 Binary files /dev/null and b/test_loop/53/KpostProcess/Kperm4.npy differ diff --git a/test_loop/53/KpostProcess/Kperm8.npy b/test_loop/53/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..d34b668 Binary files /dev/null and b/test_loop/53/KpostProcess/Kperm8.npy differ diff --git a/test_loop/53/KpostProcess/Kv16.npy b/test_loop/53/KpostProcess/Kv16.npy new file mode 100644 index 0000000..fbfd56b Binary files /dev/null and b/test_loop/53/KpostProcess/Kv16.npy differ diff --git a/test_loop/53/KpostProcess/Kv4.npy b/test_loop/53/KpostProcess/Kv4.npy new file mode 100644 index 0000000..c2857e0 Binary files /dev/null and b/test_loop/53/KpostProcess/Kv4.npy differ diff --git a/test_loop/53/KpostProcess/Kv8.npy b/test_loop/53/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c377848 Binary files /dev/null and b/test_loop/53/KpostProcess/Kv8.npy differ diff --git a/test_loop/53/P.npy b/test_loop/53/P.npy new file mode 100644 index 0000000..a8ec220 Binary files /dev/null and b/test_loop/53/P.npy differ diff --git a/test_loop/53/PosKeffSummary.txt b/test_loop/53/PosKeffSummary.txt new file mode 100644 index 0000000..5d81e8c --- /dev/null +++ b/test_loop/53/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +7.658701687996781970e+00 +7.859624469784177059e+00 +4.347801208496093750e-03 +2.405681070410177758e-01 diff --git a/test_loop/53/RunTimes.out b/test_loop/53/RunTimes.out new file mode 100644 index 0000000..1a56ecc --- /dev/null +++ b/test_loop/53/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.294734954834 +Solver: 0.205854892731 +Keff: 7.859719944296679 +N_cores: 1 diff --git a/test_loop/53/SolverRes.txt b/test_loop/53/SolverRes.txt new file mode 100644 index 0000000..1f2dc8e --- /dev/null +++ b/test_loop/53/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +7.859719944296679195e+00 +2.000000000000000000e+00 +5.005898475646972656e-01 +1.000000000000000000e+00 diff --git a/test_loop/53/V.npy b/test_loop/53/V.npy new file mode 100644 index 0000000..31fbb8d Binary files /dev/null and b/test_loop/53/V.npy differ diff --git a/test_loop/53/connec.out b/test_loop/53/connec.out new file mode 100644 index 0000000..3ae409e --- /dev/null +++ b/test_loop/53/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.531250000 + NCC : 1 diff --git a/test_loop/53/k.npy b/test_loop/53/k.npy new file mode 100644 index 0000000..b0752cc Binary files /dev/null and b/test_loop/53/k.npy differ diff --git a/test_loop/53/lc.txt b/test_loop/53/lc.txt new file mode 100644 index 0000000..6b34a69 --- /dev/null +++ b/test_loop/53/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.611595958275793450e+01 +8.354111851221130536e+00 +2.623507751187526882e+00 diff --git a/test_loop/53/tkperm_sub.txt b/test_loop/53/tkperm_sub.txt new file mode 100644 index 0000000..e6fd86a --- /dev/null +++ b/test_loop/53/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.190641403198242188e-01 +1.652240753173828125e-04 diff --git a/test_loop/54/Cmap.npy b/test_loop/54/Cmap.npy new file mode 100644 index 0000000..0dacbb7 Binary files /dev/null and b/test_loop/54/Cmap.npy differ diff --git a/test_loop/54/ConnSummary.txt b/test_loop/54/ConnSummary.txt new file mode 100644 index 0000000..2a6026d --- /dev/null +++ b/test_loop/54/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.723180294036865234e-01 +7.020936658523387885e-01 +4.191045808345847390e-02 diff --git a/test_loop/54/ConnectivityMetrics/16.npy b/test_loop/54/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..9d2f9b5 Binary files /dev/null and b/test_loop/54/ConnectivityMetrics/16.npy differ diff --git a/test_loop/54/ConnectivityMetrics/4.npy b/test_loop/54/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..0927c23 Binary files /dev/null and b/test_loop/54/ConnectivityMetrics/4.npy differ diff --git a/test_loop/54/ConnectivityMetrics/8.npy b/test_loop/54/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..fcb4d1d Binary files /dev/null and b/test_loop/54/ConnectivityMetrics/8.npy differ diff --git a/test_loop/54/D.npy b/test_loop/54/D.npy new file mode 100644 index 0000000..6c83a23 Binary files /dev/null and b/test_loop/54/D.npy differ diff --git a/test_loop/54/GenParams.txt b/test_loop/54/GenParams.txt new file mode 100644 index 0000000..4d16fb9 --- /dev/null +++ b/test_loop/54/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.874944686889648438e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/54/GlobalConnectivityMetrics/16.npy b/test_loop/54/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..9d2f9b5 Binary files /dev/null and b/test_loop/54/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/54/GlobalConnectivityMetrics/4.npy b/test_loop/54/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..6411035 Binary files /dev/null and b/test_loop/54/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/54/GlobalConnectivityMetrics/8.npy b/test_loop/54/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..6ae8c7c Binary files /dev/null and b/test_loop/54/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/54/KpostProcess/Kd1.npy b/test_loop/54/KpostProcess/Kd1.npy new file mode 100644 index 0000000..f959fea Binary files /dev/null and b/test_loop/54/KpostProcess/Kd1.npy differ diff --git a/test_loop/54/KpostProcess/Kd16.npy b/test_loop/54/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c886d4d Binary files /dev/null and b/test_loop/54/KpostProcess/Kd16.npy differ diff --git a/test_loop/54/KpostProcess/Kd2.npy b/test_loop/54/KpostProcess/Kd2.npy new file mode 100644 index 0000000..4e44a93 Binary files /dev/null and b/test_loop/54/KpostProcess/Kd2.npy differ diff --git a/test_loop/54/KpostProcess/Kd4.npy b/test_loop/54/KpostProcess/Kd4.npy new file mode 100644 index 0000000..ec23ddd Binary files /dev/null and b/test_loop/54/KpostProcess/Kd4.npy differ diff --git a/test_loop/54/KpostProcess/Kd8.npy b/test_loop/54/KpostProcess/Kd8.npy new file mode 100644 index 0000000..10c7e4f Binary files /dev/null and b/test_loop/54/KpostProcess/Kd8.npy differ diff --git a/test_loop/54/KpostProcess/Kperm2.npy b/test_loop/54/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..e814756 Binary files /dev/null and b/test_loop/54/KpostProcess/Kperm2.npy differ diff --git a/test_loop/54/KpostProcess/Kperm4.npy b/test_loop/54/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e814756 Binary files /dev/null and b/test_loop/54/KpostProcess/Kperm4.npy differ diff --git a/test_loop/54/KpostProcess/Kperm8.npy b/test_loop/54/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e814756 Binary files /dev/null and b/test_loop/54/KpostProcess/Kperm8.npy differ diff --git a/test_loop/54/KpostProcess/Kv1.npy b/test_loop/54/KpostProcess/Kv1.npy new file mode 100644 index 0000000..2832a76 Binary files /dev/null and b/test_loop/54/KpostProcess/Kv1.npy differ diff --git a/test_loop/54/KpostProcess/Kv16.npy b/test_loop/54/KpostProcess/Kv16.npy new file mode 100644 index 0000000..635646e Binary files /dev/null and b/test_loop/54/KpostProcess/Kv16.npy differ diff --git a/test_loop/54/KpostProcess/Kv2.npy b/test_loop/54/KpostProcess/Kv2.npy new file mode 100644 index 0000000..5bd9fe8 Binary files /dev/null and b/test_loop/54/KpostProcess/Kv2.npy differ diff --git a/test_loop/54/KpostProcess/Kv4.npy b/test_loop/54/KpostProcess/Kv4.npy new file mode 100644 index 0000000..10f7a51 Binary files /dev/null and b/test_loop/54/KpostProcess/Kv4.npy differ diff --git a/test_loop/54/KpostProcess/Kv8.npy b/test_loop/54/KpostProcess/Kv8.npy new file mode 100644 index 0000000..71fe8b8 Binary files /dev/null and b/test_loop/54/KpostProcess/Kv8.npy differ diff --git a/test_loop/54/P.npy b/test_loop/54/P.npy new file mode 100644 index 0000000..7ab986d Binary files /dev/null and b/test_loop/54/P.npy differ diff --git a/test_loop/54/PosKeffSummary.txt b/test_loop/54/PosKeffSummary.txt new file mode 100644 index 0000000..6e86798 --- /dev/null +++ b/test_loop/54/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.855666077660581781e+00 +2.859006073138948612e+00 +1.468129158020019531e-01 +7.676467817947377550e-03 diff --git a/test_loop/54/RunTimes.out b/test_loop/54/RunTimes.out new file mode 100644 index 0000000..277d000 --- /dev/null +++ b/test_loop/54/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.392282009125 +Solver: 0.292154073715 +Keff: 2.8590797678655457 +N_cores: 1 diff --git a/test_loop/54/SolverRes.txt b/test_loop/54/SolverRes.txt new file mode 100644 index 0000000..7dad8c0 --- /dev/null +++ b/test_loop/54/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.859079767865545740e+00 +2.000000000000000000e+00 +6.844360828399658203e-01 +1.000000000000000000e+00 diff --git a/test_loop/54/V.npy b/test_loop/54/V.npy new file mode 100644 index 0000000..db9cce2 Binary files /dev/null and b/test_loop/54/V.npy differ diff --git a/test_loop/54/connec.out b/test_loop/54/connec.out new file mode 100644 index 0000000..8e7aaf8 --- /dev/null +++ b/test_loop/54/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.421875000 + NCC : 1 diff --git a/test_loop/54/k.npy b/test_loop/54/k.npy new file mode 100644 index 0000000..fc940f0 Binary files /dev/null and b/test_loop/54/k.npy differ diff --git a/test_loop/54/lc.txt b/test_loop/54/lc.txt new file mode 100644 index 0000000..b526ab2 --- /dev/null +++ b/test_loop/54/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.281121880258162093e+00 +3.429231610119412021e+00 +2.190558678371495205e+00 diff --git a/test_loop/54/tkperm_sub.txt b/test_loop/54/tkperm_sub.txt new file mode 100644 index 0000000..905f26f --- /dev/null +++ b/test_loop/54/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.752770423889160156e-01 +1.702308654785156250e-04 +1.308917999267578125e-04 diff --git a/test_loop/55/Cmap.npy b/test_loop/55/Cmap.npy new file mode 100644 index 0000000..b02629d Binary files /dev/null and b/test_loop/55/Cmap.npy differ diff --git a/test_loop/55/ConnSummary.txt b/test_loop/55/ConnSummary.txt new file mode 100644 index 0000000..e3c4f1c --- /dev/null +++ b/test_loop/55/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.034168720245361328e-01 +7.923445660390070477e-01 +4.142837133352205575e-02 diff --git a/test_loop/55/ConnectivityMetrics/16.npy b/test_loop/55/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7d02976 Binary files /dev/null and b/test_loop/55/ConnectivityMetrics/16.npy differ diff --git a/test_loop/55/ConnectivityMetrics/4.npy b/test_loop/55/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..6f9e26a Binary files /dev/null and b/test_loop/55/ConnectivityMetrics/4.npy differ diff --git a/test_loop/55/ConnectivityMetrics/8.npy b/test_loop/55/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..9c9b6c2 Binary files /dev/null and b/test_loop/55/ConnectivityMetrics/8.npy differ diff --git a/test_loop/55/D.npy b/test_loop/55/D.npy new file mode 100644 index 0000000..2e11434 Binary files /dev/null and b/test_loop/55/D.npy differ diff --git a/test_loop/55/GenParams.txt b/test_loop/55/GenParams.txt new file mode 100644 index 0000000..ff13fe8 --- /dev/null +++ b/test_loop/55/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +1.946616172790527344e-02 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/55/GlobalConnectivityMetrics/16.npy b/test_loop/55/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7d02976 Binary files /dev/null and b/test_loop/55/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/55/GlobalConnectivityMetrics/4.npy b/test_loop/55/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..5182da2 Binary files /dev/null and b/test_loop/55/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/55/GlobalConnectivityMetrics/8.npy b/test_loop/55/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..80af644 Binary files /dev/null and b/test_loop/55/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/55/KpostProcess/Kd16.npy b/test_loop/55/KpostProcess/Kd16.npy new file mode 100644 index 0000000..9929845 Binary files /dev/null and b/test_loop/55/KpostProcess/Kd16.npy differ diff --git a/test_loop/55/KpostProcess/Kd4.npy b/test_loop/55/KpostProcess/Kd4.npy new file mode 100644 index 0000000..eae71df Binary files /dev/null and b/test_loop/55/KpostProcess/Kd4.npy differ diff --git a/test_loop/55/KpostProcess/Kd8.npy b/test_loop/55/KpostProcess/Kd8.npy new file mode 100644 index 0000000..fb100f2 Binary files /dev/null and b/test_loop/55/KpostProcess/Kd8.npy differ diff --git a/test_loop/55/KpostProcess/Kperm4.npy b/test_loop/55/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..aca79b2 Binary files /dev/null and b/test_loop/55/KpostProcess/Kperm4.npy differ diff --git a/test_loop/55/KpostProcess/Kperm8.npy b/test_loop/55/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..aca79b2 Binary files /dev/null and b/test_loop/55/KpostProcess/Kperm8.npy differ diff --git a/test_loop/55/KpostProcess/Kv16.npy b/test_loop/55/KpostProcess/Kv16.npy new file mode 100644 index 0000000..464ebb4 Binary files /dev/null and b/test_loop/55/KpostProcess/Kv16.npy differ diff --git a/test_loop/55/KpostProcess/Kv4.npy b/test_loop/55/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0b295e7 Binary files /dev/null and b/test_loop/55/KpostProcess/Kv4.npy differ diff --git a/test_loop/55/KpostProcess/Kv8.npy b/test_loop/55/KpostProcess/Kv8.npy new file mode 100644 index 0000000..6acfadd Binary files /dev/null and b/test_loop/55/KpostProcess/Kv8.npy differ diff --git a/test_loop/55/P.npy b/test_loop/55/P.npy new file mode 100644 index 0000000..863cf87 Binary files /dev/null and b/test_loop/55/P.npy differ diff --git a/test_loop/55/PosKeffSummary.txt b/test_loop/55/PosKeffSummary.txt new file mode 100644 index 0000000..309aeed --- /dev/null +++ b/test_loop/55/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +9.883283978839422446e+00 +1.003986186547573922e+01 +4.624128341674804688e-03 +2.400618716163959721e-01 diff --git a/test_loop/55/RunTimes.out b/test_loop/55/RunTimes.out new file mode 100644 index 0000000..9e508d8 --- /dev/null +++ b/test_loop/55/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.293401002884 +Solver: 0.148416042328 +Keff: 10.039875156309272 +N_cores: 1 diff --git a/test_loop/55/SolverRes.txt b/test_loop/55/SolverRes.txt new file mode 100644 index 0000000..22b2e44 --- /dev/null +++ b/test_loop/55/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.003987515630927163e+01 +2.000000000000000000e+00 +4.418170452117919922e-01 +1.000000000000000000e+00 diff --git a/test_loop/55/V.npy b/test_loop/55/V.npy new file mode 100644 index 0000000..e513bf7 Binary files /dev/null and b/test_loop/55/V.npy differ diff --git a/test_loop/55/connec.out b/test_loop/55/connec.out new file mode 100644 index 0000000..f063ff6 --- /dev/null +++ b/test_loop/55/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.562500000 + NCC : 1 diff --git a/test_loop/55/k.npy b/test_loop/55/k.npy new file mode 100644 index 0000000..0eab8da Binary files /dev/null and b/test_loop/55/k.npy differ diff --git a/test_loop/55/lc.txt b/test_loop/55/lc.txt new file mode 100644 index 0000000..a55602d --- /dev/null +++ b/test_loop/55/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.622562085159545830e+01 +8.190789174897748381e+00 +2.708593571066353345e+00 diff --git a/test_loop/55/tkperm_sub.txt b/test_loop/55/tkperm_sub.txt new file mode 100644 index 0000000..f1ded9b --- /dev/null +++ b/test_loop/55/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.796560764312744141e-01 +1.659393310546875000e-04 diff --git a/test_loop/56/Cmap.npy b/test_loop/56/Cmap.npy new file mode 100644 index 0000000..28ef996 Binary files /dev/null and b/test_loop/56/Cmap.npy differ diff --git a/test_loop/56/ConnSummary.txt b/test_loop/56/ConnSummary.txt new file mode 100644 index 0000000..d05dbb7 --- /dev/null +++ b/test_loop/56/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.671410083770751953e-01 +7.942588517054018915e-01 +3.216440537411171391e-02 diff --git a/test_loop/56/ConnectivityMetrics/16.npy b/test_loop/56/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..1e1c78a Binary files /dev/null and b/test_loop/56/ConnectivityMetrics/16.npy differ diff --git a/test_loop/56/ConnectivityMetrics/4.npy b/test_loop/56/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..659112b Binary files /dev/null and b/test_loop/56/ConnectivityMetrics/4.npy differ diff --git a/test_loop/56/ConnectivityMetrics/8.npy b/test_loop/56/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..c3c9b14 Binary files /dev/null and b/test_loop/56/ConnectivityMetrics/8.npy differ diff --git a/test_loop/56/D.npy b/test_loop/56/D.npy new file mode 100644 index 0000000..5d62cdf Binary files /dev/null and b/test_loop/56/D.npy differ diff --git a/test_loop/56/GenParams.txt b/test_loop/56/GenParams.txt new file mode 100644 index 0000000..60a1677 --- /dev/null +++ b/test_loop/56/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.008935928344726562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/56/GlobalConnectivityMetrics/16.npy b/test_loop/56/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..1e1c78a Binary files /dev/null and b/test_loop/56/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/56/GlobalConnectivityMetrics/4.npy b/test_loop/56/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..46034dc Binary files /dev/null and b/test_loop/56/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/56/GlobalConnectivityMetrics/8.npy b/test_loop/56/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..69d50b4 Binary files /dev/null and b/test_loop/56/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/56/KpostProcess/Kd1.npy b/test_loop/56/KpostProcess/Kd1.npy new file mode 100644 index 0000000..967359a Binary files /dev/null and b/test_loop/56/KpostProcess/Kd1.npy differ diff --git a/test_loop/56/KpostProcess/Kd16.npy b/test_loop/56/KpostProcess/Kd16.npy new file mode 100644 index 0000000..7f85eef Binary files /dev/null and b/test_loop/56/KpostProcess/Kd16.npy differ diff --git a/test_loop/56/KpostProcess/Kd2.npy b/test_loop/56/KpostProcess/Kd2.npy new file mode 100644 index 0000000..e713d19 Binary files /dev/null and b/test_loop/56/KpostProcess/Kd2.npy differ diff --git a/test_loop/56/KpostProcess/Kd4.npy b/test_loop/56/KpostProcess/Kd4.npy new file mode 100644 index 0000000..4656f65 Binary files /dev/null and b/test_loop/56/KpostProcess/Kd4.npy differ diff --git a/test_loop/56/KpostProcess/Kd8.npy b/test_loop/56/KpostProcess/Kd8.npy new file mode 100644 index 0000000..3c7e016 Binary files /dev/null and b/test_loop/56/KpostProcess/Kd8.npy differ diff --git a/test_loop/56/KpostProcess/Kperm2.npy b/test_loop/56/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..c356257 Binary files /dev/null and b/test_loop/56/KpostProcess/Kperm2.npy differ diff --git a/test_loop/56/KpostProcess/Kperm4.npy b/test_loop/56/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..c356257 Binary files /dev/null and b/test_loop/56/KpostProcess/Kperm4.npy differ diff --git a/test_loop/56/KpostProcess/Kperm8.npy b/test_loop/56/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..c356257 Binary files /dev/null and b/test_loop/56/KpostProcess/Kperm8.npy differ diff --git a/test_loop/56/KpostProcess/Kv1.npy b/test_loop/56/KpostProcess/Kv1.npy new file mode 100644 index 0000000..96c2aed Binary files /dev/null and b/test_loop/56/KpostProcess/Kv1.npy differ diff --git a/test_loop/56/KpostProcess/Kv16.npy b/test_loop/56/KpostProcess/Kv16.npy new file mode 100644 index 0000000..d46c744 Binary files /dev/null and b/test_loop/56/KpostProcess/Kv16.npy differ diff --git a/test_loop/56/KpostProcess/Kv2.npy b/test_loop/56/KpostProcess/Kv2.npy new file mode 100644 index 0000000..e1c67af Binary files /dev/null and b/test_loop/56/KpostProcess/Kv2.npy differ diff --git a/test_loop/56/KpostProcess/Kv4.npy b/test_loop/56/KpostProcess/Kv4.npy new file mode 100644 index 0000000..de9c0e0 Binary files /dev/null and b/test_loop/56/KpostProcess/Kv4.npy differ diff --git a/test_loop/56/KpostProcess/Kv8.npy b/test_loop/56/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ce56e84 Binary files /dev/null and b/test_loop/56/KpostProcess/Kv8.npy differ diff --git a/test_loop/56/P.npy b/test_loop/56/P.npy new file mode 100644 index 0000000..f91c4d2 Binary files /dev/null and b/test_loop/56/P.npy differ diff --git a/test_loop/56/PosKeffSummary.txt b/test_loop/56/PosKeffSummary.txt new file mode 100644 index 0000000..ed851c9 --- /dev/null +++ b/test_loop/56/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +5.353143627259386861e+00 +5.368051250060258184e+00 +2.559299468994140625e-01 +4.450145698720385339e-03 diff --git a/test_loop/56/RunTimes.out b/test_loop/56/RunTimes.out new file mode 100644 index 0000000..87815cb --- /dev/null +++ b/test_loop/56/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.300236940384 +Solver: 0.225291967392 +Keff: 5.367929777625855 +N_cores: 1 diff --git a/test_loop/56/SolverRes.txt b/test_loop/56/SolverRes.txt new file mode 100644 index 0000000..8638465 --- /dev/null +++ b/test_loop/56/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.367929777625855436e+00 +2.000000000000000000e+00 +5.255289077758789062e-01 +1.000000000000000000e+00 diff --git a/test_loop/56/V.npy b/test_loop/56/V.npy new file mode 100644 index 0000000..010d58e Binary files /dev/null and b/test_loop/56/V.npy differ diff --git a/test_loop/56/connec.out b/test_loop/56/connec.out new file mode 100644 index 0000000..8e7aaf8 --- /dev/null +++ b/test_loop/56/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.421875000 + NCC : 1 diff --git a/test_loop/56/k.npy b/test_loop/56/k.npy new file mode 100644 index 0000000..d62a960 Binary files /dev/null and b/test_loop/56/k.npy differ diff --git a/test_loop/56/lc.txt b/test_loop/56/lc.txt new file mode 100644 index 0000000..59861f7 --- /dev/null +++ b/test_loop/56/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.291474052310277898e+00 +3.466370930338719347e+00 +2.210130742160323347e+00 diff --git a/test_loop/56/tkperm_sub.txt b/test_loop/56/tkperm_sub.txt new file mode 100644 index 0000000..24ea34a --- /dev/null +++ b/test_loop/56/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.167989730834960938e-01 +1.749992370605468750e-04 +1.320838928222656250e-04 diff --git a/test_loop/57/Cmap.npy b/test_loop/57/Cmap.npy new file mode 100644 index 0000000..2ac617b Binary files /dev/null and b/test_loop/57/Cmap.npy differ diff --git a/test_loop/57/ConnSummary.txt b/test_loop/57/ConnSummary.txt new file mode 100644 index 0000000..92a1742 --- /dev/null +++ b/test_loop/57/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.055348873138427734e-01 +7.767377062555680389e-01 +4.503229865395943360e-02 diff --git a/test_loop/57/ConnectivityMetrics/16.npy b/test_loop/57/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..0486ee5 Binary files /dev/null and b/test_loop/57/ConnectivityMetrics/16.npy differ diff --git a/test_loop/57/ConnectivityMetrics/4.npy b/test_loop/57/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..4be8292 Binary files /dev/null and b/test_loop/57/ConnectivityMetrics/4.npy differ diff --git a/test_loop/57/ConnectivityMetrics/8.npy b/test_loop/57/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6d635df Binary files /dev/null and b/test_loop/57/ConnectivityMetrics/8.npy differ diff --git a/test_loop/57/D.npy b/test_loop/57/D.npy new file mode 100644 index 0000000..cbee574 Binary files /dev/null and b/test_loop/57/D.npy differ diff --git a/test_loop/57/GenParams.txt b/test_loop/57/GenParams.txt new file mode 100644 index 0000000..b0566c9 --- /dev/null +++ b/test_loop/57/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.657030105590820312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/57/GlobalConnectivityMetrics/16.npy b/test_loop/57/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..0486ee5 Binary files /dev/null and b/test_loop/57/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/57/GlobalConnectivityMetrics/4.npy b/test_loop/57/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..437fd34 Binary files /dev/null and b/test_loop/57/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/57/GlobalConnectivityMetrics/8.npy b/test_loop/57/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..8f47ccd Binary files /dev/null and b/test_loop/57/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/57/KpostProcess/Kd16.npy b/test_loop/57/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a92a041 Binary files /dev/null and b/test_loop/57/KpostProcess/Kd16.npy differ diff --git a/test_loop/57/KpostProcess/Kd4.npy b/test_loop/57/KpostProcess/Kd4.npy new file mode 100644 index 0000000..35f0d83 Binary files /dev/null and b/test_loop/57/KpostProcess/Kd4.npy differ diff --git a/test_loop/57/KpostProcess/Kd8.npy b/test_loop/57/KpostProcess/Kd8.npy new file mode 100644 index 0000000..40ccc41 Binary files /dev/null and b/test_loop/57/KpostProcess/Kd8.npy differ diff --git a/test_loop/57/KpostProcess/Kperm4.npy b/test_loop/57/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..1dd8be1 Binary files /dev/null and b/test_loop/57/KpostProcess/Kperm4.npy differ diff --git a/test_loop/57/KpostProcess/Kperm8.npy b/test_loop/57/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..1dd8be1 Binary files /dev/null and b/test_loop/57/KpostProcess/Kperm8.npy differ diff --git a/test_loop/57/KpostProcess/Kv16.npy b/test_loop/57/KpostProcess/Kv16.npy new file mode 100644 index 0000000..9e9b4a9 Binary files /dev/null and b/test_loop/57/KpostProcess/Kv16.npy differ diff --git a/test_loop/57/KpostProcess/Kv4.npy b/test_loop/57/KpostProcess/Kv4.npy new file mode 100644 index 0000000..b4e21c5 Binary files /dev/null and b/test_loop/57/KpostProcess/Kv4.npy differ diff --git a/test_loop/57/KpostProcess/Kv8.npy b/test_loop/57/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a5cf368 Binary files /dev/null and b/test_loop/57/KpostProcess/Kv8.npy differ diff --git a/test_loop/57/P.npy b/test_loop/57/P.npy new file mode 100644 index 0000000..ac7793b Binary files /dev/null and b/test_loop/57/P.npy differ diff --git a/test_loop/57/PosKeffSummary.txt b/test_loop/57/PosKeffSummary.txt new file mode 100644 index 0000000..76f9501 --- /dev/null +++ b/test_loop/57/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.138879945712280062e+01 +1.157793307459692045e+01 +4.269123077392578125e-03 +2.427119401317993919e-01 diff --git a/test_loop/57/RunTimes.out b/test_loop/57/RunTimes.out new file mode 100644 index 0000000..ddaff12 --- /dev/null +++ b/test_loop/57/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.369935035706 +Solver: 0.167031049728 +Keff: 11.578376098531914 +N_cores: 1 diff --git a/test_loop/57/SolverRes.txt b/test_loop/57/SolverRes.txt new file mode 100644 index 0000000..4d7bcd4 --- /dev/null +++ b/test_loop/57/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.157837609853191374e+01 +2.000000000000000000e+00 +5.369660854339599609e-01 +1.000000000000000000e+00 diff --git a/test_loop/57/V.npy b/test_loop/57/V.npy new file mode 100644 index 0000000..60a45c8 Binary files /dev/null and b/test_loop/57/V.npy differ diff --git a/test_loop/57/connec.out b/test_loop/57/connec.out new file mode 100644 index 0000000..d675842 --- /dev/null +++ b/test_loop/57/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.578125000 + NCC : 1 diff --git a/test_loop/57/k.npy b/test_loop/57/k.npy new file mode 100644 index 0000000..676db35 Binary files /dev/null and b/test_loop/57/k.npy differ diff --git a/test_loop/57/lc.txt b/test_loop/57/lc.txt new file mode 100644 index 0000000..8cc40bf --- /dev/null +++ b/test_loop/57/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.633131648430550698e+01 +7.984526938037643795e+00 +2.787947979083281513e+00 diff --git a/test_loop/57/tkperm_sub.txt b/test_loop/57/tkperm_sub.txt new file mode 100644 index 0000000..fb444b1 --- /dev/null +++ b/test_loop/57/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.313510417938232422e-01 +1.780986785888671875e-04 diff --git a/test_loop/58/Cmap.npy b/test_loop/58/Cmap.npy new file mode 100644 index 0000000..8f65583 Binary files /dev/null and b/test_loop/58/Cmap.npy differ diff --git a/test_loop/58/ConnSummary.txt b/test_loop/58/ConnSummary.txt new file mode 100644 index 0000000..65ce669 --- /dev/null +++ b/test_loop/58/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.514420986175537109e-01 +7.414655491145174526e-01 +4.163481009867339017e-02 diff --git a/test_loop/58/ConnectivityMetrics/16.npy b/test_loop/58/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..a946c6d Binary files /dev/null and b/test_loop/58/ConnectivityMetrics/16.npy differ diff --git a/test_loop/58/ConnectivityMetrics/4.npy b/test_loop/58/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..d6a6d7d Binary files /dev/null and b/test_loop/58/ConnectivityMetrics/4.npy differ diff --git a/test_loop/58/ConnectivityMetrics/8.npy b/test_loop/58/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..0846e1b Binary files /dev/null and b/test_loop/58/ConnectivityMetrics/8.npy differ diff --git a/test_loop/58/D.npy b/test_loop/58/D.npy new file mode 100644 index 0000000..b280f8e Binary files /dev/null and b/test_loop/58/D.npy differ diff --git a/test_loop/58/GenParams.txt b/test_loop/58/GenParams.txt new file mode 100644 index 0000000..a979cf2 --- /dev/null +++ b/test_loop/58/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.966020584106445312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/58/GlobalConnectivityMetrics/16.npy b/test_loop/58/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..a946c6d Binary files /dev/null and b/test_loop/58/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/58/GlobalConnectivityMetrics/4.npy b/test_loop/58/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..aa457e2 Binary files /dev/null and b/test_loop/58/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/58/GlobalConnectivityMetrics/8.npy b/test_loop/58/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..dd3c445 Binary files /dev/null and b/test_loop/58/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/58/KpostProcess/Kd1.npy b/test_loop/58/KpostProcess/Kd1.npy new file mode 100644 index 0000000..fc366be Binary files /dev/null and b/test_loop/58/KpostProcess/Kd1.npy differ diff --git a/test_loop/58/KpostProcess/Kd16.npy b/test_loop/58/KpostProcess/Kd16.npy new file mode 100644 index 0000000..4ffa309 Binary files /dev/null and b/test_loop/58/KpostProcess/Kd16.npy differ diff --git a/test_loop/58/KpostProcess/Kd2.npy b/test_loop/58/KpostProcess/Kd2.npy new file mode 100644 index 0000000..c469e02 Binary files /dev/null and b/test_loop/58/KpostProcess/Kd2.npy differ diff --git a/test_loop/58/KpostProcess/Kd4.npy b/test_loop/58/KpostProcess/Kd4.npy new file mode 100644 index 0000000..d0d5874 Binary files /dev/null and b/test_loop/58/KpostProcess/Kd4.npy differ diff --git a/test_loop/58/KpostProcess/Kd8.npy b/test_loop/58/KpostProcess/Kd8.npy new file mode 100644 index 0000000..e634787 Binary files /dev/null and b/test_loop/58/KpostProcess/Kd8.npy differ diff --git a/test_loop/58/KpostProcess/Kperm2.npy b/test_loop/58/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..a58f54c Binary files /dev/null and b/test_loop/58/KpostProcess/Kperm2.npy differ diff --git a/test_loop/58/KpostProcess/Kperm4.npy b/test_loop/58/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..a58f54c Binary files /dev/null and b/test_loop/58/KpostProcess/Kperm4.npy differ diff --git a/test_loop/58/KpostProcess/Kperm8.npy b/test_loop/58/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..a58f54c Binary files /dev/null and b/test_loop/58/KpostProcess/Kperm8.npy differ diff --git a/test_loop/58/KpostProcess/Kv1.npy b/test_loop/58/KpostProcess/Kv1.npy new file mode 100644 index 0000000..daf495e Binary files /dev/null and b/test_loop/58/KpostProcess/Kv1.npy differ diff --git a/test_loop/58/KpostProcess/Kv16.npy b/test_loop/58/KpostProcess/Kv16.npy new file mode 100644 index 0000000..9e16f1a Binary files /dev/null and b/test_loop/58/KpostProcess/Kv16.npy differ diff --git a/test_loop/58/KpostProcess/Kv2.npy b/test_loop/58/KpostProcess/Kv2.npy new file mode 100644 index 0000000..0ec6cee Binary files /dev/null and b/test_loop/58/KpostProcess/Kv2.npy differ diff --git a/test_loop/58/KpostProcess/Kv4.npy b/test_loop/58/KpostProcess/Kv4.npy new file mode 100644 index 0000000..72af011 Binary files /dev/null and b/test_loop/58/KpostProcess/Kv4.npy differ diff --git a/test_loop/58/KpostProcess/Kv8.npy b/test_loop/58/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ceed2be Binary files /dev/null and b/test_loop/58/KpostProcess/Kv8.npy differ diff --git a/test_loop/58/P.npy b/test_loop/58/P.npy new file mode 100644 index 0000000..6f73495 Binary files /dev/null and b/test_loop/58/P.npy differ diff --git a/test_loop/58/PosKeffSummary.txt b/test_loop/58/PosKeffSummary.txt new file mode 100644 index 0000000..e6f9466 --- /dev/null +++ b/test_loop/58/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +6.577981127970946140e+00 +6.578243224556509006e+00 +1.620059013366699219e-01 +7.721831576654667774e-03 diff --git a/test_loop/58/RunTimes.out b/test_loop/58/RunTimes.out new file mode 100644 index 0000000..7ac640d --- /dev/null +++ b/test_loop/58/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.361767053604 +Solver: 0.213266134262 +Keff: 6.578189318951549 +N_cores: 1 diff --git a/test_loop/58/SolverRes.txt b/test_loop/58/SolverRes.txt new file mode 100644 index 0000000..550209f --- /dev/null +++ b/test_loop/58/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +6.578189318951548792e+00 +2.000000000000000000e+00 +5.750331878662109375e-01 +1.000000000000000000e+00 diff --git a/test_loop/58/V.npy b/test_loop/58/V.npy new file mode 100644 index 0000000..127e3f0 Binary files /dev/null and b/test_loop/58/V.npy differ diff --git a/test_loop/58/connec.out b/test_loop/58/connec.out new file mode 100644 index 0000000..a6bc3ee --- /dev/null +++ b/test_loop/58/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.437500000 + NCC : 1 diff --git a/test_loop/58/k.npy b/test_loop/58/k.npy new file mode 100644 index 0000000..1abede6 Binary files /dev/null and b/test_loop/58/k.npy differ diff --git a/test_loop/58/lc.txt b/test_loop/58/lc.txt new file mode 100644 index 0000000..d2e3bb7 --- /dev/null +++ b/test_loop/58/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.301359007196801088e+00 +3.510094598007385880e+00 +2.260216548957294513e+00 diff --git a/test_loop/58/tkperm_sub.txt b/test_loop/58/tkperm_sub.txt new file mode 100644 index 0000000..1421915 --- /dev/null +++ b/test_loop/58/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.347229003906250000e-01 +1.819133758544921875e-04 +1.318454742431640625e-04 diff --git a/test_loop/59/Cmap.npy b/test_loop/59/Cmap.npy new file mode 100644 index 0000000..b218c3f Binary files /dev/null and b/test_loop/59/Cmap.npy differ diff --git a/test_loop/59/ConnSummary.txt b/test_loop/59/ConnSummary.txt new file mode 100644 index 0000000..f5d5e58 --- /dev/null +++ b/test_loop/59/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.051861763000488281e-01 +7.947823856087236072e-01 +4.944941787870835159e-02 diff --git a/test_loop/59/ConnectivityMetrics/16.npy b/test_loop/59/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..37f640b Binary files /dev/null and b/test_loop/59/ConnectivityMetrics/16.npy differ diff --git a/test_loop/59/ConnectivityMetrics/4.npy b/test_loop/59/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..2cc033b Binary files /dev/null and b/test_loop/59/ConnectivityMetrics/4.npy differ diff --git a/test_loop/59/ConnectivityMetrics/8.npy b/test_loop/59/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..4f89891 Binary files /dev/null and b/test_loop/59/ConnectivityMetrics/8.npy differ diff --git a/test_loop/59/D.npy b/test_loop/59/D.npy new file mode 100644 index 0000000..aadbc3a Binary files /dev/null and b/test_loop/59/D.npy differ diff --git a/test_loop/59/GenParams.txt b/test_loop/59/GenParams.txt new file mode 100644 index 0000000..ec70e38 --- /dev/null +++ b/test_loop/59/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.864931106567382812e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +2.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/59/GlobalConnectivityMetrics/16.npy b/test_loop/59/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..37f640b Binary files /dev/null and b/test_loop/59/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/59/GlobalConnectivityMetrics/4.npy b/test_loop/59/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..d8540b5 Binary files /dev/null and b/test_loop/59/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/59/GlobalConnectivityMetrics/8.npy b/test_loop/59/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..1243954 Binary files /dev/null and b/test_loop/59/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/59/KpostProcess/Kd16.npy b/test_loop/59/KpostProcess/Kd16.npy new file mode 100644 index 0000000..043533a Binary files /dev/null and b/test_loop/59/KpostProcess/Kd16.npy differ diff --git a/test_loop/59/KpostProcess/Kd4.npy b/test_loop/59/KpostProcess/Kd4.npy new file mode 100644 index 0000000..3eb931b Binary files /dev/null and b/test_loop/59/KpostProcess/Kd4.npy differ diff --git a/test_loop/59/KpostProcess/Kd8.npy b/test_loop/59/KpostProcess/Kd8.npy new file mode 100644 index 0000000..1755d55 Binary files /dev/null and b/test_loop/59/KpostProcess/Kd8.npy differ diff --git a/test_loop/59/KpostProcess/Kperm4.npy b/test_loop/59/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e45cce6 Binary files /dev/null and b/test_loop/59/KpostProcess/Kperm4.npy differ diff --git a/test_loop/59/KpostProcess/Kperm8.npy b/test_loop/59/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e45cce6 Binary files /dev/null and b/test_loop/59/KpostProcess/Kperm8.npy differ diff --git a/test_loop/59/KpostProcess/Kv16.npy b/test_loop/59/KpostProcess/Kv16.npy new file mode 100644 index 0000000..a0dabb4 Binary files /dev/null and b/test_loop/59/KpostProcess/Kv16.npy differ diff --git a/test_loop/59/KpostProcess/Kv4.npy b/test_loop/59/KpostProcess/Kv4.npy new file mode 100644 index 0000000..9708306 Binary files /dev/null and b/test_loop/59/KpostProcess/Kv4.npy differ diff --git a/test_loop/59/KpostProcess/Kv8.npy b/test_loop/59/KpostProcess/Kv8.npy new file mode 100644 index 0000000..e31245f Binary files /dev/null and b/test_loop/59/KpostProcess/Kv8.npy differ diff --git a/test_loop/59/P.npy b/test_loop/59/P.npy new file mode 100644 index 0000000..f9aa483 Binary files /dev/null and b/test_loop/59/P.npy differ diff --git a/test_loop/59/PosKeffSummary.txt b/test_loop/59/PosKeffSummary.txt new file mode 100644 index 0000000..e82f69c --- /dev/null +++ b/test_loop/59/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.321255576722913361e+01 +1.342598848962817115e+01 +4.639863967895507812e-03 +2.370381789219464519e-01 diff --git a/test_loop/59/RunTimes.out b/test_loop/59/RunTimes.out new file mode 100644 index 0000000..7979ee9 --- /dev/null +++ b/test_loop/59/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.38031578064 +Solver: 0.147198200226 +Keff: 13.426051164162068 +N_cores: 1 diff --git a/test_loop/59/SolverRes.txt b/test_loop/59/SolverRes.txt new file mode 100644 index 0000000..a86ffa8 --- /dev/null +++ b/test_loop/59/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.342605116416206812e+01 +2.000000000000000000e+00 +5.275139808654785156e-01 +1.000000000000000000e+00 diff --git a/test_loop/59/V.npy b/test_loop/59/V.npy new file mode 100644 index 0000000..72f0925 Binary files /dev/null and b/test_loop/59/V.npy differ diff --git a/test_loop/59/connec.out b/test_loop/59/connec.out new file mode 100644 index 0000000..d675842 --- /dev/null +++ b/test_loop/59/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.578125000 + NCC : 1 diff --git a/test_loop/59/k.npy b/test_loop/59/k.npy new file mode 100644 index 0000000..39b63de Binary files /dev/null and b/test_loop/59/k.npy differ diff --git a/test_loop/59/lc.txt b/test_loop/59/lc.txt new file mode 100644 index 0000000..aab55f9 --- /dev/null +++ b/test_loop/59/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.643577184534625601e+01 +8.182455723326857111e+00 +3.048077645092917010e+00 diff --git a/test_loop/59/tkperm_sub.txt b/test_loop/59/tkperm_sub.txt new file mode 100644 index 0000000..65cd4b8 --- /dev/null +++ b/test_loop/59/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.987519741058349609e-01 +1.671314239501953125e-04 diff --git a/test_loop/6/Cmap.npy b/test_loop/6/Cmap.npy new file mode 100644 index 0000000..3590e27 Binary files /dev/null and b/test_loop/6/Cmap.npy differ diff --git a/test_loop/6/ConnSummary.txt b/test_loop/6/ConnSummary.txt new file mode 100644 index 0000000..abf29f2 --- /dev/null +++ b/test_loop/6/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.426020622253417969e-01 +8.675955845714853343e-01 +2.909345920052305856e-02 diff --git a/test_loop/6/ConnectivityMetrics/16.npy b/test_loop/6/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..92a4707 Binary files /dev/null and b/test_loop/6/ConnectivityMetrics/16.npy differ diff --git a/test_loop/6/ConnectivityMetrics/4.npy b/test_loop/6/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..d0a9361 Binary files /dev/null and b/test_loop/6/ConnectivityMetrics/4.npy differ diff --git a/test_loop/6/ConnectivityMetrics/8.npy b/test_loop/6/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..23a9e49 Binary files /dev/null and b/test_loop/6/ConnectivityMetrics/8.npy differ diff --git a/test_loop/6/D.npy b/test_loop/6/D.npy new file mode 100644 index 0000000..65c5c8f Binary files /dev/null and b/test_loop/6/D.npy differ diff --git a/test_loop/6/GenParams.txt b/test_loop/6/GenParams.txt new file mode 100644 index 0000000..1fda888 --- /dev/null +++ b/test_loop/6/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.069089889526367188e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/6/GlobalConnectivityMetrics/16.npy b/test_loop/6/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..92a4707 Binary files /dev/null and b/test_loop/6/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/6/GlobalConnectivityMetrics/4.npy b/test_loop/6/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..1b110fb Binary files /dev/null and b/test_loop/6/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/6/GlobalConnectivityMetrics/8.npy b/test_loop/6/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..46f8434 Binary files /dev/null and b/test_loop/6/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/6/KpostProcess/Kd1.npy b/test_loop/6/KpostProcess/Kd1.npy new file mode 100644 index 0000000..4bb6d0c Binary files /dev/null and b/test_loop/6/KpostProcess/Kd1.npy differ diff --git a/test_loop/6/KpostProcess/Kd16.npy b/test_loop/6/KpostProcess/Kd16.npy new file mode 100644 index 0000000..21eff7c Binary files /dev/null and b/test_loop/6/KpostProcess/Kd16.npy differ diff --git a/test_loop/6/KpostProcess/Kd2.npy b/test_loop/6/KpostProcess/Kd2.npy new file mode 100644 index 0000000..2430885 Binary files /dev/null and b/test_loop/6/KpostProcess/Kd2.npy differ diff --git a/test_loop/6/KpostProcess/Kd4.npy b/test_loop/6/KpostProcess/Kd4.npy new file mode 100644 index 0000000..bc6b2cf Binary files /dev/null and b/test_loop/6/KpostProcess/Kd4.npy differ diff --git a/test_loop/6/KpostProcess/Kd8.npy b/test_loop/6/KpostProcess/Kd8.npy new file mode 100644 index 0000000..1a2858c Binary files /dev/null and b/test_loop/6/KpostProcess/Kd8.npy differ diff --git a/test_loop/6/KpostProcess/Kperm2.npy b/test_loop/6/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..ff42727 Binary files /dev/null and b/test_loop/6/KpostProcess/Kperm2.npy differ diff --git a/test_loop/6/KpostProcess/Kperm4.npy b/test_loop/6/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..ff42727 Binary files /dev/null and b/test_loop/6/KpostProcess/Kperm4.npy differ diff --git a/test_loop/6/KpostProcess/Kperm8.npy b/test_loop/6/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..ff42727 Binary files /dev/null and b/test_loop/6/KpostProcess/Kperm8.npy differ diff --git a/test_loop/6/KpostProcess/Kv1.npy b/test_loop/6/KpostProcess/Kv1.npy new file mode 100644 index 0000000..23e111f Binary files /dev/null and b/test_loop/6/KpostProcess/Kv1.npy differ diff --git a/test_loop/6/KpostProcess/Kv16.npy b/test_loop/6/KpostProcess/Kv16.npy new file mode 100644 index 0000000..7b5fc79 Binary files /dev/null and b/test_loop/6/KpostProcess/Kv16.npy differ diff --git a/test_loop/6/KpostProcess/Kv2.npy b/test_loop/6/KpostProcess/Kv2.npy new file mode 100644 index 0000000..2db0bd5 Binary files /dev/null and b/test_loop/6/KpostProcess/Kv2.npy differ diff --git a/test_loop/6/KpostProcess/Kv4.npy b/test_loop/6/KpostProcess/Kv4.npy new file mode 100644 index 0000000..8894452 Binary files /dev/null and b/test_loop/6/KpostProcess/Kv4.npy differ diff --git a/test_loop/6/KpostProcess/Kv8.npy b/test_loop/6/KpostProcess/Kv8.npy new file mode 100644 index 0000000..9974eed Binary files /dev/null and b/test_loop/6/KpostProcess/Kv8.npy differ diff --git a/test_loop/6/P.npy b/test_loop/6/P.npy new file mode 100644 index 0000000..3a86b17 Binary files /dev/null and b/test_loop/6/P.npy differ diff --git a/test_loop/6/PosKeffSummary.txt b/test_loop/6/PosKeffSummary.txt new file mode 100644 index 0000000..4b0eb9d --- /dev/null +++ b/test_loop/6/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.402776619670836583e-02 +3.417093280099107316e-02 +1.490380764007568359e-01 +7.723428319130522419e-03 diff --git a/test_loop/6/RunTimes.out b/test_loop/6/RunTimes.out new file mode 100644 index 0000000..c191937 --- /dev/null +++ b/test_loop/6/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.370156049728 +Solver: 0.225583076477 +Keff: 0.0336964380629983 +N_cores: 1 diff --git a/test_loop/6/SolverRes.txt b/test_loop/6/SolverRes.txt new file mode 100644 index 0000000..82169ae --- /dev/null +++ b/test_loop/6/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.369643806299830319e-02 +2.000000000000000000e+00 +5.957391262054443359e-01 +1.000000000000000000e+00 diff --git a/test_loop/6/V.npy b/test_loop/6/V.npy new file mode 100644 index 0000000..e1cd498 Binary files /dev/null and b/test_loop/6/V.npy differ diff --git a/test_loop/6/connec.out b/test_loop/6/connec.out new file mode 100644 index 0000000..e6ae057 --- /dev/null +++ b/test_loop/6/connec.out @@ -0,0 +1,4 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.00000000 diff --git a/test_loop/6/k.npy b/test_loop/6/k.npy new file mode 100644 index 0000000..98f07e5 Binary files /dev/null and b/test_loop/6/k.npy differ diff --git a/test_loop/6/lc.txt b/test_loop/6/lc.txt new file mode 100644 index 0000000..d35ff26 --- /dev/null +++ b/test_loop/6/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.439358374379583694e+00 +4.439358374379583694e+00 +4.718372351707160739e+00 diff --git a/test_loop/6/tkperm_sub.txt b/test_loop/6/tkperm_sub.txt new file mode 100644 index 0000000..e6f623e --- /dev/null +++ b/test_loop/6/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.908541202545166016e-01 +1.928806304931640625e-04 +1.258850097656250000e-04 diff --git a/test_loop/60/Cmap.npy b/test_loop/60/Cmap.npy new file mode 100644 index 0000000..f131aa2 Binary files /dev/null and b/test_loop/60/Cmap.npy differ diff --git a/test_loop/60/ConnSummary.txt b/test_loop/60/ConnSummary.txt new file mode 100644 index 0000000..ca4a244 --- /dev/null +++ b/test_loop/60/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.242460727691650391e-01 +8.657262462930274127e-01 +2.504696763040928711e-02 diff --git a/test_loop/60/ConnectivityMetrics/16.npy b/test_loop/60/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..b8c707f Binary files /dev/null and b/test_loop/60/ConnectivityMetrics/16.npy differ diff --git a/test_loop/60/ConnectivityMetrics/4.npy b/test_loop/60/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1365209 Binary files /dev/null and b/test_loop/60/ConnectivityMetrics/4.npy differ diff --git a/test_loop/60/ConnectivityMetrics/8.npy b/test_loop/60/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..1c161a0 Binary files /dev/null and b/test_loop/60/ConnectivityMetrics/8.npy differ diff --git a/test_loop/60/D.npy b/test_loop/60/D.npy new file mode 100644 index 0000000..4d99db6 Binary files /dev/null and b/test_loop/60/D.npy differ diff --git a/test_loop/60/GenParams.txt b/test_loop/60/GenParams.txt new file mode 100644 index 0000000..4c15f09 --- /dev/null +++ b/test_loop/60/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.933834075927734375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/60/GlobalConnectivityMetrics/16.npy b/test_loop/60/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..b8c707f Binary files /dev/null and b/test_loop/60/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/60/GlobalConnectivityMetrics/4.npy b/test_loop/60/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..930f391 Binary files /dev/null and b/test_loop/60/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/60/GlobalConnectivityMetrics/8.npy b/test_loop/60/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..401ea37 Binary files /dev/null and b/test_loop/60/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/60/KpostProcess/Kd1.npy b/test_loop/60/KpostProcess/Kd1.npy new file mode 100644 index 0000000..2458832 Binary files /dev/null and b/test_loop/60/KpostProcess/Kd1.npy differ diff --git a/test_loop/60/KpostProcess/Kd16.npy b/test_loop/60/KpostProcess/Kd16.npy new file mode 100644 index 0000000..7b46fb5 Binary files /dev/null and b/test_loop/60/KpostProcess/Kd16.npy differ diff --git a/test_loop/60/KpostProcess/Kd2.npy b/test_loop/60/KpostProcess/Kd2.npy new file mode 100644 index 0000000..765e3bb Binary files /dev/null and b/test_loop/60/KpostProcess/Kd2.npy differ diff --git a/test_loop/60/KpostProcess/Kd4.npy b/test_loop/60/KpostProcess/Kd4.npy new file mode 100644 index 0000000..b632fc5 Binary files /dev/null and b/test_loop/60/KpostProcess/Kd4.npy differ diff --git a/test_loop/60/KpostProcess/Kd8.npy b/test_loop/60/KpostProcess/Kd8.npy new file mode 100644 index 0000000..8c52a44 Binary files /dev/null and b/test_loop/60/KpostProcess/Kd8.npy differ diff --git a/test_loop/60/KpostProcess/Kperm2.npy b/test_loop/60/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..d3ba5a7 Binary files /dev/null and b/test_loop/60/KpostProcess/Kperm2.npy differ diff --git a/test_loop/60/KpostProcess/Kperm4.npy b/test_loop/60/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..d3ba5a7 Binary files /dev/null and b/test_loop/60/KpostProcess/Kperm4.npy differ diff --git a/test_loop/60/KpostProcess/Kperm8.npy b/test_loop/60/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..d3ba5a7 Binary files /dev/null and b/test_loop/60/KpostProcess/Kperm8.npy differ diff --git a/test_loop/60/KpostProcess/Kv1.npy b/test_loop/60/KpostProcess/Kv1.npy new file mode 100644 index 0000000..b246994 Binary files /dev/null and b/test_loop/60/KpostProcess/Kv1.npy differ diff --git a/test_loop/60/KpostProcess/Kv16.npy b/test_loop/60/KpostProcess/Kv16.npy new file mode 100644 index 0000000..b0e7fdc Binary files /dev/null and b/test_loop/60/KpostProcess/Kv16.npy differ diff --git a/test_loop/60/KpostProcess/Kv2.npy b/test_loop/60/KpostProcess/Kv2.npy new file mode 100644 index 0000000..404a0c2 Binary files /dev/null and b/test_loop/60/KpostProcess/Kv2.npy differ diff --git a/test_loop/60/KpostProcess/Kv4.npy b/test_loop/60/KpostProcess/Kv4.npy new file mode 100644 index 0000000..b8c15c4 Binary files /dev/null and b/test_loop/60/KpostProcess/Kv4.npy differ diff --git a/test_loop/60/KpostProcess/Kv8.npy b/test_loop/60/KpostProcess/Kv8.npy new file mode 100644 index 0000000..4962c38 Binary files /dev/null and b/test_loop/60/KpostProcess/Kv8.npy differ diff --git a/test_loop/60/P.npy b/test_loop/60/P.npy new file mode 100644 index 0000000..b3ab43c Binary files /dev/null and b/test_loop/60/P.npy differ diff --git a/test_loop/60/PosKeffSummary.txt b/test_loop/60/PosKeffSummary.txt new file mode 100644 index 0000000..a2f0489 --- /dev/null +++ b/test_loop/60/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.958244440856282340e-02 +2.030876942404596236e-02 +1.500298976898193359e-01 +1.119072704764719796e-02 diff --git a/test_loop/60/RunTimes.out b/test_loop/60/RunTimes.out new file mode 100644 index 0000000..5112863 --- /dev/null +++ b/test_loop/60/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.417757987976 +Solver: 0.250325918198 +Keff: 0.020283124059475847 +N_cores: 1 diff --git a/test_loop/60/SolverRes.txt b/test_loop/60/SolverRes.txt new file mode 100644 index 0000000..fc36a2f --- /dev/null +++ b/test_loop/60/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.028312405947584746e-02 +2.000000000000000000e+00 +6.680839061737060547e-01 +1.000000000000000000e+00 diff --git a/test_loop/60/V.npy b/test_loop/60/V.npy new file mode 100644 index 0000000..040b7d4 Binary files /dev/null and b/test_loop/60/V.npy differ diff --git a/test_loop/60/connec.out b/test_loop/60/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/60/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/60/k.npy b/test_loop/60/k.npy new file mode 100644 index 0000000..972db3e Binary files /dev/null and b/test_loop/60/k.npy differ diff --git a/test_loop/60/lc.txt b/test_loop/60/lc.txt new file mode 100644 index 0000000..402904b --- /dev/null +++ b/test_loop/60/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.893124093490272664e+00 +2.706762342668124433e+00 +1.984231946019272996e+00 diff --git a/test_loop/60/tkperm_sub.txt b/test_loop/60/tkperm_sub.txt new file mode 100644 index 0000000..abbd212 --- /dev/null +++ b/test_loop/60/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.662881851196289062e-01 +1.709461212158203125e-04 +1.339912414550781250e-04 diff --git a/test_loop/61/Cmap.npy b/test_loop/61/Cmap.npy new file mode 100644 index 0000000..18b7065 Binary files /dev/null and b/test_loop/61/Cmap.npy differ diff --git a/test_loop/61/ConnSummary.txt b/test_loop/61/ConnSummary.txt new file mode 100644 index 0000000..7978618 --- /dev/null +++ b/test_loop/61/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.756879806518554688e-01 +8.242714943012660056e-01 +3.561984382361491064e-02 diff --git a/test_loop/61/ConnectivityMetrics/16.npy b/test_loop/61/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..542c457 Binary files /dev/null and b/test_loop/61/ConnectivityMetrics/16.npy differ diff --git a/test_loop/61/ConnectivityMetrics/4.npy b/test_loop/61/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..eeb625a Binary files /dev/null and b/test_loop/61/ConnectivityMetrics/4.npy differ diff --git a/test_loop/61/ConnectivityMetrics/8.npy b/test_loop/61/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..ec1765f Binary files /dev/null and b/test_loop/61/ConnectivityMetrics/8.npy differ diff --git a/test_loop/61/D.npy b/test_loop/61/D.npy new file mode 100644 index 0000000..ee00ea8 Binary files /dev/null and b/test_loop/61/D.npy differ diff --git a/test_loop/61/GenParams.txt b/test_loop/61/GenParams.txt new file mode 100644 index 0000000..7d4d13d --- /dev/null +++ b/test_loop/61/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.871129989624023438e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.000000000000000056e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/61/GlobalConnectivityMetrics/16.npy b/test_loop/61/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..542c457 Binary files /dev/null and b/test_loop/61/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/61/GlobalConnectivityMetrics/4.npy b/test_loop/61/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..2b414d7 Binary files /dev/null and b/test_loop/61/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/61/GlobalConnectivityMetrics/8.npy b/test_loop/61/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..8716964 Binary files /dev/null and b/test_loop/61/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/61/KpostProcess/Kd16.npy b/test_loop/61/KpostProcess/Kd16.npy new file mode 100644 index 0000000..d9d04ac Binary files /dev/null and b/test_loop/61/KpostProcess/Kd16.npy differ diff --git a/test_loop/61/KpostProcess/Kd4.npy b/test_loop/61/KpostProcess/Kd4.npy new file mode 100644 index 0000000..e17d026 Binary files /dev/null and b/test_loop/61/KpostProcess/Kd4.npy differ diff --git a/test_loop/61/KpostProcess/Kd8.npy b/test_loop/61/KpostProcess/Kd8.npy new file mode 100644 index 0000000..abcfa71 Binary files /dev/null and b/test_loop/61/KpostProcess/Kd8.npy differ diff --git a/test_loop/61/KpostProcess/Kperm4.npy b/test_loop/61/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..5b8f480 Binary files /dev/null and b/test_loop/61/KpostProcess/Kperm4.npy differ diff --git a/test_loop/61/KpostProcess/Kperm8.npy b/test_loop/61/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..5b8f480 Binary files /dev/null and b/test_loop/61/KpostProcess/Kperm8.npy differ diff --git a/test_loop/61/KpostProcess/Kv16.npy b/test_loop/61/KpostProcess/Kv16.npy new file mode 100644 index 0000000..ef893aa Binary files /dev/null and b/test_loop/61/KpostProcess/Kv16.npy differ diff --git a/test_loop/61/KpostProcess/Kv4.npy b/test_loop/61/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0602054 Binary files /dev/null and b/test_loop/61/KpostProcess/Kv4.npy differ diff --git a/test_loop/61/KpostProcess/Kv8.npy b/test_loop/61/KpostProcess/Kv8.npy new file mode 100644 index 0000000..17a63ab Binary files /dev/null and b/test_loop/61/KpostProcess/Kv8.npy differ diff --git a/test_loop/61/P.npy b/test_loop/61/P.npy new file mode 100644 index 0000000..6472c1e Binary files /dev/null and b/test_loop/61/P.npy differ diff --git a/test_loop/61/PosKeffSummary.txt b/test_loop/61/PosKeffSummary.txt new file mode 100644 index 0000000..64b9730 --- /dev/null +++ b/test_loop/61/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.960805057715989119e-02 +2.023880343338416155e-02 +6.137132644653320312e-03 +1.960296802766015312e-01 diff --git a/test_loop/61/RunTimes.out b/test_loop/61/RunTimes.out new file mode 100644 index 0000000..b314102 --- /dev/null +++ b/test_loop/61/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.333890914917 +Solver: 0.136315107346 +Keff: 0.020259080634132308 +N_cores: 1 diff --git a/test_loop/61/SolverRes.txt b/test_loop/61/SolverRes.txt new file mode 100644 index 0000000..a82db9a --- /dev/null +++ b/test_loop/61/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.025908063413230792e-02 +2.000000000000000000e+00 +4.702060222625732422e-01 +1.000000000000000000e+00 diff --git a/test_loop/61/V.npy b/test_loop/61/V.npy new file mode 100644 index 0000000..0de6586 Binary files /dev/null and b/test_loop/61/V.npy differ diff --git a/test_loop/61/connec.out b/test_loop/61/connec.out new file mode 100644 index 0000000..da7804e --- /dev/null +++ b/test_loop/61/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 1.56250000E-02 + NCC : 1 diff --git a/test_loop/61/k.npy b/test_loop/61/k.npy new file mode 100644 index 0000000..c874aec Binary files /dev/null and b/test_loop/61/k.npy differ diff --git a/test_loop/61/lc.txt b/test_loop/61/lc.txt new file mode 100644 index 0000000..7931d2c --- /dev/null +++ b/test_loop/61/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.501980021709811197e+01 +6.734681489676300536e+00 +1.131474051574391737e+01 diff --git a/test_loop/61/tkperm_sub.txt b/test_loop/61/tkperm_sub.txt new file mode 100644 index 0000000..1ec8e03 --- /dev/null +++ b/test_loop/61/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.449459075927734375e-01 +2.191066741943359375e-04 diff --git a/test_loop/62/Cmap.npy b/test_loop/62/Cmap.npy new file mode 100644 index 0000000..7f321dd Binary files /dev/null and b/test_loop/62/Cmap.npy differ diff --git a/test_loop/62/ConnSummary.txt b/test_loop/62/ConnSummary.txt new file mode 100644 index 0000000..a5379ce --- /dev/null +++ b/test_loop/62/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.490650653839111328e-01 +8.052510612430289205e-01 +3.528278754307297843e-02 diff --git a/test_loop/62/ConnectivityMetrics/16.npy b/test_loop/62/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8a6b7d2 Binary files /dev/null and b/test_loop/62/ConnectivityMetrics/16.npy differ diff --git a/test_loop/62/ConnectivityMetrics/4.npy b/test_loop/62/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1cb03cb Binary files /dev/null and b/test_loop/62/ConnectivityMetrics/4.npy differ diff --git a/test_loop/62/ConnectivityMetrics/8.npy b/test_loop/62/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..722f951 Binary files /dev/null and b/test_loop/62/ConnectivityMetrics/8.npy differ diff --git a/test_loop/62/D.npy b/test_loop/62/D.npy new file mode 100644 index 0000000..8c4c7f3 Binary files /dev/null and b/test_loop/62/D.npy differ diff --git a/test_loop/62/GenParams.txt b/test_loop/62/GenParams.txt new file mode 100644 index 0000000..6903712 --- /dev/null +++ b/test_loop/62/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.920005798339843750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/62/GlobalConnectivityMetrics/16.npy b/test_loop/62/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8a6b7d2 Binary files /dev/null and b/test_loop/62/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/62/GlobalConnectivityMetrics/4.npy b/test_loop/62/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..de87d8c Binary files /dev/null and b/test_loop/62/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/62/GlobalConnectivityMetrics/8.npy b/test_loop/62/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..7d1ebe5 Binary files /dev/null and b/test_loop/62/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/62/KpostProcess/Kd1.npy b/test_loop/62/KpostProcess/Kd1.npy new file mode 100644 index 0000000..0595481 Binary files /dev/null and b/test_loop/62/KpostProcess/Kd1.npy differ diff --git a/test_loop/62/KpostProcess/Kd16.npy b/test_loop/62/KpostProcess/Kd16.npy new file mode 100644 index 0000000..4eeca15 Binary files /dev/null and b/test_loop/62/KpostProcess/Kd16.npy differ diff --git a/test_loop/62/KpostProcess/Kd2.npy b/test_loop/62/KpostProcess/Kd2.npy new file mode 100644 index 0000000..17e66cc Binary files /dev/null and b/test_loop/62/KpostProcess/Kd2.npy differ diff --git a/test_loop/62/KpostProcess/Kd4.npy b/test_loop/62/KpostProcess/Kd4.npy new file mode 100644 index 0000000..8ae1201 Binary files /dev/null and b/test_loop/62/KpostProcess/Kd4.npy differ diff --git a/test_loop/62/KpostProcess/Kd8.npy b/test_loop/62/KpostProcess/Kd8.npy new file mode 100644 index 0000000..ae08311 Binary files /dev/null and b/test_loop/62/KpostProcess/Kd8.npy differ diff --git a/test_loop/62/KpostProcess/Kperm2.npy b/test_loop/62/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..1864754 Binary files /dev/null and b/test_loop/62/KpostProcess/Kperm2.npy differ diff --git a/test_loop/62/KpostProcess/Kperm4.npy b/test_loop/62/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..1864754 Binary files /dev/null and b/test_loop/62/KpostProcess/Kperm4.npy differ diff --git a/test_loop/62/KpostProcess/Kperm8.npy b/test_loop/62/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..1864754 Binary files /dev/null and b/test_loop/62/KpostProcess/Kperm8.npy differ diff --git a/test_loop/62/KpostProcess/Kv1.npy b/test_loop/62/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6e5c34b Binary files /dev/null and b/test_loop/62/KpostProcess/Kv1.npy differ diff --git a/test_loop/62/KpostProcess/Kv16.npy b/test_loop/62/KpostProcess/Kv16.npy new file mode 100644 index 0000000..6d477b4 Binary files /dev/null and b/test_loop/62/KpostProcess/Kv16.npy differ diff --git a/test_loop/62/KpostProcess/Kv2.npy b/test_loop/62/KpostProcess/Kv2.npy new file mode 100644 index 0000000..57acdeb Binary files /dev/null and b/test_loop/62/KpostProcess/Kv2.npy differ diff --git a/test_loop/62/KpostProcess/Kv4.npy b/test_loop/62/KpostProcess/Kv4.npy new file mode 100644 index 0000000..5418ebc Binary files /dev/null and b/test_loop/62/KpostProcess/Kv4.npy differ diff --git a/test_loop/62/KpostProcess/Kv8.npy b/test_loop/62/KpostProcess/Kv8.npy new file mode 100644 index 0000000..876b4e7 Binary files /dev/null and b/test_loop/62/KpostProcess/Kv8.npy differ diff --git a/test_loop/62/P.npy b/test_loop/62/P.npy new file mode 100644 index 0000000..1fe2325 Binary files /dev/null and b/test_loop/62/P.npy differ diff --git a/test_loop/62/PosKeffSummary.txt b/test_loop/62/PosKeffSummary.txt new file mode 100644 index 0000000..8362dd5 --- /dev/null +++ b/test_loop/62/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.213686431010673458e-02 +2.316781383366559033e-02 +1.704940795898437500e-01 +7.836622365418176306e-03 diff --git a/test_loop/62/RunTimes.out b/test_loop/62/RunTimes.out new file mode 100644 index 0000000..6a54d7a --- /dev/null +++ b/test_loop/62/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.297878980637 +Solver: 0.229266881943 +Keff: 0.023209078077977438 +N_cores: 1 diff --git a/test_loop/62/SolverRes.txt b/test_loop/62/SolverRes.txt new file mode 100644 index 0000000..96c4fe7 --- /dev/null +++ b/test_loop/62/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.320907807797743805e-02 +2.000000000000000000e+00 +5.271458625793457031e-01 +1.000000000000000000e+00 diff --git a/test_loop/62/V.npy b/test_loop/62/V.npy new file mode 100644 index 0000000..9aa9793 Binary files /dev/null and b/test_loop/62/V.npy differ diff --git a/test_loop/62/connec.out b/test_loop/62/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/62/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/62/k.npy b/test_loop/62/k.npy new file mode 100644 index 0000000..6d1e67d Binary files /dev/null and b/test_loop/62/k.npy differ diff --git a/test_loop/62/lc.txt b/test_loop/62/lc.txt new file mode 100644 index 0000000..106c429 --- /dev/null +++ b/test_loop/62/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.857472089200923548e+00 +2.692653750871510709e+00 +2.046205985108954462e+00 diff --git a/test_loop/62/tkperm_sub.txt b/test_loop/62/tkperm_sub.txt new file mode 100644 index 0000000..7dc789d --- /dev/null +++ b/test_loop/62/tkperm_sub.txt @@ -0,0 +1,3 @@ +6.050851345062255859e-01 +1.668930053710937500e-04 +1.280307769775390625e-04 diff --git a/test_loop/63/Cmap.npy b/test_loop/63/Cmap.npy new file mode 100644 index 0000000..8fcdb63 Binary files /dev/null and b/test_loop/63/Cmap.npy differ diff --git a/test_loop/63/ConnSummary.txt b/test_loop/63/ConnSummary.txt new file mode 100644 index 0000000..52212ee --- /dev/null +++ b/test_loop/63/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.478441238403320312e-01 +8.074277363937698571e-01 +3.410982039310085645e-02 diff --git a/test_loop/63/ConnectivityMetrics/16.npy b/test_loop/63/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c97074e Binary files /dev/null and b/test_loop/63/ConnectivityMetrics/16.npy differ diff --git a/test_loop/63/ConnectivityMetrics/4.npy b/test_loop/63/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..e99a26f Binary files /dev/null and b/test_loop/63/ConnectivityMetrics/4.npy differ diff --git a/test_loop/63/ConnectivityMetrics/8.npy b/test_loop/63/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..3c8db01 Binary files /dev/null and b/test_loop/63/ConnectivityMetrics/8.npy differ diff --git a/test_loop/63/D.npy b/test_loop/63/D.npy new file mode 100644 index 0000000..440047c Binary files /dev/null and b/test_loop/63/D.npy differ diff --git a/test_loop/63/GenParams.txt b/test_loop/63/GenParams.txt new file mode 100644 index 0000000..defc6d0 --- /dev/null +++ b/test_loop/63/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.084037780761718750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.207142857142857184e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/63/GlobalConnectivityMetrics/16.npy b/test_loop/63/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c97074e Binary files /dev/null and b/test_loop/63/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/63/GlobalConnectivityMetrics/4.npy b/test_loop/63/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..35b2ebe Binary files /dev/null and b/test_loop/63/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/63/GlobalConnectivityMetrics/8.npy b/test_loop/63/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..f38f915 Binary files /dev/null and b/test_loop/63/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/63/KpostProcess/Kd16.npy b/test_loop/63/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f2ed48e Binary files /dev/null and b/test_loop/63/KpostProcess/Kd16.npy differ diff --git a/test_loop/63/KpostProcess/Kd4.npy b/test_loop/63/KpostProcess/Kd4.npy new file mode 100644 index 0000000..d99984d Binary files /dev/null and b/test_loop/63/KpostProcess/Kd4.npy differ diff --git a/test_loop/63/KpostProcess/Kd8.npy b/test_loop/63/KpostProcess/Kd8.npy new file mode 100644 index 0000000..85eea75 Binary files /dev/null and b/test_loop/63/KpostProcess/Kd8.npy differ diff --git a/test_loop/63/KpostProcess/Kperm4.npy b/test_loop/63/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..c68e38b Binary files /dev/null and b/test_loop/63/KpostProcess/Kperm4.npy differ diff --git a/test_loop/63/KpostProcess/Kperm8.npy b/test_loop/63/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..c68e38b Binary files /dev/null and b/test_loop/63/KpostProcess/Kperm8.npy differ diff --git a/test_loop/63/KpostProcess/Kv16.npy b/test_loop/63/KpostProcess/Kv16.npy new file mode 100644 index 0000000..dfe28f7 Binary files /dev/null and b/test_loop/63/KpostProcess/Kv16.npy differ diff --git a/test_loop/63/KpostProcess/Kv4.npy b/test_loop/63/KpostProcess/Kv4.npy new file mode 100644 index 0000000..78bec9c Binary files /dev/null and b/test_loop/63/KpostProcess/Kv4.npy differ diff --git a/test_loop/63/KpostProcess/Kv8.npy b/test_loop/63/KpostProcess/Kv8.npy new file mode 100644 index 0000000..d0044b2 Binary files /dev/null and b/test_loop/63/KpostProcess/Kv8.npy differ diff --git a/test_loop/63/P.npy b/test_loop/63/P.npy new file mode 100644 index 0000000..45ab5d2 Binary files /dev/null and b/test_loop/63/P.npy differ diff --git a/test_loop/63/PosKeffSummary.txt b/test_loop/63/PosKeffSummary.txt new file mode 100644 index 0000000..0f38331 --- /dev/null +++ b/test_loop/63/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.207649217405719191e-02 +2.323593269631284153e-02 +4.213809967041015625e-03 +2.439176191015050288e-01 diff --git a/test_loop/63/RunTimes.out b/test_loop/63/RunTimes.out new file mode 100644 index 0000000..52c1d95 --- /dev/null +++ b/test_loop/63/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.370266914368 +Solver: 0.159137010574 +Keff: 0.023950724599525318 +N_cores: 1 diff --git a/test_loop/63/SolverRes.txt b/test_loop/63/SolverRes.txt new file mode 100644 index 0000000..9efcc40 --- /dev/null +++ b/test_loop/63/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.395072459952531790e-02 +2.000000000000000000e+00 +5.294039249420166016e-01 +1.000000000000000000e+00 diff --git a/test_loop/63/V.npy b/test_loop/63/V.npy new file mode 100644 index 0000000..9698654 Binary files /dev/null and b/test_loop/63/V.npy differ diff --git a/test_loop/63/connec.out b/test_loop/63/connec.out new file mode 100644 index 0000000..fcefaf4 --- /dev/null +++ b/test_loop/63/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 3.12500000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/63/k.npy b/test_loop/63/k.npy new file mode 100644 index 0000000..9c1dc5f Binary files /dev/null and b/test_loop/63/k.npy differ diff --git a/test_loop/63/lc.txt b/test_loop/63/lc.txt new file mode 100644 index 0000000..f092e37 --- /dev/null +++ b/test_loop/63/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.488007770725832124e+01 +6.760106746737907457e+00 +9.145439827577192204e+00 diff --git a/test_loop/63/tkperm_sub.txt b/test_loop/63/tkperm_sub.txt new file mode 100644 index 0000000..c1c7643 --- /dev/null +++ b/test_loop/63/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.319220542907714844e-01 +1.590251922607421875e-04 diff --git a/test_loop/64/Cmap.npy b/test_loop/64/Cmap.npy new file mode 100644 index 0000000..a40463d Binary files /dev/null and b/test_loop/64/Cmap.npy differ diff --git a/test_loop/64/ConnSummary.txt b/test_loop/64/ConnSummary.txt new file mode 100644 index 0000000..97dc240 --- /dev/null +++ b/test_loop/64/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.949339389801025391e-01 +8.177114869967696542e-01 +3.522122002592254636e-02 diff --git a/test_loop/64/ConnectivityMetrics/16.npy b/test_loop/64/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..482f456 Binary files /dev/null and b/test_loop/64/ConnectivityMetrics/16.npy differ diff --git a/test_loop/64/ConnectivityMetrics/4.npy b/test_loop/64/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..b37b0a3 Binary files /dev/null and b/test_loop/64/ConnectivityMetrics/4.npy differ diff --git a/test_loop/64/ConnectivityMetrics/8.npy b/test_loop/64/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..2a58eff Binary files /dev/null and b/test_loop/64/ConnectivityMetrics/8.npy differ diff --git a/test_loop/64/D.npy b/test_loop/64/D.npy new file mode 100644 index 0000000..4f0b59d Binary files /dev/null and b/test_loop/64/D.npy differ diff --git a/test_loop/64/GenParams.txt b/test_loop/64/GenParams.txt new file mode 100644 index 0000000..a79b8d6 --- /dev/null +++ b/test_loop/64/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +7.706880569458007812e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/64/GlobalConnectivityMetrics/16.npy b/test_loop/64/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..482f456 Binary files /dev/null and b/test_loop/64/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/64/GlobalConnectivityMetrics/4.npy b/test_loop/64/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..5e6f5d4 Binary files /dev/null and b/test_loop/64/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/64/GlobalConnectivityMetrics/8.npy b/test_loop/64/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..2b7bf5f Binary files /dev/null and b/test_loop/64/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/64/KpostProcess/Kd1.npy b/test_loop/64/KpostProcess/Kd1.npy new file mode 100644 index 0000000..1e955a6 Binary files /dev/null and b/test_loop/64/KpostProcess/Kd1.npy differ diff --git a/test_loop/64/KpostProcess/Kd16.npy b/test_loop/64/KpostProcess/Kd16.npy new file mode 100644 index 0000000..e9d437d Binary files /dev/null and b/test_loop/64/KpostProcess/Kd16.npy differ diff --git a/test_loop/64/KpostProcess/Kd2.npy b/test_loop/64/KpostProcess/Kd2.npy new file mode 100644 index 0000000..ac434b9 Binary files /dev/null and b/test_loop/64/KpostProcess/Kd2.npy differ diff --git a/test_loop/64/KpostProcess/Kd4.npy b/test_loop/64/KpostProcess/Kd4.npy new file mode 100644 index 0000000..b45bafa Binary files /dev/null and b/test_loop/64/KpostProcess/Kd4.npy differ diff --git a/test_loop/64/KpostProcess/Kd8.npy b/test_loop/64/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2a2b8ed Binary files /dev/null and b/test_loop/64/KpostProcess/Kd8.npy differ diff --git a/test_loop/64/KpostProcess/Kperm2.npy b/test_loop/64/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..066ccd1 Binary files /dev/null and b/test_loop/64/KpostProcess/Kperm2.npy differ diff --git a/test_loop/64/KpostProcess/Kperm4.npy b/test_loop/64/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..066ccd1 Binary files /dev/null and b/test_loop/64/KpostProcess/Kperm4.npy differ diff --git a/test_loop/64/KpostProcess/Kperm8.npy b/test_loop/64/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..066ccd1 Binary files /dev/null and b/test_loop/64/KpostProcess/Kperm8.npy differ diff --git a/test_loop/64/KpostProcess/Kv1.npy b/test_loop/64/KpostProcess/Kv1.npy new file mode 100644 index 0000000..bac691b Binary files /dev/null and b/test_loop/64/KpostProcess/Kv1.npy differ diff --git a/test_loop/64/KpostProcess/Kv16.npy b/test_loop/64/KpostProcess/Kv16.npy new file mode 100644 index 0000000..a01b2db Binary files /dev/null and b/test_loop/64/KpostProcess/Kv16.npy differ diff --git a/test_loop/64/KpostProcess/Kv2.npy b/test_loop/64/KpostProcess/Kv2.npy new file mode 100644 index 0000000..adee72e Binary files /dev/null and b/test_loop/64/KpostProcess/Kv2.npy differ diff --git a/test_loop/64/KpostProcess/Kv4.npy b/test_loop/64/KpostProcess/Kv4.npy new file mode 100644 index 0000000..8ea6bc6 Binary files /dev/null and b/test_loop/64/KpostProcess/Kv4.npy differ diff --git a/test_loop/64/KpostProcess/Kv8.npy b/test_loop/64/KpostProcess/Kv8.npy new file mode 100644 index 0000000..f241c42 Binary files /dev/null and b/test_loop/64/KpostProcess/Kv8.npy differ diff --git a/test_loop/64/P.npy b/test_loop/64/P.npy new file mode 100644 index 0000000..c235b0a Binary files /dev/null and b/test_loop/64/P.npy differ diff --git a/test_loop/64/PosKeffSummary.txt b/test_loop/64/PosKeffSummary.txt new file mode 100644 index 0000000..29bb376 --- /dev/null +++ b/test_loop/64/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.490653878229147702e-02 +2.584730381956726677e-02 +1.993269920349121094e-01 +7.665919491697746092e-03 diff --git a/test_loop/64/RunTimes.out b/test_loop/64/RunTimes.out new file mode 100644 index 0000000..2069a78 --- /dev/null +++ b/test_loop/64/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.369637966156 +Solver: 0.247856855392 +Keff: 0.025910270237570567 +N_cores: 1 diff --git a/test_loop/64/SolverRes.txt b/test_loop/64/SolverRes.txt new file mode 100644 index 0000000..d2df699 --- /dev/null +++ b/test_loop/64/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.591027023757056652e-02 +2.000000000000000000e+00 +6.174948215484619141e-01 +1.000000000000000000e+00 diff --git a/test_loop/64/V.npy b/test_loop/64/V.npy new file mode 100644 index 0000000..626c034 Binary files /dev/null and b/test_loop/64/V.npy differ diff --git a/test_loop/64/connec.out b/test_loop/64/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/64/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/64/k.npy b/test_loop/64/k.npy new file mode 100644 index 0000000..6dbc7bb Binary files /dev/null and b/test_loop/64/k.npy differ diff --git a/test_loop/64/lc.txt b/test_loop/64/lc.txt new file mode 100644 index 0000000..85e5221 --- /dev/null +++ b/test_loop/64/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.835783777297509189e+00 +2.683425639747740288e+00 +1.946000018970353462e+00 diff --git a/test_loop/64/tkperm_sub.txt b/test_loop/64/tkperm_sub.txt new file mode 100644 index 0000000..786d070 --- /dev/null +++ b/test_loop/64/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.498760700225830078e-01 +1.859664916992187500e-04 +1.399517059326171875e-04 diff --git a/test_loop/65/Cmap.npy b/test_loop/65/Cmap.npy new file mode 100644 index 0000000..a5d4973 Binary files /dev/null and b/test_loop/65/Cmap.npy differ diff --git a/test_loop/65/ConnSummary.txt b/test_loop/65/ConnSummary.txt new file mode 100644 index 0000000..30ec305 --- /dev/null +++ b/test_loop/65/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.084808826446533203e-01 +8.132426852850037635e-01 +4.571022002658039346e-02 diff --git a/test_loop/65/ConnectivityMetrics/16.npy b/test_loop/65/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..cf76828 Binary files /dev/null and b/test_loop/65/ConnectivityMetrics/16.npy differ diff --git a/test_loop/65/ConnectivityMetrics/4.npy b/test_loop/65/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..9247eb8 Binary files /dev/null and b/test_loop/65/ConnectivityMetrics/4.npy differ diff --git a/test_loop/65/ConnectivityMetrics/8.npy b/test_loop/65/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..888a53e Binary files /dev/null and b/test_loop/65/ConnectivityMetrics/8.npy differ diff --git a/test_loop/65/D.npy b/test_loop/65/D.npy new file mode 100644 index 0000000..2068d0c Binary files /dev/null and b/test_loop/65/D.npy differ diff --git a/test_loop/65/GenParams.txt b/test_loop/65/GenParams.txt new file mode 100644 index 0000000..2bf5ac5 --- /dev/null +++ b/test_loop/65/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.984140396118164062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.414285714285714313e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/65/GlobalConnectivityMetrics/16.npy b/test_loop/65/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..cf76828 Binary files /dev/null and b/test_loop/65/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/65/GlobalConnectivityMetrics/4.npy b/test_loop/65/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..999954e Binary files /dev/null and b/test_loop/65/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/65/GlobalConnectivityMetrics/8.npy b/test_loop/65/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..016a283 Binary files /dev/null and b/test_loop/65/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/65/KpostProcess/Kd16.npy b/test_loop/65/KpostProcess/Kd16.npy new file mode 100644 index 0000000..4124afe Binary files /dev/null and b/test_loop/65/KpostProcess/Kd16.npy differ diff --git a/test_loop/65/KpostProcess/Kd4.npy b/test_loop/65/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0028df5 Binary files /dev/null and b/test_loop/65/KpostProcess/Kd4.npy differ diff --git a/test_loop/65/KpostProcess/Kd8.npy b/test_loop/65/KpostProcess/Kd8.npy new file mode 100644 index 0000000..acae006 Binary files /dev/null and b/test_loop/65/KpostProcess/Kd8.npy differ diff --git a/test_loop/65/KpostProcess/Kperm4.npy b/test_loop/65/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9ea3be2 Binary files /dev/null and b/test_loop/65/KpostProcess/Kperm4.npy differ diff --git a/test_loop/65/KpostProcess/Kperm8.npy b/test_loop/65/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9ea3be2 Binary files /dev/null and b/test_loop/65/KpostProcess/Kperm8.npy differ diff --git a/test_loop/65/KpostProcess/Kv16.npy b/test_loop/65/KpostProcess/Kv16.npy new file mode 100644 index 0000000..dc9e86a Binary files /dev/null and b/test_loop/65/KpostProcess/Kv16.npy differ diff --git a/test_loop/65/KpostProcess/Kv4.npy b/test_loop/65/KpostProcess/Kv4.npy new file mode 100644 index 0000000..8151021 Binary files /dev/null and b/test_loop/65/KpostProcess/Kv4.npy differ diff --git a/test_loop/65/KpostProcess/Kv8.npy b/test_loop/65/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a7e1f73 Binary files /dev/null and b/test_loop/65/KpostProcess/Kv8.npy differ diff --git a/test_loop/65/P.npy b/test_loop/65/P.npy new file mode 100644 index 0000000..26b4fc9 Binary files /dev/null and b/test_loop/65/P.npy differ diff --git a/test_loop/65/PosKeffSummary.txt b/test_loop/65/PosKeffSummary.txt new file mode 100644 index 0000000..10cae92 --- /dev/null +++ b/test_loop/65/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.538379082438566026e-02 +2.646470580578762916e-02 +4.657983779907226562e-03 +2.391359983620822138e-01 diff --git a/test_loop/65/RunTimes.out b/test_loop/65/RunTimes.out new file mode 100644 index 0000000..a9cdc6c --- /dev/null +++ b/test_loop/65/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.354308128357 +Solver: 0.170210838318 +Keff: 0.026446680255864975 +N_cores: 1 diff --git a/test_loop/65/SolverRes.txt b/test_loop/65/SolverRes.txt new file mode 100644 index 0000000..5380f73 --- /dev/null +++ b/test_loop/65/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.644668025586497523e-02 +2.000000000000000000e+00 +5.245189666748046875e-01 +1.000000000000000000e+00 diff --git a/test_loop/65/V.npy b/test_loop/65/V.npy new file mode 100644 index 0000000..ddbb11f Binary files /dev/null and b/test_loop/65/V.npy differ diff --git a/test_loop/65/connec.out b/test_loop/65/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/65/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/65/k.npy b/test_loop/65/k.npy new file mode 100644 index 0000000..b5565dd Binary files /dev/null and b/test_loop/65/k.npy differ diff --git a/test_loop/65/lc.txt b/test_loop/65/lc.txt new file mode 100644 index 0000000..0beb74d --- /dev/null +++ b/test_loop/65/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.479502147200739159e+01 +6.741665897059082369e+00 +7.354858628349455252e+00 diff --git a/test_loop/65/tkperm_sub.txt b/test_loop/65/tkperm_sub.txt new file mode 100644 index 0000000..8c89ccf --- /dev/null +++ b/test_loop/65/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.202950000762939453e-01 +1.621246337890625000e-04 diff --git a/test_loop/66/Cmap.npy b/test_loop/66/Cmap.npy new file mode 100644 index 0000000..fd5e836 Binary files /dev/null and b/test_loop/66/Cmap.npy differ diff --git a/test_loop/66/ConnSummary.txt b/test_loop/66/ConnSummary.txt new file mode 100644 index 0000000..936176c --- /dev/null +++ b/test_loop/66/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.082291126251220703e-01 +7.375193971395315184e-01 +7.167582525082684397e-02 diff --git a/test_loop/66/ConnectivityMetrics/16.npy b/test_loop/66/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8cbcc3e Binary files /dev/null and b/test_loop/66/ConnectivityMetrics/16.npy differ diff --git a/test_loop/66/ConnectivityMetrics/4.npy b/test_loop/66/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..82dc572 Binary files /dev/null and b/test_loop/66/ConnectivityMetrics/4.npy differ diff --git a/test_loop/66/ConnectivityMetrics/8.npy b/test_loop/66/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6155a93 Binary files /dev/null and b/test_loop/66/ConnectivityMetrics/8.npy differ diff --git a/test_loop/66/D.npy b/test_loop/66/D.npy new file mode 100644 index 0000000..7cafce7 Binary files /dev/null and b/test_loop/66/D.npy differ diff --git a/test_loop/66/GenParams.txt b/test_loop/66/GenParams.txt new file mode 100644 index 0000000..6aaba9b --- /dev/null +++ b/test_loop/66/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.898071289062500000e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/66/GlobalConnectivityMetrics/16.npy b/test_loop/66/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8cbcc3e Binary files /dev/null and b/test_loop/66/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/66/GlobalConnectivityMetrics/4.npy b/test_loop/66/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..e65a307 Binary files /dev/null and b/test_loop/66/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/66/GlobalConnectivityMetrics/8.npy b/test_loop/66/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..64198fe Binary files /dev/null and b/test_loop/66/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/66/KpostProcess/Kd1.npy b/test_loop/66/KpostProcess/Kd1.npy new file mode 100644 index 0000000..ec0140c Binary files /dev/null and b/test_loop/66/KpostProcess/Kd1.npy differ diff --git a/test_loop/66/KpostProcess/Kd16.npy b/test_loop/66/KpostProcess/Kd16.npy new file mode 100644 index 0000000..b03962f Binary files /dev/null and b/test_loop/66/KpostProcess/Kd16.npy differ diff --git a/test_loop/66/KpostProcess/Kd2.npy b/test_loop/66/KpostProcess/Kd2.npy new file mode 100644 index 0000000..f044273 Binary files /dev/null and b/test_loop/66/KpostProcess/Kd2.npy differ diff --git a/test_loop/66/KpostProcess/Kd4.npy b/test_loop/66/KpostProcess/Kd4.npy new file mode 100644 index 0000000..114dda1 Binary files /dev/null and b/test_loop/66/KpostProcess/Kd4.npy differ diff --git a/test_loop/66/KpostProcess/Kd8.npy b/test_loop/66/KpostProcess/Kd8.npy new file mode 100644 index 0000000..777e41b Binary files /dev/null and b/test_loop/66/KpostProcess/Kd8.npy differ diff --git a/test_loop/66/KpostProcess/Kperm2.npy b/test_loop/66/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..7aedbf0 Binary files /dev/null and b/test_loop/66/KpostProcess/Kperm2.npy differ diff --git a/test_loop/66/KpostProcess/Kperm4.npy b/test_loop/66/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..7aedbf0 Binary files /dev/null and b/test_loop/66/KpostProcess/Kperm4.npy differ diff --git a/test_loop/66/KpostProcess/Kperm8.npy b/test_loop/66/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..7aedbf0 Binary files /dev/null and b/test_loop/66/KpostProcess/Kperm8.npy differ diff --git a/test_loop/66/KpostProcess/Kv1.npy b/test_loop/66/KpostProcess/Kv1.npy new file mode 100644 index 0000000..41f545f Binary files /dev/null and b/test_loop/66/KpostProcess/Kv1.npy differ diff --git a/test_loop/66/KpostProcess/Kv16.npy b/test_loop/66/KpostProcess/Kv16.npy new file mode 100644 index 0000000..36d4cd2 Binary files /dev/null and b/test_loop/66/KpostProcess/Kv16.npy differ diff --git a/test_loop/66/KpostProcess/Kv2.npy b/test_loop/66/KpostProcess/Kv2.npy new file mode 100644 index 0000000..40b7f63 Binary files /dev/null and b/test_loop/66/KpostProcess/Kv2.npy differ diff --git a/test_loop/66/KpostProcess/Kv4.npy b/test_loop/66/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d57d7c7 Binary files /dev/null and b/test_loop/66/KpostProcess/Kv4.npy differ diff --git a/test_loop/66/KpostProcess/Kv8.npy b/test_loop/66/KpostProcess/Kv8.npy new file mode 100644 index 0000000..5195db9 Binary files /dev/null and b/test_loop/66/KpostProcess/Kv8.npy differ diff --git a/test_loop/66/P.npy b/test_loop/66/P.npy new file mode 100644 index 0000000..94bfeff Binary files /dev/null and b/test_loop/66/P.npy differ diff --git a/test_loop/66/PosKeffSummary.txt b/test_loop/66/PosKeffSummary.txt new file mode 100644 index 0000000..e9f3338 --- /dev/null +++ b/test_loop/66/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.722823235787450585e-02 +2.806071611999840995e-02 +1.481881141662597656e-01 +7.653496281852027044e-03 diff --git a/test_loop/66/RunTimes.out b/test_loop/66/RunTimes.out new file mode 100644 index 0000000..af1214a --- /dev/null +++ b/test_loop/66/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.405478000641 +Solver: 0.296656847 +Keff: 0.027937660459839225 +N_cores: 1 diff --git a/test_loop/66/SolverRes.txt b/test_loop/66/SolverRes.txt new file mode 100644 index 0000000..c0cb714 --- /dev/null +++ b/test_loop/66/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.793766045983922530e-02 +2.000000000000000000e+00 +7.021348476409912109e-01 +1.000000000000000000e+00 diff --git a/test_loop/66/V.npy b/test_loop/66/V.npy new file mode 100644 index 0000000..cc0c141 Binary files /dev/null and b/test_loop/66/V.npy differ diff --git a/test_loop/66/connec.out b/test_loop/66/connec.out new file mode 100644 index 0000000..a7bd467 --- /dev/null +++ b/test_loop/66/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 7.81250000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/66/k.npy b/test_loop/66/k.npy new file mode 100644 index 0000000..f76b72d Binary files /dev/null and b/test_loop/66/k.npy differ diff --git a/test_loop/66/lc.txt b/test_loop/66/lc.txt new file mode 100644 index 0000000..47c49bb --- /dev/null +++ b/test_loop/66/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.826168533790585968e+00 +2.674937252657260345e+00 +1.963424702242738018e+00 diff --git a/test_loop/66/tkperm_sub.txt b/test_loop/66/tkperm_sub.txt new file mode 100644 index 0000000..f99db79 --- /dev/null +++ b/test_loop/66/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.805940151214599609e-01 +1.931190490722656250e-04 +1.280307769775390625e-04 diff --git a/test_loop/67/Cmap.npy b/test_loop/67/Cmap.npy new file mode 100644 index 0000000..761e76d Binary files /dev/null and b/test_loop/67/Cmap.npy differ diff --git a/test_loop/67/ConnSummary.txt b/test_loop/67/ConnSummary.txt new file mode 100644 index 0000000..7f2f6c7 --- /dev/null +++ b/test_loop/67/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.641640186309814453e-01 +8.602626300501581280e-01 +2.795137774193631394e-02 diff --git a/test_loop/67/ConnectivityMetrics/16.npy b/test_loop/67/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..0041f88 Binary files /dev/null and b/test_loop/67/ConnectivityMetrics/16.npy differ diff --git a/test_loop/67/ConnectivityMetrics/4.npy b/test_loop/67/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..8a7c1df Binary files /dev/null and b/test_loop/67/ConnectivityMetrics/4.npy differ diff --git a/test_loop/67/ConnectivityMetrics/8.npy b/test_loop/67/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..61284ae Binary files /dev/null and b/test_loop/67/ConnectivityMetrics/8.npy differ diff --git a/test_loop/67/D.npy b/test_loop/67/D.npy new file mode 100644 index 0000000..5f848b9 Binary files /dev/null and b/test_loop/67/D.npy differ diff --git a/test_loop/67/GenParams.txt b/test_loop/67/GenParams.txt new file mode 100644 index 0000000..20952fc --- /dev/null +++ b/test_loop/67/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.793167114257812500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/67/GlobalConnectivityMetrics/16.npy b/test_loop/67/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..0041f88 Binary files /dev/null and b/test_loop/67/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/67/GlobalConnectivityMetrics/4.npy b/test_loop/67/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..232108f Binary files /dev/null and b/test_loop/67/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/67/GlobalConnectivityMetrics/8.npy b/test_loop/67/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..729fb2c Binary files /dev/null and b/test_loop/67/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/67/KpostProcess/Kd16.npy b/test_loop/67/KpostProcess/Kd16.npy new file mode 100644 index 0000000..5a78f3e Binary files /dev/null and b/test_loop/67/KpostProcess/Kd16.npy differ diff --git a/test_loop/67/KpostProcess/Kd4.npy b/test_loop/67/KpostProcess/Kd4.npy new file mode 100644 index 0000000..f63e8f7 Binary files /dev/null and b/test_loop/67/KpostProcess/Kd4.npy differ diff --git a/test_loop/67/KpostProcess/Kd8.npy b/test_loop/67/KpostProcess/Kd8.npy new file mode 100644 index 0000000..00d8b10 Binary files /dev/null and b/test_loop/67/KpostProcess/Kd8.npy differ diff --git a/test_loop/67/KpostProcess/Kperm4.npy b/test_loop/67/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..aca2937 Binary files /dev/null and b/test_loop/67/KpostProcess/Kperm4.npy differ diff --git a/test_loop/67/KpostProcess/Kperm8.npy b/test_loop/67/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..aca2937 Binary files /dev/null and b/test_loop/67/KpostProcess/Kperm8.npy differ diff --git a/test_loop/67/KpostProcess/Kv16.npy b/test_loop/67/KpostProcess/Kv16.npy new file mode 100644 index 0000000..3fd6a14 Binary files /dev/null and b/test_loop/67/KpostProcess/Kv16.npy differ diff --git a/test_loop/67/KpostProcess/Kv4.npy b/test_loop/67/KpostProcess/Kv4.npy new file mode 100644 index 0000000..6d93b30 Binary files /dev/null and b/test_loop/67/KpostProcess/Kv4.npy differ diff --git a/test_loop/67/KpostProcess/Kv8.npy b/test_loop/67/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a952ac0 Binary files /dev/null and b/test_loop/67/KpostProcess/Kv8.npy differ diff --git a/test_loop/67/P.npy b/test_loop/67/P.npy new file mode 100644 index 0000000..1558741 Binary files /dev/null and b/test_loop/67/P.npy differ diff --git a/test_loop/67/PosKeffSummary.txt b/test_loop/67/PosKeffSummary.txt new file mode 100644 index 0000000..e74c6e9 --- /dev/null +++ b/test_loop/67/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.832636309777224540e-02 +2.951232632022875516e-02 +5.514860153198242188e-03 +2.467684060351908737e-01 diff --git a/test_loop/67/RunTimes.out b/test_loop/67/RunTimes.out new file mode 100644 index 0000000..0e782c8 --- /dev/null +++ b/test_loop/67/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.307601928711 +Solver: 0.170151948929 +Keff: 0.02946968202646534 +N_cores: 1 diff --git a/test_loop/67/SolverRes.txt b/test_loop/67/SolverRes.txt new file mode 100644 index 0000000..15d5371 --- /dev/null +++ b/test_loop/67/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.946968202646534085e-02 +2.000000000000000000e+00 +4.777538776397705078e-01 +1.000000000000000000e+00 diff --git a/test_loop/67/V.npy b/test_loop/67/V.npy new file mode 100644 index 0000000..5edadec Binary files /dev/null and b/test_loop/67/V.npy differ diff --git a/test_loop/67/connec.out b/test_loop/67/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/67/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/67/k.npy b/test_loop/67/k.npy new file mode 100644 index 0000000..92cda1a Binary files /dev/null and b/test_loop/67/k.npy differ diff --git a/test_loop/67/lc.txt b/test_loop/67/lc.txt new file mode 100644 index 0000000..a7e5e68 --- /dev/null +++ b/test_loop/67/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.475731683196018551e+01 +6.766900358572815577e+00 +6.539573822136913961e+00 diff --git a/test_loop/67/tkperm_sub.txt b/test_loop/67/tkperm_sub.txt new file mode 100644 index 0000000..4aff947 --- /dev/null +++ b/test_loop/67/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.093899726867675781e-01 +1.800060272216796875e-04 diff --git a/test_loop/68/Cmap.npy b/test_loop/68/Cmap.npy new file mode 100644 index 0000000..c59e317 Binary files /dev/null and b/test_loop/68/Cmap.npy differ diff --git a/test_loop/68/ConnSummary.txt b/test_loop/68/ConnSummary.txt new file mode 100644 index 0000000..c047af6 --- /dev/null +++ b/test_loop/68/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.648200035095214844e-01 +8.164140361241851718e-01 +3.784360651066616399e-02 diff --git a/test_loop/68/ConnectivityMetrics/16.npy b/test_loop/68/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c148f9a Binary files /dev/null and b/test_loop/68/ConnectivityMetrics/16.npy differ diff --git a/test_loop/68/ConnectivityMetrics/4.npy b/test_loop/68/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..740ab3e Binary files /dev/null and b/test_loop/68/ConnectivityMetrics/4.npy differ diff --git a/test_loop/68/ConnectivityMetrics/8.npy b/test_loop/68/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..8916964 Binary files /dev/null and b/test_loop/68/ConnectivityMetrics/8.npy differ diff --git a/test_loop/68/D.npy b/test_loop/68/D.npy new file mode 100644 index 0000000..d6f8ce8 Binary files /dev/null and b/test_loop/68/D.npy differ diff --git a/test_loop/68/GenParams.txt b/test_loop/68/GenParams.txt new file mode 100644 index 0000000..269af9c --- /dev/null +++ b/test_loop/68/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.984067916870117188e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/68/GlobalConnectivityMetrics/16.npy b/test_loop/68/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c148f9a Binary files /dev/null and b/test_loop/68/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/68/GlobalConnectivityMetrics/4.npy b/test_loop/68/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..3f0fa8d Binary files /dev/null and b/test_loop/68/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/68/GlobalConnectivityMetrics/8.npy b/test_loop/68/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..22bd57e Binary files /dev/null and b/test_loop/68/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/68/KpostProcess/Kd1.npy b/test_loop/68/KpostProcess/Kd1.npy new file mode 100644 index 0000000..1672dd3 Binary files /dev/null and b/test_loop/68/KpostProcess/Kd1.npy differ diff --git a/test_loop/68/KpostProcess/Kd16.npy b/test_loop/68/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2e51c0d Binary files /dev/null and b/test_loop/68/KpostProcess/Kd16.npy differ diff --git a/test_loop/68/KpostProcess/Kd2.npy b/test_loop/68/KpostProcess/Kd2.npy new file mode 100644 index 0000000..82c3f8d Binary files /dev/null and b/test_loop/68/KpostProcess/Kd2.npy differ diff --git a/test_loop/68/KpostProcess/Kd4.npy b/test_loop/68/KpostProcess/Kd4.npy new file mode 100644 index 0000000..c8f6f8f Binary files /dev/null and b/test_loop/68/KpostProcess/Kd4.npy differ diff --git a/test_loop/68/KpostProcess/Kd8.npy b/test_loop/68/KpostProcess/Kd8.npy new file mode 100644 index 0000000..439fa27 Binary files /dev/null and b/test_loop/68/KpostProcess/Kd8.npy differ diff --git a/test_loop/68/KpostProcess/Kperm2.npy b/test_loop/68/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..7fac53c Binary files /dev/null and b/test_loop/68/KpostProcess/Kperm2.npy differ diff --git a/test_loop/68/KpostProcess/Kperm4.npy b/test_loop/68/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..7fac53c Binary files /dev/null and b/test_loop/68/KpostProcess/Kperm4.npy differ diff --git a/test_loop/68/KpostProcess/Kperm8.npy b/test_loop/68/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..7fac53c Binary files /dev/null and b/test_loop/68/KpostProcess/Kperm8.npy differ diff --git a/test_loop/68/KpostProcess/Kv1.npy b/test_loop/68/KpostProcess/Kv1.npy new file mode 100644 index 0000000..ffbd236 Binary files /dev/null and b/test_loop/68/KpostProcess/Kv1.npy differ diff --git a/test_loop/68/KpostProcess/Kv16.npy b/test_loop/68/KpostProcess/Kv16.npy new file mode 100644 index 0000000..d9393c5 Binary files /dev/null and b/test_loop/68/KpostProcess/Kv16.npy differ diff --git a/test_loop/68/KpostProcess/Kv2.npy b/test_loop/68/KpostProcess/Kv2.npy new file mode 100644 index 0000000..b2c9bd2 Binary files /dev/null and b/test_loop/68/KpostProcess/Kv2.npy differ diff --git a/test_loop/68/KpostProcess/Kv4.npy b/test_loop/68/KpostProcess/Kv4.npy new file mode 100644 index 0000000..2e0e8a0 Binary files /dev/null and b/test_loop/68/KpostProcess/Kv4.npy differ diff --git a/test_loop/68/KpostProcess/Kv8.npy b/test_loop/68/KpostProcess/Kv8.npy new file mode 100644 index 0000000..809a12c Binary files /dev/null and b/test_loop/68/KpostProcess/Kv8.npy differ diff --git a/test_loop/68/P.npy b/test_loop/68/P.npy new file mode 100644 index 0000000..524c889 Binary files /dev/null and b/test_loop/68/P.npy differ diff --git a/test_loop/68/PosKeffSummary.txt b/test_loop/68/PosKeffSummary.txt new file mode 100644 index 0000000..1327d4e --- /dev/null +++ b/test_loop/68/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.961121650135143529e-02 +3.053521117511088026e-02 +1.585619449615478516e-01 +8.564679418455862364e-03 diff --git a/test_loop/68/RunTimes.out b/test_loop/68/RunTimes.out new file mode 100644 index 0000000..681bd71 --- /dev/null +++ b/test_loop/68/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.298229932785 +Solver: 0.323092937469 +Keff: 0.030314259611093144 +N_cores: 1 diff --git a/test_loop/68/SolverRes.txt b/test_loop/68/SolverRes.txt new file mode 100644 index 0000000..0f2fef3 --- /dev/null +++ b/test_loop/68/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.031425961109314449e-02 +2.000000000000000000e+00 +6.213228702545166016e-01 +1.000000000000000000e+00 diff --git a/test_loop/68/V.npy b/test_loop/68/V.npy new file mode 100644 index 0000000..744468d Binary files /dev/null and b/test_loop/68/V.npy differ diff --git a/test_loop/68/connec.out b/test_loop/68/connec.out new file mode 100644 index 0000000..ad19c39 --- /dev/null +++ b/test_loop/68/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.109375000 + NCC : 1 diff --git a/test_loop/68/k.npy b/test_loop/68/k.npy new file mode 100644 index 0000000..f9594a6 Binary files /dev/null and b/test_loop/68/k.npy differ diff --git a/test_loop/68/lc.txt b/test_loop/68/lc.txt new file mode 100644 index 0000000..8fe1831 --- /dev/null +++ b/test_loop/68/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.824100989601600276e+00 +2.674650787807683283e+00 +1.940765712820491373e+00 diff --git a/test_loop/68/tkperm_sub.txt b/test_loop/68/tkperm_sub.txt new file mode 100644 index 0000000..4a8ff3c --- /dev/null +++ b/test_loop/68/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.277740955352783203e-01 +2.369880676269531250e-04 +1.950263977050781250e-04 diff --git a/test_loop/69/Cmap.npy b/test_loop/69/Cmap.npy new file mode 100644 index 0000000..97ad404 Binary files /dev/null and b/test_loop/69/Cmap.npy differ diff --git a/test_loop/69/ConnSummary.txt b/test_loop/69/ConnSummary.txt new file mode 100644 index 0000000..c8b12f3 --- /dev/null +++ b/test_loop/69/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +5.029089450836181641e-01 +7.835293571061837659e-01 +4.599040558882273172e-02 diff --git a/test_loop/69/ConnectivityMetrics/16.npy b/test_loop/69/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..45abc98 Binary files /dev/null and b/test_loop/69/ConnectivityMetrics/16.npy differ diff --git a/test_loop/69/ConnectivityMetrics/4.npy b/test_loop/69/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..28cc2c7 Binary files /dev/null and b/test_loop/69/ConnectivityMetrics/4.npy differ diff --git a/test_loop/69/ConnectivityMetrics/8.npy b/test_loop/69/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..6d22662 Binary files /dev/null and b/test_loop/69/ConnectivityMetrics/8.npy differ diff --git a/test_loop/69/D.npy b/test_loop/69/D.npy new file mode 100644 index 0000000..1f5a7a9 Binary files /dev/null and b/test_loop/69/D.npy differ diff --git a/test_loop/69/GenParams.txt b/test_loop/69/GenParams.txt new file mode 100644 index 0000000..08ff1d0 --- /dev/null +++ b/test_loop/69/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.368947982788085938e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/69/GlobalConnectivityMetrics/16.npy b/test_loop/69/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..45abc98 Binary files /dev/null and b/test_loop/69/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/69/GlobalConnectivityMetrics/4.npy b/test_loop/69/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..e4b73df Binary files /dev/null and b/test_loop/69/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/69/GlobalConnectivityMetrics/8.npy b/test_loop/69/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..f0ab307 Binary files /dev/null and b/test_loop/69/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/69/KpostProcess/Kd16.npy b/test_loop/69/KpostProcess/Kd16.npy new file mode 100644 index 0000000..00710da Binary files /dev/null and b/test_loop/69/KpostProcess/Kd16.npy differ diff --git a/test_loop/69/KpostProcess/Kd4.npy b/test_loop/69/KpostProcess/Kd4.npy new file mode 100644 index 0000000..815f48c Binary files /dev/null and b/test_loop/69/KpostProcess/Kd4.npy differ diff --git a/test_loop/69/KpostProcess/Kd8.npy b/test_loop/69/KpostProcess/Kd8.npy new file mode 100644 index 0000000..15e6abc Binary files /dev/null and b/test_loop/69/KpostProcess/Kd8.npy differ diff --git a/test_loop/69/KpostProcess/Kperm4.npy b/test_loop/69/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9f735a0 Binary files /dev/null and b/test_loop/69/KpostProcess/Kperm4.npy differ diff --git a/test_loop/69/KpostProcess/Kperm8.npy b/test_loop/69/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9f735a0 Binary files /dev/null and b/test_loop/69/KpostProcess/Kperm8.npy differ diff --git a/test_loop/69/KpostProcess/Kv16.npy b/test_loop/69/KpostProcess/Kv16.npy new file mode 100644 index 0000000..6162fa5 Binary files /dev/null and b/test_loop/69/KpostProcess/Kv16.npy differ diff --git a/test_loop/69/KpostProcess/Kv4.npy b/test_loop/69/KpostProcess/Kv4.npy new file mode 100644 index 0000000..aee9c20 Binary files /dev/null and b/test_loop/69/KpostProcess/Kv4.npy differ diff --git a/test_loop/69/KpostProcess/Kv8.npy b/test_loop/69/KpostProcess/Kv8.npy new file mode 100644 index 0000000..6439f88 Binary files /dev/null and b/test_loop/69/KpostProcess/Kv8.npy differ diff --git a/test_loop/69/P.npy b/test_loop/69/P.npy new file mode 100644 index 0000000..3d5e8a4 Binary files /dev/null and b/test_loop/69/P.npy differ diff --git a/test_loop/69/PosKeffSummary.txt b/test_loop/69/PosKeffSummary.txt new file mode 100644 index 0000000..71f3626 --- /dev/null +++ b/test_loop/69/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.861601084305645720e-02 +3.990265172329639926e-02 +4.235982894897460938e-03 +2.441042381944053541e-01 diff --git a/test_loop/69/RunTimes.out b/test_loop/69/RunTimes.out new file mode 100644 index 0000000..5c3b2c9 --- /dev/null +++ b/test_loop/69/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.390544891357 +Solver: 0.207603931427 +Keff: 0.03988941449022785 +N_cores: 1 diff --git a/test_loop/69/SolverRes.txt b/test_loop/69/SolverRes.txt new file mode 100644 index 0000000..df6c609 --- /dev/null +++ b/test_loop/69/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.988941449022784941e-02 +2.000000000000000000e+00 +5.981488227844238281e-01 +1.000000000000000000e+00 diff --git a/test_loop/69/V.npy b/test_loop/69/V.npy new file mode 100644 index 0000000..b3433bf Binary files /dev/null and b/test_loop/69/V.npy differ diff --git a/test_loop/69/connec.out b/test_loop/69/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/69/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/69/k.npy b/test_loop/69/k.npy new file mode 100644 index 0000000..6fe32b7 Binary files /dev/null and b/test_loop/69/k.npy differ diff --git a/test_loop/69/lc.txt b/test_loop/69/lc.txt new file mode 100644 index 0000000..42c5ee0 --- /dev/null +++ b/test_loop/69/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.474921021368812291e+01 +6.776006863857118034e+00 +6.200111071880440861e+00 diff --git a/test_loop/69/tkperm_sub.txt b/test_loop/69/tkperm_sub.txt new file mode 100644 index 0000000..47d3aa2 --- /dev/null +++ b/test_loop/69/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.739519119262695312e-01 +1.850128173828125000e-04 diff --git a/test_loop/7/Cmap.npy b/test_loop/7/Cmap.npy new file mode 100644 index 0000000..56a6e55 Binary files /dev/null and b/test_loop/7/Cmap.npy differ diff --git a/test_loop/7/ConnSummary.txt b/test_loop/7/ConnSummary.txt new file mode 100644 index 0000000..0793b18 --- /dev/null +++ b/test_loop/7/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.741370677947998047e-01 +8.184912064565602607e-01 +3.963442995964649995e-02 diff --git a/test_loop/7/ConnectivityMetrics/16.npy b/test_loop/7/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..6cdbc07 Binary files /dev/null and b/test_loop/7/ConnectivityMetrics/16.npy differ diff --git a/test_loop/7/ConnectivityMetrics/4.npy b/test_loop/7/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..27f4466 Binary files /dev/null and b/test_loop/7/ConnectivityMetrics/4.npy differ diff --git a/test_loop/7/ConnectivityMetrics/8.npy b/test_loop/7/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..9bf74ef Binary files /dev/null and b/test_loop/7/ConnectivityMetrics/8.npy differ diff --git a/test_loop/7/D.npy b/test_loop/7/D.npy new file mode 100644 index 0000000..d76f6e0 Binary files /dev/null and b/test_loop/7/D.npy differ diff --git a/test_loop/7/GenParams.txt b/test_loop/7/GenParams.txt new file mode 100644 index 0000000..d8bf162 --- /dev/null +++ b/test_loop/7/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.894018173217773438e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.621428571428571441e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/7/GlobalConnectivityMetrics/16.npy b/test_loop/7/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..6cdbc07 Binary files /dev/null and b/test_loop/7/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/7/GlobalConnectivityMetrics/4.npy b/test_loop/7/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..3120369 Binary files /dev/null and b/test_loop/7/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/7/GlobalConnectivityMetrics/8.npy b/test_loop/7/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..e62a999 Binary files /dev/null and b/test_loop/7/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/7/KpostProcess/Kd16.npy b/test_loop/7/KpostProcess/Kd16.npy new file mode 100644 index 0000000..f4db27e Binary files /dev/null and b/test_loop/7/KpostProcess/Kd16.npy differ diff --git a/test_loop/7/KpostProcess/Kd4.npy b/test_loop/7/KpostProcess/Kd4.npy new file mode 100644 index 0000000..bdc1b20 Binary files /dev/null and b/test_loop/7/KpostProcess/Kd4.npy differ diff --git a/test_loop/7/KpostProcess/Kd8.npy b/test_loop/7/KpostProcess/Kd8.npy new file mode 100644 index 0000000..8384f15 Binary files /dev/null and b/test_loop/7/KpostProcess/Kd8.npy differ diff --git a/test_loop/7/KpostProcess/Kperm4.npy b/test_loop/7/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..7a56af6 Binary files /dev/null and b/test_loop/7/KpostProcess/Kperm4.npy differ diff --git a/test_loop/7/KpostProcess/Kperm8.npy b/test_loop/7/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..7a56af6 Binary files /dev/null and b/test_loop/7/KpostProcess/Kperm8.npy differ diff --git a/test_loop/7/KpostProcess/Kv16.npy b/test_loop/7/KpostProcess/Kv16.npy new file mode 100644 index 0000000..ffd9b81 Binary files /dev/null and b/test_loop/7/KpostProcess/Kv16.npy differ diff --git a/test_loop/7/KpostProcess/Kv4.npy b/test_loop/7/KpostProcess/Kv4.npy new file mode 100644 index 0000000..660b1e3 Binary files /dev/null and b/test_loop/7/KpostProcess/Kv4.npy differ diff --git a/test_loop/7/KpostProcess/Kv8.npy b/test_loop/7/KpostProcess/Kv8.npy new file mode 100644 index 0000000..70f09e9 Binary files /dev/null and b/test_loop/7/KpostProcess/Kv8.npy differ diff --git a/test_loop/7/P.npy b/test_loop/7/P.npy new file mode 100644 index 0000000..f7af27d Binary files /dev/null and b/test_loop/7/P.npy differ diff --git a/test_loop/7/PosKeffSummary.txt b/test_loop/7/PosKeffSummary.txt new file mode 100644 index 0000000..e8a7a4d --- /dev/null +++ b/test_loop/7/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.429529316789579896e-02 +3.500556695749940106e-02 +4.842042922973632812e-03 +2.379240730710522334e-01 diff --git a/test_loop/7/RunTimes.out b/test_loop/7/RunTimes.out new file mode 100644 index 0000000..bdd9124 --- /dev/null +++ b/test_loop/7/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.366513967514 +Solver: 0.226408004761 +Keff: 0.0344789840236185 +N_cores: 1 diff --git a/test_loop/7/SolverRes.txt b/test_loop/7/SolverRes.txt new file mode 100644 index 0000000..312da80 --- /dev/null +++ b/test_loop/7/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.447898402361850023e-02 +2.000000000000000000e+00 +5.929219722747802734e-01 +1.000000000000000000e+00 diff --git a/test_loop/7/V.npy b/test_loop/7/V.npy new file mode 100644 index 0000000..c486be2 Binary files /dev/null and b/test_loop/7/V.npy differ diff --git a/test_loop/7/connec.out b/test_loop/7/connec.out new file mode 100644 index 0000000..1bbe897 --- /dev/null +++ b/test_loop/7/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.250000000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/7/k.npy b/test_loop/7/k.npy new file mode 100644 index 0000000..00eddf3 Binary files /dev/null and b/test_loop/7/k.npy differ diff --git a/test_loop/7/lc.txt b/test_loop/7/lc.txt new file mode 100644 index 0000000..ab73a47 --- /dev/null +++ b/test_loop/7/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.792634984663569853e+00 +7.792634984663569853e+00 +3.125028625174910424e+00 diff --git a/test_loop/7/tkperm_sub.txt b/test_loop/7/tkperm_sub.txt new file mode 100644 index 0000000..8d26a33 --- /dev/null +++ b/test_loop/7/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.159439563751220703e-01 +2.229213714599609375e-04 diff --git a/test_loop/70/Cmap.npy b/test_loop/70/Cmap.npy new file mode 100644 index 0000000..be1adb7 Binary files /dev/null and b/test_loop/70/Cmap.npy differ diff --git a/test_loop/70/ConnSummary.txt b/test_loop/70/ConnSummary.txt new file mode 100644 index 0000000..483c847 --- /dev/null +++ b/test_loop/70/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.208670616149902344e-01 +7.884417906189117309e-01 +4.344805448598394737e-02 diff --git a/test_loop/70/ConnectivityMetrics/16.npy b/test_loop/70/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..97a3b44 Binary files /dev/null and b/test_loop/70/ConnectivityMetrics/16.npy differ diff --git a/test_loop/70/ConnectivityMetrics/4.npy b/test_loop/70/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..2934e4c Binary files /dev/null and b/test_loop/70/ConnectivityMetrics/4.npy differ diff --git a/test_loop/70/ConnectivityMetrics/8.npy b/test_loop/70/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..79d6e0d Binary files /dev/null and b/test_loop/70/ConnectivityMetrics/8.npy differ diff --git a/test_loop/70/D.npy b/test_loop/70/D.npy new file mode 100644 index 0000000..dc78109 Binary files /dev/null and b/test_loop/70/D.npy differ diff --git a/test_loop/70/GenParams.txt b/test_loop/70/GenParams.txt new file mode 100644 index 0000000..6e2d018 --- /dev/null +++ b/test_loop/70/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.806207656860351562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/70/GlobalConnectivityMetrics/16.npy b/test_loop/70/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..97a3b44 Binary files /dev/null and b/test_loop/70/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/70/GlobalConnectivityMetrics/4.npy b/test_loop/70/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..eda1dad Binary files /dev/null and b/test_loop/70/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/70/GlobalConnectivityMetrics/8.npy b/test_loop/70/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..aaa59bc Binary files /dev/null and b/test_loop/70/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/70/KpostProcess/Kd1.npy b/test_loop/70/KpostProcess/Kd1.npy new file mode 100644 index 0000000..5748f01 Binary files /dev/null and b/test_loop/70/KpostProcess/Kd1.npy differ diff --git a/test_loop/70/KpostProcess/Kd16.npy b/test_loop/70/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a367a84 Binary files /dev/null and b/test_loop/70/KpostProcess/Kd16.npy differ diff --git a/test_loop/70/KpostProcess/Kd2.npy b/test_loop/70/KpostProcess/Kd2.npy new file mode 100644 index 0000000..829fe24 Binary files /dev/null and b/test_loop/70/KpostProcess/Kd2.npy differ diff --git a/test_loop/70/KpostProcess/Kd4.npy b/test_loop/70/KpostProcess/Kd4.npy new file mode 100644 index 0000000..fcdd83e Binary files /dev/null and b/test_loop/70/KpostProcess/Kd4.npy differ diff --git a/test_loop/70/KpostProcess/Kd8.npy b/test_loop/70/KpostProcess/Kd8.npy new file mode 100644 index 0000000..d3aaf7c Binary files /dev/null and b/test_loop/70/KpostProcess/Kd8.npy differ diff --git a/test_loop/70/KpostProcess/Kperm2.npy b/test_loop/70/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..9e8aeab Binary files /dev/null and b/test_loop/70/KpostProcess/Kperm2.npy differ diff --git a/test_loop/70/KpostProcess/Kperm4.npy b/test_loop/70/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..9e8aeab Binary files /dev/null and b/test_loop/70/KpostProcess/Kperm4.npy differ diff --git a/test_loop/70/KpostProcess/Kperm8.npy b/test_loop/70/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..9e8aeab Binary files /dev/null and b/test_loop/70/KpostProcess/Kperm8.npy differ diff --git a/test_loop/70/KpostProcess/Kv1.npy b/test_loop/70/KpostProcess/Kv1.npy new file mode 100644 index 0000000..547438c Binary files /dev/null and b/test_loop/70/KpostProcess/Kv1.npy differ diff --git a/test_loop/70/KpostProcess/Kv16.npy b/test_loop/70/KpostProcess/Kv16.npy new file mode 100644 index 0000000..7d30e46 Binary files /dev/null and b/test_loop/70/KpostProcess/Kv16.npy differ diff --git a/test_loop/70/KpostProcess/Kv2.npy b/test_loop/70/KpostProcess/Kv2.npy new file mode 100644 index 0000000..7fa302f Binary files /dev/null and b/test_loop/70/KpostProcess/Kv2.npy differ diff --git a/test_loop/70/KpostProcess/Kv4.npy b/test_loop/70/KpostProcess/Kv4.npy new file mode 100644 index 0000000..76952d7 Binary files /dev/null and b/test_loop/70/KpostProcess/Kv4.npy differ diff --git a/test_loop/70/KpostProcess/Kv8.npy b/test_loop/70/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ce202d6 Binary files /dev/null and b/test_loop/70/KpostProcess/Kv8.npy differ diff --git a/test_loop/70/P.npy b/test_loop/70/P.npy new file mode 100644 index 0000000..0cf6b7c Binary files /dev/null and b/test_loop/70/P.npy differ diff --git a/test_loop/70/PosKeffSummary.txt b/test_loop/70/PosKeffSummary.txt new file mode 100644 index 0000000..6ac8f3c --- /dev/null +++ b/test_loop/70/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.367771474420023364e-02 +3.474043596329873251e-02 +1.802818775177001953e-01 +6.156128952056252705e-03 diff --git a/test_loop/70/RunTimes.out b/test_loop/70/RunTimes.out new file mode 100644 index 0000000..05eafa9 --- /dev/null +++ b/test_loop/70/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.390252113342 +Solver: 0.317218065262 +Keff: 0.03471811792123156 +N_cores: 1 diff --git a/test_loop/70/SolverRes.txt b/test_loop/70/SolverRes.txt new file mode 100644 index 0000000..78f8183 --- /dev/null +++ b/test_loop/70/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.471811792123156298e-02 +2.000000000000000000e+00 +7.074701786041259766e-01 +1.000000000000000000e+00 diff --git a/test_loop/70/V.npy b/test_loop/70/V.npy new file mode 100644 index 0000000..f44507e Binary files /dev/null and b/test_loop/70/V.npy differ diff --git a/test_loop/70/connec.out b/test_loop/70/connec.out new file mode 100644 index 0000000..ad19c39 --- /dev/null +++ b/test_loop/70/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.109375000 + NCC : 1 diff --git a/test_loop/70/k.npy b/test_loop/70/k.npy new file mode 100644 index 0000000..c9a1e5b Binary files /dev/null and b/test_loop/70/k.npy differ diff --git a/test_loop/70/lc.txt b/test_loop/70/lc.txt new file mode 100644 index 0000000..2ab8e2f --- /dev/null +++ b/test_loop/70/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.830144799335101879e+00 +2.677589479906936631e+00 +1.916153840797907515e+00 diff --git a/test_loop/70/tkperm_sub.txt b/test_loop/70/tkperm_sub.txt new file mode 100644 index 0000000..51d6726 --- /dev/null +++ b/test_loop/70/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.533388614654541016e-01 +2.319812774658203125e-04 +1.988410949707031250e-04 diff --git a/test_loop/71/Cmap.npy b/test_loop/71/Cmap.npy new file mode 100644 index 0000000..77a891b Binary files /dev/null and b/test_loop/71/Cmap.npy differ diff --git a/test_loop/71/ConnSummary.txt b/test_loop/71/ConnSummary.txt new file mode 100644 index 0000000..f0a513b --- /dev/null +++ b/test_loop/71/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.377660751342773438e-01 +7.770379342571634984e-01 +5.705333626704950367e-02 diff --git a/test_loop/71/ConnectivityMetrics/16.npy b/test_loop/71/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..32d6018 Binary files /dev/null and b/test_loop/71/ConnectivityMetrics/16.npy differ diff --git a/test_loop/71/ConnectivityMetrics/4.npy b/test_loop/71/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..2521644 Binary files /dev/null and b/test_loop/71/ConnectivityMetrics/4.npy differ diff --git a/test_loop/71/ConnectivityMetrics/8.npy b/test_loop/71/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..fc91acb Binary files /dev/null and b/test_loop/71/ConnectivityMetrics/8.npy differ diff --git a/test_loop/71/D.npy b/test_loop/71/D.npy new file mode 100644 index 0000000..52ab3f0 Binary files /dev/null and b/test_loop/71/D.npy differ diff --git a/test_loop/71/GenParams.txt b/test_loop/71/GenParams.txt new file mode 100644 index 0000000..0446bcc --- /dev/null +++ b/test_loop/71/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +8.011102676391601562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.035714285714285698e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/71/GlobalConnectivityMetrics/16.npy b/test_loop/71/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..32d6018 Binary files /dev/null and b/test_loop/71/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/71/GlobalConnectivityMetrics/4.npy b/test_loop/71/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..0b0817b Binary files /dev/null and b/test_loop/71/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/71/GlobalConnectivityMetrics/8.npy b/test_loop/71/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..c3eb4fc Binary files /dev/null and b/test_loop/71/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/71/KpostProcess/Kd16.npy b/test_loop/71/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c5f6e73 Binary files /dev/null and b/test_loop/71/KpostProcess/Kd16.npy differ diff --git a/test_loop/71/KpostProcess/Kd4.npy b/test_loop/71/KpostProcess/Kd4.npy new file mode 100644 index 0000000..e9eae30 Binary files /dev/null and b/test_loop/71/KpostProcess/Kd4.npy differ diff --git a/test_loop/71/KpostProcess/Kd8.npy b/test_loop/71/KpostProcess/Kd8.npy new file mode 100644 index 0000000..0b89b62 Binary files /dev/null and b/test_loop/71/KpostProcess/Kd8.npy differ diff --git a/test_loop/71/KpostProcess/Kperm4.npy b/test_loop/71/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..aa74033 Binary files /dev/null and b/test_loop/71/KpostProcess/Kperm4.npy differ diff --git a/test_loop/71/KpostProcess/Kperm8.npy b/test_loop/71/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..aa74033 Binary files /dev/null and b/test_loop/71/KpostProcess/Kperm8.npy differ diff --git a/test_loop/71/KpostProcess/Kv16.npy b/test_loop/71/KpostProcess/Kv16.npy new file mode 100644 index 0000000..38bf431 Binary files /dev/null and b/test_loop/71/KpostProcess/Kv16.npy differ diff --git a/test_loop/71/KpostProcess/Kv4.npy b/test_loop/71/KpostProcess/Kv4.npy new file mode 100644 index 0000000..b493a56 Binary files /dev/null and b/test_loop/71/KpostProcess/Kv4.npy differ diff --git a/test_loop/71/KpostProcess/Kv8.npy b/test_loop/71/KpostProcess/Kv8.npy new file mode 100644 index 0000000..1119485 Binary files /dev/null and b/test_loop/71/KpostProcess/Kv8.npy differ diff --git a/test_loop/71/P.npy b/test_loop/71/P.npy new file mode 100644 index 0000000..2400e24 Binary files /dev/null and b/test_loop/71/P.npy differ diff --git a/test_loop/71/PosKeffSummary.txt b/test_loop/71/PosKeffSummary.txt new file mode 100644 index 0000000..bb3c6be --- /dev/null +++ b/test_loop/71/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +5.295672736593897145e-01 +5.630205471395514083e-01 +4.678010940551757812e-03 +2.342897915498700356e-01 diff --git a/test_loop/71/RunTimes.out b/test_loop/71/RunTimes.out new file mode 100644 index 0000000..18754d8 --- /dev/null +++ b/test_loop/71/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.380772829056 +Solver: 0.201317071915 +Keff: 0.5631354109770492 +N_cores: 1 diff --git a/test_loop/71/SolverRes.txt b/test_loop/71/SolverRes.txt new file mode 100644 index 0000000..583b73d --- /dev/null +++ b/test_loop/71/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.631354109770492222e-01 +2.000000000000000000e+00 +5.820899009704589844e-01 +1.000000000000000000e+00 diff --git a/test_loop/71/V.npy b/test_loop/71/V.npy new file mode 100644 index 0000000..d0c839c Binary files /dev/null and b/test_loop/71/V.npy differ diff --git a/test_loop/71/connec.out b/test_loop/71/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/71/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/71/k.npy b/test_loop/71/k.npy new file mode 100644 index 0000000..99361da Binary files /dev/null and b/test_loop/71/k.npy differ diff --git a/test_loop/71/lc.txt b/test_loop/71/lc.txt new file mode 100644 index 0000000..9f2302d --- /dev/null +++ b/test_loop/71/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.477290829364938496e+01 +6.742019130914653324e+00 +5.680695420896856973e+00 diff --git a/test_loop/71/tkperm_sub.txt b/test_loop/71/tkperm_sub.txt new file mode 100644 index 0000000..5ad8e50 --- /dev/null +++ b/test_loop/71/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.718249797821044922e-01 +1.690387725830078125e-04 diff --git a/test_loop/72/Cmap.npy b/test_loop/72/Cmap.npy new file mode 100644 index 0000000..60b96fd Binary files /dev/null and b/test_loop/72/Cmap.npy differ diff --git a/test_loop/72/ConnSummary.txt b/test_loop/72/ConnSummary.txt new file mode 100644 index 0000000..ff21c26 --- /dev/null +++ b/test_loop/72/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.248590469360351562e-01 +8.389843253714390769e-01 +3.431504589256493404e-02 diff --git a/test_loop/72/ConnectivityMetrics/16.npy b/test_loop/72/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..01e8f06 Binary files /dev/null and b/test_loop/72/ConnectivityMetrics/16.npy differ diff --git a/test_loop/72/ConnectivityMetrics/4.npy b/test_loop/72/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..9e0aa33 Binary files /dev/null and b/test_loop/72/ConnectivityMetrics/4.npy differ diff --git a/test_loop/72/ConnectivityMetrics/8.npy b/test_loop/72/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..ebbeee8 Binary files /dev/null and b/test_loop/72/ConnectivityMetrics/8.npy differ diff --git a/test_loop/72/D.npy b/test_loop/72/D.npy new file mode 100644 index 0000000..86026cd Binary files /dev/null and b/test_loop/72/D.npy differ diff --git a/test_loop/72/GenParams.txt b/test_loop/72/GenParams.txt new file mode 100644 index 0000000..d76fbac --- /dev/null +++ b/test_loop/72/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.719018936157226562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/72/GlobalConnectivityMetrics/16.npy b/test_loop/72/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..01e8f06 Binary files /dev/null and b/test_loop/72/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/72/GlobalConnectivityMetrics/4.npy b/test_loop/72/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..4e1cb74 Binary files /dev/null and b/test_loop/72/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/72/GlobalConnectivityMetrics/8.npy b/test_loop/72/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..365f515 Binary files /dev/null and b/test_loop/72/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/72/KpostProcess/Kd1.npy b/test_loop/72/KpostProcess/Kd1.npy new file mode 100644 index 0000000..fec53e9 Binary files /dev/null and b/test_loop/72/KpostProcess/Kd1.npy differ diff --git a/test_loop/72/KpostProcess/Kd16.npy b/test_loop/72/KpostProcess/Kd16.npy new file mode 100644 index 0000000..25532c4 Binary files /dev/null and b/test_loop/72/KpostProcess/Kd16.npy differ diff --git a/test_loop/72/KpostProcess/Kd2.npy b/test_loop/72/KpostProcess/Kd2.npy new file mode 100644 index 0000000..b0c2790 Binary files /dev/null and b/test_loop/72/KpostProcess/Kd2.npy differ diff --git a/test_loop/72/KpostProcess/Kd4.npy b/test_loop/72/KpostProcess/Kd4.npy new file mode 100644 index 0000000..673cea3 Binary files /dev/null and b/test_loop/72/KpostProcess/Kd4.npy differ diff --git a/test_loop/72/KpostProcess/Kd8.npy b/test_loop/72/KpostProcess/Kd8.npy new file mode 100644 index 0000000..929106e Binary files /dev/null and b/test_loop/72/KpostProcess/Kd8.npy differ diff --git a/test_loop/72/KpostProcess/Kperm2.npy b/test_loop/72/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..7ac77d3 Binary files /dev/null and b/test_loop/72/KpostProcess/Kperm2.npy differ diff --git a/test_loop/72/KpostProcess/Kperm4.npy b/test_loop/72/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..7ac77d3 Binary files /dev/null and b/test_loop/72/KpostProcess/Kperm4.npy differ diff --git a/test_loop/72/KpostProcess/Kperm8.npy b/test_loop/72/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..7ac77d3 Binary files /dev/null and b/test_loop/72/KpostProcess/Kperm8.npy differ diff --git a/test_loop/72/KpostProcess/Kv1.npy b/test_loop/72/KpostProcess/Kv1.npy new file mode 100644 index 0000000..9babf80 Binary files /dev/null and b/test_loop/72/KpostProcess/Kv1.npy differ diff --git a/test_loop/72/KpostProcess/Kv16.npy b/test_loop/72/KpostProcess/Kv16.npy new file mode 100644 index 0000000..bf85e48 Binary files /dev/null and b/test_loop/72/KpostProcess/Kv16.npy differ diff --git a/test_loop/72/KpostProcess/Kv2.npy b/test_loop/72/KpostProcess/Kv2.npy new file mode 100644 index 0000000..295f975 Binary files /dev/null and b/test_loop/72/KpostProcess/Kv2.npy differ diff --git a/test_loop/72/KpostProcess/Kv4.npy b/test_loop/72/KpostProcess/Kv4.npy new file mode 100644 index 0000000..723a216 Binary files /dev/null and b/test_loop/72/KpostProcess/Kv4.npy differ diff --git a/test_loop/72/KpostProcess/Kv8.npy b/test_loop/72/KpostProcess/Kv8.npy new file mode 100644 index 0000000..60a6676 Binary files /dev/null and b/test_loop/72/KpostProcess/Kv8.npy differ diff --git a/test_loop/72/P.npy b/test_loop/72/P.npy new file mode 100644 index 0000000..465ba46 Binary files /dev/null and b/test_loop/72/P.npy differ diff --git a/test_loop/72/PosKeffSummary.txt b/test_loop/72/PosKeffSummary.txt new file mode 100644 index 0000000..95842fd --- /dev/null +++ b/test_loop/72/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.418988982985766478e-02 +4.449303055443027538e-02 +1.459391117095947266e-01 +7.010143551925869521e-03 diff --git a/test_loop/72/RunTimes.out b/test_loop/72/RunTimes.out new file mode 100644 index 0000000..78ba746 --- /dev/null +++ b/test_loop/72/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.351791143417 +Solver: 0.290228843689 +Keff: 0.044232168834063 +N_cores: 1 diff --git a/test_loop/72/SolverRes.txt b/test_loop/72/SolverRes.txt new file mode 100644 index 0000000..e1700b7 --- /dev/null +++ b/test_loop/72/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.423216883406300148e-02 +2.000000000000000000e+00 +6.420199871063232422e-01 +1.000000000000000000e+00 diff --git a/test_loop/72/V.npy b/test_loop/72/V.npy new file mode 100644 index 0000000..a50855d Binary files /dev/null and b/test_loop/72/V.npy differ diff --git a/test_loop/72/connec.out b/test_loop/72/connec.out new file mode 100644 index 0000000..a047cb8 --- /dev/null +++ b/test_loop/72/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.171875000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/72/k.npy b/test_loop/72/k.npy new file mode 100644 index 0000000..68f2585 Binary files /dev/null and b/test_loop/72/k.npy differ diff --git a/test_loop/72/lc.txt b/test_loop/72/lc.txt new file mode 100644 index 0000000..71c1cb4 --- /dev/null +++ b/test_loop/72/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.842027922506798809e+00 +2.701290424237670518e+00 +1.921429556830296148e+00 diff --git a/test_loop/72/tkperm_sub.txt b/test_loop/72/tkperm_sub.txt new file mode 100644 index 0000000..9796d90 --- /dev/null +++ b/test_loop/72/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.865199089050292969e-01 +1.640319824218750000e-04 +1.249313354492187500e-04 diff --git a/test_loop/73/Cmap.npy b/test_loop/73/Cmap.npy new file mode 100644 index 0000000..c05ee92 Binary files /dev/null and b/test_loop/73/Cmap.npy differ diff --git a/test_loop/73/ConnSummary.txt b/test_loop/73/ConnSummary.txt new file mode 100644 index 0000000..6f67d1a --- /dev/null +++ b/test_loop/73/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.950760364532470703e-01 +7.632277231666273476e-01 +5.377687953851046504e-02 diff --git a/test_loop/73/ConnectivityMetrics/16.npy b/test_loop/73/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d5a7fdb Binary files /dev/null and b/test_loop/73/ConnectivityMetrics/16.npy differ diff --git a/test_loop/73/ConnectivityMetrics/4.npy b/test_loop/73/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..b1b2ebf Binary files /dev/null and b/test_loop/73/ConnectivityMetrics/4.npy differ diff --git a/test_loop/73/ConnectivityMetrics/8.npy b/test_loop/73/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e122a17 Binary files /dev/null and b/test_loop/73/ConnectivityMetrics/8.npy differ diff --git a/test_loop/73/D.npy b/test_loop/73/D.npy new file mode 100644 index 0000000..f6102cb Binary files /dev/null and b/test_loop/73/D.npy differ diff --git a/test_loop/73/GenParams.txt b/test_loop/73/GenParams.txt new file mode 100644 index 0000000..40adf87 --- /dev/null +++ b/test_loop/73/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.005836486816406250e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.242857142857143105e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/73/GlobalConnectivityMetrics/16.npy b/test_loop/73/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d5a7fdb Binary files /dev/null and b/test_loop/73/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/73/GlobalConnectivityMetrics/4.npy b/test_loop/73/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..e67d58d Binary files /dev/null and b/test_loop/73/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/73/GlobalConnectivityMetrics/8.npy b/test_loop/73/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..da07423 Binary files /dev/null and b/test_loop/73/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/73/KpostProcess/Kd16.npy b/test_loop/73/KpostProcess/Kd16.npy new file mode 100644 index 0000000..56abac2 Binary files /dev/null and b/test_loop/73/KpostProcess/Kd16.npy differ diff --git a/test_loop/73/KpostProcess/Kd4.npy b/test_loop/73/KpostProcess/Kd4.npy new file mode 100644 index 0000000..b7bff06 Binary files /dev/null and b/test_loop/73/KpostProcess/Kd4.npy differ diff --git a/test_loop/73/KpostProcess/Kd8.npy b/test_loop/73/KpostProcess/Kd8.npy new file mode 100644 index 0000000..3d3768a Binary files /dev/null and b/test_loop/73/KpostProcess/Kd8.npy differ diff --git a/test_loop/73/KpostProcess/Kperm4.npy b/test_loop/73/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..4b1ea97 Binary files /dev/null and b/test_loop/73/KpostProcess/Kperm4.npy differ diff --git a/test_loop/73/KpostProcess/Kperm8.npy b/test_loop/73/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..4b1ea97 Binary files /dev/null and b/test_loop/73/KpostProcess/Kperm8.npy differ diff --git a/test_loop/73/KpostProcess/Kv16.npy b/test_loop/73/KpostProcess/Kv16.npy new file mode 100644 index 0000000..e79fd21 Binary files /dev/null and b/test_loop/73/KpostProcess/Kv16.npy differ diff --git a/test_loop/73/KpostProcess/Kv4.npy b/test_loop/73/KpostProcess/Kv4.npy new file mode 100644 index 0000000..28c4d55 Binary files /dev/null and b/test_loop/73/KpostProcess/Kv4.npy differ diff --git a/test_loop/73/KpostProcess/Kv8.npy b/test_loop/73/KpostProcess/Kv8.npy new file mode 100644 index 0000000..f8e04e6 Binary files /dev/null and b/test_loop/73/KpostProcess/Kv8.npy differ diff --git a/test_loop/73/P.npy b/test_loop/73/P.npy new file mode 100644 index 0000000..1c84a66 Binary files /dev/null and b/test_loop/73/P.npy differ diff --git a/test_loop/73/PosKeffSummary.txt b/test_loop/73/PosKeffSummary.txt new file mode 100644 index 0000000..e244394 --- /dev/null +++ b/test_loop/73/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.189116924980054169e+00 +1.221836019765234704e+00 +6.571054458618164062e-03 +1.900874424004934393e-01 diff --git a/test_loop/73/RunTimes.out b/test_loop/73/RunTimes.out new file mode 100644 index 0000000..4d915b8 --- /dev/null +++ b/test_loop/73/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.309148073196 +Solver: 0.167487859726 +Keff: 1.2218239763707606 +N_cores: 1 diff --git a/test_loop/73/SolverRes.txt b/test_loop/73/SolverRes.txt new file mode 100644 index 0000000..db1d651 --- /dev/null +++ b/test_loop/73/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.221823976370760567e+00 +2.000000000000000000e+00 +4.766359329223632812e-01 +1.000000000000000000e+00 diff --git a/test_loop/73/V.npy b/test_loop/73/V.npy new file mode 100644 index 0000000..917e54d Binary files /dev/null and b/test_loop/73/V.npy differ diff --git a/test_loop/73/connec.out b/test_loop/73/connec.out new file mode 100644 index 0000000..6c11ef7 --- /dev/null +++ b/test_loop/73/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 6.25000000E-02 + NCC : 1 + NCC : 2 diff --git a/test_loop/73/k.npy b/test_loop/73/k.npy new file mode 100644 index 0000000..a2928db Binary files /dev/null and b/test_loop/73/k.npy differ diff --git a/test_loop/73/lc.txt b/test_loop/73/lc.txt new file mode 100644 index 0000000..a478aca --- /dev/null +++ b/test_loop/73/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.481950964753760935e+01 +6.734754796602105742e+00 +5.100645026121492620e+00 diff --git a/test_loop/73/tkperm_sub.txt b/test_loop/73/tkperm_sub.txt new file mode 100644 index 0000000..a733385 --- /dev/null +++ b/test_loop/73/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.385159969329833984e-01 +2.131462097167968750e-04 diff --git a/test_loop/74/Cmap.npy b/test_loop/74/Cmap.npy new file mode 100644 index 0000000..935df05 Binary files /dev/null and b/test_loop/74/Cmap.npy differ diff --git a/test_loop/74/ConnSummary.txt b/test_loop/74/ConnSummary.txt new file mode 100644 index 0000000..5ebeed4 --- /dev/null +++ b/test_loop/74/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.546030521392822266e-01 +7.855602687531137995e-01 +4.447214540584261411e-02 diff --git a/test_loop/74/ConnectivityMetrics/16.npy b/test_loop/74/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..7748265 Binary files /dev/null and b/test_loop/74/ConnectivityMetrics/16.npy differ diff --git a/test_loop/74/ConnectivityMetrics/4.npy b/test_loop/74/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..c05ff6b Binary files /dev/null and b/test_loop/74/ConnectivityMetrics/4.npy differ diff --git a/test_loop/74/ConnectivityMetrics/8.npy b/test_loop/74/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..412a7a2 Binary files /dev/null and b/test_loop/74/ConnectivityMetrics/8.npy differ diff --git a/test_loop/74/D.npy b/test_loop/74/D.npy new file mode 100644 index 0000000..fe5f6eb Binary files /dev/null and b/test_loop/74/D.npy differ diff --git a/test_loop/74/GenParams.txt b/test_loop/74/GenParams.txt new file mode 100644 index 0000000..0c38173 --- /dev/null +++ b/test_loop/74/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.282878875732421875e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/74/GlobalConnectivityMetrics/16.npy b/test_loop/74/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..7748265 Binary files /dev/null and b/test_loop/74/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/74/GlobalConnectivityMetrics/4.npy b/test_loop/74/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..a78514e Binary files /dev/null and b/test_loop/74/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/74/GlobalConnectivityMetrics/8.npy b/test_loop/74/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..a72c436 Binary files /dev/null and b/test_loop/74/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/74/KpostProcess/Kd1.npy b/test_loop/74/KpostProcess/Kd1.npy new file mode 100644 index 0000000..8ab236e Binary files /dev/null and b/test_loop/74/KpostProcess/Kd1.npy differ diff --git a/test_loop/74/KpostProcess/Kd16.npy b/test_loop/74/KpostProcess/Kd16.npy new file mode 100644 index 0000000..0dd8a3a Binary files /dev/null and b/test_loop/74/KpostProcess/Kd16.npy differ diff --git a/test_loop/74/KpostProcess/Kd2.npy b/test_loop/74/KpostProcess/Kd2.npy new file mode 100644 index 0000000..9f1a137 Binary files /dev/null and b/test_loop/74/KpostProcess/Kd2.npy differ diff --git a/test_loop/74/KpostProcess/Kd4.npy b/test_loop/74/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7bdfb6e Binary files /dev/null and b/test_loop/74/KpostProcess/Kd4.npy differ diff --git a/test_loop/74/KpostProcess/Kd8.npy b/test_loop/74/KpostProcess/Kd8.npy new file mode 100644 index 0000000..fb8f9fb Binary files /dev/null and b/test_loop/74/KpostProcess/Kd8.npy differ diff --git a/test_loop/74/KpostProcess/Kperm2.npy b/test_loop/74/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..b68a877 Binary files /dev/null and b/test_loop/74/KpostProcess/Kperm2.npy differ diff --git a/test_loop/74/KpostProcess/Kperm4.npy b/test_loop/74/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..b68a877 Binary files /dev/null and b/test_loop/74/KpostProcess/Kperm4.npy differ diff --git a/test_loop/74/KpostProcess/Kperm8.npy b/test_loop/74/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..b68a877 Binary files /dev/null and b/test_loop/74/KpostProcess/Kperm8.npy differ diff --git a/test_loop/74/KpostProcess/Kv1.npy b/test_loop/74/KpostProcess/Kv1.npy new file mode 100644 index 0000000..74cf12a Binary files /dev/null and b/test_loop/74/KpostProcess/Kv1.npy differ diff --git a/test_loop/74/KpostProcess/Kv16.npy b/test_loop/74/KpostProcess/Kv16.npy new file mode 100644 index 0000000..0f62a52 Binary files /dev/null and b/test_loop/74/KpostProcess/Kv16.npy differ diff --git a/test_loop/74/KpostProcess/Kv2.npy b/test_loop/74/KpostProcess/Kv2.npy new file mode 100644 index 0000000..cf7eec6 Binary files /dev/null and b/test_loop/74/KpostProcess/Kv2.npy differ diff --git a/test_loop/74/KpostProcess/Kv4.npy b/test_loop/74/KpostProcess/Kv4.npy new file mode 100644 index 0000000..93960e9 Binary files /dev/null and b/test_loop/74/KpostProcess/Kv4.npy differ diff --git a/test_loop/74/KpostProcess/Kv8.npy b/test_loop/74/KpostProcess/Kv8.npy new file mode 100644 index 0000000..96c7c68 Binary files /dev/null and b/test_loop/74/KpostProcess/Kv8.npy differ diff --git a/test_loop/74/P.npy b/test_loop/74/P.npy new file mode 100644 index 0000000..5d97eb2 Binary files /dev/null and b/test_loop/74/P.npy differ diff --git a/test_loop/74/PosKeffSummary.txt b/test_loop/74/PosKeffSummary.txt new file mode 100644 index 0000000..d2467ad --- /dev/null +++ b/test_loop/74/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +6.613811407002997411e-01 +6.922635227651350309e-01 +1.555209159851074219e-01 +6.539915560583901659e-03 diff --git a/test_loop/74/RunTimes.out b/test_loop/74/RunTimes.out new file mode 100644 index 0000000..8829468 --- /dev/null +++ b/test_loop/74/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.297522068024 +Solver: 0.296460866928 +Keff: 0.6922952553374082 +N_cores: 1 diff --git a/test_loop/74/SolverRes.txt b/test_loop/74/SolverRes.txt new file mode 100644 index 0000000..e910f52 --- /dev/null +++ b/test_loop/74/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +6.922952553374082107e-01 +2.000000000000000000e+00 +5.939829349517822266e-01 +1.000000000000000000e+00 diff --git a/test_loop/74/V.npy b/test_loop/74/V.npy new file mode 100644 index 0000000..f92855e Binary files /dev/null and b/test_loop/74/V.npy differ diff --git a/test_loop/74/connec.out b/test_loop/74/connec.out new file mode 100644 index 0000000..35a50dc --- /dev/null +++ b/test_loop/74/connec.out @@ -0,0 +1,8 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.203125000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 diff --git a/test_loop/74/k.npy b/test_loop/74/k.npy new file mode 100644 index 0000000..db95cb7 Binary files /dev/null and b/test_loop/74/k.npy differ diff --git a/test_loop/74/lc.txt b/test_loop/74/lc.txt new file mode 100644 index 0000000..00c998c --- /dev/null +++ b/test_loop/74/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.858676663160393261e+00 +2.700615599511025255e+00 +2.062322292874636975e+00 diff --git a/test_loop/74/tkperm_sub.txt b/test_loop/74/tkperm_sub.txt new file mode 100644 index 0000000..9c1f02e --- /dev/null +++ b/test_loop/74/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.180001258850097656e-01 +1.678466796875000000e-04 +1.258850097656250000e-04 diff --git a/test_loop/75/Cmap.npy b/test_loop/75/Cmap.npy new file mode 100644 index 0000000..a2fabe4 Binary files /dev/null and b/test_loop/75/Cmap.npy differ diff --git a/test_loop/75/ConnSummary.txt b/test_loop/75/ConnSummary.txt new file mode 100644 index 0000000..4471aa0 --- /dev/null +++ b/test_loop/75/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.609070777893066406e-01 +7.663385199973047346e-01 +4.520219269445365645e-02 diff --git a/test_loop/75/ConnectivityMetrics/16.npy b/test_loop/75/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..b303e85 Binary files /dev/null and b/test_loop/75/ConnectivityMetrics/16.npy differ diff --git a/test_loop/75/ConnectivityMetrics/4.npy b/test_loop/75/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..8416374 Binary files /dev/null and b/test_loop/75/ConnectivityMetrics/4.npy differ diff --git a/test_loop/75/ConnectivityMetrics/8.npy b/test_loop/75/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..61a0fdf Binary files /dev/null and b/test_loop/75/ConnectivityMetrics/8.npy differ diff --git a/test_loop/75/D.npy b/test_loop/75/D.npy new file mode 100644 index 0000000..6753584 Binary files /dev/null and b/test_loop/75/D.npy differ diff --git a/test_loop/75/GenParams.txt b/test_loop/75/GenParams.txt new file mode 100644 index 0000000..c29c910 --- /dev/null +++ b/test_loop/75/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.886150360107421875e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.449999999999999956e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/75/GlobalConnectivityMetrics/16.npy b/test_loop/75/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..b303e85 Binary files /dev/null and b/test_loop/75/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/75/GlobalConnectivityMetrics/4.npy b/test_loop/75/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..b1857e9 Binary files /dev/null and b/test_loop/75/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/75/GlobalConnectivityMetrics/8.npy b/test_loop/75/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..44691ce Binary files /dev/null and b/test_loop/75/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/75/KpostProcess/Kd16.npy b/test_loop/75/KpostProcess/Kd16.npy new file mode 100644 index 0000000..32b0608 Binary files /dev/null and b/test_loop/75/KpostProcess/Kd16.npy differ diff --git a/test_loop/75/KpostProcess/Kd4.npy b/test_loop/75/KpostProcess/Kd4.npy new file mode 100644 index 0000000..1f3ba99 Binary files /dev/null and b/test_loop/75/KpostProcess/Kd4.npy differ diff --git a/test_loop/75/KpostProcess/Kd8.npy b/test_loop/75/KpostProcess/Kd8.npy new file mode 100644 index 0000000..bee20bb Binary files /dev/null and b/test_loop/75/KpostProcess/Kd8.npy differ diff --git a/test_loop/75/KpostProcess/Kperm4.npy b/test_loop/75/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..89fe08c Binary files /dev/null and b/test_loop/75/KpostProcess/Kperm4.npy differ diff --git a/test_loop/75/KpostProcess/Kperm8.npy b/test_loop/75/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..89fe08c Binary files /dev/null and b/test_loop/75/KpostProcess/Kperm8.npy differ diff --git a/test_loop/75/KpostProcess/Kv16.npy b/test_loop/75/KpostProcess/Kv16.npy new file mode 100644 index 0000000..05c97ff Binary files /dev/null and b/test_loop/75/KpostProcess/Kv16.npy differ diff --git a/test_loop/75/KpostProcess/Kv4.npy b/test_loop/75/KpostProcess/Kv4.npy new file mode 100644 index 0000000..756a1bc Binary files /dev/null and b/test_loop/75/KpostProcess/Kv4.npy differ diff --git a/test_loop/75/KpostProcess/Kv8.npy b/test_loop/75/KpostProcess/Kv8.npy new file mode 100644 index 0000000..a399566 Binary files /dev/null and b/test_loop/75/KpostProcess/Kv8.npy differ diff --git a/test_loop/75/P.npy b/test_loop/75/P.npy new file mode 100644 index 0000000..b34cd5f Binary files /dev/null and b/test_loop/75/P.npy differ diff --git a/test_loop/75/PosKeffSummary.txt b/test_loop/75/PosKeffSummary.txt new file mode 100644 index 0000000..6f05c55 --- /dev/null +++ b/test_loop/75/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.408931061535899421e+00 +1.449496782229666714e+00 +4.270076751708984375e-03 +2.447236180904522607e-01 diff --git a/test_loop/75/RunTimes.out b/test_loop/75/RunTimes.out new file mode 100644 index 0000000..288e3ba --- /dev/null +++ b/test_loop/75/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.292932033539 +Solver: 0.254172086716 +Keff: 1.4495307211375206 +N_cores: 1 diff --git a/test_loop/75/SolverRes.txt b/test_loop/75/SolverRes.txt new file mode 100644 index 0000000..dcdf9c8 --- /dev/null +++ b/test_loop/75/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.449530721137520572e+00 +2.000000000000000000e+00 +5.471041202545166016e-01 +1.000000000000000000e+00 diff --git a/test_loop/75/V.npy b/test_loop/75/V.npy new file mode 100644 index 0000000..fc9d73d Binary files /dev/null and b/test_loop/75/V.npy differ diff --git a/test_loop/75/connec.out b/test_loop/75/connec.out new file mode 100644 index 0000000..7d7aec0 --- /dev/null +++ b/test_loop/75/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.140625000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/75/k.npy b/test_loop/75/k.npy new file mode 100644 index 0000000..899bb8a Binary files /dev/null and b/test_loop/75/k.npy differ diff --git a/test_loop/75/lc.txt b/test_loop/75/lc.txt new file mode 100644 index 0000000..16535b6 --- /dev/null +++ b/test_loop/75/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.488480123294379176e+01 +6.783191993251341145e+00 +4.853744139607076846e+00 diff --git a/test_loop/75/tkperm_sub.txt b/test_loop/75/tkperm_sub.txt new file mode 100644 index 0000000..a60d73d --- /dev/null +++ b/test_loop/75/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.472969532012939453e-01 +1.628398895263671875e-04 diff --git a/test_loop/76/Cmap.npy b/test_loop/76/Cmap.npy new file mode 100644 index 0000000..7092996 Binary files /dev/null and b/test_loop/76/Cmap.npy differ diff --git a/test_loop/76/ConnSummary.txt b/test_loop/76/ConnSummary.txt new file mode 100644 index 0000000..7842a81 --- /dev/null +++ b/test_loop/76/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.597919940948486328e-01 +7.545751475902157113e-01 +4.219334069765823952e-02 diff --git a/test_loop/76/ConnectivityMetrics/16.npy b/test_loop/76/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..8b91637 Binary files /dev/null and b/test_loop/76/ConnectivityMetrics/16.npy differ diff --git a/test_loop/76/ConnectivityMetrics/4.npy b/test_loop/76/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..e05d2f2 Binary files /dev/null and b/test_loop/76/ConnectivityMetrics/4.npy differ diff --git a/test_loop/76/ConnectivityMetrics/8.npy b/test_loop/76/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..88ea684 Binary files /dev/null and b/test_loop/76/ConnectivityMetrics/8.npy differ diff --git a/test_loop/76/D.npy b/test_loop/76/D.npy new file mode 100644 index 0000000..5ff46c0 Binary files /dev/null and b/test_loop/76/D.npy differ diff --git a/test_loop/76/GenParams.txt b/test_loop/76/GenParams.txt new file mode 100644 index 0000000..aaf8071 --- /dev/null +++ b/test_loop/76/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.782127380371093750e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/76/GlobalConnectivityMetrics/16.npy b/test_loop/76/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..8b91637 Binary files /dev/null and b/test_loop/76/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/76/GlobalConnectivityMetrics/4.npy b/test_loop/76/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..a7bec09 Binary files /dev/null and b/test_loop/76/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/76/GlobalConnectivityMetrics/8.npy b/test_loop/76/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..15c135a Binary files /dev/null and b/test_loop/76/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/76/KpostProcess/Kd1.npy b/test_loop/76/KpostProcess/Kd1.npy new file mode 100644 index 0000000..c9f9c30 Binary files /dev/null and b/test_loop/76/KpostProcess/Kd1.npy differ diff --git a/test_loop/76/KpostProcess/Kd16.npy b/test_loop/76/KpostProcess/Kd16.npy new file mode 100644 index 0000000..72256c4 Binary files /dev/null and b/test_loop/76/KpostProcess/Kd16.npy differ diff --git a/test_loop/76/KpostProcess/Kd2.npy b/test_loop/76/KpostProcess/Kd2.npy new file mode 100644 index 0000000..a2d00cc Binary files /dev/null and b/test_loop/76/KpostProcess/Kd2.npy differ diff --git a/test_loop/76/KpostProcess/Kd4.npy b/test_loop/76/KpostProcess/Kd4.npy new file mode 100644 index 0000000..5e7a92c Binary files /dev/null and b/test_loop/76/KpostProcess/Kd4.npy differ diff --git a/test_loop/76/KpostProcess/Kd8.npy b/test_loop/76/KpostProcess/Kd8.npy new file mode 100644 index 0000000..e6834da Binary files /dev/null and b/test_loop/76/KpostProcess/Kd8.npy differ diff --git a/test_loop/76/KpostProcess/Kperm2.npy b/test_loop/76/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..0c2f026 Binary files /dev/null and b/test_loop/76/KpostProcess/Kperm2.npy differ diff --git a/test_loop/76/KpostProcess/Kperm4.npy b/test_loop/76/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..0c2f026 Binary files /dev/null and b/test_loop/76/KpostProcess/Kperm4.npy differ diff --git a/test_loop/76/KpostProcess/Kperm8.npy b/test_loop/76/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..0c2f026 Binary files /dev/null and b/test_loop/76/KpostProcess/Kperm8.npy differ diff --git a/test_loop/76/KpostProcess/Kv1.npy b/test_loop/76/KpostProcess/Kv1.npy new file mode 100644 index 0000000..bc68987 Binary files /dev/null and b/test_loop/76/KpostProcess/Kv1.npy differ diff --git a/test_loop/76/KpostProcess/Kv16.npy b/test_loop/76/KpostProcess/Kv16.npy new file mode 100644 index 0000000..345bb6e Binary files /dev/null and b/test_loop/76/KpostProcess/Kv16.npy differ diff --git a/test_loop/76/KpostProcess/Kv2.npy b/test_loop/76/KpostProcess/Kv2.npy new file mode 100644 index 0000000..d099ebe Binary files /dev/null and b/test_loop/76/KpostProcess/Kv2.npy differ diff --git a/test_loop/76/KpostProcess/Kv4.npy b/test_loop/76/KpostProcess/Kv4.npy new file mode 100644 index 0000000..f84ec37 Binary files /dev/null and b/test_loop/76/KpostProcess/Kv4.npy differ diff --git a/test_loop/76/KpostProcess/Kv8.npy b/test_loop/76/KpostProcess/Kv8.npy new file mode 100644 index 0000000..80b7c7f Binary files /dev/null and b/test_loop/76/KpostProcess/Kv8.npy differ diff --git a/test_loop/76/P.npy b/test_loop/76/P.npy new file mode 100644 index 0000000..b62760b Binary files /dev/null and b/test_loop/76/P.npy differ diff --git a/test_loop/76/PosKeffSummary.txt b/test_loop/76/PosKeffSummary.txt new file mode 100644 index 0000000..0ec9bb9 --- /dev/null +++ b/test_loop/76/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +9.123615966371085850e-01 +9.567591856211739021e-01 +1.536750793457031250e-01 +6.865148318232592792e-03 diff --git a/test_loop/76/RunTimes.out b/test_loop/76/RunTimes.out new file mode 100644 index 0000000..61ce38f --- /dev/null +++ b/test_loop/76/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.33684015274 +Solver: 0.263957977295 +Keff: 0.9566835273790869 +N_cores: 1 diff --git a/test_loop/76/SolverRes.txt b/test_loop/76/SolverRes.txt new file mode 100644 index 0000000..6b791c8 --- /dev/null +++ b/test_loop/76/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +9.566835273790869065e-01 +2.000000000000000000e+00 +6.007981300354003906e-01 +1.000000000000000000e+00 diff --git a/test_loop/76/V.npy b/test_loop/76/V.npy new file mode 100644 index 0000000..253c9e3 Binary files /dev/null and b/test_loop/76/V.npy differ diff --git a/test_loop/76/connec.out b/test_loop/76/connec.out new file mode 100644 index 0000000..ee2d7b5 --- /dev/null +++ b/test_loop/76/connec.out @@ -0,0 +1,8 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.218750000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 diff --git a/test_loop/76/k.npy b/test_loop/76/k.npy new file mode 100644 index 0000000..13045e6 Binary files /dev/null and b/test_loop/76/k.npy differ diff --git a/test_loop/76/lc.txt b/test_loop/76/lc.txt new file mode 100644 index 0000000..c79f945 --- /dev/null +++ b/test_loop/76/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.879161619069331657e+00 +2.708887868195497095e+00 +2.102690765458583577e+00 diff --git a/test_loop/76/tkperm_sub.txt b/test_loop/76/tkperm_sub.txt new file mode 100644 index 0000000..2c2d5f4 --- /dev/null +++ b/test_loop/76/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.208521842956542969e-01 +1.649856567382812500e-04 +1.249313354492187500e-04 diff --git a/test_loop/77/Cmap.npy b/test_loop/77/Cmap.npy new file mode 100644 index 0000000..785f86e Binary files /dev/null and b/test_loop/77/Cmap.npy differ diff --git a/test_loop/77/ConnSummary.txt b/test_loop/77/ConnSummary.txt new file mode 100644 index 0000000..c0618e1 --- /dev/null +++ b/test_loop/77/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.750181198120117188e-01 +7.833699950411331381e-01 +4.700242857324500589e-02 diff --git a/test_loop/77/ConnectivityMetrics/16.npy b/test_loop/77/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..59f8e32 Binary files /dev/null and b/test_loop/77/ConnectivityMetrics/16.npy differ diff --git a/test_loop/77/ConnectivityMetrics/4.npy b/test_loop/77/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..19eb33e Binary files /dev/null and b/test_loop/77/ConnectivityMetrics/4.npy differ diff --git a/test_loop/77/ConnectivityMetrics/8.npy b/test_loop/77/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..90b0fdf Binary files /dev/null and b/test_loop/77/ConnectivityMetrics/8.npy differ diff --git a/test_loop/77/D.npy b/test_loop/77/D.npy new file mode 100644 index 0000000..a2e5cda Binary files /dev/null and b/test_loop/77/D.npy differ diff --git a/test_loop/77/GenParams.txt b/test_loop/77/GenParams.txt new file mode 100644 index 0000000..8f0fba4 --- /dev/null +++ b/test_loop/77/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.078958511352539062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.657142857142857362e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/77/GlobalConnectivityMetrics/16.npy b/test_loop/77/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..59f8e32 Binary files /dev/null and b/test_loop/77/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/77/GlobalConnectivityMetrics/4.npy b/test_loop/77/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..eb24042 Binary files /dev/null and b/test_loop/77/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/77/GlobalConnectivityMetrics/8.npy b/test_loop/77/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..05a2997 Binary files /dev/null and b/test_loop/77/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/77/KpostProcess/Kd16.npy b/test_loop/77/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2065d3f Binary files /dev/null and b/test_loop/77/KpostProcess/Kd16.npy differ diff --git a/test_loop/77/KpostProcess/Kd4.npy b/test_loop/77/KpostProcess/Kd4.npy new file mode 100644 index 0000000..436fcf1 Binary files /dev/null and b/test_loop/77/KpostProcess/Kd4.npy differ diff --git a/test_loop/77/KpostProcess/Kd8.npy b/test_loop/77/KpostProcess/Kd8.npy new file mode 100644 index 0000000..6a73f36 Binary files /dev/null and b/test_loop/77/KpostProcess/Kd8.npy differ diff --git a/test_loop/77/KpostProcess/Kperm4.npy b/test_loop/77/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e6b4bc4 Binary files /dev/null and b/test_loop/77/KpostProcess/Kperm4.npy differ diff --git a/test_loop/77/KpostProcess/Kperm8.npy b/test_loop/77/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e6b4bc4 Binary files /dev/null and b/test_loop/77/KpostProcess/Kperm8.npy differ diff --git a/test_loop/77/KpostProcess/Kv16.npy b/test_loop/77/KpostProcess/Kv16.npy new file mode 100644 index 0000000..77e1090 Binary files /dev/null and b/test_loop/77/KpostProcess/Kv16.npy differ diff --git a/test_loop/77/KpostProcess/Kv4.npy b/test_loop/77/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d72df4e Binary files /dev/null and b/test_loop/77/KpostProcess/Kv4.npy differ diff --git a/test_loop/77/KpostProcess/Kv8.npy b/test_loop/77/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0813d6b Binary files /dev/null and b/test_loop/77/KpostProcess/Kv8.npy differ diff --git a/test_loop/77/P.npy b/test_loop/77/P.npy new file mode 100644 index 0000000..d6867a3 Binary files /dev/null and b/test_loop/77/P.npy differ diff --git a/test_loop/77/PosKeffSummary.txt b/test_loop/77/PosKeffSummary.txt new file mode 100644 index 0000000..0b8e69d --- /dev/null +++ b/test_loop/77/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.469073755489453958e+00 +1.506057275313267052e+00 +4.659175872802734375e-03 +2.440384812199365427e-01 diff --git a/test_loop/77/RunTimes.out b/test_loop/77/RunTimes.out new file mode 100644 index 0000000..0699b9b --- /dev/null +++ b/test_loop/77/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.450544834137 +Solver: 0.220173120499 +Keff: 1.5060449233027289 +N_cores: 1 diff --git a/test_loop/77/SolverRes.txt b/test_loop/77/SolverRes.txt new file mode 100644 index 0000000..d13f5ac --- /dev/null +++ b/test_loop/77/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.506044923302728877e+00 +2.000000000000000000e+00 +6.707179546356201172e-01 +1.000000000000000000e+00 diff --git a/test_loop/77/V.npy b/test_loop/77/V.npy new file mode 100644 index 0000000..2ae5e79 Binary files /dev/null and b/test_loop/77/V.npy differ diff --git a/test_loop/77/connec.out b/test_loop/77/connec.out new file mode 100644 index 0000000..7d7aec0 --- /dev/null +++ b/test_loop/77/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.140625000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/77/k.npy b/test_loop/77/k.npy new file mode 100644 index 0000000..fa10fed Binary files /dev/null and b/test_loop/77/k.npy differ diff --git a/test_loop/77/lc.txt b/test_loop/77/lc.txt new file mode 100644 index 0000000..3d9c0f5 --- /dev/null +++ b/test_loop/77/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.496510460503824191e+01 +6.852956107841967182e+00 +4.831323028571360645e+00 diff --git a/test_loop/77/tkperm_sub.txt b/test_loop/77/tkperm_sub.txt new file mode 100644 index 0000000..1f0fd5c --- /dev/null +++ b/test_loop/77/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.332381248474121094e-01 +1.680850982666015625e-04 diff --git a/test_loop/78/Cmap.npy b/test_loop/78/Cmap.npy new file mode 100644 index 0000000..43626ab Binary files /dev/null and b/test_loop/78/Cmap.npy differ diff --git a/test_loop/78/ConnSummary.txt b/test_loop/78/ConnSummary.txt new file mode 100644 index 0000000..cda7d14 --- /dev/null +++ b/test_loop/78/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.644811153411865234e-01 +8.104805779768244900e-01 +3.936453347363558231e-02 diff --git a/test_loop/78/ConnectivityMetrics/16.npy b/test_loop/78/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c8df106 Binary files /dev/null and b/test_loop/78/ConnectivityMetrics/16.npy differ diff --git a/test_loop/78/ConnectivityMetrics/4.npy b/test_loop/78/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..9eb9ee5 Binary files /dev/null and b/test_loop/78/ConnectivityMetrics/4.npy differ diff --git a/test_loop/78/ConnectivityMetrics/8.npy b/test_loop/78/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..1cc9205 Binary files /dev/null and b/test_loop/78/ConnectivityMetrics/8.npy differ diff --git a/test_loop/78/D.npy b/test_loop/78/D.npy new file mode 100644 index 0000000..0dc16fc Binary files /dev/null and b/test_loop/78/D.npy differ diff --git a/test_loop/78/GenParams.txt b/test_loop/78/GenParams.txt new file mode 100644 index 0000000..ca9717f --- /dev/null +++ b/test_loop/78/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.009174346923828125e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/78/GlobalConnectivityMetrics/16.npy b/test_loop/78/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c8df106 Binary files /dev/null and b/test_loop/78/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/78/GlobalConnectivityMetrics/4.npy b/test_loop/78/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..8831ad5 Binary files /dev/null and b/test_loop/78/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/78/GlobalConnectivityMetrics/8.npy b/test_loop/78/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..33453da Binary files /dev/null and b/test_loop/78/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/78/KpostProcess/Kd1.npy b/test_loop/78/KpostProcess/Kd1.npy new file mode 100644 index 0000000..a4e309e Binary files /dev/null and b/test_loop/78/KpostProcess/Kd1.npy differ diff --git a/test_loop/78/KpostProcess/Kd16.npy b/test_loop/78/KpostProcess/Kd16.npy new file mode 100644 index 0000000..77f463f Binary files /dev/null and b/test_loop/78/KpostProcess/Kd16.npy differ diff --git a/test_loop/78/KpostProcess/Kd2.npy b/test_loop/78/KpostProcess/Kd2.npy new file mode 100644 index 0000000..0748c27 Binary files /dev/null and b/test_loop/78/KpostProcess/Kd2.npy differ diff --git a/test_loop/78/KpostProcess/Kd4.npy b/test_loop/78/KpostProcess/Kd4.npy new file mode 100644 index 0000000..1b23f96 Binary files /dev/null and b/test_loop/78/KpostProcess/Kd4.npy differ diff --git a/test_loop/78/KpostProcess/Kd8.npy b/test_loop/78/KpostProcess/Kd8.npy new file mode 100644 index 0000000..b8e8138 Binary files /dev/null and b/test_loop/78/KpostProcess/Kd8.npy differ diff --git a/test_loop/78/KpostProcess/Kperm2.npy b/test_loop/78/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..352e29b Binary files /dev/null and b/test_loop/78/KpostProcess/Kperm2.npy differ diff --git a/test_loop/78/KpostProcess/Kperm4.npy b/test_loop/78/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..352e29b Binary files /dev/null and b/test_loop/78/KpostProcess/Kperm4.npy differ diff --git a/test_loop/78/KpostProcess/Kperm8.npy b/test_loop/78/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..352e29b Binary files /dev/null and b/test_loop/78/KpostProcess/Kperm8.npy differ diff --git a/test_loop/78/KpostProcess/Kv1.npy b/test_loop/78/KpostProcess/Kv1.npy new file mode 100644 index 0000000..b58b295 Binary files /dev/null and b/test_loop/78/KpostProcess/Kv1.npy differ diff --git a/test_loop/78/KpostProcess/Kv16.npy b/test_loop/78/KpostProcess/Kv16.npy new file mode 100644 index 0000000..6185fbc Binary files /dev/null and b/test_loop/78/KpostProcess/Kv16.npy differ diff --git a/test_loop/78/KpostProcess/Kv2.npy b/test_loop/78/KpostProcess/Kv2.npy new file mode 100644 index 0000000..a144b5c Binary files /dev/null and b/test_loop/78/KpostProcess/Kv2.npy differ diff --git a/test_loop/78/KpostProcess/Kv4.npy b/test_loop/78/KpostProcess/Kv4.npy new file mode 100644 index 0000000..4272074 Binary files /dev/null and b/test_loop/78/KpostProcess/Kv4.npy differ diff --git a/test_loop/78/KpostProcess/Kv8.npy b/test_loop/78/KpostProcess/Kv8.npy new file mode 100644 index 0000000..63fa75f Binary files /dev/null and b/test_loop/78/KpostProcess/Kv8.npy differ diff --git a/test_loop/78/P.npy b/test_loop/78/P.npy new file mode 100644 index 0000000..3672744 Binary files /dev/null and b/test_loop/78/P.npy differ diff --git a/test_loop/78/PosKeffSummary.txt b/test_loop/78/PosKeffSummary.txt new file mode 100644 index 0000000..51a23b6 --- /dev/null +++ b/test_loop/78/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.029680148037863452e+00 +1.081448567147859308e+00 +1.484880447387695312e-01 +6.929949069049010785e-03 diff --git a/test_loop/78/RunTimes.out b/test_loop/78/RunTimes.out new file mode 100644 index 0000000..527a75b --- /dev/null +++ b/test_loop/78/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.306751966476 +Solver: 0.255385160446 +Keff: 1.0814209039624705 +N_cores: 1 diff --git a/test_loop/78/SolverRes.txt b/test_loop/78/SolverRes.txt new file mode 100644 index 0000000..28f4749 --- /dev/null +++ b/test_loop/78/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.081420903962470481e+00 +2.000000000000000000e+00 +5.621371269226074219e-01 +1.000000000000000000e+00 diff --git a/test_loop/78/V.npy b/test_loop/78/V.npy new file mode 100644 index 0000000..7c6ce5c Binary files /dev/null and b/test_loop/78/V.npy differ diff --git a/test_loop/78/connec.out b/test_loop/78/connec.out new file mode 100644 index 0000000..1bbe897 --- /dev/null +++ b/test_loop/78/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.250000000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/78/k.npy b/test_loop/78/k.npy new file mode 100644 index 0000000..5248cbb Binary files /dev/null and b/test_loop/78/k.npy differ diff --git a/test_loop/78/lc.txt b/test_loop/78/lc.txt new file mode 100644 index 0000000..d191192 --- /dev/null +++ b/test_loop/78/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.904564020510251865e+00 +2.695375363147585190e+00 +2.236725000080284076e+00 diff --git a/test_loop/78/tkperm_sub.txt b/test_loop/78/tkperm_sub.txt new file mode 100644 index 0000000..d359bd3 --- /dev/null +++ b/test_loop/78/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.852620124816894531e-01 +1.640319824218750000e-04 +1.251697540283203125e-04 diff --git a/test_loop/79/Cmap.npy b/test_loop/79/Cmap.npy new file mode 100644 index 0000000..5c6d2bb Binary files /dev/null and b/test_loop/79/Cmap.npy differ diff --git a/test_loop/79/ConnSummary.txt b/test_loop/79/ConnSummary.txt new file mode 100644 index 0000000..dc4adbc --- /dev/null +++ b/test_loop/79/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.561098575592041016e-01 +7.910001988440266141e-01 +4.934679402503827639e-02 diff --git a/test_loop/79/ConnectivityMetrics/16.npy b/test_loop/79/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..d9778c0 Binary files /dev/null and b/test_loop/79/ConnectivityMetrics/16.npy differ diff --git a/test_loop/79/ConnectivityMetrics/4.npy b/test_loop/79/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..a7c2bb7 Binary files /dev/null and b/test_loop/79/ConnectivityMetrics/4.npy differ diff --git a/test_loop/79/ConnectivityMetrics/8.npy b/test_loop/79/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..66f0989 Binary files /dev/null and b/test_loop/79/ConnectivityMetrics/8.npy differ diff --git a/test_loop/79/D.npy b/test_loop/79/D.npy new file mode 100644 index 0000000..467f11d Binary files /dev/null and b/test_loop/79/D.npy differ diff --git a/test_loop/79/GenParams.txt b/test_loop/79/GenParams.txt new file mode 100644 index 0000000..c78bf86 --- /dev/null +++ b/test_loop/79/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.748987197875976562e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +2.864285714285714768e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/79/GlobalConnectivityMetrics/16.npy b/test_loop/79/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..d9778c0 Binary files /dev/null and b/test_loop/79/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/79/GlobalConnectivityMetrics/4.npy b/test_loop/79/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..0517fbd Binary files /dev/null and b/test_loop/79/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/79/GlobalConnectivityMetrics/8.npy b/test_loop/79/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..905b36e Binary files /dev/null and b/test_loop/79/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/79/KpostProcess/Kd16.npy b/test_loop/79/KpostProcess/Kd16.npy new file mode 100644 index 0000000..cb73e91 Binary files /dev/null and b/test_loop/79/KpostProcess/Kd16.npy differ diff --git a/test_loop/79/KpostProcess/Kd4.npy b/test_loop/79/KpostProcess/Kd4.npy new file mode 100644 index 0000000..1f14ea8 Binary files /dev/null and b/test_loop/79/KpostProcess/Kd4.npy differ diff --git a/test_loop/79/KpostProcess/Kd8.npy b/test_loop/79/KpostProcess/Kd8.npy new file mode 100644 index 0000000..253dc9b Binary files /dev/null and b/test_loop/79/KpostProcess/Kd8.npy differ diff --git a/test_loop/79/KpostProcess/Kperm4.npy b/test_loop/79/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..8ee0543 Binary files /dev/null and b/test_loop/79/KpostProcess/Kperm4.npy differ diff --git a/test_loop/79/KpostProcess/Kperm8.npy b/test_loop/79/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..8ee0543 Binary files /dev/null and b/test_loop/79/KpostProcess/Kperm8.npy differ diff --git a/test_loop/79/KpostProcess/Kv16.npy b/test_loop/79/KpostProcess/Kv16.npy new file mode 100644 index 0000000..a465e4f Binary files /dev/null and b/test_loop/79/KpostProcess/Kv16.npy differ diff --git a/test_loop/79/KpostProcess/Kv4.npy b/test_loop/79/KpostProcess/Kv4.npy new file mode 100644 index 0000000..960151d Binary files /dev/null and b/test_loop/79/KpostProcess/Kv4.npy differ diff --git a/test_loop/79/KpostProcess/Kv8.npy b/test_loop/79/KpostProcess/Kv8.npy new file mode 100644 index 0000000..41791bc Binary files /dev/null and b/test_loop/79/KpostProcess/Kv8.npy differ diff --git a/test_loop/79/P.npy b/test_loop/79/P.npy new file mode 100644 index 0000000..ca9dec1 Binary files /dev/null and b/test_loop/79/P.npy differ diff --git a/test_loop/79/PosKeffSummary.txt b/test_loop/79/PosKeffSummary.txt new file mode 100644 index 0000000..581c1ef --- /dev/null +++ b/test_loop/79/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +1.547830305829592801e+00 +1.586608948276717168e+00 +4.370927810668945312e-03 +2.438771614029346113e-01 diff --git a/test_loop/79/RunTimes.out b/test_loop/79/RunTimes.out new file mode 100644 index 0000000..80384ef --- /dev/null +++ b/test_loop/79/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.39253115654 +Solver: 0.198072910309 +Keff: 1.5866896590910533 +N_cores: 1 diff --git a/test_loop/79/SolverRes.txt b/test_loop/79/SolverRes.txt new file mode 100644 index 0000000..b22074d --- /dev/null +++ b/test_loop/79/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +1.586689659091053306e+00 +2.000000000000000000e+00 +5.906040668487548828e-01 +1.000000000000000000e+00 diff --git a/test_loop/79/V.npy b/test_loop/79/V.npy new file mode 100644 index 0000000..2feefc0 Binary files /dev/null and b/test_loop/79/V.npy differ diff --git a/test_loop/79/connec.out b/test_loop/79/connec.out new file mode 100644 index 0000000..6ff4550 --- /dev/null +++ b/test_loop/79/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.156250000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/79/k.npy b/test_loop/79/k.npy new file mode 100644 index 0000000..c2b8a14 Binary files /dev/null and b/test_loop/79/k.npy differ diff --git a/test_loop/79/lc.txt b/test_loop/79/lc.txt new file mode 100644 index 0000000..97b9e28 --- /dev/null +++ b/test_loop/79/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.506458201495093618e+01 +6.976518204234796627e+00 +4.680149005982412902e+00 diff --git a/test_loop/79/tkperm_sub.txt b/test_loop/79/tkperm_sub.txt new file mode 100644 index 0000000..36fcc07 --- /dev/null +++ b/test_loop/79/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.189179897308349609e-01 +1.668930053710937500e-04 diff --git a/test_loop/8/Cmap.npy b/test_loop/8/Cmap.npy new file mode 100644 index 0000000..326f52c Binary files /dev/null and b/test_loop/8/Cmap.npy differ diff --git a/test_loop/8/ConnSummary.txt b/test_loop/8/ConnSummary.txt new file mode 100644 index 0000000..edfc028 --- /dev/null +++ b/test_loop/8/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.162440299987792969e-01 +7.230661899563193273e-01 +5.773105883997172588e-02 diff --git a/test_loop/8/ConnectivityMetrics/16.npy b/test_loop/8/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..5d7623f Binary files /dev/null and b/test_loop/8/ConnectivityMetrics/16.npy differ diff --git a/test_loop/8/ConnectivityMetrics/4.npy b/test_loop/8/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..1b0bbe1 Binary files /dev/null and b/test_loop/8/ConnectivityMetrics/4.npy differ diff --git a/test_loop/8/ConnectivityMetrics/8.npy b/test_loop/8/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..346bd74 Binary files /dev/null and b/test_loop/8/ConnectivityMetrics/8.npy differ diff --git a/test_loop/8/D.npy b/test_loop/8/D.npy new file mode 100644 index 0000000..7738d48 Binary files /dev/null and b/test_loop/8/D.npy differ diff --git a/test_loop/8/GenParams.txt b/test_loop/8/GenParams.txt new file mode 100644 index 0000000..cf945f8 --- /dev/null +++ b/test_loop/8/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.330158233642578125e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/8/GlobalConnectivityMetrics/16.npy b/test_loop/8/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..5d7623f Binary files /dev/null and b/test_loop/8/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/8/GlobalConnectivityMetrics/4.npy b/test_loop/8/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..40a0d5c Binary files /dev/null and b/test_loop/8/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/8/GlobalConnectivityMetrics/8.npy b/test_loop/8/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..d18b58e Binary files /dev/null and b/test_loop/8/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/8/KpostProcess/Kd1.npy b/test_loop/8/KpostProcess/Kd1.npy new file mode 100644 index 0000000..7b27bb9 Binary files /dev/null and b/test_loop/8/KpostProcess/Kd1.npy differ diff --git a/test_loop/8/KpostProcess/Kd16.npy b/test_loop/8/KpostProcess/Kd16.npy new file mode 100644 index 0000000..9998784 Binary files /dev/null and b/test_loop/8/KpostProcess/Kd16.npy differ diff --git a/test_loop/8/KpostProcess/Kd2.npy b/test_loop/8/KpostProcess/Kd2.npy new file mode 100644 index 0000000..d809e86 Binary files /dev/null and b/test_loop/8/KpostProcess/Kd2.npy differ diff --git a/test_loop/8/KpostProcess/Kd4.npy b/test_loop/8/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0772228 Binary files /dev/null and b/test_loop/8/KpostProcess/Kd4.npy differ diff --git a/test_loop/8/KpostProcess/Kd8.npy b/test_loop/8/KpostProcess/Kd8.npy new file mode 100644 index 0000000..7b9aa4f Binary files /dev/null and b/test_loop/8/KpostProcess/Kd8.npy differ diff --git a/test_loop/8/KpostProcess/Kperm2.npy b/test_loop/8/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..eb2edc7 Binary files /dev/null and b/test_loop/8/KpostProcess/Kperm2.npy differ diff --git a/test_loop/8/KpostProcess/Kperm4.npy b/test_loop/8/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..eb2edc7 Binary files /dev/null and b/test_loop/8/KpostProcess/Kperm4.npy differ diff --git a/test_loop/8/KpostProcess/Kperm8.npy b/test_loop/8/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..eb2edc7 Binary files /dev/null and b/test_loop/8/KpostProcess/Kperm8.npy differ diff --git a/test_loop/8/KpostProcess/Kv1.npy b/test_loop/8/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6ac91e7 Binary files /dev/null and b/test_loop/8/KpostProcess/Kv1.npy differ diff --git a/test_loop/8/KpostProcess/Kv16.npy b/test_loop/8/KpostProcess/Kv16.npy new file mode 100644 index 0000000..86bf9b5 Binary files /dev/null and b/test_loop/8/KpostProcess/Kv16.npy differ diff --git a/test_loop/8/KpostProcess/Kv2.npy b/test_loop/8/KpostProcess/Kv2.npy new file mode 100644 index 0000000..612a972 Binary files /dev/null and b/test_loop/8/KpostProcess/Kv2.npy differ diff --git a/test_loop/8/KpostProcess/Kv4.npy b/test_loop/8/KpostProcess/Kv4.npy new file mode 100644 index 0000000..251b81a Binary files /dev/null and b/test_loop/8/KpostProcess/Kv4.npy differ diff --git a/test_loop/8/KpostProcess/Kv8.npy b/test_loop/8/KpostProcess/Kv8.npy new file mode 100644 index 0000000..99aa378 Binary files /dev/null and b/test_loop/8/KpostProcess/Kv8.npy differ diff --git a/test_loop/8/P.npy b/test_loop/8/P.npy new file mode 100644 index 0000000..c13cbf6 Binary files /dev/null and b/test_loop/8/P.npy differ diff --git a/test_loop/8/PosKeffSummary.txt b/test_loop/8/PosKeffSummary.txt new file mode 100644 index 0000000..30b22c0 --- /dev/null +++ b/test_loop/8/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.665617936311880987e-02 +3.712077644148291389e-02 +2.178778648376464844e-01 +7.030725089347658434e-03 diff --git a/test_loop/8/RunTimes.out b/test_loop/8/RunTimes.out new file mode 100644 index 0000000..626c125 --- /dev/null +++ b/test_loop/8/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.304397106171 +Solver: 0.267277956009 +Keff: 0.036613409479731886 +N_cores: 1 diff --git a/test_loop/8/SolverRes.txt b/test_loop/8/SolverRes.txt new file mode 100644 index 0000000..d65c104 --- /dev/null +++ b/test_loop/8/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.661340947973188570e-02 +2.000000000000000000e+00 +5.716750621795654297e-01 +1.000000000000000000e+00 diff --git a/test_loop/8/V.npy b/test_loop/8/V.npy new file mode 100644 index 0000000..420f7a5 Binary files /dev/null and b/test_loop/8/V.npy differ diff --git a/test_loop/8/connec.out b/test_loop/8/connec.out new file mode 100644 index 0000000..da7804e --- /dev/null +++ b/test_loop/8/connec.out @@ -0,0 +1,5 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 1.56250000E-02 + NCC : 1 diff --git a/test_loop/8/k.npy b/test_loop/8/k.npy new file mode 100644 index 0000000..a8e5b14 Binary files /dev/null and b/test_loop/8/k.npy differ diff --git a/test_loop/8/lc.txt b/test_loop/8/lc.txt new file mode 100644 index 0000000..5d5a7b6 --- /dev/null +++ b/test_loop/8/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +4.392273776273362351e+00 +4.392273776273362351e+00 +4.752608333212584135e+00 diff --git a/test_loop/8/tkperm_sub.txt b/test_loop/8/tkperm_sub.txt new file mode 100644 index 0000000..b3c933f --- /dev/null +++ b/test_loop/8/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.838479995727539062e-01 +1.800060272216796875e-04 +1.318454742431640625e-04 diff --git a/test_loop/80/Cmap.npy b/test_loop/80/Cmap.npy new file mode 100644 index 0000000..0ff6d57 Binary files /dev/null and b/test_loop/80/Cmap.npy differ diff --git a/test_loop/80/ConnSummary.txt b/test_loop/80/ConnSummary.txt new file mode 100644 index 0000000..6ec374d --- /dev/null +++ b/test_loop/80/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.976030349731445312e-01 +7.600871396465004315e-01 +5.547746913654276468e-02 diff --git a/test_loop/80/ConnectivityMetrics/16.npy b/test_loop/80/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..9be48e1 Binary files /dev/null and b/test_loop/80/ConnectivityMetrics/16.npy differ diff --git a/test_loop/80/ConnectivityMetrics/4.npy b/test_loop/80/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..0802aba Binary files /dev/null and b/test_loop/80/ConnectivityMetrics/4.npy differ diff --git a/test_loop/80/ConnectivityMetrics/8.npy b/test_loop/80/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..f03bb25 Binary files /dev/null and b/test_loop/80/ConnectivityMetrics/8.npy differ diff --git a/test_loop/80/D.npy b/test_loop/80/D.npy new file mode 100644 index 0000000..45d4cf6 Binary files /dev/null and b/test_loop/80/D.npy differ diff --git a/test_loop/80/GenParams.txt b/test_loop/80/GenParams.txt new file mode 100644 index 0000000..aef7d6d --- /dev/null +++ b/test_loop/80/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.756927490234375000e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/80/GlobalConnectivityMetrics/16.npy b/test_loop/80/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..9be48e1 Binary files /dev/null and b/test_loop/80/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/80/GlobalConnectivityMetrics/4.npy b/test_loop/80/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..0604c84 Binary files /dev/null and b/test_loop/80/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/80/GlobalConnectivityMetrics/8.npy b/test_loop/80/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..425c2ee Binary files /dev/null and b/test_loop/80/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/80/KpostProcess/Kd1.npy b/test_loop/80/KpostProcess/Kd1.npy new file mode 100644 index 0000000..e26a94f Binary files /dev/null and b/test_loop/80/KpostProcess/Kd1.npy differ diff --git a/test_loop/80/KpostProcess/Kd16.npy b/test_loop/80/KpostProcess/Kd16.npy new file mode 100644 index 0000000..36868a2 Binary files /dev/null and b/test_loop/80/KpostProcess/Kd16.npy differ diff --git a/test_loop/80/KpostProcess/Kd2.npy b/test_loop/80/KpostProcess/Kd2.npy new file mode 100644 index 0000000..df16f72 Binary files /dev/null and b/test_loop/80/KpostProcess/Kd2.npy differ diff --git a/test_loop/80/KpostProcess/Kd4.npy b/test_loop/80/KpostProcess/Kd4.npy new file mode 100644 index 0000000..604ca05 Binary files /dev/null and b/test_loop/80/KpostProcess/Kd4.npy differ diff --git a/test_loop/80/KpostProcess/Kd8.npy b/test_loop/80/KpostProcess/Kd8.npy new file mode 100644 index 0000000..95c55ce Binary files /dev/null and b/test_loop/80/KpostProcess/Kd8.npy differ diff --git a/test_loop/80/KpostProcess/Kperm2.npy b/test_loop/80/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..6bbda80 Binary files /dev/null and b/test_loop/80/KpostProcess/Kperm2.npy differ diff --git a/test_loop/80/KpostProcess/Kperm4.npy b/test_loop/80/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..6bbda80 Binary files /dev/null and b/test_loop/80/KpostProcess/Kperm4.npy differ diff --git a/test_loop/80/KpostProcess/Kperm8.npy b/test_loop/80/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..6bbda80 Binary files /dev/null and b/test_loop/80/KpostProcess/Kperm8.npy differ diff --git a/test_loop/80/KpostProcess/Kv1.npy b/test_loop/80/KpostProcess/Kv1.npy new file mode 100644 index 0000000..fd4553d Binary files /dev/null and b/test_loop/80/KpostProcess/Kv1.npy differ diff --git a/test_loop/80/KpostProcess/Kv16.npy b/test_loop/80/KpostProcess/Kv16.npy new file mode 100644 index 0000000..e669922 Binary files /dev/null and b/test_loop/80/KpostProcess/Kv16.npy differ diff --git a/test_loop/80/KpostProcess/Kv2.npy b/test_loop/80/KpostProcess/Kv2.npy new file mode 100644 index 0000000..2ae7ddf Binary files /dev/null and b/test_loop/80/KpostProcess/Kv2.npy differ diff --git a/test_loop/80/KpostProcess/Kv4.npy b/test_loop/80/KpostProcess/Kv4.npy new file mode 100644 index 0000000..00c8687 Binary files /dev/null and b/test_loop/80/KpostProcess/Kv4.npy differ diff --git a/test_loop/80/KpostProcess/Kv8.npy b/test_loop/80/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ef5c457 Binary files /dev/null and b/test_loop/80/KpostProcess/Kv8.npy differ diff --git a/test_loop/80/P.npy b/test_loop/80/P.npy new file mode 100644 index 0000000..a90d5bc Binary files /dev/null and b/test_loop/80/P.npy differ diff --git a/test_loop/80/PosKeffSummary.txt b/test_loop/80/PosKeffSummary.txt new file mode 100644 index 0000000..235e3fe --- /dev/null +++ b/test_loop/80/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.578683519606382646e+00 +2.737185579994418472e+00 +1.656050682067871094e-01 +6.232381895715219389e-03 diff --git a/test_loop/80/RunTimes.out b/test_loop/80/RunTimes.out new file mode 100644 index 0000000..5c99737 --- /dev/null +++ b/test_loop/80/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.414686918259 +Solver: 0.28319811821 +Keff: 2.737159471523448 +N_cores: 1 diff --git a/test_loop/80/SolverRes.txt b/test_loop/80/SolverRes.txt new file mode 100644 index 0000000..3a56017 --- /dev/null +++ b/test_loop/80/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.737159471523447962e+00 +2.000000000000000000e+00 +6.978850364685058594e-01 +1.000000000000000000e+00 diff --git a/test_loop/80/V.npy b/test_loop/80/V.npy new file mode 100644 index 0000000..9f4765c Binary files /dev/null and b/test_loop/80/V.npy differ diff --git a/test_loop/80/connec.out b/test_loop/80/connec.out new file mode 100644 index 0000000..ac842fe --- /dev/null +++ b/test_loop/80/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.281250000 + NCC : 1 + NCC : 2 diff --git a/test_loop/80/k.npy b/test_loop/80/k.npy new file mode 100644 index 0000000..d7bd15b Binary files /dev/null and b/test_loop/80/k.npy differ diff --git a/test_loop/80/lc.txt b/test_loop/80/lc.txt new file mode 100644 index 0000000..5b3b5d6 --- /dev/null +++ b/test_loop/80/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.933223685075496689e+00 +2.668079963315141079e+00 +2.298141340973586022e+00 diff --git a/test_loop/80/tkperm_sub.txt b/test_loop/80/tkperm_sub.txt new file mode 100644 index 0000000..867588a --- /dev/null +++ b/test_loop/80/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.904628753662109375e-01 +1.668930053710937500e-04 +1.249313354492187500e-04 diff --git a/test_loop/81/Cmap.npy b/test_loop/81/Cmap.npy new file mode 100644 index 0000000..b57e2a4 Binary files /dev/null and b/test_loop/81/Cmap.npy differ diff --git a/test_loop/81/ConnSummary.txt b/test_loop/81/ConnSummary.txt new file mode 100644 index 0000000..c97491a --- /dev/null +++ b/test_loop/81/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.318799972534179688e-01 +8.275677418357589854e-01 +4.013776915110442434e-02 diff --git a/test_loop/81/ConnectivityMetrics/16.npy b/test_loop/81/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..5f5806c Binary files /dev/null and b/test_loop/81/ConnectivityMetrics/16.npy differ diff --git a/test_loop/81/ConnectivityMetrics/4.npy b/test_loop/81/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..903a52a Binary files /dev/null and b/test_loop/81/ConnectivityMetrics/4.npy differ diff --git a/test_loop/81/ConnectivityMetrics/8.npy b/test_loop/81/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..7b2247c Binary files /dev/null and b/test_loop/81/ConnectivityMetrics/8.npy differ diff --git a/test_loop/81/D.npy b/test_loop/81/D.npy new file mode 100644 index 0000000..ebaf0c7 Binary files /dev/null and b/test_loop/81/D.npy differ diff --git a/test_loop/81/GenParams.txt b/test_loop/81/GenParams.txt new file mode 100644 index 0000000..a957347 --- /dev/null +++ b/test_loop/81/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.156040191650390625e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.071428571428571619e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/81/GlobalConnectivityMetrics/16.npy b/test_loop/81/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..5f5806c Binary files /dev/null and b/test_loop/81/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/81/GlobalConnectivityMetrics/4.npy b/test_loop/81/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..c9024b0 Binary files /dev/null and b/test_loop/81/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/81/GlobalConnectivityMetrics/8.npy b/test_loop/81/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..8e10d97 Binary files /dev/null and b/test_loop/81/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/81/KpostProcess/Kd16.npy b/test_loop/81/KpostProcess/Kd16.npy new file mode 100644 index 0000000..c5aaeb0 Binary files /dev/null and b/test_loop/81/KpostProcess/Kd16.npy differ diff --git a/test_loop/81/KpostProcess/Kd4.npy b/test_loop/81/KpostProcess/Kd4.npy new file mode 100644 index 0000000..6c81d02 Binary files /dev/null and b/test_loop/81/KpostProcess/Kd4.npy differ diff --git a/test_loop/81/KpostProcess/Kd8.npy b/test_loop/81/KpostProcess/Kd8.npy new file mode 100644 index 0000000..c98cbc7 Binary files /dev/null and b/test_loop/81/KpostProcess/Kd8.npy differ diff --git a/test_loop/81/KpostProcess/Kperm4.npy b/test_loop/81/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..707f806 Binary files /dev/null and b/test_loop/81/KpostProcess/Kperm4.npy differ diff --git a/test_loop/81/KpostProcess/Kperm8.npy b/test_loop/81/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..707f806 Binary files /dev/null and b/test_loop/81/KpostProcess/Kperm8.npy differ diff --git a/test_loop/81/KpostProcess/Kv16.npy b/test_loop/81/KpostProcess/Kv16.npy new file mode 100644 index 0000000..3373b0d Binary files /dev/null and b/test_loop/81/KpostProcess/Kv16.npy differ diff --git a/test_loop/81/KpostProcess/Kv4.npy b/test_loop/81/KpostProcess/Kv4.npy new file mode 100644 index 0000000..d68ebcc Binary files /dev/null and b/test_loop/81/KpostProcess/Kv4.npy differ diff --git a/test_loop/81/KpostProcess/Kv8.npy b/test_loop/81/KpostProcess/Kv8.npy new file mode 100644 index 0000000..c0904fc Binary files /dev/null and b/test_loop/81/KpostProcess/Kv8.npy differ diff --git a/test_loop/81/P.npy b/test_loop/81/P.npy new file mode 100644 index 0000000..e2ef26c Binary files /dev/null and b/test_loop/81/P.npy differ diff --git a/test_loop/81/PosKeffSummary.txt b/test_loop/81/PosKeffSummary.txt new file mode 100644 index 0000000..d4e1a58 --- /dev/null +++ b/test_loop/81/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.187583422398643229e+00 +2.241734137585057240e+00 +4.649162292480468750e-03 +2.404615384615384488e-01 diff --git a/test_loop/81/RunTimes.out b/test_loop/81/RunTimes.out new file mode 100644 index 0000000..0449a8b --- /dev/null +++ b/test_loop/81/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.294512987137 +Solver: 0.194652080536 +Keff: 2.2418017839535147 +N_cores: 1 diff --git a/test_loop/81/SolverRes.txt b/test_loop/81/SolverRes.txt new file mode 100644 index 0000000..cfb0cb0 --- /dev/null +++ b/test_loop/81/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.241801783953514704e+00 +2.000000000000000000e+00 +4.891650676727294922e-01 +1.000000000000000000e+00 diff --git a/test_loop/81/V.npy b/test_loop/81/V.npy new file mode 100644 index 0000000..2f54882 Binary files /dev/null and b/test_loop/81/V.npy differ diff --git a/test_loop/81/connec.out b/test_loop/81/connec.out new file mode 100644 index 0000000..7f44ef1 --- /dev/null +++ b/test_loop/81/connec.out @@ -0,0 +1,8 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.187500000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 diff --git a/test_loop/81/k.npy b/test_loop/81/k.npy new file mode 100644 index 0000000..f97c2bb Binary files /dev/null and b/test_loop/81/k.npy differ diff --git a/test_loop/81/lc.txt b/test_loop/81/lc.txt new file mode 100644 index 0000000..9eef388 --- /dev/null +++ b/test_loop/81/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.517661262752534412e+01 +6.939432953056522635e+00 +4.505801717258964167e+00 diff --git a/test_loop/81/tkperm_sub.txt b/test_loop/81/tkperm_sub.txt new file mode 100644 index 0000000..d695618 --- /dev/null +++ b/test_loop/81/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.915188312530517578e-01 +1.671314239501953125e-04 diff --git a/test_loop/82/Cmap.npy b/test_loop/82/Cmap.npy new file mode 100644 index 0000000..eb8528a Binary files /dev/null and b/test_loop/82/Cmap.npy differ diff --git a/test_loop/82/ConnSummary.txt b/test_loop/82/ConnSummary.txt new file mode 100644 index 0000000..07b202e --- /dev/null +++ b/test_loop/82/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.313209056854248047e-01 +7.363891589754191225e-01 +5.379718322627220078e-02 diff --git a/test_loop/82/ConnectivityMetrics/16.npy b/test_loop/82/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..70a2f87 Binary files /dev/null and b/test_loop/82/ConnectivityMetrics/16.npy differ diff --git a/test_loop/82/ConnectivityMetrics/4.npy b/test_loop/82/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..98fed74 Binary files /dev/null and b/test_loop/82/ConnectivityMetrics/4.npy differ diff --git a/test_loop/82/ConnectivityMetrics/8.npy b/test_loop/82/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..3dbefa2 Binary files /dev/null and b/test_loop/82/ConnectivityMetrics/8.npy differ diff --git a/test_loop/82/D.npy b/test_loop/82/D.npy new file mode 100644 index 0000000..26707b0 Binary files /dev/null and b/test_loop/82/D.npy differ diff --git a/test_loop/82/GenParams.txt b/test_loop/82/GenParams.txt new file mode 100644 index 0000000..69119f9 --- /dev/null +++ b/test_loop/82/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.964113235473632812e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/82/GlobalConnectivityMetrics/16.npy b/test_loop/82/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..70a2f87 Binary files /dev/null and b/test_loop/82/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/82/GlobalConnectivityMetrics/4.npy b/test_loop/82/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..6d8e264 Binary files /dev/null and b/test_loop/82/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/82/GlobalConnectivityMetrics/8.npy b/test_loop/82/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..a0a191c Binary files /dev/null and b/test_loop/82/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/82/KpostProcess/Kd1.npy b/test_loop/82/KpostProcess/Kd1.npy new file mode 100644 index 0000000..011ac27 Binary files /dev/null and b/test_loop/82/KpostProcess/Kd1.npy differ diff --git a/test_loop/82/KpostProcess/Kd16.npy b/test_loop/82/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2cb31a3 Binary files /dev/null and b/test_loop/82/KpostProcess/Kd16.npy differ diff --git a/test_loop/82/KpostProcess/Kd2.npy b/test_loop/82/KpostProcess/Kd2.npy new file mode 100644 index 0000000..4fc956c Binary files /dev/null and b/test_loop/82/KpostProcess/Kd2.npy differ diff --git a/test_loop/82/KpostProcess/Kd4.npy b/test_loop/82/KpostProcess/Kd4.npy new file mode 100644 index 0000000..6718d02 Binary files /dev/null and b/test_loop/82/KpostProcess/Kd4.npy differ diff --git a/test_loop/82/KpostProcess/Kd8.npy b/test_loop/82/KpostProcess/Kd8.npy new file mode 100644 index 0000000..0b19dfd Binary files /dev/null and b/test_loop/82/KpostProcess/Kd8.npy differ diff --git a/test_loop/82/KpostProcess/Kperm2.npy b/test_loop/82/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..5b4e5e6 Binary files /dev/null and b/test_loop/82/KpostProcess/Kperm2.npy differ diff --git a/test_loop/82/KpostProcess/Kperm4.npy b/test_loop/82/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..5b4e5e6 Binary files /dev/null and b/test_loop/82/KpostProcess/Kperm4.npy differ diff --git a/test_loop/82/KpostProcess/Kperm8.npy b/test_loop/82/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..5b4e5e6 Binary files /dev/null and b/test_loop/82/KpostProcess/Kperm8.npy differ diff --git a/test_loop/82/KpostProcess/Kv1.npy b/test_loop/82/KpostProcess/Kv1.npy new file mode 100644 index 0000000..1e9273d Binary files /dev/null and b/test_loop/82/KpostProcess/Kv1.npy differ diff --git a/test_loop/82/KpostProcess/Kv16.npy b/test_loop/82/KpostProcess/Kv16.npy new file mode 100644 index 0000000..9d87d75 Binary files /dev/null and b/test_loop/82/KpostProcess/Kv16.npy differ diff --git a/test_loop/82/KpostProcess/Kv2.npy b/test_loop/82/KpostProcess/Kv2.npy new file mode 100644 index 0000000..e5d92ff Binary files /dev/null and b/test_loop/82/KpostProcess/Kv2.npy differ diff --git a/test_loop/82/KpostProcess/Kv4.npy b/test_loop/82/KpostProcess/Kv4.npy new file mode 100644 index 0000000..cc0fdef Binary files /dev/null and b/test_loop/82/KpostProcess/Kv4.npy differ diff --git a/test_loop/82/KpostProcess/Kv8.npy b/test_loop/82/KpostProcess/Kv8.npy new file mode 100644 index 0000000..d532ec9 Binary files /dev/null and b/test_loop/82/KpostProcess/Kv8.npy differ diff --git a/test_loop/82/P.npy b/test_loop/82/P.npy new file mode 100644 index 0000000..4d02f63 Binary files /dev/null and b/test_loop/82/P.npy differ diff --git a/test_loop/82/PosKeffSummary.txt b/test_loop/82/PosKeffSummary.txt new file mode 100644 index 0000000..3c10008 --- /dev/null +++ b/test_loop/82/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.130290561764068613e+00 +3.325444122314976436e+00 +1.851270198822021484e-01 +7.383329104843788272e-03 diff --git a/test_loop/82/RunTimes.out b/test_loop/82/RunTimes.out new file mode 100644 index 0000000..a2150e2 --- /dev/null +++ b/test_loop/82/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.294310092926 +Solver: 0.257369995117 +Keff: 3.325387850398056 +N_cores: 1 diff --git a/test_loop/82/SolverRes.txt b/test_loop/82/SolverRes.txt new file mode 100644 index 0000000..b7c3eef --- /dev/null +++ b/test_loop/82/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.325387850398056067e+00 +2.000000000000000000e+00 +5.516800880432128906e-01 +1.000000000000000000e+00 diff --git a/test_loop/82/V.npy b/test_loop/82/V.npy new file mode 100644 index 0000000..5a3a761 Binary files /dev/null and b/test_loop/82/V.npy differ diff --git a/test_loop/82/connec.out b/test_loop/82/connec.out new file mode 100644 index 0000000..007d0ba --- /dev/null +++ b/test_loop/82/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.296875000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/82/k.npy b/test_loop/82/k.npy new file mode 100644 index 0000000..2019f06 Binary files /dev/null and b/test_loop/82/k.npy differ diff --git a/test_loop/82/lc.txt b/test_loop/82/lc.txt new file mode 100644 index 0000000..b3553fb --- /dev/null +++ b/test_loop/82/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +5.966149463514672568e+00 +2.696142387782925365e+00 +2.348050457965168647e+00 diff --git a/test_loop/82/tkperm_sub.txt b/test_loop/82/tkperm_sub.txt new file mode 100644 index 0000000..fa285d9 --- /dev/null +++ b/test_loop/82/tkperm_sub.txt @@ -0,0 +1,3 @@ +5.371148586273193359e-01 +2.310276031494140625e-04 +2.000331878662109375e-04 diff --git a/test_loop/83/Cmap.npy b/test_loop/83/Cmap.npy new file mode 100644 index 0000000..1ddada2 Binary files /dev/null and b/test_loop/83/Cmap.npy differ diff --git a/test_loop/83/ConnSummary.txt b/test_loop/83/ConnSummary.txt new file mode 100644 index 0000000..49e66ee --- /dev/null +++ b/test_loop/83/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.197180271148681641e-01 +8.360662908104576907e-01 +3.317039919337660264e-02 diff --git a/test_loop/83/ConnectivityMetrics/16.npy b/test_loop/83/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..f8592b1 Binary files /dev/null and b/test_loop/83/ConnectivityMetrics/16.npy differ diff --git a/test_loop/83/ConnectivityMetrics/4.npy b/test_loop/83/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..20d509d Binary files /dev/null and b/test_loop/83/ConnectivityMetrics/4.npy differ diff --git a/test_loop/83/ConnectivityMetrics/8.npy b/test_loop/83/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..c7bcf7e Binary files /dev/null and b/test_loop/83/ConnectivityMetrics/8.npy differ diff --git a/test_loop/83/D.npy b/test_loop/83/D.npy new file mode 100644 index 0000000..7502d8f Binary files /dev/null and b/test_loop/83/D.npy differ diff --git a/test_loop/83/GenParams.txt b/test_loop/83/GenParams.txt new file mode 100644 index 0000000..83d7bc4 --- /dev/null +++ b/test_loop/83/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.069017410278320312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.278571428571429025e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/83/GlobalConnectivityMetrics/16.npy b/test_loop/83/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..f8592b1 Binary files /dev/null and b/test_loop/83/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/83/GlobalConnectivityMetrics/4.npy b/test_loop/83/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..a43f3a1 Binary files /dev/null and b/test_loop/83/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/83/GlobalConnectivityMetrics/8.npy b/test_loop/83/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..dc11f57 Binary files /dev/null and b/test_loop/83/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/83/KpostProcess/Kd16.npy b/test_loop/83/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2a22c9d Binary files /dev/null and b/test_loop/83/KpostProcess/Kd16.npy differ diff --git a/test_loop/83/KpostProcess/Kd4.npy b/test_loop/83/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0d56d72 Binary files /dev/null and b/test_loop/83/KpostProcess/Kd4.npy differ diff --git a/test_loop/83/KpostProcess/Kd8.npy b/test_loop/83/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2101218 Binary files /dev/null and b/test_loop/83/KpostProcess/Kd8.npy differ diff --git a/test_loop/83/KpostProcess/Kperm4.npy b/test_loop/83/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..32615c6 Binary files /dev/null and b/test_loop/83/KpostProcess/Kperm4.npy differ diff --git a/test_loop/83/KpostProcess/Kperm8.npy b/test_loop/83/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..32615c6 Binary files /dev/null and b/test_loop/83/KpostProcess/Kperm8.npy differ diff --git a/test_loop/83/KpostProcess/Kv16.npy b/test_loop/83/KpostProcess/Kv16.npy new file mode 100644 index 0000000..dc1d0d6 Binary files /dev/null and b/test_loop/83/KpostProcess/Kv16.npy differ diff --git a/test_loop/83/KpostProcess/Kv4.npy b/test_loop/83/KpostProcess/Kv4.npy new file mode 100644 index 0000000..42dcf5e Binary files /dev/null and b/test_loop/83/KpostProcess/Kv4.npy differ diff --git a/test_loop/83/KpostProcess/Kv8.npy b/test_loop/83/KpostProcess/Kv8.npy new file mode 100644 index 0000000..0012ce8 Binary files /dev/null and b/test_loop/83/KpostProcess/Kv8.npy differ diff --git a/test_loop/83/P.npy b/test_loop/83/P.npy new file mode 100644 index 0000000..a3eddd7 Binary files /dev/null and b/test_loop/83/P.npy differ diff --git a/test_loop/83/PosKeffSummary.txt b/test_loop/83/PosKeffSummary.txt new file mode 100644 index 0000000..a4a82ce --- /dev/null +++ b/test_loop/83/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +2.296192266505768131e+00 +2.361750916528466693e+00 +4.714012145996093750e-03 +2.443860004046125856e-01 diff --git a/test_loop/83/RunTimes.out b/test_loop/83/RunTimes.out new file mode 100644 index 0000000..4accd7e --- /dev/null +++ b/test_loop/83/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.41096496582 +Solver: 0.200647830963 +Keff: 2.3619830719752515 +N_cores: 1 diff --git a/test_loop/83/SolverRes.txt b/test_loop/83/SolverRes.txt new file mode 100644 index 0000000..ec55f73 --- /dev/null +++ b/test_loop/83/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +2.361983071975251480e+00 +2.000000000000000000e+00 +6.116127967834472656e-01 +1.000000000000000000e+00 diff --git a/test_loop/83/V.npy b/test_loop/83/V.npy new file mode 100644 index 0000000..87c6bf6 Binary files /dev/null and b/test_loop/83/V.npy differ diff --git a/test_loop/83/connec.out b/test_loop/83/connec.out new file mode 100644 index 0000000..15570b1 --- /dev/null +++ b/test_loop/83/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.203125000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/83/k.npy b/test_loop/83/k.npy new file mode 100644 index 0000000..96f62cb Binary files /dev/null and b/test_loop/83/k.npy differ diff --git a/test_loop/83/lc.txt b/test_loop/83/lc.txt new file mode 100644 index 0000000..b29b98d --- /dev/null +++ b/test_loop/83/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.530497617812741318e+01 +7.328989364956935759e+00 +4.375275296111186485e+00 diff --git a/test_loop/83/tkperm_sub.txt b/test_loop/83/tkperm_sub.txt new file mode 100644 index 0000000..0ec268a --- /dev/null +++ b/test_loop/83/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.225510120391845703e-01 +1.668930053710937500e-04 diff --git a/test_loop/84/Cmap.npy b/test_loop/84/Cmap.npy new file mode 100644 index 0000000..4882c9e Binary files /dev/null and b/test_loop/84/Cmap.npy differ diff --git a/test_loop/84/ConnSummary.txt b/test_loop/84/ConnSummary.txt new file mode 100644 index 0000000..b6c2332 --- /dev/null +++ b/test_loop/84/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.911060333251953125e-01 +7.514098127628834334e-01 +5.705712266147793671e-02 diff --git a/test_loop/84/ConnectivityMetrics/16.npy b/test_loop/84/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c8aae9a Binary files /dev/null and b/test_loop/84/ConnectivityMetrics/16.npy differ diff --git a/test_loop/84/ConnectivityMetrics/4.npy b/test_loop/84/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..534d151 Binary files /dev/null and b/test_loop/84/ConnectivityMetrics/4.npy differ diff --git a/test_loop/84/ConnectivityMetrics/8.npy b/test_loop/84/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..b8ac4c6 Binary files /dev/null and b/test_loop/84/ConnectivityMetrics/8.npy differ diff --git a/test_loop/84/D.npy b/test_loop/84/D.npy new file mode 100644 index 0000000..f89fd77 Binary files /dev/null and b/test_loop/84/D.npy differ diff --git a/test_loop/84/GenParams.txt b/test_loop/84/GenParams.txt new file mode 100644 index 0000000..e0f5b83 --- /dev/null +++ b/test_loop/84/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +7.666826248168945312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/84/GlobalConnectivityMetrics/16.npy b/test_loop/84/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c8aae9a Binary files /dev/null and b/test_loop/84/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/84/GlobalConnectivityMetrics/4.npy b/test_loop/84/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..6a49e8e Binary files /dev/null and b/test_loop/84/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/84/GlobalConnectivityMetrics/8.npy b/test_loop/84/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..381d7b9 Binary files /dev/null and b/test_loop/84/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/84/KpostProcess/Kd1.npy b/test_loop/84/KpostProcess/Kd1.npy new file mode 100644 index 0000000..ad2bf4f Binary files /dev/null and b/test_loop/84/KpostProcess/Kd1.npy differ diff --git a/test_loop/84/KpostProcess/Kd16.npy b/test_loop/84/KpostProcess/Kd16.npy new file mode 100644 index 0000000..4744c06 Binary files /dev/null and b/test_loop/84/KpostProcess/Kd16.npy differ diff --git a/test_loop/84/KpostProcess/Kd2.npy b/test_loop/84/KpostProcess/Kd2.npy new file mode 100644 index 0000000..8b00acd Binary files /dev/null and b/test_loop/84/KpostProcess/Kd2.npy differ diff --git a/test_loop/84/KpostProcess/Kd4.npy b/test_loop/84/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0a76998 Binary files /dev/null and b/test_loop/84/KpostProcess/Kd4.npy differ diff --git a/test_loop/84/KpostProcess/Kd8.npy b/test_loop/84/KpostProcess/Kd8.npy new file mode 100644 index 0000000..2c78023 Binary files /dev/null and b/test_loop/84/KpostProcess/Kd8.npy differ diff --git a/test_loop/84/KpostProcess/Kperm2.npy b/test_loop/84/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..2f5b16f Binary files /dev/null and b/test_loop/84/KpostProcess/Kperm2.npy differ diff --git a/test_loop/84/KpostProcess/Kperm4.npy b/test_loop/84/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..2f5b16f Binary files /dev/null and b/test_loop/84/KpostProcess/Kperm4.npy differ diff --git a/test_loop/84/KpostProcess/Kperm8.npy b/test_loop/84/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..2f5b16f Binary files /dev/null and b/test_loop/84/KpostProcess/Kperm8.npy differ diff --git a/test_loop/84/KpostProcess/Kv1.npy b/test_loop/84/KpostProcess/Kv1.npy new file mode 100644 index 0000000..6e96ced Binary files /dev/null and b/test_loop/84/KpostProcess/Kv1.npy differ diff --git a/test_loop/84/KpostProcess/Kv16.npy b/test_loop/84/KpostProcess/Kv16.npy new file mode 100644 index 0000000..e16d36c Binary files /dev/null and b/test_loop/84/KpostProcess/Kv16.npy differ diff --git a/test_loop/84/KpostProcess/Kv2.npy b/test_loop/84/KpostProcess/Kv2.npy new file mode 100644 index 0000000..524b344 Binary files /dev/null and b/test_loop/84/KpostProcess/Kv2.npy differ diff --git a/test_loop/84/KpostProcess/Kv4.npy b/test_loop/84/KpostProcess/Kv4.npy new file mode 100644 index 0000000..2093dab Binary files /dev/null and b/test_loop/84/KpostProcess/Kv4.npy differ diff --git a/test_loop/84/KpostProcess/Kv8.npy b/test_loop/84/KpostProcess/Kv8.npy new file mode 100644 index 0000000..042f206 Binary files /dev/null and b/test_loop/84/KpostProcess/Kv8.npy differ diff --git a/test_loop/84/P.npy b/test_loop/84/P.npy new file mode 100644 index 0000000..0bec093 Binary files /dev/null and b/test_loop/84/P.npy differ diff --git a/test_loop/84/PosKeffSummary.txt b/test_loop/84/PosKeffSummary.txt new file mode 100644 index 0000000..8490bbe --- /dev/null +++ b/test_loop/84/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.580639658822337701e+00 +3.739419534245761234e+00 +2.227089405059814453e-01 +6.325814225106491523e-03 diff --git a/test_loop/84/RunTimes.out b/test_loop/84/RunTimes.out new file mode 100644 index 0000000..57cc3cc --- /dev/null +++ b/test_loop/84/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.300117969513 +Solver: 0.261873006821 +Keff: 3.7394147503584567 +N_cores: 1 diff --git a/test_loop/84/SolverRes.txt b/test_loop/84/SolverRes.txt new file mode 100644 index 0000000..c138094 --- /dev/null +++ b/test_loop/84/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.739414750358456718e+00 +2.000000000000000000e+00 +5.619909763336181641e-01 +1.000000000000000000e+00 diff --git a/test_loop/84/V.npy b/test_loop/84/V.npy new file mode 100644 index 0000000..20385c7 Binary files /dev/null and b/test_loop/84/V.npy differ diff --git a/test_loop/84/connec.out b/test_loop/84/connec.out new file mode 100644 index 0000000..dc09ca7 --- /dev/null +++ b/test_loop/84/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.312500000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/84/k.npy b/test_loop/84/k.npy new file mode 100644 index 0000000..e191a34 Binary files /dev/null and b/test_loop/84/k.npy differ diff --git a/test_loop/84/lc.txt b/test_loop/84/lc.txt new file mode 100644 index 0000000..37e6734 --- /dev/null +++ b/test_loop/84/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.003111328939668923e+00 +2.716815653335943992e+00 +2.381683769374431492e+00 diff --git a/test_loop/84/tkperm_sub.txt b/test_loop/84/tkperm_sub.txt new file mode 100644 index 0000000..588f9b8 --- /dev/null +++ b/test_loop/84/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.387741088867187500e-01 +2.398490905761718750e-04 +1.990795135498046875e-04 diff --git a/test_loop/85/Cmap.npy b/test_loop/85/Cmap.npy new file mode 100644 index 0000000..74fca5f Binary files /dev/null and b/test_loop/85/Cmap.npy differ diff --git a/test_loop/85/ConnSummary.txt b/test_loop/85/ConnSummary.txt new file mode 100644 index 0000000..23b7a41 --- /dev/null +++ b/test_loop/85/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.588819503784179688e-01 +7.862528732577760415e-01 +3.845847229050131100e-02 diff --git a/test_loop/85/ConnectivityMetrics/16.npy b/test_loop/85/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..c27f070 Binary files /dev/null and b/test_loop/85/ConnectivityMetrics/16.npy differ diff --git a/test_loop/85/ConnectivityMetrics/4.npy b/test_loop/85/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..12bfe89 Binary files /dev/null and b/test_loop/85/ConnectivityMetrics/4.npy differ diff --git a/test_loop/85/ConnectivityMetrics/8.npy b/test_loop/85/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..e7a01f1 Binary files /dev/null and b/test_loop/85/ConnectivityMetrics/8.npy differ diff --git a/test_loop/85/D.npy b/test_loop/85/D.npy new file mode 100644 index 0000000..9ecba83 Binary files /dev/null and b/test_loop/85/D.npy differ diff --git a/test_loop/85/GenParams.txt b/test_loop/85/GenParams.txt new file mode 100644 index 0000000..77a4d98 --- /dev/null +++ b/test_loop/85/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.065917968750000000e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.485714285714285876e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/85/GlobalConnectivityMetrics/16.npy b/test_loop/85/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..c27f070 Binary files /dev/null and b/test_loop/85/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/85/GlobalConnectivityMetrics/4.npy b/test_loop/85/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..1114ea7 Binary files /dev/null and b/test_loop/85/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/85/GlobalConnectivityMetrics/8.npy b/test_loop/85/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..448abb6 Binary files /dev/null and b/test_loop/85/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/85/KpostProcess/Kd16.npy b/test_loop/85/KpostProcess/Kd16.npy new file mode 100644 index 0000000..fac0b81 Binary files /dev/null and b/test_loop/85/KpostProcess/Kd16.npy differ diff --git a/test_loop/85/KpostProcess/Kd4.npy b/test_loop/85/KpostProcess/Kd4.npy new file mode 100644 index 0000000..9f4cdea Binary files /dev/null and b/test_loop/85/KpostProcess/Kd4.npy differ diff --git a/test_loop/85/KpostProcess/Kd8.npy b/test_loop/85/KpostProcess/Kd8.npy new file mode 100644 index 0000000..9f0b123 Binary files /dev/null and b/test_loop/85/KpostProcess/Kd8.npy differ diff --git a/test_loop/85/KpostProcess/Kperm4.npy b/test_loop/85/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..3011584 Binary files /dev/null and b/test_loop/85/KpostProcess/Kperm4.npy differ diff --git a/test_loop/85/KpostProcess/Kperm8.npy b/test_loop/85/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..3011584 Binary files /dev/null and b/test_loop/85/KpostProcess/Kperm8.npy differ diff --git a/test_loop/85/KpostProcess/Kv16.npy b/test_loop/85/KpostProcess/Kv16.npy new file mode 100644 index 0000000..8568ecc Binary files /dev/null and b/test_loop/85/KpostProcess/Kv16.npy differ diff --git a/test_loop/85/KpostProcess/Kv4.npy b/test_loop/85/KpostProcess/Kv4.npy new file mode 100644 index 0000000..0d8d914 Binary files /dev/null and b/test_loop/85/KpostProcess/Kv4.npy differ diff --git a/test_loop/85/KpostProcess/Kv8.npy b/test_loop/85/KpostProcess/Kv8.npy new file mode 100644 index 0000000..37c4b30 Binary files /dev/null and b/test_loop/85/KpostProcess/Kv8.npy differ diff --git a/test_loop/85/P.npy b/test_loop/85/P.npy new file mode 100644 index 0000000..9906ae3 Binary files /dev/null and b/test_loop/85/P.npy differ diff --git a/test_loop/85/PosKeffSummary.txt b/test_loop/85/PosKeffSummary.txt new file mode 100644 index 0000000..b6f9085 --- /dev/null +++ b/test_loop/85/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.853190202507524642e+00 +3.953520383473348332e+00 +4.336118698120117188e-03 +2.382470995766206578e-01 diff --git a/test_loop/85/RunTimes.out b/test_loop/85/RunTimes.out new file mode 100644 index 0000000..0eed28f --- /dev/null +++ b/test_loop/85/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.363955020905 +Solver: 0.177072048187 +Keff: 3.953848365148514 +N_cores: 1 diff --git a/test_loop/85/SolverRes.txt b/test_loop/85/SolverRes.txt new file mode 100644 index 0000000..fed6571 --- /dev/null +++ b/test_loop/85/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +3.953848365148513899e+00 +2.000000000000000000e+00 +5.410270690917968750e-01 +1.000000000000000000e+00 diff --git a/test_loop/85/V.npy b/test_loop/85/V.npy new file mode 100644 index 0000000..22899cd Binary files /dev/null and b/test_loop/85/V.npy differ diff --git a/test_loop/85/connec.out b/test_loop/85/connec.out new file mode 100644 index 0000000..15570b1 --- /dev/null +++ b/test_loop/85/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.203125000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/85/k.npy b/test_loop/85/k.npy new file mode 100644 index 0000000..5b679aa Binary files /dev/null and b/test_loop/85/k.npy differ diff --git a/test_loop/85/lc.txt b/test_loop/85/lc.txt new file mode 100644 index 0000000..48b22ad --- /dev/null +++ b/test_loop/85/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.544854756947626484e+01 +7.413116821143924007e+00 +4.431846894573101991e+00 diff --git a/test_loop/85/tkperm_sub.txt b/test_loop/85/tkperm_sub.txt new file mode 100644 index 0000000..e35627d --- /dev/null +++ b/test_loop/85/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.463940620422363281e-01 +1.559257507324218750e-04 diff --git a/test_loop/86/Cmap.npy b/test_loop/86/Cmap.npy new file mode 100644 index 0000000..0838461 Binary files /dev/null and b/test_loop/86/Cmap.npy differ diff --git a/test_loop/86/ConnSummary.txt b/test_loop/86/ConnSummary.txt new file mode 100644 index 0000000..bcf779a --- /dev/null +++ b/test_loop/86/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.304499626159667969e-01 +7.423445169537807864e-01 +4.063224547173594631e-02 diff --git a/test_loop/86/ConnectivityMetrics/16.npy b/test_loop/86/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..1cf860b Binary files /dev/null and b/test_loop/86/ConnectivityMetrics/16.npy differ diff --git a/test_loop/86/ConnectivityMetrics/4.npy b/test_loop/86/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..a6a36c0 Binary files /dev/null and b/test_loop/86/ConnectivityMetrics/4.npy differ diff --git a/test_loop/86/ConnectivityMetrics/8.npy b/test_loop/86/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..7bc271d Binary files /dev/null and b/test_loop/86/ConnectivityMetrics/8.npy differ diff --git a/test_loop/86/D.npy b/test_loop/86/D.npy new file mode 100644 index 0000000..5a9609c Binary files /dev/null and b/test_loop/86/D.npy differ diff --git a/test_loop/86/GenParams.txt b/test_loop/86/GenParams.txt new file mode 100644 index 0000000..a6e3d63 --- /dev/null +++ b/test_loop/86/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.185054779052734375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/86/GlobalConnectivityMetrics/16.npy b/test_loop/86/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..1cf860b Binary files /dev/null and b/test_loop/86/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/86/GlobalConnectivityMetrics/4.npy b/test_loop/86/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..88dd667 Binary files /dev/null and b/test_loop/86/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/86/GlobalConnectivityMetrics/8.npy b/test_loop/86/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..3100b6c Binary files /dev/null and b/test_loop/86/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/86/KpostProcess/Kd1.npy b/test_loop/86/KpostProcess/Kd1.npy new file mode 100644 index 0000000..37c03c8 Binary files /dev/null and b/test_loop/86/KpostProcess/Kd1.npy differ diff --git a/test_loop/86/KpostProcess/Kd16.npy b/test_loop/86/KpostProcess/Kd16.npy new file mode 100644 index 0000000..674657f Binary files /dev/null and b/test_loop/86/KpostProcess/Kd16.npy differ diff --git a/test_loop/86/KpostProcess/Kd2.npy b/test_loop/86/KpostProcess/Kd2.npy new file mode 100644 index 0000000..34339ff Binary files /dev/null and b/test_loop/86/KpostProcess/Kd2.npy differ diff --git a/test_loop/86/KpostProcess/Kd4.npy b/test_loop/86/KpostProcess/Kd4.npy new file mode 100644 index 0000000..7db95fd Binary files /dev/null and b/test_loop/86/KpostProcess/Kd4.npy differ diff --git a/test_loop/86/KpostProcess/Kd8.npy b/test_loop/86/KpostProcess/Kd8.npy new file mode 100644 index 0000000..98f182b Binary files /dev/null and b/test_loop/86/KpostProcess/Kd8.npy differ diff --git a/test_loop/86/KpostProcess/Kperm2.npy b/test_loop/86/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..e0acaad Binary files /dev/null and b/test_loop/86/KpostProcess/Kperm2.npy differ diff --git a/test_loop/86/KpostProcess/Kperm4.npy b/test_loop/86/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..e0acaad Binary files /dev/null and b/test_loop/86/KpostProcess/Kperm4.npy differ diff --git a/test_loop/86/KpostProcess/Kperm8.npy b/test_loop/86/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..e0acaad Binary files /dev/null and b/test_loop/86/KpostProcess/Kperm8.npy differ diff --git a/test_loop/86/KpostProcess/Kv1.npy b/test_loop/86/KpostProcess/Kv1.npy new file mode 100644 index 0000000..b3ab49b Binary files /dev/null and b/test_loop/86/KpostProcess/Kv1.npy differ diff --git a/test_loop/86/KpostProcess/Kv16.npy b/test_loop/86/KpostProcess/Kv16.npy new file mode 100644 index 0000000..775486b Binary files /dev/null and b/test_loop/86/KpostProcess/Kv16.npy differ diff --git a/test_loop/86/KpostProcess/Kv2.npy b/test_loop/86/KpostProcess/Kv2.npy new file mode 100644 index 0000000..e60e7fb Binary files /dev/null and b/test_loop/86/KpostProcess/Kv2.npy differ diff --git a/test_loop/86/KpostProcess/Kv4.npy b/test_loop/86/KpostProcess/Kv4.npy new file mode 100644 index 0000000..e9d3108 Binary files /dev/null and b/test_loop/86/KpostProcess/Kv4.npy differ diff --git a/test_loop/86/KpostProcess/Kv8.npy b/test_loop/86/KpostProcess/Kv8.npy new file mode 100644 index 0000000..ad54a0d Binary files /dev/null and b/test_loop/86/KpostProcess/Kv8.npy differ diff --git a/test_loop/86/P.npy b/test_loop/86/P.npy new file mode 100644 index 0000000..80f5311 Binary files /dev/null and b/test_loop/86/P.npy differ diff --git a/test_loop/86/PosKeffSummary.txt b/test_loop/86/PosKeffSummary.txt new file mode 100644 index 0000000..d6c9078 --- /dev/null +++ b/test_loop/86/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +3.837521896512221531e+00 +4.001055920738552985e+00 +1.657090187072753906e-01 +8.954957599196585946e-03 diff --git a/test_loop/86/RunTimes.out b/test_loop/86/RunTimes.out new file mode 100644 index 0000000..1614bd2 --- /dev/null +++ b/test_loop/86/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.476097822189 +Solver: 0.274067163467 +Keff: 4.0010765978611955 +N_cores: 1 diff --git a/test_loop/86/SolverRes.txt b/test_loop/86/SolverRes.txt new file mode 100644 index 0000000..c764d2f --- /dev/null +++ b/test_loop/86/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.001076597861195516e+00 +2.000000000000000000e+00 +7.501649856567382812e-01 +1.000000000000000000e+00 diff --git a/test_loop/86/V.npy b/test_loop/86/V.npy new file mode 100644 index 0000000..a289fec Binary files /dev/null and b/test_loop/86/V.npy differ diff --git a/test_loop/86/connec.out b/test_loop/86/connec.out new file mode 100644 index 0000000..dc09ca7 --- /dev/null +++ b/test_loop/86/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.312500000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/86/k.npy b/test_loop/86/k.npy new file mode 100644 index 0000000..0bbf883 Binary files /dev/null and b/test_loop/86/k.npy differ diff --git a/test_loop/86/lc.txt b/test_loop/86/lc.txt new file mode 100644 index 0000000..bbbacb4 --- /dev/null +++ b/test_loop/86/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.044042049309871878e+00 +2.779105809853060549e+00 +2.360242141407713046e+00 diff --git a/test_loop/86/tkperm_sub.txt b/test_loop/86/tkperm_sub.txt new file mode 100644 index 0000000..fcb1be7 --- /dev/null +++ b/test_loop/86/tkperm_sub.txt @@ -0,0 +1,3 @@ +3.739290237426757812e-01 +1.718997955322265625e-04 +1.299381256103515625e-04 diff --git a/test_loop/87/Cmap.npy b/test_loop/87/Cmap.npy new file mode 100644 index 0000000..ab6f33b Binary files /dev/null and b/test_loop/87/Cmap.npy differ diff --git a/test_loop/87/ConnSummary.txt b/test_loop/87/ConnSummary.txt new file mode 100644 index 0000000..6e9c545 --- /dev/null +++ b/test_loop/87/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.776490688323974609e-01 +7.752458214302624384e-01 +4.576208589150712602e-02 diff --git a/test_loop/87/ConnectivityMetrics/16.npy b/test_loop/87/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..5474fe6 Binary files /dev/null and b/test_loop/87/ConnectivityMetrics/16.npy differ diff --git a/test_loop/87/ConnectivityMetrics/4.npy b/test_loop/87/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..d1bbff9 Binary files /dev/null and b/test_loop/87/ConnectivityMetrics/4.npy differ diff --git a/test_loop/87/ConnectivityMetrics/8.npy b/test_loop/87/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..a849b37 Binary files /dev/null and b/test_loop/87/ConnectivityMetrics/8.npy differ diff --git a/test_loop/87/D.npy b/test_loop/87/D.npy new file mode 100644 index 0000000..129d2f2 Binary files /dev/null and b/test_loop/87/D.npy differ diff --git a/test_loop/87/GenParams.txt b/test_loop/87/GenParams.txt new file mode 100644 index 0000000..eef87a9 --- /dev/null +++ b/test_loop/87/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +6.861925125122070312e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.692857142857143282e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/87/GlobalConnectivityMetrics/16.npy b/test_loop/87/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..5474fe6 Binary files /dev/null and b/test_loop/87/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/87/GlobalConnectivityMetrics/4.npy b/test_loop/87/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..2cfcae1 Binary files /dev/null and b/test_loop/87/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/87/GlobalConnectivityMetrics/8.npy b/test_loop/87/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..6897fb9 Binary files /dev/null and b/test_loop/87/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/87/KpostProcess/Kd16.npy b/test_loop/87/KpostProcess/Kd16.npy new file mode 100644 index 0000000..b961936 Binary files /dev/null and b/test_loop/87/KpostProcess/Kd16.npy differ diff --git a/test_loop/87/KpostProcess/Kd4.npy b/test_loop/87/KpostProcess/Kd4.npy new file mode 100644 index 0000000..6d324c0 Binary files /dev/null and b/test_loop/87/KpostProcess/Kd4.npy differ diff --git a/test_loop/87/KpostProcess/Kd8.npy b/test_loop/87/KpostProcess/Kd8.npy new file mode 100644 index 0000000..d9515bc Binary files /dev/null and b/test_loop/87/KpostProcess/Kd8.npy differ diff --git a/test_loop/87/KpostProcess/Kperm4.npy b/test_loop/87/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..6494859 Binary files /dev/null and b/test_loop/87/KpostProcess/Kperm4.npy differ diff --git a/test_loop/87/KpostProcess/Kperm8.npy b/test_loop/87/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..6494859 Binary files /dev/null and b/test_loop/87/KpostProcess/Kperm8.npy differ diff --git a/test_loop/87/KpostProcess/Kv16.npy b/test_loop/87/KpostProcess/Kv16.npy new file mode 100644 index 0000000..b827170 Binary files /dev/null and b/test_loop/87/KpostProcess/Kv16.npy differ diff --git a/test_loop/87/KpostProcess/Kv4.npy b/test_loop/87/KpostProcess/Kv4.npy new file mode 100644 index 0000000..cff4d94 Binary files /dev/null and b/test_loop/87/KpostProcess/Kv4.npy differ diff --git a/test_loop/87/KpostProcess/Kv8.npy b/test_loop/87/KpostProcess/Kv8.npy new file mode 100644 index 0000000..d46edbf Binary files /dev/null and b/test_loop/87/KpostProcess/Kv8.npy differ diff --git a/test_loop/87/P.npy b/test_loop/87/P.npy new file mode 100644 index 0000000..1d0f432 Binary files /dev/null and b/test_loop/87/P.npy differ diff --git a/test_loop/87/PosKeffSummary.txt b/test_loop/87/PosKeffSummary.txt new file mode 100644 index 0000000..eb7cefc --- /dev/null +++ b/test_loop/87/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.534192314627861542e+00 +4.628988882577430353e+00 +4.601001739501953125e-03 +2.427712716343662647e-01 diff --git a/test_loop/87/RunTimes.out b/test_loop/87/RunTimes.out new file mode 100644 index 0000000..33618b2 --- /dev/null +++ b/test_loop/87/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.299582958221 +Solver: 0.183059930801 +Keff: 4.629116390611754 +N_cores: 1 diff --git a/test_loop/87/SolverRes.txt b/test_loop/87/SolverRes.txt new file mode 100644 index 0000000..72e5c28 --- /dev/null +++ b/test_loop/87/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.629116390611754284e+00 +2.000000000000000000e+00 +4.826428890228271484e-01 +1.000000000000000000e+00 diff --git a/test_loop/87/V.npy b/test_loop/87/V.npy new file mode 100644 index 0000000..1c6560c Binary files /dev/null and b/test_loop/87/V.npy differ diff --git a/test_loop/87/connec.out b/test_loop/87/connec.out new file mode 100644 index 0000000..e87bd8d --- /dev/null +++ b/test_loop/87/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.218750000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/87/k.npy b/test_loop/87/k.npy new file mode 100644 index 0000000..e5fd238 Binary files /dev/null and b/test_loop/87/k.npy differ diff --git a/test_loop/87/lc.txt b/test_loop/87/lc.txt new file mode 100644 index 0000000..c2dd499 --- /dev/null +++ b/test_loop/87/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.560679176755447628e+01 +7.342074300627453809e+00 +4.495365357306942755e+00 diff --git a/test_loop/87/tkperm_sub.txt b/test_loop/87/tkperm_sub.txt new file mode 100644 index 0000000..e6a092e --- /dev/null +++ b/test_loop/87/tkperm_sub.txt @@ -0,0 +1,2 @@ +4.035339355468750000e-01 +1.630783081054687500e-04 diff --git a/test_loop/88/Cmap.npy b/test_loop/88/Cmap.npy new file mode 100644 index 0000000..74b2ac5 Binary files /dev/null and b/test_loop/88/Cmap.npy differ diff --git a/test_loop/88/ConnSummary.txt b/test_loop/88/ConnSummary.txt new file mode 100644 index 0000000..4777cf2 --- /dev/null +++ b/test_loop/88/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.321949481964111328e-01 +8.257659465664730636e-01 +3.665466469030322083e-02 diff --git a/test_loop/88/ConnectivityMetrics/16.npy b/test_loop/88/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..f29dd46 Binary files /dev/null and b/test_loop/88/ConnectivityMetrics/16.npy differ diff --git a/test_loop/88/ConnectivityMetrics/4.npy b/test_loop/88/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..eef1401 Binary files /dev/null and b/test_loop/88/ConnectivityMetrics/4.npy differ diff --git a/test_loop/88/ConnectivityMetrics/8.npy b/test_loop/88/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..c88d488 Binary files /dev/null and b/test_loop/88/ConnectivityMetrics/8.npy differ diff --git a/test_loop/88/D.npy b/test_loop/88/D.npy new file mode 100644 index 0000000..8ea7528 Binary files /dev/null and b/test_loop/88/D.npy differ diff --git a/test_loop/88/GenParams.txt b/test_loop/88/GenParams.txt new file mode 100644 index 0000000..f133939 --- /dev/null +++ b/test_loop/88/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +5.167007446289062500e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.462000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/88/GlobalConnectivityMetrics/16.npy b/test_loop/88/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..f29dd46 Binary files /dev/null and b/test_loop/88/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/88/GlobalConnectivityMetrics/4.npy b/test_loop/88/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..8e5eb8c Binary files /dev/null and b/test_loop/88/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/88/GlobalConnectivityMetrics/8.npy b/test_loop/88/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..76d639d Binary files /dev/null and b/test_loop/88/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/88/KpostProcess/Kd1.npy b/test_loop/88/KpostProcess/Kd1.npy new file mode 100644 index 0000000..5e12638 Binary files /dev/null and b/test_loop/88/KpostProcess/Kd1.npy differ diff --git a/test_loop/88/KpostProcess/Kd16.npy b/test_loop/88/KpostProcess/Kd16.npy new file mode 100644 index 0000000..a34a430 Binary files /dev/null and b/test_loop/88/KpostProcess/Kd16.npy differ diff --git a/test_loop/88/KpostProcess/Kd2.npy b/test_loop/88/KpostProcess/Kd2.npy new file mode 100644 index 0000000..46c955f Binary files /dev/null and b/test_loop/88/KpostProcess/Kd2.npy differ diff --git a/test_loop/88/KpostProcess/Kd4.npy b/test_loop/88/KpostProcess/Kd4.npy new file mode 100644 index 0000000..98c161a Binary files /dev/null and b/test_loop/88/KpostProcess/Kd4.npy differ diff --git a/test_loop/88/KpostProcess/Kd8.npy b/test_loop/88/KpostProcess/Kd8.npy new file mode 100644 index 0000000..f5f94dc Binary files /dev/null and b/test_loop/88/KpostProcess/Kd8.npy differ diff --git a/test_loop/88/KpostProcess/Kperm2.npy b/test_loop/88/KpostProcess/Kperm2.npy new file mode 100644 index 0000000..40efda3 Binary files /dev/null and b/test_loop/88/KpostProcess/Kperm2.npy differ diff --git a/test_loop/88/KpostProcess/Kperm4.npy b/test_loop/88/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..40efda3 Binary files /dev/null and b/test_loop/88/KpostProcess/Kperm4.npy differ diff --git a/test_loop/88/KpostProcess/Kperm8.npy b/test_loop/88/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..40efda3 Binary files /dev/null and b/test_loop/88/KpostProcess/Kperm8.npy differ diff --git a/test_loop/88/KpostProcess/Kv1.npy b/test_loop/88/KpostProcess/Kv1.npy new file mode 100644 index 0000000..c727ddc Binary files /dev/null and b/test_loop/88/KpostProcess/Kv1.npy differ diff --git a/test_loop/88/KpostProcess/Kv16.npy b/test_loop/88/KpostProcess/Kv16.npy new file mode 100644 index 0000000..5bb134e Binary files /dev/null and b/test_loop/88/KpostProcess/Kv16.npy differ diff --git a/test_loop/88/KpostProcess/Kv2.npy b/test_loop/88/KpostProcess/Kv2.npy new file mode 100644 index 0000000..bbe5a2b Binary files /dev/null and b/test_loop/88/KpostProcess/Kv2.npy differ diff --git a/test_loop/88/KpostProcess/Kv4.npy b/test_loop/88/KpostProcess/Kv4.npy new file mode 100644 index 0000000..40c001c Binary files /dev/null and b/test_loop/88/KpostProcess/Kv4.npy differ diff --git a/test_loop/88/KpostProcess/Kv8.npy b/test_loop/88/KpostProcess/Kv8.npy new file mode 100644 index 0000000..bd6ff53 Binary files /dev/null and b/test_loop/88/KpostProcess/Kv8.npy differ diff --git a/test_loop/88/P.npy b/test_loop/88/P.npy new file mode 100644 index 0000000..c57ae9b Binary files /dev/null and b/test_loop/88/P.npy differ diff --git a/test_loop/88/PosKeffSummary.txt b/test_loop/88/PosKeffSummary.txt new file mode 100644 index 0000000..a7afc71 --- /dev/null +++ b/test_loop/88/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.856427916676579137e+00 +4.967548540561382175e+00 +1.487741470336914062e-01 +7.354119524874840746e-03 diff --git a/test_loop/88/RunTimes.out b/test_loop/88/RunTimes.out new file mode 100644 index 0000000..a161da7 --- /dev/null +++ b/test_loop/88/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.311380147934 +Solver: 0.225119829178 +Keff: 4.967582151332876 +N_cores: 1 diff --git a/test_loop/88/SolverRes.txt b/test_loop/88/SolverRes.txt new file mode 100644 index 0000000..740ffda --- /dev/null +++ b/test_loop/88/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.967582151332876172e+00 +2.000000000000000000e+00 +5.364999771118164062e-01 +1.000000000000000000e+00 diff --git a/test_loop/88/V.npy b/test_loop/88/V.npy new file mode 100644 index 0000000..72595c9 Binary files /dev/null and b/test_loop/88/V.npy differ diff --git a/test_loop/88/connec.out b/test_loop/88/connec.out new file mode 100644 index 0000000..6fcd1be --- /dev/null +++ b/test_loop/88/connec.out @@ -0,0 +1,7 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.343750000 + NCC : 1 + NCC : 2 + NCC : 3 diff --git a/test_loop/88/k.npy b/test_loop/88/k.npy new file mode 100644 index 0000000..694d75b Binary files /dev/null and b/test_loop/88/k.npy differ diff --git a/test_loop/88/lc.txt b/test_loop/88/lc.txt new file mode 100644 index 0000000..8a7df1b --- /dev/null +++ b/test_loop/88/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +6.091315370823308761e+00 +2.840828450239075043e+00 +2.400572344049849871e+00 diff --git a/test_loop/88/tkperm_sub.txt b/test_loop/88/tkperm_sub.txt new file mode 100644 index 0000000..443e089 --- /dev/null +++ b/test_loop/88/tkperm_sub.txt @@ -0,0 +1,3 @@ +4.421410560607910156e-01 +1.740455627441406250e-04 +1.320838928222656250e-04 diff --git a/test_loop/89/Cmap.npy b/test_loop/89/Cmap.npy new file mode 100644 index 0000000..f1b4467 Binary files /dev/null and b/test_loop/89/Cmap.npy differ diff --git a/test_loop/89/ConnSummary.txt b/test_loop/89/ConnSummary.txt new file mode 100644 index 0000000..b958b27 --- /dev/null +++ b/test_loop/89/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +3.550119400024414062e-01 +7.838804911660492980e-01 +4.340415358206830415e-02 diff --git a/test_loop/89/ConnectivityMetrics/16.npy b/test_loop/89/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..9e7c8b2 Binary files /dev/null and b/test_loop/89/ConnectivityMetrics/16.npy differ diff --git a/test_loop/89/ConnectivityMetrics/4.npy b/test_loop/89/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..7258bda Binary files /dev/null and b/test_loop/89/ConnectivityMetrics/4.npy differ diff --git a/test_loop/89/ConnectivityMetrics/8.npy b/test_loop/89/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..5dfb11a Binary files /dev/null and b/test_loop/89/ConnectivityMetrics/8.npy differ diff --git a/test_loop/89/D.npy b/test_loop/89/D.npy new file mode 100644 index 0000000..e195599 Binary files /dev/null and b/test_loop/89/D.npy differ diff --git a/test_loop/89/GenParams.txt b/test_loop/89/GenParams.txt new file mode 100644 index 0000000..3ab240b --- /dev/null +++ b/test_loop/89/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.904031753540039062e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +3.000000000000000000e+00 +4.000000000000000000e+00 +3.900000000000000133e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/89/GlobalConnectivityMetrics/16.npy b/test_loop/89/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..9e7c8b2 Binary files /dev/null and b/test_loop/89/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/89/GlobalConnectivityMetrics/4.npy b/test_loop/89/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..fa3efac Binary files /dev/null and b/test_loop/89/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/89/GlobalConnectivityMetrics/8.npy b/test_loop/89/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..fb0ee97 Binary files /dev/null and b/test_loop/89/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/89/KpostProcess/Kd16.npy b/test_loop/89/KpostProcess/Kd16.npy new file mode 100644 index 0000000..2026930 Binary files /dev/null and b/test_loop/89/KpostProcess/Kd16.npy differ diff --git a/test_loop/89/KpostProcess/Kd4.npy b/test_loop/89/KpostProcess/Kd4.npy new file mode 100644 index 0000000..0370ccc Binary files /dev/null and b/test_loop/89/KpostProcess/Kd4.npy differ diff --git a/test_loop/89/KpostProcess/Kd8.npy b/test_loop/89/KpostProcess/Kd8.npy new file mode 100644 index 0000000..621b15b Binary files /dev/null and b/test_loop/89/KpostProcess/Kd8.npy differ diff --git a/test_loop/89/KpostProcess/Kperm4.npy b/test_loop/89/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..f5f84d5 Binary files /dev/null and b/test_loop/89/KpostProcess/Kperm4.npy differ diff --git a/test_loop/89/KpostProcess/Kperm8.npy b/test_loop/89/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..f5f84d5 Binary files /dev/null and b/test_loop/89/KpostProcess/Kperm8.npy differ diff --git a/test_loop/89/KpostProcess/Kv16.npy b/test_loop/89/KpostProcess/Kv16.npy new file mode 100644 index 0000000..fd081f7 Binary files /dev/null and b/test_loop/89/KpostProcess/Kv16.npy differ diff --git a/test_loop/89/KpostProcess/Kv4.npy b/test_loop/89/KpostProcess/Kv4.npy new file mode 100644 index 0000000..4f9f280 Binary files /dev/null and b/test_loop/89/KpostProcess/Kv4.npy differ diff --git a/test_loop/89/KpostProcess/Kv8.npy b/test_loop/89/KpostProcess/Kv8.npy new file mode 100644 index 0000000..1585ce9 Binary files /dev/null and b/test_loop/89/KpostProcess/Kv8.npy differ diff --git a/test_loop/89/P.npy b/test_loop/89/P.npy new file mode 100644 index 0000000..5b535a2 Binary files /dev/null and b/test_loop/89/P.npy differ diff --git a/test_loop/89/PosKeffSummary.txt b/test_loop/89/PosKeffSummary.txt new file mode 100644 index 0000000..95d37ee --- /dev/null +++ b/test_loop/89/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.913211343063020209e+00 +5.035450932727901119e+00 +4.395961761474609375e-03 +2.345156741512094689e-01 diff --git a/test_loop/89/RunTimes.out b/test_loop/89/RunTimes.out new file mode 100644 index 0000000..5ee1041 --- /dev/null +++ b/test_loop/89/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.29896903038 +Solver: 0.163219928741 +Keff: 5.035796416763831 +N_cores: 1 diff --git a/test_loop/89/SolverRes.txt b/test_loop/89/SolverRes.txt new file mode 100644 index 0000000..a9e4945 --- /dev/null +++ b/test_loop/89/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +5.035796416763830941e+00 +2.000000000000000000e+00 +4.621889591217041016e-01 +1.000000000000000000e+00 diff --git a/test_loop/89/V.npy b/test_loop/89/V.npy new file mode 100644 index 0000000..9eb6725 Binary files /dev/null and b/test_loop/89/V.npy differ diff --git a/test_loop/89/connec.out b/test_loop/89/connec.out new file mode 100644 index 0000000..1c308a8 --- /dev/null +++ b/test_loop/89/connec.out @@ -0,0 +1,9 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.234375000 + NCC : 1 + NCC : 2 + NCC : 3 + NCC : 4 + NCC : 5 diff --git a/test_loop/89/k.npy b/test_loop/89/k.npy new file mode 100644 index 0000000..b100a4c Binary files /dev/null and b/test_loop/89/k.npy differ diff --git a/test_loop/89/lc.txt b/test_loop/89/lc.txt new file mode 100644 index 0000000..d5b84ef --- /dev/null +++ b/test_loop/89/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +1.578849138080507331e+01 +7.666689268396062573e+00 +4.277311248373734998e+00 diff --git a/test_loop/89/tkperm_sub.txt b/test_loop/89/tkperm_sub.txt new file mode 100644 index 0000000..03bcc29 --- /dev/null +++ b/test_loop/89/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.163671493530273438e-01 +1.618862152099609375e-04 diff --git a/test_loop/9/Cmap.npy b/test_loop/9/Cmap.npy new file mode 100644 index 0000000..c919de2 Binary files /dev/null and b/test_loop/9/Cmap.npy differ diff --git a/test_loop/9/ConnSummary.txt b/test_loop/9/ConnSummary.txt new file mode 100644 index 0000000..f15e270 --- /dev/null +++ b/test_loop/9/ConnSummary.txt @@ -0,0 +1,5 @@ +# nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal +4.000000000000000000e+00 +4.500751495361328125e-01 +8.085225177883536007e-01 +3.202804181905249958e-02 diff --git a/test_loop/9/ConnectivityMetrics/16.npy b/test_loop/9/ConnectivityMetrics/16.npy new file mode 100644 index 0000000..00c89f1 Binary files /dev/null and b/test_loop/9/ConnectivityMetrics/16.npy differ diff --git a/test_loop/9/ConnectivityMetrics/4.npy b/test_loop/9/ConnectivityMetrics/4.npy new file mode 100644 index 0000000..a2e072f Binary files /dev/null and b/test_loop/9/ConnectivityMetrics/4.npy differ diff --git a/test_loop/9/ConnectivityMetrics/8.npy b/test_loop/9/ConnectivityMetrics/8.npy new file mode 100644 index 0000000..47d633b Binary files /dev/null and b/test_loop/9/ConnectivityMetrics/8.npy differ diff --git a/test_loop/9/D.npy b/test_loop/9/D.npy new file mode 100644 index 0000000..45a691d Binary files /dev/null and b/test_loop/9/D.npy differ diff --git a/test_loop/9/GenParams.txt b/test_loop/9/GenParams.txt new file mode 100644 index 0000000..1edf769 --- /dev/null +++ b/test_loop/9/GenParams.txt @@ -0,0 +1,13 @@ +# Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario +4.643917083740234375e-03 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.600000000000000000e+01 +1.000000000000000000e+00 +4.000000000000000000e+00 +1.828571428571428570e-01 +1.000000000000000000e+02 +1.000000000000000021e-02 +5.463000000000000000e+03 +0.000000000000000000e+00 +1.000000000000000000e+00 diff --git a/test_loop/9/GlobalConnectivityMetrics/16.npy b/test_loop/9/GlobalConnectivityMetrics/16.npy new file mode 100644 index 0000000..00c89f1 Binary files /dev/null and b/test_loop/9/GlobalConnectivityMetrics/16.npy differ diff --git a/test_loop/9/GlobalConnectivityMetrics/4.npy b/test_loop/9/GlobalConnectivityMetrics/4.npy new file mode 100644 index 0000000..10e3c02 Binary files /dev/null and b/test_loop/9/GlobalConnectivityMetrics/4.npy differ diff --git a/test_loop/9/GlobalConnectivityMetrics/8.npy b/test_loop/9/GlobalConnectivityMetrics/8.npy new file mode 100644 index 0000000..868d527 Binary files /dev/null and b/test_loop/9/GlobalConnectivityMetrics/8.npy differ diff --git a/test_loop/9/KpostProcess/Kd16.npy b/test_loop/9/KpostProcess/Kd16.npy new file mode 100644 index 0000000..ae2416a Binary files /dev/null and b/test_loop/9/KpostProcess/Kd16.npy differ diff --git a/test_loop/9/KpostProcess/Kd4.npy b/test_loop/9/KpostProcess/Kd4.npy new file mode 100644 index 0000000..61b2814 Binary files /dev/null and b/test_loop/9/KpostProcess/Kd4.npy differ diff --git a/test_loop/9/KpostProcess/Kd8.npy b/test_loop/9/KpostProcess/Kd8.npy new file mode 100644 index 0000000..13c20d4 Binary files /dev/null and b/test_loop/9/KpostProcess/Kd8.npy differ diff --git a/test_loop/9/KpostProcess/Kperm4.npy b/test_loop/9/KpostProcess/Kperm4.npy new file mode 100644 index 0000000..22de483 Binary files /dev/null and b/test_loop/9/KpostProcess/Kperm4.npy differ diff --git a/test_loop/9/KpostProcess/Kperm8.npy b/test_loop/9/KpostProcess/Kperm8.npy new file mode 100644 index 0000000..22de483 Binary files /dev/null and b/test_loop/9/KpostProcess/Kperm8.npy differ diff --git a/test_loop/9/KpostProcess/Kv16.npy b/test_loop/9/KpostProcess/Kv16.npy new file mode 100644 index 0000000..cf387dd Binary files /dev/null and b/test_loop/9/KpostProcess/Kv16.npy differ diff --git a/test_loop/9/KpostProcess/Kv4.npy b/test_loop/9/KpostProcess/Kv4.npy new file mode 100644 index 0000000..40f8520 Binary files /dev/null and b/test_loop/9/KpostProcess/Kv4.npy differ diff --git a/test_loop/9/KpostProcess/Kv8.npy b/test_loop/9/KpostProcess/Kv8.npy new file mode 100644 index 0000000..b589c32 Binary files /dev/null and b/test_loop/9/KpostProcess/Kv8.npy differ diff --git a/test_loop/9/P.npy b/test_loop/9/P.npy new file mode 100644 index 0000000..9aead72 Binary files /dev/null and b/test_loop/9/P.npy differ diff --git a/test_loop/9/PosKeffSummary.txt b/test_loop/9/PosKeffSummary.txt new file mode 100644 index 0000000..fbe51e1 --- /dev/null +++ b/test_loop/9/PosKeffSummary.txt @@ -0,0 +1,5 @@ +# K_diss, K_average,ttotal,tDiss/ttotal +4.563085737746095522e-02 +4.650427442705191983e-02 +4.535913467407226562e-03 +2.546123521681997182e-01 diff --git a/test_loop/9/RunTimes.out b/test_loop/9/RunTimes.out new file mode 100644 index 0000000..aca9de5 --- /dev/null +++ b/test_loop/9/RunTimes.out @@ -0,0 +1,5 @@ +ref: 2 +Matrix creation: 0.388194084167 +Solver: 0.399004936218 +Keff: 0.046874632778376696 +N_cores: 1 diff --git a/test_loop/9/SolverRes.txt b/test_loop/9/SolverRes.txt new file mode 100644 index 0000000..a554f4e --- /dev/null +++ b/test_loop/9/SolverRes.txt @@ -0,0 +1,5 @@ +# Keff, ref, Runtime, N_cores +4.687463277837669584e-02 +2.000000000000000000e+00 +7.871990203857421875e-01 +1.000000000000000000e+00 diff --git a/test_loop/9/V.npy b/test_loop/9/V.npy new file mode 100644 index 0000000..c7e33fb Binary files /dev/null and b/test_loop/9/V.npy differ diff --git a/test_loop/9/connec.out b/test_loop/9/connec.out new file mode 100644 index 0000000..9dda9cb --- /dev/null +++ b/test_loop/9/connec.out @@ -0,0 +1,6 @@ + + 6-CONNECTIVITY ANALYSIS + + PROPORTION OF PHASE 1 IS: 0.265625000 + NCC : 1 + NCC : 2 diff --git a/test_loop/9/k.npy b/test_loop/9/k.npy new file mode 100644 index 0000000..640938f Binary files /dev/null and b/test_loop/9/k.npy differ diff --git a/test_loop/9/lc.txt b/test_loop/9/lc.txt new file mode 100644 index 0000000..61fa078 --- /dev/null +++ b/test_loop/9/lc.txt @@ -0,0 +1,4 @@ +# lcG, lcNst, lcBin +7.679686838665332971e+00 +7.679686838665332971e+00 +2.875619060199801957e+00 diff --git a/test_loop/9/tkperm_sub.txt b/test_loop/9/tkperm_sub.txt new file mode 100644 index 0000000..6f401a9 --- /dev/null +++ b/test_loop/9/tkperm_sub.txt @@ -0,0 +1,2 @@ +3.471298217773437500e-01 +1.640319824218750000e-04 diff --git a/test_loop/config.ini b/test_loop/config.ini new file mode 100644 index 0000000..ee3e6ed --- /dev/null +++ b/test_loop/config.ini @@ -0,0 +1,44 @@ +[General] +simDir=test_loop +startJob=0 +[Iterables] +p=[10,39,15] +seeds=[5462,2] +lc=[4] +connectivity=[1,2,3] +variances=[1] + +[Generation] +Nx = 16 +Ny = 16 +Nz = 16 +variogram_type=1 +binary = yes +kh = 100 +kl = 0.01 +compute_lc = yes +lcBin=yes +genera=yes + + +[Connectivity] +keep_aspect= yes +block_size = 4 +indicators_MinBlockSize =4 +Max_sample_size = 12 +compGconec= 1 +conec=yes + + +[Solver] +num_of_cores = 1 +ref = 2 +solve = yes +rtol = 1e-4 + +[K-Postprocess] +MinBlockSize =1 +Max_sample_size = 4 +kperm=yes +postprocess=yes +SaveVfield=yes diff --git a/tests/integration/conf_test.ini b/tests/integration/conf_test.ini new file mode 100644 index 0000000..f34ffb4 --- /dev/null +++ b/tests/integration/conf_test.ini @@ -0,0 +1,44 @@ +[General] +simDir=tests/integration/tmp_output +startJob=0 +[Iterables] +p=[10,39,15] +seeds=[5462,2] +lc=[4] +connectivity=[1,2,3] +variances=[1] + +[Generation] +Nx = 16 +Ny = 16 +Nz = 16 +variogram_type=1 +binary = yes +kh = 100 +kl = 0.01 +compute_lc = yes +lcBin=yes +genera=yes + + +[Connectivity] +keep_aspect= yes +block_size = 4 +indicators_MinBlockSize =4 +Max_sample_size = 12 +compGconec= 1 +conec=yes + + +[Solver] +num_of_cores = 1 +ref = 2 +solve = yes +rtol = 1e-4 + +[K-Postprocess] +MinBlockSize =1 +Max_sample_size = 4 +kperm=yes +postprocess=yes +SaveVfield=yes \ No newline at end of file diff --git a/tests/integration/test.py b/tests/integration/test.py new file mode 100644 index 0000000..1eee165 --- /dev/null +++ b/tests/integration/test.py @@ -0,0 +1,88 @@ +import filecmp +import os.path +import numpy as np +import unittest +from numpy.lib.function_base import diff + +def find_relative_errors(path_original, path): + binary_original = np.load(path_original) + binary = np.load(path) + + diffs = binary_original - binary + + binary_original = binary_original.tolist() + diffs = diffs.tolist() + relative_errors = [] + + for x in range(len(diffs)): + for y in range(len(diffs)): + for z in range(len(diffs)): + if type(diffs[x][y][z]) != type([]): + relative_error = 0 if binary_original[x][y][z] == 0 else diffs[x][y][z] / binary_original[x][y][z] + relative_errors.append(abs(relative_error)) + else: + for w in range(len(diffs)): + relative_error = 0 if binary_original[x][y][z][w] == 0 else diffs[x][y][z][w] / binary_original[x][y][z][w] + relative_errors.append(abs(relative_error)) + + return relative_errors + +BINARIES = ['Cmap', 'D', 'P', 'V', 'k'] + +class TestIntegration(unittest.TestCase): + + @classmethod + def setUpClass(cls): + os.chdir('../..') + config_file = os.path.abspath("./tests/integration/conf_test.ini") + os.system("CONFIG_FILE_PATH="+ config_file + " mpirun python3 mpirunner.py") + + binary_results = {} + for binary in BINARIES: + binary_results[binary] = [] + + for i in range(90): + for binary in BINARIES: + path = './tests/integration/tmp_output/{}/{}.npy'.format(i, binary) + path_original = './test_loop/{}/{}.npy'.format(i, binary) + relative_errors = find_relative_errors(path_original, path) + binary_results[binary].append(relative_errors) + + cls.binary_stats = {} + for binary in binary_results: + binary_results[binary] = [item for sublist in binary_results[binary] for item in sublist] + if len(binary_results[binary]) != 0: + cls.binary_stats[binary] = {"max": max(binary_results[binary]), "avg": sum(binary_results[binary]) / len(binary_results[binary])} + + @classmethod + def tearDownClass(cls): + os.system("rm -rf ./tests/integration/tmp_output") + + def test_Cmap_binary(self): + cmap_stats = self.binary_stats["Cmap"] + self.assertEqual(cmap_stats["max"], 0.0) + self.assertEqual(cmap_stats["avg"], 0.0) + + def test_k_binary(self): + k_stats = self.binary_stats["k"] + self.assertEqual(k_stats["max"], 0.0) + self.assertEqual(k_stats["avg"], 0.0) + + def test_P_binary(self): + P_stats = self.binary_stats["P"] + self.assertLess(P_stats["max"], 0.5) + self.assertLess(P_stats["avg"], 0.0005) + + def test_D_binary(self): + D_stats = self.binary_stats["D"] + self.assertLess(D_stats["max"], 900) + self.assertLess(D_stats["avg"], 0.006) + + def test_V_binary(self): + V_stats = self.binary_stats["V"] + self.assertLess(V_stats["max"], 10) + self.assertLess(V_stats["avg"], 0.05) + + +if __name__ == '__main__': + unittest.main() diff --git a/tools/.nfs000000000008154900000007 b/tools/.nfs000000000008154900000007 new file mode 100644 index 0000000..f96c10d Binary files /dev/null and b/tools/.nfs000000000008154900000007 differ diff --git a/tools/.nfs00000001000b034a0000001e b/tools/.nfs00000001000b034a0000001e new file mode 100644 index 0000000..1184272 Binary files /dev/null and b/tools/.nfs00000001000b034a0000001e differ diff --git a/tools/Prealization.py b/tools/Prealization.py new file mode 100755 index 0000000..5ce8148 --- /dev/null +++ b/tools/Prealization.py @@ -0,0 +1,82 @@ +import numpy as np +from tools.generation.config import DotheLoop, get_config +import os +import sys +from mpi4py import MPI +from tools.connec.comp_cmap import comp_connec +from tools.postprocessK.comp_PostKeff import comp_postKeff +from shutil import copyfile +from tools.solver.comp_Kperm_scale import comp_kperm_sub +from tools.solver.Ndar import PetscP + +CONFIG_FILE_PATH = 'config.ini' if 'CONFIG_FILE_PATH' not in os.environ else os.environ['CONFIG_FILE_PATH'] + +def realization(job): + + if job==-1: + return + + + conffile=CONFIG_FILE_PATH + parser, iterables = get_config(conffile) + start_job=int(parser.get('General',"startJob")) + + if job1: + icomm=MPI.COMM_SELF.Spawn(sys.executable, args=['./tools/solver/Ndar.py',datadir,str(ref),'0',Rtol,'1'], maxprocs=n_p) + icomm.Disconnect() + else: + PetscP(datadir,ref,'0',True,float(Rtol),0) + + + compkperm=parser.get('K-Postprocess',"kperm") + if compkperm!='no': + #print('start kperm') + comp_kperm_sub(parser,datadir,nr) + #print('finished job ' +str(job)) + + postP=parser.get('K-Postprocess',"postprocess") + if postP!='no': + comp_postKeff(parser,datadir,nr) + + + return + +def create_dir(datadir,job): + + try: + os.makedirs(datadir) + except: + print('Warning: Unable to create dir job: '+str(job)) + + return + + + + diff --git a/tools/Prealization.pyc b/tools/Prealization.pyc new file mode 100644 index 0000000..8522330 Binary files /dev/null and b/tools/Prealization.pyc differ diff --git a/tools/__init__.py b/tools/__init__.py new file mode 100755 index 0000000..e69de29 diff --git a/tools/__init__.pyc b/tools/__init__.pyc new file mode 100644 index 0000000..f96c10d Binary files /dev/null and b/tools/__init__.pyc differ diff --git a/tools/connec/.nfs0000000200074f2200000034 b/tools/connec/.nfs0000000200074f2200000034 new file mode 100644 index 0000000..359fd0a Binary files /dev/null and b/tools/connec/.nfs0000000200074f2200000034 differ diff --git a/tools/connec/JoinCmaps.py b/tools/connec/JoinCmaps.py new file mode 100755 index 0000000..af20e5e --- /dev/null +++ b/tools/connec/JoinCmaps.py @@ -0,0 +1,136 @@ +import numpy as np + +def joinCmapX(cmap1,cmap2): + + nclus1 = np.max(cmap1) + cmap2=np.where(cmap2!=0,cmap2+nclus1,0) + + old_nclus=0 + new_nclus=1 + + while new_nclus!= old_nclus: + + old_nclus=new_nclus + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap2=np.where(cmap2==cmap2[0,i,j],cmap1[-1,i,j],cmap2) + + + + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap1=np.where(cmap1==cmap1[-1,i,j],cmap2[0,i,j],cmap1) + + cmap=np.append(cmap1,cmap2,axis=0) + y = np.bincount(cmap.reshape(-1).astype(int)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + new_nclus=cf.shape[0] #cantidad de clusters + #print(new_nclus) + + return cmap + + +def joinCmapY(cmap1,cmap2): + + nclus1 = np.max(cmap1) + cmap2=np.where(cmap2!=0,cmap2+nclus1,0) + + old_nclus=0 + new_nclus=1 + + while new_nclus!= old_nclus: + + old_nclus=new_nclus + for i in range(cmap1.shape[0]): + for j in range(cmap1.shape[2]): + if cmap1[i,-1,j] != 0 and cmap2[i,0,j] !=0: + if cmap1[i,-1,j] != cmap2[i,0,j]: + cmap2=np.where(cmap2==cmap2[i,0,j],cmap1[i,-1,j],cmap2) + + + + for i in range(cmap1.shape[0]): + for j in range(cmap1.shape[2]): + if cmap1[i,-1,j] != 0 and cmap2[i,0,j] !=0: + if cmap1[i,-1,j] != cmap2[i,0,j]: + cmap1=np.where(cmap1==cmap1[i,-1,j],cmap2[i,0,j],cmap1) + + cmap=np.append(cmap1,cmap2,axis=1) + y = np.bincount(cmap.reshape(-1).astype(int)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + new_nclus=cf.shape[0] #cantidad de clusters + #print(new_nclus) + + return cmap + + +def joinCmapZ(cmap1,cmap2): + + nclus1 = np.max(cmap1) + cmap2=np.where(cmap2!=0,cmap2+nclus1,0) + + old_nclus=0 + new_nclus=1 + + while new_nclus!= old_nclus: + + old_nclus=new_nclus + for i in range(cmap1.shape[0]): + for j in range(cmap1.shape[1]): + if cmap1[i,j,-1] != 0 and cmap2[i,j,0] !=0: + if cmap1[i,j,-1] != cmap2[i,j,0]: + cmap2=np.where(cmap2==cmap2[i,j,0],cmap1[i,j,-1],cmap2) + + + + for i in range(cmap1.shape[0]): + for j in range(cmap1.shape[1]): + if cmap1[i,j,-1] != 0 and cmap2[i,j,0] !=0: + if cmap1[i,j,-1] != cmap2[i,j,0]: + cmap1=np.where(cmap1==cmap1[i,j,-1],cmap2[i,j,0],cmap1) + + cmap=np.append(cmap1,cmap2,axis=2) + y = np.bincount(cmap.reshape(-1).astype(int)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + new_nclus=cf.shape[0] #cantidad de clusters + #print(new_nclus) + + return cmap + +def joinBox(vec,join_y,join_z): + + Nx, Ny,Nz=vec.shape[0],vec.shape[1],vec.shape[2] + nx = Nx//2 + ny,nz=Ny, Nz + if join_y: + ny=Ny//2 + if join_z: + nz=Nz//2 + + vec[:,:ny,:nz] = joinCmapX(vec[:nx,:ny,:nz],vec[nx:,:ny,:nz]) + if not join_z and not join_y: + return vec + + if join_y: + vec[:,ny:,:nz] = joinCmapX(vec[:nx,ny:,:nz],vec[nx:,ny:,:nz]) + if join_z: + vec[:,:ny,nz:] = joinCmapX(vec[:nx,:ny,nz:],vec[nx:,:ny,nz:]) + if join_z and join_y: + vec[:,ny:,nz:] = joinCmapX(vec[:nx,ny:,nz:],vec[nx:,ny:,nz:]) + if join_y: + vec[:,:,:nz] = joinCmapY(vec[:,:ny,:nz],vec[:,ny:,:nz]) + if join_z: + if join_y: + vec[:,:,nz:] = joinCmapY(vec[:,:ny,nz:],vec[:,ny:,nz:]) + vec[:,:,:] = joinCmapZ(vec[:,:,:nz],vec[:,:,nz:]) + + return vec + + diff --git a/tools/connec/JoinCmaps.pyc b/tools/connec/JoinCmaps.pyc new file mode 100644 index 0000000..6081863 Binary files /dev/null and b/tools/connec/JoinCmaps.pyc differ diff --git a/tools/connec/PostConec (copy).py b/tools/connec/PostConec (copy).py new file mode 100755 index 0000000..b390256 --- /dev/null +++ b/tools/connec/PostConec (copy).py @@ -0,0 +1,277 @@ +from __future__ import division +import numpy as np +import matplotlib.pyplot as plt +from scipy import stats +import os +import collections + + + +def ConnecInd(cmap,scales,datadir): + + datadir=datadir+'ConnectivityMetrics/' + try: + os.makedirs(datadir) + except: + nada=0 + + for scale in scales: + res=dict() + res=doforsubS_computeCmap(res,cmap,scale,postConec) + np.save(datadir+str(scale)+'.npy',res) + + return + +def doforsubS_computeCmap(res,cmap,l,funpost): + + + L=cmap.shape[0] + Nx, Ny,Nz=cmap.shape[0],cmap.shape[1],cmap.shape[2] + + nblx=Nx//l #for each dimension + nbly=Ny//l + if cmap.shape[2]==1: + lz=1 + nblz=1 + else: + lz=l + nblz=Nz//l + + keys=funpost(np.array([]),res,0,0) + + for key in keys: + res[key]=np.zeros((nblx,nbly,nblz)) + + for i in range(nblx): + for j in range(nbly): + for k in range(nblz): + res=funpost(cmap[i*l:(i+1)*l,j*l:(j+1)*l,k*l:(k+1)*lz],res,(i,j,k),1) + + return res + +def postConec(cmap,results,ind,flag): + + + if flag==0: + keys=[] + keys+=['PPHA'] + keys+=['VOLALE'] + keys+=['ZNCC'] + keys+=['GAMMA'] + keys+=['spanning', 'npz', 'npy', 'npx'] + keys+=['Plen','S','P'] + return keys + + + dim=3 + if cmap.shape[2]==1: + cmap=cmap[:,:,0] + dim=2 + + y = np.bincount(cmap.reshape(-1)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + + if cf[0,0]==0: + cf=cf[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + + if cf.shape[0]>0: + + + spanning, pclusZ, pclusY, pclusX =get_perco(cmap,dim) + plen=Plen(spanning,cmap,cf,dim) + nper=np.sum(cf[:,1]) #num de celdas permeables + nclus=cf.shape[0] #cantidad de clusters + + results['PPHA'][ind]=nper/np.size(cmap) #ppha + results['VOLALE'][ind]=np.max(cf[:,1])/nper #volale #corregido va entre [0,p] + results['ZNCC'][ind]=nclus #zncc + results['GAMMA'][ind]=np.sum(cf[:,1]**2)/np.size(cmap)/nper #gamma, recordar zintcc =gamma*p + results['spanning'][ind],results['npz'][ind], results['npy'][ind], results['npx'][ind]=spanning, len(pclusZ), len(pclusY), len(pclusX) + results['Plen'][ind],results['S'][ind],results['P'][ind] = plen[0],plen[1],plen[2] + + + if cf.shape[0]==0: + for key in keys: + results[key][ind]=0 + return results + + +#ZINTCC,VOLALE,ZGAMMA,ZIPZ,ZNCC,PPHA + + +def get_pos2D(cmap,cdis): + + Ns=cdis.shape[0] + pos=dict() + i=0 + for cnum in cdis[:,0]: + pos[cnum]=np.zeros((cdis[i,1]+1,2)) #+1 porque uso de flag + i+=1 + + for i in range(cmap.shape[0]): + for j in range(cmap.shape[1]): + if cmap[i,j] != 0: + flag=int(pos[cmap[i,j]][0,0])+1 + pos[cmap[i,j]][0,0]=flag + pos[cmap[i,j]][flag,0]=i + pos[cmap[i,j]][flag,1]=j + return pos + + +def get_pos3D(cmap,cdis): + + Ns=cdis.shape[0] + pos=dict() + i=0 + for cnum in cdis[:,0]: + pos[cnum]=np.zeros((cdis[i,1]+1,3)) + i+=1 + for i in range(cmap.shape[0]): + for j in range(cmap.shape[1]): + for k in range(cmap.shape[2]): + + if cmap[i,j,k] != 0: + flag=int(pos[cmap[i,j,k]][0,0])+1 + pos[cmap[i,j,k]][0,0]=flag + pos[cmap[i,j,k]][flag,0]=i + pos[cmap[i,j,k]][flag,1]=j + pos[cmap[i,j,k]][flag,2]=k + + + return pos + +def Plen(spannng,cmap,cdis,dim): + + if dim==2: + return P_len2D(spannng,cmap,cdis) + if dim==3: + return P_len3D(spannng,cmap,cdis) + return [] + +def P_len2D(spanning,cmap,cdis): + + pos = get_pos2D(cmap,cdis) + #print(summary['NpcY'],summary['NpcX'],summary['PPHA']) + + den=0 + num=0 + + nperm=np.sum(cdis[:,1]) + if spanning > 0: + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + else: + P=0 + + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + + +def P_len3D(spanning,cmap,cdis): + + + pos = get_pos3D(cmap,cdis) + #print(summary['NpcY'],summary['NpcX'],summary['PPHA']) + + den=0 + num=0 + + nperm=np.sum(cdis[:,1]) + if spanning > 0: + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + else: + P=0 + + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy, mposz = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]), np.mean(pos[cnum][1:,2]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2+(pos[cnum][1:,2]-mposz)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + + +def get_perco(cmap,dim): + + if dim==2: + + pclusY=[] #list of the percolating clusters + for i in range(cmap.shape[0]): + if cmap[i,0] != 0: + if cmap[i,0] not in pclusY: + if cmap[i,0] in cmap[:,-1]: + pclusY+=[cmap[i,0]] + + + pclusZ=[] #list of the percolating clusters Z direction, this one is the main flow in Ndar.py, the fixed dimension is the direction used to see if pecolates + for i in range(cmap.shape[1]): + if cmap[0,i] != 0: + if cmap[0,i] not in pclusZ: + if cmap[0,i] in cmap[-1,:]: #viendo sin en la primer cara esta el mismo cluster que en la ultima + pclusZ+=[cmap[0,i]] + + + pclusX=[] + spanning=0 + if len(pclusZ)==1 and pclusZ==pclusY: + spanning=1 + + + if dim==3: + + + pclusX=[] #list of the percolating clusters + for i in range(cmap.shape[0]): # Z + for j in range(cmap.shape[1]): #X + if cmap[i,j,0] != 0: + if cmap[i,j,0] not in pclusX: + if cmap[i,j,0] in cmap[:,:,-1]: + pclusX+=[cmap[i,j,0]] + + pclusY=[] #list of the percolating clusters + for i in range(cmap.shape[0]): # Z + for k in range(cmap.shape[2]): #X + if cmap[i,0,k] != 0: + if cmap[i,0,k] not in pclusY: + if cmap[i,0,k] in cmap[:,-1,:]: + pclusY+=[cmap[i,0,k]] + + pclusZ=[] #list of the percolating clusters + for k in range(cmap.shape[2]): #x + for j in range(cmap.shape[1]): #y + if cmap[0,j,k] != 0: + if cmap[0,j,k] not in pclusZ: + if cmap[0,j,k] in cmap[-1,:,:]: + pclusZ+=[cmap[0,j,k]] #this is the one + + spanning=0 + if len(pclusZ)==1 and pclusZ==pclusY and pclusZ==pclusX: + spanning=1 + + + return spanning, pclusZ, pclusY, pclusX diff --git a/tools/connec/PostConec.py b/tools/connec/PostConec.py new file mode 100755 index 0000000..02ea2fa --- /dev/null +++ b/tools/connec/PostConec.py @@ -0,0 +1,233 @@ +from __future__ import division +import numpy as np +from scipy import stats +import os +import collections + + + +def ConnecInd(cmap,scales,datadir): + + datadir=datadir+'ConnectivityMetrics/' + try: + os.makedirs(datadir) + except: + nada=0 + + for scale in scales: + res=dict() + res=doforsubS_computeCmap(res,cmap,scale,postConec) + np.save(datadir+str(scale)+'.npy',res) + + return + +def doforsubS_computeCmap(res,cmap,l,funpost): + + + L=cmap.shape[0] + Nx, Ny,Nz=cmap.shape[0],cmap.shape[1],cmap.shape[2] + + nblx=Nx//l #for each dimension + + ly=l + nbly=Ny//l + + lz=l + nblz=Nz//l + + if nbly==0: #si l> Ny + nbly=1 + ly=Ny + + if nblz==0: + lz=1 + nblz=1 + + + keys=funpost(np.array([]),res,0,0) + + for key in keys: + res[key]=np.zeros((nblx,nbly,nblz)) + + for i in range(nblx): + for j in range(nbly): + for k in range(nblz): + res=funpost(cmap[i*l:(i+1)*l,j*ly:(j+1)*ly,k*l:(k+1)*lz],res,(i,j,k),1) + + return res + +def postConec(cmap,results,ind,flag): + + keys=[] + keys+=['PPHA'] + keys+=['VOLALE'] + keys+=['ZNCC'] + keys+=['GAMMA'] + keys+=['spanning', 'npz', 'npy', 'npx'] + keys+=['Plen','S','P'] + keys+=['PlenX','SX','PX'] + if flag==0: + + return keys + + + y = np.bincount(cmap.reshape(-1)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + + if cf[0,0]==0: + cf=cf[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + + if cf.shape[0]>0: + spanning, pclusX, pclusY, pclusZ =get_perco(cmap) + plen=Plen(spanning,cmap,cf) + #print(pclusX,spanning) + if len(pclusX) >0 and spanning ==0: + plenX=PlenX(pclusX,cmap,cf) + else: + plenX=plen + nper=np.sum(cf[:,1]) #num de celdas permeables + nclus=cf.shape[0] #cantidad de clusters + results['PPHA'][ind]=nper/np.size(cmap) #ppha + results['VOLALE'][ind]=np.max(cf[:,1])/nper #volale #corregido va entre [0,p] + results['ZNCC'][ind]=nclus #zncc + results['GAMMA'][ind]=np.sum(cf[:,1]**2)/nper**2 #gamma, recordar zintcc =gamma*nper + results['spanning'][ind],results['npz'][ind], results['npy'][ind], results['npx'][ind]=spanning, len(pclusZ), len(pclusY), len(pclusX) + results['Plen'][ind],results['S'][ind],results['P'][ind] = plen[0],plen[1],plen[2] + results['PlenX'][ind],results['SX'][ind],results['PX'][ind] = plenX[0],plenX[1],plenX[2] + if cf.shape[0]==0: + for key in keys: + results[key][ind]=0 + return results + +def get_pos(cmap,cdis): + + Ns=cdis.shape[0] + pos=dict() + i=0 + for cnum in cdis[:,0]: + pos[cnum]=np.zeros((cdis[i,1]+1,3)) + i+=1 + for i in range(cmap.shape[0]): + for j in range(cmap.shape[1]): + for k in range(cmap.shape[2]): + + if cmap[i,j,k] != 0: + flag=int(pos[cmap[i,j,k]][0,0])+1 + pos[cmap[i,j,k]][0,0]=flag + pos[cmap[i,j,k]][flag,0]=i + pos[cmap[i,j,k]][flag,1]=j + pos[cmap[i,j,k]][flag,2]=k + + return pos + +def Plen(spanning,cmap,cdis): + + pos = get_pos(cmap,cdis) + #print(summary['NpcY'],summary['NpcX'],summary['PPHA']) + + den=0 + num=0 + + nperm=np.sum(cdis[:,1]) + if spanning > 0: + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + else: + P=0 + + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy, mposz = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]), np.mean(pos[cnum][1:,2]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2+(pos[cnum][1:,2]-mposz)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + +def PlenX(pclusX,cmap,cdis): + + #guarda que solo se entra en esta funcion si no es spanning pero hay al menos 1 cluster percolante en X + + for cluster in pclusX[1:]: + cmap=np.where(cmap==cluster,pclusX[0],cmap) + + + y = np.bincount(cmap.reshape(-1)) + ii = np.nonzero(y)[0] + cdis=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + + if cdis[0,0]==0: + cdis=cdis[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + + + pos = get_pos(cmap,cdis) + nperm=np.sum(cdis[:,1]) + + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + den=0 + num=0 + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy, mposz = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]), np.mean(pos[cnum][1:,2]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2+(pos[cnum][1:,2]-mposz)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + + +def get_perco(cmap): + + + pclusX=[] #list of the percolating clusters + for k in range(cmap.shape[2]): #x + for j in range(cmap.shape[1]): #y + if cmap[0,j,k] != 0: + if cmap[0,j,k] not in pclusX: + if cmap[0,j,k] in cmap[-1,:,:]: + pclusX+=[cmap[0,j,k]] #this is the one + + pclusY=[] #list of the percolating clusters + for i in range(cmap.shape[0]): # Z + for k in range(cmap.shape[2]): #X + if cmap[i,0,k] != 0: + if cmap[i,0,k] not in pclusY: + if cmap[i,0,k] in cmap[:,-1,:]: + pclusY+=[cmap[i,0,k]] + + pclusZ=[] #list of the percolating clusters + if cmap.shape[2]>1: + for i in range(cmap.shape[0]): # Z + for j in range(cmap.shape[1]): #X + if cmap[i,j,0] != 0: + if cmap[i,j,0] not in pclusZ: + if cmap[i,j,0] in cmap[:,:,-1]: + pclusZ+=[cmap[i,j,0]] + + spanning=0 + if len(pclusZ)==1 and pclusZ==pclusY and pclusZ==pclusX: + spanning=1 + else: + spanning=0 + if len(pclusX)==1 and pclusY==pclusX: + spanning=1 + + return spanning, pclusX, pclusY, pclusZ diff --git a/tools/connec/PostConec.pyc b/tools/connec/PostConec.pyc new file mode 100644 index 0000000..0e26281 Binary files /dev/null and b/tools/connec/PostConec.pyc differ diff --git a/tools/connec/PostConec_v2.py b/tools/connec/PostConec_v2.py new file mode 100755 index 0000000..e4cd7aa --- /dev/null +++ b/tools/connec/PostConec_v2.py @@ -0,0 +1,368 @@ +from __future__ import division +import numpy as np +import matplotlib.pyplot as plt +from scipy import stats +import os +import collections + + + +def main(): + + + #scales=[4,6,8,16,24,32] + #numofseeds=np.array([10,10,10,48,100,200]) + #startseed=1 + + scales=[2,4,8,12,16,20,26,32] + numofseeds=np.array([1,2,12,16,20,25,30,50]) + + startseed=1 + dim=3 + + numofseeds=numofseeds+startseed + + mapa=np.loadtxt(('vecconec.txt')).astype(int) + + if dim==2: + LL=int(np.sqrt(mapa.shape[0])) + mapa=mapa.reshape(LL,LL) + + if dim==3: + LL=int(np.cbrt(mapa.shape[0])) + mapa=mapa.reshape(LL,LL,LL) + res, names=doforsubS_computeCmap(mapa,scales,postConec, compCon,dim,[],numofseeds) + + with open('keysCon.txt', 'w') as f: + for item in names: + f.write("%s\n" % item) + + np.save('ConResScales.npy',res) + + + return + +def doforsubS_computeCmap(mapa,scales,funpost, funcompCmap,dim,args,numofseeds): + + L=mapa.shape[0] + res=dict() + names=[] + + + with open('Kfield.don') as f: + seed = int(f.readline()) + + for iscale in range(len(scales)): + + l=scales[iscale] + + if numofseeds[iscale] > seed: #guarda aca + + nblocks=L//l #for each dimension + + if dim==2: + for i in range(nblocks): + for j in range(nblocks): + cmapa=funcompCmap(mapa[i*l:(i+1)*l,j*l:(j+1)*l],dim) + dats,names=funpost(cmapa,dim,args) + if i== 0 and j==0: + for icon in range(len(names)): + res[l,names[icon]]=[] + for icon in range(len(names)): + res[l,names[icon]]+=[dats[icon]] + + + if dim==3: + for i in range(nblocks): + for j in range(nblocks): + for k in range(nblocks): + cmapa=funcompCmap(mapa[i*l:(i+1)*l,j*l:(j+1)*l,k*l:(k+1)*l],dim) + dats, names=funpost(cmapa,dim,args) + if i== 0 and j==0 and k==0: + for icon in range(len(names)): + res[l,names[icon]]=[] + for icon in range(len(names)): + res[l,names[icon]]+=[dats[icon]] + + + + return res, names + + +def ConConfig(L,dim): + + params=[] + if dim==2: + params=['1','4','imap.txt',str(L)+' '+str(L),'1.0 1.0','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec2d' + + if dim==3: + params=['1','6','imap.txt',str(L)+' '+str(L)+' ' +str(L),'1.0 1.0 1.0','30','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec3d' + return params, execCon + + + +def compCon(mapa,dim): + + exeDir='./' + L=mapa.shape[0] + params,execCon=ConConfig(L,dim) + + with open(exeDir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + np.savetxt(exeDir+params[2],mapa.reshape(-1)) + + #wiam=os.getcwd() + #os.chdir(exeDir) + os.system('cp ../../../tools/conec3d ./') + os.system(' ./'+execCon +'>/dev/null') #'cd ' +exeDir+ + + cmapa=np.loadtxt(params[-2]).reshape(mapa.shape).astype(int) #exeDir+ + #os.chdir(wiam) + return cmapa + + + + + +def postConec(cmap,dim,args): + + names=['PPHA','VOLALE','ZNCC','zintcc','spaninning','npz','npy','npx',] + + + L=cmap.shape[0] + results=[] + names=[] + + + y = np.bincount(cmap.reshape(-1)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + + if cf[0,0]==0: + cf=cf[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + + if cf.shape[0]>0: + # headers=['N','p','Csize','CLenX','CLenY','CmaxVol','MaxLenX','MaxLenY','NpcX','NpcY'] + + nper=np.sum(cf[:,1]) #num de celdas permeables + nclus=cf.shape[0] #cantidad de clusters + + + #ZINTCC,VOLALE,ZGAMMA,ZIPZ,ZNCC,PPHA + results+=[nper/np.size(cmap)] #ppha + results+=[np.max(cf[:,1])/nper] #volale #corregido va entre [0,p] + results+=[nclus] #zncc + results+=[np.sum(cf[:,1]**2)/np.size(cmap)/nper] #gamma, recordar zintcc =gamma*p + + spanning, pclusZ, pclusY, pclusX =get_perco(cmap,dim) + results+=[spanning, len(pclusZ), len(pclusY), len(pclusX)] + + + results+=Plen(spanning,cmap,cf,dim) + + + names+=['PPHA'] + names+=['VOLALE'] + names+=['ZNCC'] + names+=['ZINTCC'] + names+=['spanning', 'npz', 'npy', 'npx'] + names+=['Plen','S','P'] + + if cf.shape[0]==0: + for i in range(len(names)): + results+=[0] + return results, names + + +#ZINTCC,VOLALE,ZGAMMA,ZIPZ,ZNCC,PPHA + + +def get_pos2D(cmap,cdis): + + Ns=cdis.shape[0] + pos=dict() + i=0 + for cnum in cdis[:,0]: + pos[cnum]=np.zeros((cdis[i,1]+1,2)) #+1 porque uso de flag + i+=1 + + for i in range(cmap.shape[0]): + for j in range(cmap.shape[1]): + if cmap[i,j] != 0: + flag=int(pos[cmap[i,j]][0,0])+1 + pos[cmap[i,j]][0,0]=flag + pos[cmap[i,j]][flag,0]=i + pos[cmap[i,j]][flag,1]=j + + + + return pos + + +def get_pos3D(cmap,cdis): + + Ns=cdis.shape[0] + pos=dict() + i=0 + for cnum in cdis[:,0]: + pos[cnum]=np.zeros((cdis[i,1]+1,3)) + i+=1 + for i in range(cmap.shape[0]): + for j in range(cmap.shape[1]): + for k in range(cmap.shape[2]): + + if cmap[i,j,k] != 0: + flag=int(pos[cmap[i,j,k]][0,0])+1 + pos[cmap[i,j,k]][0,0]=flag + pos[cmap[i,j,k]][flag,0]=i + pos[cmap[i,j,k]][flag,1]=j + pos[cmap[i,j,k]][flag,2]=k + + + return pos + +def Plen(spannng,cmap,cdis,dim): + + if dim==2: + return P_len2D(spannng,cmap,cdis) + if dim==3: + return P_len3D(spannng,cmap,cdis) + return [] + +def P_len2D(spanning,cmap,cdis): + + + pos = get_pos2D(cmap,cdis) + #print(summary['NpcY'],summary['NpcX'],summary['PPHA']) + + den=0 + num=0 + + nperm=np.sum(cdis[:,1]) + if spanning > 0: + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + else: + P=0 + + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + + +def P_len3D(spanning,cmap,cdis): + + + pos = get_pos3D(cmap,cdis) + #print(summary['NpcY'],summary['NpcX'],summary['PPHA']) + + den=0 + num=0 + + nperm=np.sum(cdis[:,1]) + if spanning > 0: + amax=np.argmax(cdis[:,1]) + P=cdis[amax,1]/nperm + cdis=np.delete(cdis,amax,axis=0) + + else: + P=0 + + i=0 + if cdis.shape[0]> 0: + S=np.sum(cdis[:,1])/(cdis.shape[0]) + for cnum in cdis[:,0]: #los clusters estan numerados a partir de 1, cluster cero es k- + mposx, mposy, mposz = np.mean(pos[cnum][1:,0]), np.mean(pos[cnum][1:,1]), np.mean(pos[cnum][1:,2]) #el 1: de sacar el flag + Rs =np.mean((pos[cnum][1:,0]-mposx)**2 +(pos[cnum][1:,1]-mposy)**2+(pos[cnum][1:,2]-mposz)**2) #Rs cuadrado ecuacion 12.9 libro Harvey Gould, Jan Tobochnik + num += cdis[i,1]**2 * Rs + den+=cdis[i,1]**2 + i+=1 + return [np.sqrt(num/den), S, P] + else: + return [0,0,P] + + + + +def get_perco(cmap,dim): + + if dim==2: + + pclusY=[] #list of the percolating clusters + for i in range(cmap.shape[0]): + if cmap[i,0] != 0: + if cmap[i,0] not in pclusY: + if cmap[i,0] in cmap[:,-1]: + pclusY+=[cmap[i,0]] + + + pclusZ=[] #list of the percolating clusters Z direction, this one is the main flow in Ndar.py, the fixed dimension is the direction used to see if pecolates + for i in range(cmap.shape[1]): + if cmap[0,i] != 0: + if cmap[0,i] not in pclusZ: + if cmap[0,i] in cmap[-1,:]: #viendo sin en la primer cara esta el mismo cluster que en la ultima + pclusZ+=[cmap[0,i]] + + + pclusX=[] + spanning=0 + if len(pclusZ)==1 and pclusZ==pclusY: + spanning=1 + + + if dim==3: + + + pclusX=[] #list of the percolating clusters + for i in range(cmap.shape[0]): # Z + for j in range(cmap.shape[1]): #X + if cmap[i,j,0] != 0: + if cmap[i,j,0] not in pclusX: + if cmap[i,j,0] in cmap[:,:,-1]: + pclusX+=[cmap[i,j,0]] + + pclusY=[] #list of the percolating clusters + for i in range(cmap.shape[0]): # Z + for k in range(cmap.shape[2]): #X + if cmap[i,0,k] != 0: + if cmap[i,0,k] not in pclusY: + if cmap[i,0,k] in cmap[:,-1,:]: + pclusY+=[cmap[i,0,k]] + + pclusZ=[] #list of the percolating clusters + for k in range(cmap.shape[2]): #x + for j in range(cmap.shape[1]): #y + if cmap[0,j,k] != 0: + if cmap[0,j,k] not in pclusZ: + if cmap[0,j,k] in cmap[-1,:,:]: + pclusZ+=[cmap[0,j,k]] #this is the one + + spanning=0 + if len(pclusZ)==1 and pclusZ==pclusY and pclusZ==pclusX: + spanning=1 + + + return spanning, pclusZ, pclusY, pclusX + + +main() + + + + diff --git a/tools/connec/__init__.py b/tools/connec/__init__.py new file mode 100755 index 0000000..e69de29 diff --git a/tools/connec/__init__.pyc b/tools/connec/__init__.pyc new file mode 100644 index 0000000..c48371d Binary files /dev/null and b/tools/connec/__init__.pyc differ diff --git a/tools/connec/back/comp_cmap_scales.py b/tools/connec/back/comp_cmap_scales.py new file mode 100755 index 0000000..6da035b --- /dev/null +++ b/tools/connec/back/comp_cmap_scales.py @@ -0,0 +1,130 @@ +import numpy as np +import os +import time +from JoinCmaps import * +#k[x,y,z] + + +def div_veccon(kc,kh,nbl,rundir): + + t0=time.time() + kc=np.where(kc==kh,1,0).astype(int) + + tcmaps=time.time() + kc=get_smallCmap(kc,nbl,rundir) + tcmaps=time.time()-tcmaps + #if s_scale/dev/null') #'cd ' +exeDir++'>/dev/null' + vec=np.loadtxt(params[-2]).reshape(vec.shape[0],vec.shape[1],vec.shape[2]).astype(int) + return vec + +def ConConfig(sx,sy,sz,Nz,rundir): + + params=[] + if Nz==1: + params=['1','4','vecconec.txt',str(sx)+' '+str(sy),'1.0 1.0','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec2d' + + else: + params=['1','6','vecconec.txt',str(sx)+' '+str(sy)+' ' +str(sz),'1.0 1.0 1.0','30','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec3d' + + + with open(rundir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + + return params, execCon + +def join(vec,nbl): + + + Nx, Ny,Nz=vec.shape[0],vec.shape[1],vec.shape[2] + sx,sy,sz = Nx//nbl,Ny//nbl,Nz//nbl + ex,ey,ez=np.log2(Nx),np.log2(Ny),np.log2(Nz) + + if Nz==1: + sz=1 + nbz=1 + ez=1 + esz=1 + else: + esz=np.log2(sz) + + + esx,esy=np.log2(sx),np.log2(sy) + + + + for bs in range(0,int(ex-esx)): + + nbx,nby = int(2**(ex-esx-bs-1)),int(2**(ey-esy-bs-1)) + if Nz==1: + sz=1 + nbz=1 + else: + nbz=int(2**(ez-esz-bs-1)) + sz=Nz//nbz + sx,sy=Nx//nbx,Ny//nby + + for i in range(nbx): + for j in range(nby): + for k in range(nbz): + a=2 + vec[i*sx:(i+1)*sx,j*sy:(j+1)*sy,k*sz:(k+1)*sz]=joinBox(vec[i*sx:(i+1)*sx,j*sy:(j+1)*sy,k*sz:(k+1)*sz],True,False) + + return vec + +''' +job=0 +k=np.load('../../data/'+str(job)+'/k.npy') +div_veccon(k,100,1,'./') +div_veccon(k,100,2,'./') +div_veccon(k,100,4,'./') +''' + +for job in range(6): + k=np.load('../../data/'+str(job)+'/k.npy') + print(job) + res=div_veccon(k,100,4,'./') + np.savetxt('../../data/'+str(job)+'/Cmap_res.txt',res) + res=div_veccon(k,100,1,'./') + #div_veccon(k,100,64,'./') + #div_veccon(k,100,128,'./') diff --git a/tools/connec/back/get_cmap.py b/tools/connec/back/get_cmap.py new file mode 100755 index 0000000..76ce203 --- /dev/null +++ b/tools/connec/back/get_cmap.py @@ -0,0 +1,117 @@ +import numpy as np +import os +import time + +def div_veccon(vec,kh,npartes,condir): + + vec=np.where(vec==kh,1,0).astype(int) + Nx, Ny,Nz=k.shape[0],k.shape[1],k.shape[2] + rdir='./' + tt=0 + t1=time.time() + nx=Nx//npartes + params,execCon=ConConfig(nx,Ny,Nz) + + with open(condir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + + wiam=os.getcwd() + os.chdir(condir) + + + i=0 + np.savetxt(condir+params[2],vec[i*nx:(i+1)*nx,:,:].reshape(-1)) + tcon=time.time() + os.system(' ./'+execCon +'>/dev/null') #'cd ' +exeDir+ + tt=tt+(time.time()-tcon) + cmap=np.loadtxt(params[-2]).reshape(nx,Ny,Nz).astype(int) + + + + for i in range(1,npartes): + np.savetxt(condir+params[2],vec[i*nx:(i+1)*nx,:,:].reshape(-1)) + tcon=time.time() + os.system(' ./'+execCon +'>/dev/null') #'cd ' +exeDir++'>/dev/null' + tt=tt+(time.time()-tcon) + cmapb=np.loadtxt(params[-2]).reshape(nx,Ny,Nz).astype(int) + cmap=joinCmap(cmap,cmapb) + + if npartes > 1: + np.savetxt(rdir+'cmap.txt',cmap.reshape(-1)) + + Ttotal, frac_solver = time.time()-t1, tt/(time.time()-t1) + + + y = np.bincount(cmap.reshape(-1)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + if cf[0,0]==0: + cf=cf[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + nclus=cf.shape[0] #cantidad de clusters + nper=np.sum(cf[:,1]) #num de celdas permeables + print(nclus,float(nper)/(vec.size),Ttotal) + return np.array([npartes,nx*Ny*Nz,Ttotal, frac_solver ,nclus,float(nper)/(Nx*Nx)]) + + +def ConConfig(nx,Ny,Nz): + + params=[] + if Nz==1: + params=['1','4','vecconec.txt',str(nx)+' '+str(Ny),'1.0 1.0','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec2d' + + else: + params=['1','6','vecconec.txt',str(nx)+' '+str(Nz)+' ' +str(Nz),'1.0 1.0 1.0','30','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec3d' + return params, execCon + + +def joinCmap(cmap1,cmap2): + + nclus1 = np.max(cmap1) + cmap2=np.where(cmap2!=0,cmap2+nclus1,0) + + old_nclus=0 + new_nclus=1 + + while new_nclus!= old_nclus: + + old_nclus=new_nclus + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap2=np.where(cmap2==cmap2[0,i,j],cmap1[-1,i,j],cmap2) + + + + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap1=np.where(cmap1==cmap1[-1,i,j],cmap2[0,i,j],cmap1) + + cmap=np.append(cmap1,cmap2,axis=0) + y = np.bincount(cmap.reshape(-1).astype(int)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + new_nclus=cf.shape[0] #cantidad de clusters + #print(new_nclus) + + + + return cmap + + +partes=[1,4] +for i in range(1): + t00=time.time() + res=np.array([]) + rdir='../../data/'+str(i)+'/' + k=np.load('k643d.npy') + for npar in partes: + res=np.append(res,div_veccon(k,100,npar,'./')) + np.savetxt(rdir+'resTestCon.txt',res.reshape(len(partes),-1)) + #np.savetxt(rdir+'resTestCon.txt',res.reshape(len(partes),-1)) + print(i,time.time()-t00) diff --git a/tools/connec/back/get_cmapOpt.py b/tools/connec/back/get_cmapOpt.py new file mode 100755 index 0000000..435898c --- /dev/null +++ b/tools/connec/back/get_cmapOpt.py @@ -0,0 +1,111 @@ +import numpy as np +import os +import time + +def div_veccon(vec,kh,npartes,condir): + + vec=np.where(vec==kh,1,0).astype(int) + Nx, Ny,Nz=k.shape[0],k.shape[1],k.shape[2] + rdir='./' + tt=0 + t1=time.time() + nx=Nx//npartes + params,execCon=ConConfig(nx,Ny,Nz) + + with open(condir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + + wiam=os.getcwd() + os.chdir(condir) + + + i=0 + np.savetxt(condir+params[2],vec[i*nx:(i+1)*nx,:,:].reshape(-1)) + tcon=time.time() + os.system(' ./'+execCon +'>/dev/null') #'cd ' +exeDir+ + tt=tt+(time.time()-tcon) + cmap=np.loadtxt(params[-2]).reshape(nx,Ny,Nz) + + + + for i in range(1,npartes): + np.savetxt(condir+params[2],vec[i*nx:(i+1)*nx,:,:].reshape(-1)) + tcon=time.time() + os.system(' ./'+execCon +'>/dev/null') #'cd ' +exeDir++'>/dev/null' + tt=tt+(time.time()-tcon) + cmapb=np.loadtxt(params[-2]).reshape(nx,Ny,Nz) + cmap=joinCmap(cmap,cmapb) + + if npartes > 1: + np.savetxt(rdir+'cmap.txt',cmap.reshape(-1)) + + Ttotal, frac_solver = time.time()-t1, tt/(time.time()-t1) + + + y = np.bincount(cmap.reshape(-1).astype(int)) + ii = np.nonzero(y)[0] + cf=np.vstack((ii,y[ii])).T #numero de cluster, frecuencia + if cf[0,0]==0: + cf=cf[1:,:] #me quedo solo con la distr de tamanos, elimino info cluster cero + nclus=cf.shape[0] #cantidad de clusters + nper=np.sum(cf[:,1]) #num de celdas permeables + + return np.array([npartes,nx*Ny*Nz,Ttotal, frac_solver ,nclus,float(nper)/(Nx*Nx)]) + + +def ConConfig(nx,Ny,Nz): + + params=[] + if Nz==1: + params=['1','4','vecconec.txt',str(nx)+' '+str(Ny),'1.0 1.0','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec2d' + + else: + params=['1','6','vecconec.txt',str(nx)+' '+str(Nz)+' ' +str(Nz),'1.0 1.0 1.0','30','pardol.STA','pardol.CCO','pardol.COF'] + execCon='conec3d' + return params, execCon + + +def joinCmap(cmap1,cmap2): + + nclus1 = np.max(cmap1) + cmap2=np.where(cmap2!=0,cmap2+nclus1,0) + + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap2=np.where(cmap2==cmap2[0,i,j],cmap1[-1,i,j],cmap2) + + + + for i in range(cmap1.shape[1]): + for j in range(cmap1.shape[2]): + if cmap1[-1,i,j] != 0 and cmap2[0,i,j] !=0: + if cmap1[-1,i,j] != cmap2[0,i,j]: + cmap1=np.where(cmap1==cmap1[-1,i,j],cmap2[0,i,j],cmap1) + + cmap=np.append(cmap1,cmap2,axis=0) + + + + return cmap + +njobs=2 +partes=[1,4,8,16] +for i in range(210): + t00=time.time() + res=np.array([]) + rdir='../../data/'+str(i)+'/' + k=np.load(rdir+'k.npy') + for npar in partes: + res=np.append(res,div_veccon(k,100,npar,'./')) + res=res.reshape(len(partes),-1) + try: + rres=np.loadtxt(rdir+'resTestCon.txt') + res=np.append(rres,res,axis=0) + np.savetxt(rdir+'resTestCon.txt',res) + except: + np.savetxt(rdir+'resTestCon.txt',res) + print(i,time.time()-t00) diff --git a/tools/connec/comp_cmap.py b/tools/connec/comp_cmap.py new file mode 100755 index 0000000..5f867b4 --- /dev/null +++ b/tools/connec/comp_cmap.py @@ -0,0 +1,186 @@ +import numpy as np +import os +import time +from tools.connec.JoinCmaps import * +import subprocess +from tools.connec.PostConec import ConnecInd +#k[x,y,z] +import json + +def comp_connec(parser,rundir,nr): + + + kc=np.load(rundir+'k.npy') + keep_aspect = parser.get('Connectivity','keep_aspect') + kh,sx = float(parser.get('Generation','kh')),int(parser.get('Connectivity','block_size')) + S_min_post = int(parser.get('Connectivity','indicators_MinBlockSize')) + nimax =2** int(parser.get('Connectivity','Max_sample_size')) + + gcon =bool(parser.get('Connectivity','compGconec')) + + if S_min_post ==-1 or S_min_post > kc.shape[0]: + S_min_post=kc.shape[0] #solo calcula indicadores para mayo escala + if S_min_post ==0: + S_min_post=sx #solo calcula indicadores para escalas a partir del optimo + if sx > S_min_post: + sx = get_min_nbl(kc,nimax,nr,S_min_post) #corta en mas artes para tener mediads de conec + + nbl=kc.shape[0]//sx + + + if keep_aspect=='yes': + keep_aspect=True + else: + keep_aspect=False + + t0=time.time() + kc=np.where(kc==kh,1,0).astype(int) + tcmaps=time.time() + kc=get_smallCmap(kc,nbl,rundir,keep_aspect) + tcmaps=time.time()-tcmaps + + kc,PostConTime=join(kc,nbl,keep_aspect,rundir,S_min_post,gcon) + + ttotal=time.time()-t0 + + summary = np.array([nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal]) + np.savetxt(rundir + 'ConnSummary.txt',summary,header='nbl,ttotal,tcmaps/ttotal,PostConTime/ttotal') + np.save(rundir+'Cmap.npy',kc) + return + + +def get_min_nbl(kc,nimax,nr,smin): + + if kc.shape[2]==1: + dim=2.0 + else: + dim=3.0 + + if nr>0: + y=(1/dim)*np.log2(nr*kc.size/(nimax*(smin**dim))) + else: + y=0 + y=int(y) + s=int((2**y) * smin) + if s connec.out 2>&1') #subprocess.call(['./tools/connec/'+execCon],cwd=rundir) #, '>/dev/null' , cwd=rundir + os.chdir(wd) + vec=np.loadtxt(rundir+params[-1]).reshape(vec.shape[0],vec.shape[1],vec.shape[2]).astype(int) + return vec + +def ConConfig(sx,sy,sz,Nz,rundir): + + params=[] + if Nz==1: + params=['1','4','vecconec.txt',str(sx)+' '+str(sy),'1.0 1.0','pardol.CCO'] + execCon='conec2d' + + else: + params=['1','6','vecconec.txt',str(sx)+' '+str(sy)+' ' +str(sz),'1.0 1.0 1.0','pardol.CCO'] + execCon='conec3d' + + + with open(rundir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + + return params, execCon + +def join(vec,nbl,keep_aspect,datadir,S_min_post,gcon): + + Nx, Ny,Nz=vec.shape[0],vec.shape[1],vec.shape[2] + sx = Nx//nbl + + if keep_aspect: + sy,sz = Ny//nbl,Nz//nbl + nblx, nbly,nblz = nbl, nbl, nbl + else: + sy,sz = sx,sx + nblx=nbl + nbly, nblz = Ny//sy, Nz//sz + + ex=np.log2(Nx) + esx=np.log2(sx) + join_z=True + join_y=True + if Nz==1: + sz=1 + nblz=1 + + + post_time=0 + sxL=[sx] + for bs in range(0,int(ex-esx)): + + + if vec.shape[0]==vec.shape[1] and sx>=S_min_post: + t0=time.time() + ConnecInd(vec,[sx],datadir) + post_time=time.time()-t0 + sx,sy,sz = 2*sx,2*sy,2*sz + sxL+=[sx] + + if sz > Nz: + sz=Nz + nblz=1 + join_z=False + if sy > Ny: + sy=Ny + nbly=1 + join_y=False + + nblx,nbly,nblz = Nx//sx, Ny//sy, Nz//sz + + for i in range(nblx): + for j in range(nbly): + for k in range(nblz): + vec[i*sx:(i+1)*sx,j*sy:(j+1)*sy,k*sz:(k+1)*sz]=joinBox(vec[i*sx:(i+1)*sx,j*sy:(j+1)*sy,k*sz:(k+1)*sz],join_y,join_z) + + if vec.shape[0]==vec.shape[1] and sx>=S_min_post: # + t0=time.time() + ConnecInd(vec,[sx],datadir) + post_time=post_time+(time.time()-t0) + if gcon: + ConnecInd(vec,sxL,datadir+'Global') + return vec, post_time + diff --git a/tools/connec/comp_cmap.pyc b/tools/connec/comp_cmap.pyc new file mode 100644 index 0000000..42d8dab Binary files /dev/null and b/tools/connec/comp_cmap.pyc differ diff --git a/tools/connec/connec-src/CONNEC2D.FOR b/tools/connec/connec-src/CONNEC2D.FOR new file mode 100644 index 0000000..e0363b9 --- /dev/null +++ b/tools/connec/connec-src/CONNEC2D.FOR @@ -0,0 +1,425 @@ +C CONNEC2D.FOR VER.21-FEB-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 2D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 4 FOR 4-CONNECTIVITY AND 8 FOR 8-CONNECTIVITY +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY : NUMBER OF POINTS IN X AND Y +C DX DY : GRID DIMENSIONS IN X AND Y +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C +C IND(I,J) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG NE-SW DIRECTION. +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG NW-SE DIRECTION. +C CCFU(.,5): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,6): MEAN CONNECTIVITY FUNCTION ALONG THE DIAGONALS. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(4096,4096) +C,NPX(256),NPY(256),NPCX(256),NPCY(256) +C DIMENSION NPE(256),NPW(256),NPCE(256),NPCW(256),CCFU(256,6) +C + CHARACTER*12 CPAR,CINP,COU2 +C +C MATRIX DIMENSION LIMITATION +C + NXM=4096 + NYM=4096 +C + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.4.AND.ICON.NE.8) THEN + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 4 OR A 8' + WRITE (6,*)'4 MEANS 4-CONNECTIVITY' + WRITE (6,*)'8 MEANS 8-CONNECTIVITY' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY + READ (1,*) DX,DY + READ (1,100) COU2 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'MAXIMUM NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'MAXIMUM NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 2D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + READ (1,*) VAL + IND(I,J)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).NE.1.AND.IND(I,J).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).EQ.1) JPHA=JPHA+1 +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.4) WRITE (6,*)'4-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.8) WRITE (6,*)'8-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + IF (IND(I,J).EQ.1) THEN + IAI=I + IAJ=J + GOTO 8 + END IF +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + IF (IND(I,J).NE.0) IND(I,J)=IND(I,J)-1 +51 CONTINUE +50 CONTINUE +C + +C +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) +C OPEN (2,FILE=CINP) +C + DO 15 I=1,NX + DO 16 J=1,NY +C READ (2,*) ZVA + WRITE (1,*) IND(I,J) +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION') +321 FORMAT (/1X,'ALONG THE NE-SW DIRECTION') +322 FORMAT (/1X,'ALONG THE NW-SE DIRECTION') +323 FORMAT (/1X,'AVERAGE ALONG THE DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +400 FORMAT (25(/),1X,'CONNEC2D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/CONNEC3D.FOR b/tools/connec/connec-src/CONNEC3D.FOR new file mode 100644 index 0000000..ed5092b --- /dev/null +++ b/tools/connec/connec-src/CONNEC3D.FOR @@ -0,0 +1,854 @@ +C CONNEC3D.FOR VER.11-NOV-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 3D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 6, 18 OR 26-CONNECTIVITY. +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY NZ : NUMBER OF POINTS IN X AND Y +C DX DY DZ : GRID DIMENSIONS IN X AND Y +C N2 : NUMBER OF LAGS FOR CONNECTIVITY FUNCTION CALCULATION +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY,DZ ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C NZ : NUMBER OF POINTS ALONG THE Z DIRECTION +C +C IND(I,J,L) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPZ(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Z DIRECTION AND THAT BELONG TO FACIES 1. +C NPCZ(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C RZME : MEAN LENGTH ALONG THE Z DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C IZMA : MAXIMUM LENGTH ALONG Z. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IZMI : MINIMUM LENGTH ALONG Z. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C IPZ : NUMBER OF PERCOLATING COMPONENTS ALONG Z. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG Z (VERTICAL). +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG 3D FIRST DIAGONAL. +C CCFU(.,5): CONNECTIVITY FUNCTION ALONG 3D SECOND DIAGONAL. +C CCFU(.,6): CONNECTIVITY FUNCTION ALONG 3D THIRD DIAGONAL. +C CCFU(.,7): CONNECTIVITY FUNCTION ALONG 3D FOURTH DIAGONAL. +C CCFU(.,8): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,9): MEAN CONNECTIVITY FUNCTION ALONG X,Y,Z. +C CCFU(.,10): MEAN CONNECTIVITY FUNCTION ALONG THE 3D DIAGONALS. +C CCFU(.,11): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Y PLANE. +C CCFU(.,12): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Y PLANE. +C CCFU(.,13): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Z PLANE. +C CCFU(.,14): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Z PLANE. +C CCFU(.,15): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL Y-Z PLANE. +C CCFU(.,16): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL Y-Z PLANE. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(512,512,512) + + +C,NPX(256),NPY(256),NPCX(256),NPCY(256) +C DIMENSION NPZ(256),NPCZ(256),NP1(256),NP2(256),NP3(256) +C DIMENSION NP4(256) +C,NPC1(256),NPC2(256),NPC3(256),NPC4(256) +C DIMENSION CCFU(256,16) +C DIMENSION NXY1(256),NXY2(256),NXZ1(256),NXZ2(256) +C DIMENSION NYZ1(256),NYZ2(256),NCXY1(256),NCXY2(256) +C DIMENSION NCXZ1(256),NCXZ2(256),NCYZ1(256),NCYZ2(256) +C + CHARACTER*12 CPAR,CINP,COU2 +C +C MATRIX DIMENSION LIMITATION +C + NXM=256 + NYM=NXM + NZM=NXM +C + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.6.AND.ICON.NE.18.AND.ICON.NE.26) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE 6, 18 OR 26' + WRITE (6,*)'6 MEANS 6-CONNECTIVITY (FACE CONNECTIVITY)' + WRITE (6,*)'18 MEANS 18-CONNECTIVITY (FACE+EDGE CONNECTIVITY)' + WRITE (6,*)'26 MEANS 26-CONNECTIVITY (FACE+EDGE+VERTEX CONN.)' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY,NZ + READ (1,*) DX,DY,DZ + READ (1,100) COU2 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF + IF (NZ.GT.NZM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NZ IS ',NZM + WRITE (6,*)'ACTUAL VALUE IS ',NZ + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 3D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + DO 3 L=1,NZ + READ (1,*) VAL + IND(I,J,L)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).NE.1.AND.IND(I,J,L).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J,L) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).EQ.1) JPHA=JPHA+1 +3 CONTINUE +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY*NZ + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.6) WRITE (6,*)'6-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.18) WRITE (6,*)'18-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.26) WRITE (6,*)'26-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + DO 67 L=1,NZ + IF (IND(I,J,L).EQ.1) THEN + IAI=I + IAJ=J + IAL=L + GOTO 8 + END IF +67 CONTINUE +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 + WRITE (6,*)'NCC : ',NCC +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ,IAL)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + DO 68 L=IAL,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +68 CONTINUE +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + DO 69 L=IAL,1,-1 +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +69 CONTINUE +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + DO 70 L=1,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +70 CONTINUE +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J,L)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + DO 71 L=1,NZ + IF (IND(I,J,L).NE.0) IND(I,J,L)=IND(I,J,L)-1 +71 CONTINUE +51 CONTINUE +50 CONTINUE +C + +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) +C + DO 15 I=1,NX + DO 16 J=1,NY + DO 85 L=1,NZ + WRITE (1,*) IND(I,J,L) +85 CONTINUE +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +131 FORMAT (1X,'NZ : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +151 FORMAT (1X,'DZ : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +241 FORMAT (1X,'MEAN LENGTH ALONG Z (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +251 FORMAT (1X,'MIMIMUN LENGTH ALONG Z (IN PIXELS) : ',I6) +261 FORMAT (1X,'MAXIMUM LENGTH ALONG Z (IN PIXELS) : ',I6) + +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +281 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Z : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION (1,0,0)') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION (0,1,0)') +321 FORMAT (/1X,'ALONG THE Z DIRECTION (0,0,1)') +322 FORMAT (/1X,'ALONG THE FIRST 3D DIAGONAL (1,1,1)') +323 FORMAT (/1X,'ALONG THE SECOND 3D DIAGONAL (1,-1,1)') +324 FORMAT (/1X,'ALONG THE THIRD 3D DIAGONAL (-1,-1,1)') +325 FORMAT (/1X,'ALONG THE FOURTH 3D DIAGONAL (-1,1,1)') +327 FORMAT (/1X,'AVERAGE ALONG THE 3D DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +328 FORMAT (/1X,'AVERAGE ALONG X, Y AND Z') +329 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Y PLANE (1,1,0)') +331 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Y PLANE (1,-1,0') +332 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Z PLANE (1,0,1)') +333 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Z PLANE (1,0,-1)') +334 FORMAT (/1X,'FIRST DIAGONAL ON THE Y-Z PLANE (0,1,1)') +335 FORMAT (/1X,'SECOND DIAGONAL ON THE Y-Z PLANE (0,1,-1)') +400 FORMAT (25(/),1X,'CONNEC3D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'6-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'18-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +450 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'26-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/makefile b/tools/connec/connec-src/makefile new file mode 100755 index 0000000..14450d8 --- /dev/null +++ b/tools/connec/connec-src/makefile @@ -0,0 +1,9 @@ +F90:= gfortran +all: conec2d conec3d +conec2d: CONNEC2D.FOR + $(F90) -O3 -o conec2d CONNEC2D.FOR +conec3d: CONNEC3D.FOR + $(F90) -O3 -o conec3d CONNEC3D.FOR +clean: + -rm -f conec2d conec3d + diff --git a/tools/connec/connec-src/simpConnec/CONFIG_FILE.txt b/tools/connec/connec-src/simpConnec/CONFIG_FILE.txt new file mode 100755 index 0000000..9087854 --- /dev/null +++ b/tools/connec/connec-src/simpConnec/CONFIG_FILE.txt @@ -0,0 +1,21 @@ + +def ConConfig(sx,sy,sz,Nz,rundir): + + params=[] + if Nz==1: + params=['1','4','vecconec.txt',str(sx)+' '+str(sy),'1.0 1.0','pardol.CCO'] + execCon='conec2d' + + else: + params=['1','6','vecconec.txt',str(sx)+' '+str(sy)+' ' +str(sz),'1.0 1.0 1.0','pardol.CCO'] + execCon='conec3d' + + + with open(rundir+'coninput.txt', 'w') as f: + for item in params: + f.write("%s\n" % item) + + return params, execCon + + +Solamente calcula y devuelve el mapa de conectividad!! diff --git a/tools/connec/connec-src/simpConnec/CONNEC2D.FOR b/tools/connec/connec-src/simpConnec/CONNEC2D.FOR new file mode 100644 index 0000000..e0363b9 --- /dev/null +++ b/tools/connec/connec-src/simpConnec/CONNEC2D.FOR @@ -0,0 +1,425 @@ +C CONNEC2D.FOR VER.21-FEB-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 2D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 4 FOR 4-CONNECTIVITY AND 8 FOR 8-CONNECTIVITY +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY : NUMBER OF POINTS IN X AND Y +C DX DY : GRID DIMENSIONS IN X AND Y +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C +C IND(I,J) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG NE-SW DIRECTION. +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG NW-SE DIRECTION. +C CCFU(.,5): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,6): MEAN CONNECTIVITY FUNCTION ALONG THE DIAGONALS. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(4096,4096) +C,NPX(256),NPY(256),NPCX(256),NPCY(256) +C DIMENSION NPE(256),NPW(256),NPCE(256),NPCW(256),CCFU(256,6) +C + CHARACTER*12 CPAR,CINP,COU2 +C +C MATRIX DIMENSION LIMITATION +C + NXM=4096 + NYM=4096 +C + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.4.AND.ICON.NE.8) THEN + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 4 OR A 8' + WRITE (6,*)'4 MEANS 4-CONNECTIVITY' + WRITE (6,*)'8 MEANS 8-CONNECTIVITY' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY + READ (1,*) DX,DY + READ (1,100) COU2 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'MAXIMUM NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'MAXIMUM NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 2D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + READ (1,*) VAL + IND(I,J)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).NE.1.AND.IND(I,J).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).EQ.1) JPHA=JPHA+1 +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.4) WRITE (6,*)'4-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.8) WRITE (6,*)'8-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + IF (IND(I,J).EQ.1) THEN + IAI=I + IAJ=J + GOTO 8 + END IF +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + IF (IND(I,J).NE.0) IND(I,J)=IND(I,J)-1 +51 CONTINUE +50 CONTINUE +C + +C +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) +C OPEN (2,FILE=CINP) +C + DO 15 I=1,NX + DO 16 J=1,NY +C READ (2,*) ZVA + WRITE (1,*) IND(I,J) +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION') +321 FORMAT (/1X,'ALONG THE NE-SW DIRECTION') +322 FORMAT (/1X,'ALONG THE NW-SE DIRECTION') +323 FORMAT (/1X,'AVERAGE ALONG THE DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +400 FORMAT (25(/),1X,'CONNEC2D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/simpConnec/CONNEC3D.FOR b/tools/connec/connec-src/simpConnec/CONNEC3D.FOR new file mode 100644 index 0000000..ed5092b --- /dev/null +++ b/tools/connec/connec-src/simpConnec/CONNEC3D.FOR @@ -0,0 +1,854 @@ +C CONNEC3D.FOR VER.11-NOV-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 3D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 6, 18 OR 26-CONNECTIVITY. +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY NZ : NUMBER OF POINTS IN X AND Y +C DX DY DZ : GRID DIMENSIONS IN X AND Y +C N2 : NUMBER OF LAGS FOR CONNECTIVITY FUNCTION CALCULATION +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY,DZ ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C NZ : NUMBER OF POINTS ALONG THE Z DIRECTION +C +C IND(I,J,L) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPZ(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Z DIRECTION AND THAT BELONG TO FACIES 1. +C NPCZ(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C RZME : MEAN LENGTH ALONG THE Z DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C IZMA : MAXIMUM LENGTH ALONG Z. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IZMI : MINIMUM LENGTH ALONG Z. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C IPZ : NUMBER OF PERCOLATING COMPONENTS ALONG Z. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG Z (VERTICAL). +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG 3D FIRST DIAGONAL. +C CCFU(.,5): CONNECTIVITY FUNCTION ALONG 3D SECOND DIAGONAL. +C CCFU(.,6): CONNECTIVITY FUNCTION ALONG 3D THIRD DIAGONAL. +C CCFU(.,7): CONNECTIVITY FUNCTION ALONG 3D FOURTH DIAGONAL. +C CCFU(.,8): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,9): MEAN CONNECTIVITY FUNCTION ALONG X,Y,Z. +C CCFU(.,10): MEAN CONNECTIVITY FUNCTION ALONG THE 3D DIAGONALS. +C CCFU(.,11): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Y PLANE. +C CCFU(.,12): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Y PLANE. +C CCFU(.,13): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Z PLANE. +C CCFU(.,14): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Z PLANE. +C CCFU(.,15): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL Y-Z PLANE. +C CCFU(.,16): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL Y-Z PLANE. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(512,512,512) + + +C,NPX(256),NPY(256),NPCX(256),NPCY(256) +C DIMENSION NPZ(256),NPCZ(256),NP1(256),NP2(256),NP3(256) +C DIMENSION NP4(256) +C,NPC1(256),NPC2(256),NPC3(256),NPC4(256) +C DIMENSION CCFU(256,16) +C DIMENSION NXY1(256),NXY2(256),NXZ1(256),NXZ2(256) +C DIMENSION NYZ1(256),NYZ2(256),NCXY1(256),NCXY2(256) +C DIMENSION NCXZ1(256),NCXZ2(256),NCYZ1(256),NCYZ2(256) +C + CHARACTER*12 CPAR,CINP,COU2 +C +C MATRIX DIMENSION LIMITATION +C + NXM=256 + NYM=NXM + NZM=NXM +C + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.6.AND.ICON.NE.18.AND.ICON.NE.26) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE 6, 18 OR 26' + WRITE (6,*)'6 MEANS 6-CONNECTIVITY (FACE CONNECTIVITY)' + WRITE (6,*)'18 MEANS 18-CONNECTIVITY (FACE+EDGE CONNECTIVITY)' + WRITE (6,*)'26 MEANS 26-CONNECTIVITY (FACE+EDGE+VERTEX CONN.)' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY,NZ + READ (1,*) DX,DY,DZ + READ (1,100) COU2 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF + IF (NZ.GT.NZM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NZ IS ',NZM + WRITE (6,*)'ACTUAL VALUE IS ',NZ + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 3D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + DO 3 L=1,NZ + READ (1,*) VAL + IND(I,J,L)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).NE.1.AND.IND(I,J,L).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J,L) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).EQ.1) JPHA=JPHA+1 +3 CONTINUE +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY*NZ + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.6) WRITE (6,*)'6-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.18) WRITE (6,*)'18-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.26) WRITE (6,*)'26-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + DO 67 L=1,NZ + IF (IND(I,J,L).EQ.1) THEN + IAI=I + IAJ=J + IAL=L + GOTO 8 + END IF +67 CONTINUE +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 + WRITE (6,*)'NCC : ',NCC +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ,IAL)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + DO 68 L=IAL,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +68 CONTINUE +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + DO 69 L=IAL,1,-1 +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +69 CONTINUE +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + DO 70 L=1,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +70 CONTINUE +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J,L)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + DO 71 L=1,NZ + IF (IND(I,J,L).NE.0) IND(I,J,L)=IND(I,J,L)-1 +71 CONTINUE +51 CONTINUE +50 CONTINUE +C + +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) +C + DO 15 I=1,NX + DO 16 J=1,NY + DO 85 L=1,NZ + WRITE (1,*) IND(I,J,L) +85 CONTINUE +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +131 FORMAT (1X,'NZ : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +151 FORMAT (1X,'DZ : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +241 FORMAT (1X,'MEAN LENGTH ALONG Z (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +251 FORMAT (1X,'MIMIMUN LENGTH ALONG Z (IN PIXELS) : ',I6) +261 FORMAT (1X,'MAXIMUM LENGTH ALONG Z (IN PIXELS) : ',I6) + +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +281 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Z : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION (1,0,0)') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION (0,1,0)') +321 FORMAT (/1X,'ALONG THE Z DIRECTION (0,0,1)') +322 FORMAT (/1X,'ALONG THE FIRST 3D DIAGONAL (1,1,1)') +323 FORMAT (/1X,'ALONG THE SECOND 3D DIAGONAL (1,-1,1)') +324 FORMAT (/1X,'ALONG THE THIRD 3D DIAGONAL (-1,-1,1)') +325 FORMAT (/1X,'ALONG THE FOURTH 3D DIAGONAL (-1,1,1)') +327 FORMAT (/1X,'AVERAGE ALONG THE 3D DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +328 FORMAT (/1X,'AVERAGE ALONG X, Y AND Z') +329 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Y PLANE (1,1,0)') +331 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Y PLANE (1,-1,0') +332 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Z PLANE (1,0,1)') +333 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Z PLANE (1,0,-1)') +334 FORMAT (/1X,'FIRST DIAGONAL ON THE Y-Z PLANE (0,1,1)') +335 FORMAT (/1X,'SECOND DIAGONAL ON THE Y-Z PLANE (0,1,-1)') +400 FORMAT (25(/),1X,'CONNEC3D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'6-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'18-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +450 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'26-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/simpConnec/makefile b/tools/connec/connec-src/simpConnec/makefile new file mode 100755 index 0000000..14450d8 --- /dev/null +++ b/tools/connec/connec-src/simpConnec/makefile @@ -0,0 +1,9 @@ +F90:= gfortran +all: conec2d conec3d +conec2d: CONNEC2D.FOR + $(F90) -O3 -o conec2d CONNEC2D.FOR +conec3d: CONNEC3D.FOR + $(F90) -O3 -o conec3d CONNEC3D.FOR +clean: + -rm -f conec2d conec3d + diff --git a/tools/connec/connec-src/ver_modificada/conec2d.FOR b/tools/connec/connec-src/ver_modificada/conec2d.FOR new file mode 100755 index 0000000..3e58c58 --- /dev/null +++ b/tools/connec/connec-src/ver_modificada/conec2d.FOR @@ -0,0 +1,1334 @@ +C $LARGE +C CONNEC3D.FOR VER.11-NOV-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 3D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 6, 18 OR 26-CONNECTIVITY. +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY NZ : NUMBER OF POINTS IN X AND Y +C DX DY DZ : GRID DIMENSIONS IN X AND Y +C N2 : NUMBER OF LAGS FOR CONNECTIVITY FUNCTION CALCULATION +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY,DZ ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C NZ : NUMBER OF POINTS ALONG THE Z DIRECTION +C +C IND(I,J,L) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPZ(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Z DIRECTION AND THAT BELONG TO FACIES 1. +C NPCZ(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C RZME : MEAN LENGTH ALONG THE Z DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (Of LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C IZMA : MAXIMUM LENGTH ALONG Z. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IZMI : MINIMUM LENGTH ALONG Z. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C IPZ : NUMBER OF PERCOLATING COMPONENTS ALONG Z. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG Z (VERTICAL). +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG 3D FIRST DIAGONAL. +C CCFU(.,5): CONNECTIVITY FUNCTION ALONG 3D SECOND DIAGONAL. +C CCFU(.,6): CONNECTIVITY FUNCTION ALONG 3D THIRD DIAGONAL. +C CCFU(.,7): CONNECTIVITY FUNCTION ALONG 3D FOURTH DIAGONAL. +C CCFU(.,8): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,9): MEAN CONNECTIVITY FUNCTION ALONG X,Y,Z. +C CCFU(.,10): MEAN CONNECTIVITY FUNCTION ALONG THE 3D DIAGONALS. +C CCFU(.,11): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Y PLANE. +C CCFU(.,12): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Y PLANE. +C CCFU(.,13): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Z PLANE. +C CCFU(.,14): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Z PLANE. +C CCFU(.,15): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL Y-Z PLANE. +C CCFU(.,16): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL Y-Z PLANE. +C +C +C ---------------------------------------------------------------- + DIMENSION IND(1,4096,4096),NPX(4096) + DIMENSION NPY(4096),NPCX(4096),NPCY(4096) + DIMENSION NPZ(4096),NPCZ(4096),NP1(4096) + DIMENSION NP2(4096),NP3(4096) + DIMENSION NP4(4096),NPC1(4096),NPC2(4096) + DIMENSION NPC3(4096),NPC4(4096) + DIMENSION CCFU(4096,16) + DIMENSION NXY1(4096),NXY2(4096) + DIMENSION NXZ1(4096),NXZ2(4096) + DIMENSION NYZ1(4096),NYZ2(4096) + DIMENSION NCXY1(4096),NCXY2(4096) + DIMENSION NCXZ1(4096),NCXZ2(4096) + DIMENSION NCYZ1(4096),NCYZ2(4096) +C + CHARACTER*12 CPAR,CINP,COUT,COU2,COU3,DATALE +C +C MATRIX DIMENSION LIMITATION (lo cambie) +C---------------------------------------------------------- + + NXM=1 + NYM=4096 + NZM=4096 +C ZINVERSAE=0.367879 + ZGAMMA=0.0 +C PARAMETER (INVERSAE=0.367879)----------------------------------------------- +C +C WRITE (6,400) aca cambie para que tome archivo entrada directo + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.6.AND.ICON.NE.18.AND.ICON.NE.26) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE 6, 18 OR 26' + WRITE (6,*)'6 MEANS 6-CONNECTIVITY (FACE CONNECTIVITY)' + WRITE (6,*)'18 MEANS 18-CONNECTIVITY (FACE+EDGE CONNECTIVITY)' + WRITE (6,*)'26 MEANS 26-CONNECTIVITY (FACE+EDGE+VERTEX CONN.)' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY,NZ + READ (1,*) DX,DY,DZ + READ (1,*) N2 + READ (1,100) COUT + READ (1,100) COU2 + READ (1,100) COU3 + READ (1,100) DATALE + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF + IF (NZ.GT.NZM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NZ IS ',NZM + WRITE (6,*)'ACTUAL VALUE IS ',NZ + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 3D FIELD +Ccambie el orden de los 3 DO----------------------------------------- + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 L=1,NZ + DO 2 J=1,NY + DO 3 I=1,NX + READ (1,*) VAL + IND(I,J,L)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).NE.1.AND.IND(I,J,L).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J,L) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).EQ.1) JPHA=JPHA+1 +3 CONTINUE +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY*NZ + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.6) WRITE (6,*)'6-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.18) WRITE (6,*)'18-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.26) WRITE (6,*)'26-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + DO 67 L=1,NZ + IF (IND(I,J,L).EQ.1) THEN + IAI=I + IAJ=J + IAL=L + GOTO 8 + END IF +67 CONTINUE +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 +C WRITE (6,*)'NCC : ',NCC-------------------------------------- +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ,IAL)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + DO 68 L=IAL,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +68 CONTINUE +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + DO 69 L=IAL,1,-1 +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +69 CONTINUE +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + DO 70 L=1,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +70 CONTINUE +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J,L)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + DO 71 L=1,NZ + IF (IND(I,J,L).NE.0) IND(I,J,L)=IND(I,J,L)-1 +71 CONTINUE +51 CONTINUE +50 CONTINUE +C +C STATISTICS ON CONNECTED COMPONENTS +C + ISME=0 + IXME=0 + IYME=0 + IZME=0 + ISMI=NX*NY*NZ + ISMA=1 + IXMI=NX + IXMA=1 + IYMI=NY + IYMA=1 + IZMI=NZ + IZMA=1 + IPX=0 + IPY=0 + IPZ=0 + WRITE (6,*) + WRITE (6,*)'NUMBER OF CONNECTED COMPONENTS: ',NCC + DO 14 III=1,NCC + IS=0 + IX1=NX + IY1=NY + IZ1=NZ + IX2=1 + IY2=1 + IZ2=1 + DO 11 I=1,NX + DO 12 J=1,NY + DO 72 L=1,NZ + IF (IND(I,J,L).EQ.III) THEN + IS=IS+1 + IF (I.LT.IX1) IX1=I + IF (I.GT.IX2) IX2=I + IF (J.LT.IY1) IY1=J + IF (J.GT.IY2) IY2=J + IF (L.LT.IZ1) IZ1=L + IF (L.GT.IZ2) IZ2=L + END IF +72 CONTINUE +12 CONTINUE +11 CONTINUE + + IXSI=IX2-IX1+1 + IYSI=IY2-IY1+1 + IZSI=IZ2-IZ1+1 + ISME=ISME+IS + IXME=IXME+IXSI + IYME=IYME+IYSI + IZME=IZME+IZSI + IF (IS.LT.ISMI) ISMI=IS + IF (IS.GT.ISMA) THEN + ISMA=IS + ICOM=III + END IF + + IF (IXSI.LT.IXMI) IXMI=IXSI + IF (IXSI.GT.IXMA) IXMA=IXSI + IF (IYSI.LT.IYMI) IYMI=IYSI + IF (IYSI.GT.IYMA) IYMA=IYSI + IF (IZSI.LT.IZMI) IZMI=IZSI + IF (IZSI.GT.IZMA) IZMA=IZSI + IF (IXSI.EQ.NX) IPX=IPX+1 + IF (IYSI.EQ.NY) IPY=IPY+1 + IF (IZSI.EQ.NZ) IPZ=IPZ+1 +C--------------------------armo la gamma renard, sumo los cuadrados de los elementos de cada cluster, fui dividiendo por np para no quil + ZTEMP=FLOAT(IS)/FLOAT(JPHA) + ZGAMMA=ZGAMMA+ZTEMP*ZTEMP +C WRITE (6,*)'ZGAMMA1 ',ZSUMA +C---------------------- +14 CONTINUE +C +C -----------------------------------------------------------OUTPUT 1 +C +C OPEN (1,FILE=COUT) +C IF (ICON.EQ.6) WRITE (1,430) CPAR +C IF (ICON.EQ.18) WRITE (1,440) CPAR +C IF (ICON.EQ.26) WRITE (1,450) CPAR +C WRITE (1,110) CINP +C WRITE (1,120) NX +C WRITE (1,130) NY +C WRITE (1,131) NZ +C WRITE (1,140) DX +C WRITE (1,150) DY +C WRITE (1,151) DZ +C WRITE (1,160) IPHA,PPHA +C WRITE (1,170) NCC + RSME=DX*DY*DZ*ISME/FLOAT(NCC) + RISM=FLOAT(ISME)/NCC + RTOT=RISM/JPHA +C WRITE (1,175) +C WRITE (1,180) RISM +C WRITE (1,190) RSME +C WRITE (1,200) IPHA,RTOT + RXME=FLOAT(IXME)/NCC + RYME=FLOAT(IYME)/NCC + RZME=FLOAT(IZME)/NCC +C WRITE (1,210) RXME +C WRITE (1,240) RYME +C WRITE (1,241) RZME +C WRITE (1,177) +C WRITE (1,235) ICOM +C WRITE (1,236) ISMA + RSIZ=FLOAT(ISMA)/JPHA + +C WRITE (1,237) IPHA,RSIZ +C WRITE (1,230) IXMA +C WRITE (1,260) IYMA +C WRITE (1,261) IZMA +C WRITE (1,176) +C WRITE (1,238) ISMI +C WRITE (1,220) IXMI +C WRITE (1,250) IYMI +C WRITE (1,251) IZMI +C WRITE (1,178) +C WRITE (1,270) IPX cuantos clusters percolan en x +C WRITE (1,280) IPY +C WRITE (1,281) IPZ +C WRITE (1,290) COU2 +C WRITE (1,295) COU3 +C +C CONNECTIVITY FUNCTION +C CALCULATED FOR N2 LAGS +C C NP4(I)=0 +C C NPCX(I)=0 +C C NPCY(I)=0 +C C NPCZ(I)=0 +C C NPC1(I)=0 +C C NPC2(I)=0 +C C NP +C C DO 595 I=1,N2 +C C NPX(I)=0 +C C NP Y(I)=0 +C C NPZ(I)=0 +C C NP1(I)=0 +C C NP2(I)=0 +C C NP3(I)=0 +C C3(I)=0 +C C NPC4(I)=0 +C 595 CONTINUE +C C DO 30 I=1,NX +C C DO 31 J=1,NY +C C DO 73 L=1,NZ +C C I1=IND(I,J,L) +C IF (I1.EQ.0) GOTO 73 +C DO 32 K=1,N2 +C +C ALONG X +C +C IF (I+K.LE.NX) THEN +C IF (IND(I+K,J,L).NE.0) THEN +C NPX(K)=NPX(K)+1 +C IF (I1.EQ.IND(I+K,J,L)) NPCX(K)=NPCX(K)+1 +C END IF +C END IF +C +C C ALONG Y +C C +C IF (J+K.LE.NY) THEN +C IF (IND(I,J+K,L).NE.0) THEN +C NPY(K)=NPY(K)+1 +C IF (I1.EQ.IND(I,J+K,L)) NPCY(K)=NPCY(K)+1 +C END IF +C END IF +C C +C C ALONG Z +C C +C IF (L+K.LE.NZ) THEN +C IF (IND(I,J,L+K).NE.0) THEN +C NPZ(K)=NPZ(K)+1 +C IF (I1.EQ.IND(I,J,L+K)) NPCZ(K)=NPCZ(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 1 (I+, J+, K+) +C C +C IF ((J+K.LE.NY).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J+K,L+K).NE.0) THEN +C NP1(K)=NP1(K)+1 +C IF (I1.EQ.IND(I+K,J+K,L+K)) NPC1(K)=NPC1(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 2 (I+, J-, K+) +C C +C IF ((J-K.GT.0).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J-K,L+K).NE.0) THEN +C NP2(K)=NP2(K)+1 +C IF (I1.EQ.IND(I+K,J-K,L+K)) NPC2(K)=NPC2(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 3 (I-, J-, K+) +C C +C IF ((J-K.GT.0).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN +C IF (IND(I-K,J-K,L+K).NE.0) THEN +C NP3(K)=NP3(K)+1 +C IF (I1.EQ.IND(I-K,J-K,L+K)) NPC3(K)=NPC3(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 4 (I-, J+, K+) +C C +C IF ((J+K.LE.NY).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN +C IF (IND(I-K,J+K,L+K).NE.0) THEN +C NP4(K)=NP4(K)+1 +C IF (I1.EQ.IND(I-K,J+K,L+K)) NPC4(K)=NPC4(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE X-Y +C C +C IF ((I+K.LE.NX).AND.(J+K.LE.NY)) THEN +C IF (IND(I+K,J+K,L).NE.0) THEN +C NXY1(K)=NXY1(K)+1 +C IF (I1.EQ.IND(I+K,J+K,L)) NCXY1(K)=NCXY1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE X-Y +C C +C IF ((I+K.LE.NX).AND.(J-K.GT.0)) THEN +C IF (IND(I+K,J-K,L).NE.0) THEN +C NXY2(K)=NXY2(K)+1 +C IF (I1.EQ.IND(I+K,J-K,L)) NCXY2(K)=NCXY2(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE X-Z +C C +C IF ((I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J,L+K).NE.0) THEN +C NXZ1(K)=NXZ1(K)+1 +C IF (I1.EQ.IND(I+K,J,L+K)) NCXZ1(K)=NCXZ1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE X-Z +C C +C IF ((I+K.LE.NX).AND.(L-K.GT.0)) THEN +C IF (IND(I+K,J,L-K).NE.0) THEN +C NXZ2(K)=NXZ2(K)+1 +C IF (I1.EQ.IND(I+K,J,L-K)) NCXZ2(K)=NCXZ2(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE Y-Z +C C +C IF ((J+K.LE.NY).AND.(L+K.LE.NZ)) THEN +C IF (IND(I,J+K,L+K).NE.0) THEN +C NYZ1(K)=NYZ1(K)+1 +C IF (I1.EQ.IND(I,J+K,L+K)) NCYZ1(K)=NCYZ1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE Y-Z +C C +C IF ((J+K.LE.NY).AND.(L-K.GT.0)) THEN +C IF (IND(I,J+K,L-K).NE.0) THEN +C NYZ2(K)=NYZ2(K)+1 +C IF (I1.EQ.IND(I,J+K,L-K)) NCYZ2(K)=NCYZ2(K)+1 +C END IF +C END IF +C32 CONTINUE +C73 CONTINUE +C31 CONTINUE +C30 CONTINUE +C aca calcula con func y la ----le saque toda la escritura al archivo de estadisticas y solo calcu 1 func conec +C WRITE (1,300) +C ZACUMCC=0.0 +C DO 33 I=1,N2 +C CCFU(I,1)=FLOAT(NPCX(I))/AMAX0(1,NPX(I)) +C ZACUMCC=ZACUMCC+CCFU(I,1) +C WRITE (1,310) I*DX,CCFU(I,1),NPCX(I),NPX(I)----------------------------------------------- +C33 CONTINUE +C WRITE (1,320) +C DO 34 I=1,N2 +C CCFU(I,2)=FLOAT(NPCY(I))/AMAX0(1,NPY(I)) +C WRITE (1,310) I*DY,CCFU(I,2),NPCY(I),NPY(I) +C34 CONTINUE +C WRITE (1,321) +C DO 36 I=1,N2 +C CCFU(I,3)=FLOAT(NPCZ(I))/AMAX0(1,NPZ(I)) +C WRITE (1,310) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +C36 CONTINUE + DXYZ=SQRT(DX*DX+DY*DY+DZ*DZ) + DXY=SQRT(DX*DX+DY*DY) + DXZ=SQRT(DX*DX+DZ*DZ) + DYZ=SQRT(DY*DY+DZ*DZ) +C WRITE (1,322) +C DO 37 I=1,N2 +C CCFU(I,4)=FLOAT(NPC1(I))/AMAX0(1,NP1(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +C37 CONTINUE +C WRITE (1,323) +C DO 81 I=1,N2 +C CCFU(I,5)=FLOAT(NPC2(I))/AMAX0(1,NP2(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +C81 CONTINUE +C WRITE (1,324) +C DO 82 I=1,N2 +C CCFU(I,6)=FLOAT(NPC3(I))/AMAX0(1,NP3(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +C82 CONTINUE +C WRITE (1,325) +C DO 83 I=1,N2 +C CCFU(I,7)=FLOAT(NPC4(I))/AMAX0(1,NP4(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +C83 CONTINUE +C WRITE (1,330) +C DO 35 I=1,N2 +C CCFU(I,8)=(NPCX(I)+NPCY(I))/AMAX0(1,(NPX(I)+NPY(I))) +C WRITE (1,310) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) +C * ,NPX(I)+NPY(I) +C35 CONTINUE +C WRITE (1,328) +C DO 84 I=1,N2 +C CCFU(I,9)=(NPCX(I)+NPCY(I)+NPCZ(I))/AMAX0(1,(NPX(I)+NPY(I) +C * +NPZ(I))) +C WRITE (1,310) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) +C * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +C84 CONTINUE +C WRITE (1,327) +C DO 38 I=1,N2 +C CCFU(I,10)=(NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I)) +C * /AMAX0(1,(NP1(I)+NP2(I)+NP3(I)+NP4(I))) +C WRITE(1,310) I*DXYZ,CCFU(I,10), +C * NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I),NP1(I)+NP2(I)+NP3(I)+NP4(I) +C38 CONTINUE +C WRITE (1,329) +C DO 91 I=1,N2 +C CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) +C WRITE (1,310) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +C91 CONTINUE +C WRITE (1,331) +C DO 92 I=1,N2 +C CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) +C WRITE (1,310) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +C92 CONTINUE +C WRITE (1,332) +C DO 93 I=1,N2 +C CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) +C WRITE (1,310) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +C93 CONTINUE +C WRITE (1,333) +C DO 94 I=1,N2 +C CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) +C WRITE (1,310) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +C94 CONTINUE +C WRITE (1,334) +C DO 95 I=1,N2 +C CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) +C WRITE (1,310) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +C95 CONTINUE +C WRITE (1,335) +C DO 96 I=1,N2 +C CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) +C WRITE (1,310) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +C96 CONTINUE +C CLOSE (1) +C --------------------aca abro archivo salida ------------------- +c-------------------------------------------volale + VOLALE=FLOAT(ISMA)/FLOAT(IARE) + ZINTCC=ZGAMMA*FLOAT(JPHA)/FLOAT(NX*NY*NZ) + ZNCC=FLOAT(NCC) + ZIPZ=FLOAT(IPZ) + OPEN (1,FILE=DATALE) +C DO 555 I=1,N2 +C WRITE (6,*) CCFU(I,1) +C IF (CCFU(I,1).LE.ZINVERSAE) THEN +C CONCAR=I + + WRITE (6,*) ZINTCC +C WRITE (6,*) ZACUMCC +C WRITE (6,*) VOLALE +C WRITE (6,*) ZGAMMA +C EXIT +C END IF +C555 CONTINUE + WRITE (1,500) ZINTCC, VOLALE, ZGAMMA, ZIPZ, ZNCC, PPHA +C WRITE (1,500) CONCAR, ZACUMCC, VOLALE, ZGAMMA, ZNCC, ZIPX, PPHA +C WRITE (1,'(F8.5)') CONCAR + CLOSE (1) +C --------------------aca CIERRO archivo salida ----------------- + + +C OUTPUT FILE WITH CONNECTED COMPONENTS +CC -----------------------------------------------------------OUTPUT 2 +C OPEN (1,FILE=COU2) +C +C DO 15 I=1,NX +C DO 16 J=1,NY +C DO 85 L=1,NZ +C WRITE (1,*) IND(I,J,L) +C85 CONTINUE +C16 CONTINUE +C15 CONTINUE +C +C CLOSE (1) +C--------------------------------------------------------------- + CLOSE (2) +C OPEN (1,FILE=COU3) +C DO 17 I=1,N2 +C WRITE (1,*) I*DX,CCFU(I,1),NPCX(I),NPX(I) +C17 CONTINUE +C WRITE (1,*) +C DO 18 I=1,N2 +C WRITE (1,*) I*DY,CCFU(I,2),NPCY(I),NPY(I) +C18 CONTINUE +C WRITE (1,*) +C DO 86 I=1,N2 +C WRITE (1,*) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +C86 CONTINUE +C WRITE (1,*) +C DO 19 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +C19 CONTINUE +C WRITE (1,*) +C DO 23 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +C23 CONTINUE +C WRITE (1,*) +C DO 87 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +C87 CONTINUE +C WRITE (1,*) +C DO 88 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +C88 CONTINUE +C WRITE (1,*) +C DO 21 I=1,N2 +C WRITE (1,*) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) +C * ,NPX(I)+NPY(I) +C21 CONTINUE +C WRITE (1,*) +C DO 89 I=1,N2 +C WRITE (1,*) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) +C * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +C89 CONTINUE +C WRITE (1,*) +C DO 22 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,10),NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I) +C * ,NP1(I)+NP2(I)+NP3(I)+NP4(I) +C22 CONTINUE +C WRITE (1,*) +C DO 111 I=1,N2 +C CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) +C WRITE (1,*) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +C111 CONTINUE +C WRITE (1,*) +C DO 112 I=1,N2 +C CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) +C WRITE (1,*) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +C112 CONTINUE +C WRITE (1,*) +C DO 113 I=1,N2 +C CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) +C WRITE (1,*) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +C113 CONTINUE +C WRITE (1,*) +C DO 114 I=1,N2 +C CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) +C WRITE (1,*) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +C114 CONTINUE +C WRITE (1,*) +C DO 115 I=1,N2 +C CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) +C WRITE (1,*) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +C115 CONTINUE +C WRITE (1,*) +C DO 116 I=1,N2 +C CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) +C WRITE (1,*) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +C116 CONTINUE +C CLOSE (1) +C---------------------------------------------------------------- +C WRITE (6,410) COUT +C WRITE (6,420) COU2 +C WRITE (6,425) COU3 + STOP +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +131 FORMAT (1X,'NZ : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +151 FORMAT (1X,'DZ : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +241 FORMAT (1X,'MEAN LENGTH ALONG Z (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +251 FORMAT (1X,'MIMIMUN LENGTH ALONG Z (IN PIXELS) : ',I6) +261 FORMAT (1X,'MAXIMUM LENGTH ALONG Z (IN PIXELS) : ',I6) + +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +281 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Z : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION (1,0,0)') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION (0,1,0)') +321 FORMAT (/1X,'ALONG THE Z DIRECTION (0,0,1)') +322 FORMAT (/1X,'ALONG THE FIRST 3D DIAGONAL (1,1,1)') +323 FORMAT (/1X,'ALONG THE SECOND 3D DIAGONAL (1,-1,1)') +324 FORMAT (/1X,'ALONG THE THIRD 3D DIAGONAL (-1,-1,1)') +325 FORMAT (/1X,'ALONG THE FOURTH 3D DIAGONAL (-1,1,1)') +327 FORMAT (/1X,'AVERAGE ALONG THE 3D DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +328 FORMAT (/1X,'AVERAGE ALONG X, Y AND Z') +329 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Y PLANE (1,1,0)') +331 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Y PLANE (1,-1,0') +332 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Z PLANE (1,0,1)') +333 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Z PLANE (1,0,-1)') +334 FORMAT (/1X,'FIRST DIAGONAL ON THE Y-Z PLANE (0,1,1)') +335 FORMAT (/1X,'SECOND DIAGONAL ON THE Y-Z PLANE (0,1,-1)') +400 FORMAT (25(/),1X,'CONNEC3D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'6-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'18-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +450 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'26-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +C-----agregue este format concar (cuando cae abajo 1/e), zacum (integral cc),volale (vol largest cluster / vol tot),gamma,ppha +C- WRITE (1,500) CONCAR, VOLALE, ZGAMMA, ZIPZ, ZNCC, PPHA +500 FORMAT (1X,F8.7,' ',F8.7,' ',F8.7,' ',F8.2,' ',F8.2,' ',F8.5) +C500 FORMAT (1X,F8.2,' ',F8.5,' ',F8.5,' ',F8.7,' ',F8.2,' ',F8.5) + END diff --git a/tools/connec/connec-src/ver_modificada/conec3d.FOR b/tools/connec/connec-src/ver_modificada/conec3d.FOR new file mode 100755 index 0000000..bc21e96 --- /dev/null +++ b/tools/connec/connec-src/ver_modificada/conec3d.FOR @@ -0,0 +1,1329 @@ +C $LARGE +C CONNEC3D.FOR VER.11-NOV-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 3D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 6, 18 OR 26-CONNECTIVITY. +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY NZ : NUMBER OF POINTS IN X AND Y +C DX DY DZ : GRID DIMENSIONS IN X AND Y +C N2 : NUMBER OF LAGS FOR CONNECTIVITY FUNCTION CALCULATION +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY,DZ ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C NZ : NUMBER OF POINTS ALONG THE Z DIRECTION +C +C IND(I,J,L) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPZ(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Z DIRECTION AND THAT BELONG TO FACIES 1. +C NPCZ(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C RZME : MEAN LENGTH ALONG THE Z DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (Of LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C IZMA : MAXIMUM LENGTH ALONG Z. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IZMI : MINIMUM LENGTH ALONG Z. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C IPZ : NUMBER OF PERCOLATING COMPONENTS ALONG Z. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG Z (VERTICAL). +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG 3D FIRST DIAGONAL. +C CCFU(.,5): CONNECTIVITY FUNCTION ALONG 3D SECOND DIAGONAL. +C CCFU(.,6): CONNECTIVITY FUNCTION ALONG 3D THIRD DIAGONAL. +C CCFU(.,7): CONNECTIVITY FUNCTION ALONG 3D FOURTH DIAGONAL. +C CCFU(.,8): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,9): MEAN CONNECTIVITY FUNCTION ALONG X,Y,Z. +C CCFU(.,10): MEAN CONNECTIVITY FUNCTION ALONG THE 3D DIAGONALS. +C CCFU(.,11): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Y PLANE. +C CCFU(.,12): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Y PLANE. +C CCFU(.,13): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Z PLANE. +C CCFU(.,14): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Z PLANE. +C CCFU(.,15): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL Y-Z PLANE. +C CCFU(.,16): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL Y-Z PLANE. +C +C +C ---------------------------------------------------------------- +C ( cambie ind) + DIMENSION IND(64,64,64),NPX(256),NPY(256),NPCX(256),NPCY(256) + DIMENSION NPZ(256),NPCZ(256),NP1(256),NP2(256),NP3(256) + DIMENSION NP4(256),NPC1(256),NPC2(256),NPC3(256),NPC4(256) + DIMENSION CCFU(256,16) + DIMENSION NXY1(256),NXY2(256),NXZ1(256),NXZ2(256) + DIMENSION NYZ1(256),NYZ2(256),NCXY1(256),NCXY2(256) + DIMENSION NCXZ1(256),NCXZ2(256),NCYZ1(256),NCYZ2(256) +C + CHARACTER*12 CPAR,CINP,COUT,COU2,COU3,DATALE +C +C MATRIX DIMENSION LIMITATION (lo cambie) +C---------------------------------------------------------- + + NXM=101 + NYM=101 + NZM=101 +C ZINVERSAE=0.367879 + ZGAMMA=0.0 +C PARAMETER (INVERSAE=0.367879)----------------------------------------------- +C +C WRITE (6,400) aca cambie para que tome archivo entrada directo + CPAR="coninput.txt" + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.6.AND.ICON.NE.18.AND.ICON.NE.26) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE 6, 18 OR 26' + WRITE (6,*)'6 MEANS 6-CONNECTIVITY (FACE CONNECTIVITY)' + WRITE (6,*)'18 MEANS 18-CONNECTIVITY (FACE+EDGE CONNECTIVITY)' + WRITE (6,*)'26 MEANS 26-CONNECTIVITY (FACE+EDGE+VERTEX CONN.)' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY,NZ + READ (1,*) DX,DY,DZ + READ (1,*) N2 + READ (1,100) COUT + READ (1,100) COU2 + READ (1,100) COU3 + READ (1,100) DATALE + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF + IF (NZ.GT.NZM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NZ IS ',NZM + WRITE (6,*)'ACTUAL VALUE IS ',NZ + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 3D FIELD +Ccambie el orden de los 3 DO----------------------------------------- + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 L=1,NZ + DO 2 J=1,NY + DO 3 I=1,NX + READ (1,*) VAL + IND(I,J,L)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).NE.1.AND.IND(I,J,L).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J,L) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).EQ.1) JPHA=JPHA+1 +3 CONTINUE +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY*NZ + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.6) WRITE (6,*)'6-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.18) WRITE (6,*)'18-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.26) WRITE (6,*)'26-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + DO 67 L=1,NZ + IF (IND(I,J,L).EQ.1) THEN + IAI=I + IAJ=J + IAL=L + GOTO 8 + END IF +67 CONTINUE +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 +C WRITE (6,*)'NCC : ',NCC-------------------------------------- +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ,IAL)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + DO 68 L=IAL,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +68 CONTINUE +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + DO 69 L=IAL,1,-1 +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +69 CONTINUE +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + DO 70 L=1,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +70 CONTINUE +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J,L)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + DO 71 L=1,NZ + IF (IND(I,J,L).NE.0) IND(I,J,L)=IND(I,J,L)-1 +71 CONTINUE +51 CONTINUE +50 CONTINUE +C +C STATISTICS ON CONNECTED COMPONENTS +C + ISME=0 + IXME=0 + IYME=0 + IZME=0 + ISMI=NX*NY*NZ + ISMA=1 + IXMI=NX + IXMA=1 + IYMI=NY + IYMA=1 + IZMI=NZ + IZMA=1 + IPX=0 + IPY=0 + IPZ=0 + WRITE (6,*) + WRITE (6,*)'NUMBER OF CONNECTED COMPONENTS: ',NCC + DO 14 III=1,NCC + IS=0 + IX1=NX + IY1=NY + IZ1=NZ + IX2=1 + IY2=1 + IZ2=1 + DO 11 I=1,NX + DO 12 J=1,NY + DO 72 L=1,NZ + IF (IND(I,J,L).EQ.III) THEN + IS=IS+1 + IF (I.LT.IX1) IX1=I + IF (I.GT.IX2) IX2=I + IF (J.LT.IY1) IY1=J + IF (J.GT.IY2) IY2=J + IF (L.LT.IZ1) IZ1=L + IF (L.GT.IZ2) IZ2=L + END IF +72 CONTINUE +12 CONTINUE +11 CONTINUE + + IXSI=IX2-IX1+1 + IYSI=IY2-IY1+1 + IZSI=IZ2-IZ1+1 + ISME=ISME+IS + IXME=IXME+IXSI + IYME=IYME+IYSI + IZME=IZME+IZSI + IF (IS.LT.ISMI) ISMI=IS + IF (IS.GT.ISMA) THEN + ISMA=IS + ICOM=III + END IF + + IF (IXSI.LT.IXMI) IXMI=IXSI + IF (IXSI.GT.IXMA) IXMA=IXSI + IF (IYSI.LT.IYMI) IYMI=IYSI + IF (IYSI.GT.IYMA) IYMA=IYSI + IF (IZSI.LT.IZMI) IZMI=IZSI + IF (IZSI.GT.IZMA) IZMA=IZSI + IF (IXSI.EQ.NX) IPX=IPX+1 + IF (IYSI.EQ.NY) IPY=IPY+1 + IF (IZSI.EQ.NZ) IPZ=IPZ+1 +C--------------------------armo la gamma renard, sumo los cuadrados de los elementos de cada cluster, fui dividiendo por np para no quil + ZTEMP=FLOAT(IS)/FLOAT(JPHA) + ZGAMMA=ZGAMMA+ZTEMP*ZTEMP +C WRITE (6,*)'ZGAMMA1 ',ZSUMA +C---------------------- +14 CONTINUE +C +C -----------------------------------------------------------OUTPUT 1 +C +C OPEN (1,FILE=COUT) +C IF (ICON.EQ.6) WRITE (1,430) CPAR +C IF (ICON.EQ.18) WRITE (1,440) CPAR +C IF (ICON.EQ.26) WRITE (1,450) CPAR +C WRITE (1,110) CINP +C WRITE (1,120) NX +C WRITE (1,130) NY +C WRITE (1,131) NZ +C WRITE (1,140) DX +C WRITE (1,150) DY +C WRITE (1,151) DZ +C WRITE (1,160) IPHA,PPHA +C WRITE (1,170) NCC + RSME=DX*DY*DZ*ISME/FLOAT(NCC) + RISM=FLOAT(ISME)/NCC + RTOT=RISM/JPHA +C WRITE (1,175) +C WRITE (1,180) RISM +C WRITE (1,190) RSME +C WRITE (1,200) IPHA,RTOT + RXME=FLOAT(IXME)/NCC + RYME=FLOAT(IYME)/NCC + RZME=FLOAT(IZME)/NCC +C WRITE (1,210) RXME +C WRITE (1,240) RYME +C WRITE (1,241) RZME +C WRITE (1,177) +C WRITE (1,235) ICOM +C WRITE (1,236) ISMA + RSIZ=FLOAT(ISMA)/JPHA + +C WRITE (1,237) IPHA,RSIZ +C WRITE (1,230) IXMA +C WRITE (1,260) IYMA +C WRITE (1,261) IZMA +C WRITE (1,176) +C WRITE (1,238) ISMI +C WRITE (1,220) IXMI +C WRITE (1,250) IYMI +C WRITE (1,251) IZMI +C WRITE (1,178) +C WRITE (1,270) IPX cuantos clusters percolan en x +C WRITE (1,280) IPY +C WRITE (1,281) IPZ +C WRITE (1,290) COU2 +C WRITE (1,295) COU3 +C +C CONNECTIVITY FUNCTION +C CALCULATED FOR N2 LAGS +C C NP4(I)=0 +C C NPCX(I)=0 +C C NPCY(I)=0 +C C NPCZ(I)=0 +C C NPC1(I)=0 +C C NPC2(I)=0 +C C NP +C C DO 595 I=1,N2 +C C NPX(I)=0 +C C NP Y(I)=0 +C C NPZ(I)=0 +C C NP1(I)=0 +C C NP2(I)=0 +C C NP3(I)=0 +C C3(I)=0 +C C NPC4(I)=0 +C 595 CONTINUE +C C DO 30 I=1,NX +C C DO 31 J=1,NY +C C DO 73 L=1,NZ +C C I1=IND(I,J,L) +C IF (I1.EQ.0) GOTO 73 +C DO 32 K=1,N2 +C +C ALONG X +C +C IF (I+K.LE.NX) THEN +C IF (IND(I+K,J,L).NE.0) THEN +C NPX(K)=NPX(K)+1 +C IF (I1.EQ.IND(I+K,J,L)) NPCX(K)=NPCX(K)+1 +C END IF +C END IF +C +C C ALONG Y +C C +C IF (J+K.LE.NY) THEN +C IF (IND(I,J+K,L).NE.0) THEN +C NPY(K)=NPY(K)+1 +C IF (I1.EQ.IND(I,J+K,L)) NPCY(K)=NPCY(K)+1 +C END IF +C END IF +C C +C C ALONG Z +C C +C IF (L+K.LE.NZ) THEN +C IF (IND(I,J,L+K).NE.0) THEN +C NPZ(K)=NPZ(K)+1 +C IF (I1.EQ.IND(I,J,L+K)) NPCZ(K)=NPCZ(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 1 (I+, J+, K+) +C C +C IF ((J+K.LE.NY).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J+K,L+K).NE.0) THEN +C NP1(K)=NP1(K)+1 +C IF (I1.EQ.IND(I+K,J+K,L+K)) NPC1(K)=NPC1(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 2 (I+, J-, K+) +C C +C IF ((J-K.GT.0).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J-K,L+K).NE.0) THEN +C NP2(K)=NP2(K)+1 +C IF (I1.EQ.IND(I+K,J-K,L+K)) NPC2(K)=NPC2(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 3 (I-, J-, K+) +C C +C IF ((J-K.GT.0).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN +C IF (IND(I-K,J-K,L+K).NE.0) THEN +C NP3(K)=NP3(K)+1 +C IF (I1.EQ.IND(I-K,J-K,L+K)) NPC3(K)=NPC3(K)+1 +C END IF +C END IF +C C +C C ALONG 3D DIAGONAL 4 (I-, J+, K+) +C C +C IF ((J+K.LE.NY).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN +C IF (IND(I-K,J+K,L+K).NE.0) THEN +C NP4(K)=NP4(K)+1 +C IF (I1.EQ.IND(I-K,J+K,L+K)) NPC4(K)=NPC4(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE X-Y +C C +C IF ((I+K.LE.NX).AND.(J+K.LE.NY)) THEN +C IF (IND(I+K,J+K,L).NE.0) THEN +C NXY1(K)=NXY1(K)+1 +C IF (I1.EQ.IND(I+K,J+K,L)) NCXY1(K)=NCXY1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE X-Y +C C +C IF ((I+K.LE.NX).AND.(J-K.GT.0)) THEN +C IF (IND(I+K,J-K,L).NE.0) THEN +C NXY2(K)=NXY2(K)+1 +C IF (I1.EQ.IND(I+K,J-K,L)) NCXY2(K)=NCXY2(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE X-Z +C C +C IF ((I+K.LE.NX).AND.(L+K.LE.NZ)) THEN +C IF (IND(I+K,J,L+K).NE.0) THEN +C NXZ1(K)=NXZ1(K)+1 +C IF (I1.EQ.IND(I+K,J,L+K)) NCXZ1(K)=NCXZ1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE X-Z +C C +C IF ((I+K.LE.NX).AND.(L-K.GT.0)) THEN +C IF (IND(I+K,J,L-K).NE.0) THEN +C NXZ2(K)=NXZ2(K)+1 +C IF (I1.EQ.IND(I+K,J,L-K)) NCXZ2(K)=NCXZ2(K)+1 +C END IF +C END IF +C C +C C FIRST DIAGONAL IN THE PLANE Y-Z +C C +C IF ((J+K.LE.NY).AND.(L+K.LE.NZ)) THEN +C IF (IND(I,J+K,L+K).NE.0) THEN +C NYZ1(K)=NYZ1(K)+1 +C IF (I1.EQ.IND(I,J+K,L+K)) NCYZ1(K)=NCYZ1(K)+1 +C END IF +C END IF +C C +C C SECOND DIAGONAL IN THE PLANE Y-Z +C C +C IF ((J+K.LE.NY).AND.(L-K.GT.0)) THEN +C IF (IND(I,J+K,L-K).NE.0) THEN +C NYZ2(K)=NYZ2(K)+1 +C IF (I1.EQ.IND(I,J+K,L-K)) NCYZ2(K)=NCYZ2(K)+1 +C END IF +C END IF +C32 CONTINUE +C73 CONTINUE +C31 CONTINUE +C30 CONTINUE +C aca calcula con func y la ----le saque toda la escritura al archivo de estadisticas y solo calcu 1 func conec +C WRITE (1,300) +C ZACUMCC=0.0 +C DO 33 I=1,N2 +C CCFU(I,1)=FLOAT(NPCX(I))/AMAX0(1,NPX(I)) +C ZACUMCC=ZACUMCC+CCFU(I,1) +C WRITE (1,310) I*DX,CCFU(I,1),NPCX(I),NPX(I)----------------------------------------------- +C33 CONTINUE +C WRITE (1,320) +C DO 34 I=1,N2 +C CCFU(I,2)=FLOAT(NPCY(I))/AMAX0(1,NPY(I)) +C WRITE (1,310) I*DY,CCFU(I,2),NPCY(I),NPY(I) +C34 CONTINUE +C WRITE (1,321) +C DO 36 I=1,N2 +C CCFU(I,3)=FLOAT(NPCZ(I))/AMAX0(1,NPZ(I)) +C WRITE (1,310) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +C36 CONTINUE + DXYZ=SQRT(DX*DX+DY*DY+DZ*DZ) + DXY=SQRT(DX*DX+DY*DY) + DXZ=SQRT(DX*DX+DZ*DZ) + DYZ=SQRT(DY*DY+DZ*DZ) +C WRITE (1,322) +C DO 37 I=1,N2 +C CCFU(I,4)=FLOAT(NPC1(I))/AMAX0(1,NP1(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +C37 CONTINUE +C WRITE (1,323) +C DO 81 I=1,N2 +C CCFU(I,5)=FLOAT(NPC2(I))/AMAX0(1,NP2(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +C81 CONTINUE +C WRITE (1,324) +C DO 82 I=1,N2 +C CCFU(I,6)=FLOAT(NPC3(I))/AMAX0(1,NP3(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +C82 CONTINUE +C WRITE (1,325) +C DO 83 I=1,N2 +C CCFU(I,7)=FLOAT(NPC4(I))/AMAX0(1,NP4(I)) +C WRITE (1,310) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +C83 CONTINUE +C WRITE (1,330) +C DO 35 I=1,N2 +C CCFU(I,8)=(NPCX(I)+NPCY(I))/AMAX0(1,(NPX(I)+NPY(I))) +C WRITE (1,310) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) +C * ,NPX(I)+NPY(I) +C35 CONTINUE +C WRITE (1,328) +C DO 84 I=1,N2 +C CCFU(I,9)=(NPCX(I)+NPCY(I)+NPCZ(I))/AMAX0(1,(NPX(I)+NPY(I) +C * +NPZ(I))) +C WRITE (1,310) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) +C * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +C84 CONTINUE +C WRITE (1,327) +C DO 38 I=1,N2 +C CCFU(I,10)=(NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I)) +C * /AMAX0(1,(NP1(I)+NP2(I)+NP3(I)+NP4(I))) +C WRITE(1,310) I*DXYZ,CCFU(I,10), +C * NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I),NP1(I)+NP2(I)+NP3(I)+NP4(I) +C38 CONTINUE +C WRITE (1,329) +C DO 91 I=1,N2 +C CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) +C WRITE (1,310) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +C91 CONTINUE +C WRITE (1,331) +C DO 92 I=1,N2 +C CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) +C WRITE (1,310) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +C92 CONTINUE +C WRITE (1,332) +C DO 93 I=1,N2 +C CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) +C WRITE (1,310) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +C93 CONTINUE +C WRITE (1,333) +C DO 94 I=1,N2 +C CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) +C WRITE (1,310) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +C94 CONTINUE +C WRITE (1,334) +C DO 95 I=1,N2 +C CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) +C WRITE (1,310) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +C95 CONTINUE +C WRITE (1,335) +C DO 96 I=1,N2 +C CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) +C WRITE (1,310) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +C96 CONTINUE +C CLOSE (1) +C --------------------aca abro archivo salida ------------------- +c-------------------------------------------volale + VOLALE=FLOAT(ISMA)/FLOAT(IARE) + ZINTCC=ZGAMMA*FLOAT(JPHA)/FLOAT(NX*NY*NZ) + ZNCC=FLOAT(NCC) + ZIPZ=FLOAT(IPZ) + OPEN (1,FILE=DATALE) +C DO 555 I=1,N2 +C WRITE (6,*) CCFU(I,1) +C IF (CCFU(I,1).LE.ZINVERSAE) THEN +C CONCAR=I + +C WRITE (6,*) ZINTCC +C WRITE (6,*) ZACUMCC +C WRITE (6,*) VOLALE +C WRITE (6,*) ZGAMMA +C EXIT +C END IF +C555 CONTINUE + WRITE (1,500) ZINTCC, VOLALE, ZGAMMA, ZIPZ, ZNCC, PPHA +C WRITE (1,500) CONCAR, ZACUMCC, VOLALE, ZGAMMA, ZNCC, ZIPX, PPHA +C WRITE (1,'(F8.5)') CONCAR + CLOSE (1) +C --------------------aca CIERRO archivo salida ----------------- + + +C OUTPUT FILE WITH CONNECTED COMPONENTS +CC -----------------------------------------------------------OUTPUT 2 +C OPEN (1,FILE=COU2) +C +C DO 15 I=1,NX +C DO 16 J=1,NY +C DO 85 L=1,NZ +C WRITE (1,*) IND(I,J,L) +C85 CONTINUE +C16 CONTINUE +C15 CONTINUE +C +C CLOSE (1) +C--------------------------------------------------------------- + CLOSE (2) +C OPEN (1,FILE=COU3) +C DO 17 I=1,N2 +C WRITE (1,*) I*DX,CCFU(I,1),NPCX(I),NPX(I) +C17 CONTINUE +C WRITE (1,*) +C DO 18 I=1,N2 +C WRITE (1,*) I*DY,CCFU(I,2),NPCY(I),NPY(I) +C18 CONTINUE +C WRITE (1,*) +C DO 86 I=1,N2 +C WRITE (1,*) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +C86 CONTINUE +C WRITE (1,*) +C DO 19 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +C19 CONTINUE +C WRITE (1,*) +C DO 23 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +C23 CONTINUE +C WRITE (1,*) +C DO 87 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +C87 CONTINUE +C WRITE (1,*) +C DO 88 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +C88 CONTINUE +C WRITE (1,*) +C DO 21 I=1,N2 +C WRITE (1,*) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) +C * ,NPX(I)+NPY(I) +C21 CONTINUE +C WRITE (1,*) +C DO 89 I=1,N2 +C WRITE (1,*) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) +C * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +C89 CONTINUE +C WRITE (1,*) +C DO 22 I=1,N2 +C WRITE (1,*) I*DXYZ,CCFU(I,10),NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I) +C * ,NP1(I)+NP2(I)+NP3(I)+NP4(I) +C22 CONTINUE +C WRITE (1,*) +C DO 111 I=1,N2 +C CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) +C WRITE (1,*) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +C111 CONTINUE +C WRITE (1,*) +C DO 112 I=1,N2 +C CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) +C WRITE (1,*) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +C112 CONTINUE +C WRITE (1,*) +C DO 113 I=1,N2 +C CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) +C WRITE (1,*) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +C113 CONTINUE +C WRITE (1,*) +C DO 114 I=1,N2 +C CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) +C WRITE (1,*) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +C114 CONTINUE +C WRITE (1,*) +C DO 115 I=1,N2 +C CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) +C WRITE (1,*) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +C115 CONTINUE +C WRITE (1,*) +C DO 116 I=1,N2 +C CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) +C WRITE (1,*) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +C116 CONTINUE +C CLOSE (1) +C---------------------------------------------------------------- +C WRITE (6,410) COUT +C WRITE (6,420) COU2 +C WRITE (6,425) COU3 + STOP +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +131 FORMAT (1X,'NZ : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +151 FORMAT (1X,'DZ : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +241 FORMAT (1X,'MEAN LENGTH ALONG Z (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +251 FORMAT (1X,'MIMIMUN LENGTH ALONG Z (IN PIXELS) : ',I6) +261 FORMAT (1X,'MAXIMUM LENGTH ALONG Z (IN PIXELS) : ',I6) + +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +281 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Z : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION (1,0,0)') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION (0,1,0)') +321 FORMAT (/1X,'ALONG THE Z DIRECTION (0,0,1)') +322 FORMAT (/1X,'ALONG THE FIRST 3D DIAGONAL (1,1,1)') +323 FORMAT (/1X,'ALONG THE SECOND 3D DIAGONAL (1,-1,1)') +324 FORMAT (/1X,'ALONG THE THIRD 3D DIAGONAL (-1,-1,1)') +325 FORMAT (/1X,'ALONG THE FOURTH 3D DIAGONAL (-1,1,1)') +327 FORMAT (/1X,'AVERAGE ALONG THE 3D DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +328 FORMAT (/1X,'AVERAGE ALONG X, Y AND Z') +329 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Y PLANE (1,1,0)') +331 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Y PLANE (1,-1,0') +332 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Z PLANE (1,0,1)') +333 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Z PLANE (1,0,-1)') +334 FORMAT (/1X,'FIRST DIAGONAL ON THE Y-Z PLANE (0,1,1)') +335 FORMAT (/1X,'SECOND DIAGONAL ON THE Y-Z PLANE (0,1,-1)') +400 FORMAT (25(/),1X,'CONNEC3D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'6-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'18-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +450 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'26-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +C-----agregue este format concar (cuando cae abajo 1/e), zacum (integral cc),volale (vol largest cluster / vol tot),gamma,ppha +C- WRITE (1,500) CONCAR, VOLALE, ZGAMMA, ZIPZ, ZNCC, PPHA +500 FORMAT (1X,F8.7,' ',F8.7,' ',F8.7,' ',F8.2,' ',F8.2,' ',F8.5) +C500 FORMAT (1X,F8.2,' ',F8.5,' ',F8.5,' ',F8.7,' ',F8.2,' ',F8.5) + END diff --git a/tools/connec/connec-src/ver_modificada/makefile b/tools/connec/connec-src/ver_modificada/makefile new file mode 100755 index 0000000..b87c5ff --- /dev/null +++ b/tools/connec/connec-src/ver_modificada/makefile @@ -0,0 +1,9 @@ +F90:= gfortran +all: conec2d conec3d +conec2d: conec2d.FOR + $(F90) -O3 -o conec2d conec2d.FOR +conec3d: conec3d.FOR + $(F90) -O3 -o conec3d conec3d.FOR +clean: + -rm -f conec2d conec3d + diff --git a/tools/connec/connec-src/ver_original/CONNEC2D(1).FOR b/tools/connec/connec-src/ver_original/CONNEC2D(1).FOR new file mode 100644 index 0000000..cf48b53 --- /dev/null +++ b/tools/connec/connec-src/ver_original/CONNEC2D(1).FOR @@ -0,0 +1,427 @@ +C CONNEC2D.FOR VER.21-FEB-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 2D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 4 FOR 4-CONNECTIVITY AND 8 FOR 8-CONNECTIVITY +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY : NUMBER OF POINTS IN X AND Y +C DX DY : GRID DIMENSIONS IN X AND Y +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C +C IND(I,J) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG NE-SW DIRECTION. +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG NW-SE DIRECTION. +C CCFU(.,5): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,6): MEAN CONNECTIVITY FUNCTION ALONG THE DIAGONALS. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(256,256),NPX(256),NPY(256),NPCX(256),NPCY(256) + DIMENSION NPE(256),NPW(256),NPCE(256),NPCW(256),CCFU(256,6) +C + CHARACTER*12 CPAR,CINP,COUT,COU2,COU3 +C +C MATRIX DIMENSION LIMITATION +C + NXM=256 + NYM=256 +C + WRITE (6,400) + READ (5,100) CPAR + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.4.AND.ICON.NE.8) THEN + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 4 OR A 8' + WRITE (6,*)'4 MEANS 4-CONNECTIVITY' + WRITE (6,*)'8 MEANS 8-CONNECTIVITY' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY + READ (1,*) DX,DY + READ (1,100) COUT + READ (1,100) COU2 + READ (1,100) COU3 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'MAXIMUM NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'MAXIMUM NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 2D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + READ (1,*) XX,YY,VAL + IND(I,J)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).NE.1.AND.IND(I,J).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J)=1 + ELSE + IND(I,J)=0 + END IF + END IF + IF (IND(I,J).EQ.1) JPHA=JPHA+1 +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.4) WRITE (6,*)'4-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.8) WRITE (6,*)'8-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + IF (IND(I,J).EQ.1) THEN + IAI=I + IAJ=J + GOTO 8 + END IF +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J-1)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I,J+1)=NCC+1 + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I-1,J+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) IND(I+1,J+1)=NCC+1 + END IF + END IF + END IF +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + IF ((I-1).GT.0) THEN + IF (IND(I-1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (ICON.EQ.8) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I-1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1).EQ.1) THEN + IF (IND(I,J).EQ.NCC+1) THEN + IND(I+1,J+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + IF (IND(I,J).NE.0) IND(I,J)=IND(I,J)-1 +51 CONTINUE +50 CONTINUE +C + +C +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) + OPEN (2,FILE=CINP) +C + DO 15 I=1,NX + DO 16 J=1,NY + READ (2,*) XX,YY,ZVA + WRITE (1,*) XX,YY,IND(I,J) +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION') +321 FORMAT (/1X,'ALONG THE NE-SW DIRECTION') +322 FORMAT (/1X,'ALONG THE NW-SE DIRECTION') +323 FORMAT (/1X,'AVERAGE ALONG THE DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +400 FORMAT (25(/),1X,'CONNEC2D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC2D'//1X'4-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/ver_original/Connec_ver_original.zip b/tools/connec/connec-src/ver_original/Connec_ver_original.zip new file mode 100644 index 0000000..6545324 Binary files /dev/null and b/tools/connec/connec-src/ver_original/Connec_ver_original.zip differ diff --git a/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.EXE b/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.EXE new file mode 100644 index 0000000..69a14b4 Binary files /dev/null and b/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.EXE differ diff --git a/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.FOR b/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.FOR new file mode 100644 index 0000000..e1e55d5 --- /dev/null +++ b/tools/connec/connec-src/ver_original/Connec_ver_original/CONNEC3D.FOR @@ -0,0 +1,1282 @@ +$LARGE +C CONNEC3D.FOR VER.11-NOV-2002 +C +C PROGRAM FOR CONNECTIVITY ANALYSIS OF A 3D INDICATOR MAP +C +C GIVEN AN INDICATOR FIELDS (VALUES 0 AND 1 ONLY), THE RANDOM SET +C WITH VALUES 1 IS ANALYSED FOR CONNECTIVITY. +C +C INPUT PARAMETER FILE WITH +C +C IPHA : 0 OR 1 FOR CONNECTIVITY ANALYSIS OF PHASE 0 OR 1. +C ICON : 6, 18 OR 26-CONNECTIVITY. +C CINP : INPUT FILE WITH INDICATOR VARIABLE (VALUS 0/1 ONLY) +C NX NY NZ : NUMBER OF POINTS IN X AND Y +C DX DY DZ : GRID DIMENSIONS IN X AND Y +C N2 : NUMBER OF LAGS FOR CONNECTIVITY FUNCTION CALCULATION +C COUT : OUTPUT FILE WITH STATISTICS +C COU2 : OUTPUT FILE WITH CONNECTED COMPONENTS +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCITON +C +C DX,DY,DZ ARE ONLY USED FOR CONVERTING GRID UNITS TO REAL UNITS. +C NX : NUMBER OF POINTS ALONG THE X DIRECTION +C NY : NUMBER OF POINTS ALONG THE Y DIRECTION +C NZ : NUMBER OF POINTS ALONG THE Z DIRECTION +C +C IND(I,J,L) : 0/1 INDICATOR VALUE +C AT THE TERMINATION OF THE PROGRAM THE MATRIX IND(I,J) CONTAINS +C THE CONNECTED COMPONENTS WITH VALUES 1,2,3,4,5,... FOR FIRST, +C SECOND, THIRD, ... ETC CONNECTED COMMPONENTS. +C THE VALUE 0 REMAINS 0. +C COUT : OUTPUT FILE WITH STATISTICS AND CONNECTIVITY FUNCTION. +C COU2 : OUTPUT FILE WITH THE CONNECTED COMPONENTS. +C COU3 : OUTPUT FILE WITH CONNECTIVITY FUNCTION +C +C FOR THE CONNECTIVITY FUNCTION: +C NPX(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE X DIRECTION AND THAT BELONG TO FACIES 1. +C NPCX(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPY(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Y DIRECTION AND THAT BELONG TO FACIES 1. +C NPCY(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C NPZ(K): NUMBER OF PAIRS OF VALUES SEPARATED A DISTANCE K ALONG +C THE Z DIRECTION AND THAT BELONG TO FACIES 1. +C NPCZ(K): NUMBER OF THE PREVIOUS VALUES THAT ARE CONNECTED. +C +C +C PPHA : PROPORTION OF FACIES 1. +C NCC : NUMBER OF CONNECTED COMPONENTS. +C RISM : MEAN CONNECTED COMPONENT SIZE IN PIXELS. +C RSME : MRAN SIZE IN REAL UNITS. +C RTOT : MEAN SIZE RELATIVE TO SIZE OF FACIES 1. +C RXME : MEAN LENGTH ALONG THE X DIRECTION. +C RYME : MEAN LENGTH ALONG THE Y DIRECTION. +C RZME : MEAN LENGTH ALONG THE Z DIRECTION. +C ICOM : NUMBER OF THE LARGEST COMPONENT. +C ISMA : SIZE IN PIXELS (OR LARGEST COMPONENT). +C RSIZ : SIZE RELATIVE TO SIZE OF FACIES 1. +C IXMA : MAXIMUM LENGTH ALONG X. +C IYMA : MAXIMUM LENGTH ALONG Y. +C IZMA : MAXIMUM LENGTH ALONG Z. +C ISMI : SIZE OF SMALLEST COMPONENT. +C IXMI : MINIMUM LENGTH ALONG X. +C IYMI : MINIMUM LENGTH ALONG Y. +C IZMI : MINIMUM LENGTH ALONG Z. +C IPX : NUMBER OF PERCOLATING COMPONENTS ALONG X. +C IPY : NUMBER OF PERCOLATING COMPONENTS ALONG Y. +C IPZ : NUMBER OF PERCOLATING COMPONENTS ALONG Z. +C CCFU(.,.) : CONNECTIVITY FUNCTION. +C +C CCFU(.,1): CONNECTIVITY FUNCTION ALONG X (E-W). +C CCFU(.,2): CONNECTIVITY FUNCTION ALONG Y (N-S). +C CCFU(.,3): CONNECTIVITY FUNCTION ALONG Z (VERTICAL). +C CCFU(.,4): CONNECTIVITY FUNCTION ALONG 3D FIRST DIAGONAL. +C CCFU(.,5): CONNECTIVITY FUNCTION ALONG 3D SECOND DIAGONAL. +C CCFU(.,6): CONNECTIVITY FUNCTION ALONG 3D THIRD DIAGONAL. +C CCFU(.,7): CONNECTIVITY FUNCTION ALONG 3D FOURTH DIAGONAL. +C CCFU(.,8): MEAN CONNECTIVITY FUNCTION ALONG X AND Y. +C CCFU(.,9): MEAN CONNECTIVITY FUNCTION ALONG X,Y,Z. +C CCFU(.,10): MEAN CONNECTIVITY FUNCTION ALONG THE 3D DIAGONALS. +C CCFU(.,11): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Y PLANE. +C CCFU(.,12): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Y PLANE. +C CCFU(.,13): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL X-Z PLANE. +C CCFU(.,14): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL X-Z PLANE. +C CCFU(.,15): CONNECTIVITY FUNCTION ALONG FIRST DIAGONAL Y-Z PLANE. +C CCFU(.,16): CONNECTIVITY FUNCTION ALONG SECOND DIAGONAL Y-Z PLANE. +C +C +C ---------------------------------------------------------------- +C + DIMENSION IND(100,100,50),NPX(256),NPY(256),NPCX(256),NPCY(256) + DIMENSION NPZ(256),NPCZ(256),NP1(256),NP2(256),NP3(256) + DIMENSION NP4(256),NPC1(256),NPC2(256),NPC3(256),NPC4(256) + DIMENSION CCFU(256,16) + DIMENSION NXY1(256),NXY2(256),NXZ1(256),NXZ2(256) + DIMENSION NYZ1(256),NYZ2(256),NCXY1(256),NCXY2(256) + DIMENSION NCXZ1(256),NCXZ2(256),NCYZ1(256),NCYZ2(256) +C + CHARACTER*12 CPAR,CINP,COUT,COU2,COU3 +C +C MATRIX DIMENSION LIMITATION +C + NXM=100 + NYM=100 + NZM=50 +C + WRITE (6,400) + READ (5,100) CPAR + OPEN (1,FILE=CPAR) + READ (1,*) IPHA + IF (IPHA.NE.0.AND.IPHA.NE.1) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE FIRST LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE A 0 OR A 1' + WRITE (6,*)'0 FOR CONNECTIVITY ANALYSIS OF PHASE 0' + WRITE (6,*)'1 FOR CONNECTIVITY ANALYSIS OF PHASE 1' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',IPHA + STOP + END IF + READ (1,*) ICON + IF (ICON.NE.6.AND.ICON.NE.18.AND.ICON.NE.26) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'THE SECOND LINE IN THE PARAMETER FILE' + WRITE (6,*)'MUST BE 6, 18 OR 26' + WRITE (6,*)'6 MEANS 6-CONNECTIVITY (FACE CONNECTIVITY)' + WRITE (6,*)'18 MEANS 18-CONNECTIVITY (FACE+EDGE CONNECTIVITY)' + WRITE (6,*)'26 MEANS 26-CONNECTIVITY (FACE+EDGE+VERTEX CONN.)' + WRITE (6,*)'THE ACTUAL VALUE IN THE PARAMETER FILE IS: ',ICON + STOP + END IF + READ (1,100) CINP + READ (1,*) NX,NY,NZ + READ (1,*) DX,DY,DZ + READ (1,*) N2 + READ (1,100) COUT + READ (1,100) COU2 + READ (1,100) COU3 + CLOSE (1) + IF (NX.GT.NXM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NX IS ',NXM + WRITE (6,*)'ACTUAL VALUE IS ',NX + STOP + END IF + IF (NY.GT.NYM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NY IS ',NYM + WRITE (6,*)'ACTUAL VALUE IS ',NY + STOP + END IF + IF (NZ.GT.NZM) THEN + WRITE (6,*)'ERROR IN PARAMETER FILE !!!' + WRITE (6,*)'MAXIMUM ALLOWED NZ IS ',NZM + WRITE (6,*)'ACTUAL VALUE IS ',NZ + STOP + END IF +C +C READING EXPERIMENTAL INDICATOR DATA 3D FIELD +C + OPEN (1,FILE=CINP) + JPHA=0 + DO 1 I=1,NX + DO 2 J=1,NY + DO 3 L=1,NZ + READ (1,*) VAL + IND(I,J,L)=INT(VAL) + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).NE.1.AND.IND(I,J,L).NE.0) THEN + WRITE (6,*)'EXPERIMENTAL DATA MUST BE INDICATOR DATA 0/1' + WRITE (6,*)'ACTUAL VALUE : ',IND(I,J,L) + STOP + END IF + IF (IPHA.EQ.0) THEN + IF (INT(VAL).EQ.0) THEN + IND(I,J,L)=1 + ELSE + IND(I,J,L)=0 + END IF + END IF + IF (IND(I,J,L).EQ.1) JPHA=JPHA+1 +3 CONTINUE +2 CONTINUE +1 CONTINUE + CLOSE (1) + IARE=NX*NY*NZ + PPHA=FLOAT(JPHA)/IARE + WRITE (6,*) + IF (ICON.EQ.6) WRITE (6,*)'6-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.18) WRITE (6,*)'18-CONNECTIVITY ANALYSIS' + IF (ICON.EQ.26) WRITE (6,*)'26-CONNECTIVITY ANALYSIS' + WRITE (6,*) + WRITE (6,*)'PROPORTION OF PHASE 1 IS: ',PPHA +C +C +C LOOKING FOR CONNECTED COMPONENTS +C + NCC=0 +C +5 DO 6 I=1,NX + DO 7 J=1,NY + DO 67 L=1,NZ + IF (IND(I,J,L).EQ.1) THEN + IAI=I + IAJ=J + IAL=L + GOTO 8 + END IF +67 CONTINUE +7 CONTINUE +6 CONTINUE +C NO MORE CONNECTED COMPONENTS SENDING CONTROL TO LABEL 20 + GOTO 20 +C +C A NEW COMPONEND HAS BEEN FOUND, INCREASE NUMBER OF +C CONNECTED COMPONENTS BY 1 +C +C +8 NCC=NCC+1 + WRITE (6,*)'NCC : ',NCC +C +C LOOKING FOR COMPONENT NCC WITH LABEL NNC+1 +C + IND(IAI,IAJ,IAL)=NCC+1 + DO 9 I=IAI,NX + DO 10 J=IAJ,NY + DO 68 L=IAL,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +68 CONTINUE +10 CONTINUE +9 CONTINUE + DO 40 I=IAI,1,-1 + DO 41 J=IAJ,1,-1 + DO 69 L=IAL,1,-1 +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L)=NCC+1 + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L)=NCC+1 + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L)=NCC+1 + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L)=NCC+1 + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L-1)=NCC+1 + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J,L+1)=NCC+1 + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L-1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L-1)=NCC+1 + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J-1,L+1)=NCC+1 + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L)=NCC+1 + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L-1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J-1,L+1)=NCC+1 + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I-1,J+1,L+1)=NCC+1 + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) IND(I+1,J+1,L+1)=NCC+1 + END IF + END IF + END IF +69 CONTINUE +41 CONTINUE +40 CONTINUE +C +62 NNN=0 + DO 60 I=1,NX + DO 61 J=1,NY + DO 70 L=1,NZ +C +C 6-CONNECTIVITY +C + IF ((I-1).GT.0) THEN + IF (IND(I-1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (I+1.LE.NX) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J-1.GT.0) THEN + IF (IND(I,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (J+1.LE.NY) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L-1.GT.0) THEN + IF (IND(I,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF (L+1.LE.NZ) THEN + IF (IND(I,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF +C +C 18-CONNECTIVITY +C + IF (ICON.GT.6) THEN + IF ((J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L-1).GT.0) THEN + IF (IND(I+1,J,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY) THEN + IF (IND(I+1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0) THEN + IF (IND(I+1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY) THEN + IF (IND(I-1,J+1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0) THEN + IF (IND(I-1,J-1,L).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +C +C 26-CONNECTIVITY +C + IF (ICON.GT.18) THEN + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I-1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L-1).GT.0) THEN + IF (IND(I+1,J-1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I-1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L-1).GT.0) THEN + IF (IND(I+1,J+1,L-1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L-1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J-1).GT.0.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J-1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J-1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I-1).GT.0.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I-1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I-1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + IF ((I+1).LE.NX.AND.(J+1).LE.NY.AND.(L+1).LE.NZ) THEN + IF (IND(I+1,J+1,L+1).EQ.1) THEN + IF (IND(I,J,L).EQ.NCC+1) THEN + IND(I+1,J+1,L+1)=NCC+1 + NNN=NNN+1 + END IF + END IF + END IF + END IF +70 CONTINUE +61 CONTINUE +60 CONTINUE + IF (NNN.GT.0) GOTO 62 + GOTO 5 +C +C THE CONNECTED COMPONENT IS THE COMPONENT WITH VALUES +C IA(I,J,L)=NCC, WE SUBSTRACT 1 FROM THE LEBEL +C +20 DO 50 I=1,NX + DO 51 J=1,NY + DO 71 L=1,NZ + IF (IND(I,J,L).NE.0) IND(I,J,L)=IND(I,J,L)-1 +71 CONTINUE +51 CONTINUE +50 CONTINUE +C +C STATISTICS ON CONNECTED COMPONENTS +C + ISME=0 + IXME=0 + IYME=0 + IZME=0 + ISMI=NX*NY*NZ + ISMA=1 + IXMI=NX + IXMA=1 + IYMI=NY + IYMA=1 + IZMI=NZ + IZMA=1 + IPX=0 + IPY=0 + IPZ=0 + WRITE (6,*) + WRITE (6,*)'NUMBER OF CONNECTED COMPONENTS: ',NCC + DO 14 III=1,NCC + IS=0 + IX1=NX + IY1=NY + IZ1=NZ + IX2=1 + IY2=1 + IZ2=1 + DO 11 I=1,NX + DO 12 J=1,NY + DO 72 L=1,NZ + IF (IND(I,J,L).EQ.III) THEN + IS=IS+1 + IF (I.LT.IX1) IX1=I + IF (I.GT.IX2) IX2=I + IF (J.LT.IY1) IY1=J + IF (J.GT.IY2) IY2=J + IF (L.LT.IZ1) IZ1=L + IF (L.GT.IZ2) IZ2=L + END IF +72 CONTINUE +12 CONTINUE +11 CONTINUE + IXSI=IX2-IX1+1 + IYSI=IY2-IY1+1 + IZSI=IZ2-IZ1+1 + ISME=ISME+IS + IXME=IXME+IXSI + IYME=IYME+IYSI + IZME=IZME+IZSI + IF (IS.LT.ISMI) ISMI=IS + IF (IS.GT.ISMA) THEN + ISMA=IS + ICOM=III + END IF + IF (IXSI.LT.IXMI) IXMI=IXSI + IF (IXSI.GT.IXMA) IXMA=IXSI + IF (IYSI.LT.IYMI) IYMI=IYSI + IF (IYSI.GT.IYMA) IYMA=IYSI + IF (IZSI.LT.IZMI) IZMI=IZSI + IF (IZSI.GT.IZMA) IZMA=IZSI + IF (IXSI.EQ.NX) IPX=IPX+1 + IF (IYSI.EQ.NY) IPY=IPY+1 + IF (IZSI.EQ.NZ) IPZ=IPZ+1 +14 CONTINUE +C +C OUTPUT +C + OPEN (1,FILE=COUT) + IF (ICON.EQ.6) WRITE (1,430) CPAR + IF (ICON.EQ.18) WRITE (1,440) CPAR + IF (ICON.EQ.26) WRITE (1,450) CPAR + WRITE (1,110) CINP + WRITE (1,120) NX + WRITE (1,130) NY + WRITE (1,131) NZ + WRITE (1,140) DX + WRITE (1,150) DY + WRITE (1,151) DZ + WRITE (1,160) IPHA,PPHA + WRITE (1,170) NCC + RSME=DX*DY*DZ*ISME/FLOAT(NCC) + RISM=FLOAT(ISME)/NCC + RTOT=RISM/JPHA + WRITE (1,175) + WRITE (1,180) RISM + WRITE (1,190) RSME + WRITE (1,200) IPHA,RTOT + RXME=FLOAT(IXME)/NCC + RYME=FLOAT(IYME)/NCC + RZME=FLOAT(IZME)/NCC + WRITE (1,210) RXME + WRITE (1,240) RYME + WRITE (1,241) RZME + WRITE (1,177) + WRITE (1,235) ICOM + WRITE (1,236) ISMA + RSIZ=FLOAT(ISMA)/JPHA + WRITE (1,237) IPHA,RSIZ + WRITE (1,230) IXMA + WRITE (1,260) IYMA + WRITE (1,261) IZMA + WRITE (1,176) + WRITE (1,238) ISMI + WRITE (1,220) IXMI + WRITE (1,250) IYMI + WRITE (1,251) IZMI + WRITE (1,178) + WRITE (1,270) IPX + WRITE (1,280) IPY + WRITE (1,281) IPZ + WRITE (1,290) COU2 + WRITE (1,295) COU3 +C +C CONNECTIVITY FUNCTION +C CALCULATED FOR N2 LAGS +C + DO 595 I=1,N2 + NPX(I)=0 + NPY(I)=0 + NPZ(I)=0 + NP1(I)=0 + NP2(I)=0 + NP3(I)=0 + NP4(I)=0 + NPCX(I)=0 + NPCY(I)=0 + NPCZ(I)=0 + NPC1(I)=0 + NPC2(I)=0 + NPC3(I)=0 + NPC4(I)=0 +595 CONTINUE + DO 30 I=1,NX + DO 31 J=1,NY + DO 73 L=1,NZ + I1=IND(I,J,L) + IF (I1.EQ.0) GOTO 73 + DO 32 K=1,N2 +C +C ALONG X +C + IF (I+K.LE.NX) THEN + IF (IND(I+K,J,L).NE.0) THEN + NPX(K)=NPX(K)+1 + IF (I1.EQ.IND(I+K,J,L)) NPCX(K)=NPCX(K)+1 + END IF + END IF +C +C ALONG Y +C + IF (J+K.LE.NY) THEN + IF (IND(I,J+K,L).NE.0) THEN + NPY(K)=NPY(K)+1 + IF (I1.EQ.IND(I,J+K,L)) NPCY(K)=NPCY(K)+1 + END IF + END IF +C +C ALONG Z +C + IF (L+K.LE.NZ) THEN + IF (IND(I,J,L+K).NE.0) THEN + NPZ(K)=NPZ(K)+1 + IF (I1.EQ.IND(I,J,L+K)) NPCZ(K)=NPCZ(K)+1 + END IF + END IF +C +C ALONG 3D DIAGONAL 1 (I+, J+, K+) +C + IF ((J+K.LE.NY).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN + IF (IND(I+K,J+K,L+K).NE.0) THEN + NP1(K)=NP1(K)+1 + IF (I1.EQ.IND(I+K,J+K,L+K)) NPC1(K)=NPC1(K)+1 + END IF + END IF +C +C ALONG 3D DIAGONAL 2 (I+, J-, K+) +C + IF ((J-K.GT.0).AND.(I+K.LE.NX).AND.(L+K.LE.NZ)) THEN + IF (IND(I+K,J-K,L+K).NE.0) THEN + NP2(K)=NP2(K)+1 + IF (I1.EQ.IND(I+K,J-K,L+K)) NPC2(K)=NPC2(K)+1 + END IF + END IF +C +C ALONG 3D DIAGONAL 3 (I-, J-, K+) +C + IF ((J-K.GT.0).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN + IF (IND(I-K,J-K,L+K).NE.0) THEN + NP3(K)=NP3(K)+1 + IF (I1.EQ.IND(I-K,J-K,L+K)) NPC3(K)=NPC3(K)+1 + END IF + END IF +C +C ALONG 3D DIAGONAL 4 (I-, J+, K+) +C + IF ((J+K.LE.NY).AND.(I-K.GT.0).AND.(L+K.LE.NZ)) THEN + IF (IND(I-K,J+K,L+K).NE.0) THEN + NP4(K)=NP4(K)+1 + IF (I1.EQ.IND(I-K,J+K,L+K)) NPC4(K)=NPC4(K)+1 + END IF + END IF +C +C FIRST DIAGONAL IN THE PLANE X-Y +C + IF ((I+K.LE.NX).AND.(J+K.LE.NY)) THEN + IF (IND(I+K,J+K,L).NE.0) THEN + NXY1(K)=NXY1(K)+1 + IF (I1.EQ.IND(I+K,J+K,L)) NCXY1(K)=NCXY1(K)+1 + END IF + END IF +C +C SECOND DIAGONAL IN THE PLANE X-Y +C + IF ((I+K.LE.NX).AND.(J-K.GT.0)) THEN + IF (IND(I+K,J-K,L).NE.0) THEN + NXY2(K)=NXY2(K)+1 + IF (I1.EQ.IND(I+K,J-K,L)) NCXY2(K)=NCXY2(K)+1 + END IF + END IF +C +C FIRST DIAGONAL IN THE PLANE X-Z +C + IF ((I+K.LE.NX).AND.(L+K.LE.NZ)) THEN + IF (IND(I+K,J,L+K).NE.0) THEN + NXZ1(K)=NXZ1(K)+1 + IF (I1.EQ.IND(I+K,J,L+K)) NCXZ1(K)=NCXZ1(K)+1 + END IF + END IF +C +C SECOND DIAGONAL IN THE PLANE X-Z +C + IF ((I+K.LE.NX).AND.(L-K.GT.0)) THEN + IF (IND(I+K,J,L-K).NE.0) THEN + NXZ2(K)=NXZ2(K)+1 + IF (I1.EQ.IND(I+K,J,L-K)) NCXZ2(K)=NCXZ2(K)+1 + END IF + END IF +C +C FIRST DIAGONAL IN THE PLANE Y-Z +C + IF ((J+K.LE.NY).AND.(L+K.LE.NZ)) THEN + IF (IND(I,J+K,L+K).NE.0) THEN + NYZ1(K)=NYZ1(K)+1 + IF (I1.EQ.IND(I,J+K,L+K)) NCYZ1(K)=NCYZ1(K)+1 + END IF + END IF +C +C SECOND DIAGONAL IN THE PLANE Y-Z +C + IF ((J+K.LE.NY).AND.(L-K.GT.0)) THEN + IF (IND(I,J+K,L-K).NE.0) THEN + NYZ2(K)=NYZ2(K)+1 + IF (I1.EQ.IND(I,J+K,L-K)) NCYZ2(K)=NCYZ2(K)+1 + END IF + END IF +32 CONTINUE +73 CONTINUE +31 CONTINUE +30 CONTINUE + WRITE (1,300) + DO 33 I=1,N2 + CCFU(I,1)=FLOAT(NPCX(I))/AMAX0(1,NPX(I)) + WRITE (1,310) I*DX,CCFU(I,1),NPCX(I),NPX(I) +33 CONTINUE + WRITE (1,320) + DO 34 I=1,N2 + CCFU(I,2)=FLOAT(NPCY(I))/AMAX0(1,NPY(I)) + WRITE (1,310) I*DY,CCFU(I,2),NPCY(I),NPY(I) +34 CONTINUE + WRITE (1,321) + DO 36 I=1,N2 + CCFU(I,3)=FLOAT(NPCZ(I))/AMAX0(1,NPZ(I)) + WRITE (1,310) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +36 CONTINUE + DXYZ=SQRT(DX*DX+DY*DY+DZ*DZ) + DXY=SQRT(DX*DX+DY*DY) + DXZ=SQRT(DX*DX+DZ*DZ) + DYZ=SQRT(DY*DY+DZ*DZ) + WRITE (1,322) + DO 37 I=1,N2 + CCFU(I,4)=FLOAT(NPC1(I))/AMAX0(1,NP1(I)) + WRITE (1,310) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +37 CONTINUE + WRITE (1,323) + DO 81 I=1,N2 + CCFU(I,5)=FLOAT(NPC2(I))/AMAX0(1,NP2(I)) + WRITE (1,310) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +81 CONTINUE + WRITE (1,324) + DO 82 I=1,N2 + CCFU(I,6)=FLOAT(NPC3(I))/AMAX0(1,NP3(I)) + WRITE (1,310) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +82 CONTINUE + WRITE (1,325) + DO 83 I=1,N2 + CCFU(I,7)=FLOAT(NPC4(I))/AMAX0(1,NP4(I)) + WRITE (1,310) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +83 CONTINUE + WRITE (1,330) + DO 35 I=1,N2 + CCFU(I,8)=(NPCX(I)+NPCY(I))/AMAX0(1,(NPX(I)+NPY(I))) + WRITE (1,310) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) + * ,NPX(I)+NPY(I) +35 CONTINUE + WRITE (1,328) + DO 84 I=1,N2 + CCFU(I,9)=(NPCX(I)+NPCY(I)+NPCZ(I))/AMAX0(1,(NPX(I)+NPY(I) + * +NPZ(I))) + WRITE (1,310) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) + * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +84 CONTINUE + WRITE (1,327) + DO 38 I=1,N2 + CCFU(I,10)=(NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I)) + * /AMAX0(1,(NP1(I)+NP2(I)+NP3(I)+NP4(I))) + WRITE(1,310) I*DXYZ,CCFU(I,10), + * NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I),NP1(I)+NP2(I)+NP3(I)+NP4(I) +38 CONTINUE + WRITE (1,329) + DO 91 I=1,N2 + CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) + WRITE (1,310) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +91 CONTINUE + WRITE (1,331) + DO 92 I=1,N2 + CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) + WRITE (1,310) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +92 CONTINUE + WRITE (1,332) + DO 93 I=1,N2 + CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) + WRITE (1,310) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +93 CONTINUE + WRITE (1,333) + DO 94 I=1,N2 + CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) + WRITE (1,310) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +94 CONTINUE + WRITE (1,334) + DO 95 I=1,N2 + CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) + WRITE (1,310) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +95 CONTINUE + WRITE (1,335) + DO 96 I=1,N2 + CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) + WRITE (1,310) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +96 CONTINUE + CLOSE (1) +C +C OUTPUT FILE WITH CONNECTED COMPONENTS +C + OPEN (1,FILE=COU2) +C + DO 15 I=1,NX + DO 16 J=1,NY + DO 85 L=1,NZ + WRITE (1,*) IND(I,J,L) +85 CONTINUE +16 CONTINUE +15 CONTINUE +C + CLOSE (1) + CLOSE (2) + OPEN (1,FILE=COU3) + DO 17 I=1,N2 + WRITE (1,*) I*DX,CCFU(I,1),NPCX(I),NPX(I) +17 CONTINUE + WRITE (1,*) + DO 18 I=1,N2 + WRITE (1,*) I*DY,CCFU(I,2),NPCY(I),NPY(I) +18 CONTINUE + WRITE (1,*) + DO 86 I=1,N2 + WRITE (1,*) I*DZ,CCFU(I,3),NPCZ(I),NPZ(I) +86 CONTINUE + WRITE (1,*) + DO 19 I=1,N2 + WRITE (1,*) I*DXYZ,CCFU(I,4),NPC1(I),NP1(I) +19 CONTINUE + WRITE (1,*) + DO 23 I=1,N2 + WRITE (1,*) I*DXYZ,CCFU(I,5),NPC2(I),NP2(I) +23 CONTINUE + WRITE (1,*) + DO 87 I=1,N2 + WRITE (1,*) I*DXYZ,CCFU(I,6),NPC3(I),NP3(I) +87 CONTINUE + WRITE (1,*) + DO 88 I=1,N2 + WRITE (1,*) I*DXYZ,CCFU(I,7),NPC4(I),NP4(I) +88 CONTINUE + WRITE (1,*) + DO 21 I=1,N2 + WRITE (1,*) I*0.5*(DX+DY),CCFU(I,8),NPCX(I)+NPCY(I) + * ,NPX(I)+NPY(I) +21 CONTINUE + WRITE (1,*) + DO 89 I=1,N2 + WRITE (1,*) I*(DX+DY+DZ)/3.0,CCFU(I,9),NPCX(I)+NPCY(I) + * +NPCZ(I),NPX(I)+NPY(I)+NPZ(I) +89 CONTINUE + WRITE (1,*) + DO 22 I=1,N2 + WRITE (1,*) I*DXYZ,CCFU(I,10),NPC1(I)+NPC2(I)+NPC3(I)+NPC4(I) + * ,NP1(I)+NP2(I)+NP3(I)+NP4(I) +22 CONTINUE + WRITE (1,*) + DO 111 I=1,N2 + CCFU(I,11)=FLOAT(NCXY1(I))/AMAX0(1,NXY1(I)) + WRITE (1,*) I*DXY,CCFU(I,11),NCXY1(I),NXY1(I) +111 CONTINUE + WRITE (1,*) + DO 112 I=1,N2 + CCFU(I,12)=FLOAT(NCXY2(I))/AMAX0(1,NXY2(I)) + WRITE (1,*) I*DXY,CCFU(I,12),NCXY2(I),NXY2(I) +112 CONTINUE + WRITE (1,*) + DO 113 I=1,N2 + CCFU(I,13)=FLOAT(NCXZ1(I))/AMAX0(1,NXZ1(I)) + WRITE (1,*) I*DXZ,CCFU(I,13),NCXZ1(I),NXZ1(I) +113 CONTINUE + WRITE (1,*) + DO 114 I=1,N2 + CCFU(I,14)=FLOAT(NCXZ2(I))/AMAX0(1,NXZ2(I)) + WRITE (1,*) I*DXZ,CCFU(I,14),NCXZ2(I),NXZ2(I) +114 CONTINUE + WRITE (1,*) + DO 115 I=1,N2 + CCFU(I,15)=FLOAT(NCYZ1(I))/AMAX0(1,NYZ1(I)) + WRITE (1,*) I*DYZ,CCFU(I,15),NCYZ1(I),NYZ1(I) +115 CONTINUE + WRITE (1,*) + DO 116 I=1,N2 + CCFU(I,16)=FLOAT(NCYZ2(I))/AMAX0(1,NYZ2(I)) + WRITE (1,*) I*DYZ,CCFU(I,16),NCYZ2(I),NYZ2(I) +116 CONTINUE + CLOSE (1) + WRITE (6,410) COUT + WRITE (6,420) COU2 + WRITE (6,425) COU3 + STOP +C +100 FORMAT (A) +110 FORMAT (1X,'INPUT INDICATOR FILE : ',A12) +120 FORMAT (1X,'NX : ',I6) +130 FORMAT (1X,'NY : ',I6) +131 FORMAT (1X,'NZ : ',I6) +140 FORMAT (1X,'DX : ',F10.3) +150 FORMAT (1X,'DY : ',F10.3) +151 FORMAT (1X,'DZ : ',F10.3) +160 FORMAT (1X,'PROPORTION OF FACIES ',I1,' : ',F10.4) +170 FORMAT (/1X,'CONNECTED COMPONENTS STATISTICS'// + * /1X,'NUMBER OF CONNECTED COMPONENTS : ',I6) +175 FORMAT (/1X,'AVERAGES'/1X,8('=')) +176 FORMAT (/1X,'MINIMA'/1X,6('=')) +177 FORMAT (/1X,'MAXIMA'/1X,6('=')) +178 FORMAT (/1X,'PERCOLATION'/1X,11('=')) +180 FORMAT (1X,'MEAN SIZE IN PIXELS : ',F10.4) +190 FORMAT (1X,'MEAN SIZE REAL UNITS : ',F12.4) +200 FORMAT (1X,'MEAN SIZE RELATIVE TO TOTAL AREA OF FACIES ',I1, + * ' : ',F10.4) +210 FORMAT (1X,'MEAN LENGTH ALONG X (IN PIXELS) : ',F10.4) +220 FORMAT (1X,'MINIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +230 FORMAT (1X,'MAXIMUM LENGTH ALONG X (IN PIXELS) : ',I6) +235 FORMAT (1X,'THE LARGEST COMPONENT IS NUMBER : ',I6) +236 FORMAT (1X,'WITH MAXIMUM SIZE IN PIXELS : ',I6) +237 FORMAT (1X,'AND RELATIVE TO TOTAL AREA OF FACIES ' + * ,I1,' : ',F10.4) +238 FORMAT (1X,'SIZE IN PIXELS OF SMALLEST COMPONENT : ',I6) +240 FORMAT (1X,'MEAN LENGTH ALONG Y (IN PIXELS) : ',F10.4) +241 FORMAT (1X,'MEAN LENGTH ALONG Z (IN PIXELS) : ',F10.4) +250 FORMAT (1X,'MIMIMUN LENGTH ALONG Y (IN PIXELS) : ',I6) +260 FORMAT (1X,'MAXIMUM LENGTH ALONG Y (IN PIXELS) : ',I6) +251 FORMAT (1X,'MIMIMUN LENGTH ALONG Z (IN PIXELS) : ',I6) +261 FORMAT (1X,'MAXIMUM LENGTH ALONG Z (IN PIXELS) : ',I6) + +270 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN X : ',I6) +280 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Y : ',I6) +281 FORMAT (1X,'NUMBER OF PERCOLATING COMPONENTS IN Z : ',I6) +290 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS : ',A12) +295 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVIY FUNCTION : ',A12) +300 FORMAT (/1X,'CONNECTIVITY FUNCTION'/1X,21('=') + * //1X,'ALONG THE X DIRECTION (1,0,0)') +310 FORMAT (F10.3,F12.6,2I12) +320 FORMAT (/1X,'ALONG THE Y DIRECTION (0,1,0)') +321 FORMAT (/1X,'ALONG THE Z DIRECTION (0,0,1)') +322 FORMAT (/1X,'ALONG THE FIRST 3D DIAGONAL (1,1,1)') +323 FORMAT (/1X,'ALONG THE SECOND 3D DIAGONAL (1,-1,1)') +324 FORMAT (/1X,'ALONG THE THIRD 3D DIAGONAL (-1,-1,1)') +325 FORMAT (/1X,'ALONG THE FOURTH 3D DIAGONAL (-1,1,1)') +327 FORMAT (/1X,'AVERAGE ALONG THE 3D DIAGONALS') +330 FORMAT (/1X,'AVERAGE ALONG X AND Y') +328 FORMAT (/1X,'AVERAGE ALONG X, Y AND Z') +329 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Y PLANE (1,1,0)') +331 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Y PLANE (1,-1,0') +332 FORMAT (/1X,'FIRST DIAGONAL ON THE X-Z PLANE (1,0,1)') +333 FORMAT (/1X,'SECOND DIAGONAL ON THE X-Z PLANE (1,0,-1)') +334 FORMAT (/1X,'FIRST DIAGONAL ON THE Y-Z PLANE (0,1,1)') +335 FORMAT (/1X,'SECOND DIAGONAL ON THE Y-Z PLANE (0,1,-1)') +400 FORMAT (25(/),1X,'CONNEC3D PROGRAM VER. 1.0'/1X,27('=')/// + * 1X,'INPUT PARAMETER FILE ---> ',$) +410 FORMAT (/1X,'OUTPUT FILE WITH STATISTICS AND CONNECTIVITY ' + * 'FUNCTION: ',A12) +420 FORMAT (/1X,'OUTPUT FILE WITH CONNECTED COMPONENTS: ',A12) +425 FORMAT (/1X,'OUTPUT FILE WITH CONNECTIVITY FUNCTION: ',A12) +430 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'6-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +440 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'18-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) +450 FORMAT (1X,'OUTPUT RESULTS OF CONNEC3D'//1X'26-CONNECTIVITY' + * ' ANALYSIS'/1X,'PARAMETER FILE WAS : ',A12//) + END diff --git a/tools/connec/connec-src/ver_original/Connec_ver_original/PHASE3.PAR b/tools/connec/connec-src/ver_original/Connec_ver_original/PHASE3.PAR new file mode 100644 index 0000000..c461cc0 --- /dev/null +++ b/tools/connec/connec-src/ver_original/Connec_ver_original/PHASE3.PAR @@ -0,0 +1,9 @@ +1 WHICH PHASE TO ANALYZE 0 OR 1 +6 6, 18 OR 26-CONNECTIVITY +PHASE3.DAT INDICATOR (0/1) MAP + 100 100 50 NX NY AND NZ + 1.0 1.0 1.0 DX DY AND DZ +30 NUMBER OF LAGS FOR CONNECTIVITY FUNC. +PHASE3.STA OUTPUT FILE CONNECTIVITY STATISTICS +PHASE3.CCO OUTPUT FILE CONNECTED COMPONENTS +PHASE3.COF OUTPUT FILE CONNECTIVITY FUNCTION diff --git a/tools/connec/makefile b/tools/connec/makefile new file mode 100755 index 0000000..14450d8 --- /dev/null +++ b/tools/connec/makefile @@ -0,0 +1,9 @@ +F90:= gfortran +all: conec2d conec3d +conec2d: CONNEC2D.FOR + $(F90) -O3 -o conec2d CONNEC2D.FOR +conec3d: CONNEC3D.FOR + $(F90) -O3 -o conec3d CONNEC3D.FOR +clean: + -rm -f conec2d conec3d + diff --git a/tools/generation/.nfs000000090002213100000011 b/tools/generation/.nfs000000090002213100000011 new file mode 100644 index 0000000..15f2ec0 Binary files /dev/null and b/tools/generation/.nfs000000090002213100000011 differ diff --git a/tools/generation/__init__.py b/tools/generation/__init__.py new file mode 100755 index 0000000..e69de29 diff --git a/tools/generation/__init__.pyc b/tools/generation/__init__.pyc new file mode 100644 index 0000000..8827068 Binary files /dev/null and b/tools/generation/__init__.pyc differ diff --git a/tools/generation/config.py b/tools/generation/config.py new file mode 100755 index 0000000..8f89238 --- /dev/null +++ b/tools/generation/config.py @@ -0,0 +1,78 @@ +import numpy as np +import configparser + +import json + +def get_config(conffile): + + parser = configparser.ConfigParser() + parser.read(conffile) + + cons=json.loads(parser.get('Iterables',"connectivity")) + ps=json.loads(parser.get('Iterables',"p")) + lcs=json.loads(parser.get('Iterables',"lc")) + variances=json.loads(parser.get('Iterables',"variances")) + seeds=json.loads(parser.get('Iterables',"seeds")) + + seeds=np.arange(seeds[0],seeds[1]+seeds[0]) + ps=np.linspace(ps[0],ps[1],ps[2])/100 + + iterables=dict() + iterables['ps'] = ps + iterables['seeds'] = seeds + iterables['lcs'] = lcs + iterables['variances'] = variances + iterables['cons'] = cons + return parser, iterables + + + +def DotheLoop(job,parser,iterables): + + + + + ps = iterables['ps'] + seeds = iterables['seeds'] + lcs = iterables['lcs'] + variances = iterables['variances'] + cons = iterables['cons'] + + if job==-1: + if parser.get('Generation','binary')=='yes': + if 0 not in cons: + njobs=len(ps)*len(cons)*len(seeds)*len(lcs) + else: + njobs=len(ps)*(len(cons)-1)*len(seeds)*len(lcs)+len(ps)*len(seeds) + else: + if 0 not in cons: + njobs=len(variances)*len(cons)*len(seeds)*len(lcs) + else: + njobs=len(variances)*(len(cons)-1)*len(seeds)*len(lcs)+len(variances)*len(seeds) + + return njobs + + i=0 + + for con in cons: + if con == 0: + llcs=[0.000001] + else: + llcs=lcs + for lc in llcs: + if parser.get('Generation','binary')=='yes': + for p in ps: + for seed in seeds: + if i==job: + return [con,lc,p,seed] + i+=1 + + else: + for v in variances: + for seed in seeds: + if i==job: + return [con,lc,v,seed] + i+=1 + return [] + + diff --git a/tools/generation/config.pyc b/tools/generation/config.pyc new file mode 100644 index 0000000..f8fe3a5 Binary files /dev/null and b/tools/generation/config.pyc differ diff --git a/tools/generation/fftma_gen.py b/tools/generation/fftma_gen.py new file mode 100755 index 0000000..ff0df94 --- /dev/null +++ b/tools/generation/fftma_gen.py @@ -0,0 +1,159 @@ +import numpy as np +from scipy.special import erf, erfinv +from scipy.optimize import curve_fit +from scipy.stats import norm +from FFTMA import gen +from config import DotheLoop, get_config +from variograma import get_lc +from scipy.interpolate import interp1d +import sys +import time +import os + + + +def fftmaGenerator(datadir,job,conffile): + + t0=time.time() + parser, iterables = get_config(conffile) + params = DotheLoop(job,parser, iterables ) + + binary=parser.get('Generation','binary') + uselc_bin=parser.get('Generation','lcBin') + + if binary=='yes': + logn='no' + con,lc,p,seed = params[0],params[1],params[2],params[3] + variance=0 + else: + logn='yes' + con,lc,variance,seed = params[0],params[1],params[2],params[3] + p=0 + + + Nx,Ny,Nz = int(parser.get('Generation','Nx')), int(parser.get('Generation','Ny')), int(parser.get('Generation','Nz')) + #N=int(42.666666667*lc) + #Nx,Ny,Nz = N,N,N + #print(N) + + kh,kl,vario = float(parser.get('Generation','kh')),float(parser.get('Generation','kl')), int(parser.get('Generation','variogram_type')) + compute_lc=parser.get('Generation','compute_lc') + generate_K(Nx,Ny,Nz,con,lc,p,kh,kl,seed,logn,variance,vario,datadir,compute_lc,uselc_bin) + + np.savetxt(datadir+'GenParams.txt',np.array([time.time()-t0,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario]),header='Runtime,Nx,Ny,Nz,con,lc,p,kh,kl,seed,variance,vario') + + + return + + +def obtainLctobin(p,con,vario): + + + lc=np.load('./tools/generation/lc.npy',allow_pickle=True, encoding = 'latin1').item() + + f=interp1d(lc['p'],lc[vario,con]) + if p==0 or p==1: + return 1.0 + return 1.0/f(p) + +def obtainLctobinBack(p,con,vario): + + pb=np.linspace(0.0,1.0,11) + + + if vario==2: + i=[0.0, 1.951, 2.142, 2.247, 2.301, 2.317, 2.301, 2.246, 2.142, 1.952, 0.0] + c=[0.0, 1.188, 1.460, 1.730, 2.017, 2.284, 2.497, 2.652, 2.736, 2.689, 0.0] + d=[0.0,2.689, 2.736,2.652, 2.497, 2.284, 2.017, 1.730, 1.460, 1.188, 0.0] + lcBin=np.array([i,c,d]) + lcBin=lcBin/3.0 + + if vario==1: + i=[0.0,3.13, 3.66, 3.94, 4.08, 4.10, 4.01, 3.84, 3.55, 3.00,0.0] + c=[0.0,0.85, 1.095, 1.312, 1.547, 1.762, 1.966, 2.149, 2.257, 2.186,0.0] + d=[0.0,2.186, 2.2575,2.1495,1.9660,1.7625,1.5476,1.3128,1.0950,0.8510,0.0] + lcBin=np.array([i,c,d]) + lcBin=lcBin/6.0 + + f=interp1d(pb,lcBin[con-1]) + return 1.0/f(p) + + + +def generate_K(Nx,Ny,Nz,con,lc,p,kh,kl,seed,logn,LogVariance,vario,datadir,compute_lc,uselc_bin): + + + k=genGaussK(Nx,Ny,Nz,con,lc,p,kh,kl,seed,logn,LogVariance,vario,uselc_bin) + if compute_lc =='yes': + lcG=get_lc(k,vario) + lcNst=lcG + lcBin=np.nan + if con==2: + k = -nst(k) #normal score transform + if compute_lc =='yes': + lcNst=get_lc(k,vario) + if con==3: + k = nst(k) + if compute_lc =='yes': + lcNst=get_lc(k,vario) + + if logn == 'yes': + k=k*(LogVariance**0.5) + k = np.exp(k) + + else: + k = binarize(k,kh,kl,p) + if compute_lc =='yes': + lcBin=get_lc(np.where(k>kl,1,0),vario) + np.save(datadir+'k.npy',k) + if compute_lc =='yes': + np.savetxt(datadir+'lc.txt',np.array([lcG,lcNst,lcBin]),header='lcG, lcNst, lcBin') + return + +def genGaussK(Nx,Ny,Nz,con,lc,p,kh,kl,seed,logn,LogVariance,vario,uselc_bin): + + + typ=0 #structure du champ: 0=normal; 1=lognormal; 2=log-10 + dx, dy, dz = 1.0, 1.0, 1.0 + var=1 #Nbr de structure du variogramme + alpha=1 #valeur exposant + if con==0: + lc=0.000001 + + if (con==2 or con==3) and vario==2: + lc=lc/0.60019978939 + if (con==2 or con==3) and vario==1: + lc=lc/0.38165155120015 + + if uselc_bin=='yes' and con!=0: + lc=lc*obtainLctobin(p,con,vario) + v1 = (var, vario, alpha, lc, lc, lc, 1, 0, 0, 0, 1, 0) # coord des vecteurs de base (1 0 0) y (0 1 0) + k=gen(Nz, Ny, Nx, dx, dy, dz, seed, [v1], 0, 1, 0) # 0, 1, 0 = mean, variance, typ #Generation of a correlated standard dsitribution N(0,1) + + return k + + +def nst(kc): + kc=np.abs(kc) + kc=np.sqrt(2)*erfinv(2*erf(kc/np.sqrt(2))-1) + return kc + + +def binarize(kc,kh,kl,p): + + if kc.size < 100**3: + if p>0: + at=int((1-p)*kc.size) # + else: + at=kc.size-1 + t1=np.sort(kc.reshape(-1))[at] #get permeability treshold + kc=np.where(kc0: + y=(1/dim)*np.log2(nr*kc.size/(nimax*(smin**dim))) + else: + y=0 + y=int(y) + s=int((2**y) * smin) + if s0: + y=(1/dim)*np.log2(nr*kc.size/(nimax*(smin**dim))) + else: + y=0 + y=int(y) + s=int((2**y) * smin) + if s0) and (rank0) and (rank0) and (rank0) and (rank0) and (rank0: + y=(1/dim)*np.log2(nr*kc.size/(nimax*(smin**dim))) + else: + y=0 + y=int(y) + s=int((2**y) * smin) + if s0) and (rank0) and (rank0) and (rank)$' + + folder=j*50+i + + V=np.load(rdir+str(folder)+'/V.npy')[0][:,:,0] + perco=np.load(rdir+str(folder)+'/ConnectivityMetrics/1024.npy',allow_pickle=True).item()['spanning'][0,0,0] + V=np.log10(np.abs(V)) #/np.mean(np.abs(V))) + leg='p = '+str(ps[i])[:4]+'% ('+str(perco)+')' + plot_hist(V,rdir+str(folder)+'/HisTabsV',log,label,-.8,.5,leg) + plotK_imshow(V[512:1536,512:1536],rdir+str(i)+'/V',log,label,-4,1) + plt.legend(loc='upper left') + plt.savefig(rdir+str(folder)+'VelHistogramB.png') + plt.close() +''' + +label=r'$\log_{10}(|v_x|/<|v_x|>)$' +V=np.load(rdir+str(i)+'/V.npy')[0][:,:,0] +V=np.log10(np.abs(V)/np.mean(np.abs(V))) +plot_hist(V,rdir+str(i)+'/HisTabsVx',log,label,-4,1.5) +plotK_imshow(V[1024:2048,512:1024],rdir+str(i)+'/Vx',log,label,0,2) + +label=r'$\log_{10}(|v_y|/<|v_y|>)$' +V=np.load(rdir+str(i)+'/V.npy')[1][:,:,0] +V=np.log10(np.abs(V)/np.mean(np.abs(V))) +plot_hist(V,rdir+str(i)+'/HisTabsVy',log,label,-5,1.5) +plotK_imshow(V[1024:2048,512:1024],rdir+str(i)+'/Vy',log,label,0,1) +#plot_hist(k,rdir+'Res/'+resname,log) + + + +''' + + diff --git a/utilities/plot_lc.py b/utilities/plot_lc.py new file mode 100755 index 0000000..e407dd5 --- /dev/null +++ b/utilities/plot_lc.py @@ -0,0 +1,23 @@ +import numpy as np +import matplotlib.pyplot as plt + + + +rdir='./lc_vslcbin/' +nps=41 +ps=np.linspace(.1,.5,nps) + +clabels=['Intermediate','high','low'] + +for con in range(1): + keff=np.zeros(nps) + for ip in range(nps): + folder=con*nps+ip + keff[ip]=np.loadtxt(rdir+str(folder)+'/lc.txt')[2] + + plt.plot(ps,keff,label=clabels[con]) + +plt.legend() +plt.grid() +plt.savefig('lc2.png') + diff --git a/utilities/plot_val_Kpost.py b/utilities/plot_val_Kpost.py new file mode 100755 index 0000000..5d67b34 --- /dev/null +++ b/utilities/plot_val_Kpost.py @@ -0,0 +1,33 @@ +import numpy as np +import matplotlib.pyplot as plt + + + +rdir='./data/' + + +clabels=[r'$K_{perm}$',r'$K_{diss}$',r'$K_{average}$'] +cases=[r'$Lognormal \ \sigma^{2}_{\log(k)} = 0.1$',r'$Lognormal \ \sigma^{2}_{\log(k)} = 7$', r'$Binary p = 0.2; k+/k- = 10^4$'] + +scales=np.array([4,8,16,32,64,128,256,512]) +lcs=[16,16,8] + +for i in range(3): + + kpost=np.zeros((len(scales),3)) + for scale in range(len(scales)): + kpost[scale,0]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/kperm/'+str(scales[scale])+'.npy')))) + kpost[scale,1]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/KpostProcess/Kd'+str(scales[scale])+'.npy')))) + kpost[scale,2]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/KpostProcess/Kv'+str(scales[scale])+'.npy')))) + plt.semilogx(scales/512.0,kpost[:,0],label=clabels[0],marker='x') + plt.semilogx(scales/512.0,kpost[:,1],label=clabels[1],marker='s') + plt.semilogx(scales/512.0,kpost[:,2],label=clabels[2],marker='^') + plt.vlines(lcs[i]/512.0,kpost[:,0].min(),kpost[:,0].max(),label=r'$lc = $'+str(lcs[i])) + plt.xlabel(r'$\lambda / L$') + plt.ylabel(r'$_G$') + plt.legend() + plt.grid() + plt.title(cases[i]) + plt.tight_layout() + plt.savefig(rdir+str(i)+'/Kpost_mean.png') + plt.close() diff --git a/utilities/plot_val_Kpost_varianve.py b/utilities/plot_val_Kpost_varianve.py new file mode 100755 index 0000000..3f3c4dc --- /dev/null +++ b/utilities/plot_val_Kpost_varianve.py @@ -0,0 +1,44 @@ +import numpy as np +import matplotlib.pyplot as plt +from Var_analytical import * + + +rdir='./data/' + + +clabels=[r'$K_{perm}$',r'$K_{diss}$',r'$K_{average}$',r'$K_{1/3}$','analitycal Gaussian cov'] +cases=[r'$Lognormal \ \sigma^{2}_{\log(k)} = 0.1$',r'$Lognormal \ \sigma^{2}_{\log(k)} = 7$', r'$Binary p = 0.2; k+/k- = 10^4$'] + +scales=np.array([4,8,16,32,64,128]) +variances=[0.1,7,13.572859162824695] +x=scales/512.0 +lcs=[16,16,8] +va=VarLgauss(16/2.45398,scales,3) + +for i in range(3): + + + + kpost=np.zeros((len(scales),4)) + for scale in range(len(scales)): + kpost[scale,0]=np.nanvar(np.log(np.load(rdir+str(i)+'/kperm/'+str(scales[scale])+'.npy')))/variances[i] + kpost[scale,1]=np.nanvar(np.log(np.load(rdir+str(i)+'/KpostProcess/Kd'+str(scales[scale])+'.npy')))/variances[i] + kpost[scale,2]=np.nanvar(np.log(np.load(rdir+str(i)+'/KpostProcess/Kv'+str(scales[scale])+'.npy')))/variances[i] + kpost[scale,3]=np.nanvar(np.log(np.load(rdir+str(i)+'/KpostProcess/Kpo'+str(scales[scale])+'.npy')))/variances[i] + plt.loglog(x,(x**3)*kpost[:,0],label=clabels[0],marker='x') + plt.loglog(x,(x**3)*kpost[:,1],label=clabels[1],marker='s') + plt.loglog(x,(x**3)*kpost[:,2],label=clabels[2],marker='^') + plt.loglog(x,(x**3)*kpost[:,3],label=clabels[3],marker='o') + if i==0 or i==1: + plt.loglog(x,(x**3)*va,label=clabels[4],marker='',linestyle='--') + + plt.vlines(lcs[i]/512.0,((x**3)*kpost[:,0]).min(),((x**3)*kpost[:,0]).max(),label=r'$lc = $'+str(lcs[i])) + plt.xlabel(r'$\lambda / L$') + plt.ylabel(r'$(\lambda / L)^3 \sigma^{2}_{\log(K_{eff})} / \sigma^{2}_{\log(k)}$') + plt.legend() + plt.grid() + plt.title(cases[i]) + plt.tight_layout() + plt.savefig(rdir+str(i)+'/Kpost_var.png') + plt.close() + diff --git a/utilities/plot_val_Kpost_with_power (copy).py b/utilities/plot_val_Kpost_with_power (copy).py new file mode 100755 index 0000000..91f32a5 --- /dev/null +++ b/utilities/plot_val_Kpost_with_power (copy).py @@ -0,0 +1,44 @@ +import numpy as np +import matplotlib.pyplot as plt + + + +rdir='./data/' + + +clabels=[r'$K_{perm}$',r'$K_{diss}$',r'$K_{average}$',r'$K_{1/3}$'] +names=['Kperm','Kdiss','Kaverage','Kpower'] +cases=[r'$Lognormal \ \sigma^{2}_{\log(k)} = 0.1$',r'$Lognormal \ \sigma^{2}_{\log(k)} = 7$', r'$Binary p = 0.2; k+/k- = 10^4$'] + +scales=np.array([4,8,16,32,64]) +lcs=[16,16,8] +est=3 +ranges=[(-0.5,0.5),(-5,5),(-4,4)] +for i in range(3): + + + for scale in range(len(scales)): + if est==0: + keff=np.log(np.load(rdir+str(i)+'/kperm/'+str(scales[scale])+'.npy')) + if est==1: + keff=np.log(np.load(rdir+str(i)+'/KpostProcess/Kd'+str(scales[scale])+'.npy')) + + if est==2: + keff=np.log(np.load(rdir+str(i)+'/KpostProcess/Kv'+str(scales[scale])+'.npy')) + if est==3: + keff=np.log(np.load(rdir+str(i)+'/KpostProcess/Kpo'+str(scales[scale])+'.npy')) + + + plt.hist(keff.reshape(-1),label=r'$\lambda = $'+' ' +str(scales[scale]),density=True,histtype='step',range=ranges[i]) + #plt.semilogx(scales/512.0,kpost[:,1],label=clabels[1],marker='s') + #plt.semilogx(scales/512.0,kpost[:,2],label=clabels[2],marker='^') + #plt.semilogx(scales/512.0,kpost[:,3],label=clabels[3],marker='o') + #plt.vlines(lcs[i]/512.0,kpost[:,0].min(),kpost[:,0].max(),label=r'$lc = $'+str(lcs[i])) + plt.xlabel(r'$\log(K_{eff})$') + plt.ylabel(r'$P(K_{eff})$') + plt.legend() + plt.grid() + plt.title(cases[i]+' '+str(names[est])) + plt.tight_layout() + plt.savefig(rdir+str(i)+'/Kpost_dist_scales_'+names[est]+'.png') + plt.close() diff --git a/utilities/plot_val_Kpost_with_power.py b/utilities/plot_val_Kpost_with_power.py new file mode 100755 index 0000000..e47076b --- /dev/null +++ b/utilities/plot_val_Kpost_with_power.py @@ -0,0 +1,37 @@ +import numpy as np +import matplotlib.pyplot as plt + + + +rdir='./data/' + + +clabels=[r'$K_{perm}$',r'$K_{diss}$',r'$K_{average}$',r'$K_{1/3}$'] +cases=[r'$Lognormal \ \sigma^{2}_{\log(k)} = 0.1$',r'$Lognormal \ \sigma^{2}_{\log(k)} = 7$', r'$Binary p = 0.2; k+/k- = 10^4$'] + +scales=np.array([4,8,16,32,64,128,256,512]) +lcs=[16,16,8] + +for i in range(3): + + kpost=np.zeros((len(scales),4)) + + + for scale in range(len(scales)): + kpost[scale,0]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/kperm/'+str(scales[scale])+'.npy')))) + kpost[scale,1]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/KpostProcess/Kd'+str(scales[scale])+'.npy')))) + kpost[scale,2]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/KpostProcess/Kv'+str(scales[scale])+'.npy')))) + kpost[scale,3]=np.exp(np.nanmean(np.log(np.load(rdir+str(i)+'/KpostProcess/Kpo'+str(scales[scale])+'.npy')))) + plt.semilogx(scales/512.0,kpost[:,0],label=clabels[0],marker='x') + plt.semilogx(scales/512.0,kpost[:,1],label=clabels[1],marker='s') + plt.semilogx(scales/512.0,kpost[:,2],label=clabels[2],marker='^') + plt.semilogx(scales/512.0,kpost[:,3],label=clabels[3],marker='o') + plt.vlines(lcs[i]/512.0,kpost[:,0].min(),kpost[:,0].max(),label=r'$lc = $'+str(lcs[i])) + plt.xlabel(r'$\lambda / L$') + plt.ylabel(r'$_G$') + plt.legend() + plt.grid() + plt.title(cases[i]) + plt.tight_layout() + plt.savefig(rdir+str(i)+'/Kpost_mean.png') + plt.close() diff --git a/utilities/powerLaw.py b/utilities/powerLaw.py new file mode 100755 index 0000000..b4bf6d7 --- /dev/null +++ b/utilities/powerLaw.py @@ -0,0 +1,43 @@ +import numpy as np + + + +def power_aver(kf,scales,pot,datadir): + + + keff=np.zeros((len(scales),2)) + + for s in range(len(scales)): + l=scales[s] + lz=scales[s] + + nbx, nby, nbz= kf.shape[0]//l, kf.shape[1]//l,kf.shape[2]//l, + if nbz==0: + nbz=1 + lz=1 + + res=np.zeros((nbx,nby,nbz)) + + for i in range(nbx): + for j in range(nby): + for k in range(nbz): + + res[i,j,k]=np.mean(kf[i*l:(i+1)*l,j*l:(j+1)*l,k*lz:(k+1)*lz]**(1.0/pot))**(pot) + + keff[s,0]=np.exp(np.mean(np.log(res))) + keff[s,01]=np.var(np.log(res)) + np.save(datadir+'KpostProcess/Kpo'+str(scales[s])+'.npy',res) + return keff + + +rdir='./data/' + + + +scales=np.array([4,8,16,32,64,128,256,512]) + +for i in range(3): + + kf=np.load(rdir+str(i)+'/k.npy') + kpower=power_aver(kf,scales,3,rdir+str(i)+'/') + diff --git a/utilities/powerLaw.pyc b/utilities/powerLaw.pyc new file mode 100644 index 0000000..7f2c145 Binary files /dev/null and b/utilities/powerLaw.pyc differ