An open exchange for the MATLAB and Simulink user community
How do you export your syms equation to a new/different .m file to be able to use the equation with parameters.
1
answer
I would like to create a SIMULINK model that basically takes an input, lets say 2.5, and check if this value is between 6.5 to 8.5. Once checked, if below this range, then it must add 1 to the...
0
answer
Hi, I am solving coupled reaction diffusion PDEs of the form: I am using the 'pdepe' function to solve them. I have become aware that there is an 'events' functionality embedded into the 'pdepe' solver that allows the user to trigger an event when a certain event occurs. ...
0
answer
Hi all, I'm working on quite some time to improve the code which I've written for better visualization of A0 mode. In my code everything looks good even I'm able to track the properties of the wave...
0
answer
I'm working on the MATLAB Simulink Power Systems Simulation Onramp, specifically Task 5. I changed the Wye-Connected Load block component structure to Series RL and set the default value to 12∠0° (A) for inductive reactive power, as required. I also used the filter from the previous task to ...
1
answer
Simulink Flightgear 6DoF simulation with full state feedback controller.

This is a simple TCP-based web server in MATLAB using Java sockets. It allows executing MATLAB functions via HTTP requests.

With 2025 well underway, we are taking a moment to reflect on the milestones of MathWorks startup program in 2024. Here's a look by the numbers: In 2024, we worked with over 900 new startups,...

As we celebrate the 30th anniversary of Dynare, we at MathWorks would like to take a moment to reflect on its influence on the global economics community. Developed by Michel Juillard, Dynare has been a cornerstone in computational economics, enabling researchers and policymakers worldwide to model ...

This illustrates how elegant the analysis of a two-port network using MATLAB is.

On 27th February María Elena Gavilán Alfonso and I will be giving an online seminar that has been a while in the making. We'll be covering MATLAB with Jupyter, Visual Studio Code, Python, Git and...
0
reply
Check out the result of "emoji matrix" multiplication below. vector multiply vector: a = ["😁","😁","😁"] b = ["😂"; "😂" "😂"] c = a*b matrix multiply matrix: matrix1 = [ "😀", "😃"; "😄", "😁"] m...
3
replies
In computer vision, pretrained models are often used and adapted to the task at hand by performing transfer learning. Transfer learning involves modifying and retraining a pretrained network with your data. Most pretrained models are trained on large, colorful image datasets like ImageNet. But how ...

You recently bought an electric kettle for your kitchen, and you want to estimate how much it costs to run every month. The kettle operates at 230V and consumes 2000W (or 2kW) when in use. You...
A voltage divider is a simple circuit used to obtain a reduced voltage from a higher voltage source using two resistors in series. The output voltage (Vout) is given by the formula:Where:Vout is...
In an electrical circuit, the current (III) flowing through an LED is determined using Ohm’s Law:Where:I is the current in amperes (A)V is the supply voltage in volts (V)Vf is the forward voltage...
The energy (EEE) stored in an inductor is given by the formula:Where:E is the energy in joules (J)L is the inductance in henrys (H)I is the current in amperes (A)Write a function that takes...
I am looking for a Simulink tutor to help me with Reinforcement Learning Agent integration. If you work for MathWorks, I am willing to pay $30/hr. I am working on a passion project, ready to start ASAP. DM me if you're interested. TUTOR NEEDED!! OFFER $20/hr!!
0
reply
Bitte um Hilfe beim Kauf Wie kann ich eine MATLAB Student Suite Lizenz kaufen, wenn ich keine Kreditkarte habe? Approximate translation: How can I purchase a MATLAB Student Suite license if I don't have a credit card? Request help with purchase
1
reply
So, in my attempt to add a settings feature to my web app, I have managed to add a settings tab with one uicontrol. When it's value is changed, it saves its value to a MAT file. Next, when the app...

In a Battery Management System (BMS), the lifetime of a battery depends on various factors, including the Depth of Discharge (DoD), load profile, and the battery's cycle life. The cycle life of a battery is the number of complete charge-discharge cycles the battery can undergo before its cap...
Mike is spreading some MATLAB Valentines joy over on the MATLAB Blog. Here is MathWorker Jonathan Gale's ode to the Mapping Toolbox and the Bonne spherical projection. What would your caption for...

