Giter VIP home page Giter VIP logo

gsl-shell's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

gsl-shell's Issues

Comments for 2.2.0-rc1

  • Merge in the fix for the short function syntax (gsl-shell segfaults since goto/labels have been implemented).
  • Demos ode6, sf1 and sf2 do not open a window from the command line interface.

'Use' imports to the wrong level when called from a co-routine

Francesco,

The following fails with GSL-shell 2.3.1:

coroutine.resume(coroutine.create(function()
  use 'math'
  print(pi)
end))

pi is printed as nil. I think the use() function has to be modified to use level 2 instead of 3:

function use(...)
   local level = debug.getinfo(2, "") and 2 or 0 --<-- use level 2
   local env = new_env()
   env.use(...)
   setfenv(level, env)
end

This affects debugging in ZeroBrane Studio as it's using coroutines to run debugging (for reference: pkulchenko/ZeroBraneStudio#239).

README.md links broken

In the Build Instructions there are 3 links. None of them works.
Each one opens a page with text "Non-Image content-type returned".

ode-vec branch integration

I took the liberty of rebasing your ode-vec branch on the master because I needed the RK8PD integrator recently (in vector form). Do you still intend to integrate this feature? If there are any known issues with it I can try to fix them and clean it up a little.

GSL as a LuaJIT module

Hi Franco,

I was interested in 2012 and I am still interested in being able to use gsl as a module that can be loaded in LuaJIT (with require"gsl")
Is this now posible?
I saw lgsl but seems abandoned

Best Regards
Victor Bombi

"Cannot find a suitable truetype font" error

Hello,

Running gsl-shell failed with "cannot find a suitable truetype font". (note: this is a very confusing error message)
Looking around, I found that gsl-shell look for fonts in several hard coded paths listed in
agg-plot/support_x11.cpp.

const char *ttf_names[] = {
    "ubuntu-font-family/Ubuntu-R.ttf",
    "freefont/FreeSans.ttf", "freefont-ttf/FreeSans.ttf", "FreeSans.ttf",
    "ttf-dejavu/DejaVuSans.ttf", "dejavu/DejaVuSans.ttf", "DejaVuSans.ttf",
    "liberation/LiberationSans-Regular.ttf", 0};
const char *ttf_system_dir[] = {"/usr/share/fonts/truetype", "/usr/share/fonts", "/usr/share/fonts/TTF", 0};

I would suggest using fontconfig font discovery methods instead of hardcoding the paths directly.
In my case was that I have the fonts, but they are in a different path than what was hardcoded.
Other approach is by allowing runtime configuration for the font path.

This is not really severe, but causes confusion, since the INSTALL did not mention the need to have the fonts on that exact paths.

Regards,

mail list not working

I did post to [email protected] after subscribing and checked at http://lists.nongnu.org/archive/html/gsl-shell-info/ but there was not my email. It was:

Should I write ffi interface for using gsl_poly_complex_solve or is there
something better to do?

Is there any documentation about templates?

In the meanwhile I did

'''
local ffi = require 'ffi'
local gsl = require 'gsl'
ffi.cdef[[
typedef long gsl_poly_complex_workspace;
typedef double* gsl_complex_packed_ptr;
gsl_poly_complex_workspace * gsl_poly_complex_workspace_alloc (size_t n);
void gsl_poly_complex_workspace_free (gsl_poly_complex_workspace * w);
int gsl_poly_complex_solve (const double * a, size_t n, gsl_poly_complex_workspace * w, gsl_complex_packed_ptr z);
]]

function solvePoly(t)
local n = #t
local coefs = ffi.new("double[?]", n)
local roots = ffi.new("double[?]", 2_(n-1))
for i=1,n do coefs[i-1]=t[i] end
local ws = gsl.gsl_poly_complex_workspace_alloc (n)
if gsl.GSL_SUCCESS~=gsl.gsl_poly_complex_solve (coefs,n,ws, roots) then
print("no convergence")
end
gsl.gsl_poly_complex_workspace_free(ws)
local res = {}
for i=1,n-1 do
res[i]=complex.new(roots[2_(i-1)],roots[2*(i-1)+1])
end
return res
end
'''

but I am afraid that if it was not in gsl-shell it is because there is a better alternative (roots.lua??) and is inacurate in multiple roots.
I still dont undestand templates.

I am also working in a library for digital filter design and I dont know if there is any interest in
incorporating the library

Best Regards
Victor Bombi

OSX make error

Mac OSX sierra & High sierra is make Error.
How can I make it?

I used LuaJIT (lujit 2.1.0 beta3)

install is brew.

brew install --with-gc64 --devel luajit
brew install gsl
brew cask install xquartz
brew install fox
git clone https://github.com/franko/gsl-shell
cd gsl-shell
make

error

$ make
make: dpkg-architecture: Command not found
Compiling completion.c
completion.c:7:10: fatal error: 'readline.h' file not found
#include <readline.h>
         ^~~~~~~~~~~~
1 error generated.
make: *** [completion.o] Error 1

readline is brew install

brew list |grep readline
readline

I will try and report any necessary information and survey methods if instructed.

best regards.

Using pre-compiled windows binary libraries with gsl-shell

Hi,

I have been looking for a good scripting language: found Lua. Then I looked for good extensions: found gsl-shell. As a windows user gsl-shell-gui is very nice; it's great to paste code from your help pages and see it run!

