% @(#)replacfunc.hlq	19.1 (ESO-IPG) 02/25/03 13:19:18 
%++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
%.COPYRIGHT  (c)  1990 European Southern Observatory
%.IDENT      replacfunc.hlq
%.AUTHOR     PhD,, IPG/ESO
%.KEYWORDS   MIDAS, help files, REPLACE/FUNCTION
%.PURPOSE    On-line help file for the command: REPLACE/FUNCTION
%.VERSION    1.0  07-JULY-1986 : Creation, PhD,
%----------------------------------------------------------------
\se
SECTION./FUNC
\es\co
REPLACE/FUNCTION					07-JULY-1986   PhD, JDP
\oc\su
REPLACE/FUNCTION fun1[,fun2...]
	replace user functions for fitting
\us\pu
Purpose:      
              Replace user function(s) to be used by fitting package.
              This command has to be used after CREATE/FUNCTION when
              a modification is needed in the user defined function.
              The defined functions are coded in FORTRAN in files
              user00.for to user09.for.
              The command
\\            - compiles the functions,
\\            - links the corresponding system primitives in the user work area,
\\            - sets a system flag to execute the user version of the
                primitives.
\\            The defined functions can be used in the EDIT/FIT command.
\up\sy
Syntax:       
              REPLACE/FUNCTION fun1[,fun2...]
\ys\pa
              fun1[,fun2...]   = function names as user00, ... user09
\ap\no
Note:         
              User functions are coded as subroutines with the following
              arguments:\\
\\
              SUBROUTINE user0i(N, X, NP, P, Y, DY)\\
              input arguments are :\\
              N      integer   no. of independent variables\\
              X(N)   real      array with the values of the independent vars.\\
              NP     integer   no. of parameters\\
              P(NP)  double precision  array with the values of the parameters\\
              output arguments are :\\
              Y      double precision  output value of the function\\
              DY(NP) double precision  array with the values of the function
                               derivatives with respect to each parameter.
\\
              IMPORTANT: The name of these files user0i.for HAS to be in
              lowercase.
\on\exs
Examples:
\ex
              CREATE/FUNCTION user00,user03
              includes in the system the functions defined in the
              FORTRAN sources user00.for and user03.for
              after modifications in user03.for, the command
              REPLACE/FUNCTION user03
              replaces in the system this function.
\xe\sxe
