Prev Next

@(@\newcommand{\W}[1]{ \; #1 \; } \newcommand{\R}[1]{ {\rm #1} } \newcommand{\B}[1]{ {\bf #1} } \newcommand{\D}[2]{ \frac{\partial #1}{\partial #2} } \newcommand{\DD}[3]{ \frac{\partial^2 #1}{\partial #2 \partial #3} } \newcommand{\Dpow}[2]{ \frac{\partial^{#1}}{\partial {#2}^{#1}} } \newcommand{\dpow}[2]{ \frac{ {\rm d}^{#1}}{{\rm d}\, {#2}^{#1}} }@)@
abs_normal: Evaluate First Order Approximation

Syntax
g_tilde = abs_eval(nmsg_hatg_jacdelta_x)

Prototype

template <class Vector>
Vector abs_eval(
     size_t        n       ,
     size_t        m       ,
     size_t        s       ,
     const Vector& g_hat   ,
     const Vector& g_jac   ,
     const Vector& delta_x )

Source
This following is a link to the source code for this example: abs_eval.hpp .

Purpose
Given a current that abs-normal representation at a point @(@ \hat{x} \in \B{R}^n @)@, and a @(@ \Delta x \in \B{R}^n @)@, this routine evaluates the abs-normal approximation for f(x) where @(@ x = \hat{x} + \Delta x @)@.

Vector
The type Vector is a simple vector with elements of type double.

f
We use the notation f for the original function; see f .

n
This is the dimension of the domain space for f ; see n .

m
This is the dimension of the range space for f ; see m .

s
This is the number of absolute value terms in f ; see

g
We use the notation g for the abs-normal representation of f ; see g .

g_hat
This vector has size m + s and is the value of g(x, u) at @(@ x = \hat{x} @)@ and @(@ u = a( \hat{x} ) @)@.

g_jac
This vector has size (m + s) * (n + s) and is the Jacobian of @(@ g(x, u) @)@ at @(@ x = \hat{x} @)@ and @(@ u = a( \hat{x} ) @)@.

delta_x
This vector has size n and is the difference @(@ \Delta x = x - \hat{x} @)@, where @(@ x @)@ is the point that we are approximating @(@ f(x) @)@.

g_tilde
This vector has size m + s and is a the first order approximation for g that corresponds to the point @(@ x = \hat{x} + \Delta x @)@ and @(@ u = a(x) @)@.

Example
The file abs_eval.cpp contains an example and test of abs_eval. It returns true if the test passes and false otherwise.
Input File: example/abs_normal/abs_eval.hpp