problem about study TAUCS (a new learner)

105 views
Skip to first unread message

chin...@gmail.com

unread,
Dec 23, 2008, 9:18:15 AM12/23/08
to matrixprogramming
Hello ,my name is chen cheng a student in china .

I start to learn TAUCS about one week ago,but still have no idea of
how to
use it in VC6.0
I use your program which solves Ax=b but without success as in the
discussion
"http://groups.google.com/group/matrixprogramming/browse_thread/thread/
7f370c733be7e385/1fb95635797edacc"

As a new learner i still don't know how to use the taucs_full down
from website as Evgenii said
1) unzip taucs_full.zip
2) configure (why do this ? for get something?)
3) nmake

when i go with (2)and (3) problem comes ,which is shown as follow

I unzip taucs_full.zip to D:

*(C) 1985-2001 Microsoft Corp.*
> *C:\Documents and Settings\SL>d;
> *
> *C:\Documents and Settings\SL>d:*
> *D:\>cd taucs_full*
> *D:\taucs_full>configure.bat
> 'nmake' is not recognized as an internal or
> external command
> 'configurator\configurator' is not recognized as an internal or
> external command
> 。
> can find D:\taucs_full\.lastconf*


could some sent me a example program you have sucessfull to TAUCS run
in VC6.0 . or tell me in detail how to use it (i have read the D:
\taucs_full\.doc\taucs.pdf for one week still have no idea)

> This is what i did
>
> First insert D:/taucs_full to VC6.0 Tools->option->directories
> Second Project ->setting ->Link-las_win32.lib
> lapack_win32.lib
> libatlas.lib
> libcblas.lib lib
> f77blas.lib
> liblapack.lib
> libmetis.lib
> vcf2c.lib
> these 8 lib files from taucs_full\external\lib\win32
(is 8 files enough ?i saw someone said it need 9 files)

Evgenii Rudnyi

unread,
Dec 23, 2008, 4:12:26 PM12/23/08
to matrixpr...@googlegroups.com
Hi Chen,

Let us do step by step. First you have libraries on which TAUCS depends
but the TAUCS library is not yet there. It is necessary to compile it first.


> 1) unzip taucs_full.zip
> 2) configure (why do this ? for get something?)

configure is a small program that will write makefiles for nmake. One
can influence it on what should be in the TAUCS library. configure as
such requires that nmake and cl should be on the system path.

>> *D:\taucs_full>configure.bat
>> 'nmake' is not recognized as an internal or
>> external command

This says that the OS cannot find nmake. It is necessary to have it on
the path. To reach this, you should run not cmd but to find in VC Visual
Studio command prompt. It will set up the path as well as other system
variables for you. You should check that this was successful by typing
nmake and cl. In both cases there should be output saying the current
version of these tools.

When it is done, you can go further with configure.cmd. Open it in some
editor but not in Notepad. There everything will be on one line.

configure.cmd is a simple script. First it runs nmake to compile
configurator.exe and then runs it. configurator.exe makes makefiles for
nmake to compile TAUCS.

So first steps.

1) Find Visual Studio command prompt and make sure that nmake and cl are
on the path.

2) Run configure.bat and check that configurator\configurator.exe in the
TAUCS directory was made.

When it is done please let me know and we will continue. If you have
problems/questions along this way, just please ask.

It is also possible to compile configurator.exe with GUI, but I should
say that I do not use GUI so unfortunately I cannot help you with this.

Evgenii

P.S. It could be useful to open and inspect configurator\makefile.win32.
This is a make file to compile configurator\configurator.exe. Its
content may look puzzling at the first glance but actually it is pretty
simple. See for example introduction to make at

http://www.eng.hawaii.edu/Tutor/Make/

You can find much more by Googling make tutorial

alejandro a. ortiz bernardin

unread,
Dec 23, 2008, 5:33:38 PM12/23/08
to matrixpr...@googlegroups.com
In addition to what Egvenii said, that are my answers and I give you
more details to compile the files in the user interfase of MVS 6.0 or
2005:

"*(C) 1985-2001 Microsoft Corp.*
> *C:\Documents and Settings\SL>d;
> *
> *C:\Documents and Settings\SL>d:*
> *D:\>cd taucs_full*

> *D:\taucs_full>configure.bat
> 'nmake' is not recognized as an internal or
> external command

> 'configurator\configurator' is not recognized as an internal or
> external command
> 。


> can find D:\taucs_full\.lastconf*"

It seems that you don't have the path to nmake in your system. If you
are using Win XP You can register the path in System --> System
properties -->Advanced --> Environment variables.

"could some sent me a example program you have sucessfull to TAUCS run
in VC6.0 . or tell me in detail how to use it (i have read the D:
\taucs_full\.doc\taucs.pdf for one week still have no idea)"

You can compile the TAUCS libraries in Win32 using the files provided
by the TAUCS's author in his website doing the following either in
Microsoft Visual Studio 6.0 or 2005 (If you read the related post in
this forum there is a problem with MVS 2008, so first verify that you
are using MVS 6.0 or 2005):