Almost immediately after the DeepSeek-R1 AI models were made available to the world, people started asking how you can use them in MATLAB. Late last week, Vasileios Papanastasiou, a software test engineer at MathWorks, posted how to do this on LinkedIn and this morning I tried out his instructions f...

This topic is for discussing highlights to the current R2025a Pre-release. R2025a Pre-release highlights One of the changes is the built-in support for Dark Mode and Themes. Personally I find Dark...
64
replies
Try new Beta features to create, visualize, and run pipelines for machine learning workflows.

This curriculum module contains interactive examples that teach fundamental concepts of power electronics.

Back in April last year, I announced the MATLAB extension for Visual Studio Code on The MATLAB Blog and everyone at MathWorks was blown away by its popularity. In less than a year there have been...

Everyone's talking about Large Language Models (LLMs) and a huge number of you are using them too. Here are 4 ways to make use of them in the MathWorks ecosystem right now, no matter what your skill...

During an online meeting with my colleagues in Boston yesterday, some of them were rather startled when their offices started violently shaking for a brief time! We quickly hopped onto BlueSky (Feel free to follow me there) where we saw thousands of messages referring to what everyone suspected was ...

l cann't log in my account of my school in the matlab. when l clicked the log in , there skiped the erros mw-login::No endpoint specified. in the past, the matlab was normally.
1
answer
This model demonstrates an ESS powered by solar which integrates renewable energy sources with an efficient battery storage mechanism

In this blog post we are going to show you how to use the newest MATLAB functions to: Import models from TensorFlow and PyTorch into MATLAB Export models from MATLAB to TensorFlow and PyTorch This...

In the past two years, large language models have brought us significant changes, leading to the emergence of programming tools such as GitHub Copilot, Tabnine, Kite, CodeGPT, Replit, Cursor, and many others. Most of these tools support code writing by providing auto-completion, prompts, and sugg...
8
replies
Vehicle templates with multibody suspension and electric powertrain sized for Formula Student competitions.

You've probably heard about the DeepSeek AI models by now. Did you know you can run them on your own machine (assuming its powerful enough) and interact with them on MATLAB? In my latest blog post, I...
2
replies
Hi everyone The R2025a pre-release is now available to licensed users. I highly encourage you to download, give it a try and give us some feedback. The first thing I tried was switching to Dark mode. Here's the magic s = settings; s.matlab.appearance.MATLABTheme.PersonalValu...
6
replies
Remove the row that contain the max value in the matrix?If you like the problem, please like it :) %%x = [1 2 3 4 5 6 ...
Hello, I have a plot consisting of "square-ish" TTL pulses and I want to be able to 1: Extract the data thats in the "Zoomed" XLim, and then 2: Find the x-location of each rising edge at a certain...
1
answer
Hello, I have been encountering several times a day for a few weeks an error when updating my data stored on Thingspeak (computerized hive parameters). The return code of my Arduinos is 211! But I...
7
answers
I have matrices A (m by v) and B (v by n). I also have a logical matrix L (m by n). I am interested in, as efficiently as possible, calculating only the values in A * B that correspond to logical...
2
answers
Delete rows with specific properites as following:Find rows that have a negative value in any element of the row and delete it.Check if the last element of the row is equal of bigger than 24 and...
I'm doing optimization using fmincon. I used ObjectiveLimit to terminate the optimization when the size of the objective function is less than 0.2, As I was writing the code, it seems that if the nonlinear constraints are satisfied, the termination condition is also satisfied. However, when ...
1
answer
Explore Community Areas
Ask & Answer questions about MATLAB & Simulink!
Download or contribute user-submitted code!
Solve problem groups, learn MATLAB & earn badges!
Get the inside view on MATLAB and Simulink!
Connect with fellow users!
Use AI to generate initial draft MATLAB code, and answer questions!