jhass[m] changed the topic of #ruby to: Rules: https://ruby-community.com | Ruby 3.1.2, 3.0.4, 2.7.6: https://www.ruby-lang.org | Paste 4+ lines to: https://gist.github.com | Books: https://goo.gl/wpGhoQ
moldorcoder7 has quit [Ping timeout: 256 seconds]
perdent has joined #ruby
naquad has quit [Read error: Connection reset by peer]
onyx has quit [Read error: Connection reset by peer]
naquad has joined #ruby
markong has quit [Ping timeout: 240 seconds]
Sankalp has quit [Ping timeout: 256 seconds]
Sankalp- has joined #ruby
Sankalp- is now known as Sankalp
abws has quit [Ping timeout: 248 seconds]
novapy has joined #ruby
mixfix41 has quit [Ping timeout: 256 seconds]
ur5us has joined #ruby
s-liao-2000 has joined #ruby
perdent has quit [Quit: Client closed]
ur5us has quit [Ping timeout: 248 seconds]
novapy has quit [Ping timeout: 256 seconds]
cornett is now known as Guest9768
typeof[panda] has quit [Quit: Client closed]
CrazyEddy has quit [Ping timeout: 255 seconds]
Guest26nakilon has joined #ruby
<Guest26nakilon> I use this thing https://github.com/jfelchner/ruby-progressbar/blob/master/lib/ruby-progressbar/refinements/enumerator.rb and couple of other gems in my program that all to the backtrace; I would like to shorten it but I don't want to wrap the code in a huge block with additional indentation so I'm thinking about monkey-patching the outer call,
<Guest26nakilon> i.e. the progressbar
<Guest26nakilon> but I start doing it I get this https://dpaste.org/XhC49/slim -- is it impossible to monkey patch a refinement? or at least not in the way I do it?
<Guest26nakilon> *in couple with, *that all add to the backtrace, *when I start -- sorry for typos
Guest26nakilon has quit [Quit: Client closed]
Rounin has quit [Ping timeout: 246 seconds]
Guest26nakilon has joined #ruby
Al2O3 has quit [Quit: I'm quitting, thanks for all the sharks.]
Ziyan has joined #ruby
John_Ivan has quit [Ping timeout: 276 seconds]
Guest26nakilon has quit [Quit: Client closed]
davidw has quit [Ping timeout: 246 seconds]
szkl has quit [Quit: Connection closed for inactivity]
rvalue has quit [Quit: ZNC - https://znc.in]
rvalue has joined #ruby
gr33n7007h has quit [Read error: Connection reset by peer]
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
gr33n7007h has joined #ruby
dionysus69 has joined #ruby
siery has quit [Ping timeout: 255 seconds]
kazoos1 has joined #ruby
jpn has joined #ruby
CrazyEddy has joined #ruby
jpn has quit [Ping timeout: 246 seconds]
Sankalp has quit [Ping timeout: 248 seconds]
shokohsc has quit [Read error: Connection reset by peer]
kazoos1 has quit [Ping timeout: 256 seconds]
shokohsc has joined #ruby
s-liao-2000 has quit [Quit: Client closed]
Sankalp has joined #ruby
robotmay has quit [Quit: Be excellent to each other]
robotmay has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 246 seconds]
kazoos1 has joined #ruby
_ht has joined #ruby
kazoos1 has quit [Ping timeout: 256 seconds]
jpn has joined #ruby
perdent has joined #ruby
<naquad> leftylink, very cool link, thank you :)
naquad has quit [Remote host closed the connection]
moldorcoder7 has joined #ruby
reset has quit [Quit: reset]
emcb54 has quit [Ping timeout: 240 seconds]
emcb54 has joined #ruby
Ziyan has quit [Quit: Textual IRC Client: www.textualapp.com]
perdent has quit [Quit: Client closed]
Rounin has joined #ruby
tuxcrafter has quit [Quit: Client closed]
markong has joined #ruby
jpn has quit [Ping timeout: 240 seconds]
twosuns has joined #ruby
desnudopenguino1 has joined #ruby
desnudopenguino has quit [Ping timeout: 272 seconds]
desnudopenguino1 is now known as desnudopenguino
jpn has joined #ruby
gr33n7007h has quit [Quit: WeeChat 3.5]
twosuns has quit [Quit: ...]
s-liao-2000 has joined #ruby
gr33n7007h has joined #ruby
protektwar has joined #ruby
protektwar has quit [Changing host]
protektwar has joined #ruby
henninb has quit [Ping timeout: 272 seconds]
jpn has quit [Ping timeout: 244 seconds]
jpn has joined #ruby
Aminda has quit [Quit: Default quit message is difficult to set. If you don't see me returning, ask me? You will find me, if you want to]
jpn has quit [Ping timeout: 246 seconds]
John_Ivan has joined #ruby
Aminda has joined #ruby
gr33n7007h has quit [Quit: WeeChat 3.5]
gr33n7007h has joined #ruby
gr33n7007h has quit [Client Quit]
Ziyan has joined #ruby
finsternis has quit [Ping timeout: 240 seconds]
finsternis has joined #ruby
gr33n7007h has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 246 seconds]
RickHull has joined #ruby
jpn has joined #ruby
jpn has quit [Ping timeout: 248 seconds]
Ziyan_ has joined #ruby
Ziyan has quit [Ping timeout: 248 seconds]
<RickHull> i've got a simple curve defined by around 10 points. it starts on the left with a y-value of zero. it goes up and to the right. then falls back to zero.
<RickHull> i think it's "convex" -- it doesn't swerve sharply
<RickHull> i think I can represent these 10 points with a function/equation instead. mostly for nice interpolation, where I can provide any x-value and get a corresponding y-val
jpn has joined #ruby
<RickHull> some relevant terms: "curve fitting" "polynomial regression" "polynomial interpolation"
<RickHull> not sure on a concrete approach. i think there is a relatively simple equation that describes my set of points. it's not like a scatter plot where a single x-value may have many different y-values (or in a cluster)
<RickHull> a 10th order polynomial equation would be "guaranteed" to hit my 10 points on the nose, I think. but it would be very wiggly as I understand. not a good model. I'm guessing a good model will hit 50% of my points, and the rest will be very close
jpn has quit [Ping timeout: 246 seconds]
<Ziyan_> RickHull : interesting... I haven't done that math in a long time... you trying to plot with Ruby?
<RickHull> i'm simulating a motor with a torque curve. x-axis is RPM. y-axis is torque measurement
aeris has quit [Remote host closed the connection]
<RickHull> in specifying a motor, you can specify the torque curve. provide torque values at various rpms
aeris has joined #ruby
<RickHull> next, we need the torque at any given rpm, say 5109
<RickHull> i'd like to have an equation that describes torque(rpm) given the original 10 points in the spec
<RickHull> right now, i walk up the points and do linear interpolation in the gap
jpn has joined #ruby
naquad has joined #ruby
davidw has joined #ruby
<Ziyan_> RickHull IIRC different interpolation algorithms have their strengths. I would take a few known torque curves and code a number of algorithms and see what makes it best. Given the form of the curve your described, I think Spline interpolation might be what you want. Its been a good 12 years since I worked with curves. Don't quote me on it.
<RickHull> ok, that helps
<RickHull> I found this old thing: https://github.com/v0dro/interpolation
<RickHull> i don't care so much if the curve is a perfect description of reality. already, the curve provided in the form of 10-or-so points is very rough
<RickHull> i don't want a user to have to specify a curve. just 5-15 points and then the curve is generated
<RickHull> it looks to me like "cubic spline" is a good approach, just skimming things
<Ziyan_> RickHull yes, I think so too. give it a try....
<Ziyan_> That GEM is a little old though, hopefully runs on modern Rub, you may need to fork and update some code
<RickHull> probably I'll just lift 10-20 lines, if I go that route
<Ziyan_> Yah, that is simpler
___nick___ has joined #ruby
<Ziyan_> RickHull may I ask what kind of website you are working on. These electric motors.
cocalero has joined #ruby
Aminda has quit [Remote host closed the connection]
Aminda has joined #ruby
Ziyan_ has quit [Ping timeout: 255 seconds]
Ziyan has joined #ruby
<Ziyan> RickHull Nice.... there's your first star 😉
dionysus69 has quit [Ping timeout: 248 seconds]
s-liao-2000 has quit [Quit: Client closed]
georgemp has quit [Quit: ZNC - https://znc.in]
___nick___ has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
georgemp has joined #ruby
georgemp has quit [Remote host closed the connection]
georgemp has joined #ruby
___nick___ has joined #ruby
___nick___ has joined #ruby
georgemp has quit [Client Quit]
xuochi has joined #ruby
xuochi has quit [Client Quit]
georgemp has joined #ruby
aeris has quit [Remote host closed the connection]
aeris has joined #ruby
wand has quit [Ping timeout: 240 seconds]
<RickHull> ha, thanks
cocalero_ has joined #ruby
cocalero has quit [Ping timeout: 248 seconds]
cocalero_ is now known as cocalero
<RickHull> i'm trying to build mruby, getting > undefined reference to symbol 'fgetc@@GLIBC_2.2.5'
markong has quit [Ping timeout: 256 seconds]
cocalero has quit [Quit: Going offline, see ya! (www.adiirc.com)]
wand has joined #ruby
reset has joined #ruby
Ziyan has quit [Quit: Textual IRC Client: www.textualapp.com]
siery has joined #ruby
<RickHull> roughly, LD doesn't know about symbols from glibc?
<RickHull> this is on nixos btw
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #ruby
___nick___ has quit [Ping timeout: 248 seconds]
_ht has quit [Remote host closed the connection]
protektwar has quit [Ping timeout: 248 seconds]
Al2O3 has joined #ruby
naquad has quit [Remote host closed the connection]
ur5us has joined #ruby
mixfix41 has joined #ruby
markong has joined #ruby
e2- has quit [Quit: Stable ZNC provider #bnc4you]
RickHull has quit [Ping timeout: 246 seconds]
e2 has joined #ruby
jpn has quit [Ping timeout: 256 seconds]
s-liao-2000 has joined #ruby
dionysus69 has joined #ruby
RickHull has joined #ruby