Home > matlab > acado > packages > +acado > @OptimizationAlgorithm > OptimizationAlgorithm.m

OptimizationAlgorithm

PURPOSE ^

User-interface to formulate and solve optimal control problems and static NLPs.

SYNOPSIS ^

This is a script file.

DESCRIPTION ^

User-interface to formulate and solve optimal control problems and static NLPs. 

  Usage:
    >> OptimizationAlgorithm(ocp);

  Parameters:
    ocp         link to an OCP object                 [acado.OCP]

  Example:
    >> ocp = acado.OCP(0.0, 1.0, 20);
    >> algo = acado.OptimizationAlgorithm(ocp);   

  See also:
    acado.OptimizationAlgorithm.initializeDifferentialStates
    acado.OptimizationAlgorithm.initializeAlgebraicStates
    acado.OptimizationAlgorithm.initializeControls
    acado.OptimizationAlgorithm.initializeParameters
    acado.OptimizationAlgorithm.initializeDisturbances
    acado.OptimizationAlgorithm.set


  Licence:
    This file is part of ACADO Toolkit  - (http://www.acadotoolkit.org/)

    ACADO Toolkit -- A Toolkit for Automatic Control and Dynamic Optimization.
    Copyright (C) 2008-2009 by Boris Houska and Hans Joachim Ferreau, K.U.Leuven.
    Developed within the Optimization in Engineering Center (OPTEC) under
    supervision of Moritz Diehl. All rights reserved.

    ACADO Toolkit is free software; you can redistribute it and/or
    modify it under the terms of the GNU Lesser General Public
    License as published by the Free Software Foundation; either
    version 3 of the License, or (at your option) any later version.

    ACADO Toolkit is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
    Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public
    License along with ACADO Toolkit; if not, write to the Free Software
    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA

    Author: David Ariens
    Date: 2009

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SUBFUNCTIONS ^

SOURCE CODE ^

0001 %User-interface to formulate and solve optimal control problems and static NLPs.
0002 %
0003 %  Usage:
0004 %    >> OptimizationAlgorithm(ocp);
0005 %
0006 %  Parameters:
0007 %    ocp         link to an OCP object                 [acado.OCP]
0008 %
0009 %  Example:
0010 %    >> ocp = acado.OCP(0.0, 1.0, 20);
0011 %    >> algo = acado.OptimizationAlgorithm(ocp);
0012 %
0013 %  See also:
0014 %    acado.OptimizationAlgorithm.initializeDifferentialStates
0015 %    acado.OptimizationAlgorithm.initializeAlgebraicStates
0016 %    acado.OptimizationAlgorithm.initializeControls
0017 %    acado.OptimizationAlgorithm.initializeParameters
0018 %    acado.OptimizationAlgorithm.initializeDisturbances
0019 %    acado.OptimizationAlgorithm.set
0020 %
0021 %
0022 %  Licence:
0023 %    This file is part of ACADO Toolkit  - (http://www.acadotoolkit.org/)
0024 %
0025 %    ACADO Toolkit -- A Toolkit for Automatic Control and Dynamic Optimization.
0026 %    Copyright (C) 2008-2009 by Boris Houska and Hans Joachim Ferreau, K.U.Leuven.
0027 %    Developed within the Optimization in Engineering Center (OPTEC) under
0028 %    supervision of Moritz Diehl. All rights reserved.
0029 %
0030 %    ACADO Toolkit is free software; you can redistribute it and/or
0031 %    modify it under the terms of the GNU Lesser General Public
0032 %    License as published by the Free Software Foundation; either
0033 %    version 3 of the License, or (at your option) any later version.
0034 %
0035 %    ACADO Toolkit is distributed in the hope that it will be useful,
0036 %    but WITHOUT ANY WARRANTY; without even the implied warranty of
0037 %    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
0038 %    Lesser General Public License for more details.
0039 %
0040 %    You should have received a copy of the GNU Lesser General Public
0041 %    License along with ACADO Toolkit; if not, write to the Free Software
0042 %    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
0043 %
0044 %    Author: David Ariens
0045 %    Date: 2009
0046 %
0047 classdef OptimizationAlgorithm < acado.OptimizationAlgorithmBase    
0048     properties(SetAccess='protected')
0049 
0050     end
0051     
0052     methods
0053         function obj = OptimizationAlgorithm(varargin)
0054 
0055             global ACADO_;
0056             ACADO_.count_optalgo = ACADO_.count_optalgo+1;
0057             obj.name = strcat(obj.name, num2str(ACADO_.count_optalgo));
0058             
0059             if (nargin == 1 && isa(varargin{1}, 'acado.OCP') )
0060                 obj.ocp = varargin{1};   
0061             end
0062 
0063             ACADO_.helper.addInstruction(obj);
0064             
0065         end
0066         
0067         getInstructions(obj, cppobj, get)
0068 
0069         
0070     end
0071     
0072 end
0073

www.acadotoolkit.org/matlab
Generated on Tue 01-Jun-2010 20:14:12 by m2html © 2005