Boost logo

Boost-Commit :

From: john_at_[hidden]
Date: 2007-08-26 14:40:19


Author: johnmaddock
Date: 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
New Revision: 38972
URL: http://svn.boost.org/trac/boost/changeset/38972

Log:
Renamed over-long files and sections.
Added:
   sandbox/math_toolkit/libs/math/example/neg_binom_confidence_limits.cpp
      - copied unchanged from r38968, /sandbox/math_toolkit/libs/math/example/neg_binomial_confidence_limits.cpp
   sandbox/math_toolkit/libs/math/test/compile_test/dist_neg_binom_incl_test.cpp
      - copied unchanged from r38968, /sandbox/math_toolkit/libs/math/test/compile_test/dist_negative_binomial_incl_test.cpp
   sandbox/math_toolkit/libs/math/test/compile_test/sf_sph_harm_incl_test.cpp
      - copied unchanged from r38968, /sandbox/math_toolkit/libs/math/test/compile_test/sf_spherical_harmonic_incl_test.cpp
Removed:
   sandbox/math_toolkit/libs/math/example/neg_binomial_confidence_limits.cpp
   sandbox/math_toolkit/libs/math/test/compile_test/dist_negative_binomial_incl_test.cpp
   sandbox/math_toolkit/libs/math/test/compile_test/sf_spherical_harmonic_incl_test.cpp
Text files modified:
   sandbox/math_toolkit/libs/math/doc/concepts.qbk | 18 +++++++++---------
   sandbox/math_toolkit/libs/math/doc/distributions/negative_binomial_example.qbk | 6 +++---
   sandbox/math_toolkit/libs/math/doc/math.qbk | 4 ++--
   sandbox/math_toolkit/libs/math/doc/minimax.qbk | 2 +-
   sandbox/math_toolkit/libs/math/doc/result_type_calc.qbk | 2 +-
   sandbox/math_toolkit/libs/math/test/Jamfile.v2 | 5 +++--
   6 files changed, 19 insertions(+), 18 deletions(-)

Modified: sandbox/math_toolkit/libs/math/doc/concepts.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/concepts.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/concepts.qbk 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -1,4 +1,4 @@
-[section:use_NTL Using With NTL - a High-Precision Floating-Point Library]
+[section:use_ntl Using With NTL - a High-Precision Floating-Point Library]
 
 The special functions and tools in this library can be used with
 [@http://shoup.net/ntl/doc/RR.txt NTL::RR (an arbitrary precision number type)],
@@ -33,7 +33,7 @@
 function headers (if you don't use it, you'll get a slower, but
 fully generic implementation for all of the gamma-like functions).
 
-[endsect][/section:use_NTL Using With NTL - a High Precision Floating-Point Library]
+[endsect][/section:use_ntl Using With NTL - a High Precision Floating-Point Library]
 
 [section:concepts Conceptual Requirements for Real Number Types]
 
@@ -41,7 +41,7 @@
 any type /RealType/ that meets the conceptual requirements given below. All
 the built in floating point types will meet these requirements.
 User defined types that meet the requirements can also be used. For example,
-with [link math_toolkit.Using_UDT.use_NTL minor modifications] two of the types
+with [link math_toolkit.using_udt.use_ntl minor modifications] two of the types
 provided with [@http://shoup.net/ntl/ NTL (RR and quad_float)] can be used.
 
 The guiding principal behind these requirements, is that a /RealType/
@@ -301,7 +301,7 @@
    
    }}} // namespaces
 
-`real_concept` is an archetype for [link math_toolkit.Using_UDT.concepts
+`real_concept` is an archetype for [link math_toolkit.using_udt.concepts
 user defined real types], it
 declares it's standard library functions in it's own
 namespace: these will only be found if they are called unqualified
@@ -310,11 +310,11 @@
 this allows code that would not otherwise be exercised by the built-in
 floating point types to be tested. There is no std::numeric_limits<>
 support for this type, since this is not a conceptual requirement
-for [link math_toolkit.Using_UDT.concepts RealType]'s.
+for [link math_toolkit.using_udt.concepts RealType]'s.
 
 NTL RR is an example of a type meeting the requirements that this type
 models, but note minor additions are needed - see ntl.diff and documentation
-[link math_toolkit.Using_UDT.use_NTL "Using With NTL - a High-Precision Floating-Point Library"].
+[link math_toolkit.using_udt.use_ntl "Using With NTL - a High-Precision Floating-Point Library"].
 
 There is no specific test case for type `real_concept`, instead, since this
 type is usable at runtime, each individual test case as well as testing
@@ -335,7 +335,7 @@
    }}} // namespaces
    
 The class template `distribution_archetype` is a model of the
