$LastChangedDate: 27-Juil-2011 $

# CL_kp_characteristics

Various Keplerian characteristics

## Calling Sequence

       kep = CL_kp_characteristics(sma,ecc,v[,er[,mu]])

## Description

- Computes many keplerian parameters for elliptic or hyperbolic orbits. Parabolic orbits are not handled.

  The computed parameters are :

  - standard quantities:

  semi major axis, eccentricity, apoapsis radius, periapsis radius, apoapsis altitude, periapsis altitude, velocity at apoapsis, velocity at periapsis, energy, law of areas' constant, period, semi minor axis, conic's p parameter, conic's c parameter (angular momentum), mean motion, velocity at infinity on an hyperbola, distance from asymptote to focus for an hyperbola, escape velocity at apoapsis, escape velocity at periapsis, escape delta-V at apoapsis, escape delta-V at periapsis.

  - position-related quantities :

  true anomaly, mean anomaly, eccentric anomaly, time from periapsis, radius, x cartesian coordinate, y cartesian coordinate, slope of velocity vector, velocity.

  The output argument kep is a structure that contains everything.

  Parameters that are irrelevant are given the value %nan. Example: kep.period is %nan for hyperbolic orbits.

  kep is defined as follows:

  - kep.orb_type: type of orbit (1->elliptical, 2->hyperbolic)

  - kep.sma: semi major axis [m]

  - kep.ecc: eccentricity

  - kep.ra: apoapsis radius [m]

  - kep.rp: periapsis radius [m]

  - kep.ha: apoapsis altitude (= kep.ra minus planet (equatorial) radius) [m]

  - kep.hp: periapsis altitude (= kep.rp minus planet (equatorial) radius) [m]

  - kep.va: velocity at apoapsis [m/s]

  - kep.vp: velocity at periapsis [m/s]

  - kep.vinf: velocity at infinity for an hyperbolic orbit (%nan otherwise) [m/s]

  - kep.period: orbit's period [s]

  - kep.mm: orbit's mean motion [rad/s]

  - kep.energy: orbit's energy [J]

  - kep.c_area: C constant for the law of areas [m^2/s]

  - kep.l_con: conic's l parameter (semi latus rectum)

  - kep.c_con: conic's c parameter (linear eccentricity) [m]

  - kep.smb: semi minor axis [m]

  - kep.d_asymt: distance asymptote-focus for an hyperbolic orbit (%nan otherwise) [m]

  - kep.vlp: escape velocity at periapsis [m/s]

  - kep.vla: escape velocity at apoapsis [m/s]

  - kep.dvp: escape delta-V at periapsis [m/s]

  - kep.dva: escape delta-V at apoapsis [m/s]

  - kep.v: true anomaly [rad]

  - kep.M: mean anomaly [rad]

  - kep.E: eccentric anomaly [rad]

  - kep.taninf: true anomaly at infinity (only for hyperbolic orbits, %nan otherwise) [rad]

  - kep.tperi: time from periapsis [s]

  - kep.r: norm of radius vector [m]

  - kep.x: x cartesian coordinate [m]

  - kep.y: y cartesian coordinate [m]

  - kep.slope: slope of velocity vector [rad]

  - kep.vel: velocity [m/s]

  NB: the linear eccentricity (kep.c_con) is the distance between the center and the focus (or one of the two foci). The latus rectum is the chord parallel to the directrix and passing through the focus (or one of the two foci). The semi latus rectum (kep.l_con) is half of the latus rectum.

- Notes:

  A few names have changed but are still recognized. They should be avoided as could disappear in the future. These names are:

  - k : same as energy

  - C_area : same as c_area

  - d_foy : same as d_asymt

  - anvinf : same as taninf

  - date: same as tperi

  - R: same as r

  - v_slope: same as slope

## Parameters

sma:

  semi major axis [m] (1xN or 1x1)

ecc:

  eccentricity (1xN or 1x1)

v:

  true anomaly [rad] (1xN or 1x1)

mu:

  (optional) gravitational constant [m^3/s^2] (default value is %CL_mu)

er:

  (optional) planet equatorial radius [m] (default is %CL_eqRad)

kep:

  structure containing all the data (1xN)

## See also

- CL_kp_params

- CL_kp_E2v

- CL_kp_v2E

- CL_kp_E2M

- CL_kp_M2E

- CL_op_rarp2ae

- CL_op_rava2ae

- CL_op_rpvinf2ae

- CL_op_rpvp2ae

## Authors

- CNES - DCT/SB

## Examples

    sma = 7078.e3;
    ecc = 0.0001;
    v = %pi/4;
    kep = CL_kp_characteristics(sma,ecc,v)