hello friends
i'm a mechanical engineer. i have to prepare an interface for an engineering
project using with Visual Fortran programming language.
i have learned something about Visual Fortran but i need your help to improve
myself and i have problems about the writing of modules, windows applications.
Can you help me
Waiting for your messages.
Thank you that works also, I used ACOS(-1) but that adds another variation =)
---------------------------------
Do you Yahoo!?
Get on board. You're invited to try the new Yahoo! Mail.
[Non-text portions of this message have been removed]
I am very new to FORTRAN and need to learn it quick. I wrote the
following code to find the definite integral of x^2 between 0 and 1
which should come out to 0.33333 etc. This same code with slight
syntax changes works in visual basic. When I run it in FORTRAN I
get .015625
The strange thing is if I try to make it less accurate by setting
dxval to 1000 and running the DO loop 1000 times I get a much more
accurate answer of .332828, running the same code in VB 1000 times
gives me .332833
I am guessing this has to do with a lack of understanding on my part
of how numbers are stored and calculated in FORTRAN variables but I
just can't find the mistake. I also tried converting dxval in the DO
loop to an integer with int(dxval) and still got the same result.
Here's the code. I am using a compiler called Plato3 and running it
under Windows XP.
PROGRAM ERIC
IMPLICIT NONE
real,parameter :: dxval=100000000.0,lower=0.0,upper=1.0
real :: dx,x,y
integer :: i
y=0.0
dx=(upper-lower)/dxval
x=0.0
DO i = 1,dxval, 1
y = y + ((x**2)*dx)
x = x + dx
END DO
write(*,*) y
END PROGRAM
ty works as ACOS(-1) Did more research when I was less frustrated =)
---------------------------------
Do you Yahoo!?
Everyone is raving about the all-new Yahoo! Mail.
[Non-text portions of this message have been removed]
Hi,
Try:
PI = ACOS(-1)
Best regards,
Alex
hezdanswe2 <hezdanswe2@...> escreveu: Hi,
I am a college student taking Fortran 95 as an elective. I was
given an assignment that has already been turned in. I had one part
that I could not answer because my trig skills are poor to begin with
and I have never programmed trig. My assignment was to declare PI but
instead of declaring it as a constant I was to declare it as a trig
formula. I got my entire program working, however I could not get the
trig formula down. We are using Unix to develope and compile our
programs. Can anyone help me? Thank you
---------------------------------
Yahoo! Search
Música para ver e ouvir: You're Beautiful, do James Blunt
[Non-text portions of this message have been removed]
hezdanswe2 wrote:
>
> Hi, I am a college student taking Fortran 95 as an elective.
Good for you!
> ... My assignment was to declare PI but
> instead of declaring it as a constant I was to declare it as a trig
> formula. I got my entire program working, however I could not get the
> trig formula down...
Hint: Look at the definitions of ACOS, ATAN, and/or ATAN2.
W.
PI = ATAN(1.0)*4
Larry
--- hezdanswe2 <hezdanswe2@...> wrote:
> Hi, I am a college student taking Fortran 95 as an elective. I was
> given an assignment that has already been turned in. I had one part
> that I could not answer because my trig skills are poor to begin with
> and I have never programmed trig. My assignment was to declare PI but
> instead of declaring it as a constant I was to declare it as a trig
> formula. I got my entire program working, however I could not get the
> trig formula down. We are using Unix to develope and compile our
> programs. Can anyone help me? Thank you
>
>
>
>
>
>
>
--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--*--
, ; , .-'"""'-. , ; ,
\\|/ .' '. \|//
\-;-/ () () \-;-/
// ; ; \\
//__; :. .; ;__\\
`-----\'.'-.....-'.'/-----'
'.'.-.-,_.'.'
'( (..-'
'-'
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
Hi, I am a college student taking Fortran 95 as an elective. I was
given an assignment that has already been turned in. I had one part
that I could not answer because my trig skills are poor to begin with
and I have never programmed trig. My assignment was to declare PI but
instead of declaring it as a constant I was to declare it as a trig
formula. I got my entire program working, however I could not get the
trig formula down. We are using Unix to develope and compile our
programs. Can anyone help me? Thank you
Hello,
I got a copy of Fortran Power Station from 1994. I love it. I have
alot of algorithms for doing just about everything. I have been
looking for the IMSL libraries for Fortran 77, but I can't find them.
Maybe somebody in the group could help me. I program mathematical
algorithms for engineering and science applications. I program in C,
C++, Java and Fortran. I even got an old computer to run the Fortran
compiler. It is so simple. Don't get me wrong I program C++ in a high
power computer. But I refused to let to waist all of my algorithms in
Fortran 77.
Thanks for the help.
--- In Fortran@yahoogroups.com, "Balwinder Singh"
<handsome_2k_21@...> wrote:
>
> Hi all,
> I am new to fortran, so I am just trying to know how fortran code
> uses memory.
> I run a fortran program and want to look up how much memory it
uses
> while its running. I look at the task manager(windows XP) to know
> the memory usage.
> I am using the following code to know how much memory my arrays
are
> using:
> >>>>
> allocate(a(nx))
> ............
> ............
> ............
> .............using a() here..........
> ..........
> .........
>
> pause -----[1]
>
> dealocate(a)
> pause-----[2]
>
> >>>>>>>>>>
>
> I check the task manager at [1] and [2].
> When I ran the code with multiple arrays (instead of just one), I
> didn't see any significant change in memory at [1] and [2] pause
> statement. I am just wondering if there is any other program which
> can tell me 'not so significant' memory changes?
>
> Thanks.
>
I think Process Explorer is probably better than winxp's Task
Manager. Otherwise, just a guess, whilst running, try the "mem"
command from a Dos_prompt.
Dyl.
Hi all,
I am new to fortran, so I am just trying to know how fortran code
uses memory.
I run a fortran program and want to look up how much memory it uses
while its running. I look at the task manager(windows XP) to know
the memory usage.
I am using the following code to know how much memory my arrays are
using:
>>>>
allocate(a(nx))
............
............
............
.............using a() here..........
..........
.........
pause -----[1]
dealocate(a)
pause-----[2]
>>>>>>>>>>
I check the task manager at [1] and [2].
When I ran the code with multiple arrays (instead of just one), I
didn't see any significant change in memory at [1] and [2] pause
statement. I am just wondering if there is any other program which
can tell me 'not so significant' memory changes?
Thanks.
hi i agree with saif in knowledge sharing process
with best regards
kathirvel.m
saif_n_85 <saif_n_85@...> wrote:
hello dear members
hopefully all of your are fine and doing well
i just have a sugession to improve this group
i think it will be nice idea if each member send his/her programs
which maade bye fortran programing language to share his/her
experiment with all members
with all my best regards
SPONSORED LINKS
C programming language Computer programming languages Java
programming language The c programming language C programming language
Concept of programming language
---------------------------------
YAHOO! GROUPS LINKS
Visit your group "Fortran" on the web.
To unsubscribe from this group, send an email to:
Fortran-unsubscribe@yahoogroups.com
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
---------------------------------
---------------------------------
Brings words and photos together (easily) with
PhotoMail - it's free and works with Yahoo! Mail.
[Non-text portions of this message have been removed]
hello dear members
hopefully all of your are fine and doing well
i just have a sugession to improve this group
i think it will be nice idea if each member send his/her programs
which maade bye fortran programing language to share his/her
experiment with all members
with all my best regards
hi i think i have the one i may send you the same as soon as possible
i am working in fortran77 of lahey if you want that icould send you sooner
kathirvel.m
---------------------------------
Yahoo! Mail - Helps protect you from nasty viruses.
[Non-text portions of this message have been removed]
hello all
i'm new to this nice group and i have a simple problem , hoplfuly you
help m e
i just want to download a free version of lahley ed4w (fortran 90)
but i couldn't find it
wishly help me
In 1974, Gustav Larsson, a young programmer from Helsinki,
Finland, stumbled upon an amazing discovery. While working
with a PDP-8 mainframe computer, Gustav suddenly because
bored. He decided to attempt to compile a single byte
program. For what reasons we cannot know.
Nevertheless, Gustav was already familiar with RTPS FORTRAN
and thus picked a single character to represent the
contents of the program: "@". Once compiled, he expected
nothing to happen.
He was wrong. To his absolute amazement, it compiled
successfully!
Using an ARS-33 Teletype, Gustav printed out the 1 byte program
followed by its output. It appeared to contain a message from
God. A devout Catholic, Gustav showed it to his immediate
supervisor, who ordered both the print out and the program
itself destroyed. Although Gustav complied with his wishes,
it is rumored that he kept a copy of the printout in a small
shoe box in his apartment in Helsinki.
He also kept a brown diary which included various small
passages from the "Helsinki Code" (as he described it years
later). According to Gustav, the Helsinki Code came directly
from the 'Mind of God.'
The Helsinki Code read (in part):
"...[M]y presence in your world is unalterable for I am the
sanctuary of both the cosmos and the one soul inside you. I
could awaken each of you in this very moment to [my] unity,
but there is a larger design - a more comprehensive vision -
that places you in the boundaries of time and the spatial
dimensions of separateness...[T]he design requires a
progression into my wholeness that reacquaints you with
[my] unity through the experience of separation. Your
awakening, while slow and sometimes painful, is assured,
and this you must trust above all else..."
(Page 26 of Gustav's Journal - Dated February 10th, 1975)
Gustav passed away in 1996. Although his diary has since
turned up missing, the above fragment from the 'Helsinki
Code' remains. Perhaps, just perhaps, we can learn to
be better people simply by reading it.
Paul
hello every one i am running a fortran code and during the execution
i get the "DATA TRANSFER BEYOUND END OF FILE"
Am running FEA codes the data given is nodal values.
what type of error it is and could it be solved
thank you
for your kindness
kathirvelm
Hello all,
I am hoping you will help with a Fortran Language
Dictionary (cheat-sheet) page in the Software
Engineers' Handbook Wikibook. I'm looking for a quick
overview of general program structure with pointers to
more specific information. (Yes, I could look this all
up, but it's much much faster if you know the language
well and have used it recently. The site is under the
GNU Documentation License, so I don't want to take
examples directly from books and many online
references.)
Here's the Fortran page:
http://en.wikibooks.org/wiki/Software_Engineers_Handbook:Language_Dictionary:FOR\
TRAN
Here is the web site for the wikibook
http://en.wikibooks.org/wiki/Software_Engineers_Handbook
I would love help with the other pages too.
I would be happy to coordinate submissions for folks
unwilling to adjust to wiki markup.
Thanks for the help!
Chris
__________________________________
Yahoo! Mail - PC Magazine Editors' Choice 2005
http://mail.yahoo.com
hi to all
m new to this great n nice group, i have a query regarding 'ill
conditioning' of a
matrix, if this warning is coming, can i ignore this? If i ignore this, can i
ensur that the results coming accurate?
if i should not ignore this, are there any other ways to solve this type of
'ill conditioning' ?
please help me...........
thanking you...........
Badam Nandu
contact me at 09840302560
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
[Non-text portions of this message have been removed]
millenavillar wrote:
> I would like to know how can I print the addres of a pointer , in
> Fortran 90. When I try to print the pointer only appear the value of
> the variable that is associated to it. Is there other manner than by
> "loc()"?? (but it only accept the associated variable)
F90 pointers are funny creatures in that almost any reference to them
causes them to be dereferenced.
The "usual trick" with F90 pointers is to place them into a derived
type:
type rpointer
real, pointer :: p(:) => NULL ()
end type
:
type(rpointer) :: my_pointer
:
print '(a,z)', 'the address of my_pointer is: ', loc (my_pointer)
This is also the "usual trick" for defining arrays of pointers.
HTH,
Walt
--- In fortran@yahoogroups.com, "millenavillar" <millenavillar@y...>
wrote:
> I would like to know how can I print the addres of a pointer , in
> Fortran 90. When I try to print the pointer only appear the value of
> the variable that is associated to it. Is there other manner than by
> "loc()"?? (but it only accept the associated variable)
F90 pointers are funny creatures in that they are dereferenced in
almost all contexts. You are not supposed to be able to get at them
directly.
A "usual trick" with F90 pointers is to place them into a derived
type:
type rpointer
real, pointer :: p(:) => NULL ()
end type
:
type(rpointer) :: my_pointer
:
print '(a,z)', 'the address of my_pointer is: ', loc (my_pointer)
This is also the "usual trick" for defining arrays of pointers.
HTH,
Walt
millenavillar <millenavillar@...> wrote:Hi,
I would like to know how can I print the addres of a pointer , in
Fortran 90. When I try to print the pointer only appear the value of
the variable that is associated to it. Is there other manner than by
"loc()"?? (but it only accept the associated variable)
thanks
millena
SPONSORED LINKS
Basic programming language C programming language Computer programming languages
The c programming language C programming language List of programming languages
---------------------------------
YAHOO! GROUPS LINKS
Visit your group "fortran" on the web.
To unsubscribe from this group, send an email to:
fortran-unsubscribe@yahoogroups.com
Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service.
---------------------------------
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
[Non-text portions of this message have been removed]
Hi,
I would like to know how can I print the addres of a pointer , in
Fortran 90. When I try to print the pointer only appear the value of
the variable that is associated to it. Is there other manner than by
"loc()"?? (but it only accept the associated variable)
thanks
millena
hi to all
m new to this great n nice group,
i have a query regarding 'ill conditioning' of a
matrix, if this warning is coming, can i ignore this?
If i ignore this, are the results coming accurate?
if i should not ignore this, are there any other
ways to solve this type of 'ill conditioning'
thanking u all
Badam Nandu
have fun at 09444176573
__________________________________________________
Do You Yahoo!?
Tired of spam? Yahoo! Mail has the best spam protection around
http://mail.yahoo.com
--- In fortran@yahoogroups.com, "dlyzxl" <dlyzxl@y...> wrote:
> Dear friends:
>
> I am trying to compile downloaded mopac7 source code (many files)
in
> Sparc solaris system. Tons of errors come up. A little beginning is
> copied directly.
>
> Can any one suggest me how so many errors are caused? by system? by
> compiler? etc.......
>
There are two problems with the example code, but these are
probably only the tip of the iceberg.
i. The $ format descriptor means write the line without a newline
(Carriage return, linefeed etc) at the end. It is non-
standard, but is supported by most Fortran systems. Most (not
all) of those do not require a comma to separate the $ from
the next token. Your Solaris compiler either doesn;t accept $
(there is an alternative and standard mechanism in Fortran 90)
or requires the comma.
ii. The Fortran standard requires that a COMMON block (except the
un-named common) is the same size wherever it is referenced.
Many Fortran compilers do not impose this restriction. Most
Unix compilers do. Yours does.
The underlying problem is that the code was written for a fairly
permissive system like VMS or CVF, and won't run on a strict Fortran
90 or Fortran 77 system. We have a tool, WinFPT (See
http://www.simcon.uk.com) which will convert the code. Please
contact us if you would like to use it.
Best wishes, and good luck!
John.
john_collins@...
Dear friends:
I am trying to compile downloaded mopac7 source code (many files) in
Sparc solaris system. Tons of errors come up. A little beginning is
copied directly.
Can any one suggest me how so many errors are caused? by system? by
compiler? etc.......
errors:
[rathlefs@ishmael ~/users/justin/mopac_1]$ g77 -O *.f -o mopac.exe
ef.f: In subroutine `ef':
ef.f:198: warning:
$ ' CARTESIAN OPTIMIZATION.',/,1x,'IF THE OPTIMIZATION IS',
^
Missing comma in FORMAT statement at (^)
ef.f: In subroutine `efstr':
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:564: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2
Common block `nllcom' is 1152960 bytes in length at (1) but 923520
bytes at (2)
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:564: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2
Common block `nllcom' is 1152960 bytes in length at (1) but 923520
bytes at (2)
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:564: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2
Common block `nllcom' is 1152960 bytes in length at (1) but 923520
bytes at (2)
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:564: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2
Common block `nllcom' is 1152960 bytes in length at (1) but 923520
bytes at (2)
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:564: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2
Common block `nllcom' is 1152960 bytes in length at (1) but 923520
bytes at (2)
ef.f: In subroutine `gethes':
ef.f:48: warning:
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT(MAXPAR,MAXPAR),
1
ef.f:1032: (continued):
COMMON /NLLCOM/ HESS(MAXPAR,MAXPAR),BMAT
(MAXPAR,MAXPAR),
2