development release version 9.0.4

Started by Lutz, November 28, 2006, 05:34:19 AM

Previous topic - Next topic

Lutz

• new hyperbolic functions

• round

• expanded HTTP server mode for GET queries

• support for HTTP DELETE



For files and change notes see:



http://newlisp.org/downloads/development/">http://newlisp.org/downloads/development/



Lutz

newdep

#1
Thanks Lutz!



You know what I always thought was funny in newlisp, that "pi" is missing ;-)

(Its there ofcourse (div 22 7)..)



I know it can be set ofcourse, but a lot of languages have it predefined, not

that it is always needed or should be..But because you are now touching hyperbolics I just thought to give it a ring ;-)



Norman.





BTW: I thing that 'ostype is one of the few static's in newlisp, why did you not

chose for  (ostype) ?





BTW2: Ill just try it again, now your extending the internal http functions is there a change to get callbacks from those to report bytes processed?

(I requested it befor)
-- (define? (Cornflakes))

Lutz

#2
For PI you can use:


> (mul 2 (acos 0))
3.141592654
> (atan2 0 -1)
3.141592654


'ostype' is less to type then '(ostype)' and there are no parameters to pass. If you need more detailed info use: (sys-info). 'ostype' wil mostly be used like this: (if (= ostype "Win32") ...) etc.



(put-url ... ) and (write-file "http://...") or (append-file "htttp:// ...") report the number of bytes transferred as a small text snippet coming back.



The only thing missing is processing POST requests (v.9.0.5) and that will be all. The newLISP HTTP server mode is mainly for:



(a) distributed application support for file transfer between nodes, loading programs from remote nodes via HTTP and execute code remotely via HTTP. The same server node also understands 'net-eval' requests at the same time.



(b) for behind the firewall webserving without any security or rewriting URL's and the like. The newLISP HTTP server mode does not try to replace Apache or another web server installations, but could be used to run the web based IDE on the local desktop or assist an Apache instalallation for fast server tasks behind a firewall, e.g. as a database connector or other dedicated intelligent HTTTP server.



Lutz

cormullion

#3
Quote from: "newdep"You know what I always thought was funny in newlisp, that "pi" is missing ;-)

(Its there of course (div 22 7)..)


If you have 'bc' on your machine:



(replace "" (join (exec "echo 'scale=300; 4 * a(1)' | bc -ql")) "")
"3.141592653589793238462643383279502884197169399375105820974944592307816406286208998628034825342117067982148086513282306647093844609550582231725359408128481117450284102701938521105559644622948954930381964428810975665933446128475648233786783165271201909145648566923460348610454326648213393607260249141272"



Does this look nice in your browser?! ;-)

Lutz

#4
... beautiful (if you have one of those 40 inch screens :) ), for a nice application of PI and demonstration of loading code remotely via HTTP try the following:



Fire up newlisp-tk, and in the console window type/paste in the following:



(load "http://www.intricatevisions.com/source/newlisp/graph-draw.lsp">http://www.intricatevisions.com/source/ ... h-draw.lsp">http://www.intricatevisions.com/source/newlisp/graph-draw.lsp")



one of Fanda's nice newlisp-tk programs.



Also, for more math constants look into Jeremy's Math page here:



http://newlisp-on-noodles.org/wiki/index.php/Math">http://newlisp-on-noodles.org/wiki/index.php/Math



Lutz

HPW

#5
When testing 9.0.4 with my neobook demo app I noticed that my turtle-demo was broken.

Fortunatly it turns out to be a name conflict with the new (round ..) function, which I had used there.
Hans-Peter

HPW

#6
I noticed that the newLISP files are dated on 01.12.2006 (so coming from the future!)

;-)



PS: The new functions are not documented yet, so no direct jump.
Hans-Peter