07-30-2009
Thank you folks for your help.
vidyadhar85 - Your solution worked perfectly. I went ahead with your solution.
summer_cherry - Thank you for your help too. Somehow the file would not print the first match in test I ran (it would print other matches).
Thanks
10 More Discussions You Might Find Interesting
1. Shell Programming and Scripting
My Friends,
Need your help to find the difference between few columns from two comma delimited files. For example, File1 and File2 has 22 columns, and I want to find the difference in first 12 columns.
I have list of file names in MyListOfFiles2Compare.txt. Data is separated with commas.... (5 Replies)
Discussion started by: manish44
5 Replies
2. Shell Programming and Scripting
Hiiiii friends
I have 2 files which contains huge data & few lines of it are as shown below
File1: b.dat(which has 21 columns)
SSR 1976 8 12 13 10 44.00 39.0700 70.7800 7.0 0 0.00 0 2.78 0.00 0.00 0 0.00 2.78 0 NULL
ISC 1976 8 12 22 32 37.39 36.2942 70.7338... (6 Replies)
Discussion started by: reva
6 Replies
3. UNIX for Dummies Questions & Answers
Hi all,
I would like to compare a column in one file to a column in another file and when there is a match it prints the first column and the corresponding second column. Example
File1
ABA
ABC
ABE
ABF
File 2
ABA 123
ABB 124
ABD 125
ABC 126
So what I would like printed to a file... (0 Replies)
Discussion started by: pcg
0 Replies
4. Shell Programming and Scripting
Hi
I have file 1 like this
and file 2 like this
I need to compare column 3 of both files and delete lines in file1 with same column 3 values in two files. So the output is
I tried with perl but didnt work. A perl code will be good as I am learning the language, but any other code would... (1 Reply)
Discussion started by: polsum
1 Replies
5. Shell Programming and Scripting
Hi,
I want to compare the columns of two files excluding column 2 from both the files. I tried this awk command.
awk -F":" 'NR==FNR{++a;next} !(a)' file1.txt file2.txt
.
Example: File1.txt
123:09-15-2011:abc:123456
123:09-15-2011:abc:234567
123:09-15-2011:abc:345678
... (5 Replies)
Discussion started by: shell_newbie
5 Replies
6. Shell Programming and Scripting
Hi,
I need to compare multiple columns from 2 files.
I can, for example, have these 2 files:
file1:
col1, col2, col3,col4
a,1,4,7
b,2,5,8
c,3,6,9file2:
col1, col2, col3,col4
a,2,3,2
b,5,7,5
c,1,9,8As a result, I need for example the difference between the columns 2 and 4:
col2,... (3 Replies)
Discussion started by: Subbeh
3 Replies
7. Shell Programming and Scripting
Hi,
I have two files like this:
8 1.3
10 1.3
12 1.3
15 1.3
21 1.3
and
1
2
3
4
10
11
15
16
21
22 (3 Replies)
Discussion started by: jamie_123
3 Replies
8. Shell Programming and Scripting
Hi all, I'm pretty much a newbie to UNIX. I would appreciate any help with UNIX coding on comparing two large csv files (greater than 10 GB in size), and output a file with matching columns.
I want to compare file1 and file2 by 'id' and 'chain' columns, then extract exact matching rows'... (5 Replies)
Discussion started by: bkane3
5 Replies
9. UNIX for Dummies Questions & Answers
Hi,
Below is my requirement
file1
id|cnt
1|1
2|2
3|3
file2
id_1|cnt_1
1|1
2|1
3|1
I want to compare cnt and cnt_1 columns, if they are differ then give the details
Am using below awk command, but the output is not as expected. (2 Replies)
Discussion started by: grandhirahuletl
2 Replies
10. UNIX for Dummies Questions & Answers
Hi All,
I have a.dat file with content
1,338,30253395122015103,2015103,UB0085000,STMT151117055527002,,,
1,338,30253395122015103,2015103,UB0085000,STMT151117055527001,,,
and b.dat having content
1,STMT151117055527001,a1.txt,b1.txt,c1.txt
1,STMT151117055527002,a2.txt,b2.txt,c2.txt
... (13 Replies)
Discussion started by: PRAMOD 96
13 Replies
LEARN ABOUT REDHAT
dptrfs
DPTRFS(l) ) DPTRFS(l)
NAME
DPTRFS - improve the computed solution to a system of linear equations when the coefficient matrix is symmetric positive definite and
tridiagonal, and provides error bounds and backward error estimates for the solution
SYNOPSIS
SUBROUTINE DPTRFS( N, NRHS, D, E, DF, EF, B, LDB, X, LDX, FERR, BERR, WORK, INFO )
INTEGER INFO, LDB, LDX, N, NRHS
DOUBLE PRECISION B( LDB, * ), BERR( * ), D( * ), DF( * ), E( * ), EF( * ), FERR( * ), WORK( * ), X( LDX, * )
PURPOSE
DPTRFS improves the computed solution to a system of linear equations when the coefficient matrix is symmetric positive definite and tridi-
agonal, and provides error bounds and backward error estimates for the solution.
ARGUMENTS
N (input) INTEGER
The order of the matrix A. N >= 0.
NRHS (input) INTEGER
The number of right hand sides, i.e., the number of columns of the matrix B. NRHS >= 0.
D (input) DOUBLE PRECISION array, dimension (N)
The n diagonal elements of the tridiagonal matrix A.
E (input) DOUBLE PRECISION array, dimension (N-1)
The (n-1) subdiagonal elements of the tridiagonal matrix A.
DF (input) DOUBLE PRECISION array, dimension (N)
The n diagonal elements of the diagonal matrix D from the factorization computed by DPTTRF.
EF (input) DOUBLE PRECISION array, dimension (N-1)
The (n-1) subdiagonal elements of the unit bidiagonal factor L from the factorization computed by DPTTRF.
B (input) DOUBLE PRECISION array, dimension (LDB,NRHS)
The right hand side matrix B.
LDB (input) INTEGER
The leading dimension of the array B. LDB >= max(1,N).
X (input/output) DOUBLE PRECISION array, dimension (LDX,NRHS)
On entry, the solution matrix X, as computed by DPTTRS. On exit, the improved solution matrix X.
LDX (input) INTEGER
The leading dimension of the array X. LDX >= max(1,N).
FERR (output) DOUBLE PRECISION array, dimension (NRHS)
The forward error bound for each solution vector X(j) (the j-th column of the solution matrix X). If XTRUE is the true solution
corresponding to X(j), FERR(j) is an estimated upper bound for the magnitude of the largest element in (X(j) - XTRUE) divided by
the magnitude of the largest element in X(j).
BERR (output) DOUBLE PRECISION array, dimension (NRHS)
The componentwise relative backward error of each solution vector X(j) (i.e., the smallest relative change in any element of A or B
that makes X(j) an exact solution).
WORK (workspace) DOUBLE PRECISION array, dimension (2*N)
INFO (output) INTEGER
= 0: successful exit
< 0: if INFO = -i, the i-th argument had an illegal value
PARAMETERS
ITMAX is the maximum number of steps of iterative refinement.
LAPACK version 3.0 15 June 2000 DPTRFS(l)