Commit 469a2839 authored by robin.requadt's avatar robin.requadt
Browse files

Upload New File

parent eda994db
"""
function [Fx1, method_input] = GRAAL_F(x, method_input)
% GRAAL_F.m
% written on Aug 18, 2017 by
% Russell Luke
% Inst. Fuer Numerische und Angewandte Mathematik
% Universitaet Goettingen
%
% DESCRIPTION: user-friendly version of Malitskyi's Golden-Ratio algorithm
%
%
% INPUT: u, an array, and method_input, a data structure
%
% OUTPUT: method_input, an appended data structure with
% xnew = the algorithm fixed point
%
% USAGE: [xnew, method_input] = GRAAL_F(x, method_input)
%
% Nonstandard Matlab function calls: method_input.Prox1 and .Prox2
%
% ---
% Golden Ratio Algorithm for the problem x = Tx
%
% T is the operator
% J is the energy which we want to check, like |x-x*|
% x0 is the starting point
%
% ---
"""
from .SimpleAlgortihm import SimpleAlgorithm
import numpy as np
from numpy import exp
from proxtoolbox import ProxOperators
from .proxoperators import ProxOperator
class GRAAL_F(SimpleAlgorithm):
def __init__(self,config):
"""
Parameters
----------
config : dict
Dictionary containing the problem configuration.
It must contain the following mapping:
T : a Proxoperator
"""
self.T = config['T']
def evaluate(self, x):
T = self.T
Fx1 = x - T.work(x)
xnew = Fx1
return xnew
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment