Changeset 3741


Ignore:
Timestamp:
Oct 7, 2015 10:51:10 AM (4 years ago)
Author:
bradbell
Message:

merge to branch: trunk
from repository: https://github.com/coin-or/CppAD
start hash code: cd48f5689e158e2758a3bfb57f2e6285b62b8ec1
end hash code: 561a31b99cdbf7b162480026f4fc2ea8efe4d62a

commit 561a31b99cdbf7b162480026f4fc2ea8efe4d62a
Author: Brad Bell <bradbell@…>
Date: Wed Oct 7 07:48:49 2015 -0700

Fix auto-tools install and test (mistake in move of old_atomic).
makefile.in: automatic changes.
makefile.in: automatic changes.

commit 3258aae589805d9c65b4e7030315bac61dd3b650
Author: Brad Bell <bradbell@…>
Date: Wed Oct 7 07:11:50 2015 -0700

  1. Use chosen sparsity (not inside timiming so has no effect).
  2. remove some invisible white space.

commit 0569b4eb838712ce6dea6450ecf131f80c972947
Author: Brad Bell <bradbell@…>
Date: Wed Oct 7 06:17:00 2015 -0700

reduce_index.py: exclude more simple prepositions.

Location:
trunk
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/bin/reduce_index.py

    r3740 r3741  
    1616# -----------------------------------------------------------------------------
    1717# list of words that should be excluded from mindex comamnds
    18 exclude_list = ['as', 'in', 'of', 'or', 'to']
     18exclude_list = 'a an and as at by for in of or to'.split()
    1919# -----------------------------------------------------------------------------
    2020def split_words(string) :
    21         pattern = '[^A-Za-z_]'
     21        pattern = '(\s|,)'
    2222        replace = ' '
    2323        string  = re.sub(pattern, replace, string)
  • trunk/example/atomic/makefile.am

    r3740 r3741  
    3333        reciprocal.cpp \
    3434        sparsity.cpp \
    35         tangent.cpp \
    36         old_mat_mul.hpp \
     35        tangent.cpp
    3736
    3837test: check
  • trunk/example/atomic/makefile.in

    r3717 r3741  
    101101        get_started.$(OBJEXT) hes_sparse.$(OBJEXT) mat_mul.$(OBJEXT) \
    102102        norm_sq.$(OBJEXT) reciprocal.$(OBJEXT) sparsity.$(OBJEXT) \
    103         tangent.$(OBJEXT) old_mat_mul.$(OBJEXT) \
    104         old_reciprocal.$(OBJEXT) old_tan.$(OBJEXT) \
    105         old_usead_1.$(OBJEXT) old_usead_2.$(OBJEXT)
     103        tangent.$(OBJEXT)
    106104atomic_OBJECTS = $(am_atomic_OBJECTS)
    107105atomic_LDADD = $(LDADD)
     
    135133am__v_CXXLD_0 = @echo "  CXXLD   " $@;
    136134am__v_CXXLD_1 =
    137 COMPILE = $(CC) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) \
    138         $(CPPFLAGS) $(AM_CFLAGS) $(CFLAGS)
    139 AM_V_CC = $(am__v_CC_@AM_V@)
    140 am__v_CC_ = $(am__v_CC_@AM_DEFAULT_V@)
    141 am__v_CC_0 = @echo "  CC      " $@;
    142 am__v_CC_1 =
    143 CCLD = $(CC)
    144 LINK = $(CCLD) $(AM_CFLAGS) $(CFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
    145 AM_V_CCLD = $(am__v_CCLD_@AM_V@)
    146 am__v_CCLD_ = $(am__v_CCLD_@AM_DEFAULT_V@)
    147 am__v_CCLD_0 = @echo "  CCLD    " $@;
    148 am__v_CCLD_1 =
    149135SOURCES = $(atomic_SOURCES)
    150136DIST_SOURCES = $(atomic_SOURCES)
     
    206192# $Id$
    207193# -----------------------------------------------------------------------------
    208 # CppAD: C++ Algorithmic Differentiation: Copyright (C) 2003-13 Bradley M. Bell
     194# CppAD: C++ Algorithmic Differentiation: Copyright (C) 2003-15 Bradley M. Bell
    209195#
    210196# CppAD is distributed under multiple licenses. This distribution is under
    211 # the terms of the 
     197# the terms of the
    212198#                     Eclipse Public License Version 1.0.
    213199#
     
    350336top_srcdir = @top_srcdir@
    351337#
    352 AM_CXXFLAGS = -g $(CXX_FLAGS) 
     338AM_CXXFLAGS = -g $(CXX_FLAGS)
    353339#
    354340AM_CPPFLAGS = -I. \
    355341        -I$(top_srcdir) \
    356342        $(BOOST_INCLUDE) \
    357         $(EIGEN_INCLUDE) 
     343        $(EIGEN_INCLUDE)
    358344
    359345#
     
    367353        reciprocal.cpp \
    368354        sparsity.cpp \
    369         tangent.cpp \
    370         old_mat_mul.hpp \
    371         old_mat_mul.cpp \
    372         old_reciprocal.cpp \
    373         old_tan.cpp \
    374         old_usead_1.cpp \
    375         old_usead_2.cpp
     355        tangent.cpp
    376356
    377357all: all-am
     
    428408@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/mat_mul.Po@am__quote@
    429409@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/norm_sq.Po@am__quote@
    430 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_mat_mul.Po@am__quote@
    431 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_reciprocal.Po@am__quote@
    432 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_tan.Po@am__quote@
    433 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_usead_1.Po@am__quote@
    434 @AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_usead_2.Po@am__quote@
    435410@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/reciprocal.Po@am__quote@
    436411@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/sparsity.Po@am__quote@
  • trunk/speed/cppad/mat_mul.cpp

    r3607 r3741  
    44
    55CppAD is distributed under multiple licenses. This distribution is under
    6 the terms of the 
     6the terms of the
    77                    Eclipse Public License Version 1.0.
    88
     
    2828        dz
    2929        typedef
     30        boolsparsity
     31        enum
    3032$$
    3133
    32 $section CppAD Speed: Matrix Multiplication$$
     34$section CppAD Speed, Matrix Multiplication$$
     35$mindex link_mat_mul multiply$$
    3336
    34 $index link_mat_mul, cppad$$
    35 $index cppad, link_mat_mul$$
    36 $index speed, cppad$$
    37 $index cppad, speed$$
    38 $index matrix, speed cppad$$
    39 $index multiply, speed cppad$$
    4037
    4138$head Specifications$$
     
    5249// Note that CppAD uses global_memory at the main program level
    5350extern bool
    54         global_onetape, global_atomic, global_optimize;
     51        global_onetape, global_atomic, global_optimize, global_boolsparsity;
    5552
    5653bool link_mat_mul(
    57         size_t                           size     , 
    58         size_t                           repeat   , 
     54        size_t                           size     ,
     55        size_t                           repeat   ,
    5956        CppAD::vector<double>&           x        ,
    6057        CppAD::vector<double>&           z        ,
     
    6461        // -----------------------------------------------------
    6562        // setup
    66         typedef CppAD::AD<double>           ADScalar; 
    67         typedef CppAD::vector<ADScalar>     ADVector; 
     63        typedef CppAD::AD<double>           ADScalar;
     64        typedef CppAD::vector<ADScalar>     ADVector;
    6865
    6966        size_t j;               // temporary index
     
    7471        ADVector   Z(m);        // AD range space vector
    7572        CppAD::ADFun<double> f; // AD function object
    76        
    77         // vectors of reverse mode weights 
     73
     74        // vectors of reverse mode weights
    7875        CppAD::vector<double> w(1);
    7976        w[0] = 1.;
     
    8582        size_t nc_result = size;
    8683        matrix_mul atom_mul(nr_result, n_middle, nc_result);
    87 
     84        //
     85        if( global_boolsparsity )
     86                atom_mul.option( CppAD::atomic_base<double>::pack_sparsity_enum );
     87        else
     88                atom_mul.option( CppAD::atomic_base<double>::set_sparsity_enum );
    8889        // ------------------------------------------------------
    8990        if( ! global_onetape ) while(repeat--)
     
    109110                        for(j = 0; j < n; j++)
    110111                                Z[0] += ay[j];
    111                 } 
     112                }
    112113                // create function object f : X -> Z
    113114                f.Dependent(X, Z);
     
    145146                        for(j = 0; j < n; j++)
    146147                                Z[0] += ay[j];
    147                 } 
    148        
     148                }
     149
    149150                // create function object f : X -> Z
    150151                f.Dependent(X, Z);
     
    166167        }
    167168        // --------------------------------------------------------------------
    168         // Free temporary work space. (If there are future calls to 
     169        // Free temporary work space. (If there are future calls to
    169170        // mat_mul they would create new temporary work space.)
    170171        CppAD::user_atomic<double>::clear();
  • trunk/test_more/makefile.am

    r3740 r3741  
    8686#
    8787test_more_SOURCES  = \
    88         old_usead_2.cpp \
    89         old_usead_1.cpp \
    90         old_tan.cpp \
    91         old_reciprocal.cpp \
    92         old_mat_mul.cpp \
    9388        $(ADOLC_SRC_FILES) \
    9489        $(IPOPT_SRC_FILES) \
     
    151146        neg.cpp \
    152147        ode_err_control.cpp \
     148        old_usead_2.cpp \
     149        old_usead_1.cpp \
     150        old_tan.cpp \
     151        old_reciprocal.cpp \
     152        old_mat_mul.cpp \
     153        old_mat_mul.hpp \
    153154        omp_alloc.cpp \
    154155        optimize.cpp \
  • trunk/test_more/makefile.in

    r3738 r3741  
    125125        mul_cskip.cpp mul_eq.cpp mul_level.cpp mul_cond_rev.cpp \
    126126        mul_zdouble.cpp mul_zero_one.cpp near_equal_ext.cpp neg.cpp \
    127         ode_err_control.cpp omp_alloc.cpp optimize.cpp parameter.cpp \
    128         poly.cpp pow.cpp pow_int.cpp print_for.cpp romberg_one.cpp \
    129         rosen_34.cpp runge_45.cpp reverse.cpp rev_sparse_hes.cpp \
    130         rev_sparse_jac.cpp rev_two.cpp simple_vector.cpp sin.cpp \
    131         sin_cos.cpp sinh.cpp sparse_hessian.cpp sparse_jacobian.cpp \
    132         sparse_vec_ad.cpp sqrt.cpp std_math.cpp sub.cpp sub_eq.cpp \
    133         sub_zero.cpp tan.cpp test_vector.cpp track_new_del.cpp \
    134         value.cpp vec_ad.cpp vec_ad_par.cpp vec_unary.cpp zdouble.cpp
     127        ode_err_control.cpp old_usead_2.cpp old_usead_1.cpp \
     128        old_tan.cpp old_reciprocal.cpp old_mat_mul.cpp old_mat_mul.hpp \
     129        omp_alloc.cpp optimize.cpp parameter.cpp poly.cpp pow.cpp \
     130        pow_int.cpp print_for.cpp romberg_one.cpp rosen_34.cpp \
     131        runge_45.cpp reverse.cpp rev_sparse_hes.cpp rev_sparse_jac.cpp \
     132        rev_two.cpp simple_vector.cpp sin.cpp sin_cos.cpp sinh.cpp \
     133        sparse_hessian.cpp sparse_jacobian.cpp sparse_vec_ad.cpp \
     134        sqrt.cpp std_math.cpp sub.cpp sub_eq.cpp sub_zero.cpp tan.cpp \
     135        test_vector.cpp track_new_del.cpp value.cpp vec_ad.cpp \
     136        vec_ad_par.cpp vec_unary.cpp zdouble.cpp
    135137@CppAD_ADOLC_TRUE@am__objects_1 = base_adolc.$(OBJEXT)
    136138@CppAD_IPOPT_TRUE@am__objects_2 = ipopt_solve.$(OBJEXT)
     
    158160        mul_zdouble.$(OBJEXT) mul_zero_one.$(OBJEXT) \
    159161        near_equal_ext.$(OBJEXT) neg.$(OBJEXT) \
    160         ode_err_control.$(OBJEXT) omp_alloc.$(OBJEXT) \
    161         optimize.$(OBJEXT) parameter.$(OBJEXT) poly.$(OBJEXT) \
    162         pow.$(OBJEXT) pow_int.$(OBJEXT) print_for.$(OBJEXT) \
    163         romberg_one.$(OBJEXT) rosen_34.$(OBJEXT) runge_45.$(OBJEXT) \
    164         reverse.$(OBJEXT) rev_sparse_hes.$(OBJEXT) \
     162        ode_err_control.$(OBJEXT) old_usead_2.$(OBJEXT) \
     163        old_usead_1.$(OBJEXT) old_tan.$(OBJEXT) \
     164        old_reciprocal.$(OBJEXT) old_mat_mul.$(OBJEXT) \
     165        omp_alloc.$(OBJEXT) optimize.$(OBJEXT) parameter.$(OBJEXT) \
     166        poly.$(OBJEXT) pow.$(OBJEXT) pow_int.$(OBJEXT) \
     167        print_for.$(OBJEXT) romberg_one.$(OBJEXT) rosen_34.$(OBJEXT) \
     168        runge_45.$(OBJEXT) reverse.$(OBJEXT) rev_sparse_hes.$(OBJEXT) \
    165169        rev_sparse_jac.$(OBJEXT) rev_two.$(OBJEXT) \
    166170        simple_vector.$(OBJEXT) sin.$(OBJEXT) sin_cos.$(OBJEXT) \
     
    551555        neg.cpp \
    552556        ode_err_control.cpp \
     557        old_usead_2.cpp \
     558        old_usead_1.cpp \
     559        old_tan.cpp \
     560        old_reciprocal.cpp \
     561        old_mat_mul.cpp \
     562        old_mat_mul.hpp \
    553563        omp_alloc.cpp \
    554564        optimize.cpp \
     
    702712@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/num_limits.Po@am__quote@
    703713@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/ode_err_control.Po@am__quote@
     714@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_mat_mul.Po@am__quote@
     715@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_reciprocal.Po@am__quote@
     716@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_tan.Po@am__quote@
     717@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_usead_1.Po@am__quote@
     718@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/old_usead_2.Po@am__quote@
    704719@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/omp_alloc.Po@am__quote@
    705720@AMDEP_TRUE@@am__include@ @am__quote@./$(DEPDIR)/optimize.Po@am__quote@
Note: See TracChangeset for help on using the changeset viewer.