Memory function in Control and Simulation loop - ODE solver problem

Hello,
I am currectly using the control & simulation loop to simulate the behaviour of what is essentially a spring-damper-mass system. In the process the change in time (dt) is being used to integrate an arbitrary value. I am using a built in memory function to store the time, to calculate the time change (dt).
The simulation is rather complex, due to the necessary accuracy needed, not all the ODE solvers can handle it. Currently I am using Adams-Moulton method, this works fine for the simulation. However it cannot detect the change in time, the change is constantly zero. This problem worked it self out by using another ODE solver, but then the simulation was rather messed up (even when I tuned the step sizes and tolerances). So I am quite confident that Adams-Moulton is one of the best suited ODE solver for the problem at hand.
Is there another way to store the previous time and use it calculate the time difference, than using the memory function? Has anyone experienced such problems before?
I have been doing alot of error searching using the probe, but I am quite sure that there is a problem with the ODE solver and the memory function. See picture below, showing in basic how the change in time is being calculated.
I am rather new to LabVIEW, so if there could be something else I have missed I will be glad to hear it.
PS! I have tuned the minimum step size/relative and absolute tolerances for the Adams-Moulton to simulate the behaviour of the system correctly.
Solved!
Go to Solution.

Hi Willy,
I am sorry, I can not upload the VI some of the content is confidential. I have attached a larger picture of the section were the change in volume and time is calculated, dV and dt. Also I have marked the two memory functions used. Hopefully this can help.
My parameters:
- ODE solver Adams-Moulton
- Relative tolerance      1e-8
- Absolute tolerance     1e-7
- Minimum step size     0,0005
- Maximum step size    0,01
- Initial step size           0,01
- Auto discrete time      On
- Decimation                 0
- Synz loop to timing source off
Attachments:
06-05-2014 21-20-00.png ‏52 KB

