Today's guest blogger is Alan Weiss, who writes documentation for Optimization Toolbox™ and other mathematical toolboxes.Table of ContentsCone Programming Discrete Dynamics With Cone... read more >>
...read more >>
Have you ever needed to solve an optimization problem where there were local minima? What strategy do you use to solve it, trying to find the "best" answer? Today I'm going to talk about a simple... read more >>
Have you ever needed to solve an optimization problem where there were local minima? What strategy do you use to solve it, trying to find the "best" answer? Today I'm going to talk about a simple strategy, readily available in the Global Optimization Toolbox.Solve a Simple ProblemOr at least let's try. I have some data and I want to fit a particular form of a curve to it. First let's look at the pharmacokinetic data. Here's the reference: Parameter estimation in nonlinear algebraic models via global optimization. Computers & Chemical Engineering, Volume 22, Supplement 1, 15 March 1998, Pages S213-S220 William R. Esposito, Christodoulos A. Floudas.The data are time vs. concentrationt = [ 3.92, 7.93, 11.89, 23.90, 47.87, 71.91, 93.85, 117.84 ]t = 1×8 3.9200 7.9300 11.8900 23.9000 47.8700 71.9100 93.8500 117.8400 c = [0.163, 0.679, 0.679, 0.388, 0.183, 0.125, 0.086, 0.0624 ]c = 1×8
...read more >>
目录代码槽,很多地方共享文件代码的可复制性和可重用性网站承载MATLAB与其他语言的互操作性资源结论有很多方法阅读更多>>
Table of ContentsLots of Code, Lots of Places Shared Files Code Reproducibility and Reuse Sites that Host MATLAB Interoperability with Other Languages Resources ConclusionsThere are lots of ways to share MATLAB code. Since there are lots more than there used to be, I thought it would be good to review the state as of July 2021.Lots of Code, Lots of PlacesThere are lots of places where you can find shared MATLAB code. My first go-to, after checking that the code I need is not in MATLAB or any of the toolboxes, is to check out the File Exchange.From here, I can filter further, in this case to find contributions for Earth, Ocean, and Atmospheric Sciences.And that's not counting more general files on the File Exchange that could be useful for this
...read more >>
Before the pandemic (actually a couple of years before), as I was trying to find a super easy way to show the power of a pre-trained network in MATLAB, I made this example from my desk in the office.... read more >>
Before the pandemic (actually a couple of years before), as I was trying to find a super easy way to show the power of a pre-trained network in MATLAB, I made this example from my desk in the office. Behind there is a "board" half of which is magnetic and the other half is cloth-covered so I can hang things with pushpins on it.Here's a picture of me standing in front of this board, scowling at my computer screen for some reason.And here's the code I was using. But I am not in my office now so you will see different pictures.First set up my webcamI first set up my webcam, and make sure it's working. You may be pleasantly surprised to learn that your webcam can be used in MATLAB Online.And I import the pretrained network alexnet.w = webcamw = webcam with properties: Name:
...read more >>
A mind-bending tale of adventure. A mildly distasteful yarn.Today's guest blogger is Rob Holt, who works at MathWorks in Natick, Massachusetts.Rob currently serves as the Manager for Biological... read more >>
A mind-bending tale of adventure. A mildly distasteful yarn.Today's guest blogger is Rob Holt, who works at MathWorks in Natick, Massachusetts.Rob currently serves as the Manager for Biological Sciences at MathWorks. He is a coordinator and collaborator for biology, biotech, and pharmaceutical applications. Previously, Rob spent five years as a Senior Scientist at Invicro, a Konica Minolta company, where he designed, implemented, and communicated image analysis algorithms for drug discovery and development. Rob earned his PhD at Dartmouth College, where he focused on molecular cancer imaging through multimodal medical image synthesis. Follow more of Robÿs antics on his Twitterand his LinkedIn. I was trimming my beard last weekend. While my mind was wandering due to the lack of a nearby computational device, I thought "how fast does my beard hair grow?" It was one of those
...read more >>
Today's post is brought to you from Peter Perkins, a member of the MathWorks development team.Having worked on some of MATLAB's time and date functions, people at The MathWorks sometimes ask me... read more >>
今天的帖子是由彼得·帕金斯为您带来的,MathWorks开发团队的一名成员。在使用了MATLAB的一些时间和日期函数后,MathWorks的人有时会问我有关日历和计时的问题。通常是这样的:在1月初(或7月),我在午餐时盯着手机看了一会儿,然后脱口而出,“公告C刚刚发布!明年6月(或12月)没有新的闰秒!”,然后在尴尬的沉默和“不再”之后从以前听过这个的人看来,一个新来的人会说,“闰秒到底是什么?”我不是专家,但我的标准答案是,“所以,地球正在减速。”接下来的故事如下。一路上,我将展示一些对处理时间序列数据有用的时间表和日期时间的用法。目录因此,地球正在减速。。。但是
Today our guest blogger is Lisa Kempler, who works at MathWorks in Natick, Massachusetts. Lisa supports researchers and educators, frequently geoscientists, helping them build and host the tools that... read more >>
...read more >>
In a recent post, I talked about for-loops in MATLAB and how to optimize their use knowing how MATLAB stores arrays in memory. Today I want to talk about getting ready for parallel computation,... read more >>
In a recent post, I talked about for-loops in MATLAB and how to optimize their use knowing how MATLAB stores arrays in memory. Today I want to talk about getting ready for parallel computation, specifically using parallel for-loops, via parfor. En route to creating code suitable for running in parallel, sometimes we take code with a for-loop and simply replace it with a parallel loop, using parfor. That is, if we can't vectorize the code well first. This transformation from for->parfor works really well sometimes, but does not always work, and for very good reasons. For example, you can't simply replace for with parfor if loop iterations are not completely independent. You can find out more conditions here. There is a notable
...read more >>
Have you ever looked at code where you are calling a function with many arguments, many of which are strings, and find it hard to see what's going on? I know I have. And perhaps you too. In release... read more >>
Have you ever looked at code where you are calling a function with many arguments, many of which are strings, and find it hard to see what's going on? I know I have. And perhaps you too. In release R2021a, there is a new feature in the language that can help me out, in addition to the relatively new arguments block which I wrote about here. For making your own argument, you might want to watch this classic video.Make a plot to modifyLet's start by making a plot and annotating it.t = 0:0.1:10;y = sin(2*pi*60*t) + 0.2*randn(size(t));plot(t,y)xlabel("Time (in seconds)")ylabel("Signal (in Voltage)")title("Canonical signal")grid("on")Change the plot via name-value pairs (2020 and before)Now let's say I want to recreate the same plot but with
...read more >>
今天我要欢迎一位客座博主,Mike Croucher,他最近加入了MathWorks作为客户成功工程师,在长期支持学术计算研究之后。万博1manbetxTable of ContentsIntroduction Don't Fear the Looper Changing mod to floor Trying Integer Types for an Integer Algorithm MATLAB as a Repository of Algorithms System Information Your Need for Speed?IntroductionMost of my career has been dedicated to collaborating with scientists and engineers to improve their computational workflows. There are many things that could be done including encouraging the use of version control or unit testing
...read more >>