Skip to content
Snippets Groups Projects
Commit 80544fee authored by Liam M. Healy's avatar Liam M. Healy Committed by Liam M. Healy
Browse files

Shadow symbols from antik

With the export of unit and dimension names, there are conflicts with
gsl:psi, gsl:acceleration, gsl:knots.  There is no actual conflict in
the usage because Antik physical quantities only needs to use these
symbols as symbols, there is no binding.  So they are now
shadowing-imported into gsll.  

Added explicit "d0" to numbers in polynomial to insure they are read
as double-floats.
parent e6380d35
No related branches found
No related tags found
No related merge requests found
;; Basis splines. ;; Basis splines.
;; Liam Healy 2008-02-18 14:43:20EST basis-splines.lisp ;; Liam Healy 2008-02-18 14:43:20EST basis-splines.lisp
;; Time-stamp: <2010-06-30 19:57:28EDT basis-splines.lisp> ;; Time-stamp: <2011-01-10 10:30:07EST basis-splines.lisp>
;; ;;
;; Copyright 2008, 2009 Liam M. Healy ;; Copyright 2008, 2009, 2011 Liam M. Healy
;; Distributed under the terms of the GNU General Public License ;; Distributed under the terms of the GNU General Public License
;; ;;
;; This program is free software: you can redistribute it and/or modify ;; This program is free software: you can redistribute it and/or modify
...@@ -20,6 +20,11 @@ ...@@ -20,6 +20,11 @@
(in-package :gsl) (in-package :gsl)
;;; antik:knots means "nautical miles per hour" but there's no conflict
;;; here with the function #'gsl:knots, so we shadow import the symbol
;;; from antik.
(shadowing-import 'antik:knots)
;;; /usr/include/gsl/gsl_bspline.h ;;; /usr/include/gsl/gsl_bspline.h
;;; Should be subclass of interpolation? ;;; Should be subclass of interpolation?
......
;; Index lookup and acceleration ;; Index lookup and acceleration
;; Liam Healy, Sun Nov 4 2007 - 18:09 ;; Liam Healy, Sun Nov 4 2007 - 18:09
;; Time-stamp: <2009-12-27 09:52:14EST lookup.lisp> ;; Time-stamp: <2011-01-10 10:29:57EST lookup.lisp>
;; ;;
;; Copyright 2007, 2008, 2009 Liam M. Healy ;; Copyright 2007, 2008, 2009, 2011 Liam M. Healy
;; Distributed under the terms of the GNU General Public License ;; Distributed under the terms of the GNU General Public License
;; ;;
;; This program is free software: you can redistribute it and/or modify ;; This program is free software: you can redistribute it and/or modify
...@@ -20,6 +20,11 @@ ...@@ -20,6 +20,11 @@
(in-package :gsl) (in-package :gsl)
;;; antik:acceleration refers to the time derivative of velocity but
;;; there's no conflict here with the object 'gsl:acceleration, so we
;;; shadow import the symbol from antik.
(shadowing-import 'antik:acceleration)
(defmobject acceleration "gsl_interp_accel" (defmobject acceleration "gsl_interp_accel"
() ()
"acceleration for interpolation" "acceleration for interpolation"
......
;; Polynomials ;; Polynomials
;; Liam Healy, Tue Mar 21 2006 - 18:33 ;; Liam Healy, Tue Mar 21 2006 - 18:33
;; Time-stamp: <2010-07-07 14:18:55EDT polynomial.lisp> ;; Time-stamp: <2011-01-10 10:29:48EST polynomial.lisp>
;; ;;
;; Copyright 2009 Liam M. Healy ;; Copyright 2009, 2011 Liam M. Healy
;; Distributed under the terms of the GNU General Public License ;; Distributed under the terms of the GNU General Public License
;; ;;
;; This program is free software: you can redistribute it and/or modify ;; This program is free software: you can redistribute it and/or modify
...@@ -213,8 +213,10 @@ ...@@ -213,8 +213,10 @@
;; Example from GSL manual ;; Example from GSL manual
(grid:copy-to (polynomial-solve #m(-1.0d0 0.0d0 0.0d0 0.0d0 0.0d0 1.0d0))) (grid:copy-to (polynomial-solve #m(-1.0d0 0.0d0 0.0d0 0.0d0 0.0d0 1.0d0)))
;; tests from gsl-1.11/poly/test.c ;; tests from gsl-1.11/poly/test.c
(evaluate #m(1 0.5 0.3) 0.5d0) (evaluate #m(1.0d0 0.5d0 0.3d0) 0.5d0)
(evaluate #m(1 -1 1 -1 1 -1 1 -1 1 -1 1) 1.0d0) (evaluate
#m(1.0d0 -1.0d0 1.0d0 -1.0d0 1.0d0 -1.0d0 1.0d0 -1.0d0 1.0d0 -1.0d0 1.0d0)
1.0d0)
(solve-quadratic 4.0d0 -20.0d0 26.0d0) ; no roots (solve-quadratic 4.0d0 -20.0d0 26.0d0) ; no roots
(solve-quadratic 4.0d0 -20.0d0 25.0d0) ; one root (solve-quadratic 4.0d0 -20.0d0 25.0d0) ; one root
(solve-quadratic 4.0d0 -20.0d0 21.0d0) ; two roots (solve-quadratic 4.0d0 -20.0d0 21.0d0) ; two roots
...@@ -242,10 +244,10 @@ ...@@ -242,10 +244,10 @@
(solve-cubic-complex -57.0d0 1071.0d0 -6647.0d0) (solve-cubic-complex -57.0d0 1071.0d0 -6647.0d0)
(solve-cubic-complex -11.0d0 -493.0d0 +6647.0d0) (solve-cubic-complex -11.0d0 -493.0d0 +6647.0d0)
(solve-cubic-complex -143.0d0 5087.0d0 -50065.0d0) (solve-cubic-complex -143.0d0 5087.0d0 -50065.0d0)
(grid:copy-to (polynomial-solve #m(-120 274 -225 85 -15 1.0))) (grid:copy-to (polynomial-solve #m(-120.0d0 274.0d0 -225.0d0 85.0d0 -15.0d0 1.0d0)))
(grid:copy-to (polynomial-solve #m(1 0 0 0 1 0 0 0 1))) (grid:copy-to (polynomial-solve #m(1.0d0 0.0d0 0.0d0 0.0d0 1.0d0 0.0d0 0.0d0 0.0d0 1.0d0)))
(let* ((xa #m(0.16 0.97 1.94 2.74 3.58 3.73 4.70)) (let* ((xa #m(0.16d0 0.97d0 1.94d0 2.74d0 3.58d0 3.73d0 4.70d0))
(ya #m(0.73 1.11 1.49 1.84 2.30 2.41 3.07)) (ya #m(0.73d0 1.11d0 1.49d0 1.84d0 2.30d0 2.41d0 3.07d0))
(dd (divided-difference xa ya))) (dd (divided-difference xa ya)))
(list (list
(grid:copy-to dd) (grid:copy-to dd)
......
;; Psi (digamma) functions ;; Psi (digamma) functions
;; Liam Healy, Mon May 1 2006 - 22:11 ;; Liam Healy, Mon May 1 2006 - 22:11
;; Time-stamp: <2009-12-27 10:10:00EST psi.lisp> ;; Time-stamp: <2011-01-10 10:21:07EST psi.lisp>
;; ;;
;; Copyright 2006, 2007, 2008, 2009 Liam M. Healy ;; Copyright 2006, 2007, 2008, 2009, 2011 Liam M. Healy
;; Distributed under the terms of the GNU General Public License ;; Distributed under the terms of the GNU General Public License
;; ;;
;; This program is free software: you can redistribute it and/or modify ;; This program is free software: you can redistribute it and/or modify
...@@ -20,6 +20,11 @@ ...@@ -20,6 +20,11 @@
(in-package :gsl) (in-package :gsl)
;;; antik:psi means "pounds per square inch" but there's no conflict
;;; here with the function #'gsl:psi, so we shadow import the symbol
;;; from antik.
(shadowing-import 'antik:psi)
;;;;**************************************************************************** ;;;;****************************************************************************
;;;; Digamma Function ;;;; Digamma Function
;;;;**************************************************************************** ;;;;****************************************************************************
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment