Answered
elec_bipolar_callback
You can use the |edit| command as follows in the Command Window and you'll see the code come up in the MATLAB editor. edit ...

10 years ago | 0

| accepted

Answered
I want to change a variable in SIMULINK using m-file.Suppose for a certain simulation time t=0 to 5,I want V=10 and for t=5 to 10, V=20. How to write in m-file
It might be doable with callbacks and such, but I'd recommend going simple if possible. The easiest thing would be converting...

10 years ago | 0

Answered
How do I increase simscape simulation accuracy?
The first thing I would do is make sure the local solver is turned off in your Solver Configuration block. If you want the most ...

10 years ago | 0

| accepted

Answered
How can Simdriveline's 'Vehicle Body' component distinguish between front and rear wheels?
You need to use the *NR* and *NF* ports in the Vehicle Body block and connect them to the *N* ports of the tire blocks you want ...

10 years ago | 0

| accepted

Answered
How can I simulate a load with DC comsumption in SimPowerSystem?
First off, SimPowerSystems Specialized Technology has the blocks (I think) you need: # <http://www.mathworks.com/help/physmod...

10 years ago | 1

| accepted

Answered
Edit Mask for Simscape Block
You cannot modify the mask directly as you are suggesting. There are 2 ways I can think of to get around this: # Create a sep...

10 years ago | 1

| accepted

Answered
How to Stop Simulation in Test Sequence Block
You can use the |error| function inside the step you want. This will stop the simulation and output a custom error message. ...

10 years ago | 0

Answered
Simhydraulics: Pressure distribution over the entire circuit
If you know the exact time range you want, you can tell Simulink to log data only in that range. For example, suppose you alread...

10 years ago | 0

| accepted

Answered
Is it possible to visualise SimMechanics 2nd generation model without using Mechanics explorer?
That should be possible. If you go to the Model Configuration Parameters, you can turn off the Mechanics Explorer. Then, you can...

10 years ago | 0

| accepted

Answered
C code generation using Flow Graph of StateFlow(Simulink)
I am sure this depends on many factors. The main one, I think, would be optimizations to make the code more efficient. Withou...

10 years ago | 0

Answered
how to give the parameter value in three phase induction motor design??
"Power Systems Blockset" is the old name for SimPowerSystems. If you have that tool, you can find the machine models here: ht...

10 years ago | 0

Answered
can anyone tell me the .mdl extension and how does it differ from .slx
The .mdl extension is the older (backwards compatible) Simulink model format. In R2012b, .slx became the default extension, ...

10 years ago | 0

Answered
Bode plot in Matlab
In your <http://www.mathworks.com/matlabcentral/answers/247056-how-do-i-write-the-transferfunksjon-in-matlab previous question>,...

10 years ago | 0

Answered
How do I access simulation end time of Simulink model from within a MATLAB function block?
I think the easiest thing to do is define a variable in MATLAB base workspace -- let's call it |tEnd|. Then, set your simulat...

10 years ago | 1

| accepted

Answered
How to get rid of "SVN" heading in "Current Folder"
You should be able to turn this off in the MATLAB preferences, as shown here: http://www.mathworks.com/help/matlab/matlab_env...

10 years ago | 2

Answered
Why is a triggered subsystem activated on the second rising edge
It's because of the Unit Delay block "delaying" the output by 1 trigger. If you move the Unit Delay block to the lower branc...

10 years ago | 0

| accepted

Answered
Coulomb friction in simmechanics gen 2
Would it be sufficient to take advantage of the Simscape friction blocks as shown in this Answer? http://www.mathworks.com/ma...

10 years ago | 0

Answered
How can I determine which blocksets my Simulink model uses?
For Simulink, there is |dependencies.toolboxDependencyAnalysis|. http://www.mathworks.com/help/simulink/slref/dependencies.to...

10 years ago | 0

| accepted

Answered
How do I write the transferfunksjon in Matlab
If you have Control Systems Toolbox, the |tf| (transfer function) or |zpk| (zero-pole-gain) functions will be very helpful. Sinc...

10 years ago | 0

Answered
Adding elements by elements
So... what is the question? Your code runs fine. You should really describe your problem instead of asking everyone to "please c...

10 years ago | 0

Answered
Clarification required for through and across variable. What is basis for declaring force as through variable and velocity as across variable?
I like to think about it this way. Assuming no friction or other losses: * If you push a block with force from your arm, all ...

10 years ago | 2

| accepted

Answered
Physical explanation: Smooth absolute value of mass flow rate for energy flow rate calculations (Simscape 2P domain)
For the first question, the closest thing I found was in the "Full Flux Scheme" section of the <http://www.mathworks.com/help/re...

10 years ago | 1

| accepted

Answered
How can i do object oriented programming in Simulink?
If you want object-oriented programming in Simulink, I would recommend going the route of creating System objects. These can be...

10 years ago | 1

| accepted

Answered
Speeding up Simulink simlation time.
<http://www.mathworks.com/company/newsletters/articles/improving-simulation-performance-in-simulink.html This article> covers a ...

10 years ago | 0

Answered
Simulink block for plotting output (on Y axis) with input (on X-axis)?
There is an <http://www.mathworks.com/help/simulink/slref/xygraph.html X-Y Graph> block in Simulink. For this, you'd have to con...

10 years ago | 0

| accepted

Answered
How can I fix this "The "FixedStepDiscrete" solver cannot be used to simulate block diagram,because it contains continuous states"
You should replace any continuous-time blocks with states (e.g. Integrator, Transfer Fcn, PID Controller, etc.) with their discr...

10 years ago | 3

| accepted

Answered
How to set "show masked subsystem" off as default?
You can configure this in the Simulink Preferences. The first section, "Display Defaults for New Models" has a "Show Masked ...

10 years ago | 0

| accepted

Answered
how to access a simulink's block ouput values ?
I would look into this Answer: http://www.mathworks.com/matlabcentral/answers/96425-how-can-i-update-a-gui-with-values-from-m...

10 years ago | 1

| accepted

Answered
Running a stateflow block as a subsystem?
Since both Stateflow charts are being driven by the same clock, I would suggest combining them into a single chart. You can have...

10 years ago | 0

| accepted

Answered
Creating "referenced model" that contains physical modeling connection ports
You're right that model reference boundaries don't work with physical model blocks. The reason your workaround makes the simulat...

10 years ago | 0

| accepted

Load more