|
American-transaction costs 1.0.0.0
American option pricer under proportional transaction costs
|
#include "config.h"#include "piecewiselinear/piecewiselinear.h"#include "spot.h"#include "portfolio.h"Go to the source code of this file.
Functions | |
| void | ensure_solvent (PiecewiseLinear &portfolios, const Spot &spot) |
| void | include_solvent_portfolios (PiecewiseLinear &portfolios, const Spot &spot) |
| PiecewiseLinear | portfolios_that_can_afford (const Portfolio &portfolio, const Spot &spot) |
| int | soluble (const Portfolio &portfolio, const Spot &spot) |
| PiecewiseLinear | solvency_cone (const Spot &spot) |
| void | untangle_restriction (Portfolio &portfolio, const PiecewiseLinear &portfolios, const Spot &spot) |
Utility functions for trading and solvency.
| void ensure_solvent | ( | PiecewiseLinear & | portfolios, |
| const Spot & | spot | ||
| ) | [inline] |
Restricts a set of portfolios to ensure that they are solvent.
| portfolios | Piecewise linear function forming lower bound of collection of portfolios |
| spot | Current spot price |
| void include_solvent_portfolios | ( | PiecewiseLinear & | portfolios, |
| const Spot & | spot | ||
| ) | [inline] |
Enlarges a set of portfolios to contain all solvent portfolios
| portfolios | Piecewise linear function forming lower bound of collection of portfolios |
| spot | Current spot price |
| PiecewiseLinear portfolios_that_can_afford | ( | const Portfolio & | portfolio, |
| const Spot & | spot | ||
| ) | [inline] |
Returns a piecewise linear convex function whose epigraph is the portfolios from which one can afford portfolio at the price spot.
Checks whether portfolio can be converted into a nonnegative amount of cash when the current share price is spot.
| PiecewiseLinear solvency_cone | ( | const Spot & | spot | ) | [inline] |
Returns a piecewise linear convex function whose epigraph is the solvency cone.
| void untangle_restriction | ( | Portfolio & | portfolio, |
| const PiecewiseLinear & | portfolios, | ||
| const Spot & | spot | ||
| ) | [inline] |
Adjusts portfolio, which is assumed to be in the epigraph of portfolios.restrict(-spot.ask(), -spot.bid()) (this is not tested!), in a self-financing way so that it is in the epigraph of portfolios.