001/*
002 * Licensed to the Apache Software Foundation (ASF) under one or more
003 * contributor license agreements.  See the NOTICE file distributed with
004 * this work for additional information regarding copyright ownership.
005 * The ASF licenses this file to You under the Apache License, Version 2.0
006 * (the "License"); you may not use this file except in compliance with
007 * the License.  You may obtain a copy of the License at
008 *
009 *      http://www.apache.org/licenses/LICENSE-2.0
010 *
011 * Unless required by applicable law or agreed to in writing, software
012 * distributed under the License is distributed on an "AS IS" BASIS,
013 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
014 * See the License for the specific language governing permissions and
015 * limitations under the License.
016 */
017
018package org.apache.commons.math3.optimization.general;
019
020/**
021 * Available choices of update formulas for the β parameter
022 * in {@link NonLinearConjugateGradientOptimizer}.
023 * <p>
024 * The &beta; parameter is used to compute the successive conjugate
025 * search directions. For non-linear conjugate gradients, there are
026 * two formulas to compute &beta;:
027 * <ul>
028 *   <li>Fletcher-Reeves formula</li>
029 *   <li>Polak-Ribi&egrave;re formula</li>
030 * </ul>
031 * On the one hand, the Fletcher-Reeves formula is guaranteed to converge
032 * if the start point is close enough of the optimum whether the
033 * Polak-Ribi&egrave;re formula may not converge in rare cases. On the
034 * other hand, the Polak-Ribi&egrave;re formula is often faster when it
035 * does converge. Polak-Ribi&egrave;re is often used.
036 * <p>
037 * @see NonLinearConjugateGradientOptimizer
038 * @deprecated As of 3.1 (to be removed in 4.0).
039 * @since 2.0
040 */
041@Deprecated
042public enum ConjugateGradientFormula {
043
044    /** Fletcher-Reeves formula. */
045    FLETCHER_REEVES,
046
047    /** Polak-Ribi&egrave;re formula. */
048    POLAK_RIBIERE
049
050}