DriveHQ Start Menu
Cloud Drive Mapping
Folder Sync
Cloud Backup
True Drop Box
FTP/SFTP Hosting
Group Account
DriveHQ Start Menu
Online File Server
My Storage
|
Manage Shares
|
Publishes
|
Drop Boxes
|
Group Account
WebDAV Drive Mapping
Cloud Drive Home
|
WebDAV Guide
|
Drive Mapping Tool
|
Drive Mapping URL
Complete Data Backup
Backup Guide
|
Online Backup Tool
|
Cloud-to-Cloud Backup
FTP, Email & Web Service
FTP Home
|
FTP Hosting FAQ
|
Email Hosting
|
EmailManager
|
Web Hosting
Help & Resources
About
|
Enterprise Service
|
Partnership
|
Comparisons
|
Support
Quick Links
Security and Privacy
Download Software
Service Manual
Use Cases
Group Account
Online Help
Blog
Contact
Cloud Surveillance
Sign Up
Login
Features
Business Features
Online File Server
FTP Hosting
Cloud Drive Mapping
Cloud File Backup
Email Backup & Hosting
Cloud File Sharing
Folder Synchronization
Group Management
True Drop Box
Full-text Search
AD Integration/SSO
Mobile Access
IP Camera & DVR Solution
More...
Personal Features
Personal Cloud Drive
Backup All Devices
Mobile APPs
Personal Web Hosting
Sub-Account (for Kids)
Home/PC/Kids Monitoring
More...
Software
DriveHQ Drive Mapping Tool
DriveHQ FileManager
DriveHQ Online Backup
DriveHQ Mobile Apps
Pricing
Business Plans & Pricing
Personal Plans & Pricing
Price Comparison with Others
Feature Comparison with Others
Install Mobile App
Sign up
Creating account...
Invalid character in username! Only 0-9, a-z, A-Z, _, -, . allowed.
Username is required!
Invalid email address!
E-mail is required!
Password is required!
Password is invalid!
Password and confirmation do not match.
Confirm password is required!
I accept
Membership Agreement
Please read the Membership Agreement and check "I accept"!
Free Quick Sign-up
Sign-up Page
Log in
Signing in...
Username or e-mail address is required!
Password is required!
Keep me logged in
Quick Login
Forgot Password
Up
Upload
Download
Share
Publish
New Folder
New File
Copy
Cut
Delete
Paste
Rate
Upgrade
Rotate
Effect
Edit
Slide
History
// // Copyright (c) 2000-2002 // Joerg Walter, Mathias Koch // // 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) // // The authors gratefully acknowledge the support of // GeNeSys mbH & Co. KG in producing this work. // #ifndef _BOOST_UBLAS_OPERATION_BLOCKED_ #define _BOOST_UBLAS_OPERATION_BLOCKED_ #include
#include
// indexing_vector_assign #include
// indexing_matrix_assign namespace boost { namespace numeric { namespace ublas { template
BOOST_UBLAS_INLINE V block_prod (const matrix_expression
&e1, const vector_expression
&e2) { typedef V vector_type; typedef const E1 expression1_type; typedef const E2 expression2_type; typedef typename V::size_type size_type; typedef typename V::value_type value_type; const size_type block_size = BS; V v (e1 ().size1 ()); #if BOOST_UBLAS_TYPE_CHECK vector
cv (v.size ()); typedef typename type_traits
::real_type real_type; real_type verrorbound (norm_1 (v) + norm_1 (e1) * norm_1 (e2)); indexing_vector_assign
(cv, prod (e1, e2)); #endif size_type i_size = e1 ().size1 (); size_type j_size = BOOST_UBLAS_SAME (e1 ().size2 (), e2 ().size ()); for (size_type i_begin = 0; i_begin < i_size; i_begin += block_size) { size_type i_end = i_begin + (std::min) (i_size - i_begin, block_size); // FIX: never ignore Martin Weiser's advice ;-( #ifdef BOOST_UBLAS_NO_CACHE vector_range
v_range (v, range (i_begin, i_end)); #else // vector
> v_range (i_end - i_begin); vector
v_range (i_end - i_begin); #endif v_range.assign (zero_vector
(i_end - i_begin)); for (size_type j_begin = 0; j_begin < j_size; j_begin += block_size) { size_type j_end = j_begin + (std::min) (j_size - j_begin, block_size); #ifdef BOOST_UBLAS_NO_CACHE const matrix_range
e1_range (e1 (), range (i_begin, i_end), range (j_begin, j_end)); const vector_range
e2_range (e2 (), range (j_begin, j_end)); v_range.plus_assign (prod (e1_range, e2_range)); #else // const matrix
> e1_range (project (e1 (), range (i_begin, i_end), range (j_begin, j_end))); // const vector
> e2_range (project (e2 (), range (j_begin, j_end))); const matrix
e1_range (project (e1 (), range (i_begin, i_end), range (j_begin, j_end))); const vector
e2_range (project (e2 (), range (j_begin, j_end))); v_range.plus_assign (prod (e1_range, e2_range)); #endif } #ifndef BOOST_UBLAS_NO_CACHE project (v, range (i_begin, i_end)).assign (v_range); #endif } #if BOOST_UBLAS_TYPE_CHECK BOOST_UBLAS_CHECK (norm_1 (v - cv) <= 2 * std::numeric_limits
::epsilon () * verrorbound, internal_logic ()); #endif return v; } template
BOOST_UBLAS_INLINE V block_prod (const vector_expression
&e1, const matrix_expression
&e2) { typedef V vector_type; typedef const E1 expression1_type; typedef const E2 expression2_type; typedef typename V::size_type size_type; typedef typename V::value_type value_type; const size_type block_size = BS; V v (e2 ().size2 ()); #if BOOST_UBLAS_TYPE_CHECK vector
cv (v.size ()); typedef typename type_traits
::real_type real_type; real_type verrorbound (norm_1 (v) + norm_1 (e1) * norm_1 (e2)); indexing_vector_assign
(cv, prod (e1, e2)); #endif size_type i_size = BOOST_UBLAS_SAME (e1 ().size (), e2 ().size1 ()); size_type j_size = e2 ().size2 (); for (size_type j_begin = 0; j_begin < j_size; j_begin += block_size) { size_type j_end = j_begin + (std::min) (j_size - j_begin, block_size); // FIX: never ignore Martin Weiser's advice ;-( #ifdef BOOST_UBLAS_NO_CACHE vector_range
v_range (v, range (j_begin, j_end)); #else // vector
> v_range (j_end - j_begin); vector
v_range (j_end - j_begin); #endif v_range.assign (zero_vector
(j_end - j_begin)); for (size_type i_begin = 0; i_begin < i_size; i_begin += block_size) { size_type i_end = i_begin + (std::min) (i_size - i_begin, block_size); #ifdef BOOST_UBLAS_NO_CACHE const vector_range
e1_range (e1 (), range (i_begin, i_end)); const matrix_range
e2_range (e2 (), range (i_begin, i_end), range (j_begin, j_end)); #else // const vector
> e1_range (project (e1 (), range (i_begin, i_end))); // const matrix
> e2_range (project (e2 (), range (i_begin, i_end), range (j_begin, j_end))); const vector
e1_range (project (e1 (), range (i_begin, i_end))); const matrix
e2_range (project (e2 (), range (i_begin, i_end), range (j_begin, j_end))); #endif v_range.plus_assign (prod (e1_range, e2_range)); } #ifndef BOOST_UBLAS_NO_CACHE project (v, range (j_begin, j_end)).assign (v_range); #endif } #if BOOST_UBLAS_TYPE_CHECK BOOST_UBLAS_CHECK (norm_1 (v - cv) <= 2 * std::numeric_limits
::epsilon () * verrorbound, internal_logic ()); #endif return v; } template
BOOST_UBLAS_INLINE M block_prod (const matrix_expression
&e1, const matrix_expression
&e2, row_major_tag) { typedef M matrix_type; typedef const E1 expression1_type; typedef const E2 expression2_type; typedef typename M::size_type size_type; typedef typename M::value_type value_type; const size_type block_size = BS; M m (e1 ().size1 (), e2 ().size2 ()); #if BOOST_UBLAS_TYPE_CHECK matrix
cm (m.size1 (), m.size2 ()); typedef typename type_traits
::real_type real_type; real_type merrorbound (norm_1 (m) + norm_1 (e1) * norm_1 (e2)); indexing_matrix_assign
(cm, prod (e1, e2), row_major_tag ()); disable_type_check
::value = true; #endif size_type i_size = e1 ().size1 (); size_type j_size = e2 ().size2 (); size_type k_size = BOOST_UBLAS_SAME (e1 ().size2 (), e2 ().size1 ()); for (size_type i_begin = 0; i_begin < i_size; i_begin += block_size) { size_type i_end = i_begin + (std::min) (i_size - i_begin, block_size); for (size_type j_begin = 0; j_begin < j_size; j_begin += block_size) { size_type j_end = j_begin + (std::min) (j_size - j_begin, block_size); // FIX: never ignore Martin Weiser's advice ;-( #ifdef BOOST_UBLAS_NO_CACHE matrix_range
m_range (m, range (i_begin, i_end), range (j_begin, j_end)); #else // matrix
> m_range (i_end - i_begin, j_end - j_begin); matrix
m_range (i_end - i_begin, j_end - j_begin); #endif m_range.assign (zero_matrix
(i_end - i_begin, j_end - j_begin)); for (size_type k_begin = 0; k_begin < k_size; k_begin += block_size) { size_type k_end = k_begin + (std::min) (k_size - k_begin, block_size); #ifdef BOOST_UBLAS_NO_CACHE const matrix_range
e1_range (e1 (), range (i_begin, i_end), range (k_begin, k_end)); const matrix_range
e2_range (e2 (), range (k_begin, k_end), range (j_begin, j_end)); #else // const matrix
> e1_range (project (e1 (), range (i_begin, i_end), range (k_begin, k_end))); // const matrix
> e2_range (project (e2 (), range (k_begin, k_end), range (j_begin, j_end))); const matrix
e1_range (project (e1 (), range (i_begin, i_end), range (k_begin, k_end))); const matrix
e2_range (project (e2 (), range (k_begin, k_end), range (j_begin, j_end))); #endif m_range.plus_assign (prod (e1_range, e2_range)); } #ifndef BOOST_UBLAS_NO_CACHE project (m, range (i_begin, i_end), range (j_begin, j_end)).assign (m_range); #endif } } #if BOOST_UBLAS_TYPE_CHECK disable_type_check
::value = false; BOOST_UBLAS_CHECK (norm_1 (m - cm) <= 2 * std::numeric_limits
::epsilon () * merrorbound, internal_logic ()); #endif return m; } template
BOOST_UBLAS_INLINE M block_prod (const matrix_expression
&e1, const matrix_expression
&e2, column_major_tag) { typedef M matrix_type; typedef const E1 expression1_type; typedef const E2 expression2_type; typedef typename M::size_type size_type; typedef typename M::value_type value_type; const size_type block_size = BS; M m (e1 ().size1 (), e2 ().size2 ()); #if BOOST_UBLAS_TYPE_CHECK matrix
cm (m.size1 (), m.size2 ()); typedef typename type_traits
::real_type real_type; real_type merrorbound (norm_1 (m) + norm_1 (e1) * norm_1 (e2)); indexing_matrix_assign
(cm, prod (e1, e2), column_major_tag ()); disable_type_check
::value = true; #endif size_type i_size = e1 ().size1 (); size_type j_size = e2 ().size2 (); size_type k_size = BOOST_UBLAS_SAME (e1 ().size2 (), e2 ().size1 ()); for (size_type j_begin = 0; j_begin < j_size; j_begin += block_size) { size_type j_end = j_begin + (std::min) (j_size - j_begin, block_size); for (size_type i_begin = 0; i_begin < i_size; i_begin += block_size) { size_type i_end = i_begin + (std::min) (i_size - i_begin, block_size); // FIX: never ignore Martin Weiser's advice ;-( #ifdef BOOST_UBLAS_NO_CACHE matrix_range
m_range (m, range (i_begin, i_end), range (j_begin, j_end)); #else // matrix
> m_range (i_end - i_begin, j_end - j_begin); matrix
m_range (i_end - i_begin, j_end - j_begin); #endif m_range.assign (zero_matrix
(i_end - i_begin, j_end - j_begin)); for (size_type k_begin = 0; k_begin < k_size; k_begin += block_size) { size_type k_end = k_begin + (std::min) (k_size - k_begin, block_size); #ifdef BOOST_UBLAS_NO_CACHE const matrix_range
e1_range (e1 (), range (i_begin, i_end), range (k_begin, k_end)); const matrix_range
e2_range (e2 (), range (k_begin, k_end), range (j_begin, j_end)); #else // const matrix
> e1_range (project (e1 (), range (i_begin, i_end), range (k_begin, k_end))); // const matrix
> e2_range (project (e2 (), range (k_begin, k_end), range (j_begin, j_end))); const matrix
e1_range (project (e1 (), range (i_begin, i_end), range (k_begin, k_end))); const matrix
e2_range (project (e2 (), range (k_begin, k_end), range (j_begin, j_end))); #endif m_range.plus_assign (prod (e1_range, e2_range)); } #ifndef BOOST_UBLAS_NO_CACHE project (m, range (i_begin, i_end), range (j_begin, j_end)).assign (m_range); #endif } } #if BOOST_UBLAS_TYPE_CHECK disable_type_check
::value = false; BOOST_UBLAS_CHECK (norm_1 (m - cm) <= 2 * std::numeric_limits
::epsilon () * merrorbound, internal_logic ()); #endif return m; } // Dispatcher template
BOOST_UBLAS_INLINE M block_prod (const matrix_expression
&e1, const matrix_expression
&e2) { typedef typename M::orientation_category orientation_category; return block_prod
(e1, e2, orientation_category ()); } }}} #endif
operation_blocked.hpp
Page URL
File URL
Prev
15/26
Next
Download
( 13 KB )
Note: The DriveHQ service banners will NOT be displayed if the file owner is a paid member.
Comments
Total ratings:
0
Average rating:
Not Rated
Would you like to comment?
Join DriveHQ
for a free account, or
Logon
if you are already a member.