Difference between revisions of "Template:OrbitVelocity"

From Kerbal Space Program Wiki
Jump to: navigation, search
m (!left over closing bracket;)
(+support BodyData directly and new parameters from the core template;)
Line 1: Line 1:
<includeonly>{{formatnum|{{#expr: {{OrbitVelocity/Core|{{{1|{{{period|{{{period_s}}}}}}}}}|{{{2|{{{mass|{{{mass_kg}}}}}}}}}}} {{#switch: {{{factor|}}}
+
<includeonly>{{formatnum|{{OrbitVelocity/Core|{{{1|{{{period|{{{period_s}}}}}}}}}|{{{2|{{{mass|{{{mass_kg}}}}}}}}}|b={{{body|{{{b|}}}}}}|f={{{factor|{{{f|}}}}}}|pf={{{period factor|{{{pf|}}}}}}}}|2}}&nbsp;{{Dict|{{{factor|{{{f|}}}}}}}}{{Dict|m}}/{{Dict|s}}{{#if: {{{period_s|}}}{{{mass_kg|}}}{{{round|}}}{{{suffix|}}}|[[Category:OrbitVelocity with old parameters]]}}</includeonly><noinclude>This template calculates the velocity of an orbit. To calculate further with the orbit's velocity use {{Tl|OrbitVelocity/Core}}.
|k=/1000
 
|M=/1000000
 
|G=/1000000000}}}}|2}}&nbsp;{{Dict|{{{factor|}}}}}{{Dict|m}}/{{Dict|s}}{{#if: {{{period_s|}}}{{{mass_kg|}}}{{{round|}}}{{{suffix|}}}|[[Category:OrbitVelocity with old parameters]]}}</includeonly><noinclude>This template calculates the velocity of an orbit. To calculate further with the orbit's velocity use {{Tl|OrbitVelocity/Core}}. To add the mass, and possibly the period, automatically the {{Tl|BodyData/Orbit velocity}} can be used.
 
  
 
All usages with the old parameter names will be sorted into the category [[:Category:OrbitVelocity with old parameters]].
 
All usages with the old parameter names will be sorted into the category [[:Category:OrbitVelocity with old parameters]].
Line 11: Line 8:
 
{{Parameter Row|period|name2=1|Period of the orbit in seconds (Old parametername: <tt>{{{period_s}}}</tt>)}}
 
{{Parameter Row|period|name2=1|Period of the orbit in seconds (Old parametername: <tt>{{{period_s}}}</tt>)}}
 
{{Parameter Row|mass|name2=2|Mass of central body in kilograms (Old parametername: <tt>{{{mass_kg}}}</tt>)}}
 
{{Parameter Row|mass|name2=2|Mass of central body in kilograms (Old parametername: <tt>{{{mass_kg}}}</tt>)}}
{{Parameter Row|factor|Factor in which the velocity should be shown. Available values: None (m/s), '''k''' (km/s), '''M''' (Mm/s), '''G''' (Gm/s).|None}}
+
{{Parameter Row|factor|name2=f|Factor in which the velocity should be shown. Available values: None (m/s), '''k''' (km/s), '''M''' (Mm/s), '''G''' (Gm/s).|None}}
 +
{{Parameter Row|body|name2=b|Uses the sidereal rotation period and mass as default from the given body. Can be overwritten.|Not set (makes the first two parameters mandatory)}}
 +
{{Parameter Row|period factor|name2=pf|2=Multiplies the period with this value. Useful to easily calculate semi-synchronous orbits (<tt>pf=1/2</tt> then).|3=<tt>1</tt>}}
 
}}
 
}}
  

Revision as of 10:26, 17 September 2013

This template calculates the velocity of an orbit. To calculate further with the orbit's velocity use {{OrbitVelocity/Core}}.

All usages with the old parameter names will be sorted into the category Category:OrbitVelocity with old parameters.

Parameters

Template:Parameter Table

Examples

Usage Produces
{{OrbitVelocity | period=64980 | mass=4.515e21}}
307.72 m/s
{{OrbitVelocity | 64980 | 4.515e21}}
307.72 m/s