Similar Messages

  • How to use Fuzzy Logic Controller for transfer function in labview control and simulation loop?

    I am facing problem with fuzzy PD logic controller for transfer function in control and simulation loop.
    Plz Help me in this regard...................
    i have attache snapshot of my program
    Attachments:
    fuzzy in simulation loop.JPG ‏52 KB

    Hi Sankhadip,
    Sorry for the late response. I was looking at your code and
    I noticed that the graph scale does not start from zero. That might be the
    reason why you don't see the transient in the simulation. To change the scales
    simply double click on the lower limit and set it to zero. If this is not the
    expected results, can you please post the expected results, so we can see what are the
    differences between the results . Also, you might be using different
    solvers, and that gives different results as well.    
    Thanks and have a great day.
    Esmail Hamdan | Applications Engineering | National
    Instruments

  • Synchronize Control and Simulation loops

    When simulating control systems with LV Control and Simulation loops, I often have multiple loops running at different rates. For example, I have a PWM loop running at 20 kHz, a data acquisition loop running at 100 kHz, and a control loop running at 10 kHz. How can I synchronize all of these loops so that they stay on the same time base? Obviously the master time base will need to be at least as fast as the fastest simulation loop.
    I've tried synchronizing all loops to the 1 kHz clock (I'm running on Windows), but each loop runs one period per clock tick (e.g. my 20 kHz loop counts up 50us per clock tick, my 100 kHz loop counts up 10us per clock tick, etc). I need all of the loops to be synchronized to one master time base so the simulation time is identical in each loop, but each loop will be executed at a different rate.
    Any thoughts?
    Solved!
    Go to Solution.

    Hello,
    A quick suggestion - why can't you run all three systems in a single simulation loop, but have different sample rates for the blocks for each system ?
    Is your system entirely digital, or a mixture of continuous and digital - it may simplify things if you can convert everything to discrete time.
    Hope this helps,
    Andy Clegg
    Consultant Control Engineer
    www-isc-ltd.com

  • Resetting Integrator in Control and Simulation Loop

    Hello,
    I am trying to run a real-time simulation in Labview 14. I have prepared front panel controls and data flow such that I can reset the simulation to some preset initialization values upon clicking a button. However, I am not able to figure out how to reset the integrator in the control and simulation loop. Even after reinitialization of all the values, the integrators will overwrite the initialization values with whatever they were holding. Please help me find a way out.
    Thanks

    Please share what code you have so that we can see what you've tried and understand exactly what you're trying to do.

  • Simulation Loop ODE Solver

    I keep getting Error 2324: Labview Simulation Module: The ODE solver cannot meet the error tolerance using the minimum step size. I've broken my code down and my signal multiplication function seems to be the cause. If I don't multiply things it works fine. If I do, I get the error. Any ideas?
    Thanks,
    Brian
    Solved!
    Go to Solution.
    Attachments:
    Signal Multiplication.JPG ‏46 KB

    Brian,
    The Simulation Loop has some parameters that needed to be changed. In general, you can try to reduce the stepsize (double-click on the terminal on the left of the Simulation Loop) and change the minimal step size. Also, it is worth to change the relative and absolute tolerance to relax the values. If you increase, you can have some results.
    Additional to that, in general, if you try to use a "pure" PID, you run into some numerical issues because of the transfer function has no limits and, also, if you try to have "KD" different than zero, it won't even run the simulation. To avoid this problem, use a value for the high frequency time constant higher than zero. This way, you won't run into this problem.
    If you still have questions, please feel free to reply with you actual code and version of LabVIEW that you use.
    Cheers!
    Barp - Control and Simulation Group - LabVIEW R&D - National Instruments

  • How to run simulations of MIMO models having direct feedthrough, using the control and simulation loop?

    say i have the MIMO model of a system in transfer function as
    4s + 4       0
    10s+1
                                    =   G(s)
    0             3s + 3
                   10s+1
    this model has direct feedthrough. how do i run simulations of to say, a 2 step inputs?
    I don't get any output signals. please, see attached VI file.
    thank you.
    Attachments:
    Q1 test.vi ‏56 KB

    Hi tomcruize79
    Thanks for using the forums!  Sorry for the delay in getting back to you - how have you been getting on with this?
    One thing to note is that you can use the Signal Generator VI to generate a function as an input.  Try this with your model and let me know how you get on.
    Regards,
    Peter D

  • Design control and simulation palette

    After hitting Next bottoms and succesfully installation for Design control and simulation toolkit , when I launchำก Labview programme  there is nothing in this function and the palette is blank. Anyone knows what happen.  I use Labview 2013 student edition 64 bit(free 6 months version). Thanks in advance+++
    Solved!
    Go to Solution.

    Do you truely have the 64bit version of LabVIEw installed?
    If you do, then you will not be able to use this module.
    It is only valid for 32bit LabVIEW.
    You can see the system requirements here:
    http://www.ni.com/labview/requirements/#cds
    You can try to install 32bit version of LabVIEW and then install the module.

  • Where can I find more information on Control and Simulation Software?

    Where can I find out more information on Control and Simulation Software for G (GSIM)?
    I am currently programming a PID controller using a Siemens PLC. I have installed LabVIEW DataLogging and Supervisory Control Module which allows LabVIEW to interface with my PLC.
    Would appreciate if you could offer me some advice on whether it would be possible for the PLC PID controller to control a first order process model created using GSIM? Please email me at [email protected] if you could offer me any advice or assistance.
    Merry Christmas and a Happy New Year.
    Best regards
    Donald

    I see that you posted to the DSC forum, but you did not get GSIM information. Below is the link for the user manual for the Control and Simulation Toolkit. It is the single best source for info on the toolkit.
    http://digital.ni.com/manuals.nsf/webAdvsearch/63E23F9BA1494FE98625665E00635898?OpenDocument

  • Table controls and step loops

    what are the differances between table controls and step loops?

    Hi
    It's only graphic diff. managed by diff. ways (of course):
    in steploop there isn't a table control so in PBO and PAI it has only the stataments LOOP/ENDLOOP or LOOP AT ITAB/ENDLOOP.
    The step loop is way older than table control to display the data of a table.
    check this
    Re: step loops, table controls
    -charitha.

  • Can't install Control and Simulation Module in LABVIEW2009

    HI all,
    I m using LABVIEW2009 x64 and wanted to update control module in it.
    when ever I try to install the Control DEsign and Simulation module, the setup won't proceed.
    IT shows the following error message : 
    NI LabVIEW 2009 Control Design and Simulation Module
    The Control Design and Simulation Module requires LabVIEW 2009 Full or Professional Development System to be installed.
    however, I have already installed and reinstalled once as well. Please help me.

    Hi Rishabh,
    Unfortunately, we do not have a version of Control Design and Simulation for x64. You can try to install the 32-bit version of LabVIEW instead on a 64-bit OS. This should allow you to install CD&SIM.
    Please let me know if can help any further.
    Barp - Control and Simulation Group - LabVIEW R&D - National Instruments

  • Control and simulation

    For someone who is skilled in labview and spare some time ,I am new to labview and found an intersting labview application which it can be used as a start for control and simulation. I would like a help to run this vi and see what could be added to it to make it more usefull.
    Attachments:
    RS.vi ‏84 KB

    Bin,
    You should post this question to the page where you found the VI, and ask ADEEB or Al S what they used the VI for.
    Zvezdana S.

  • Fpga, Control and Simulation Module

    Hello,
    I am trying to implement control by Control and Simulation Module through NI CRIO 9024. The error message pops up when trying the run the RT vi. 
    Other vis which are not coded by the Control and Simulation Module can work properly. However, when it comes to the Control and Simulation Module, the error message pops up. Is there anything wrong with the installation of the Control and Simulation Module? Please let me know if you have an idea about that. I appreciate your help.

    Hi Richard629,
    As seen in this Knowledgebase article, you most likely do not have the Control Design and Simulation module installed on the controller. You can use NI Measurement & Automation Explorer to install the Control Design and Simulation module on your controller.
    Regards,
    Allison M.
    Applications Engineer
    National Instruments
    ni.com/support

  • How to reset indicators in a control design and simulation loop before each run?

    Hi,
    I am new to Labview. I have tried using property node to reset indicators before each run. But since it is in a simulation loop, it gets resetted many times. I am primarily interested in resetting only before each run. 
    Any hint will be of great help.
    Thank you!
    Regards,
    Divya

    Hi Divya, 
    This KnowledgeBase article describes 2 methods for resetting your Front Panel programmatically:
    http://digital.ni.com/public.nsf/allkb/08E7DDAE66A7D02C86256DDA00630E75
    However if you have tried these methods, and are still not getting the behaviour you want, it would be easier to help if you could post your code (or even a screen shot of the section of code where you're trying to reset your values)

  • Control and simulation - SMP

    I am using a LabVIEW Real-Time 2012 and a Desktop RIO for some real-time 
    simulations. The CPU has four cores. I have a problem when I try to run 
    multiple control & simulation loops in parallel on different cores. I have 
    manually assigned different cores to the loops and they are running, but not at 
    the same time. I need them to have exactly the same simulation time, 
    synchronized to the CPU. Is this possible?
    Thanks a lot!
    Best regards,
    Sinkva

    Hi Sinkva,
    You can use notifiers or queues to 'trig' synchronous execution of loops, have a look at this white paper:
    Application Design Patterns: Producer/Consumer
    http://www.ni.com/white-paper/3023/en/
    Make sure you are not entering the next iteration in the master loop until all slave loops have finished the current iteration (the slowest loop will set the timing).
    Best regards,
    Robert P-F
    Applications Engineer
    National Instruments Sweden

  • No icon in the control and simulation palette, toolkit is instaled

    only question marks on the palette

    Hi Adj;
    Do you have more information on the LabVIEW and the control design and simulation toolkit you are using?
    Here is a document that solves that issue for LabVIEW 8.2 and Control Design and Simulation Toolkit 2.1.1:
    http://digital.ni.com/public.nsf/allkb/57E03AEB671A6D9F8625725A0079E37F?OpenDocument
    I hope the information is useful
    Good Luck! 
    Francisco Arellano
    National Instruments Mexico
    Field Systems Engineer - Energy Segment
    www.ni.com/soporte

Maybe you are looking for

  • Error in Phase Run ABAP report

    Hi All, We are running an installation on I5/OS for ERP 6.0 EHP5. Installation is stucked at phase Run ABAP reports where it is trying to run RSWBOINS report and giving an error SQL error -7008. Log says ddic user is not able to login in the system a

  • T420, Win8: webcam not working

    Hi, I'm using T420 with Windows 8 64bit, but the webcam is not recognized. Win8 Camera-App does not recognize the cam, too. Message from Microsoft was to contact the manufacturer to support drivers for Win8 64bit. BUT: webcam works fine with Skype an

  • Activate Adobe Reader Pro 9

    How To Activate

  • How to use Export-csv

    I have a loop at the end of my script which writes a bunch of stuff to the command window foreach($i in $hash.keys){ write-host "Hostname: $i" ; Write-host "Template:" "$($hash.$i)"; $objIwsList = $iwsObjSearcher.findAll() | foreach-object{ $tmp_name

  • Trash says "being emptied" for hours, but doesn't empty.

    So, about a week ago, I clicked empty my trash. It took a little while. A minute later, I forgot that it was running, so I closed my Mac. When I turned it back on, I realized that the trash was paused emptying and the error started. I couldn't empty