My question: how can I use other Luajit compiled libraries (e.g. https://code.google.com/p/lua-files/) in scripts run by gsl-shell.exe or gsl-shell-gui.exe. I have tried putting examples in the gsl-shell folder (as indicated by the default cpath) and "requiring" them - they fail to load.

Like many "users" I do not want to invest time in learning to compile anything from source code.

I would like to be sure the environment is extendable before investing lots of time in gsl-shell.

Kind Regards

Gavin

GSL-Shell-GUI Bug

Hi Francesco,

I have been repeatedly restarting GSL-Shell-GUI with CTRL-R and eventually this causes a loss of alphanumeric input - I can't type any commands. Interestingly the arrow keys and enter keys continue to work.

It's a minor problem, but something is broken.

Kind Regards

Gavin

linfit for complex

I have written a routine for fiting rational functions. Now I am trying to do it with complex rational function (with real coefs for digital filter design as invfreqz in matlab) but I see that linfit works only with real matrix. What should be changed for making it work with complex matrixes?

Best Regards
Victor Bombi

Livecoding fun

Hi Francesco,

not a bug at all, but try gsl shell from zerobrane studio with a script like this and live coding. It is incredibly powerful and fun to use. I hope to create some plugins soon for zbs to provide more control of graphing during live coding with help from Paul. Thinking of clone graph, etc.

Regards,

Marcel

-- create plot area
if p==nil then
p = graph.plot('radial scatter kernel (red) and radial integral (blue)')
p:show()
end

function kernel()
return |r| r_(math.exp(-3.45_r^2)+math.exp(-0.033*r^2)/25.5)
end

local fk = kernel()
local fi = function(t) return num.integ(fk, 0, t) end
local fi100= fi(100)

local ln1 = graph.fxline(|t| fk(t)/fi100, 0, 12)
local ln2 = graph.fxline(|t| 0.73+0.26*fi(t)/fi100), 0, 12, 100)

p:clear()
p:addline(ln1, 'red')
p:addline(ln2, 'blue')

Mavericks build -lsupc++

Hey Francesco,

on the new Mavericks (I cannot say anything about other OSX versions) I could not build the shell unless I deleted all -lsupc++ library references in the Makefile and makedefs.

I didn´t find much about the relevance of this gcc support library but it seems to work without it quite well. Maybe this is the case on all OSX versions and additional 'ifs' might catch that error in the future.

Ben

gsl-shell-gui.exe - breaks if mouse used above command line

Hi,

Returning to update my installation of GSL-Shell for Windows ( gsl-shell-windows-x86.zip
4.29 MB 15 Apr 2022 ) the GUI shell is not working as expected.

  • I can run commands and plot demo graphs.
  • If I use my mouse to click or select anywhere above the active command line the application becomes unusable.
  • The escape key does not return control to the active command line as discussed in issue #16 .

I have tested on Windows 8.1 and windows 10.

Kind Regards Gavin Holt

Does gsl-shell come with the full gsl for Windows

Hello,

Does gsl-shell for Windows come with the full gnu scientific library for accessing functions not yet implemented in the shell itself, but could still be accessed through the FFI (such as BDF method for ODEs) ?

I'm asking because there doesn't seem to be an easy binaries install for gsl for Windows. I'm not much of a computer science guy so I'm not too confident building the gsl myself. Accessing the gsl through the FFI doesn't look too bad thanks to the example in the manual. This would also be a way users could gain indirect access to gsl functions that haven't been fully implemented yet (such as many of the ODE solvers) until they eventually are integrated into the shell.

Thank you,
Carl

matrix_complex in eigen.lua

Frankly, idk whether I use the newest version, but to avoid an error msg using e.g. eigen.herm, I replaced matrix_complex.copy by matrix.copy in eigen.lua (seems to work).

thx for this great piece of software.
btw, I'd also vote for that parts of gsl-shell are (useable as) LuaJIT2 modules, but it's just a Lua ecosystem thing.

Regards

HEAD is pointing to an old branch

If we follow these simples steps:

$ git clone git://github.com/franko/gsl-shell.git
$ git branch -a

 * algebra-mod
   remotes/origin/HEAD -> origin/algebra-mod

We end up on the "default" branch which is remotes/origin/algebra-mod instead of remotes/origin/master. It would be easier for other users if you set HEAD back to master.

gsl-shell and zerobrane?

Is it still possible to use the most recent gsl-shell in zerobrane on macos? I was looking for a plotting environment for geometry algorithms and visualization.

GDT as a lua library

Hi,

I have only recently discovered GSL-Shell. Thank you for your great work.

I'm very interested in the GDT module in GSL-Shell as I work with tabular data quite frequently.

Currently, I have LuaJIT embedded in my workflow. I have a configuration lua script that parses and pre-processes the input tabular data before passing it to the C++ program.

How can I use GDT module in this case? I hope to be able to use gdt = require('gdt').

LuaJIT 2.1?

Do you plan to migrate to the 2.1 branch? It is faster than v2.0.x, and AFAIK stable enough to be used in production at CloudFlare.

GSL-Shell_GUI: Enhancement

Hi Francesco,

It would be really convenient if the ESC key would bring the cursor back to the active command line and scroll down to display the prompt. If the cursor is at the command line it would be nice if ESC would clear the line.

As a windows user the GUI is so much better that a DOS box that doesn't understand CRTL-C CRTL-X CTRL-V - many thanks for your work providing a stylish usable console.

Kind Regards

Gavin

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.