SIMULKADE (Posts about Matlab)http://simulkade.com/enTue, 22 May 2018 13:24:35 GMTNikola (getnikola.com)http://blogs.law.harvard.edu/tech/rssMatlab and Julia -- Part IIhttp://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20II.htmlAA Eftekhari<div><p>In the previous post, I explained how to program the solution procedure of Buckley-Leverett equation in Matlab. Here, I'm trying to move everything to Julia. First, you need to install Julia, and a few important packages. Personally, I prefer the last development version. In Ubuntu-based distributions, you can install it by writing the following lines in the terminal.</p>
<pre class="code literal-block"><span></span>sudo add-apt-repository ppa:staticfloat/julianightlies
sudo add-apt-repository ppa:staticfloat/julia-deps
sudo apt-get update
sudo apt-get install julia
</pre>
<p><a href="http://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20II.html">Read more…</a> (2 min remaining to read)</p></div>JuliaMatlabhttp://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20II.htmlThu, 02 Oct 2014 20:43:27 GMTMatlab and Julia -- Part Ihttp://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20I.htmlAA Eftekhari<div><p>I'm very comfortable with Matlab. It does most of the things that I need to do and I've written so many handy scripts and functions in it that I can barely afford to divorce it. I can easily read my data, which are not so many most of the time, analyze them, plot the results, and export the final figure to a format I prefer. However, I'm going to try and detach myself by learning how I can do all the Matlab stuff in Julia. I've already learned how to work with the arrays, write types, and I almost know all the differences. I'll write a post about it later. Here, I' going to try the root finding and optimization in Julia. Let's star by root finding. Let's say I have a function in Matlab. Most of the time, if it's not a long relation, I write it using <code>@</code>. For instance, consider the fractional flow function:</p>
<p>$$ f_w = \frac {k_{rw}/\mu_w}{k_{rw}/\mu_w+k_{ro}/\mu_o} $$
</p><p><a href="http://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20I.html">Read more…</a> (5 min remaining to read)</p></div>JuliaMatlabhttp://simulkade.com/posts/Matlab%20and%20Julia%20--%20Part%20I.htmlFri, 26 Sep 2014 08:25:07 GMT