# lamberthub.universal_solvers.arora

A module hosting all algorithms devised by Arora

## Module Contents

### Functions

 arora2013(mu, r1, r2, tof, M=0, prograde=True, low_path=True, maxiter=35, atol=1e-05, rtol=1e-07, full_output=False) Solves Lambert problem using Arora's devised algorithm _get_gammas(F_i, F_n, F_star) Compute different gamma values _get_x(F_0, F_1, F_i, F_star, Z, alpha) Computes Sundman transformation variable. _get_W(k, M, epsilon=0.02) Evaluates the auxiliary function at particular value of the independent Evaluate the first derivative of Ws w.r.t. independent variable k. Evaluate the second derivative of Ws w.r.t. independent variable k. _get_Wprime(k, W, epsilon=0.02) Evaluates the first derivative of the auxiliary function w.r.t. the _get_W2prime(k, W, W_prime, epsilon=0.02) Evaluates the second derivative of the auxiliary function w.r.t. the _get_TOF(k, tau, S, W) Evaluates the time of flight at a particular value of the independent variable.
lamberthub.universal_solvers.arora.arora2013(mu, r1, r2, tof, M=0, prograde=True, low_path=True, maxiter=35, atol=1e-05, rtol=1e-07, full_output=False)

Solves Lambert problem using Arora’s devised algorithm

Parameters
• mu (float) – Gravitational parameter, equivalent to $$GM$$ of attractor body.

• r1 (numpy.array) – Initial position vector.

• r2 (numpy.array) – Final position vector.

• M (int) – Number of revolutions. Must be equal or greater than 0 value.

• low_path (bool) – If two solutions are available, it selects between high or low path.

• maxiter (int) – Maximum number of iterations.

• atol (float) – Absolute tolerance $$abs(x_{i+1} - x_{i})$$

• rtol (float) – Relative tolerance $$abs(\frac{x_{i+1}}{x_{i}} - 1)$$

• full_output (bool) – If True, the number of iterations and time per iteration are also returned.

Returns

• v1 (numpy.array) – Initial velocity vector

• v2 (numpy.array) – Final velocity vector

• numiter (int) – Number of iterations.

• tpi (float) – Time per iteration in seconds.

Notes

Lambert’s problem solver using the method proposed by Nitin Arora and Ryan P. Rusell in 2013, see [1]. This algorithm exploits the universal formulae by defining a new cosine-based transformation and developing a robust initial guess. Although based on arbitrary conditions, the algorithm shows a high performance.

References

[1] Arora, N., & Russell, R. P. (2013). A fast and robust multiple revolution Lambert algorithm using a cosine transformation. Paper AAS, 13, 728.

lamberthub.universal_solvers.arora._get_gammas(F_i, F_n, F_star)

Compute different gamma values

lamberthub.universal_solvers.arora._get_x(F_0, F_1, F_i, F_star, Z, alpha)

Computes Sundman transformation variable.

Parameters
• F_0 (float) – First boundary coefficient.

• F_1 (float) – Second boundary coefficient.

• F_i (float) – Third boundary coefficient.

• F_star (float) – Last boundary coefficient.

• Z (float) – Auxiliary constant.

• alpha (float) – Auxiliary constant.

Returns

x – Sundman transformation value.

Return type

float

Notes

This is equation (44) from original report.

lamberthub.universal_solvers.arora._get_W(k, M, epsilon=0.02)

Evaluates the auxiliary function at particular value of the independent variable.

Parameters
• k (float) – Indepentent variable.

• M (int) – Number of revolutions

• epsilon (float) – Tolerance parameter. Default value as in the original report.

Returns

W – Value of the auxiliary function.

Return type

float

Notes

This is equation (27) from official report.

lamberthub.universal_solvers.arora._get_Wsprime(k)

Evaluate the first derivative of Ws w.r.t. independent variable k.

Parameters

k (float) – The independent variable.

Returns

Ws_prime – Value of the first derivative w.r.t. to k.

Return type

float

Notes

This equation was not provided in the original report, probably because author assumed it was trivial.

lamberthub.universal_solvers.arora._get_Ws2prime(k)

Evaluate the second derivative of Ws w.r.t. independent variable k.

Parameters

k (float) – The independent variable.

Returns

Ws_2prime – Value of the second derivative w.r.t. to k.

Return type

float

Notes

This equation was not provided in the original report, probably because author assumed it was trivial.

lamberthub.universal_solvers.arora._get_Wprime(k, W, epsilon=0.02)

Evaluates the first derivative of the auxiliary function w.r.t. the independent variable k.

Parameters
• k (float) – The independet variable.

• W (float) – The auxiliary function value.

Returns

W_prime – The value of the first derivative of the auxiliary function.

Return type

float

Notes

This is equation set (38) from official report.

lamberthub.universal_solvers.arora._get_W2prime(k, W, W_prime, epsilon=0.02)

Evaluates the second derivative of the auxiliary function w.r.t. the independent variable k.

Parameters
• k (float) – The independet variable.

• W (float) – The auxiliary function value.

Returns

W_2prime – The value of the second derivative of the auxiliary function.

Return type

float

Notes

This is equation set (39) from official report.

lamberthub.universal_solvers.arora._get_TOF(k, tau, S, W)

Evaluates the time of flight at a particular value of the independent variable.

Parameters
• k (float) – The independent variable.

• tau (float) – Lambert’s geometry parameter.

• S (float) – Auxiliary variable.

Returns

TOF – Computed time of flight.

Return type

float

Notes

This is equation (26) form official report.