Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.c++ > #91700
| Path | csiph.com!weretis.net!feeder8.news.weretis.net!eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail |
|---|---|
| From | Ben Bacarisse <ben.usenet@bsb.me.uk> |
| Newsgroups | comp.lang.c++ |
| Subject | Re: Problem with calling C++ from Fortran |
| Date | Tue, 12 Sep 2023 14:14:03 +0100 |
| Organization | A noiseless patient Spider |
| Lines | 34 |
| Message-ID | <87cyynpm90.fsf@bsb.me.uk> (permalink) |
| References | <udhbs9$e5d$1@dont-email.me> <udhcaj$j8l$1@dont-email.me> <udkdu9$itm4$1@dont-email.me> <87o7iajh8b.fsf@bsb.me.uk> <udmvg7$11r4u$1@dont-email.me> <87cyyoqoka.fsf@bsb.me.uk> <udp8l4$1frsv$1@dont-email.me> |
| MIME-Version | 1.0 |
| Content-Type | text/plain |
| Injection-Info | dont-email.me; posting-host="0b3d05af22d1f5f0f239039facdde43d"; logging-data="1662275"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+FP35JNpikUtB3e/UOXxHz5Hv5DCQsVPo=" |
| User-Agent | Gnus/5.13 (Gnus v5.13) Emacs/28.2 (gnu/linux) |
| Cancel-Lock | sha1:QxxxAqkfrnWkfwMM/Rkesk9UfPU= sha1:LE+fr7O5G7yMYT2HHUUwTTzRrG8= |
| X-BSB-Auth | 1.3a07ebe5454fef238a8e.20230912141403BST.87cyynpm90.fsf@bsb.me.uk |
| Xref | csiph.com comp.lang.c++:91700 |
Show key headers only | View raw
db <dieterhansbritz@gmail.com> writes: >> BTW, you said the C++ was written by a C++ expert. I don't think it >> was! >> > The code, apart from the extra lines suggested by someone here, > but without the information on where to put them, is runnable > C++ code written by another person who knows C++ very well. I was just saying that the code does not look like it was written by someone who knows C++ very well. All those unnecessary duplicated sizes. A const qualified function return type. Including "math.h" rather that either <math.h> or <cmath>. > I myself use Fortran and you are right, I know next to nothing about > C++. Did I say that? Sorry. > I did use the extra code exactly as is, but possibly > put it in the wrong place. I tried two, without success. > I am giving up, and will translate the C++ function into Fortran, > where I know what I'm doing. OK. Odd to give up just as two people have given you working code. Oh well... Mind you, the C++ (or C) just picks an array and an initial value (an 'x' in a polynomial evaluation) and calculates a simple sum. It will be trivial in Fortran. The hard work is in the coefficients and those can just be coped. -- Ben.
Back to comp.lang.c++ | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-09 10:54 +0200
Re: Problem with calling C++ from Fortran Muttley@dastardlyhq.com - 2023-09-09 09:02 +0000
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-09 12:47 +0200
Re: Problem with calling C++ from Fortran Muttley@dastardlyhq.com - 2023-09-09 10:51 +0000
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-09 12:52 +0200
Re: Problem with calling C++ from Fortran Muttley@dastardlyhq.com - 2023-09-09 11:00 +0000
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-10 14:33 +0200
Re: Problem with calling C++ from Fortran Paavo Helde <eesnimi@osa.pri.ee> - 2023-09-10 18:49 +0300
Re: Problem with calling C++ from Fortran Muttley@dastardlyhq.com - 2023-09-11 08:23 +0000
Re: Problem with calling C++ from Fortran Paavo Helde <eesnimi@osa.pri.ee> - 2023-09-09 16:56 +0300
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-10 14:36 +0200
Re: Problem with calling C++ from Fortran James Kuyper <jameskuyper@alumni.caltech.edu> - 2023-09-11 00:14 -0400
Re: Problem with calling C++ from Fortran Bo Persson <bo@bo-persson.se> - 2023-09-10 16:08 +0200
Re: Problem with calling C++ from Fortran "Alf P. Steinbach" <alf.p.steinbach@gmail.com> - 2023-09-09 16:30 +0200
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-10 14:48 +0200
Re: Problem with calling C++ from Fortran Ben Bacarisse <ben.usenet@bsb.me.uk> - 2023-09-10 14:22 +0100
Re: Problem with calling C++ from Fortran Ben Bacarisse <ben.usenet@bsb.me.uk> - 2023-09-10 17:27 +0100
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-11 14:00 +0200
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-11 05:21 -0700
Re: Problem with calling C++ from Fortran Muttley@dastardlyhq.com - 2023-09-11 13:33 +0000
Re: Problem with calling C++ from Fortran Ben Bacarisse <ben.usenet@bsb.me.uk> - 2023-09-12 00:26 +0100
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-12 10:48 +0200
Re: Problem with calling C++ from Fortran Ben Bacarisse <ben.usenet@bsb.me.uk> - 2023-09-12 14:14 +0100
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-12 07:15 -0700
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-12 02:00 -0700
Re: Problem with calling C++ from Fortran Ben Bacarisse <ben.usenet@bsb.me.uk> - 2023-09-12 14:22 +0100
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-12 07:32 -0700
Re: Problem with calling C++ from Fortran db <dieterhansbritz@gmail.com> - 2023-09-12 18:36 +0200
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-19 02:39 -0700
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-10 08:38 -0700
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-10 09:51 -0700
Re: Problem with calling C++ from Fortran Michael S <already5chosen@yahoo.com> - 2023-09-11 02:49 -0700
Buy Zen Mushroom Chocolate Bar Microdose "https://psychedelicminds.shop/" <psychedelicsmind@gmail.com> - 2023-09-11 05:14 -0700
csiph-web