Muller
sample Muller's potential
|
Muller's potential function. More...
#include <config.h>
#include <stdlib.h>
#include <stdio.h>
#include <inttypes.h>
#include <math.h>
#include <assert.h>
#include <jwsc/base/error.h>
#include <jwsc/matrix/matrix.h>
#include "potential.h"
Go to the source code of this file.
Defines | |
#define | ERR_BUF_LEN 256 |
Functions | |
mullers_potential | |
Computes Muller's potential. | |
Error * | mullers_potential_f (float *V_out, float x, float y) |
Calculates Muller's potential with single precision. | |
Error * | mullers_potential_d (double *V_out, double x, double y) |
Calculates Muller's potential with double precision. | |
grad_mullers_potential | |
Calculates the gradient of Muller's potential. | |
Error * | grad_mullers_potential_f (float *dx_V_out, float *dy_V_out, float x, float y) |
Calculates the gradient of Muller's potential with single precision. | |
Error * | grad_mullers_potential_d (double *dx_V_out, double *dy_V_out, double x, double y) |
Calculates the gradient of Muller's potential with double precision. | |
grad_matrix_mullers_potential | |
Calculates the gradient matrix of Muller's potential. | |
Error * | grad_matrix_mullers_potential_d (Matrix_d **gg_out, double x, double y) |
Calculates the gradient matrix of Muller's potential. | |
hessian_mullers_potential | |
Calculates the Hessian matrix of Muller's potential. | |
Error * | hessian_mullers_potential_f (Matrix_f **H_V_out, float x, float y) |
Calculates the Hessian matrix of Muller's potential with single precision. | |
Error * | hessian_mullers_potential_d (Matrix_d **H_V_out, double x, double y) |
Calculates the Hessian matrix of Muller's potential with single precision. | |
Variables | |
static const float | A [4] = {-200.0f, -100.0f, -170.0f, 15.0f} |
Constant A in Muller's potential function. | |
static const float | a [4] = {-1.0f, -1.0f, -6.5f, 0.7f} |
Constant a in Muller's potential function. | |
static const float | b [4] = {0.0f, 0.0f, 11.0f, 0.6f} |
Constant b in Muller's potential function. | |
static const float | c [4] = {-10.0f, -10.0f, -6.5f, 0.7f} |
Constant c in Muller's potential function. | |
static const float | X [4] = {1.0f, 0.0f, -0.5f, -1.0f} |
Constant X in Muller's potential function. | |
static const float | Y [4] = {0.0f, 0.5f, 1.5f, 1.0f} |
Constant Y in Muller's potential function. | |
static char | err_buf [ERR_BUF_LEN] = {0} |
Error buffer. |
#define ERR_BUF_LEN 256 |
Definition at line 60 of file potential.c.
Error* mullers_potential_f | ( | float * | V_out, |
float | x, | ||
float | y | ||
) |
Calculates Muller's potential with single precision.
V_out | Result parameter. Muller's potential evaluated at x,y. |
x | Input to evaluate Muller's potential at. |
y | Input to evaluate Muller's potential at. |
Definition at line 106 of file potential.c.
Error* mullers_potential_d | ( | double * | V_out, |
double | x, | ||
double | y | ||
) |
Calculates Muller's potential with double precision.
V_out | Result parameter. Muller's potential evaluated at x,y. |
x | Input to evaluate Muller's potential at. |
y | Input to evaluate Muller's potential at. |
Definition at line 144 of file potential.c.
Error* grad_mullers_potential_f | ( | float * | dx_V_out, |
float * | dy_V_out, | ||
float | x, | ||
float | y | ||
) |
Calculates the gradient of Muller's potential with single precision.
dx_V_out | Result parameter. Partial derivative of Muller's potential w.r.t. x. |
dy_V_out | Result parameter. Partial derivative of Muller's potential w.r.t. y. |
x | Input to evaluate the partial derivative of Muller's potential w.r.t. x at. |
y | Input to evaluate the partial derivative of Muller's potential w.r.t. y at. |
Definition at line 199 of file potential.c.
Error* grad_mullers_potential_d | ( | double * | dx_V_out, |
double * | dy_V_out, | ||
double | x, | ||
double | y | ||
) |
Calculates the gradient of Muller's potential with double precision.
dx_V_out | Result parameter. Partial derivative of Muller's potential w.r.t. x. |
dy_V_out | Result parameter. Partial derivative of Muller's potential w.r.t. y. |
x | Input to evaluate the partial derivative of Muller's potential w.r.t. x at. |
y | Input to evaluate the partial derivative of Muller's potential w.r.t. y at. |
Definition at line 259 of file potential.c.
Calculates the gradient matrix of Muller's potential.
gg_out | Result parameter. Partial derivatives of Muller's potential in a matrix. |
x | Input to evaluate the partial derivative of Muller's potential w.r.t. x at. |
y | Input to evaluate the partial derivative of Muller's potential w.r.t. y at. |
Definition at line 333 of file potential.c.
Calculates the Hessian matrix of Muller's potential with single precision.
H_V_out | Result parameter. Hessian matrix: second order partial derivatives of Muller's potential. |
x | Input to evaluate the partial derivative of Muller's potential w.r.t. x at. |
y | Input to evaluate the partial derivative of Muller's potential w.r.t. y at. |
Definition at line 393 of file potential.c.
Calculates the Hessian matrix of Muller's potential with single precision.
H_V_out | Result parameter. Hessian matrix: second order partial derivatives of Muller's potential. |
x | Input to evaluate the partial derivative of Muller's potential w.r.t. x at. |
y | Input to evaluate the partial derivative of Muller's potential w.r.t. y at. |
Definition at line 473 of file potential.c.
const float A[4] = {-200.0f, -100.0f, -170.0f, 15.0f} [static] |
Constant A in Muller's potential function.
Definition at line 64 of file potential.c.
const float a[4] = {-1.0f, -1.0f, -6.5f, 0.7f} [static] |
Constant a in Muller's potential function.
Definition at line 68 of file potential.c.
const float b[4] = {0.0f, 0.0f, 11.0f, 0.6f} [static] |
Constant b in Muller's potential function.
Definition at line 72 of file potential.c.
const float c[4] = {-10.0f, -10.0f, -6.5f, 0.7f} [static] |
Constant c in Muller's potential function.
Definition at line 76 of file potential.c.
const float X[4] = {1.0f, 0.0f, -0.5f, -1.0f} [static] |
Constant X in Muller's potential function.
Definition at line 80 of file potential.c.
const float Y[4] = {0.0f, 0.5f, 1.5f, 1.0f} [static] |
Constant Y in Muller's potential function.
Definition at line 84 of file potential.c.
char err_buf[ERR_BUF_LEN] = {0} [static] |
Error buffer.
Definition at line 88 of file potential.c.