Point Mass Forces Longitudinal — Robotics/Equations Of Motion
Robotics/Equations_Of_Motion/Point_Mass_Forces_Longitudinal · 7 input / 2 output port(s) at insert · exports to Python, MATLAB, Java, Rust, C, C++, VHDL, Verilog, SystemVerilog, PLC Structured Text
Description#
The block's own DESCRIPTION_HTML, rendered verbatim — the same text the config dialog's info panel and the library navigator show. Fix a wrong sentence in the block's .cpp (R-D9), never here.
Point Mass Forces (4th Order, Longitudinal)
Robotics / Equations Of Motion
The aerodynamic, thrust and weight forces of a point-mass airframe resolved into the local geographic frame. Two intermediates carry the whole block:
- A = T·cosα − D – the along-path net of thrust and drag
- B = T·sinα + L – the across-path net of thrust and lift
and the components are
- Feast = A − W·sinγ
- Fup = B·cosμ − W·cosγ
Ports
- L – the lift, a [1,1] scalar force.
- D – the drag, a [1,1] scalar force, positive aft.
- W – the weight, a [1,1] scalar force, positive down.
- T – the thrust, a [1,1] scalar force.
- gamma – the flight-path angle γ, a [1,1] scalar in radians.
- mu – the bank angle μ, a [1,1] scalar in radians.
- alpha – the angle of attack α, a [1,1] scalar in radians.
- Feast – the east component, a [1,1] scalar: A − W·sinγ.
- Fup – the up component, a [1,1] scalar: B·cosμ − W·cosγ.
⚠ Every port is a scalar, so a wrong wiring passes every size check there is. The input order is the Simulink block's own: L, D, W, T, γ, μ, α – the three ANGLES last, after the four forces.
Parameters
- Sampling Time (s) – zero or less inherits the solver's rate; a positive value runs the block at that period.
There are no others: every quantity arrives on a port, and the Simulink counterpart has no dialog parameters at all.
Code export
All ten targets: Python, MATLAB, Java, Rust, C, C++, VHDL, Verilog, SystemVerilog and PLC Structured Text.
The three HDL targets are simulation-only real
arithmetic, not synthesizable fixed point: four sines and cosines of values that
arrive on ports, which a Q16.16 datapath has no primitive for. They
quantize at the port boundary and evaluate in real – correct
in simulation, and not offered as hardware. VHDL's
IEEE.MATH_REAL SIN and COS are total, so unlike an
arctangent there is nothing to guard.
Simulink bridge
Import and export, mapped to Aerospace Blockset's
aerolibptmass/4th Order Point Mass Forces (Longitudinal). That block has no dialog
parameters at all – measured in R2026a – so nothing is mapped and
the add_block carrying nothing is itself the assertion. It defines
no SampleTime either (set_param is refused), so
the rate stays on the ICore side and a block given an explicit positive period
reports that it did not cross. Its library path carries an embedded
newline with no space before it, which is why the entry spells it out
rather than typing it.
Notes
- Algebraic and stateless: the outputs depend on this sample alone.
- ⚠ This block and 6th Order Point Mass Forces (Coordinated Flight) are the SAME arithmetic. Measured on identical inputs, their Feast and Fup agree bit for bit; the six-component form adds Fnorth = B·sinμ and nothing else. In particular the longitudinal form's Fup still carries cosμ – "longitudinal" does not mean the bank angle is ignored, and a reader who assumes it is will be out by a factor of cosμ.
- Not linear – three transcendental functions of inputs, and products of inputs – so the block carries no state space and model reduction correctly reports it as unmergeable.
- Verified against R2026a at two independent points, the second with a negative flight-path angle and a negative incidence, bit for bit on every component.
Code facts#
| Fact | Value |
|---|---|
| registered type | Robotics/Equations_Of_Motion/Point_Mass_Forces_Longitudinal |
| family | Robotics/Equations_Of_Motion |
| solver environment class | ICoreBlock_0_Robotics_1_Equations_Of_Motion_2_Point_Mass_Forces_Longitudinal |
| source | src/ICoreBlocks/ICoreBlockLibrary/Blocks/Robotics/Equations_Of_Motion/Point_Mass_Forces_Longitudinal/ICoreBlock_0_Robotics_1_Equations_Of_Motion_2_Point_Mass_Forces_Longitudinal.cpp |
| header | src/ICoreBlocks/ICoreBlockLibrary/Blocks/Robotics/Equations_Of_Motion/Point_Mass_Forces_Longitudinal/ICoreBlock_0_Robotics_1_Equations_Of_Motion_2_Point_Mass_Forces_Longitudinal.h |
| default size on canvas | 140 × 128 px |
| ports at insert | 7 in, 2 out |
| code generators implemented | Python, MATLAB, Java, Rust, C, C++, VHDL, Verilog, SystemVerilog, PLC Structured Text |
Ports#
| # | Direction | Signal type | Description label |
|---|---|---|---|
| 1 | in | ICoreDouble | L |
| 2 | in | ICoreDouble | D |
| 3 | in | ICoreDouble | W |
| 4 | in | ICoreDouble | T |
| 5 | in | ICoreDouble | gamma |
| 6 | in | ICoreDouble | mu |
| 7 | in | ICoreDouble | alpha |
| 8 | out | ICoreDouble | Feast |
| 9 | out | ICoreDouble | Fup |
Ports the constructor creates. A block whose port list changes with its configuration adds or removes ports at load time; the count above is the one a freshly inserted block has.
Configuration variables#
No config variable beyond the Sampling Time (s) every block carries.
Every block also carries Sampling Time (s) from ICoreBlockSolverEnvironment: zero or less inherits the solver's rate, a positive value runs the block at that period.
Simulink bridge#
| support | Support::Both |
| Simulink path | aerolibptmass/4th Order Point Mass Forces\n(Longitudinal) |
| port-count rule | PortsParam::None |
SampleTime parameter | no — the counterpart defines none; the rate stays on the ICore side |
Caveat (shown to the user): the Simulink block carries no dialog parameters and no SampleTime, so the whole mapping is the library path and the port order: L, D, W, T, then the three ANGLES gamma, mu and alpha. Its library path carries an embedded newline with NO space before it, so it is written out rather than typed. The rate stays on the ICore side
Catalog contract: src/ICoreBlocks/ICoreCoder/ICoreCommandSystem/SimulinkBridge/ICoreSimulinkBlockCatalog.h
Description vs code#
The lists agree. check_block_descriptions.py finds no disagreement between the description's Ports, Parameters, Code export and Simulink bridge lists and the code's.
The verdict above is
tools/docs/check_block_descriptions.py(P7.1), which compares LISTS. It cannot read a sentence: "stateless" on a block with a state, an initial-value semantic the recursion does not implement, a "not synthesizable" caveat the HDL banner contradicts. That is the agent audit (P7.3) on BLOCK_DESCRIPTION_AUDIT.md, and this tool's green is not a substitute for one.
File banner (developer view)#
The top comment of the block's .cpp — the maths, the realization and the export strategy, addressed to whoever changes it. It must not contradict the description above (P7.5).
4th Order Point Mass Forces (Longitudinal) A = T*cos(alpha) - D the along-path net of thrust and drag B = T*sin(alpha) + L the across-path net of thrust and lift
Feast = A - W*sin(gamma) Fup = B*cos(mu) - W*cos(gamma)
MEASURED AGAINST R2026a AT TWO INDEPENDENT POINTS, bit for bit, the second chosen with a NEGATIVE flight-path angle and a NEGATIVE incidence so that no sign could be right by accident. At L = 1200, D = 310, W = 9500, T = 2100, gamma = 0.21, mu = 0.37, alpha = 0.13 the Simulink block answers Feast = -208.08907173689067 and Fup = -7918.6918173662452; at L = 430, D = 95, W = 6100, T = 880, gamma = -0.34, mu = 0.62, alpha = -0.09 it answers Feast = 2815.7096671095228 and Fup = -5465.2079124773654. Both are the expressions above evaluated LEFT TO RIGHT, which is what this block emits in all ten targets.
⚠⚠ THE TWO POINT MASS FORCES BLOCKS ARE THE SAME ARITHMETIC, WHICH IS A MEASUREMENT AND NOT AN ASSUMPTION. Fed identical inputs, the 4th-order (longitudinal) and 6th-order (coordinated flight) Simulink blocks return IDENTICAL Feast and Fup; the 6th-order one adds Fnorth = B*sin(mu) and nothing else. In particular THE LONGITUDINAL FORM'S Fup STILL CARRIES cos(mu) -- "longitudinal" does not mean the bank angle is dropped, and a reader who assumes it is will be out by a factor of cos(mu).
⚠ SEVEN SCALAR INPUTS IN THE SIMULINK BLOCK'S OWN ORDER: L, D, W, T, gamma, mu, alpha -- the four forces first and the three ANGLES last. Every port is a scalar, so nothing about a wrong wiring is caught by a size check; the rig drives all seven from independent gates for exactly that reason.
NO DIALOG PARAMETERS AT ALL and NO SampleTime -- measured; set_param on the rate is refused.
ALGEBRAIC and STATELESS. The three HDL targets are SIMULATION-ONLY
real: four sines and cosines of port values, which Q16.16 has no primitive for. VHDL's IEEE.MATH_REAL SIN and COS are TOTAL, so unlike an arctangent there is nothing to guard.
Sample results#
| t | in ICoreDouble-Out-0 | in ICoreDouble-Out-0 | in ICoreDouble-Out-0 | out ICoreDouble-Out-0 | out ICoreDouble-Out-1 |
|---|---|---|---|---|---|
| 0 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 0.4 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 0.8 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 1.2 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 1.6 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 2 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 2.4 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 2.8 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 3.2 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 3.6 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 4 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 4.4 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
| 4.8 | -2 | -2 | -2 | 1.014 | -0.7568 |
| 5.2 | 0.5 | 0.5 | 0.5 | -0.3009 | 0.2104 |
Every 4th of 60 samples, from the table stimulus.
The same rig also ran:
| Stimulus | What it is | Output range |
|---|---|---|
impulse | Impulse: one sample of 1 at k = 5, 0 elsewhere (Repeating Sequence Stair) | -1.301 … 0 |
ramp | Ramp: slope 1 from t = 0 | -6.41 … 2.278 |
sine | Sine Wave: amplitude 1, 2 rad/s, no phase, no bias | -1.3 … 0 |
step | Step: 0 -> 1 at t = 1 s | -1.301 … 0 |
Plotted: table — Repeating Sequence Stair: [-2 -1 -0.5 0 0.5 1 2 3], one entry per sample
Category static · sample time 0.1 · 60 steps · commit b755fc86d0eadc503c92782f3b2145159e1ec333 · produced by docsSample --out <folder> --blocks Point_Mass_Forces_Longitudinal Point_Mass_Forces_Coordinated_Flight --steps 60 · data docs/generated/samples/Robotics__Equations_Of_Motion__Point_Mass_Forces_Longitudinal.json · the SVG is generated from those numbers by tools/docs/plot_svg.py, so it is a run and not a drawing (R-D10).