In mathematics, a curve (also called a curved line in older texts) is, generally speaking, an object similar to a line but which is not required to be straight.
Questions tagged [curve]
1306 questions
5
votes
1 answer
how to calculate Riemann Sums in R?
Can any one help how to find approximate area under the curve using Riemann Sums in R?
It seems we do not have any package in R which could help.
Sample data:
MNo1 X1 Y1 MNo2 X2 Y2
1 2981 -66287 1 595 -47797
1 2981 -66287 1 …

Manoj Kumar
- 5,273
- 1
- 26
- 33
5
votes
2 answers
How to reduce space between axis ticks and axis labels in R
I have the below plot generated in R:
Code:
ecdf.bdel<-ecdf(bDE[,6]) #### cumulative distribution of a vector of numeric values
curve(1-ecdf.bdel(x),col="red",xlim=r,xlab="r2",ylab="Fraction of SVs tagged") ###plotting inverse ecdf curve
the…

chas
- 1,565
- 5
- 26
- 54
5
votes
2 answers
Calculating an area under a continuous density plot
I have two density curves plotted using this:
Network <- Mydf$Networks
quartiles <- quantile(Mydf$Avg.Position, probs=c(25,50,75)/100)
density <- ggplot(Mydf, aes(x = Avg.Position, fill = Network))
d <- density + geom_density(alpha = 0.2) +…

datayoda
- 1,067
- 2
- 12
- 24
5
votes
2 answers
Using Core Graphics from ObjectiveC, how to you curve an arrow around a circle?
Our designer has asked me to recreate this:
Im subclassing UIView, and I've overridden the drawRect command like this:
[super drawRect:frame];
CGFloat x = self.frame.origin.x;
CGFloat y = self.frame.origin.y;
CGFloat w =…

Ken Corey
- 435
- 3
- 15
5
votes
2 answers
Control points to curve formula for ImageMagick's '-FX' function using Gnuplot on Windows
I had many issues replicating the generated curve formula example found in the ImageMagick web site on my Windows platform until now.
I've finally worked it out and would like to share it with you.
The FX formula from the ImageMagick web site is…

Tremours
- 245
- 2
- 9
5
votes
4 answers
How to make a curve on a rectangle's top in css? only in top edge
I want to create the following shape:
Important: if I use "Border Radius" I get this (and I do not want this result):

user3307335
- 53
- 1
- 3
5
votes
3 answers
The equation -e**-((-log(7)/100.0)*(100-x))+7 returns NaN
I'm trying to implement this curve as part of the leveling system of a small game I'm currently working on. The equation is as follows
f(x) = -e^-((-log(7)/100)*(100-x))+7
Which in python can be defined as
f=lambda…

user2963567
- 53
- 4
4
votes
1 answer
Two Dimensional Curve Approximation
here is what I want to do (preferably with Matlab):
Basically I have several traces of cars driving on an intersection. Each one is noisy, so I want to take the mean over all measurements to get a better approximation of the real route. In other…

ILikeCars
- 41
- 1
4
votes
1 answer
How to remove a node of a Bezier curve so that the shape of the curve does not change?
I need a help in writing the algorithm remove nodes Bezier curve. Using cubic Bezier curves, there are two curves (P0, P1, P2, P3 and Q0, Q1, Q2, Q3), which have a common point (P3=Q0). Need to get a single curve (P0, R1, R2, Q3), repeating the…

Nekit_SPb
- 43
- 4
4
votes
1 answer
Delphi algorithm to solve 4 or 5 parameter logistics equation?
I'm looking for an [Pascal/Delphi] algorithm that can solve a 4 or 5 parameter logistics equation. I've been searching the web for quite a while now and have not been successful in finding an algorithm that works.
For example, 4 parameter…

Hanzaplastique
- 564
- 8
- 13
4
votes
1 answer
How to Curve a bitmap in android
I am developing a game and I want to give a smoke effect at the tail of the objects moving freely on the screen. I just created a bitmap and attached it at the end of object but the problem is that this doesn't look good because when the objects…

Jawad Amjad
- 2,532
- 2
- 29
- 59
4
votes
2 answers
How can I know the coordinates of the peak point of an svg quadratic bezier arc?
I am creating an svg arc between two points. I am interested in creating a slightly curved arc and adding an svg circle element at the peak of the arc (i.e. where the curve changes orientation).
Based on some basic search, creating this curve is…

Ali
- 77
- 6
4
votes
1 answer
Calculating the area of irregular shape in R
I would like to calculate the closed area in R as in the graph below:
The code is:
a <- c(0,1,2,2,1,0,-1,-2,-2,-1,0)
b <- c(0,0,0,1,0,0,0,0,1,0,0)
id <- order(a)
AUC <- sum(abs(diff(a[id])*rollmean(b[id],2)))
The result for AUC is 0.5. Why it is…

Dori
- 53
- 4
4
votes
1 answer
Scale density curve made with geom_density to similar height of geom_histogram?
I need to align the density line with the height of geom_histogram and keep count values on the y axis instead of density.
I have these 2 versions:
# Creating dataframe
library(ggplot2)
values <- c(rep(0,2), rep(2,3), rep(3,3), rep(4,3), 5,…

Iraleksa
- 155
- 1
- 9
4
votes
2 answers
I have a problem with plotting sphere and a curve on it
I am trying to plot a curve on a sphere but I can not plot them at the same time. I identified some points with Euclidean norm 10 for my curve, and some other points to plot the sphere of radius 10, respectively as following.
Points for…

Sik Sik
- 123
- 1
- 7