Software :: Reading And Writing SAC (Seismic Analysis Code) Data Files In Fortran Codes
Dec 2, 2008
I synthesized a seismogram by using Fortran codes, I need plot the synthesized seismogram and the data together, so I can verify the accuracy of code. Now I encounter a question: how to read the SAC data by Fortran code, I have searched some codes on Internet, the details as follow:the velr12a.sac is my data file.
Code:
c read sac file
PROGRAM RSAC
PARAMETER (MAX=1000)
DIMENSION YARRAY(MAX)
CHARACTER*10 KNAME
[Code]....
View 2 Replies
ADVERTISEMENT
Jan 1, 2011
Reading and writing text files in C?
View 9 Replies
View Related
Mar 18, 2010
Samba seems to crash and come back after some seconds if I copy a lot of small files in a short period of time over the network. How do I fix it?
I have Ubuntu 9.10 Server 64bit running on a D945GCLF2 board sharing two 1TB ext4 formatted HDDs to my Windows PCs using samba. I've been having an issue with reading or writing files through samba. It happens during copying operations or checksumming, anything that reads or writes MANY small files in a small amount of time. I am pretty sure the problem has to do with my server because the server has run on two different LANs in different homes and will crash from activity with any of several other PCs. There is no crashing if I access the files through SSH, although when I do that the max transfer speed is less than 1MB/s.
When I induce the crashing, there is absolutely no output to the server terminal.
As an easy access example of something that will crash samba, extracting Cinebench R11.5 to the server will do the job. It always fails.
View 9 Replies
View Related
Sep 27, 2010
Whenever I am busy reading or writing large files, or large sum of files, my computer is unresponsive. Screens are getting greyed-out and I just can sit there and wait until the reading/writing is done.
This is not caused by the CPU which is overstressed because it is not. Look at the attachments and you will see the CPU is used for about 20%. When these pictures were captured the computer was using hellanzb to unrar a long list of rar-files.
When you look at my signature you see the computer is not bad at all, just disk-access is slow. I can transfer files with a maximum speed of 30MB/s. Is that normal or is it very slow? I don't know the numbers. I have 2 SATA disks.
O.S. is Mint 9-Isadora, based on Ubuntu 10.04 and I use the 64-bits version.
View 9 Replies
View Related
Mar 17, 2011
I have a folder which includes bunch of folders each having data files in them. [ Folder A has F1, F2 F3 ..... F1000 folders in it, and F1, F2, F3 ... each has about 10 different files named FILE 1, FILE2, FILE3 .... in them.
I am interested in File 1 of each Folder, because that contains the data I need in it. More specifically, that File1 s have a line "ANSWER=..." in them, and i need to get that value of the ANSWER from each file. So doing it by hand is so hard, so I need to write a script that will scan all folders and give me a list of values of eache ANSWERs.
View 4 Replies
View Related
Aug 9, 2010
I'm having trouble reading EXIF data from TIFF files. Both 8 bit and 16 bit fail to load EXIF data via eye of gnome and GIMP and I'm not sure why. Neither files downloaded online nor rendered from Bibble 5 seem to work. Using Ubuntu 10.04 64bit and GIMP 2.7.2.
View 2 Replies
View Related
Jul 20, 2010
I have recently stumbled across some aged lecture notes that were posted to the Internet in the 1990s. And I now have the leisure to read them (and possibly derive some benefit from the reading).
The covering "ReadMe" states that the notes were originally written in WordStar and posted to the Internet as WordPerfect documents. The text is perfectly readable. But the supplied references have formating codes that mean nothing to my readers. An example is:
Plato explicitly says that the Good is "above being"
(i+5df8h-epe-i+5d'keina f8t^-yv oum0-i+9dh chapter s'-iav).
Is there any current reader that understands these code?
View 2 Replies
View Related
May 20, 2010
i installed kernel 2.6.34 to fix my lid closing issue, and that went great. but now when i go to reinstall my broadcom i get this error. Code: Reading package lists... Done Building dependency tree Reading state information... Done bcmwl-kernel-source is already the newest version. 0 upgraded, 0 newly installed, 0 to remove and 1 not upgraded. 1 not fully installed or removed. After this operation, 0B of additional disk space will be used. Setting up bcmwl-kernel-source (5.60.48.36+bdcom-0ubuntu3) ... Removing old bcmwl-5.60.48.36+bdcom DKMS files...
[Code].....
View 9 Replies
View Related
Sep 11, 2010
I am currently looking for tools for static/dynamic code analysis for embedded Linux system development (both device driver and user space apps). We will use Eclipse IDE and C++ lanuage. I hope the tools are easy-to-use, reliable, popular, better with good supports, and not-too-expensive. I already find a list of tools at WiKi, however, I don't have time to try them all. Could anyboy please recommend me a few? If you can tell me briefly about their pros and cons, that will be the bet.
View 1 Replies
View Related
Oct 1, 2010
I need to read raw codes from various remote controls (for TVs, DVRs, etc). For that I use a Tekram IR-210B serial dongle. At least I try, since I can't put any meaning on the codes I get by reading /dev/ttyS0 . I tried various tricks, including reading /dev/ttyS0 as a stream, using the Linux irda stack, lirc, similar experiments with Windows 2000/XP too, but nothing seems to work (at least not as I am expecting). The technical documentation is non-existant, Tekram e-mail support doesn't answer (or returns non-existant user errors when it does), browsing the kernel file tekram.c didn't help either, so I'm kind of stuck.
Because I won't need this for more than a few days (or weeks at the very most), I don't need a rock-solid solution, what I need is nothing mode than read raw (presumably RC-5) codes from a few remote controls (2 of them being from mainstream brands, another one claiming to be universal). So if nothing else a dirty trick will perfectly do.
Ideally, a technical documention on how to get the raw codes from the remote controls is what I am looking for. Something that tells me what baud rate to use, which parity, number of stop bits, and how to decode the stream (as I suspect it doesn't contain the raw codes as-is). However, I will be happy with any advice you may have on where to look or what tricks I might try.
View 4 Replies
View Related
Sep 11, 2010
I am looking for tools for static/dynamic code analysis for embedded Linux system development (both device driver and user space apps). We will use Eclipse IDE and C++ lanuage. I hope the tools are easy-to-use, reliable, popular, better with good
supports, and not-too-expensive. I already find a list of tools at WiKi, however, I don't have time to try them all. Could anyboy please recommend me a few? If you can tell
me briefly about their pros and cons, that will be the bet.
View 1 Replies
View Related
Apr 15, 2009
I'm trying to call some Fortran 95 code in C, but I'm having problems with integers not having the same value in C as in Fortran, and changing values upon each run of the program. I think it has to do with the integer type, but I don't know how to fix it. I'm running Gentoo x86. Here are the files I've got:
foo.c:
Code:
#include <stdio.h>
extern int qux_();
main() {
[code]....
View 2 Replies
View Related
Aug 28, 2011
Fedora 15 uses scidavis (Scientific Data Analysis and Visualization) taken from Fedora 14. If you try to build the native rpm package, an error occurs in building the documentation. A 1-line sed in the spec file solves the problem:
Code:
#fix spurious-executable-perm
find . -type f -exec chmod 0644 {} ;
#fix docbook to adapt different versions of fedora
sed -i "s/VER-REL/`rpm -q docbook-dtds|sed "s/^[^0-9]*//;s/.noarch//;
s/./\./g"`/" manual/docbook-en/index.docbook
#
# ---> sed line to fix Fedora15 building:
sed -i -e 's/xsl-stylesheets-1.75.2/xsl-stylesheets-1.76.1/' manual/scidavis_html.xsl
#
#fix default path for fitPlugins
sed -i "s/usr/lib/%{name}/plugins\%{_libdir}/%{name}/pluginsg"
%{name}/src/ApplicationWindow.cpp
sed -i -e 's/Qt;Science;Physics;Math;Graphics;/Education;Science;DataVisualization;Qt/' %{name}/%{name}.desktop
View 1 Replies
View Related
Aug 19, 2011
I have a big fortran code for FE analysis. I want to change the code to python. I am curious to know, whether I will get any advantage over speed, If not at least the speed should not be less than what fortran gives. Should I go for it.
View 2 Replies
View Related
May 18, 2011
I can compile an old fortran program on my macbook using the Absoft fortran compiler and the command:f90 'W132 C SOURCECODE.flU77lV77
Unfortunately I cannot find f90 for linux. I can, however, find gfortran. However, gfortran does not recognize the flag -W132 and when I remove -W132 the compiler thinks all lines end after a certain number of characters. Does anyone know what flags call the equivalent type of compilation using gfortran? Is it possible I need to use f90? If so, is there a free version of f90 for linux?
View 8 Replies
View Related
Jun 10, 2009
I'm not a Fortran coder but I need to call the sub-routine ADAPT.f from a c code.This subroutine calculates a multiple integral of a given function.My problem is that the c code works with no problem in a 32 bit machine but it does not in a 64 bit machine, and the problem seems to be related to adapt, which calculations gives a NA rather than the result of integration.Since fortran is quite obscure for me, I don't know why is this happening. Maybe I should change some data type (from real to double), but I'm not sure. Does anyone have a clue?
View 3 Replies
View Related
Mar 10, 2011
I am dealing with one FORTRAN 90 code, have made small changes.
milenko@milenkons:~/mt4$ make mt4
make: 'mt4' is up to date.
milenko@milenkons:~/mt4$ ifort -c MT2DDIB1.FOR
milenko@milenkons:~/mt4$ make mt4
make: 'mt4' is up to date.
milenko@milenkons:~/mt4$ make mt4
make: 'mt4' is up to date.
milenko@milenkons:~/mt4$ make mt4
make: 'mt4' is up to date.
I go for make command but it does not see that the source code has been modified.Than I do compilation from command line,try make again but no use.
F95=ifort
FFLAFGS= -O1
mt3: driver_mt2ddi.o constants.o settings.o params.o mt2dmod.o fdsystem.o mt2ddat.o mt2dsens.o
$(F95) -o $(FFLAGS) mt3 constants.o settings.o params.o mt2dmod.o fdsystem.o mt2ddat.o mt2dsens.o driver_mt2ddi.o
driver_mt2ddi.o: driver_mt2ddi.for constants.o settings.o params.o mt2dmod.o fdsystem.o mt2ddat.o mt2dsens.o
$(F95) -c $(FFLAGS) driver_mt2ddi.for
View 2 Replies
View Related
Jan 25, 2011
user@user-laptop:~$ sudo dd if=sd_backup of=/dev/sdd bs=4M conv=noerror,sync
205520896 bytes (206 MB) copied, 28.564 s, 7.2 MB/s
247463936 bytes (247 MB) copied, 57.1285 s, 4.3 MB/s
260046848 bytes (260 MB) copied, 73.2388 s, 3.6 MB/s
289406976 bytes (289 MB) copied, 104.121 s, 2.8 MB/s
[Code]....
How come dd gets slower after copying this 8GB file? What can I do about it?
View 1 Replies
View Related
Mar 14, 2010
I remotely access to my OPENsuse 11. I am using TightVNC program. There is nothing wrong with accessing. But I have to start an analysis program, an this analysis takes about 4 to 6 hours. Therefore, I want to disconnect and let my analysis continue.But after disconnecting from suse, the program i started stops to work. Does anybody know how not to kill the program while i am not connected?
View 6 Replies
View Related
Feb 9, 2010
I've been able to get access to our Netgear NAS, I can browse it, copy files etc. just fine. But I don't have "direct access" in as far as, Open Office won't open any files residing on the NAS, neither can I save directly to the NAS form a program and when I get a "Browse for File" form field on a website (eg attachments in GMail etc.), I can't browse to the NAS either. My XP box does do all of this, either through my mapped network drive or even through browsing the network. How can I make openSuse 11.2 use the NAS with my login credentials as if it was a local disk?
View 4 Replies
View Related
May 9, 2010
I've used ext2ifs drivers to mount my ext3 partition in winxp, but I don't have write acces, it's mounted in a read-only mode, and i didn't check the rad-only box during the installation of the drivers. [URL] It's a straithfoward proces so I dont understand what I did wrong. I'm using fresh xp install with (more or less) all the updates and ubuntu 10.04 Also the partition is mounted at /home, so I dont know if that makes any difference.
View 1 Replies
View Related
May 9, 2010
I've used ext2ifs drivers to mount my ext3 partition in winxp, but I don't have write acces, it's mounted in a read-only mode, and i didn't check the rad-only box during the installation of the drivers.I've used help from the official site http://www.fs-driver.org/and this tutorial http://www.dedoimedo.com/computers/l...s-windows.html
It's a straithfoward proces so I dont understand what I did wrong.I'm using fresh xp install with (more or less) all the updates and ubuntu 10.04Also the partition is mounted at /home, so I dont know if that makes any diferance.
View 3 Replies
View Related
Jul 25, 2010
My main workstation incorporates a mixture of ext3, ext4, and NTFS partitions scattered across a number of hard drives. Several of the ext4 partitions are encrypted, and I intend to encrypt the rest of the Linux partitions in the near future.I run VMware workstation, with several Windows OS guests, including Win2K, WinXP and Win7. My Win7 VM is installed on a virtual hard disk, and that virtual hard disk is encrypted using VMware facilities.So this leaves me with a bunch of NTFS partitions that are not encrypted. These are physical partitions on a couple of different hard drives. The reason I have them is ancient and historical, and as I have upgraded my system over time I have maintained the architecture due to the extreme difficulty of rearranging Windows systems.I still need to maintain Win2K and WinXP support, and rearranging those virtual machines would represent a hideous nightmare for me; I really want to maintain the same hard drive partition architecture.But I want to encrypt the NTFS partitions, in a fashion that can be handled by any of the Windows operating systems, AND can be accessed for read and write from Linux.Is this possible? If not using Windows facilities (I don't think ntfs-3g handles encryption, and there are known backdoors in the Windows facilities anyway), is there any third party solution that would work? Would True Crypt do the job in a fashion that would permit access from all the various operating systems, as required? I do generally mount the NTFS partitions in whichever Windows VM is appropriate, then share them out via SMB, but there are circumstances (like when a VM is not running) where I will directly hit them from Linux. So, it is possible for me to contemplate a solution that only works from Windows, but this would cost me the ability to repair/modify those filesystems directly from Linux, which under certain circumstances (a malfunction of the VM, for instance) could be a problem.
View 2 Replies
View Related
Dec 5, 2008
I am about to write a program to listen and read data from /dev/ttyS0 and write the data to /dev/ttyS1 after processing. Also, the same time I need to listen to /dev/ttyS1 and write to /dev/ttyS0 if any data arrived at /dev/ttyS1.
View 9 Replies
View Related
Dec 3, 2010
I would like to write a program that can read every ethernet frame arriving on a specific hardware NIC, without a TCP/IP stack otherwise doing anything on that NIC. Likewise I want to be able to write out to that NIC. So every arriving ethernet frame, of all types, would be readable (probably one at a time to preserve frame boundaries). And every write of exactly that same data would send frames out. The data read and written would be the whole ethernet frame. The kernel would do nothing else with this data, but other NICs would still operate as usual.
What I would be doing is that on 2 separate NICs, copying frames from one to the other, as in bridging. But I would also be doing modifications per what my program needs to do (not at liberty to say what that would be). What facility would I need to be looking at to do this? There is no ethernet device file. Would raw sockets be able to do this? The programming language will be C.
View 4 Replies
View Related
Jan 18, 2011
I just want to read and write some values (integer) to my driver. I used put/get user but always getting errors.
driver
Quote:
int Wert;
static int device_ioctl(struct inode *inode, struct file *file, unsigned int cmd, unsinged long arg)
int ret;
[code]...
Quote:
int WERT
ret=ioctl(fd, SETIT, WERT)
ret=ioctl(fd, GETIT, WERT)
if i say in C++ WERT is 5 the value arg of the driver becomes 5 but not WERT the returnvalue of get and put user is -1 so it failed.
View 12 Replies
View Related
Apr 3, 2010
I want to be able to access my email account from the console. I'm reading all day about fetchmail, postfix, sendmail etc. but all the stuff I found is related to building whole mail system. All I want to do is to read my emails and write some. Which is the painless way to do this? I successfully configured Evolution for this purpose but I want to do that from the console.
View 10 Replies
View Related
Jul 27, 2011
I am looking for a text editor that does 1) syntax highlighting2) code folding3) it would be a bonus if I could set which macros were defined and it would show me the source I have tried geany, and codeblocks. Both incorrectly code fold around preprocessor #ifdef and #endif. The gedit plugin doesn't seem to work at all
View 7 Replies
View Related
Mar 5, 2010
I have an application where I am sending data via serial port from PC1 (Java App) and reading that data in PC2 (C++ App). The problem that I am facing is that my PC2 (C++ App) is not able to read complete data sent by PC1 i.e. from my PC1 I am sending 190 bytes but PC2 is able to read close to 140 bytes though I am trying to read in a loop.Below is code snippet of my C++ AppOpen the connection to serial port
Code:
serialfd = open( serialPortName.c_str(), O_RDWR | O_NOCTTY | O_NDELAY);
if (serialfd == -1)
[code]...
View 5 Replies
View Related
Dec 2, 2010
I am trying to read a file character wise and trying to write the same character to another file. In this process, I unable to read and write white spaces successfully to the new file. The script reads the white spaces but while writing the white space is lost. The section of the code, is given below. Please advice how can i read and retain the white space while writing to a new file.
Code:
if [ -s f_test.txt ] && [ -f f_test.txt ]; then
echo "File Exists !!"
while read -n1 char; do
[code]....
View 2 Replies
View Related