-[link math_toolkit.Using_UDT.dist_concept Distribution concept].
+[link math_toolkit.using_udt.dist_concept Distribution concept].
 
 The class template `DistributionConcept` is a
 [@../../../../libs/concept_check/index.html concept checking class]
@@ -345,11 +345,11 @@
 [@../../test/distribution_concept_check.cpp distribution_concept_check.cpp]
 is responsible for using `DistributionConcept` to verify that all the
 distributions in this library conform to the
-[link math_toolkit.Using_UDT.dist_concept Distribution concept].
+[link math_toolkit.using_udt.dist_concept Distribution concept].
 
 The class template `DistributionConcept` verifies the existence
 (but not proper function) of the non-member accessors
-required by the [link math_toolkit.Using_UDT.dist_concept Distribution concept].
+required by the [link math_toolkit.using_udt.dist_concept Distribution concept].
 These are checked by calls like
 
 v = pdf(dist, x); // (Result v is ignored).

Modified: sandbox/math_toolkit/libs/math/doc/distributions/negative_binomial_example.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/distributions/negative_binomial_example.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/distributions/negative_binomial_example.qbk 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -20,10 +20,10 @@
 `negative_binomial_distribution<>::find_upper_bound_on_p`
 allow you to calculate the confidence intervals for your estimate of the success fraction.
 
-The sample program [@../../example/neg_binomial_confidence_limits.cpp
-neg_binomial_confidence_limits.cpp] illustrates their use.
+The sample program [@../../example/neg_binom_confidence_limits.cpp
+neg_binom_confidence_limits.cpp] illustrates their use.
 
-[import ../../example/neg_binomial_confidence_limits.cpp]
+[import ../../example/neg_binom_confidence_limits.cpp]
 
 [neg_binomial_confidence_limits]
 Let's see some sample output for a 1 in 10

Modified: sandbox/math_toolkit/libs/math/doc/math.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/math.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/math.qbk 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -402,9 +402,9 @@
 
 [endsect] [/section:toolkit Toolkit]
 
-[section:Using_UDT Use with User Defined Floating-Point Types]
+[section:using_udt Use with User Defined Floating-Point Types]
 [include concepts.qbk]
-[endsect] [/section:Using_UDT Use with User Defined Floating-Point Types]
+[endsect] [/section:using_udt Use with User Defined Floating-Point Types]
 
 [include policy.qbk]
 

Modified: sandbox/math_toolkit/libs/math/doc/minimax.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/minimax.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/minimax.qbk 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -33,7 +33,7 @@
 after the existing examples.
 
 In addition to those two files, the program needs to be linked to
-a [link math_toolkit.Using_UDT.use_NTL patched NTL library to compile].
+a [link math_toolkit.using_udt.use_ntl patched NTL library to compile].
 
 Note that the function /f/ must return the rational part of the
 approximation: for example if you are approximating a function

Modified: sandbox/math_toolkit/libs/math/doc/result_type_calc.qbk
==============================================================================
--- sandbox/math_toolkit/libs/math/doc/result_type_calc.qbk (original)
+++ sandbox/math_toolkit/libs/math/doc/result_type_calc.qbk 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -55,7 +55,7 @@
    
 In the last case, quad_float is convertible to RR, but not vice-versa, so
 the result will be an NTL::RR. Note that this assumes that you are using
