This Python code only works with function that crossing x-axis.
The idea is we started from x=0 and walking to the positive direction and evaluating f(x) as we walk.
If there's change of the sign of f(x) from + to -, or vice versa, there must be a root in that area.
We began to surround it to find the-x that correspond to f(x)=0. That x value is the root.
After the root is found, we began to walk along x-axis again until found any sign change of f(x), or until x limit set on code.
Friday, April 21, 2017
Thursday, April 20, 2017
Manual Gauss Elimination on 3x3 Matrices in Delphi
I use this code in order to find its pattern.
Yes, there is many Gauss code out there. I plan to write it on next post about it. The dynamic Gauss Elimination code that could be implemented to any size of matrices.
But for now, let just settle on this.
https://youtu.be/csiFpdsrzzQ
Yes, there is many Gauss code out there. I plan to write it on next post about it. The dynamic Gauss Elimination code that could be implemented to any size of matrices.
But for now, let just settle on this.
https://youtu.be/csiFpdsrzzQ
Wednesday, April 19, 2017
Lagrange Polynomial Interpolation on Python.
It's a whole a lot easier than Newton's divided differences interpolation polynomial, because there is no divided difference part that need a recursive function.
Tuesday, April 18, 2017
Dewa.
Tentang religi, sepertinya @pitoyoamrih memang sangat berhati-hati sekali. Beliau menempatkan setting cerita bukan di dunia nyata kita (yang sudah penuh kontroversi religi), namun di dunia tersendiri yang bernama dunia wayang, :)
Pun demikian, toh dewa-dewa di dunia wayang @pitoyoamrih tidak bertindak sebagai Tuhan, namun sebagai makhluk dengan tugas dan kemampuan khusus.
Bahkan di banyak cerita, para dewa ini cenderung bertindak seperti oknum pejabat yang korup dan/atau sewenang-wenang sehingga perlu dilabrak oleh rakyatnya, :)
Sukati dan Penyukilan.
Akhirnya saya tahu yang ini. Lagi-lagi @PitoyoAmrih menambal lubang di kamus wayang saya. :)
Kali ini tentang nama alias.
Saya sudah cukup akrab dengan nama alternatif di dunia wayang. Bahkan dengan beberapa gagrak yang berbeda.
Permadi, Pinten, Tangsen, Yayi Suni, kakang Suman, Bawor, Jaka Pitana, Suyudana, Jaladara, Kakrasana,...
Monday, April 17, 2017
Tak Terduga dan Menyenangkan.
Masih mbulet di buku @PitoyoAmrih, dengan gaya cerita beliau yang seperti orang ngobrol santai diantara teman.
Awalnya, saat memegang buku "Pertempuran Dua Pemanah. Arjuna-Karna" untuk pertama kali, saya sudah penuh dengan antisipasi bahwa ini bukan hanya tentang pertempuran dua orang itu.
Seperti di "Wisanggeni Membakar Api" atau "Antareja dan Antasena", saya menduga bahwa Pitoyo Amrih pasti akan menceritakan masa kecil Karna dan Permadi, yang memang dilakukan oleh beliau.
Namun ada tokoh "utama" lagi yang menyedot fokus saya yang disuguhkan beliau, ada pemanah lain. Adalah Ekalaya, Raden Bambang Ekalaya, raja Paranggelung, yang ternyata juga pemanah hebat. Yang sebelumnya hanya saya kenal sepintas lalu sebagai raja bergelar Prabu Palgunadi. Itupun, di otak saya, selalu tak lepas dari nama lain yang harus selalu hadir di imajinasi saya, meskipun saya tak tahu ada apa dengan dua nama tersebut. Nama itu adalah Palguna-Palgunadi.
Hal lain yang saya perhatikan adalah gaya bercerita Pitoyo Amrih di novel ini. Tadi sudah saya sebut bahwa beliau bercerita seperti ngobrol santai diantara teman. Ngobrol santai, tak ada jadwal, tak ada target, tapi tetap bikin nyaman. Bukankah itu tujuan santai diantara sahabat?
Ngobrol santai bagaimana? Yeah, saat kita ngobrol, saat kita sedang bicara tentang suatu topik, adakalanya topik itu merembet ke topik yang lain, yang juga merembet ke topik yang lainnya lagi, dan lainnya lagi, yang kemudian dengan santainya, mungkin sambil menyeruput kopi hangat yang tinggal separuh, kembali ke topik awal dengan mulus tanpa terkesan dipaksakan.
Hal itu terjadi di buku ini, betapa cerita masa kecil Karna tiba-tiba bergeser ke sayembara Kunti, geger Kangsadewa, dan kembali ke Karna lagi.
Saat ngobrol, kadangkala urutan kronologis juga sering tak beraturan. Kita bicara tentang kejadian hari ini yang merupakan akibat dari kejadian dua minggu yang lalu, yang direncanakan seminggu sebelum itu, berakibat dua minggu kemudian, dan akan kita lihat apakah besok ada akibat dari kejadian yang sekarang.
Hal yang sama saya kenali di buku ini saat tiba di bagian Ekalaya, berawal dari Ekalaya yang sudah lusuh, mundur ke Ekalaya saat masih di istana, maju sedikit ke bagian Ekalaya yang ditolak Durna, maju lagi, dan lagi.
Apakah membingungkan? Dari sisi cerita, ini justru menarik karena kita tahu sebuah akibat dulu, sehingga penasaran apa sebabnya, yang kemudian dijawab dengan elegant oleh Pitoyo Amrih. Sehingga jalan cerita jadi menarik, misteri atau rasa penasaran selalu jadi bahan bakar cerita yang menarik.
Akan lain halnya misal bagian Bambang Ekalaya diceritakan runtut secara kronologis, tak akan menarik karena kita akan tahu hasil akhirnya, atau mungkin malah tidak tahu sama sekali mau mengarah ke mana. Pitoyo Amrih tahu cara membuat cerita menjadi menarik. :)
Unexpected and Enjoyable.
It's still around @PitoyoAmrih book, with his story style that is like people chatting casually among friends.
Initially, when holding the book "Pertempuran 2 Pemanah. Arjuna-Karna", "Battle of the Two Archers. Arjuna-Karna" for the first time, I was full of anticipation that this was not just about the battle of the two people.
As in "Wisanggeni Membakar Api" or "Antareja and Antasena", I suspect that Pitoyo Amrih will surely tell about Karna and Permadi's childhood, which he did.
But there is another "main" character who appeared in the focus. There are other archers. It was Ekalaya, Raden Bambang Ekalaya, king of Paranggelung, who was also a great archer. Previously, I only knew at a glance as a king, Prabu Palgunadi. And even then, in my brain, it always can't be separated from other names that must always be present in my imagination, even though I don't know what/who the two names are. The name is Palguna-Palgunadi.
Another thing I noticed was the storytelling style of Pitoyo Amrih in this novel. I mentioned earlier that he told stories like casual chatting between friends. Chat casually, no schedule, no targets, but still comfortable. Isn't that a relaxed goal while chatting among friends?
Chat casually what? Yeah, when we talk, when we're talking about a topic, sometimes the topic spreads to other topics, which also spread to another topics, and more, which then casually, maybe while sipping a half cup of warm coffee, return to the original topic smoothly without being forced.
This happened in this book, how the story of Karna's childhood suddenly shifted to the Kunti contest, commotion Kangsadewa, and returned to Karna again.
When we're chatting, sometimes the chronological order is also often irregular. We are talking about what happened today which was the result of the incident two weeks ago, which was planned a week before that, resulting in two weeks later, and we will see if tomorrow there will be a result of what is happening now.
The same thing I recognized in this book when I arrived in the part of Ekalaya, started from Ekalaya who was already worn out, retreated to Ekalaya while still in the palace, advanced slightly to the Ekalaya section which was rejected by Durna, advanced again, and again.
Is it confusing? In terms of the story, this is actually interesting because we know a result first, so we wondered why, which was then answered elegantly by Pitoyo Amrih. So that the storyline becomes interesting, mystery or curiosity is always became a fuel for an interesting story.
It will be different, for example, if Bambang Ekalaya's part is told in chronological order, it will not be interesting because we will know the end result, or maybe we don't know where it'll go at all. Pitoyo Amrih knows how to make stories interesting. :)
Subscribe to:
Posts (Atom)
My sky is high, blue, bright and silent.
Nugroho's (almost like junk) blog
By: Nugroho Adi Pramono
323f
(5)
amp
(1)
android
(12)
apple
(7)
arduino
(18)
art
(1)
assembler
(21)
astina
(4)
ATTiny
(23)
blackberry
(4)
camera
(3)
canon
(2)
cerita
(2)
computer
(106)
crazyness
(11)
debian
(1)
delphi
(39)
diary
(286)
flash
(8)
fortran
(6)
freebsd
(6)
google apps script
(8)
guitar
(2)
HTML5
(10)
IFTTT
(7)
Instagram
(7)
internet
(12)
iOS
(5)
iPad
(6)
iPhone
(5)
java
(1)
javascript
(1)
keynote
(2)
LaTeX
(6)
lazarus
(1)
linux
(29)
lion
(15)
mac
(28)
macbook air
(8)
macbook pro
(3)
macOS
(1)
Math
(3)
mathematica
(1)
maverick
(6)
mazda
(4)
microcontroler
(35)
mountain lion
(2)
music
(37)
netbook
(1)
nugnux
(6)
os x
(36)
php
(1)
Physicist
(29)
Picture
(3)
programming
(189)
Python
(109)
S2
(13)
software
(7)
Soliloquy
(125)
Ubuntu
(5)
unix
(4)
Video
(8)
wayang
(3)
yosemite
(3)