DNRGE: Calculation of the First-Order Derivative of the...

View source: R/DNRGE.R

DNRGER Documentation

Calculation of the First-Order Derivative of the Narushin-Romanov-Griffin Equation

Description

DNRGE is used to calculate the first-order derivative of the Narushin-Romanov-Griffin equation at a given x-value.

Usage

DNRGE(P, x)

Arguments

P

the parameters of the Narushin-Romanov-Griffin equation.

x

the x-value used in the Narushin-Romanov-Griffin equation.

Details

Let us define:

f_{1}(x) = \frac{B}{2}\sqrt{\frac{A^2-4x^2}{A^2+8Cx+4C^2}},

f_{2}(x) = \sqrt{\frac{A\left(A^{2}+8Cx+4C^{2}\right)}{2(A-2C)x^{2}+\left(A^{2}+8AC-4C^{2}\right)x+2AC^{2}+A^{2}C+A^{3}}},

f_{3}(x) = A^2 - 4x,

f_{4}(x) = A^2+8Cx+4C^2,

E = \frac{\sqrt{5.5A^{2}+11AC+4C^{2}} \cdot \left(\sqrt{3}AB-2D\sqrt{A^{2}+2AC+4C^{2 }}\right)}{\sqrt{3}AB\left(\sqrt{5.5A^{2}+11AC+4C^{2}}-2\sqrt{A^{2}+2AC+4C^{2}}\right)},

F = 2\left(A-2C\right),

G = A^{2}+8AC-4C^{2},

H = 2AC^{2}+A^{2}C+A^{3},

and then the first-order derivative of the Narushin-Romanov-Griffin equation at a given x-value is:

J(x) = -\frac{4\,f_{1}(x)\left[C\,f_{3}(x)+x\,f_{4}(x)\right]}{f_{3}(x) \cdot f_{4}(x)}\left\{1-E \cdot \left[1-f_{2}(x)\right]\right\}-\frac{AE}{2}\frac{f_{1}(x)}{f_{2}(x)}\frac{f_{4}(x) \cdot \left(2Fx+G\right)}{\left(Fx^2+Gx+H\right)^2},

where P has four parameters: A, B, C, and D.

Note

The argument P in the DNRGE function has the same parameters, as those in the NRGE function.

Author(s)

Peijian Shi pjshi@njfu.edu.cn, Johan Gielis johan.gielis@uantwerpen.be, Brady K. Quinn Brady.Quinn@dfo-mpo.gc.ca.

References

Narushin, V.G., Romanov, M.N., Griffin, D.K. (2021) Egg and math: introducing a universal formula for egg shape. Annals of the New York Academy of Sciences 1505, 169-177. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/nyas.14680")}

Narushin, V.G., Romanov, M.N., Mishra, B., Griffin, D.K. (2022) Mathematical progression of avian egg shape with associated area and volume determinations. Annals of the New York Academy of Sciences 1513, 65-78. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/nyas.14771")}

Shi, P., Chen, L., Quinn, B.K., Yu, K., Miao, Q., Guo, X., Lian, M., Gielis, J., Niklas, K.J. (2023) A simple way to calculate the volume and surface area of avian eggs. Annals of the New York Academy of Sciences 1524, 118-131. \Sexpr[results=rd]{tools:::Rd_expr_doi("10.1111/nyas.15000")}

See Also

fitNRGE, NRGE, SurfaceAreaNRGE

Examples

  Par6 <- c(4.51, 3.18, 0.1227, 2.2284)
  xx3  <- seq(-4.51/2, 4.51/2, len=2000)
  J1   <- DNRGE(P=Par6, x=xx3)
  J2   <- -DNRGE(P=Par6, x=xx3)
  ind  <- which(is.na(J1) | is.na(J2))
  xx3  <- xx3[-ind]
  J1   <- J1[-ind]
  J2   <- J2[-ind]

  dev.new()
  plot(xx3, J1, type="l", col=4, cex.lab=1.5, cex.axis=1.5,
       xlim=c(-4.51/2, 4.51/2), ylim=c(-20, 20), xlab=expression(italic(x)), 
       ylab=expression(paste(italic(J), "(", italic(x), ")", sep="")))
  lines(xx3, J2, col=2)  

  graphics.off()

biogeom documentation built on May 29, 2024, 8:52 a.m.

Related to DNRGE in biogeom...