From: mecej4 on
Lynn McGuire wrote:

<...>
> My long term goal is to convert our F77 code to C++ using FOR_C.
> We may be trying this later this year when all of our Hollerith
> code is gone.
A couple of points to quote in that regard:

i) Cobalt-Blue's FOR_C is an F77 to C (NOT C++) converter.

ii) FOR_C may choke on many of the non-standard F77 extensions used in
your code.

-- mecej4
From: Lynn McGuire on
>> My long term goal is to convert our F77 code to C++ using FOR_C.
>> We may be trying this later this year when all of our Hollerith
>> code is gone.
> A couple of points to quote in that regard:
>
> i) Cobalt-Blue's FOR_C is an F77 to C (NOT C++) converter.

Yes. But converting C code to C++ code is fairly easy. I've done
it several times now. However, converting char * strings to STL
strings is non-trivial but that can be done later.

> ii) FOR_C may choke on many of the non-standard F77 extensions used in
> your code.

Nope. FOR_C understands the vax structure, union, map and record
keywords. That is the only extension that we are currently using.

Thanks,
Lynn
From: Lynn McGuire on
> Les Hatton (he has a web site) has published reports on studies of production
> codes in oil exploration. C, C++ and Fortran with Fortran causing least
> problems. Various others have reported that C++ is a real bear with
> two caveats 1. no use of object inheritance 2. serious objects only
> when objects are very well designed such as the (many-ith iteration)
> of a design such as windows and the design is now static and widely used.
> Basically C++ is impossible to read/maintain is there is any serious
> local use of objects as one no longer knows what the code is doing with
> only a local inspection.

I found it here. http://www.leshatton.org/ with a specific
1992 paper at http://www.leshatton.org/Documents/JSX_0192.pdf .
A lot has changed in fortran and C++ since then. I will take a
look but we have quite a bit of experience here.

Thanks,
lynn
From: e p chandler on

"Lynn McGuire" <lmc(a)winsim.com> wrote in message
news:i02jfd$lmu$1(a)news.eternal-september.org...
>>> had one of my guys add an isothermal flash cache to our general
>>> flash. ...
>>
>> In a quick moment before heading to fields...
>>
>> I have no clue what you just said???
>
> Our software has a large thermodynamic calculation engine built
> into it. An isothermal flash is performed at a given temperature
> and a given pressure. Given a certain amount of components in a
> mixture (water, methane, ethane, propane, butane, pentane, carbon
> dioxide, hydrogen sulfide, etc - up to 1,000 components), we will
> calculate how much of each component is in the vapor phase, the
> hydrocarbon liquid phase and the aqueous liquid phase.
>
> So anyway, we save the results of the calculations now. If the
> flowsheet wants to make the same exact calculation again, we already
> have it saved. Apparently saves a lot of time !
>
> Thanks,
> Lynn

supposedly Terje Mathisen once said "All programming is an exercise in
caching."


From: e p chandler on

"mecej4" <mecej4.nyetspam(a)operamail.com> wrote in message
news:i03iq8$har$1(a)news.eternal-september.org...
> Lynn McGuire wrote:
>
> <...>
>> My long term goal is to convert our F77 code to C++ using FOR_C.
>> We may be trying this later this year when all of our Hollerith
>> code is gone.
> A couple of points to quote in that regard:
>
> i) Cobalt-Blue's FOR_C is an F77 to C (NOT C++) converter.
>
> ii) FOR_C may choke on many of the non-standard F77 extensions used in
> your code.
>
> -- mecej4

What about the quality of the converted code? Can you read it? Can you
maintain it? Or is it guacamole?