I apoligize humbly. I have reproduced your result. I must have done something wrong to get the segfault. Many thanks.

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.

Show posts MenuPages1

#1

I apoligize humbly. I have reproduced your result. I must have done something wrong to get the segfault. Many thanks.

#2

Try with value 2.07. It gives segmentation fault here. I was aware that 3.14 is reported as 3.14 (with some fractional error) but thought it fit only to report the segfault. Thanks. Kindly help.

#3

There is a library, called exodriver downloadable from 'labjack' which gives its library version (2.07) as a 32 bit float through it's function LJUSB_GetLibraryVersion().This I have verified by importing this function in another programming language.

But newLisp v10.76 returns a value 0 instead of 2.07 when the following expression is used:

(import "liblabjackusb.so" "LJUSB_GetLibraryVersion" "float") followed by (LJUSB_GetLibrarVersion) returns a value 0 instead of 2.07.

Perhaps that is because "float" is a cut down version of "double"?

I just checked that there is segmentation fault reading a flost from libc on linux 64 bit, as follows:

(import "libc.so.6" "strtof" "float" "char*")

(strtof "2.07")

yields segmentation fault.

I would appreciate if this issue is resolved.

But newLisp v10.76 returns a value 0 instead of 2.07 when the following expression is used:

(import "liblabjackusb.so" "LJUSB_GetLibraryVersion" "float") followed by (LJUSB_GetLibrarVersion) returns a value 0 instead of 2.07.

Perhaps that is because "float" is a cut down version of "double"?

I just checked that there is segmentation fault reading a flost from libc on linux 64 bit, as follows:

(import "libc.so.6" "strtof" "float" "char*")

(strtof "2.07")

yields segmentation fault.

I would appreciate if this issue is resolved.

#4

#5

#6

For small x << 1, ln(1+x) and exp(x)-1 and sinh(x) are close to x. This means there is loss of several digits of precision when calculating exp(x)-1 from exp(x) because we taking difference of two numbers almost equal to one another and to 1. Likewise there is similar error in ln1+x) and sinh(x) when calculated from ln(x) and exp(x) for small x.

ANSI Forth, C, and x87 FPU provide instructions expm1(x) and log1p(x) to meet this need. Once expm1 and log1p are provided, accurate computation of sinh, asinh, tanh, atanh also becomes possible for small x.

Therefore I request that expm1 and log1p be provided in newLisp.

Pages1