YASim: Difference between revisions

Jump to navigation Jump to search
196 bytes added ,  2 November 2014
no edit summary
(Heading cleanup)
No edit summary
Line 325: Line 325:


== Command Line ==
== Command Line ==
=== Standard Usage ===
=== Windows ===
By use of a standard command line, we can see what the YASim solver is calculating. First, open up a command line prompt, and enter in the location of YASim.exe, and then the location of the YASim xml file. For example, here's what you would type in for a standard Windows 32-bit installation, and viewing the [[Boeing 777-200ER]]'s YASim file.
By using the standard command line, we can see what the YASim solver is calculating. First, open up Command Prompt, enter in the location of yasim.exe, and then the location of the YASim XML file. For example, here's what you would type in for a standard Windows [[Changelog_2.12|FlightGear 2.12.0]] installation, and viewing the [[F-14_Tomcat|F-14B's]] YASim file.
{{Note|You can copy & paste the examples into Command Prompt by right-clicking on the title and navigate to Edit > Paste.  Then, click Enter to execute.}}


<code>"C:\Program Files\FlightGear\bin\Win32\yasim.exe" "C:\Program Files\FlightGear\data\Aircraft\777-200\777-200ER.xml"</code>
<code>"C:\Program Files\FlightGear\bin\Win32\yasim.exe" "C:\Program Files\FlightGear\data\Aircraft\f-14b\f-14b-yasim.xml"</code>
 
The quotes around the paths are required because of the spaces in the path names. Some other options can be used, but they are not needed for normal testing.


The results will give many different values.
The results will give many different values.
Line 336: Line 335:
* '''Drag Coefficient:''' The drag coefficient of the aircraft.
* '''Drag Coefficient:''' The drag coefficient of the aircraft.
* '''Lift Ratio:''' The lift ratio of the aircraft.
* '''Lift Ratio:''' The lift ratio of the aircraft.
* '''Cruise AoA:''' The cruise AoA, from conditions at <[[YASim#cruise|cruise]]> in the xml file.
* '''Cruise AoA:''' The cruise AoA, from conditions at [[YASim#cruise|<cruise>]] in the xml file.
* '''Tail Incidence:''' The incidence angle of the tail, "solved" by YASim as a way to stabilize the aircraft.
* '''Tail Incidence:''' The incidence angle of the tail, "solved" by YASim as a way to stabilize the aircraft.
* '''Approach Elevator:''' The approach elevator, from conditions at <[[YASim#approach|approach]]> in the xml file.
* '''Approach Elevator:''' The approach elevator, from conditions at [[YASim#approach|<approach>]] in the xml file.
* '''CG:''' Center of gravity of the aircraft in coordinates. Unless it's supposed to be offset, it should always have a Y value of 0.
* '''CG:''' Center of gravity of the aircraft in coordinates. Unless it's supposed to be offset, it should always have a Y value of 0.


=== Advanced Usage ===
The YASim standalone solver also has some command line flags that change it's behaviour.
The YASim standalone solver also has some command line flags that change it's behaviour.


<code>Usage: yasim <ac.xml> [-g [-a alt] [-s kts]] </code>
<code>"C:\Program Files\FlightGear\bin\Win32\yasim.exe" "C:\Program Files\FlightGear\data\Aircraft\f-14b\f-14b-yasim.xml" -g -a 1000 -s 490</code>


*'''-g :''' Instructs YASim to generate space separated tabular data instead of the usual solver output. This can be redirected to a file and used in various plotting programs to visualize the actual lift, drag, L/D curves. The columns of the output are: AoA, Lift, Drag, L/D. (aoa in degrees, lift and drag in G's)
* '''-g:''' Instructs YASim to generate table-style data instead of the usual solver output. This can be redirected to a file and used in various plotting programs to visualize the actual lift, drag, L/D curves. The columns of the output from left to right are: AoA, Lift, Drag, L/D. (aoa in degrees, lift and drag in G's).
*'''-a alt:''' Run the solver at the given '''alt''' altitude in feet.
* '''-a <altitude in feet:>''' Run the solver at the given altitude in feet.
*'''-s kts:''' Also run at the given airspeed '''kts''' in knots.
* '''-s <speed in knots>:''' Also run at the given airspeed in knots.


Note that the above are for the aircraft taken as a whole, as solved by YASim, so they differ from the values of the wing airfoil.
{{Note|The values generated by this method are for the aircraft taken as a whole, as solved by YASim, so they differ from the values of the wing airfoil.}}


To get the tabular output for the example above at 1000 ft and 150 knots one would issue:
To get the tabular output for the example above at 1000 ft and 150 knots, and to redirect this to a file, one would issue:


<code>"C:\Program Files\FlightGear\bin\Win32\yasim.exe" "C:\Program Files\FlightGear\data\Aircraft\777-200\777-200ER.xml" -g -a 1000 -s 150</code>
<code>"C:\Program Files\FlightGear\bin\Win32\yasim.exe" "C:\Program Files\FlightGear\data\Aircraft\f-14b\f-14b-yasim.xml" -g -a 1000 -s 150 > "C:\Program Files\FlightGear\yasim.txt"</code>


== YASim design notes ==
== YASim design notes ==

Navigation menu