|
From: Matthias S. <mat...@us...> - 2007-03-29 20:24:06
|
Update of /cvsroot/boost-sandbox/boost-sandbox/boost/units/systems/conversions In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv29436 Added Files: convert_degrees_to_gradians.hpp convert_degrees_to_radians.hpp convert_gradians_to_degrees.hpp convert_gradians_to_radians.hpp convert_radians_to_degrees.hpp convert_radians_to_gradians.hpp Log Message: conversions for angles --- NEW FILE: convert_gradians_to_radians.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_GRADIANS_TO_RADIANS_HPP #define BOOST_UNITS_CONVERT_GRADIANS_TO_RADIANS_HPP #include <boost/units/systems/angles/convert_radians_to_gradians.hpp> } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_GRADIANS_TO_RADIANS_HPP --- NEW FILE: convert_gradians_to_degrees.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_GRADIANS_TO_DEGREES_HPP #define BOOST_UNITS_CONVERT_GRADIANS_TO_DEGREES_HPP #include <boost/units/systems/angles/convert_degrees_to_gradians.hpp> } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_GRADIANS_TO_DEGREES_HPP --- NEW FILE: convert_radians_to_gradians.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_RADIANS_TO_GRADIANS_HPP #define BOOST_UNITS_CONVERT_RADIANS_TO_GRADIANS_HPP #include <boost/units/conversion.hpp> #include <boost/units/systems/angles/gradians.hpp> #include <boost/units/systems/angles/radians.hpp> namespace boost { namespace units { // conversions from radians to gradians template<> struct base_unit_converter<angle_tag,angle::radian_system_tag,angle::gradian_system_tag> #ifdef BOOST_UNITS_ENABLE_IMPLICIT_UNIT_CONVERSION : public implicitly_convertible, trivial_inverse_conversion #endif { typedef double type; static type value() { return 200.0/3.1415926535897932385; } }; } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_RADIANS_TO_GRADIANS_HPP --- NEW FILE: convert_radians_to_degrees.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_RADIANS_TO_DEGREES_HPP #define BOOST_UNITS_CONVERT_RADIANS_TO_DEGREES_HPP #include <boost/units/conversion.hpp> #include <boost/units/systems/angles/degrees.hpp> #include <boost/units/systems/angles/radians.hpp> namespace boost { namespace units { // conversions from radians to degrees template<> struct base_unit_converter<angle_tag,angle::radian_system_tag,angle::degree_system_tag> #ifdef BOOST_UNITS_ENABLE_IMPLICIT_UNIT_CONVERSION : public implicitly_convertible, trivial_inverse_conversion #endif { typedef double type; static type value() { return 180.0/3.1415926535897932385; } }; } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_RADIANS_TO_DEGREES_HPP --- NEW FILE: convert_degrees_to_gradians.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_DEGREES_TO_GRADIANS_HPP #define BOOST_UNITS_CONVERT_DEGREES_TO_GRADIANS_HPP #include <boost/units/conversion.hpp> #include <boost/units/systems/angles/degrees.hpp> #include <boost/units/systems/angles/gradians.hpp> namespace boost { namespace units { // conversions from degrees to gradians template<> struct base_unit_converter<angle_tag,angle::degree_system_tag,angle::gradian_system_tag> #ifdef BOOST_UNITS_ENABLE_IMPLICIT_UNIT_CONVERSION : public implicitly_convertible, trivial_inverse_conversion #endif { typedef double type; static type value() { return 200.0/180.0; } }; } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_DEGREES_TO_GRADIANS_HPP --- NEW FILE: convert_degrees_to_radians.hpp --- // mcs::units - A C++ library for zero-overhead dimensional analysis and // unit/quantity manipulation and conversion // // Copyright (C) 2003-2007 Matthias Christian Schabel // Copyright (C) 2007 Steven Watanabe // // Distributed under 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) #ifndef BOOST_UNITS_CONVERT_DEGREES_TO_RADIANS_HPP #define BOOST_UNITS_CONVERT_DEGREES_TO_RADIANS_HPP #include <boost/units/systems/angles/convert_degrees_to_radians.hpp> } // namespace units } // namespace boost #endif // BOOST_UNITS_CONVERT_DEGREES_TO_RADIANS_HPP |