coqueraux: Fast, conceptually simple, iterative scheme for Weierstrass P...

Description Usage Arguments Author(s) References Examples

Description

Fast, conceptually simple, iterative scheme for Weierstrass P functions, following the ideas of Robert Coqueraux

Usage

1
coqueraux(z, g, N = 5, use.fpp = FALSE, give = FALSE)

Arguments

z

Primary complex argument

g

Invariants; if an object of type parameters is supplied, the invariants will be extracted appropriately

N

Number of iterations to use

use.fpp

Boolean, with default FALSE meaning to not reduce z to the fpp. Setting to TRUE reduces z to the fpp via parameters(): this is more accurate (see example) but slower

give

Boolean, with TRUE meaning to return an estimate of the error, and FALSE meaning to return just the value

Author(s)

Robin K. S. Hankin

References

R. Coqueraux, 1990. Iterative method for calculation of the Weierstrass elliptic function, IMA Journal of Numerical Analysis, volume 10, pp119-128

Examples

1
2
3
4
5
6
7
 z <- seq(from=1+1i,to=30-10i,len=55)
 p <- P(z,c(0,1))
 c.true <- coqueraux(z,c(0,1),use.fpp=TRUE)
 c.false <- coqueraux(z,c(0,1),use.fpp=FALSE)
 plot(1:55,abs(p-c.false))
 points(1:55,abs(p-c.true),pch=16)
 

Example output

Attaching package: 'elliptic'

The following objects are masked from 'package:stats':

    sd, sigma

The following object is masked from 'package:base':

    is.primitive

elliptic documentation built on May 2, 2019, 9:37 a.m.