-a [link math_toolkit.Using_UDT.use_NTL patched NTL library].
+a [link math_toolkit.using_udt.use_ntl patched NTL library].
 
 These rules are chosen to be compatible with the behaviour of
 ['ISO/IEC 9899:1999 Programming languages - C]

Deleted: sandbox/math_toolkit/libs/math/example/neg_binomial_confidence_limits.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/example/neg_binomial_confidence_limits.cpp 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
+++ (empty file)
@@ -1,179 +0,0 @@
-// neg_binomial_confidence_limits.cpp
-
-// Copyright John Maddock 2006
-// Copyright Paul A. Bristow 2007
-// Use, modification and distribution are subject to the
-// Boost Software License, Version 1.0.
-// (See accompanying file LICENSE_1_0.txt
-// or copy at http://www.boost.org/LICENSE_1_0.txt)
-
-// Caution: this file contains quickbook markup as well as code
-// and comments, don't change any of the special comment markups!
-
-//[neg_binomial_confidence_limits
-
-/*`
-
-First we need some includes to access the negative binomial distribution
-(and some basic std output of course).
-
-*/
-
-#include <boost/math/distributions/negative_binomial.hpp>
-using boost::math::negative_binomial;
-
-#include <iostream>
-using std::cout; using std::endl;
-#include <iomanip>
-using std::setprecision;
-using std::setw; using std::left; using std::fixed; using std::right;
-
-/*`
-First define a table of significance levels: these are the
-probabilities that the true occurrence frequency lies outside the calculated
-interval:
-*/
-
- double alpha[] = { 0.5, 0.25, 0.1, 0.05, 0.01, 0.001, 0.0001, 0.00001 };
-
-/*`
-
-Confidence value as % is (1 - alpha) * 100, so alpha 0.05 == 95% confidence
-that the true occurence frequency lies *inside* the calculated interval.
-
-We need a function to calculate and print confidence limits
-for an observed frequency of occurrence
-that follows a negative binomial distribution.
-
-*/
-
-void confidence_limits_on_frequency(unsigned trials, unsigned successes)
-{
- // trials = Total number of trials.
- // successes = Total number of observed successes.
- // failures = trials - successes.
- // success_fraction = successes /trials.
- // Print out general info:
- cout <<
- "______________________________________________\n"
- "2-Sided Confidence Limits For Success Fraction\n"
- "______________________________________________\n\n";
- cout << setprecision(7);
- cout << setw(40) << left << "Number of trials" << " = " << trials << "\n";
- cout << setw(40) << left << "Number of successes" << " = " << successes << "\n";
- cout << setw(40) << left << "Number of failures" << " = " << trials - successes << "\n";
- cout << setw(40) << left << "Observed frequency of occurrence" << " = " << double(successes) / trials << "\n";
-
- // Print table header:
- cout << "\n\n"
- "___________________________________________\n"
- "Confidence Lower Upper\n"
- " Value (%) Limit Limit\n"
- "___________________________________________\n";
-
-
-/*`
-And now for the important part - the bounds themselves.
-For each value of /alpha/, we call `find_lower_bound_on_p` and
-`find_upper_bound_on_p` to obtain lower and upper bounds respectively.
-Note that since we are calculating a two-sided interval,
-we must divide the value of alpha in two. Had we been calculating a
-single-sided interval, for example: ['"Calculate a lower bound so that we are P%
-sure that the true occurrence frequency is greater than some value"]
-then we would *not* have divided by two.
-
-*/
-
- // Now print out the upper and lower limits for the alpha table values.
- for(unsigned i = 0; i < sizeof(alpha)/sizeof(alpha[0]); ++i)
- {
- // Confidence value:
- cout << fixed << setprecision(3) << setw(10) << right << 100 * (1-alpha[i]);
- // Calculate bounds:
- double lower = negative_binomial::find_lower_bound_on_p(trials, successes, alpha[i]/2);
- double upper = negative_binomial::find_upper_bound_on_p(trials, successes, alpha[i]/2);
- // Print limits:
- cout << fixed << setprecision(5) << setw(15) << right << lower;
- cout << fixed << setprecision(5) << setw(15) << right << upper << endl;
- }
- cout << endl;
-} // void confidence_limits_on_frequency(unsigned trials, unsigned successes)
-
-/*`
-
-And then call confidence_limits_on_frequency with increasing numbers of trials,
-but always the same success fraction 0.1, or 1 in 10.
-
-*/
-
-int main()
-{
- confidence_limits_on_frequency(20, 2); // 20 trials, 2 successes, 2 in 20, = 1 in 10 = 0.1 success fraction.
- confidence_limits_on_frequency(200, 20); // More trials, but same 0.1 success fraction.
- confidence_limits_on_frequency(2000, 200); // Many more trials, but same 0.1 success fraction.
-
- return 0;
-} // int main()
-
-//] [/negative_binomial_confidence_limits_eg end of Quickbook in C++ markup]
-
-/*
-
-______________________________________________
-2-Sided Confidence Limits For Success Fraction
-______________________________________________
-Number of trials = 20
-Number of successes = 2
-Number of failures = 18
-Observed frequency of occurrence = 0.1
-___________________________________________
-Confidence Lower Upper
- Value (%) Limit Limit
-___________________________________________
- 50.000 0.04812 0.13554
- 75.000 0.03078 0.17727
- 90.000 0.01807 0.22637
- 95.000 0.01235 0.26028
- 99.000 0.00530 0.33111
- 99.900 0.00164 0.41802
- 99.990 0.00051 0.49202
- 99.999 0.00016 0.55574
-______________________________________________
-2-Sided Confidence Limits For Success Fraction
-______________________________________________
-Number of trials = 200
-Number of successes = 20
-Number of failures = 180
-Observed frequency of occurrence = 0.1000000
-___________________________________________
-Confidence Lower Upper
- Value (%) Limit Limit
-___________________________________________
- 50.000 0.08462 0.11350
- 75.000 0.07580 0.12469
- 90.000 0.06726 0.13695
- 95.000 0.06216 0.14508
- 99.000 0.05293 0.16170
- 99.900 0.04343 0.18212
- 99.990 0.03641 0.20017
- 99.999 0.03095 0.21664
-______________________________________________
-2-Sided Confidence Limits For Success Fraction
-______________________________________________
-Number of trials = 2000
-Number of successes = 200
-Number of failures = 1800
-Observed frequency of occurrence = 0.1000000
-___________________________________________
-Confidence Lower Upper
- Value (%) Limit Limit
-___________________________________________
- 50.000 0.09536 0.10445
- 75.000 0.09228 0.10776
- 90.000 0.08916 0.11125
- 95.000 0.08720 0.11352
- 99.000 0.08344 0.11802
- 99.900 0.07921 0.12336
- 99.990 0.07577 0.12795
- 99.999 0.07282 0.13206
-*/
\ No newline at end of file

Modified: sandbox/math_toolkit/libs/math/test/Jamfile.v2
==============================================================================
--- sandbox/math_toolkit/libs/math/test/Jamfile.v2 (original)
+++ sandbox/math_toolkit/libs/math/test/Jamfile.v2 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
@@ -125,7 +125,7 @@
 compile compile_test/dist_fisher_f_incl_test.cpp ;
 compile compile_test/dist_gamma_incl_test.cpp ;
 compile compile_test/dist_lognormal_incl_test.cpp ;
-compile compile_test/dist_negative_binomial_incl_test.cpp ;
+compile compile_test/dist_neg_binom_incl_test.cpp ;
 compile compile_test/dist_normal_incl_test.cpp ;
 compile compile_test/dist_poisson_incl_test.cpp ;
 compile compile_test/dist_students_t_incl_test.cpp ;
@@ -163,7 +163,7 @@
 compile compile_test/sf_sin_pi_incl_test.cpp ;
 compile compile_test/sf_sinc_incl_test.cpp ;
 compile compile_test/sf_sinhc_incl_test.cpp ;
-compile compile_test/sf_spherical_harmonic_incl_test.cpp ;
+compile compile_test/sf_sph_harm_incl_test.cpp ;
 compile compile_test/sf_sqrt1pm1_incl_test.cpp ;
 compile compile_test/std_real_concept_check.cpp ;
 compile compile_test/tools_config_inc_test.cpp ;
@@ -187,3 +187,4 @@
 
 
 
+

Deleted: sandbox/math_toolkit/libs/math/test/compile_test/dist_negative_binomial_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/dist_negative_binomial_incl_test.cpp 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
+++ (empty file)
@@ -1,13 +0,0 @@
-// Copyright John Maddock 2006.
-// Use, modification and distribution are subject to the
-// Boost Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// Basic sanity check that header <boost/math/distributions/negative_binomial.hpp>
-// #includes all the files that it needs to.
-//
-#include <boost/math/distributions/negative_binomial.hpp>
-
-template class boost::math::negative_binomial_distribution<float, boost::math::policies::policy<> >;
-template class boost::math::negative_binomial_distribution<double, boost::math::policies::policy<> >;
-template class boost::math::negative_binomial_distribution<long double, boost::math::policies::policy<> >;

Deleted: sandbox/math_toolkit/libs/math/test/compile_test/sf_spherical_harmonic_incl_test.cpp
==============================================================================
--- sandbox/math_toolkit/libs/math/test/compile_test/sf_spherical_harmonic_incl_test.cpp 2007-08-26 14:40:16 EDT (Sun, 26 Aug 2007)
+++ (empty file)
@@ -1,24 +0,0 @@
-// Copyright John Maddock 2006.
-// Use, modification and distribution are subject to the
-// Boost Software License, Version 1.0. (See accompanying file
-// LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
-//
-// Basic sanity check that header <boost/math/special_functions/spherical_harmonic.hpp>
-// #includes all the files that it needs to.
-//
-#include <boost/math/special_functions/spherical_harmonic.hpp>
-
-template std::complex<float> boost::math::spherical_harmonic<float>(unsigned, int, float, float);
-template std::complex<double> boost::math::spherical_harmonic<double>(unsigned, int, double, double);
-template std::complex<long double> boost::math::spherical_harmonic<long double>(unsigned, int, long double, long double);
-
-template float boost::math::spherical_harmonic_r<float>(unsigned, int, float, float);
-template double boost::math::spherical_harmonic_r<double>(unsigned, int, double, double);
-template long double boost::math::spherical_harmonic_r<long double>(unsigned, int, long double, long double);
-
-template float boost::math::spherical_harmonic_i<float>(unsigned, int, float, float);
-template double boost::math::spherical_harmonic_i<double>(unsigned, int, double, double);
-template long double boost::math::spherical_harmonic_i<long double>(unsigned, int, long double, long double);
-
-
-


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk