Use cpplapack on ubuntu

For my memorandum

About CPPLA PACK

http://cpplapack.sourceforge.net/doc/main_page/Japanese.html BLAS, LAPACK, and PARDISO C ++ class wrappers. Matrix, vector calculation, singular value decomposition, solution of simultaneous equations, etc. can be described very simply.

Introduction

Basically http://cpplapack.sourceforge.net/tutorial/japanese/index.html It can be introduced if you proceed according to.

Install lapack and gfortran.

sudo apt install libatlas3-base libatlas-base-dev
sudo apt install gfortran

In cpplapack, make and makedepend are used to build the code, so install the following as well.

sudo apt install build-essential xutils-dev

For the main body of cpplapack, check out to ~ / local / using Subversion.

cd ~
mkdir local
cd local
svn checkout https://svn.code.sf.net/p/cpplapack/code/trunk cpplapack

The preparation is now complete.

Operation check

Check the operation of cpplapack. Create the following code.

#include "cpplapack.h"

int main(){
  CPPL::dgematrix A(2, 3);
  A(0, 0) = 1; A(0, 1) = 2; A(0, 2) = 3;
  A(1, 0) = 4; A(1, 1) = 5; A(1, 2) = 6;
  std::cout << A;
  return 0;
}

It can be easily built by using the Makefile included in the cpplapack itself.

cp ~/local/cpplapack/makefiles/Makefile ./
make
./A.OUT

If it is displayed as below, it is OK.

 1 2 3
 4 5 6

Recommended Posts

Use cpplapack on ubuntu
Use Flutter on Ubuntu
Use mkdir on ubuntu
How to use Bio-Formats on Ubuntu 20.04
Preparing to use electron-react-boilerplate on Ubuntu 20.4
tmux on Ubuntu
Use cljstyle with Spacemacs on Ubuntu on WSL2
Screen recording on Ubuntu 20.04
Web Bluetooth on Ubuntu20.04
Try DisplayLink on Ubuntu 20.04
Reinstall Kubernetes on Ubuntu 19.10
Use perltidy on CentOS 8
Install pyqt5 on ubuntu
Install Ruby on Ubuntu 20.04
Use mod_auth_cas on CentOS 8
Setting JAVA_HOME on Ubuntu
Install Autoware on Ubuntu 18.04.5
Put JetBrains on Ubuntu
Apache2 on Ubuntu20.04 LTS
Use Corretto 11 on Heroku
ubuntu on wsl part 10
Install Homebrew on Ubuntu 20.04
Run tiscamera on Ubuntu 18.04
Build Zabbix on Ubuntu 20.04
Using Flutter on Ubuntu (Part 2)
Create SSL certificate on Ubuntu 18.04
Building WebGIS on Ubuntu20.04 LTS
Install OpenJDK7 (JAVA) on ubuntu 14.04
Build VNC Server on Ubuntu 20.04
Install Cybozu Office 10 on Ubuntu 20.4
Extend swap area on Ubuntu 18.04
Install Docker on Ubuntu Server 20.04
Ubuntu on Windows Community Preview
Japanese input on Ubuntu20.04 Desktop
Use serial communication on Android
Oracle Java 8 on Docker Ubuntu
Install MAV Proxy on Ubuntu 18.04
Install Arudino IDE on Ubuntu 20
Record video on ubuntu18.04 LTS
Introduced knowledge (wiki) on Ubuntu
Installing OpenMX on Ubuntu 18.04.5 LTS
Install Java on WSL Ubuntu 18.04
Ruby installation on WSL2 + Ubuntu 20.04
Install Ubuntu Desktop 20.10 on RaspberryPi4
Install Arduino IDE on Ubuntu 20.04
Ubuntu on Windows build speed
Use devise on multiple models
Run java applet on ubuntu
Install raspi-config on Ubuntu 20.04 (LTS)
Use native code on Android
Install WordPress 5.5 on Ubuntu 20.04 LTS
Run Eclipse CDT on Ubuntu
Set up ansible-playbook on Ubuntu 20.04
Install PlantUML on Intellij on Ubuntu
Install Ubuntu Server 20.04 on Btrfs
Note: Install PostgreSQL 9.5 on Ubuntu 18.04
Use PG Backups on Heroku
I want to use screen sharing on the login screen on Ubuntu 18
Use virtual AP on Ubuntu 18.04 LTS to sub-monitor old iPad
Results of trying to use NVENC (CUDA) with Ubuntu 18.04 on WSL2
How to install and use Composer on an ECS instance on Ubuntu 16.04