Page Menu
Home
c4science
Search
Configure Global Search
Log In
Files
F96959785
o_set_start.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
Wed, Jan 1, 03:08
Size
1 KB
Mime Type
text/x-c
Expires
Fri, Jan 3, 03:08 (1 d, 23 h)
Engine
blob
Format
Raw Data
Handle
23226315
Attached To
R1448 Lenstool-HPC
o_set_start.c
View Options
#include<stdio.h>
#include<math.h>
#include<fonction.h>
#include<constant.h>
#include<dimension.h>
#include<structure.h>
/****************************************************************/
/* nom: o_set_start */
/* auteur: Jean-Paul Kneib */
/* date: 10/02/92 */
/* place: Toulouse */
/****************************************************************/
/* Set the starting values of each parameter for the lens i according
* to the limits settings in the parameters file */
void o_set_start(int i, int block[NLMAX][NPAMAX])
{
extern struct ipot ip;
double a, b, lmin, lmax, x;
int ipx;
for ( ipx = 0; ipx < ip.pmax ; ipx++ )
{
if ( block[i][ipx] > 0 )
{
lmin = o_get_lmin(i, ipx);
lmax = o_get_lmax(i, ipx);
a = ( lmin * 2. + lmax ) / 3.;
b = ( lmin + 2. * lmax ) / 3.;
x = o_get_lens(i, ipx);
x = Min(b, x);
x = Max(a, x);
o_set_lens( i, ipx, x );
}
}
}
Event Timeline
Log In to Comment