473,385 Members | 1,535 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

area under the curve

1
hello,
i am using Visual studio environment to run GUI in c#, which is connecting to a Micro controller via Rs232, the problem is i am getting a wave on GUI (sometimes multiple waves)(using A/D converter), and i want to calculate the area under the curve in simple words consider i am getting a sine wave and on that wave i want to calculate the area from point X1 to X2. any suggestions will be appreciated, i am also attaching a code where i read strings form micro controller and display them on Gui.

public delegate void AddnewText(string str);
public void AddTextToLabel(string str)
{
if (this.tb_Received.InvokeRequired)
{
if (str.IndexOf(".", 2)>1) str = str.Substring(0, str.IndexOf(".", 2));
this.Invoke(new AddnewText(AddTextToLabel), str);

//MessageBox.Show("invoked");

}


else
{
if (str != "\f")
{
this.tb_Received.Text = "";
this.tb_Received.Text += str;
string a = str;
input = Convert.ToDouble(str);

// this.tb_Received.Text += input;

// double[] intArray;
// intArray = new double [200];
//intArray[p] = input;
CreateChart(zedGraphControl1);
p++;
}
else
{
this.tb_Received.Text = "";
}
}
}
Apr 11 '08 #1
0 1095

Sign in to post your reply or Sign up for a free account.

Similar topics

5
by: Vinodh Kumar | last post by:
Number One: ========= I know its a 100% offline post.But seeing the diversity of the domain from which people are participating, I would like to post this question here.Pardon me.At the least, u...
0
by: Betty Harvey | last post by:
The next meeting of the XML Users Group will be held on Wednesday, November 19, 2003 at the American Geophysical Union (AGU) at 2000 Florida Avenue, N.W., Washington, DC 20009-1277. The meeting...
0
by: Betty Harvey | last post by:
Happy 2004! I hope everyone had a great holiday and will have a good new year. The next meeting of the XML Users Group will be held on Wednesday, January 21, 2004 at the American Geophysical...
5
by: reagan | last post by:
I am trying to get a program(in visual C++) to draw a sine curve (from 0 to 2pi). It takes 8 lines to draw the complete curve. However, the user can choose to use up to 100 lines to make the curve...
2
by: MLH | last post by:
This question, I apologize, is more of a math question than it is an Access question - I'm almost certain. The bell curve is another name for the normal distribution, which is a common type of...
8
by: scorpion53061 | last post by:
Hi, I am a vb.net guy......(I know boo hiss LOL) I was thinking of learning C# as well. Can I expect a hard road of it as far as a learning curve? As as side note, what made you choose...
15
by: anand | last post by:
Dear all, I am trying to "find the area under the curve f(x)=sin(x)/x for x=1 to 3" a) Use the trapezoidal rule method. Prove that your trapezoidal rule method is second order accurate...
4
by: babyinc | last post by:
Please help me. I am totally beginner of C++ and my tutor give us these huge program to solve within 20 days. As a MSc student I am really gonna cry. Please anyone can help me. sumon1in1@yahoo.com ...
0
by: sa6113 | last post by:
Hello there, I have a problem on curve fitting , would you please help me ?! I want to to develop a application that reads a text file with 2 columns of floating point data (as x and y) and...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.