Profile image

Automatic computation of a firing solution with line of sight target designation capability

66.6k SnoWFLakE0s  3.7 years ago

Hello folks, it's been a while since I've posted, both due to IRL and in game complications. I've still found some time to invest in SP, and today I've finished what essentially is the most advanced fire control system that is physically possible in the current state of the game,

Already my third rendition (including one failed attempt) of the system, the Mk II Fire Control System offers one primary change that differentiates it from the Mk I.

Previously on the Mk I FCS / FAS, the system assumed a flat ground trajectory between the gun and the target, an assumption that is quite often untrue. This not only is problematic in its own right, but it also meant the system could not calculate solutions for a target under the gun, meaning 0 gun depression. It is also not the most easy thing to operate owing to lack of visual indication of the targeting point. These issues have been addressed in the new version, utilizing a completely new fire solution algorithm to compute gun elevation angles. This post aims to document the features offered by the system.


Contents:

  1. Features
  2. Theory

Features

The objective of the system still remains in assisting an operator to quickly and accurately engage targets. A number of features have been included to achieve this goal.

First, the usage of a new firing solution algorithm enables numerous engagement options previously not available on the Mk I variant. Notably, the Mk II can now produce firing solutions for targets at different altitudes, providing practical assistance in combat.

Second, the usage of a visual aid. The Mk II departs from the static targeting display of the Mk I variant, not offering full control of the viewport. Now the engagement procedure has been made far more intuitive and easier due to this change, as the only step required is to point the reticle at the target, and input the range,

Theory

Owing to the new firing solution algorithm, the theory behind the Mk II FCS is definitely more complex than the Mk I where a flat ground assumption was made.

Using trigonometry and the Line of Sight range to the target, the horizontal and vertical displacement from the target is first deviated. These values are then fed into an equation fundamentally identical to the one found on Wikipedia's article on projectile motion, in the "angle to reach coordinate" section. The angle of elevation required is found, then fed into the gun. This completes the theory behind the Mk II FCS / FAS, apart from the derivation of the motion equation itself.

Just for posterity, here's the code used in the testbed.

atan((pow(1675,2) - sqrt(pow(1675,4) - 9.807*(9.807*pow(Throttle*3000*cos(Trim*20),2) + 2*(Throttle*3000*sin(Trim*20))*pow(1675,2))))/(9.807*Throttle*3000*cos(Trim*20)))

You may see this system in action here. This will be implemented on my Challenger 2 build, which should be releasing in the coming weeks.

  • Log in to leave a comment
  • Profile image
    66.6k SnoWFLakE0s

    Why is this the most advanced FCS possible in SP, you ask? Well, it's not me being arrogant- for a more complete FCS, that is, a system with automatic lead and predictive targeting capabilities, the solving of a massive quartic (not quadratic) equation is required, which cannot be done without a dedicated quartic solver as no defined general form for quartics exist. Thus, this is about the best FCS that can be created in game right now.

    Pinned 3.7 years ago
  • Profile image
    46.4k PlaneFlightX

    Hi, can you please visit This car and follow the instructions to code it? Thanks.

    3.7 years ago
  • Profile image
    34.7k WarHawk95

    Far too complicated for me but sounds awesome

    3.7 years ago