Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8544239
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 11, 20262026-06-11T12:30:31+00:00 2026-06-11T12:30:31+00:00

Starting the the error, which is showed by building the following code: Testfile.cpp:27:41: error:

  • 0

Starting the the error, which is showed by building the following code:

Testfile.cpp:27:41: error: variable ‘boost::numeric::ublas::matrix_column<boost::numeric::ublas::bounded_matrix<double, 2u, 2u> > op1’ has initialiser but incomplete type.

Please condider the following code:

//! System includes
#include <iostream>
#include <fstream>
//! Boost includes
#include <boost/lexical_cast.hpp>
#include <boost/integer/static_min_max.hpp>

#include <boost/numeric/ublas/vector.hpp>
#include <boost/numeric/ublas/matrix.hpp>
#include <boost/array.hpp>

int main( )
{
    namespace ublas = boost::numeric::ublas;

    typedef ublas::bounded_matrix<double,2,2>       MatDofDdim;
    typedef ublas::bounded_vector<double,2>             VecDof;

    MatDofDdim op;
    for(int i=0;i<2;i++){
        for(int j=0;j<2;j++){
            op(i,j)=i+j;
        }
    }

    //VecDof op1;
    ublas::matrix_column<MatDofDdim> op1 ( op, 1 ) ;

    //VecDof op1( ublas::matrix_column<MatDofDdim>( op, 1 ));
    return 0;
}

I also tried an different approach with comment the line "ublas::matrix_column<MatDofDdim> op1 ( op, 1 ) ;" and with uncomment the preceeding and following line.

Then it says:
Testfile.cpp:29:48: error: redeclaration of ‘VecDof op1’
Testfile.cpp:26:9: error: ‘VecDof op1’ previously declared here
Testfile.cpp:29:54: error: invalid use of incomplete type ‘struct boost::numeric::ublas::matrix_column<boost::numeric::ublas::bounded_matrix<double, 2u, 2u> >’
/usr/include/boost/numeric/ublas/fwd.hpp:75:11: error: declaration of ‘struct boost::numeric::ublas::matrix_column<boost::numeric::ublas::bounded_matrix<double, 2u, 2u> >’

I use eclipse in ubuntu with g++.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-11T12:30:33+00:00Added an answer on June 11, 2026 at 12:30 pm

    matrix_column is declared in <boost/numeric/ublas/matrix_proxy.hpp>
    http://www.boost.org/doc/libs/1_51_0/libs/numeric/ublas/doc/matrix_proxy.htm#matrix_column

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have odd problem: After starting server I got this error: undefined local variable
I am encountering the following error in my app. upon starting it: [3/26/12 13:05:26:109
I have some pretty simple Java code in which I'm starting another process and
Starting with a .csproj which defines various xml Content files. Have code generation Target
I am getting a timeout error while starting my Windows service. I am tring
I'm starting a process and redirecting the error stream to be able to parse
I have two functions, one which produces messages like Starting initialization... and another which
This error occurs when I was trying to connect to SQL Server 2005 which
I'm starting to look into Google's Picasa API for photo data, which provides you
I have a problem with deserializing in C#/ASP.NET, which gives the exact error: The

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.