23 sprintf(filename,
"%srho_restart.tyc",
output_dir);
24 fd = fopen(filename,
"wb");
26 printf(
"-----------------------------------\n");
27 printf(
"The output directory does not exist\n");
28 printf(
"-----------------------------------\n");
32 fseek(fd, 200, SEEK_SET);
33 for (i = 0; i <
x; i++) {
34 for (j = 0; j <
y; j++) {
35 for (k = 0; k <
z; k++) {
38 printf(
"NaN in density array %i %i %i\n", i, j, k);
41 fwrite(&tmp, 1,
sizeof (
double), fd);
48 sprintf(filename,
"%stemp_restart.tyc",
output_dir);
49 fd = fopen(filename,
"wb");
51 fseek(fd, 200, SEEK_SET);
52 for (i = 0; i <
x; i++) {
53 for (j = 0; j <
y; j++) {
54 for (k = 0; k <
z; k++) {
57 printf(
"NaN in temperature array %i %i %i\n", i, j, k);
60 fwrite(&tmp, 1,
sizeof (
double), fd);
66 sprintf(filename,
"%svel_restart.tyc",
output_dir);
67 fd = fopen(filename,
"wb");
69 fseek(fd, 200, SEEK_SET);
70 for (i = 0; i <
x; i++) {
71 for (j = 0; j <
y; j++) {
72 for (k = 0; k <
z; k++) {
74 fwrite(&tmp, 1,
sizeof (
double), fd);
76 fwrite(&tmp, 1,
sizeof (
double), fd);
78 fwrite(&tmp, 1,
sizeof (
double), fd);
85 sprintf(filename,
"%sdom_restart.tyc",
output_dir);
86 fd = fopen(filename,
"wb");
88 fseek(fd, 200, SEEK_SET);
89 for (i = 0; i <
x; i++) {
90 for (j = 0; j <
y; j++) {
91 for (k = 0; k <
z; k++) {
94 printf(
"NaN in dom array %i %i %i\n", i, j, k);
97 fwrite(&tmp1, 1,
sizeof (
int), fd);
105 sprintf(filename,
"%ssound_emitter_restart.tyc",
output_dir);
106 fd = fopen(filename,
"wb");
108 fseek(fd, 200, SEEK_SET);
109 for (i = 0; i <
x; i++) {
110 for (j = 0; j <
y; j++) {
111 for (k = 0; k <
z; k++) {
114 printf(
"NaN in sound_emitter array %i %i %i\n", i, j, k);
117 fwrite(&tmp1, 1,
sizeof (
int), fd);
123 sprintf(filename,
"%spressure_integrated_restart.tyc",
output_dir);
124 fd = fopen(filename,
"wb");
126 fseek(fd, 200, SEEK_SET);
127 for (i = 0; i <
x; i++) {
128 for (j = 0; j <
y; j++) {
129 for (k = 0; k <
z; k++) {
132 printf(
"NaN in spressure_integrated_restart array %i %i %i\n", i, j, k);
135 fwrite(&tmp, 1,
sizeof (
double), fd);
144 sprintf(filename,
"%smarker_restart.tyc",
output_dir);
145 fd = fopen(filename,
"wb");
147 fseek(fd, 200, SEEK_SET);
148 for (i = 0; i <
x; i++) {
149 for (j = 0; j <
y; j++) {
150 for (k = 0; k <
z; k++) {
153 printf(
"NaN in marker array %i %i %i\n", i, j, k);
156 fwrite(&tmp, 1,
sizeof (
double), fd);
166 sprintf(filename,
"%swind_restart.tyc",
output_dir);
167 fd = fopen(filename,
"wb");
169 fseek(fd, 200, SEEK_SET);
170 for (i = 0; i <
x; i++) {
171 for (j = 0; j <
y; j++) {
172 for (k = 0; k <
z; k++) {
175 printf(
"NaN in wind marker array %i %i %i\n", i, j, k);
178 fwrite(&tmp, 1,
sizeof (
double), fd);