Hi everybody ... i've been working for a while on interfacing matlab with FG, and i could eventually achieve this connection, but i have some problems regarding the flight dynamics itself.
I use the JSBsim SFunction that can be used directly in a simulink model, and i would like to ask how can i make sure that i've specified the right aircraft model, because when i run the GUI of the JSBsim SFunction project, the AC model list says "AC model selection (Not working yet)" so i have the feeling that the AC model may not be well specified.
The motivation behind this question is that when i used the version 1.9.1 with matlab, using the f16 aircraft model, the aircraft keeps climbing till it reaches an altitude of 45000 ft and then descends till it hits the ground, but when i used the version 3.0, the aircraft started to fall from its initial altitude and velocity till it hit the ground, baring in mind that the JSBsim folder that contains the data of planes and engines (that found in the JSBsim project folder) is the same, and i don't have an explanation for this.
Moreover, i made a quick search on the center of gravity of the f16 aircraft, and found that it is designed to have negative stability, meaning the center of gravity is behind the neutral point of the aircraft, in other words, the aircraft should tend to pitch upwards rather than downwards in normal aircrafts. However, it tends to make a pitch down and fall direct to the ground when i start the matlab simulation and i interpreted this as an error in reading aircraft data by JSBsim.
Another question ... is there a way that i can get the stability derivatives and the dimensions of an aircraft out of the FG?? i need them so i can use them to build a simple FDM model using matlab aerospace block instead of the JSBsim project.
Thank you in advance.