[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: fid=-1
From: |
Andy Buckle |
Subject: |
Re: fid=-1 |
Date: |
Thu, 26 May 2011 20:07:21 +0100 |
On Thu, May 26, 2011 at 7:51 PM, James Sherman Jr. <address@hidden> wrote:
>
>
> On Thu, May 26, 2011 at 3:51 AM, Federica <address@hidden>
> wrote:
>>
>> Hi,
>>
>> I'm new to this forum and above all I'm new to Octave....in this forum I
>> found some useful information on how Octave works but I'm having a lot of
>> problems in trying to create a script with Octave 3.2.4 on Windows and so
>> I
>> decided to ask for your help. I'd like to solve a system of differential
>> equations whose coefficients must be taken from a txt or csv file. Each
>> row
>> of the file gives the 8 coefficients needed by the the two equations. So I
>> was thinking that dlmread could be useful but a first problem appears. The
>> file cannot be opened and I don't understand why. I tried with
>>
>> filename= "prova.txt"
>> fid=fopen(filename, "r")
>>
>> but the fid=-1 so it cannot opened but why? the txt file contains numbers
>> with 3 decimal numbers
>
> Hi Frederica,
> My first guess (and I've done this many times) is that you're not in the
> correct directory. Try comparing the output of "pwd" with the directory
> where your txt file is located. If they are different, either use "cd" to
> change your current working directory or include the entire path in your
> filename.
> Hope this helps,
> _______________________________________________
> Help-octave mailing list
> address@hidden
> https://mailman.cae.wisc.edu/listinfo/help-octave
and if you do this it will tell you why it can't open it.
[fid msg]=fopen(filename, "r")
--
/* andy buckle */
- fid=-1, Federica, 2011/05/26
- Re: fid=-1, James Sherman Jr., 2011/05/26
- Re: fid=-1,
Andy Buckle <=
- Re: fid=-1, Federica, 2011/05/27
- Re: fid=-1, Federica, 2011/05/27
- Re: fid=-1, marco atzeri, 2011/05/27
- Re: fid=-1, Andy Buckle, 2011/05/27
- Re: fid=-1, Federica, 2011/05/27
- Re: fid=-1, Federica, 2011/05/27