LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Cardio simulation

Good day, the developers!

Apologies for the English
Never before I have worked with LabView, but encountered, in simulation cardio.
It is necessary to build cardio on points using data sets of several variables.
Required to build the chart cardio described by the formula, which is equal to the sum of the functions describing each tooth of electro cardio signal (ECG) (or a portion of the ECG). It looks as follows :

f(t)=f(1)+f(2)+f(3)+f(4)+f(5)+f(6)+f(7)+f(8)+f(9)

f(n)=y(x)

Each tooth cardiogram draw by the Gauss impulses : 

1.JPG

My idea is this: a unit for each term which will look like this:

Снимок2.JPG

 

 

This function describes the tooth, but the very structure of each tooth:

Снимок3.JPG

Then, most likely, you need to sum each block, here I do not know what to do

Снимок4.JPG

 

After summation of 9 blocks, we get a one period of cardiosignal :

Снимок5.JPG

How to build a program that would be possible to construct a 3 period, ECG, and for each period - different variables (such as the need to read from the file .tht) The final result should be a next: 

Снимок6.JPG

The values ​​of A, TM, σ1, σ2, ie for each period - the columns of the array data

All the building blocks, the description of each tooth, and data sets with variable (.tht) in the attached file.
If anything, I apologize in advance for such an exposition of ideas, how to explain the problem in another way - alas, not invented.
Rescues, Developers, and then be gone completely = (

Thanks a ton in advance 😆

 

 

 

0 Kudos
Message 1 of 19
(6,959 Views)

up

0 Kudos
Message 2 of 19
(6,914 Views)

Hi Zorga,

 

use a FOR loop. Create a single signal period in each iteration (using autoindexing on the parameters). Append the generated waveforms…

 

It's not nice to bump a thread that soon. 😞

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
Message 3 of 19
(6,899 Views)

Sorry for early bumping of topic Smiley Happy

How using the FOR LOOP to make a change signal in real time? can best be applied while loop?
Still, I do not much understand how to make each period were used for different values of the data set used in the Gaussian pulse. Prompt architecture itself

thanks for the help

with respect, ZORGa

0 Kudos
Message 4 of 19
(6,886 Views)

I’m not sure if this is helpful, but here is a link that explains in a little bit greater detail the concept of Auto-Indexing. Take a look, and continue to post any questions you have!

 

http://digital.ni.com/public.nsf/allkb/B85025233861378A86256CE700491E34

Ross S.
Applications Engineering
National Instruments
0 Kudos
Message 5 of 19
(6,808 Views)

Zorga,

 

     If you want us to help you with your code, attach your code.  I, for one, cannot see the details of the pictures you posted of your Front Panel and Block Diagram, and, much more important, I can't run your code to see what it does (and to try to make it "better").

 

     If you don't understand Auto-indexing and For Loops, then you must not know very much about LabVIEW.  Besides classroom instruction (which you might not have available), there is numerous Tutorial material on the Web, including links on the first page (upper right corner) of this Forum.  Spend a few hours, do all of the examples, and then think about what you want to do.

 

Bob Schor

0 Kudos
Message 6 of 19
(6,798 Views)

@Bob_Schor wrote:

Zorga,

 

     If you want us to help you with your code, attach your code.  I, for one, cannot see the details of the pictures you posted of your Front Panel and Block Diagram, and, much more important, I can't run your code to see what it does (and to try to make it "better").

 

     If you don't understand Auto-indexing and For Loops, then you must not know very much about LabVIEW.  Besides classroom instruction (which you might not have available), there is numerous Tutorial material on the Web, including links on the first page (upper right corner) of this Forum.  Spend a few hours, do all of the examples, and then think about what you want to do.

 

Bob Schor


Dear developers! Thank you very much for the advice, tips and responsiveness!
Your information helped me get acquainted with the basic concepts in LabView 
For a start, I tried to deal with the construction of 3 teeth ECG in real time (using the "for loop" and manual input), however, to achieve the desired result is not obtained e =
Do not tell me that I'm wrong?
Thank you.
with respect  ZORGa

 

 

0 Kudos
Message 7 of 19
(6,773 Views)

Hi Zorga,

 

are you sure your "Gaussian pulse" VI is correct?

I simplified your main VI to check it's general behaviour and I get plots, which aren't similar to the ones you have shown in your images…

 

Do you really need to make copies of those VIs? They seem to use the very same code, so just one VI (with several instances) should be sufficient!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 8 of 19
(6,764 Views)

The construction of each tooth is given by the normal distribution of the variable X by the rule is not symmetrically Gauss curve.
You mean whether I realized the distribution formula?

The original formula is: iOmdJDTn5MA.jpg

 

Block Gaussian impulse, I believe, corresponds to the above formula (I or somewhere made a mistake, but it seems like everything is correct)

Dear GerdW, you certainly are right. You could use 1 unit, which describes each tooth, but how to use it to build several teeth from the matrix of values ​​of A, TM, σ1, σ2 (and, for each period, these values ​​are different), I have not mastered, as the first encounter in LW

0 Kudos
Message 9 of 19
(6,751 Views)

Is this what you are hoping to see?

EKG.png

This is created from your VI in the Zip file after fixing one small error that you made.  Your Gaussian impulses have time parameters in fractions of a second, but you feed them "whole seconds", when I suspect they want "whole milliseconds".  All I did was divide the index I by 1000 before sending them to your P, Q, and R routines, and look at what I got ...  a beating heart!

 

Bob Schor

Message 10 of 19
(6,712 Views)