INSTALLING TAUCS ON Win32
=========================

1) TAUCS thinks that you have the Microsoft C++ compiler already
installed in your machine,
so make sure that you have installed Microsoft C++. I have tried using the C++
compiler included in Microsoft Visual Studio 6.0 and Microsoft Visual Studio
2008. It seems that TAUCS compilation will work only in Microsoft
Visual Studio 6.0 (Visual C++ 6.0 and also in 2005). The newer
compiler (2008) will not work (see the other posts regarding this).

2) Once, you have done the described above, in a windows command prompt
go to the taucs_full directory and type:

configure

This will create a makefile ready to use for your machine.

3) Now type:

nmake

Note: nmake is the equivalent to make command in Unix/Linux and it is provided
by Microsoft C++.

A bunch of numbers, commands, etc will appear on your screen. The result of
that will be a file called libtaucs.lib which is the TAUCS library for your
machine.

4) In order to use TAUCS in your codes, you need to use the TAUCS library and
other external libraries such as blas, metis, etc. and some TAUCS headers.
So, go to:

\taucs_full\external\lib\win32 where the external libraries are available

\taucs_full\lib\win32 where the TAUCS library is available

\taucs_full\src where two TAUCS headers are located.
You must use: taucs.h and taucs_private.h.

Note:
Whenever you refer to taucs.h do the following:
extern "C" {
#include <taucs.h>
}

Or

extern "C" {
#include "taucs.h"
}
and provide the path to "taucs.h" in ADDITIONAL INCLUDE DIRECTORIES IN MVS 6.0


\taucs_full\build\win32 where two more TAUCS headers are
located. You need both: taucs_config_build.h and taucs_config_test.h


5) In your code you must make reference to all the libraries and the
headers described above, so copy them in a directory so you know
where they are. You can use them in the same taucs_full folder if you want.

This is a list of the complete set of libraries that were created when
compiling TAUCS and described in 4):

blas_win32.lib
lapack_win32.lib
libatlas.lib
libcblas.lib
libf77blas.lib
liblapack.lib
libmetis.lib
libtaucs.lib
vcf2c.lib


HOW TO COMPILE AND BUILT YOUR APPLICATIONS USING TAUCS LIBRARY
==============================================================

When compiling your codes that make reference to the above libraries
make sure that you do the following (in MV C++):

1) C++ --> Code generation --> Use run-time library: Debug
Single-Threaded (/MLd)

2) Link --> Input: Object/library modules: add TAUCS libraries and
external libraries (blas, atlas, metis, etc)

3) If the libraries are not in the same place where you have your cpp
files, then make sure that you indicate the
folder in which they are in ADDITIONAL PATH LIBRARY.

4) Make sure that you ignore LIBCMT.LIB in IGNORE LIBRARIES blank.

5) Now you can compile and build your application using TAUCS.


Good luck!

Alejandro.

chinacsl

unread,
Dec 23, 2008, 8:31:28 PM12/23/08
to matrixprogramming
2008 12 24 9.21am
Thank Evgenii and Alejandro very I read your replay carefully and i
will have a try according what you have said and let you know the
result.When i check my question above I found many spelling and
grammar errors though it is not important to my question , i correct
it as follow [ :-) sorry for my poor english and thank you again]
Corrected:

I start to learn TAUCS about one week ago,but still have no idea of
how to use it in VC6.0
I use the program which solves Ax=b but without success as in the
discussion "http://groups.google.com/group/matrixprogramming/
browse_thread/thread/
7f370c733be7e385/1fb95635797edacc"


As a new learner i still don't know how to use the taucs_full download
from website
as Evgenii said
1) unzip taucs_full.zip
2) configure (why do this ? for get something?)
3) nmake


when i go with (2)and (3) problem comes ,which is shown as follow


I unzip taucs_full.zip to D:


*(C) 1985-2001 Microsoft Corp.*


C:\Documents and Settings\SL>d:*
D:\>cd taucs_full*
D:\taucs_full>configure.bat
'nmake' is not recognized as an internal or
external command
'configurator\configurator' is not recognized as an internal or
external command

can't find D:\taucs_full\.lastconf*


could someone sent me an example program you have sucessfully run
TAUCS
in VC6.0 . or tell me in detail how to use it (i have read the D:
\taucs_full\.doc\taucs.pdf for one week still have no idea)


alejandro a. ortiz bernardin

unread,
Dec 23, 2008, 9:23:32 PM12/23/08
to matrixpr...@googlegroups.com
Yes, they are 9 libraries. In your list there is one library missed
... the TAUCS library. See my previous reply in number 4). You can
find the missed library there.

Alejandro.

chinacsl

unread,
Dec 24, 2008, 1:46:14 AM12/24/08
to matrixprogramming
To Alejandro:
I use VC6.0 in xp sp2 and I put taucs_full folder in D: the
direction is D:/taucs_full
according to what you said
"It seems that you don't have the path to nmake in your system. If
you
are using Win XP You can register the path in System --> System
properties -->Advanced --> Environment variables. "

