393 Commits

Author SHA1 Message Date
Joe Pfeiffer
c7b3466dd5
Unstable (#5)
* Fix Average Thrust Calculation (fixes issue #441)

Remove test for short time interval before first data point in thrust
curve.  Comment said it was for numerical stability; multiplying by a
small number and then adding doesn't introduce any instabilities I'm
aware of in this code.

Add parentheses to clarify that values are being multiplied by time
intervals, not divided.

* Code clarification; should make no difference to results

* [refactor] fixed warnings and made variable names more explicit in [Freeform]FinSetConfig Dialogs

- de-duped  writeCSVFile methods

* [Fixes #424] Respaced FinSetConfig Window:

Resolved some sources of phantom whitespace; Spacing on component configuration
windows is now generally tighter.

* [cleanup] Refactored naming in ScaleSelector to be more consistent 'Zoom' -> 'Scale'

* [refactor] updated BoundingBox class to be more useful

- FlightConfiguration now exposes the BoundingBox method for its rocket

* [refactor] Reduce redundant methods in Scalefigures, and harmonize common function names

- removed interface that was only inherited by the single AbstractBaseClass
- harmonizes  the border pixels variables in the scalefigure package

* [rm] excised EXTRA_SCALE (==S) factor in ScaleFigure Code

* [fix] FinPointFigure now auto-scales correctly

- auto-zooms on startup
- ScaleSelector Text updates with +/- buttons
- adjusts fin-point drawing code

* [feat] FinPointFigure draws its parent/mounting half-body (w/front & back terminators)

* [fixes #425] FinPointFigure ScrollBars now adjust with zoom in/out

* [fix] clicking away from points now longer causes an exception

* Version Bump to Alpha 8

* [fixes #424] Addes back in ConfigDialog outside spacing.

* [feature][Resolves #426] implemented FinPoint SelectedIndex Indicators

- figure and table update each other

* [fixes #419] Clicking in fin-point figure now calculates closest segment correctly

* [fixes #431] Fins default to instance count / fin count == 1

- Fixed init bug
- added unittests for fin count loading/saving/creation

* [fix] Revert patch 6289aef0... which introduced simulation anomalies

* [resolves #423][partial] BarrowmanCalculator no longer multiplies instanced leaf nodes.

* [fix] Fixes the way BarrowmanCalculator handles instancing, particularly for ComponentAssemblies

* [test] Moved fins from core-body to booster-body; (they are now doubly-instanced); adjusted tests to accept this.

* [refactor] renamed FinSet#fins => FinSet#finCount to make it's meaning more explicit

* [minor][debug][oneline] removed excess sys.err debug line

* [fixes #439] May now delete points again, in the FreeformFinSetConfig window

* [fix] AbstractScaleFigure now stores (& requires!) the visible bounds when setting zoom/scale.

- if the visible bounds are larger than the requested scale bounds, then the figure is expanded to match.

* [fixes #436] Rocket figures now center as desired.

* [fixes #425][fixes #440] FinPointFigure contents are bottom-aligned, properly sized.

* [refactor] separated FinSet Tests into files corresponding to FinSet, TrapezoidalFinSet, and FreeformFinSet

* [fixes #419] Adding new points to FreeformFins are now placed at the mouse cursor

* Little bit more massaging for clarity (replace avgImpulse with impulse)

* [fixes #426] reworks FreeformFinSet Selected point display... it is now a second, expanded, different colored box.

* missed reversing the operands in the calculation of last bit of impulse

* [build] Updated dependencies for running from intellij

* [feat] added shared build configurations for Intellij at .idea/runConfigurations/*"

* [fix][config] rename Run Target Configurations

* [build] added jar artifact for IDEA Intellij build

* [fix] run configuration and jar paths are now cross-platform

* [fix] may now create and drag a point in one click.

* [fix] cleanup up unused imports in core/test/net/sf/openrocket/rocketcomponent/*

* [cleanup] removed dead code, and fixed javadocs

* [refactor] tightened access specifiers in FinSet.java

* [fix][Refactor] rocketcomponent.position.RadiusMethod to be clearer

1. renamed getOuterRadius() => getBoundingRadius()
   Previous function did not make sense, where implemented in FinSet.
2. Changed implementation of RadiusMethod.*.getRadius()
   now fails a bit more gracefully.

* [fix] Fixes repeated bug in Presets/Material Loading -- inconsistent test criteria

* Closes 443

When the events STAGE_SEPARATION and EJECTION_CHARGE are both triggered by
BURNOUT, both events occur simultaneously and either can be inserted
in EventQueue first.  If STAGE_SEPARATION is inserted first, the
filter in BasicEventSimulationEngine.java ignoring events from
components that are no longer attached to the rocket drops ignores
EJECTION_CHARGE.  If second stage IGNITION is triggered by
EJECTION_CHARGE it is filtered out, and second stage IGNITION fails to
happen.  This can be seen in the following snippet of a log file:

10592          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=BURNOUT,time=1.03,source=Body tube,data=B4]
10592          DEBUG [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine -  detected Motor Burnout for motor B4@ 1.03  on stage 1: Stage
10592          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=STAGE_SEPARATION,time=1.03,source=Stage,data=null]
10592          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=EJECTION_CHARGE,time=1.0311458852237796,source=Stage,data=B4], FlightEvent[type=ALTITUDE,time=1.0311458852237796,source=Rocket,data=[25.502739793351193;25.603323566419885]]]
10592          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=STAGE_SEPARATION,time=1.03,source=Stage,data=null]
10592          INFO  [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - ==>> @ 1.03115; from Branch: Sustainer ---- Branching: Stage ----

10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=EJECTION_CHARGE,time=1.0311458852237796,source=Stage,data=B4]
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=ALTITUDE,time=1.0311458852237796,source=Rocket,data=[25.502739793351193;25.603323566419885]]]
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Ignoring event from unattached componenent
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=ALTITUDE,time=1.0311458852237796,source=Rocket,data=[25.502739793351193;25.603323566419885]]
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = []
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=ALTITUDE,time=1.0311458852237796,source=Rocket,data=[25.502739793351193;25.603323566419885]]
10593          TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Taking simulation step at t=1.0311458852237796 altitude 25.603323566419885
10593          TRACE [pool-4-thread-1] n.s.o.s.RK4SimulationStepper - Too small time step 0.0014030377018961126 (limiting factor 5), using 0.0025 instead.
10593          TRACE [pool-4-thread-1] n.s.o.s.RK4SimulationStepper - Thrust = 0.0

Note here that there was no IGNITION in the sustainer branch, and the
Thrust is 0.0 at the end of the snippet.

Moving the test for ignition events ahead of the filter assures the
IGNITION is scheduled, as seen in this log file snippet:

8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=BURNOUT,time=1.03,source=Body tube,data=B4]
8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]]
8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=BURNOUT,time=1.03,source=Body tube,data=B4]
8994           DEBUG [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine -  detected Motor Burnout for motor B4@ 1.03  on stage 1: Stage
8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=STAGE_SEPARATION,time=1.03,source=Stage,data=null]
8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=EJECTION_CHARGE,time=1.0302951181945657,source=Stage,data=B4], FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]]
8994           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=STAGE_SEPARATION,time=1.03,source=Stage,data=null]
8995           INFO  [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - ==>> @ 1.03030; from Branch: Sustainer ---- Branching: Stage ----

8995           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=EJECTION_CHARGE,time=1.0302951181945657,source=Stage,data=B4]
8995           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]]
8995           INFO  [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Queueing Ignition Event for:               Body tube/334ebb79 /   A8 - Armed @: 1.0302951181945657
8995           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Ignoring event from unattached componenent
8995           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=IGNITION,time=1.0302951181945657,source=Body tube,data=A8]
8995           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]]
8996           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=IGNITION,time=1.0302951181945657,source=Body tube,data=A8]
8996           INFO  [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine -   Igniting motor:               Body tube/334ebb79 /   A8 - Armed @1.0302951181945657
8996           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Obtained event from queue:  FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]
8996           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Remaining EventQueue = [FlightEvent[type=BURNOUT,time=1.7602951181945656,source=Body tube,data=A8]]
8996           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Handling event FlightEvent[type=ALTITUDE,time=1.0302951181945657,source=Rocket,data=[25.478255057184594;25.5788943164009]]
8996           TRACE [pool-4-thread-1] n.s.o.s.BasicEventSimulationEngine - Taking simulation step at t=1.0302951181945657 altitude 25.5788943164009
8996           TRACE [pool-4-thread-1] n.s.o.s.RK4SimulationStepper - Too small time step 0.0012514398786730699 (limiting factor 5), using 0.0025 instead.
8996           TRACE [pool-4-thread-1] n.s.o.s.RK4SimulationStepper - Thrust = 0.015609756097560644

Here, the IGNITION does take place, and Thrust is non-zero.
Displaying a plot of the flight, and saving CSV files, shows a normal
two-stage flight profile.

This commit does two things:

(1) adds a little more logging, in particular logging what event has been
    obtained from EventQueue and logging when that event is ignored.

(2) moves the motor ignition events test ahead of the filter, as
    described above.

* Correct active stages after STAGE_SEPARATION event

* oops, didn't want to keep the extra debugging log entries

* more fixes to stage ignition:  now also pays attention to ignition
type and additional delay
2018-09-29 16:17:33 -06:00
Wes Cravens
5fcd62dc84
Merge pull request #420 from teyrana/fix_new_stage
[fix][oneline] both Create Stage buttons now create stages with the same name
2018-07-05 00:54:41 -05:00
Daniel_M_Williams
14414d6279 [fix] removed duplicate property keys 2018-06-16 19:52:12 -04:00
Daniel_M_Williams
73db54ae7b [fix] removes obsolete l10n string 'RocketActions.ActBoosterstage' from 'core/resources/l10n/message.properties' 2018-06-09 20:22:32 -04:00
Daniel_M_Williams
85fc41d203 [feature][refactor] Implemented Relative Positioning for Axial, Angular, and Radius directions
- Allows more precise and flexible control of component positions
- file format:
  -- maintains compatability with previous major release (15.04)
  -- may not accept file formats from unstable development branches in-between major releases
2018-01-21 12:06:42 -05:00
Daniel_M_Williams
0498900078 [feat] Added Positioning methods and interfaces for Axial, Radius, and Angle directions
- also added minor angle-wrapping function to MathUtil
2018-01-21 12:06:25 -05:00
Daniel_M_Williams
5c96ad9454 [ver] Bumped version number for Alpha Release 5 2018-01-21 12:05:59 -05:00
Daniel_M_Williams
bf41c07f76 [version] version bump to rc4 2018-01-13 20:47:04 -05:00
Daniel_M_Williams
bb756decfc [doc] Bump version number to 18.01-rc3 2017-12-25 20:56:11 -05:00
Daniel_M_Williams
cfc1715cf4 [fix] Added details toggle to DebugLogDialog 2017-11-05 11:06:11 -05:00
Daniel_M_Williams
42270276d5 [doc] Version bump to 17.11-rc2 2017-11-05 11:06:11 -05:00
Daniel_M_Williams
bd42c7ecde [doc][version] bumped version number to 18.10-rc1 2017-10-28 13:42:10 -04:00
Alexander Allen
107d987973 Implemented CD Override 2017-09-20 21:45:26 -04:00
Daniel_M_Williams
f1c9ebb25f [refactor] Merged configuration tabs for boosters and pods into the 'ComponentAssemblyConfig' class 2017-09-02 11:09:37 -04:00
ChrisMickelson
3997d08a45 update splashscreen 2017-06-05 01:40:42 -04:00
Matt Kendall
3642398b1a Remove opaque background from Tube Fin Component Icon 2016-11-05 23:55:31 +00:00
Kevin Ruland
6532743c3f Revising previous commit to include the missing files. 2016-10-10 19:50:17 -05:00
Kevin Ruland
f121def910 Significantly modified management of motor information provided by
OpenRocket.  At build time, it will utilize the Thrustcurve.org xml api
to download the current information (curve files and supplemental
information).  OpenRocket uses the supplemental information to populate
case-info, propellant type, availability as well as correct diameters
and length. Modified motor search dialog to hide unavailable motors and
show case-info.
2016-10-10 17:27:25 -05:00
Daniel_M_Williams
a6990dddc5 [Bugfix] Fixed additional Translation, Configuration Issues
- Fixed translation messages
   - FlightConfiguration, MotorConfiguration
   - correctly display under debug & production
- Fixed exception throw when adding empty-MotorConfiguration to a FlightConfig
2016-05-20 18:46:47 -04:00
Daniel_M_Williams
2ee7464038 [Bugfix] FlightConfiguration now uses i8n for its empty-motors description 2016-04-27 21:36:31 -04:00
Kevin Ruland
4b4a7c74fc Merge remote-tracking branch 'upstream/master' into unstable
Conflicts:
	swing/src/net/sf/openrocket/gui/figureelements/RocketInfo.java
2016-04-02 16:49:15 -05:00
kruland2607
512f572879 Merge pull request #259 from wcravens/mass-info-both-with-and-without-motor
Mass info both with and without motor - Includes IntelliJ CE Configuration files
2016-03-24 17:36:30 -05:00
Wes Cravens
74d636bf33 Add concurrent mass info for both with and without motor configuration 2016-03-23 13:23:40 -05:00
Daniel_M_Williams
1226666a41 added missing (default) translation string 2016-01-17 13:05:24 -05:00
Daniel_M_Williams
0979cff505 fixed bugs in the Photo Renderer 2015-12-23 23:17:59 -05:00
Kevin Ruland
4c56c53135 Added CaseInfo enum and compatible case information to
MotorInformationPanl.
2015-12-13 10:58:47 -06:00
Daniel_M_Williams
238726f371 Merge branch 'master' of https://github.com/openrocket/openrocket into parallel_staging
Conflicts:
	swing/src/net/sf/openrocket/gui/main/BasicFrame.java (resolved)
2015-12-12 11:14:13 -05:00
Kevin Ruland
b415238a02 Changed Motor to support additional fields case info, prop info, and
availability flag provided by Thrustcurve.org.  Change serialization
process to pull current files from Thrustcurve.org using the xml api,
use the corrected data for diameter and length, and use a consistent
motor designation.  Added fields to the Motor chooser - case info is a
column in the listing (replacing MotorType), the other info is in the
motor details tab.  Added toggle to hide motors which are OOP.
2015-12-07 22:27:05 -06:00
Daniel_M_Williams
657c407ba5 [UI] fixed RailButton UI, file I/O 2015-11-23 23:54:07 -05:00
Daniel_M_Williams
1ce452265c [Feature] Implemented RailButton Shapes (2D only)
RailButtons loaded, edited, and displayed (in 2d, and 3d)
2015-11-23 14:40:57 -05:00
Daniel_M_Williams
82e3a7ff1c [Feature] Implemented more RailButton code:
RailButtons can be loaded, and edited, but not really displayed.
    - data entry has defined file parameters, but needs some debugging.
    - added icons for component creation.  The button just needs to be uncommented
    - display works, but only for rotation = 0;
       - requires a new type of shape drawing.  Not inherently hard, just tedious.
2015-11-22 22:28:51 -05:00
Kevin Ruland
4924773c3a Changed to using Import/Export file menu functions to handle RockSim
formatted files.  Save & Save As will only save in ork format.
2015-11-21 21:37:57 -06:00
Daniel_M_Williams
2501bc2b8f [Bugfix] Enabled auto-positioning of parallel stages
AutoRadialOffset is a boolean flag on parallel stages
    - when enabled, the radialOffset is automatically
    - auto radius is based on the max radius of contained components
2015-11-21 10:02:16 -05:00
Daniel_M_Williams
4e8838aa4c Merge branch 'master' of https://github.com/openrocket/openrocket into child_staging 2015-11-14 11:23:48 -05:00
Kevin Ruland
e8167ac159 Added message properties and prefs for showing warning dialogs.
Restored auto-open last design preference.
2015-10-28 06:27:55 -05:00
Harry Dalton
39ec03370d Adding missing Spanish translation`
(thanks to Carlos)
2015-10-08 12:14:12 +01:00
Daniel_M_Williams
0a55f59548 [Minor] Harmonized interface for instanceable components
Implemented 'Instanceable' Interface
    - MotorMount implements instanceable
        - BodyTube
        - Innertube
    -RingInstance interface
        - BoosterSet
        - PodSet
    -LineInstanceable interface [This feature is not exposed in UI)
        - LaunchLug
        - LaunchButton (Stub only, ATT)
        - RingComponent (abstract ancestor class)
-Reverted MotorMount Function names to "[is|set]MotorMount"
2015-10-06 12:02:57 -04:00
Daniel_M_Williams
a6be346c8d Fixed Load/Save Issues for Boosters and Pods
Fixed hiearchy / naming issues, mostly
    mv StageSaver.java => AxialStageSaver.java
    populate ComponentAssemblySaver.java
    fixed method class refs in DocumentConfig.java
2015-08-27 11:52:31 -04:00
Daniel_M_Williams
ea8066f63c Fixed GUI elements & function f/Boosters/Pods
Model
  Refactored code from AxialStage, BoosterSet, PodSet => ComponentAssembly

GUI
  BoosterSet: Fixed bugs, allowed boosters and pods to be correctly located.
2015-08-27 08:54:35 -04:00
Daniel_M_Williams
0c01123551 refactored Stages (Axial & Booster) now load correctly. 2015-08-25 22:38:13 -04:00
Daniel_M_Williams
c8a3d675d8 messy commit: refactored Stage => AxialStage, BoosterSet, PodSet 2015-08-25 09:57:23 -04:00
Daniel_M_Williams
2f42594acb fixed many display issues relating to refactoring of RocketComponent axialOffset code. 2015-07-21 14:16:13 -04:00
Daniel_M_Williams
6f4cba68ae refactored RocketFigure to use RocketPanel.VIEW_TYPE enum instead of unchecked ints 2015-06-23 13:12:48 -04:00
Daniel_M_Williams
8e268a9a25 added gui and model elements for stage multiplicity 2015-06-22 16:10:13 -04:00
Daniel_M_Williams
c5d47cf806 implemented gui elements for controlling stage axial placement. + other Event refinements 2015-06-15 15:38:18 -04:00
Daniel_M_Williams
4f716b40af Updated GUI with axial stage position elements 2015-06-13 22:47:19 -04:00
Daniel_M_Williams
8371876718 ACTUAL bugfix commit: Stage Config dialog fixed. 2015-06-08 18:19:23 -04:00
Daniel_M_Williams
b8b1e6576e [GUI Options Implemented] Implemented GUI elements to change the position of external components.
External Components are pods and parallel stages.  Slightly different UI options have been implemented for each.
2015-06-03 15:48:13 -04:00
celeron533
1c42de5540 Update zh_CN translation
Update zh_CN translation file
2015-03-28 18:03:56 +08:00
kruland2607
25a2279073 Change to dev. 2015-03-26 08:01:05 -05:00