tensor4(2rheolef) rheolef-6.1 tensor4(2rheolef)NAME
tensor4 - a fouth order tensor
SYNOPSYS
The tensor4 class defines a fourth tensor where indices varie from zero to 2 (aka 3D physical space).
IMPLEMENTATION
template<class T>
class tensor4_basic {
public:
typedef size_t size_type;
typedef T element_type;
// allocators:
tensor4_basic (const T& init_val = 0);
tensor4_basic (const tensor4_basic<T>& a);
// affectation:
tensor4_basic<T>& operator= (const tensor4_basic<T>& a);
tensor4_basic<T>& operator= (const T& val);
// accessors:
T& operator()(size_type i, size_type j, size_type k, size_type l);
const T& operator()(size_type i, size_type j, size_type k, size_type l) const;
// data:
protected:
T _x [3][3][3][3];
};
typedef tensor4_basic<Float> tensor4;
rheolef-6.1 rheolef-6.1 tensor4(2rheolef)
Check Out this Related Man Page
distributor(2rheolef) rheolef-6.1 distributor(2rheolef)NAME
distributor - data distribution table (rheolef-6.1)
SYNOPSYS
Used by "array"(1), "asr"(1) and "csr"(1). and such classes that distribute data as chunk.
IMPLEMENTATION
class distributor : public Vector<std::allocator<int>::size_type> {
public:
// typedefs:
typedef std::allocator<int>::size_type size_type;
typedef Vector<size_type> _base;
typedef _base::iterator iterator;
typedef _base::const_iterator const_iterator;
typedef int tag_type;
typedef communicator communicator_type;
// constants:
static const size_type decide = size_type(-1);
// allocators/deallocators:
distributor(
size_type dis_size = 0,
const communicator_type& c = communicator_type(),
size_type loc_size = decide);
distributor(const distributor&);
~distributor();
void resize(
size_type dis_size = 0,
const communicator_type& c = communicator_type(),
size_type loc_size = decide);
// accessors:
const communicator_type& comm() const;
/// global and local sizes
size_type dis_size () const;
/// current process id
size_type process () const;
/// number of processes
size_type n_process () const;
/// find iproc associated to a global index dis_i: CPU=log(nproc)
size_type find_owner (size_type dis_i) const;
/// global index range and local size owned by ip-th process
size_type first_index (size_type ip) const;
size_type last_index (size_type ip) const;
size_type size (size_type ip) const;
/// global index range and local size owned by current process
size_type first_index () const;
size_type last_index () const;
size_type size () const;
/// true when dis_i in [first_index(ip):last_index(ip)[
bool is_owned (size_type dis_i, size_type ip) const;
// the same with ip=current process
bool is_owned (size_type dis_i) const;
/// returns a new tag
static tag_type get_new_tag();
// comparators:
bool operator== (const distributor&) const;
bool operator!= (const distributor&) const;
// data:
protected:
communicator_type _comm;
};
rheolef-6.1 rheolef-6.1 distributor(2rheolef)
I have a huge matrix file containing some 1.5 million rows and 6000 columns. The matrix looks something like this:
1 2 3
4 5 6
7 8 9
3 4 5
I want to add all the numbers in the columns of this matrix and display the result to my stdout. This means that the numbers in the first column are:
... (2 Replies)
Hi,
Just trying to get to grips with sed and awk for some reporting for work and I need some assistance:
I have a file that lists policy names on the first line and then on the second line whether the policy is active or not.
Policy Name: Policy1
Active: yes
Policy... (8 Replies)
version info :
vi availabe with RHEL 5.4
I have a text file with 10,000 lines. I want to copy lines from 5000th line to 7000th and redirect to a file. Any idea how I can do this?
Note:
The above scenario is just an example. In my actual requirement, the file has 14 million lines and I want... (9 Replies)
Hi everyone,
I know the following questions are noobish questions but I am asking them because I am confused about the basics of history behind UNIX and LINUX.
Ok onto business, my questions are-:
Was/Is UNIX ever an open source operating system ?
If UNIX was... (21 Replies)
Hello,
I couldn't find an actual introduction thread, so I decided to just put this here.
I go by d0wngrade online. I have been programming in multiple languages for about 15+ years. I started with standard web design languages like HTML and CSS, but I then advanced from design to development... (2 Replies)
Hi guys...
The first active code line in AudioScope.sh is set -u .
This causes a complete exit if a variable is used/found but has not been allocated at the start of the program.
However, apart from writing code to do the task, is there a switch to to check which variables have been... (17 Replies)
Hi.
In thread https://www.unix.com/shell-programming-and-scripting/267833-grouping-counting.html rovf and I had a mini-discussion on grep and awk.
Here is a demo script that compares the awk and grep approaches for this single problem:
#!/usr/bin/env bash
# @(#) s2 Demonstrate group... (1 Reply)
Hello,
I have to fish out some specific columns from a file based on the header value. I have the list of columns I need in a different file. I thought I could read in the list of headers I need,
# file with header names of required columns in required order
headers_file=$2
# read contents... (11 Replies)
For those interested in installing dash shell on OSX Lion to help test POSIX compliancy of shell scripts, it is quite easy. I did it like this:
If you don't have gcc on your system:
0. Download and install the Command Line Tools for Xcode package from Sign In - Apple *
1. Download the dash... (2 Replies)
Hello and thanks in advance for any help anyone can offer me
I'm trying to learn the find command and thought I was understanding it... Apparently I was wrong. I was doing compound searches and I started getting weird results with the -size test. I was trying to do a search on a 1G file owned by... (14 Replies)
I have data of an excel files as given below,
file1
org1_1 1 1 2.5 100
org1_2 1 2 5.5 98
org1_3 1 3 7.2 88
file2
org2_1 1 1 2.5 100
org2_2 1 2 5.5 56
org2_3 1 3 7.2 70
I have multiple excel files as above shown.
I have to copy column 1, column 4 and paste into a new excel file as... (26 Replies)
Dear All,
Taking a break from Vue.js coding for the site, SEO and YT videos; and hopefully addressing some well deserved criticism from some here that I have been too focused on the visual aspects of the forums versus the substance and the community....
While the "current generation... (9 Replies)
Hi all...
Well guys and gals, I jumped in at the deep end and found things that PERL cannot do by default.
Many tricky terminal escape codes are not catered for so I had to create workarounds.
One thing I searched for was this:
Passing perl variable to shell command
AND, @Neo this was... (15 Replies)