differential equation

Dear Sir

I am a beginner in labview and I would like to solve two differential equations and field them over time:

DX1/dt = (G - K * x 1 (t)) /V (t)

dV (t) /dt = (1/((1-(((G-x1*(K-U))/(G-x0*(K-U)))^((U/(K-U)))-1))*U

G = 7.8

U = 0,166

x 0 = 132

VO = 432

K = 2.02

Could someone please help me and send the block diagram for these two equations.

The graphs of these two variables have to be reduced over time. The graph of X 1 is of exponential decay.

Hello Ahmad,

I made a simple example and put it on our community page.  This example uses our ODE solver vis LabVIEW comes with 8 built in ODE solvers.  These are all linear system solvers.  It seems that your equations are not linear. I suggest using the LaPlace transforms to solve equations.

Code example

Tags: NI Software

Similar Questions

  • First HP: differential equation solver...

    Hi all

    I would like to know how to use HP first to solve the differential equation



    I tried to read the user manual, but with no luck.

    Tim

    Hi!, @Theplum:

    Welcome to Forum!

    If you learn properly the use of desolve, you see, better explained in the AUR HP50G, of...

    [PDF] HP 50 g / 49 g + / 48gII graphing calculator

    h10032.www1.HP.com › manual GTC

  • The first (emulator) HP: HP Premium differential equations

    Hello

    I'm looking a calculator with AC for my electrical engineering studies and just tested

    the first emulator to get a first impresseion.

    But while testing its features, I got some results of unexpectet on differential equations,
    that I would be confirmed on a calculator of real world.

    A simple as equation y' = x

    CODE: desolve (diff (y) = x, x, y)

    wait-> x ^ 2/2 + C

    First HP-> 1/2 * (x ^ 2 + 2 * C).

    The result is correct, but nobody would write it down in this way, nor would one solve it how works the first.

    A little more difficult equation could not be resolved by the premium: 2 x ^ 3 * (1 + y ^ 2) = y'

    CODE: desolve (2 * x ^ 3 *(1+y^2) = diff (y), x, y)

    wait-> y = tan (1/2 * x ^ 4 + C).

    First HP-> could not resolve the implicit equation

    It is not an implicit equation, the two WolframAlpha (iOS) and CASES of TI (iOS) could also resolve this one)

    And last but not least: y' * sin (x) = y * ln

    CODE: desolve (diff (y) * sin (x) = y * ln (y), x, y)

    wait-> y = e ^ (C * tan (x/2))

    First HP-> y = e ^ (sqrt (cos (x) ^ 2-1) / (C * cos (x) + C))

    I don't know what made the CASE here, but there is no reason to use the Pythagorean trigonometric identity.

    Would be nice if someone with a premium could conifrm/refute these results or tell me what I've done
    evil.

    Hello

    The latest version of premium can solve your 2nd test case (desolve ((2 * x ^ 3 *(1+y^2)) = (y'), x, y))

    However, the results for 1 and 3 test cases are the same that you tested.

    I will pass the info to the person who develops the CASE and if all goes well he will be able to improve it.

    Cyrille

  • Just me, or is the 50g low in solving differential equations?

    Hi all

    I used Ti-89 s widely in the past, as well as the Ti-NSpire CX CASE and now the 50 g for about 1.5 years. I love some aspects of the 50g (sensation of keys, ease of unit, RPN conversion), but I can't help but notice some areas where it reallllly hangs out of the competition.

    It is an example that I really noticed recently in solving differential equations. So far, several examples I've tried (all immediately resolved by my Ti - 89 and Nspire CX CASE), the 50g smothered on each.

    A very simple example: solve y "= - 9.8, with boundary conditions y (0) = 2.9 and y'(0) = 3.8.  This can be solved by hand in about one minute, but the 50g can't do. If I input ['d1d1Y (X) =-9.8' ' Y (0) = 2.9 ' ' d1Y (0) = 3.8 '] in level 2 on the stack, then 'Y' on a level and then run desolve, it returns "Error: Undefined result.

    I missing something here, or is - this really unable to resolve such a differential equation based? I thought that advanced and 'better' mathematical capacity HP CASE was meant to be one of the reasons why it takes precedence over offers from Ti, but I must say, so far I do not see that.

    Josh

    Hello!

    Try with the exact numbers:

    ["d1d1Y (X) =-49/5 ' ' Y (0) = 29/10 ' ' d1Y (0) = 19/5 '"]

    « Y »

    DESOLVE

    (after SIMPLIFICATION) You'll get years:

    {Y (X) =-(49*X^2-38*X-29)/10}

  • Algebraic manipulations of solutions to differential equations

    Hi, guys

    I found the general solution of the differential equation y "-3 t = 1 using the command DESOLVE. I did it manually first and the answer I got was: 1/2 t ^ 3 + 1/2 t ^ 2 + C1t + C2; However, when I do with the calculator that I get is: (2cC0 + t * cC1 2 + t ^ 3 + t ^ 2) / 2.  I tried everything in the ALG menu to get rid of the 2 in the denominator. Nothing has worked.  I'm in Exact, symbolic mode.  Am I missing something?

    Thank you very much!

    Hi!, jc_cfa:

    If you have RPN MODE...

    Configure the FLAGS ...

    Function 03-> symb

    Approx. 105 mode on

    Calculator modes

    Number format... STD

  • solve the differential equation

    Hello

    I m trying to solve a simple equation using euler vi. But I have not yet. the equation is:

    (T) DH / DT = 1/A *(F-h/R). I m not understand what I need to plug on euler vi. I´v already took a look at the example of ode euler, but I continuously difficult. Please help me. Thank you.

    I guess that your real goal is to learn to use Euler's method as it is a fairly easy to solve analytically ODE.  Here's a quick example.

  • System of differential equations to solve a model of BZ reaction

    Hello

    I wrote this little code to visualize the oscillation of the BZ reaction. I expect to see the oscillation as in page 3 and 7 of the link below

    http://home2.fvcc.edu/~dhicketh/DiffEqns/spring2014projects/SilasSchwarz/final/final/bzreaction.PDF

    This work is done in Matlab, and I want to reproduce in Labview with the same settings. But so far I could not see the oscillation.

    Could someone body spot what is wrong with this code?

    See you soon,.

    Zied

    I have noticed that but not had time yesterday to examine it. I've implemented their matlab scripts and it turns out that the constants they give; e, e' and q are in fact 10 ^-n, and not 10 ^ n. A typo in a student newspaper, how rare once I changed that I had the correct plot as shown here:

    Attached to the VI. It runs much more slowly than in Matlab, so be warned.

  • Problem call Matlab external function under Labview 7.1

    Hello

    I have the problem when I want to call my m.file function in the script Matlab under Labview 7.1, that labview does not seem to be able to find this external Matlab function. I searched this forum, someone talked about setting search path in the tool-> option-> Matlab search path, but it seems that it does not exist in the version 7.1.

    Is it possible to solve this problem in version 7.1 or update to the latest version, the only solution?

    Thank you

    Hello

    I think you're confusing the LabVIEW MathScript nodes and the MATLAB® script.  The MathScript node is introduced in LabVIEW 8.0 and the setting of path search that you speak to MathScript, reason why it does not exist in LabVIEW 7.1.  Look at the example of differential equation Lorenz for the MATLAB script node.  It shows how to set the path of research to be compared to the VI.  The example is found in the node of script examples\scriptnode\MATLAB - Lorenz Diff Eq.vi.

    MATLAB® is a registered trademark of The MathWorks, Inc.

    Grant M.
    Staff software engineer | LabVIEW Math & Signal Processing | National Instruments

  • program import Java in Labview

    I have an equation of the standard deviation (7th order differential equation) calculaiton written in Java and I wanted to use this program in Labview. Anyone can suggest how to do it plse. I'm not familiar with Java me.

    Hi SINANGA,

    I'm sure that we can help, however I copy and paste your message in the forum of LabVIEW for a faster response.

    http://forums.NI.com/NI/Board?Board.ID=170

    I hope this helps!

    Chad Erickson

    Switches Product Support Engineer

    NOR - USA

  • The Solver RK4 VI has a maximum length of scan?

    I have to solve a differential equation in one of my report, and after adding in a new logic (which decides whether or not to include an additional number in the equation), it stops the execute. The Solver, RK4 VI East-23009 error: error in the right-hand side of the equation. Covering over the stream, I've isolated to two eq'ns: dG/dt and dI1/dt, who both have their own VI in the case of ODE solver. I have all converted to a width of 8, precision channels 12 and I think that my newest additions have exceeded the limit digitization of execution of RK4 screws max. inside, I quickly found that I can't really understand what is happening, so I come to you.

    Some good starting parameters:

    in VariableCluster.ctl, set Xa 100 X (t - 1) de.01, I1(t-1) 10, I2(t-1) a.5

    control.CTL constant, the value weight 80, activate auto of Glucose.

    EDIT: to start execution, run solver.vi ODE which is located in the folder of ODE solver.

    In VD.vi VD is set to the value of the constant of VD Mult (hidden) which by default is zero. Later, this value is used as a divider that produces NaN values in f. I have no idea whether it is what you want, but the NaN will keep it forms solve anything.

    I have not dug down beyond that point.

    Lynn

  • Documentation of the API for CWIMAQControls

    I am a software developer with several years of experience in medicine and other sciences, but now is working on a software project using National Instruments IMAQ customer in .NET and have no prior experience with image processing.  The only I can find the API documentation is a help file with the product intalled.  Then this under did a good job explaining the service inputs and outputs, it is light on the explanation in a real retail functions actually do.  Under .NET (not my favorite but this is what I got), I can get a good summary of the objects and their properties / methods, which is useful.  I see there are a lot of good material in this forum, but what I need right now is good basic documentation.  I also noted a plethora of PDF files in the directory of installation but found nothing there or on ni.com which gives me the level detail fo I need.  When I think that the documentation of the API, I expect something as complete what Sun Microsystems offers with any JDK Java - it seems that the doc API IMAQ assumes a certain level of ease and does not for someone like me come with literally no background outside a lot of math (algebra of vector fortunately!) and science in College courses.

    Am I missing something?  I see that there are many examples of programs and I can get what want from those, I guess, but I do not charge my client for all the time it will take, if there is a more ready fo source information.

    Now, I realize that the field of the treatment of the image is large and it would be difficult to develop a software of this nature without a learning curve.  So I have

    I studied through two web queries image processing and having bought the book 'Digital Image Processing (Gonzalez, wood).

    Specifically, I was put to zero in on what is needed for the task at hand: "blob detection" and "blob tracking movement."  It seems pretty clear to me, some have become familiar with the image processing basic terminology and methodologies that have been developed for tracking, and image recognition of movement IMAQ software can do what it takes.  At this point, I can do basic things with objects presented in .NET.  It is analogous to maybe ask a kid who just the definition of an equilateral triangle to solve differential equations.

    In this case, what I really need is one or more examples of programs that perform functions similar to what I want to do.  Is there any suggestions in this regard?  My research on ni.com revealed evidence of the items of "blob detection" and "blob motion" and I see that these were used for tasks as complex as the particles of follow-up and the counting of blood components.  I don't see and od you expect not to see any object, follow also specific methods than what I need to do - which is in fact quite abstract - and chart the path of the blob more to light to the camera image gained when it moves in real time.

    It's a strange feeling to have been programming for decades, and then enter a field where the customer needs require me to act as a nini who has not done its homework.  But it's the nature of the job.  The pointers will be appreciated.  If I missed something obvious I don't even mind being reprimanded to be unobservant or lazy.

    Thank you very much in advance for any assistance that may be provided.

    tsfarrell-

    Have you looked at the manual of the Vision Concept?  (it should be in the form of PDF in the documentation directory, or you can see it here) It has a more detailed description on what our algorithms.

    We also ship many examples for .NET - those of the 2. Functions\Binary analysis file dealing with blob detection and may be useful.

    Good luck to you on your application!

    Greg Stoll

    Vision R & D

    National Instruments

  • Variables in the function MathScript ode solver

    Hello

    I'm using LabView for awhile and I started using the text tools more. To solve a system of differential equations, there is this very elegant tool to do this in a MathScript node with the ode solve algorithms (for example, "ode_adams"). As the LabView help said, I've defined a function and registered as a ".m" file. I loaded this function in mathscript and solve differential equations.

    Both and so good, but my problem is that I can not all variables in the function. I can only put numbers in the function but not variables. Unfortunately I need to define the variables outside the function in the MathScript node.

    Does anyone have an idea how to manage the variables in this case?

    I have attatched a picture of the function and test VI (LV2014).

    Greetings

    Global variables to solve this problem:

    Solution:

    Greetings

  • exponential response moving average stage fpga

    Hey guys,.

    I have a problem with my filter, the exponential weighted moving average filter (IIR 1 st order.). Excerpt from the book: understand the digital signal processing (Richard Lyons) I have the following formula, calculate the frequency of 3dB (CF) of alpha. Alpha is the parameter to control the filter.

    Differential equation of the filter: y [n] = x [n] * alpha + (1 - alpha) * y [n-1]

    Relationship between CF and alpha: alpha = cos(2fc/fs) - 1 + sqrt [cos²(2fc/fs) - 4 * cos(2fc/fs) + 3]

    If I now choose a frequency of 3 dB from 0, 0794Hz (time constant (TC) = 2 s) alpha = 0,00169621. (fs = 94)

    For a filter command 1st IIR, the rise time (your) of the stepresponse (from 10% to 90%) is: ta = 2, 2 * TC which translates your = 4, 4S.

    But if I simulate the step response, my rise time is about 3 times this value at 14.

    I can't explain why the response of my filter is so much different. For my Moving Average filter, the calculated and simulated rise time are equal.

    I have the vi that is performed on the attached FPGA. Maybe someone can find a mistake...

    Greetz

    Slev1n

    Hey ZX81.

    Thank you very much for your detailed answer.

    Regarding the issue with the rise time, I think I've found the error. You might be right, that the formula is not correct, or which is most probably misunderstood by me and put in the wrong context.

    When I was cycling home from work I remembered a practical function of labview: 'coefficients.vi filter smoothing' here you only need to define tau/TC and fs and it calculates the numerator and the denominator for the moving average exponential and the moving average. Offering it is alpha I could compare the result of the formula I've used and there was a big difference. LabVIEW uses the following formula: alpha = 1 - exp (-1 /(fs*TC)). With this formula, TC = 2 s is equal to alpha = 0, 0053.

    And with this alpha my simulation works! Risetime 4.4 s

    Quote you: "in general, at this stage, I have maturities adjust alpha until my results matching what I wanted and move." I would like to do the same thing, but as it's my thesis I have to solve such things

    Now, back to the rounded questions. I understand that the small values are a more serious problem. This filter is used in a Lock In, the values are going to be REALLY small. But I've already tested on our measuring device and it works, to that effect, I'll test your version as well, but if I get no problems, I guess I keep to the 40bits. Simulating the following configuration, caused an error of 2.3%. 57 bits using reduced the error less than 1%. I think that 40bits should be sufficient.

    Alpha = 0, 000335693 entry = 1, 19209E-7

    And regarding resources, I have no worries. Although using a myrio ultimately I still have a lot of DSP Slices for the multiplication and 10% in flip flops.

    So I guess that this matter is resolved. Thanks for your great help and interesting reflections.

    Kind regards

    Slev1n

  • Circuit of Simulink connection to the controller of LABview

    I try to use my LABview VI to control the switches in a Simulink model. I do not know how to accomplish this task, but right now I'm trying to establish a connection between the two.
    I have 2015 LABview and MATLAB 2011.
    After googling how to connect a LabVIEW Simulink model, I found the following:

    1 using the model Interface tool (MIT)

    2. using controls and Simulation tools to convert a LABVIEW Simulation Model

    1. I downloaded MIT and Veristrand and followed the steps in this link: http://zone.ni.com/reference/en-XX/help/374160A-01/vsmithelp/mit_convert_model_to_dll/
    But I do not know where to go to from there.  Most of the tutorials I found using the SIT

    2. the Simulink components are not recognized in LABVIEW and are just empty boxes.

    Question: What is the best way to connect with LABview Simulink model?

    Hello

    This seems closely related to it.

    The two methods can be used, but both methods require some considerations.

    For the model interface Toolkit, you need to mind what are the features you use. Please take a look at this.

    «In the Simulink software, you can convert models that use only a Solver step-size ordinary differential equation (ODE) in compiled templates fixed.» In addition, you must disable data logging in the application of Simulink software. »

    Please refer to the following as well.

    http://zone.NI.com/reference/en-XX/help/374160B-01/vsmithelp/mit_model_from_mdl/

    http://zone.NI.com/reference/en-XX/help/374160B-01/vsmithelp/mit_model_support/

    (the same that I linked above)

    http://zone.NI.com/reference/linksen-XX/help/374160B-01/vsmithelp/mit_models_mdl/

    http://zone.NI.com/reference/en-XX/help/374160B-01/vsmithelp/mit_convert_model_to_dll/

    (is the one you linked, I just want to bring the model must be a dll to work with the model Interface Toolkit)

    http://forums.NI.com/T5/LabVIEW/importing-MATLAB-model-file-to-LabVIEW/TD-p/883625

    (the message mentions the 'SIT', that is not the model Interface Toolkit)

    The last of them brings something about the method of Simulation of design by control &: the model must be a mdl file so that the converter of Simulation Model work.

    http://www.NI.com/white-paper/11281/en/

    (this link is LabVIEW 2012, but it is still valid on later versions)

    https://zone.NI.com/reference/en-XX/help/371894G-01/LVSIM/sim_simtrans/

    It will be useful.

    MATLAB® and Simulink® are registered trademarks of The MathWorks, Inc.

    Kind regards

  • model of dynamic system, which is the Solver

    Dear Member

    What labview mean by that word in this helpl http://zone.ni.com/reference/en-XX/help/371894G-01/lvsimconcepts/sim_c_ode/ labview

    "" Because many models of dynamic systems consist of differential equations, you must resolve these differential equations".

    "" Most of the simulations that you create in the LabVIEW Control Design and Simulation Module use solving of ordinary differential equations (EDO).

    Best regards

    Most of the linear systems can be modeled by linear differential equations, which can then be used to create a transfer function that describes how the system acts on an input to create output. Help is just stating that a Solver of ordinary differential equations (EDO) will serve as the default option, to solve the differential equations that make up the transfer function. It will solve the transfer function, probably composed of differential equations, for descrete time step, thus returning the step responses of the system for a given entry.

Maybe you are looking for

  • I can't see the pictures of my opening in iMovie; any ideas?

    El Capitan 10.11.4 OSX (15E65); Opening 3.6.  The Aperture library is in iMovie, but when I choose 'Albums' it does not appear my Albums of opening.  How can I fix?

  • Thunderbird opens once and may not be reopened unless I restart

    I have Mozilla thunderbird as my mail connection, it will open when the computer is turned on, but not after I have Run any other program first, I have to turn the computer back on and then access my emails, all the answers. Moved from the community

  • Aspire 7741z does not illuminate

    OK, so I have a aspire 7741z which won't turn on. I changed the power connector and the power button, I changed the power adapter as well. then, when I connect the adapter directly, without the battery nothing happens, no power no lights or anything,

  • Using tiles view

    Is it possible to sort by something while having shown different information. For example, to sort by track number, but have the information shown beside it be the file size or duration instead of the track number? Or sort by name, without showing th

  • Error 1606 problem installing & R Block home State:

    I tried to install the tax program & H R Block home for my condition and am getting the Error 1606. I checked the registry as it says in the article kb886549 and everything matches. Anyone have a suggestion?