Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F96784522
o_keepz_min.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
Mon, Dec 30, 20:10
Size
1 KB
Mime Type
text/x-c
Expires
Wed, Jan 1, 20:10 (2 d)
Engine
blob
Format
Raw Data
Handle
23226400
Attached To
R1448 Lenstool-HPC
o_keepz_min.c
View Options
#include<stdio.h>
#include<math.h>
#include<fonction.h>
#include<constant.h>
#include<dimension.h>
#include<structure.h>
/****************************************************************/
/* nom: o_keepz_min */
/* auteur: Jean-Paul Kneib */
/* date: 10/02/92 */
/* place: Toulouse */
/****************************************************************
* In the zm_limit optimisation context :
* ------------------------------------
* - Modify the global variables x1min,x2min,y1min and y2min to keep
* in memory the min and max Khi2 positions.
* - In case of modification of any of those variables, assign to
* the global variable izmin, the id of the zm_limit source.
*/
void
o_keepz_min
(
double
x1
,
double
x2
,
double
y1
,
double
y2
,
int
iz
)
{
extern
double
x1min
,
x1max
,
y1min
,
y1max
;
extern
double
x2min
,
x2max
,
y2min
,
y2max
;
extern
int
izmin
,
izmax
;
extern
int
ipmin
,
ipmax
;
extern
int
ilsmin
,
ilsmax
;
// extern struct z_lim zlim[];
if
((
y1
<
y1min
)
||
(
y2
<
y1min
))
{
ipmin
=
-
1
;
ilsmin
=
-
1
;
izmin
=
iz
;
if
(
y1
<
y2
)
{
x1min
=
x1
;
y1min
=
y1
;
x2min
=
x2
;
y2min
=
y2
;
}
else
{
x1min
=
x2
;
y1min
=
y2
;
x2min
=
x1
;
y2min
=
y1
;
};
}
else
if
((
y1
>
y1max
)
||
(
y2
>
y1max
))
{
ipmax
=
-
1
;
ilsmax
=
-
1
;
izmax
=
iz
;
if
(
y1
<
y2
)
{
x1max
=
x2
;
y1max
=
y2
;
x2max
=
x1
;
y2max
=
y1
;
}
else
{
x1max
=
x1
;
y1max
=
y1
;
x2max
=
x2
;
y2max
=
y2
;
};
}
/*
else
{ zlim[izmax].excu=.2; zlim[izmax].excd=.2; };
*/
}
Event Timeline
Log In to Comment