-
Notifications
You must be signed in to change notification settings - Fork 15
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #32 from stepan-neretin7/17_fix_theta_function
[ISSUE #17] Corrected the angle functions to fix the incorrected results strans function according to the documentation.
- Loading branch information
Showing
9 changed files
with
196 additions
and
10 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -6,6 +6,6 @@ CREATE EXTENSION pg_sphere; | |
select pg_sphere_version(); | ||
pg_sphere_version | ||
------------------- | ||
1.2.2 | ||
1.2.3 | ||
(1 row) | ||
|
This file was deleted.
Oops, something went wrong.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
# pg_sphere extension | ||
comment = 'spherical objects with useful functions, operators and index support' | ||
default_version = '1.2.2' | ||
default_version = '1.2.3' | ||
module_pathname = '$libdir/pg_sphere' | ||
relocatable = true |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,55 @@ | ||
\set ECHO none | ||
SELECT set_sphere_output_precision(8); | ||
SET extra_float_digits TO -3; | ||
\set ECHO all | ||
|
||
-- checking Euler transformation operators | ||
|
||
SELECT strans '-10d,0d,10d,ZZZ' = '-10d,0d,10d,XXX' ; | ||
SELECT strans '-40d,0d,40d,ZZZ' <> '-40d,0d,40d,XXX' ; | ||
|
||
SELECT strans ( 20.0*pi()/180.0, -270.0*pi()/180.0, 70.5*pi()/180.0, 'XZY' ); | ||
|
||
SELECT theta( strans ( 20.0*pi()/180.0, -270.0*pi()/180.0, 70.5*pi()/180.0, 'XZY' ) ); | ||
|
||
SELECT psi( strans ( 20.0*pi()/180.0, -270.0*pi()/180.0, 70.5*pi()/180.0, 'XZY' ) ); | ||
|
||
SELECT phi( strans ( 20.0*pi()/180.0, -270.0*pi()/180.0, 70.5*pi()/180.0, 'XZY' ) ); | ||
|
||
SELECT theta( strans( '20d, 30d, 40d, XZY' ) ); | ||
|
||
SELECT psi( strans( '20d, 30d, 40d, XZY' ) ); | ||
|
||
SELECT phi( strans( '20d, 30d, 40d, XZY' ) ); | ||
|
||
SELECT strans( '2d 20m, 10d, 0' ); | ||
|
||
SELECT theta( strans( '2d 20m, 10d, 0' ) ); | ||
|
||
SELECT psi( strans( '2d 20m, 10d, 0' ) ); | ||
|
||
SELECT phi( strans( '2d 20m, 10d, 0' ) ); | ||
|
||
SELECT strans ( '10d, 90d, 270d, ZXZ' ); | ||
|
||
SELECT theta( strans ( '10d, 90d, 270d, ZXZ' ) ); | ||
|
||
SELECT psi( strans ( '10d, 90d, 270d, ZXZ' ) ); | ||
|
||
SELECT phi( strans ( '10d, 90d, 270d, ZXZ' ) ); | ||
|
||
SELECT - strans ( '20d, 50d, 80d, XYZ' ); | ||
|
||
SELECT theta( - strans ( '20d, 50d, 80d, XYZ' ) ); | ||
|
||
SELECT psi( - strans ( '20d, 50d, 80d, XYZ' ) ); | ||
|
||
SELECT phi( - strans ( '20d, 50d, 80d, XYZ' ) ); | ||
|
||
SELECT strans( '90d, 60d, 30d' ); | ||
|
||
SELECT theta( strans( '90d, 60d, 30d' ) ); | ||
|
||
SELECT psi( strans( '90d, 60d, 30d' ) ); | ||
|
||
SELECT phi( strans( '90d, 60d, 30d' ) ); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
-- Nothing to upgrade in the schema |