Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F97280690
grid.c
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Award Token
Subscribers
None
File Metadata
Details
File Info
Storage
Attached
Created
Sat, Jan 4, 00:32
Size
1 KB
Mime Type
text/x-c
Expires
Mon, Jan 6, 00:32 (2 d)
Engine
blob
Format
Raw Data
Handle
23371169
Attached To
R1448 Lenstool-HPC
grid.c
View Options
#include<stdio.h>
#include<math.h>
#include<fonction.h>
#include<constant.h>
#include<dimension.h>
#include<structure.h>
/****************************************************************/
/* nom: grid */
/* auteur: Jean-Paul Kneib */
/* date: 10/02/92 */
/* place: Toulouse
* Initialize the gimage global variable in a rectangular shape.
* gimage is defined with G.ngrid^2 (number in grille section)
* coordinates that map the field of study defined in the champ
* section.
*
***************************************************************/
void
grid
()
{
const
extern
struct
g_mode
M
;
const
extern
struct
g_grille
G
;
const
extern
struct
g_frame
F
;
extern
struct
point
gimage
[
NGGMAX
][
NGGMAX
];
double
I
,
J
,
N
;
register
int
i
,
j
;
NPRINTF
(
stderr
,
"SET: Grid XY %dx%d
\n
"
,
G
.
ngrid
,
G
.
ngrid
);
for
(
i
=
0
;
i
<
G
.
ngrid
;
i
++
)
for
(
j
=
0
;
j
<
G
.
ngrid
;
j
++
)
{
I
=
i
;
J
=
j
;
N
=
G
.
ngrid
-
1
;
I
=
I
/
N
;
J
=
J
/
N
;
gimage
[
i
][
j
].
x
=
F
.
xmin
+
I
*
(
F
.
xmax
-
F
.
xmin
);
gimage
[
i
][
j
].
y
=
F
.
ymin
+
J
*
(
F
.
ymax
-
F
.
ymin
);
};
}
Event Timeline
Log In to Comment