Overview
Comment:Further fixes to make nonlinear PPP work ...
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | origin/master | trunk
Files: files | file ages | folders
SHA3-256: 2a772279a110cbc2171fc9199bc3038a62bf9a2d72092869edee8634243ceb8f
User & Date: gawthrop@users.sourceforge.net on 2001-06-06 07:54:38
Other Links: branch diff | manifest | tags
Context
2001-06-11
15:06:58
Now handles user-defined components check-in: 192ab17f96 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
2001-06-06
07:54:38
Further fixes to make nonlinear PPP work ... check-in: 2a772279a1 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
07:53:07
Now generates x vector correctly check-in: 7728816dd1 user: gawthrop@users.sourceforge.net tags: origin/master, trunk
Changes

Modified mttroot/mtt/lib/control/PPP/ppp_optimise.m from [b7facdcf98] to [7c6d6441ee].

1
2
3
4
5
6
7
8
9
10
11
function [par,Par,Error,Y,iterations] = \
      ppp_optimise(system_name,x_0,par_0,simpar,u,y_0,free,extras);
  ## Levenberg-Marquardt optimisation for PPP/MTT
  ## Usage: [par,Par,Error,Y,iterations] = ppp_optimise(system_name,x_0,par_0,simpar,u,y_0,free[,extras]);
  ##  system_name     String containing system name
  ##  x_0             Initial state
  ##  par_0           Initial parameter vector estimate
  ##  simpar          Simulation parameters:
  ##        .first      first time
  ##        .dt         time increment
  ##        .stepfactor Euler integration step factor
|


|







1
2
3
4
5
6
7
8
9
10
11
function [par,Par,Error,Y,iterations,x] = \
      ppp_optimise(system_name,x_0,par_0,simpar,u,y_0,free,extras);
  ## Levenberg-Marquardt optimisation for PPP/MTT
  ## Usage: [par,Par,Error,Y,iterations,x] = ppp_optimise(system_name,x_0,par_0,simpar,u,y_0,free[,extras]);
  ##  system_name     String containing system name
  ##  x_0             Initial state
  ##  par_0           Initial parameter vector estimate
  ##  simpar          Simulation parameters:
  ##        .first      first time
  ##        .dt         time increment
  ##        .stepfactor Euler integration step factor
24
25
26
27
28
29
30



31
32
33
34
35
36
37
  ######################################
  
  ###############################################################
  ## Version control history
  ###############################################################
  ## $Id$
  ## $Log$



  ## Revision 1.3  2001/04/05 11:50:12  gawthrop
  ## Tidied up documentation + verbose mode
  ##
  ## Revision 1.2  2001/04/04 08:36:25  gawthrop
  ## Restuctured to be more logical.
  ## Data is now in columns to be compatible with MTT.
  ##







>
>
>







24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
  ######################################
  
  ###############################################################
  ## Version control history
  ###############################################################
  ## $Id$
  ## $Log$
  ## Revision 1.4  2001/05/26 15:46:38  gawthrop
  ## Updated to account for new nonlinear ppp
  ##
  ## Revision 1.3  2001/04/05 11:50:12  gawthrop
  ## Tidied up documentation + verbose mode
  ##
  ## Revision 1.2  2001/04/04 08:36:25  gawthrop
  ## Restuctured to be more logical.
  ## Data is now in columns to be compatible with MTT.
  ##
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
  
  while (abs(reduction)>extras.criterion)&&\
	(abs(error)>extras.criterion)&&\
	(iterations<extras.max_iterations)

    iterations = iterations + 1; # Increment iteration counter

    [y,y_par] = eval(sim_command); # Simulate
    [N_data,N_y] = size(y);

    if (N_y!=n_y)
      mess = sprintf("n_y (%i) in data not same as n_y (%i) in model", n_y,N_y);
      error(mess);
    endif
    







|







96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
  
  while (abs(reduction)>extras.criterion)&&\
	(abs(error)>extras.criterion)&&\
	(iterations<extras.max_iterations)

    iterations = iterations + 1; # Increment iteration counter

    [y,y_par,x] = eval(sim_command); # Simulate
    [N_data,N_y] = size(y);

    if (N_y!=n_y)
      mess = sprintf("n_y (%i) in data not same as n_y (%i) in model", n_y,N_y);
      error(mess);
    endif
    


MTT: Model Transformation Tools
GitHub | SourceHut | Sourceforge | Fossil RSS ]