Science topic
Simulink - Science topic
Simulink, developed by MathWorks, is a commercial tool for modeling, simulating and analyzing multidomain dynamic systems. Its primary interface is a graphical block diagramming tool and a customizable set of block libraries. It offers tight integration with the rest of the MATLAB environment and can either drive MATLAB or be scripted from it. Simulink is widely used in control theory and digital signal processing for multidomain simulation and Model-Based Design.
Questions related to Simulink
Hi,
I want to collect data for 120 Hz in simulink real time simulation to have sample time same as the controller. But i am getting error for sapmle time less than 0.01 and even for 0.01 sample time the result i got had 0.02 sec interval in data points.
Thanks
I have a Simulink model that connected a main utility (AC-grid) with a three-phase load changing from 20kW to 100kW in 5 seconds and I don't know how to build this load in Simulink. Please your help, will be highly appreciated.
Hi, I am looking to link MATLAB to Aspen Adsorption. I know that for Aspen Plus, it is possible to use actxserver(). Does anyone know if the same method can be used for Aspen Adsorption as well?
But i have Aspen Adsorption linking with Excel VBA code is here, if you have any matlab code please share ..
Sub aspenaAdorption()
' Declare variables for the ACM application, document, and simulation
Dim ACMApp As Object
Dim ACMDocument As Object
Dim ACMSimulation As Object
' Create an instance of the ACM application
Set ACMApp = CreateObject("ACM Application")
' Use "ACM Application" for Aspen Custom Modeler
' Use "ADS Application" for Aspen Adsorption
' Make the ACM application visible
ACMApp.Visible = True
' Open the specified simulation document
Set ACMDocument = ACMApp.OpenDocument("C:\Users\user\Desktop\H2_Purification.acmf")
' Set the simulation object to the current simulation in the application
Set ACMSimulation = ACMApp.Simulation
' Set the simulation to run in dynamic mode
ACMSimulation.RunMode = "Dynamic"
' Run the simulation
ACMSimulation.Run (True)
' Check if the simulation was successful and display a message box
If ACMSimulation.Successful Then
MsgBox "Simulation Complete"
Else
MsgBox "Simulation Failed"
End If
' Quit the ACM application
ACMApp.Quit
End Sub
hashtag #aspenAdsorption #Adsorption #AspentechAspenTechnology #MATLAB Coding #optimization #aspen #chemicalengineering Chemical Engineering
I'm new. I know just little use of matlab.
Help me for do this matlab simulink project.
I try to build a three-phase wireless power transmission model and saw this module in an article.
I am using the Fuzzy Controller in MatLab R2017a. But when I execute the controller, it gives an error:
Error in 'model3_FUZZY/Fuzzy_PID_Controller/FuzzyController': Initialization commands cannot be evaluated.
Caused by:
Struct contents reference from a non-struct array object.
The files are also given. Kindly guide me, How do I proceed, and remove this error.
Adaptive Filters are core of the ANC system. They continuously adjusts its filter coefficients to minimize the error signal, effectively generating the anti-noise signal. Common choices include the Least Mean Squares (LMS) or Normalized LMS (NLMS) algorithms implemented using the respective Simulink blocks. However if the Anti-noise algorithm is analog electronic PCB with feedback mechanism, then does there exists a built in block in Simulink audio tool to design this algorithm?
What is the best approach to design an H infinity controller for a linear model of a wind energy conversion system, with the goal of simulating it in Simulink? Any specific methods or tools recommended for implementation?
Hi,
I am trying to implement the TECS core algorithm to my closed-loop 3DoF model of the aircraft in MatLab/Simulink.
The tuning of the innermost loops was accomplished succesfully, but now I am struggling with tuning the gains of the TECS core algoritm. I know that the dynamics of both the two errors must be the same, so the time constant must be the same. The problem is that I don't know how to impose this constraint via MatLab's standard command as systune or looptune.
Do you have any suggestions on how to do that?
Thank you
Hello
In Simulink MATLAB, we have a three-phase microgrid that we want to improve its power quality with the help of a three-phase inverter and adding a proportional-resonance controller to the system. But we don't know how to implement the proportional-resonance controller in the Z domain (discrete time); We have tried many ways and failed; Please advise what are the ways to design the proportional-resonance controller in the discrete time domain?
Thanks
Currently, I have a global variable array and I can also plot it in the calibration window but I want to plot each data sample by a delay of 2.5 mili Seconds which means after one data sample next should be plotted after 2.5 mili Seconds.
and is it possible to do so in CANape Only without external software such as MATLAB-Simulink or Python etc...
Can anyone suggest me or send me the MATLAB/SIMULINK file of optimization techniques based MPPT algorithm for solar photovoltaic systems??
I want to do Open loop analysis of BLDC motor. While doing so, when I want to connect BLDC motor block with 3-phase inverter in Simulink, it don't let me to connect it. This is the desired circuit which I want to connect it with.
You can send me the file at kwadwoagyare0812@gmail.com , thank you
it was available in previous version under (S-Function-Simcoupler) simcoupler provides interface between PSIM and Matlab/Simulink for co-simulation.
I've made a simple simulation on Simulink consisting on a PV panel, dc-dc converter, resistive load and a function block acting as a MPPT running the code for grey wolf algortihm
When I increase the solar radiance, the current from the panel (2nd graph) starts fluctuating. When i decrease the the solar radiance, the voltage from the panel (4th graph) starts to fluctuate. Further more, if the change the value of the load resistor to 100 ohms from 10 ohms, both the current and voltage goes crazy.
I have no idea what is causing this and was hoping someone could point out my mistake. I have attached the pictures below along with the simulink file. I am willing to provide more information if needed.
How do I extract transient stability post-fault response data from IEEE 16 Bus power system Simulink model for classification
I'm running a real-time model with Simulink/dSPACE DS1104. I have to make it first in MATLAB Simulink, compile it to C and download it on PCI( dSPACE 1104).
1- My sample time is 1.6e-5 s and I want to feed an RNN block with 2000 data (32 ms) via Buffer block. But I get an overrun error. I'm wondering what's the maximum available data that the RNN block can receive in this situation and how I can increase it.
2- My alternative solution is to make the problem simpler. Where a Buffer block with 64 data is enough. here the RNN block sample time is (T_r = 64*1.6e-5). but again I'm getting overrun error and I guess T_r is not enough for RNN block operation. If it's the reason how I can give the RNN block more time and skip some data? For example, receive receives data [1:64], calculate them in 9*T_r, skip [65:640] and again receive [641:704]?
I am trying to simulate BTMS based on immersion cooling system by using the software Matlab Simulink but until now I did not get the correct process neither the good results.
What do you think please ? For this type of system , it is oky to use 1D simulation ?
Moreover , if you have any sources that can help me on my simulation ,I will be so gratiful .
Thank you,
Sara
Hello. I am trying to implement space vector pwm control for permanent magnet motor. In my work the permanent magnet motor is represented by two 3d look up table based flux maps. I have generated necessary switching signals for the universal bridge block which works as an inverter. My plan is to measure the three phase voltages with three phase V-I measurement block and then use park transformation to convert the abc voltage to d-q voltage values which after some mathematical operation will be inputs to the look up tables. However, I am facing two issues.
(1) I can not connect the output of the three phase VI measurement to a multiplexer through which I can connect the three phase voltages to the abc to dq0 block (as highlighted in the attached image). Is there any converter block required so that they can be connected?
(2) I need to measure the phase voltages (phase to ground). However, in my model there is ground connection. Will I be able to measure the phase voltage?
Hi everyone,
I want to use the Casadi optimization package for my NLMPC controller in Matlab/Simulink.
I read the examples of https://web.casadi.org/ site, but I can't modify them for my problem.
I want to use Casadi for the tacking problem, so I will have a time-varying cost function and I have time-varying constraints as well.
All the examples which I saw aren't included the time-varying cost function or time-varying constraints.
I would be grateful if anyone can help me.
Regards,
Hossein.
I am trying to simulate the PV module model with varying irradiation (after considering the beam, diffuse and reflected). I have modeled the the PV module using the mathematical equations in Simulink and managed to get the P-V & I-V curves for constant values. But I get error when I input a signal. If anyone know how do this to kindly assist.
I'm trying to understand how the Belbic system works but i'm having some problems. The plant can track my deisred rerence but i can not see any learning dynamic
Hello i hope Ur doin great.
i would like to share with my problem which blocked me 2 weeks. and i need a help. my project was to implement the LQR control of a bidirectional dc-dc converter for EV charging, i have done the averaged mathematical model of my converter and the design of the observer and the LQR control (correctors), when i went to the simulation in MATLAB/SIMULINK I Found that the mathematical model converge to the references but the physical model does not converge i tried everything but i did not succeed, i have based on the file below ?
i really need Ur help.
I share with you the simulink model of the sliding mode control technique applied to a DFIG-based wind power system
Link to download the simulink file: https://fr.mathworks.com/matlabcentral/fileexchange/124140-sliding-mode-dfig-wind-turbine?s_tid=prof_contriblnk
I want to make weak grid in Simulink using PV-Battery Systems and then to apply fuzzy control logic system to stabilize the voltages and frequency of weak grid efficiently.
Suggest me any efficient model and technique to get some results.
hi
looking for an article about EVs simulation in Matlab's Simulink
Hi I have question how can I model and simulate circuit breaker in Matlab/Simulink mentioned in subject with specific trip curve …
Thanks for advices …
Hi all,
In matlab, we are able to find many features in the control system design applications but it always requires specifying the system inputs and outputs to be able to generate its A, B, C, D matrices. However, for an autonomous microgrid, the system has no inputs and outputs which means we only have the A matrix only. How to get the A matrix ? and how could we avoid specifying those inputs/outputs while linearizing the model ?
I trying to design IEEE 9 bus model in MATLAB Simulink. However, after inserting values of all parameters according to the IEEE standard, the load flow analysis is not working. It shows an error with propagation speed. Can anyone help me to solve it?
Example of model predictive control based on MATLAB/Simulink. In operation, 'quadprog' function is not supported by external generated code. How to solve this problem? Or how to replace the function to achieve MPC program generalization, easy to understand students?
The object and its state space equation are known. It is expected to realize a method of MPC generalization that is easy for students to understand, and to realize hardware-in-the-loop experiment in Simulink environment.
My research is based on: OPTIMIZATION APPLICATION ON SMART GRID FOR OPERATIONAL
PLANNING AND MINIMIZATION OF POWER LOSSES ON BOTH TRANSMISSION
AND DISTRIBUTION NETWORKS USING MATLAB/SIMULINK
How can some assist me from the basic concept of MATLAB? Simulink to get started with this work?
I got five angles from the genetic algorithm to eliminate certain harmonics. Now how should I use these angles in Simulink for generating switching pulses? Do you have any resources including SHE PWM simulation details or any demo file?
Dear Colleagues,
I want to ask about the reasons for obtaining always positive magnitude in dB and phase always greater than -180 in Bode plots when checking the stability by linear analysis tool in Simulink and what this indicates about the system stability?
I am grateful in advance.
How to calculate and design LCL filter for harmonic reduction in matlab simulink?
Hello, I have used multiple PID/PI/PD controllers in my model. The controllers are really difficult to tune or autotune individually. I would appreciate it if you could help me find a better way to tune in MATLAB/Simulink instead of using the auto tuning option.
Hello, I need a model to simulate the electrolysis process using solar panels. Can you help me?
Thank you
I am currently working on my undergraduate thesis which involves the "Non-Linear Neural Control of a Quadratic Tank Process with Delays using Internal Model Control". I have obtained the mathematical models for the plant under minimum phase and non-minimum phase operating conditions. The transfer function of the plant is a 2x2 transfer function matrix.
However, as a beginner, I am quite confused about the next step to take towards representing the built models in MATLAB & SIMULINK, obtaining data from the built models in MATLAB&SIMULINK, the algorithms to use to train the neural networks for modeling the plant, and the controller in the IMC structure, and how to validate the performance of the neural network algorithms generally.
I will appreciate any help or pointers to help me resolve my dilemma, Thank you!
Hello everyone,
I am currently working on energy management in micro grids using agents. I have already implemented my testbed under matlab/simulink, and now I am working with jade.
I need please your suggestions concerning the connection between simulink and jade. I had a look at Macsimjx tool, however it requires Jade version 3.6.1, can anyone provide me with a link to download this version? or any other suggestion to help me with the connection?
Thank you very much
What all inputs and outputs have to be fed into the input and output of this block?
I have an input sine signal, an output from quantizer and an output from zero order hold in a sigma delta ADC.
i will train neural network off line with dataset ,the performance is very good, but when i use the neural network block in model Simulink don't give better results, the type of solver and the does affect in the results ? note that the model Simulink works in discrete time
I am working on the analytic signal concept for observing the frequency variation in the faulted phase current waveform in MATLAB/Simulink model. In MATLAB/Simulink model, I have used analytic signal block and hilbert's transform method to calculate the real and imaginary components of the faulted phase current. After that I have used the data of real and imaginary components of the faulted phase current to calculate the magnitude, phase, and instantaneous frequency. When I plotted the curve between the instantaneous frequency variation vs time for the faulted phase current, I observed that the frequency variation is negative in the curve of instantaneous frequency vs time for the faulted phase current. Why it is so ?
I am working on the analytic signal concept for observing the frequency variation in the faulted phase current waveform in MATLAB/Simulink model. In MATLAB/Simulink model, I have used analytic signal block and hilbert's transform method to calculate the real and imaginary components of the faulted phase current. After that I have used the data for real and imaginary components of the faulted phase current to calculate the magnitude, phase, and instantaneous frequency. When I plotted the curve between the instantaneous frequency variation vs time for the faulted phase current, I observed that there are high frequency spikes in the curve. What can be the reason and what is this phenomena called ?
Hi All,
I'm working on a Matlab-Simulink project related to PV arrays. The Simulink model contains more than 50 modules connected in series, due to which the simulation process takes a lot of time to complete.
Any suggestion to increase speed?
Any help is highly appreciated.
I have simulated a DC-DC converter with a switching frequency of 10 kHz. I need to obtain the averaged values of the measured signals like capacitor voltage and inductor current by filtering the switching measurements. I've tried using the Simulink "Mean" block with a frequency of 10kHz, but as can be seen in the following picture, it does not result in the averaged signal, which should be a straight dc signal(the red curve) as the converter is in steady state. Can you provide a reference that introduces a systematic way to obtain the average value of a switching waveform?
How can I make a connection between FPGA and Simulink?
I want to use FPGA-In-the-Loop (FIL) and my purpose is performing altera board DE1-soc and Simulink.
Unfortunately I haven't found a way to do that yet if it's even possible.
Please leave any suggestions.
Best regards
I am trying to model SMA in Simulink (MATLAB). can anyone here help me to model SMA?
A mathematically modeled one. Thanks.
I have created simple QPSK model in Simulink using the different blocks of, QPSK mod and demod, AWGN channel and raised cosine tx and rx filter. Firstly I used the random integer in simulink it works perfectly. But, now I am calling the signal from workspace using the signal from workspace block and I am receiving the 50 % bit error rate. It as giving an error inconsistent sample time does this impact they BER level or not. If anyone face this kind of issue in Simulink, and resolved it please help me.
Thanks
I was wondering if anyone has experince in tranining a neural network in simulink. I tried a couple of methods, they work in offline, however do not work well with the simulink. Any advice is much appreciated. Thank you
I am trying to simulate a Perturb and Observe and Incremental Conductance MPPT algorithm in Simulink for an PV array.
However I am maxing up the PWM duty cycle to maximum possible value of duty cycle (i.e. 85%). If I manually set the duty cycle using pulse generator I get maximum power between 30% to 35% but in my simulation it does directly to 85%.
The same algorithm is working properly on physical hardware but not on Simulink.
The following two blocks cannot be connected in series:
Block 1: 'A_stator: Asynchronous Machine pu Units'
Block 2: 'phase_A: Three-Phase Series RLC Load'
The first block, modeled as a current source, cannot be connected in series with the inductive element of the second block.
Add a high-value resistance in parallel with one of the two block.
I am trying to use hydrogen produced from the Alkaline electrolyzer in production of Green Ammonia. I have researched online and found most of the ammonia synthesis are done in Aspen plus or HYSYS or dwsim or similar like that.
I am trying to make Ammonia synthesis model in MATLAB but I am having problem in here. Originally I am not the chemical engineering student, so I don't know much of dynamic mass and energy balance. Is there a good resource which I can use for modelling Ammonia synthesis in MATLAB?
Alkaline electrolyzer model is made on MATLAB simulink, so I am trying to make Ammonia synthesis model on MATLAB too.
Please help me in here if you know something.
In MATLAB, I'm attempting to transform my model from continuous state space to discrete state space. The error occurred is "Matrix is Singular to working precision." Please, someone assist me.
A =[0 1.0000 0 0;
51.6923 0 0 0.0221;
0 0 0 1.0000;
-51.6923 0 0 -0.5361]
B =[0;
-0.3412;
0;
8.2597]
Q=[1 0 0 0;
0 1 0 0;
0 0 1 0;
0 0 0 1]
C=[1 0 0 0;
0 0 1 0]
D=[0;0]
R=1;
K=lqr(A,B, Q, R)
q1_int=0.01;
q1_dot_int=0;
q2_int=0;
q2_dot_int=0.01;
%converting our continuous state space model to discrete-time
fs=20;
T=1/fs;
Ad=expm(A*T)
Bd=(Ad-eye(4))/A*B
I would like to perform a tolerance analysis of a CLLC topology using matlab simulink. But the main constraint is the simulation speed. It takes almost 20mins to perform one simulation . The switching frequency of the model is 200KHz. The simulation step size is 1e-8. I am currently using the circuit simulation model. i would like to perform some 2000 simulations using monte carlo approach. This can cost me more time. Is there any better solution available?
Can gams works online with matlab simulink so that optimization is done in gams and send online to simulink model ??
- hello every one i Need help for modeling Electric véhicule with Matlab and Simulink using PMSM motor and dc/ac Converter
I want to have a normal distribution of PV or Slack bus voltages in order to calculate the mean and the variance... The results of the simulation always give a constant value for the slack and PV bus as the voltage have to be known and predefined.
Dear respected
I would like to implement Automatic Switch between two PV panel Depending on output voltage (Exactly I mean depending on the shading ) to change connection form series to parallel or from parallel to series .... I implement it hardware by using two relay but in Simulink I can not do it
so how I can implement below image as MATLAB Simulink ?
kindly any one can help ?
hello,
I'm trying to plot dissipated power of suspension damper Vs frequency plot from 2-dof Quarter car model in MATLAB Simulink. I'm attaching the image of plot can any one help me to get this type of plot from 2-dof Quarter car model in MATLAB Simulink. It will be be very helpful to procced my work further and i will be extremely thankful to help me.
I'm also attaching 2-dof Quarter car model in MATLAB Simulink and the article which I'm following to plot (Follow equation (30) and figure 5(A) of the article attached ). Please find the attachments and hope positive response.
Kindly help me.
Anybody Please help me. if anyone having any explanation or solution regarding above mentioned my problem kindly contact me on my mail id 20pmee08@iiitdmj.ac.in.
I m designing a PV plant that is able to supply an off grid community with power. This error occurs when I try to simulate the model. It occurs in a MEAN block in a charge controller that I made, the controller in directly connected to the P & O algorithm.
Reject percentage is the percent of reject flowrate allowed to leave RO or UF membranes,
Reject % = reject flowrate/ feed flowrate x 100% = (feed flowrate - permeate flowrate)/feed flowrate x 100%
By controlling the reject valve, the pressure difference can be controlled to prevent damage to RO/UF membranes.
Dear All,
How can I make Matlab/Simulink exclude inter-harmonics when calculating THD value??, because its FFT tool in powergui block includes inter-harmonics in calculations.