I did as follow:
System --> System properties -->Advanced --> Environment variables ->i
new a user variable as "variable name:taucs ;variable value:D:
\taucs_full" Am i right? (i also new a system variable as the same)
then run -> cmd -> the problem still as before
C:\Documents and Settings\SL>d:
D:\>cd taucs_full

chinacsl

unread,
Dec 24, 2008, 2:31:30 AM12/24/08
to matrixprogramming
To Evgenii:
according what you said "1) Find Visual Studio command prompt and make
sure that nmake and cl are on the path. "
I can't find where Visual Studio command prompt is,and i search
"Visual Studio command prompt "in google,get the information that
Tools->Visual Studio 2008 command prompt ,but I can't find the menu in
VC6.0 at all

thank for your replay
Merry chiristmas!
chen 12-24 15.30pm

Evgenii Rudnyi

unread,
Dec 24, 2008, 3:08:14 AM12/24/08
to matrixpr...@googlegroups.com

> To Evgenii:
> according what you said "1) Find Visual Studio command prompt and make
> sure that nmake and cl are on the path. "
> I can't find where Visual Studio command prompt is,and i search
> "Visual Studio command prompt "in google,get the information that
> Tools->Visual Studio 2008 command prompt ,but I can't find the menu in
> VC6.0 at all

Dear Chen,

First please look at environmental variables. A good paper in this
respect is

http://en.wikipedia.org/wiki/Environment_variable

and there are some more links at the bottom. I understand that you would
like to compile TAUCS as soon as possible but it seems that first you
have to learn some things about working from command line. If you are
going to work in programming seriously, you actually must do it.

Please read the text and think it over. If you do not understand the
concept of environmental variables, please ask questions.

So, to work with Visual Studio, several environment variables should be
set correctly. This concerns actually not only PATH but also LIB,
INCLUDE, and some others.

These variables are defined in vsvars32.bat. Search it on your hard
drive in the VS installation. I have it in

C:\Programme\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat

It could be that it is named as vsvars32.txt. Then you should check that
its content correct and to rename it. I have a shortcut that runs this
batch file

Programs | Visual C++ 2005 Express Edition | Visual Studio Tools

If this is not available in your installation, please just run from the
command line

"C:\Programme\Microsoft Visual Studio 8\Common7\Tools\vsvars32.bat"

Well, this should correspond to the correct path at your computer.
Probably you should have Program Files and not Programme. Quotes are
necessary if there are spaces in the name.

If everything is successful, the commands cl and nmake from the command
line after executing vsvars32.bat should work.

Please report about the progress.

Best wishes,

Evgenii

chinacsl

unread,
Dec 24, 2008, 5:10:20 AM12/24/08
to matrixprogramming
Hello everybody ,first i want thank Evgenii and Alejandro
I have successfully run a simple program(copy from
http://groups.google.com/group/matrixprogramming/
browse_thread/thread/ ) in VC6.0 to solve Ax=b by newing a VC6.0
win32 Console application and get the answer
X=[0 2 0 4].but not successful when using the same program in MFC(exe)
Single document. Now i am debug it
After i successfully use TAUCS in MFC(exe) Single document,I will give
a brief sum up to the new learner like me :-)

Have a good day!
Chen Cheng
08-12-24 18:09pm

chinacsl

unread,
Dec 24, 2008, 6:21:51 AM12/24/08
to matrixprogramming
To new user of TAUCS (based on VC6.0)
down TAUCS from websit and
1) unzip taucs_full.zip (you can see 8 lib files in \taucs_full
\external\lib)
2) configure
3) nmake
2) and 3) find help from what Evgenii and Alejandro have said above
then you will get ninth lib file in taucs_full\lib\win32
In VC 6.0 new a project
Project ->setting ->Link-las_win32.lib
lapack_win32.lib
libatlas.lib
libcblas.lib lib
f77blas.lib
liblapack.lib
libmetis.lib
vcf2c.lib
libtaucs.lib
in your .cpp files add this
extern "C"
{
#include "src\taucs.h"
#include "src\taucs_private.h"
}

#include <vector>
....your own program


Good Luck wish be helpful to you! I


Evgenii Rudnyi

unread,
Dec 24, 2008, 10:38:11 AM12/24/08
to matrixpr...@googlegroups.com

I am glad to hear that you have successfully compiled TAUCS. Do you mean
by MFC Microsoft Foundation Classes? Or something else? Please report
about your problems.

Evgenii

chinacsl

unread,
Dec 24, 2008, 10:07:35 PM12/24/08
to matrixprogramming



> I am glad to hear that you have successfully compiled TAUCS. Do you mean
>   by MFC Microsoft Foundation Classes? Or something else? Please report
> about your problems.
>
> Evgenii
The problem has been solved last night(just a #include error), Happy
to know you and Alejandro !

chen cheng
2008 12 25 11:07am
Reply all
Reply to author
Forward
0 new messages