Sponsored Content
Top Forums UNIX for Dummies Questions & Answers a dummy question on data processing Post 302344834 by kaixinsjtu on Monday 17th of August 2009 06:42:50 PM
Old 08-17-2009
CPU & Memory a dummy question on data processing

Hi, everyone,
I have a matrix, let's say:

1 2 3 4 5 6 ...
4 5 6 7 8 9 ...
7 8 9 1 2 3 ...
3 4 5 6 7 8 ...
.........
(nxm matrix)

Is there a simple command that can take certain specific rows out of the matrix?
e.g., I want to take row 2 (4 5 6 7 8 9 ...) and row 4 (3 4 5 6 7 8 ...) out and put them into another file. I failed to do that with "grep". Do y'all have any idea ? Thanks.
Also, how to remove certain specific rows from the original file? (I know cut works if I want to remove columns, but how about rows??) Thanks a lot. Smilie
 

10 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Unix dummy's question

:confused: Hi, 2 questions to get some insight. Thanks (1) I would like to add a prefix (XX00) in each row of the line in my text file and save a newly generated file another name. How to go about it. (2) How to insert a blank line into each row in my file. and save the file another name.... (2 Replies)
Discussion started by: merry susana
2 Replies

2. UNIX for Dummies Questions & Answers

question from a dummy

okay so I just started this unix class and understood all the test questions but this "normal" question threy me through a loop :confused:. The question is Why are UNIX commands noninteractive and why is their output not usually preceededby header information? This question has been driving me... (2 Replies)
Discussion started by: cinnamonbear
2 Replies

3. Filesystems, Disks and Memory

A simple dummy question

Hello Everyone! changing from Microsoft to Macintosh, I connected my hard disk (nearly full) to the apple computer, which could not recognize it. I was prompt to "initialize it", unfortunately I DECIDED YES!!, but just for 1/100 of a second: now I cannot access the hard disk at all. Is still... (1 Reply)
Discussion started by: NETTO68
1 Replies

4. Shell Programming and Scripting

how to plug dummy data into zero byte file?

Hi, How can I plug dummy data into files that are zero bytes ? Here is a sample script for removing the files I think. find /path/to/directory -size 0 -type f -exec rm -f {} \; I am not sure how to change it to echo "dummy" > zerobyte.txt. Any suggestions? Here's the farthest I got:... (2 Replies)
Discussion started by: ihot
2 Replies

5. UNIX for Dummies Questions & Answers

Dummy question about /proc/cpuinfo

Perhaps this is a very dummy question but sorry I don't know other place to do it. We just buy a new cluster of Xeon machines but there is something I don't understand and perhaps someone can help me. The more /proc/cpuinfo produces the following output (just part of it). processor : 0... (1 Reply)
Discussion started by: jhc
1 Replies

6. UNIX for Dummies Questions & Answers

a dummy question...needs help...

I am trying to use 'cut' to get a line from my file. But it seems that 'cut' recongnizes TAB as default. My file uses space instead. So 'cut' doesn't work. Anybody can tell me how to change the default from TAB to space ? Or how to transform a space-delimited file into tab-delimited file??... (2 Replies)
Discussion started by: kaixinsjtu
2 Replies

7. UNIX for Dummies Questions & Answers

dummy question on data process

I have a file which contains 6 columns. But I only need the first 3 columns. So I need to remove the last 3 columns. I checked 'cut' but it seems not working. So is there a command that could remove certain columns from a file? :( Thanks a lot!! (5 Replies)
Discussion started by: kaixinsjtu
5 Replies

8. IP Networking

DNS dummy question

Hello everyone, I have a some doubt about DNS. We have connected to 2 ISPs /ISP#1 and ISP#2/. Our web site's dns zone is located on ISP#1. If connection to ISP#1 is down clients won't find our website. ISP#1 connection went down few times this month. So we are going to create our website's... (0 Replies)
Discussion started by: sembii
0 Replies

9. UNIX for Dummies Questions & Answers

Dummy question on awk

Hi, I have a file which has three columns and 200 rows. I would like to print an extra column say "disco" for every 10 th row starting from 4 th row. How is that possible? Thnx (4 Replies)
Discussion started by: Indra2011
4 Replies

10. UNIX for Beginners Questions & Answers

Dummy Question

Where can I get UNIX? (1 Reply)
Discussion started by: ciao303
1 Replies
clacrm.f(3)							      LAPACK							       clacrm.f(3)

NAME
clacrm.f - SYNOPSIS
Functions/Subroutines subroutine clacrm (M, N, A, LDA, B, LDB, C, LDC, RWORK) CLACRM multiplies a complex matrix by a square real matrix. Function/Subroutine Documentation subroutine clacrm (integerM, integerN, complex, dimension( lda, * )A, integerLDA, real, dimension( ldb, * )B, integerLDB, complex, dimension( ldc, * )C, integerLDC, real, dimension( * )RWORK) CLACRM multiplies a complex matrix by a square real matrix. Purpose: CLACRM performs a very simple matrix-matrix multiplication: C := A * B, where A is M by N and complex; B is N by N and real; C is M by N and complex. Parameters: M M is INTEGER The number of rows of the matrix A and of the matrix C. M >= 0. N N is INTEGER The number of columns and rows of the matrix B and the number of columns of the matrix C. N >= 0. A A is COMPLEX array, dimension (LDA, N) A contains the M by N matrix A. LDA LDA is INTEGER The leading dimension of the array A. LDA >=max(1,M). B B is REAL array, dimension (LDB, N) B contains the N by N matrix B. LDB LDB is INTEGER The leading dimension of the array B. LDB >=max(1,N). C C is COMPLEX array, dimension (LDC, N) C contains the M by N matrix C. LDC LDC is INTEGER The leading dimension of the array C. LDC >=max(1,N). RWORK RWORK is REAL array, dimension (2*M*N) Author: Univ. of Tennessee Univ. of California Berkeley Univ. of Colorado Denver NAG Ltd. Date: September 2012 Definition at line 115 of file clacrm.f. Author Generated automatically by Doxygen for LAPACK from the source code. Version 3.4.2 Tue Sep 25 2012 clacrm.f(3)
All times are GMT -4. The time now is 08:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy