Scientific notation with D instead of E

352 views
Skip to first unread message

Shane McCarthy

unread,
Jun 15, 2016, 7:05:02 AM6/15/16
to isla...@googlegroups.com
We are building a repository that to index files generated by Fortran programs.  There are files that use D instead of E for the exponent in scientific notation.  Unfortunately the value is only accepted by solr when it is a string when it is D.  Is there a way to make solr accept a number with the notation using the D as a double?

Shane

Jared Whiklo

unread,
Jun 15, 2016, 11:34:38 AM6/15/16
to isla...@googlegroups.com
Hi Shane,

It's been a while since I did any fortran. But it appears that the D
relates to double precision numbers vs the E which are for single
precision numbers.

My guess is going to be that to do this in Solr you'll need to use a
TrieDoubleField. But I've never tried and it is possible that due to
this being a Fortran specific declaration, you will still need to
convert the D -> E. But perhaps in an indexing filter?

cheers,
jared
> --
> For more information about using this group, please read our Listserv
> Guidelines: http://islandora.ca/content/welcome-islandora-listserv
> ---
> You received this message because you are subscribed to the Google
> Groups "islandora" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to islandora+...@googlegroups.com
> <mailto:islandora+...@googlegroups.com>.
> Visit this group at https://groups.google.com/group/islandora.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/islandora/CAAhmLgPBb5Yw%3D97hdaO9C%2BvvGjVKCc8rOaoezdSec4%3DVD1KY9w%40mail.gmail.com
> <https://groups.google.com/d/msgid/islandora/CAAhmLgPBb5Yw%3D97hdaO9C%2BvvGjVKCc8rOaoezdSec4%3DVD1KY9w%40mail.gmail.com?utm_medium=email&utm_source=footer>.
> For more options, visit https://groups.google.com/d/optout.

--
Jared Whiklo
jwh...@gmail.com
--------------------------------------------------
There is always one more imbecile than you counted on.

signature.asc

Shane McCarthy

unread,
Jun 15, 2016, 2:12:40 PM6/15/16
to isla...@googlegroups.com
Hey Jared,

You can even have Q for quadruple precision.  I have only really used Fortran90 so everything was E.  

Thankfully the fellow responsible for the parsing of the output into the xml documents was able to remove the D so the problem was solved that way.

Thanks,
Shane



To unsubscribe from this group and stop receiving emails from it, send an email to islandora+...@googlegroups.com.
Reply all
Reply to author
Forward
0 new messages