[savi] 01/04: Imported Upstream version 1.5.0b
Bas Couwenberg
sebastic at debian.org
Tue Jun 13 18:54:04 UTC 2017
This is an automated email from the git hooks/post-receive script.
sebastic pushed a commit to branch master
in repository savi.
commit 802c72b0f97a592379e51a6a3ab83eb8cc5f17db
Author: Bas Couwenberg <sebastic at xs4all.nl>
Date: Tue Jun 13 20:48:50 2017 +0200
Imported Upstream version 1.5.0b
---
RELEASE-NOTE | 4 ++++
tcl/constellations.tcl | 12 ++++++------
2 files changed, 10 insertions(+), 6 deletions(-)
diff --git a/RELEASE-NOTE b/RELEASE-NOTE
index ee94e15..0843ace 100644
--- a/RELEASE-NOTE
+++ b/RELEASE-NOTE
@@ -1,3 +1,7 @@
+SaVi 1.5.0b includes codefixes to SaVi 1.5.0a to prevent bugs:
+- in tcl/constellations.tcl to prevent rounding errors when generating constellations
+ (degrees such as 180 and 360 should be 180.0 and 360.0 to force floating point in Tcl.)
+
SaVi 1.5.0a includes two one-line codefixes to SaVi 1.5.0 to prevent bugs:
- in tcl/constellations.tcl to allow loading of unnamed TLEs (elsets) without a name error.
- in tcl/coverage_frames.tcl to enable better detection of gifsicle, if installed.
diff --git a/tcl/constellations.tcl b/tcl/constellations.tcl
index f227f60..444746c 100644
--- a/tcl/constellations.tcl
+++ b/tcl/constellations.tcl
@@ -29,7 +29,7 @@
# hard to get right. Use at own risk.
# These need considerable expansion and work.
#
-# $Id: constellations.tcl,v 1.31 2016/11/17 05:32:50 lloydwood Exp $
+# $Id: constellations.tcl,v 1.32 2017/06/07 11:36:06 lloydwood Exp $
proc walker {T P F alt inc lan_offset phase_offset} {
@@ -69,7 +69,7 @@ The crude star tool needs to consider desired coverage as an input to the comput
set RADIUS_OF_EARTH $params(Radius)
# this is a very crude first approximation. No seam adjustment
- set INTERPLANE_SPACING [expr 180/$NUM_PLANES]
+ set INTERPLANE_SPACING [expr 180.0 / $NUM_PLANES]
# setup orbital elements
set a [expr $alt+$RADIUS_OF_EARTH]
@@ -78,7 +78,7 @@ The crude star tool needs to consider desired coverage as an input to the comput
set T_per [expr 2 * $PI * pow($a,1.5) / sqrt($MU)]
# 360 degrees is $T_per; get the fraction.
- set plane_offset [expr $T_per / $SATS_PER_PLANE /2 ]
+ set plane_offset [expr $T_per / $SATS_PER_PLANE / 2.0 ]
satellites GV_BEGIN
for {set j 0} {$j < $NUM_PLANES} {incr j} {
@@ -139,7 +139,7 @@ J. G. Walker, Satellite constellations, Journal of the British Interplanetary So
set RADIUS_OF_EARTH $params(Radius)
set TOTAL_SATS [expr $NUM_PLANES * $SATS_PER_PLANE]
- set INTERPLANE_SPACING [expr 360/$NUM_PLANES]
+ set INTERPLANE_SPACING [expr 360.0 / $NUM_PLANES]
# setup orbital elements
set a [expr $alt+$RADIUS_OF_EARTH]
@@ -149,7 +149,7 @@ J. G. Walker, Satellite constellations, Journal of the British Interplanetary So
# 360 degrees is $T_per; get the fraction.
set plane_offset [expr $T_per / $TOTAL_SATS * $F ]
- set overall_offset [expr $T_per / 360 * $phase_offset ]
+ set overall_offset [expr $T_per / 360.0 * $phase_offset ]
satellites GV_BEGIN
for {set j 0} {$j < $NUM_PLANES} {incr j} {
@@ -246,7 +246,7 @@ proc tle_file_input {filename} {
# if we have everything then write out a satellite!
if {($line1 == 1) && ($line2 == 1)} {
# write out orbital elements
- set period [expr 86400/$mean_motion]
+ set period [expr 86400.0 / $mean_motion]
set a [expr pow($period*sqrt($MU)/2.0/$PI,2.0/3.0)]
set mean_anomaly [expr fmod($mean_anomaly + \
$dt*$mean_motion*360.0, 360.0)]
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-grass/savi.git
More information about the Pkg-grass-devel
mailing list