text:
# Quick Answer: What Is The Weakest Type Of Bond?

## Which type of bonds are very weak?

In biological terms, ionic bonds, hydrogen bonds, and van der Waals interactions are considered weak bonds.

In biological systems, weak bonds are being continually broken and reformed without the aid of enzymes..

## Which is weaker ionic or covalent?

Covalent is stronger because the 2 atoms involve share 2 or more outer shell electrons. … Ionic bonds are formed when a valence outer shell electron is transferred from one atom to another – a much weaker interaction. Salt is an ionic bonded compound.

## What are strong and weak bonds?

Chemical bonds may be divided into two groups: 1) covalent (strong) bonds in which atoms share electrons, and; 2) a variety of weak bonds, including electrostatic attractions (ionic bonds, hydrogen bonds), hydrophobic interactions, and Van der Waals forces.

## What is the strongest hydrogen bond?

fluorineAs fluorine has small size and high electronegativity, it has high tendency to attract partial positive charge accumulated on H-atom. So, fluorine forms strongest H-bond.

## Are ionic bonds weak?

Ionic bonds within a salt crystal may be quite strong. … The strength of ionic bonds in a cell is generally weak (about 3 kcal/mole) due to the presence of water, but deep within the core of a protein, where water is often excluded, such bonds can be influential.” In water, ionic bonds are very weak.

## What is the weakest bond?

ionic bondThe ionic bond is generally the weakest of the true chemical bonds that bind atoms to atoms.

## Which chemical bond is strongest?

Covalent Bonds. Another type of strong chemical bond between two or more atoms is a covalent bond. These bonds form when an electron is shared between two elements and are the strongest and most common form of chemical bond in living organisms.

## Are ionic bonds the strongest?

Ionic bond is generally stronger because the ion-ion force that exists in ionic bonding is the strongest. In covalent bonds, electrons are shared, which doesn’t generate a force as strong as that in ionic bonding. This can also be explained when we compare the boiling points of ionic compounds and covalent compounds.

## What is the strongest bond in the world?

Covalent bondAnswer: Covalent bond is the strongest bond.

## What is the strongest type of covalent bond?

A single covalent bond is when only one pair of electrons is shared between atoms. A sigma bond is the strongest type of covalent bond, in which the atomic orbitals directly overlap between the nuclei of two atoms.

## Why are covalent bonds so strong?

An atom that shares one or more of its electrons will complete its outer shell. Covalent bonds are strong – a lot of energy is needed to break them. … Both nuclei are strongly attracted to the shared pair of electrons in the covalent bond, so covalent bonds are very strong and require a lot of energy to break.

## Is a hydrogen bond stronger than a covalent bond?

The hydrogen atom in a hydrogen bond is partly shared between two relatively electronegative atoms such as nitrogen or oxygen. … Hydrogen bonds are much weaker than covalent bonds.

## Are hydrogen bonds the weakest?

Hydrogen bonds are intermolecular forces (“between-molecule”), rather than intramolecular (“within-molecule”) forces. … Hydrogen bonds are weaker than chemical bonds. For example, they are much weaker than the covalent bonds holding atoms together within molecules of covalent compounds.

## Is a single or double bond stronger?

Double bonds are stronger than single bonds and they are characterized by the sharing of four or six electrons between atoms, respectively. Double bonds are comprised of sigma bonds between hybridized orbitals, and pi bonds between unhybridized p orbitals.

## Why is triple bond the strongest?

Triple bonds are stronger than double bonds due to the the presence of two $\pi$ bonds rather than one. Each carbon has two sp hybrid orbitals, and one of them overlaps with its corresponding one from the other carbon atom to form an sp-sp sigma bond.

## Is Van der Waals the weakest bond?

Van der Waals interaction is the weakest of all intermolecular attractions between molecules. However, with a lot of Van der Waals forces interacting between two objects, the interaction can be very strong.

## Is Covalent stronger than metallic?

Covalent bond means overlapping of two electron clouds. So, in metallic bond there is actually no overlapping between any two atoms. So,we can conclude that a covalent bond is more stronger than a metallic bond. … This bond is non-directional, meaning that the pull of the electrons does not favor one atom over another.

## What bonds are strongest to weakest?

Thus, we will think of these bonds in the following order (strongest to weakest): Covalent, Ionic, Hydrogen, and van der Waals. Also note that in Chemistry, the weakest bonds are more commonly referred to as “dispersion forces.”


text:
MathSciNet bibliographic data MR948199 35L65 (35B35) Temple, Blake Weak stability in the global \$L\sp 1\$$L\sp 1$-norm for systems of hyperbolic conservation laws. Trans. Amer. Math. Soc. 317 (1990), no. 2, 673–685. Article

For users without a MathSciNet license , Relay Station allows linking from MR numbers in online mathematical literature directly to electronic journals and original articles. Subscribers receive the added value of full MathSciNet reviews.

format: plain


text:
# Use the given zero to find the remaining zeros of the function `f(x) = x^3 - 9x^2 + 4x - 36` ; zero:2i Enter the remaining zeros of f

Inna Shpiro | Certified Educator

calendarEducator since 2013

starTop subjects are Math, Science, and Literature

If 2i is one zero of this function, then its conjugate, - 2i, is also zero of this function (this is because the function is a polynomial with real coefficients.)

This means,...

(The entire section contains 98 words.)


text:
# Substituting Integration with trigonometric function

## Homework Statement

$\int_{1}^{5}\sqrt{4-(x-3)^2}dx$

## The Attempt at a Solution

Not really a homework. Just curious.

Let $x-3=2sin u$
$x=2sin u+3$

Now limit change,
when x=1, u = arcsin (-1)
when x=5, u = arcsin (1)

Since there are infinitely many solution of arcsin (-1) and arcsin (1), How do we know which ones to choose?

Thank you very much

Last edited:

$\int_{1}^{5}\sqrt{4-(x-3)^2}dx$

You have to write itex for the Latex to work, not tex. And the ending tag is /itex with a forward slash, not \itex with a backward slash.

There are not infinitely many solutions to $sin^{-1}(-1)$ and $sin^{-1}(1)$. The range of $sin^{-1}(x)$ is $[-\frac{π}{2},\frac{π}{2}]$.

EDIT: While trigonometric substitution is a valid way to solve this definite integral, you can also solve the problem by thinking about what the graph of $y=\sqrt{4-(x-3)^{2}}$ is, and remembering that a definite integral is the area between the curve and the x-axis.

Last edited:
There are not infinitely many solutions to $sin^{-1}(-1)$ and $sin^{-1}(1)$. The range of $sin^{-1}(x)$ is $[-\frac{π}{2},\frac{π}{2}]$.

Why is that? can't it be [3∏/2, 5∏/2]? or let's say [-∏/2 , 5∏/2] ?

There are not infinitely many solutions to $sin^{-1}(-1)$ and $sin^{-1}(1)$. The range of $sin^{-1}(x)$ is $[-\frac{π}{2},\frac{π}{2}]$.

EDIT: While trigonometric substitution is a valid way to solve this definite integral, you can also solve the problem by thinking about what the graph of $y=\sqrt{4-(x-3)^{2}}$ is, and remembering that a definite integral is the area between the curve and the x-axis.

I know. I can solve this integral by modelling it as a semi circle and find the area.

But here, I am curious about the trigonometric substitution.

I'm not sure "why" exactly. But if I had to guess I'd say just because. That's the way the inverse sine function was defined. It was given a restricted range. I'm not sure you need a reason why since it's in the definition of the inverse sine function.

EDIT: You can use $\frac{3π}{2}$ as your lower limit of integration and $\frac{5π}{2}$ as your upper limit if you want. You'll get the same answer since $4cos^{2}u$, the integrand you end up with after the substitution, has a period of $π$.

Last edited:
Ray Vickson
Homework Helper
Dearly Missed

## Homework Statement

$\int_{1}^{5}\sqrt{4-(x-3)^2}dx$

## The Attempt at a Solution

Not really a homework. Just curious.

Let $x-3=2sin u$
$x=2sin u+3$

Now limit change,
when x=1, u = arcsin (-1)
when x=5, u = arcsin (1)

Since there are infinitely many solution of arcsin (-1) and arcsin (1), How do we know which ones to choose?

Thank you very much

When you change variables to $x = 3 + 2 \sin(t)$ you can see directly that $x$ ranges from 1 to 5 when $t$ ranges from $-\pi/2 \text{ to } \pi/2.$ We don't need to bother with different branches of the arcsin function; in fact, we can forget about arcsin completely----just look at the original requirements.

BTW: it is perfectly OK to use "[tex ]" and "[/tex ]" (no spaces); that will give you a displayed result, like $$\int_1^5 \sqrt{4 - (x-3)^2} \, dx,$$ instead of the in-line result you get when using "[itex ]" and "[/itex ]", which would write the same expression as $\int_1^5 \sqrt{4 - (x-3)^2} \, dx.$

RGV

SammyS
Staff Emeritus
Homework Helper
Gold Member
...

Now limit change,
when x=1, u = arcsin (-1)
when x=5, u = arcsin (1)

Since there are infinitely many solution of arcsin (-1) and arcsin (1), How do we know which ones to choose?

Thank you very much
BTW, there are not infinitely many solutions for arcsin(-1) and arcsin(1).

The arcsine function is a perfectly well-defined function for which arcsin(-1) = -π/2 and arcsin(1) = π/2 .

However, each of the following two equations do have infinitely many solutions.
$1=2\sin(u)+3$

$5=2\sin(u)+3$
As Ray V. mentioned, you don't need to consider all of those solutions for this problem.

Alright. Thank you so much, you guys.


text:
# Here we have given NCERT Solutions for Class 6 Maths Chapter 11 Algebra Ex 11.4.

• Algebra Class 6 Ex 11.1
• Algebra Class 6 Ex 11.2
• Algebra Class 6 Ex 11.3
• Algebra Class 6 Ex 11.5

 Board CBSE Textbook NCERT Class Class 6 Subject Maths Chapter Chapter 11 Chapter Name Algebra Exercise Ex 11.4 Number of Questions Solved 3 Category NCERT Solutions

## NCERT Solutions for Class 6 Maths Chapter 11 Algebra Ex 11.4

Ex 11.4 Class 6 Maths Question 1.
Answer the following:
(a) Take Sarita’s present age to be y years

• What will be her age 5 years from now?
• What was her age 3 years back?
• Sarita’s grandfather is 6 times her age. What is the age of her grandfather?
• Grandmother is 2 years younger than grandfather. What is grandmother’s age?
• Sarita’s father’s age is 5 years more than 3 times Sarita’s age. What is her father’s age?

(b) The length of a rectangular hall is 4 metres less than 3 times the breadth of the hall. What is the length, if the breadth is b metres?
(c) A rectangular box has height h cm. Its length is 5 times the height and breadth is 10 cm less than the length. Express the length and the breadth of the box in terms of the height.
(d) Meena, Beena and Leena are climbing the steps io the hill top. Meena is at step s, Beena is 8 steps ahead and Leena 7 steps behind. Where are Beena and Meena? The total number of steps to the hill top is 10 less than 4 times what Meena has reached. Express the total number of steps using s.
(e) A bus travels at v km per hour. It is going from L>aspur to Beespur. After the bus has travelled 5 hours, Beespuris still 20 km away. What is the distance from Daspur to Beespur? Express it using v.
Solution:
(a) Let Santa’s present age be y years.

• Her age 5 years from now = (y + 5) years.
• Her age 3 years back = (y – 3) years.
• Since Sarita’s grandfather’s age is 6 times that of Sarita’s age.
∴ Her grandfather’s age = 6y years.
• Since grandmother is 2 years younger than grandfather. Therefore,
Grandmother’s age = (6 y – 2) years.
• Since Sarita’s father’s age is 5 years more than 3 times Sarita’s age.
Therefore, her father’s age = (3y + 5) years.

(b) Let the breadth of the hall be b metres
Since its length is 4 metres less than 3 times the breadth of the hall.
∴ Length of the hall = (3b – 4) metres
(c) Let the height of the rectangular box = h cm
It is given that its length is 5 times the height and breadth is 10 cm less than the length. Therefore,
Its length = 5h cm
and, breadth = (5h-10) cm
(d) Let Meena be at step s while climbing the steps to the hill top.
Since Beena is 8 steps ahead and Leena 7 steps behind Meena.
∴ Beena is at step (s + 8) and Leena is at step (s – 7)
Also, the total number of steps to the hill top is 10 less than 4 times what Meena has reached. .
∴ Total number of steps to the hill top = 4s-10
(e) Speed of the bus = v km per hour
Distance travelled by the bus in 5 hours = 5v km
According to question,
Distance from Daspur to Beespur
= Distance travelled by bus in 5 hours +20 km
= 5km +20 km = (5v +20) km.

Ex 11.4 Class 6 Maths Question 2.
Change the following statements using expressions into statements in ordinary language.
(For example, Given Salim scores r runs in a cricket match, Nalin scores (r +15) runs. In ordinary language-Nalin scores 15 runs more than Salim.)
(a) A notebook costs ₹ p.A book costs ₹ 3p.
(b) Tony puts q marbles on the table. He has 8 q marbles in his box.
(c) Our class has n students. The school has 20n students.
(d) Jaggu is z years old. His uncle is 4z years old and his aunt is (4z – 3) years old.
(e) In an arrangement of dots there are r rows. Each row contains 5 dots.
Solution:
(a) A book costs 3 times the cost of a notebook.
(b) Tony’s box contains 8 times the marbles on the table.
(c) Total number of students in the school is 20 times that of our class.
(d) Jaggu’s uncle is 4 times older than Jaggu and Jaggu’s aunt is 3 years younger than his uncle.
(e) The number of dots in a row is 5 times the number of rows.

Ex 11.4 Class 6 Maths Question 3.
(a) Given, Munnu’s age %p be x years, can you guess what (x – 2) may show?
Can you guess what (x + 4) may show? What (3x + 7) may show?
(b) Given Sara’s age today to be y years. Think of her age in the future or in the past. What will the following expression indicate?
y + 7, y-3, y + 4$\frac { 1 }{ 2 }$, y – 2$\frac { 1 }{ 2 }$.
(c) Given n students in the class like football, what may 2n show? What may $\frac { n }{ 2 }$ show?
Solution:
(a) (x – 2) may show the age of his younger sister.
(x + 4) may show the age of his elder brother.
(3x + 7) may show the age of his grandfather.
(b) The expressions (y + 7), (y + 4$\frac { 1 }{ 2 }$) may indicate Sara’s age in future.
The expressions (y – 3), (y – 2$\frac { 1 }{ 2 }$) may indicate Sara’s past age.
(c) The expression 2n may show the number of students who like hockey. The expression $\frac { n }{ 2 }$ may show the number of students who like basketball.

We hope the NCERT Solutions for Class 6 Maths Chapter 11 Algebra Ex 11.4 help you. If you have any query regarding NCERT Solutions for Class 6 Maths Chapter 11 Algebra Ex 11.4, drop a comment below and we will get back to you at the earliest.


text:
## Error message

• Notice: Undefined index: field_poster in include() (line 39 of /home/it/www/www-icts/sites/all/themes/riley/templates/views/calendar/views-view-fields--calendar--day.tpl.php).
• Notice: Trying to get property of non-object in include() (line 39 of /home/it/www/www-icts/sites/all/themes/riley/templates/views/calendar/views-view-fields--calendar--day.tpl.php).
• Notice: Undefined index: field_poster in include() (line 39 of /home/it/www/www-icts/sites/all/themes/riley/templates/views/calendar/views-view-fields--calendar--day.tpl.php).
• Notice: Trying to get property of non-object in include() (line 39 of /home/it/www/www-icts/sites/all/themes/riley/templates/views/calendar/views-view-fields--calendar--day.tpl.php).
• Notice: Undefined property: views_plugin_style_default::$date_info in include() (line 31 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php). • Notice: Trying to get property of non-object in include() (line 31 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php). • Notice: Undefined property: views_plugin_style_default::$date_info in include() (line 32 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php).
• Notice: Trying to get property of non-object in include() (line 32 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php).
• Notice: Undefined property: views_plugin_style_default::\$date_info in include() (line 34 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php).
• Notice: Trying to get property of non-object in include() (line 34 of /home/it/www/www-icts/sites/all/themes/riley/templates/date-views-pager--calendar.tpl.php).
Friday, February 23, 2018
Seminar
21 August 2017, 16:00 to 21 August 2018, 17:30
Emmy Noether Seminar Room, ICTS Campus, Bangalore
Quantum Hall nematics are states that combine the topological order of the quantum Hall effect with the orientational ordering of nematics. I will describe how discrete nematics arise in multi-valley...more
23 February 2018, 11:15 to 12:15
Emmy Noether Seminar Room, ICTS Campus, Bangalore
In this talk I'll talk about Matrix Models and application of Complex Langevin Dynamics to study them. I'll begin with introducing Matrix Models, and how they appear in various physics problems. I'll...more


text:
# Entropy in an isobar transformation

1. Jul 13, 2012

### alialice

What is the variation of entropy in an isobar transformation?

2. Jul 13, 2012

### Andrew Mason

Are we dealing with an ideal gas? If so, we can work it out from: TdS = dU + PdV

If P is constant then:

$\Delta S = \int \frac{dU}{T} + P\int \frac{dV}{T}$

If this is an ideal gas where PV = nRT, then we can substitute nRT/V for P (or nRdT/P for dV) and nCvdT for dU. Can you work that out?

AM

3. Jul 13, 2012

### alialice

Yes, it's just so!
Thank you very much! :)


text:
x

留言板

 引用本文:
 Citation:

Quantum secure direct communication scheme with identity authentication

Zhou Xian-Tao, Jiang Ying-Hua
PDF
HTML
• 摘要

针对传统量子安全直接通信方案中需提前假设通信双方合法性的问题, 提出一种带身份认证的基于GHZ态(一种涉及至少三个子系统或粒子纠缠的量子态)的量子安全直接通信方案. 该方案将GHZ态粒子分成三部分, 并分三次发送, 每一次都加入窃听检测粒子检测信道是否安全, 并在第二次发送的时候加入身份认证, 用以验证接收方的身份, 在第三次发送完粒子之后, 接收方将所有检测粒子抽取出来, 之后对GHZ态粒子做联合测量, 并通过原先给定的编码规则恢复原始信息. 本方案设计简单、高效, 无需复杂的幺正变换即可实现通信. 安全性分析证明, 该方案能抵御常见的内部攻击和外部攻击, 并且有较高的传输效率、量子比特利用率和编码容量, 最大的优势在于发送方发送信息的时候不需要假设接收方的合法性, 有较高的实际应用价值.

Abstract

Aiming at the problem that traditional quantum secure direct communication schemes need to assume the legitimacy of both parties in advance, a GHZ state (a quantum state involving at least three subsystems or particles entanglement) based quantum secure direct communication scheme with identity authentication is proposed. The scheme first encodes GHZ state particles into eight types, divides the particles into three parts, and sends them three times. Each time, eavesdropping is added to detect whether the particle detection channel is secure, and identity authentication is added when sending particles for the second time to verify the identity of the receiver. Specifically, according to the value of the ID key IDA, the specified particles (such as $|0\rangle$ particles or $|+ \rangle$ particles) are found in the two particles. Then their positions are marked as L and they traverse down until all the identity keys are traversed, obtaining a position sequence L. After sending the two particles to Bob for eavesdropping detection, Bob measures the L position of the two particles on the corresponding basis according to the value of the identity key, the measurement results are coded, and compared with the identity key IDA to complete the identity authentication. After sending the particles for the third time. the receiver extracts all the detected particles, and then the GHZ state particles are jointly measured, and the original information is recovered through the previously given coding rules, so as to realize quantum safe direct communication. The design of this scheme is simple and efficient, and the communication can be realized without complex unitary transformation. The correctness analysis proves that the scheme is correct in theory. The security analyses of interception/measurement retransmission attack, Trojan horse attack, denial of service attack, auxiliary particle attack, identity impersonation attack, and other attacks prove that the scheme can resist common internal attacks and external attacks, and solve the problem of information leakage. The transmission efficiency of the scheme is 1, the quantum bit utilization is 1, and the coding capacity is a quantum state carrying 3 bits of information. Compared with some previous schemes, this scheme has obvious advantages in these three aspects. The biggest advantage is that the sender does not need to assume the legitimacy of the receiver when sending information, so it has high practical application value.

作者及机构信息

通信作者: 江英华, 250364629@qq.com
• 基金项目: 陕西省教育厅科研专项科学研究计划(批准号: 19JK0889)资助的课题.

Authors and contacts

Corresponding author: Jiang Ying-Hua, 250364629@qq.com
• Funds: Project supported by the Special Scientific Research Plan of Shaanxi Provincial Department of Education, China (Grant No. 19JK0889).

施引文献

• 文章访问数:  285
• PDF下载量:  7
• 被引次数: 0
出版历程
• 收稿日期:  2022-08-24
• 修回日期:  2022-10-03
• 上网日期:  2022-10-19
• 刊出日期:  2023-01-20

带身份认证的量子安全直接通信方案

• 西藏民族大学信息工程学院, 咸阳　712000
• 通信作者: 江英华, 250364629@qq.com
基金项目: 陕西省教育厅科研专项科学研究计划(批准号: 19JK0889)资助的课题.

/


text:
# Why would spacetime curvature cause gravity?

It is fine to say that for an object flying past a massive object, the spacetime is curved by the massive object, and so the object flying past follows the curved path of the geodesic, so it "appears" to be experiencing gravitational acceleration. Do we also say along with it, that the object flying past in reality exeriences NO attraction force towards the massive object? Is it just following the spacetime geodesic curve while experiencing NO attractive force?

Now come to the other issue: Supposing two objects are at rest relative to each other, ie they are not following any spacetime geodesic. Then why will they experience gravitational attraction towards each other? E.g. why will an apple fall to earth? Why won't it sit there in its original position high above the earth? How does the curvature of spacetime cause it to experience an attraction force towards the earth, and why would we need to exert a force in reverse direction to prevent it from falling? How does the curvature of spacetime cause this?

When the apple was detatched from the branch of the tree, it was stationary, so it did not have to follow any geodesic curve. So we cannot just say that it fell to earth because its geodesic curve passed through the earth. Why did the spacetime curvature cause it to start moving in the first place?

-
I have always wondered about this (and related). This is so brushed aside in populist explanations! –  GreenAsJade Mar 11 '14 at 12:06

To really understand this you should study the differential geometry of geodesics in curved spacetimes. I'll try to provide a simplified explanation.

Even objects "at rest" (in a given reference frame) are actually moving through spacetime, because spacetime is not just space, but also time: apple is "getting older" - moving through time. The "velocity" through spacetime is called a four-velocity and it is always equal to the speed of light. Spacetime in gravitation field is curved, so the time axis (in simple terms) is no longer orthogonal to the space axes. The apple moving first only in the time direction (i.e. at rest in space) starts accelerating in space thanks to the curvature (the "mixing" of the space and time axes) - the velocity in time becomes velocity in space. The acceleration happens because the time flows slower when the gravitational potential is decreasing. Apple is moving deeper into the graviational field, thus its velocity in the "time direction" is changing (as time gets slower and slower). The four-velocity is conserved (always equal to the speed of light), so the object must accelerate in space. This acceleration has the direction of decreasing gravitational gradient.

Edit - based on the comments I decided to clarify what the four-velocity is:

4-velocity is a four-vector, i.e. a vector with 4 components. The first component is the "speed through time" (how much of the coordinate time elapses per 1 unit of proper time). The remaining 3 components are the classical velocity vector (speed in the 3 spatial directions).

$$U=\left(c\frac{dt}{d\tau},\frac{dx}{d\tau},\frac{dy}{d\tau},\frac{dz}{d\tau}\right)$$

When you observe the apple in its rest frame (the apple is at rest - zero spatial velocity), the whole 4-velocity is in the "speed through time". It is because in the rest frame the coordinate time equals the proper time, so $\frac{dt}{d\tau} = 1$.

When you observe the apple from some other reference frame, where the apple is moving at some speed, the coordinate time is no longer equal to the proper time. The time dilation causes that there is less proper time measured by the apple than the elapsed coordinate time (the time of the apple is slower than the time in the reference frame from which we are observing the apple). So in this frame, the "speed through time" of the apple is more than the speed of light ($\frac{dt}{d\tau} > 1$), but the speed through space is also increasing.

The magnitude of the 4-velocity always equals c, because it is an invariant (it does not depend on the choice of the reference frame). It is defined as:

$$\left\|U\right\| =\sqrt[2]{c^2\left(\frac{dt}{d\tau}\right)^2-\left(\frac{dx}{d\tau}\right)^2-\left(\frac{dy}{d\tau}\right)^2-\left(\frac{dz}{d\tau}\right)^2}$$

Notice the minus signs in the expression - these come from the Minkowski metric. The components of the 4-velocity can change when you switch from one reference frame to another, but the magnitude stays unchanged (all the changes in components "cancel out" in the magnitude).

-
Can you comment on why the four-velocity is always the speed of light? –  GreenAsJade Mar 11 '14 at 12:07
@GreenAsJade: The four-velocity is commonly defined as $u^i = \frac{dx^i}{d\tau}$. Written as a four vector, it looks like $\vec{u} = \gamma (c, \mathbf{v})$, with $\gamma = (1-v^2/c^2)^{-1/2}$. Its length squared is then $\gamma^2 (c^2-v^2)$, which is equal to $c^2$. –  Javier Mar 11 '14 at 14:19
Does this mean that particles passing through space in the speed of light does not pass through time? Do electrons not have an age? –  Pål GD Mar 11 '14 at 23:35
@PålGD: Correct, particles moving at the speed of light do not age. Thus the "time delation" mentioned in space travel things, where they travel a long way but not much time passes. –  Mooing Duck Mar 12 '14 at 0:36
@AlanSE The apple is moving through time at light speed only in the reference frame where the apple is at rest (spatially). In some other reference frame (where the apple has some spatial velocity) its speed through time is slower. The four-velocity is a vector which has 4 components. All these components can vary between frames, but the magnitude of this 4-vector remains unchanged (always equals c). –  mpv Mar 12 '14 at 6:00

When the apple was detatched from the branch of the tree, it was stationary, so it did not have to follow any geodesic curve.

Even when at rest in space, the apple still advances in space-time. Here is a visualization of the falling apple in distorted space-time:

-
I've always visualized it as the apple being held by the stem at the top of a valley, the bottom of which is the Earth's gravity well / center of mass. The stem breaks and the apple rolls down the hill into the "valley's" gravity. The animation is very good, but I'm left wondering why space-time is curving away from the direction of earth's gravity. (I think I'm interpreting that correctly because the stem/branch force arrows point opposite from the center of the earth, and that direction is shown to be the center of the curve of the spacetime graph.) –  Patrick M Mar 12 '14 at 16:56
This is a great video... –  SS-3.1415926535897932384626433 Mar 13 '14 at 2:49

As to the first paragraph, gravity shows up as geodesic deviation; initially parallel geodesics do not remain parallel.

Since, for a freely falling particle, the proper acceleration (the reading of an accelerometer attached to the particle) is zero, it is correct to say that a particle whose worldline is a geodesic has no proper acceleration.

But it is not correct to say that a freely falling particle has no coordinate acceleration.

Regarding the second paragraph, if a particle's wordline is not a geodesic, the particle will have a proper acceleration, the particle's accelerometer will not read zero. Two particles that are preventing from falling towards one another will have weight.

Regarding the third paragraph, I think you need to sharpen your conception of worldines and geodesics. If a particle exists, it has a worldline and the worldline of a particle that is free to fall is a geodesic even if the particle is momentarily stationary.

-

Not everything needs to follow geodesic Spacetime curvature available to it. With external force, you can prevent a particle from following Spacetime curvature. Only "freely" falling particles follow Spacetime curvature available to them. So, when you see a stationary object not following Spacetime curvature, it's because an external force is preventing it from going to it's inertial trajectory... Means, it's not in "Free Fall".

Come to Apple: In terms of Spacetime, nothing is in rest. An Apple, when attached with tree, is also in motion. But, the motion exist fully in time with zero space component. This motion is NOT according to Spacetime curvature available to it because external forces holding root of Apple oppose it at microscopic level. When these external forces stop working, Apple starts to follow Spacetime curvature which converts time component of motion to space component. That's why Apple's acceleration is merely inertial motion. You can see removal of time component of motion in Gravitational Time Dilation.

-

Imagine you are on the northern hemisphere on Earth (assuming it's a perfect sphere).

Now go north with constant speed: you can just go straight north you don't need to steer.

Now go east with constant speed: this is something different now, in order to remain on the same latitude circle you must steer northwards constantly. If you don't see why, try to imagine you are doing it on the 89° latitude circle. If you stop steering, you begin to go "straight" along a geodesic and "fall" towards the equator.

This correction force depends on where you are and which direction you are going (and wish to remain on a "coordinate-straight" path), it's a linear map that maps your velocity into force. It's called the Christoffel-symbols. It's a property of your chosen coordinate system and the geometry of the space-time.

Now in reality on Earth you are in a coordinate system where the coordinates given by the latitude, longitude and altitude and time. Your 4-velocity in space-time is constant $c$. If you stand still, you go straight in the time direction. But in order to keep this four velocity, you feel an upwards force from the floor, this is the effect of the Christoffel-symbols. If you lose the floor your trajectory in space time will be a geodesic and you will fall.

-

## protected by Qmechanic♦Mar 12 '14 at 11:52

Thank you for your interest in this question. Because it has attracted low-quality answers, posting an answer now requires 10 reputation on this site.

Would you like to answer one of these unanswered questions instead?


text:
File Exchange

## Plot2LaTeX

version 1.2.0.0 (9.79 KB) by Jan de Jong

### Jan de Jong (view profile)

Exports a figure as a pdf file in vector format for inclusion into LaTeX.

Updated 20 Apr 2016

PLOT2LATEX saves a Matlab figure as a pdf file in vector format for inclusion into LaTeX. Requires free and open-source vector graphics editor Inkscape. It invokes Inkscape to save the text, labels, legends, titles, etc. to be incorporated into LaTeX. This allows a true LaTeX font and scripts.
Use of the 'PDFLatex' output profile does not directly support psfrag (and therefore laprint or matlabfrag). Plot2LaTex uses the features of Inkscape to export vector image to pdf with supporting pdf_tex file for text placement. Plot2LaTeX supports transparency.
Plot2LaTeX requires Matlab version 2014b or higher.
Plot2Latex requires Inkscape.

David Nelson

### David Nelson (view profile)

Hi Jan,
I love the function so far, however I'm getting a few minor issues. The first is that when I attempt to place the figure in a wrapfigure environment, I get an 'improper alphabetic constant'. The code I'm using is here:
\begin{figure}[H]
\centering
\def\svgwidth{0.6\linewidth}
\input{Temp_n7.pdf_tex}
\caption{Temperature Distribution for Fine Grid}
\label{fig:Temp_n7}
\end{figure}

Another issue I get is that when I add a colorbar to surface plots the text attached to the colorbar is automatically inserted into the middle of the colorbar instead of to the right. Do you have any suggestions for fixing or working around this?

Ricardo Guerrero

Rafael Clemente

Pedro Pedrosa

### Pedro Pedrosa (view profile)

Any ideas on what might be causing the problem reported by Philipp, "Unrecognized property 'TickLabelInterpreter' for class 'matlab.ui.controls.AxesToolbar'."? I'm having the same problem and would appreciate any help solving this.

Muhammad Haziq Kamarul Azman

.

Samuel Schneider

### Samuel Schneider (view profile)

@All with version 2018b or newer:
Adding a sgtitle (title over all subplots) won't work as it has no position property.
A workaround is using a TextBox in your figure, like

h = figure();

This prints the text at the same position as a sgtitle would.
Cheers!

Markue

Jan de Jong

### Jan de Jong (view profile)

Dear Philip,
Thank you for your question. I think you can find my email adress on my profile page. Could you send your figure there?
Regards,
Jan

Philipp Buck

### Philipp Buck (view profile)

in a second run the errormsg is:
Unrecognized property 'TickLabelInterpreter' for class 'matlab.ui.controls.AxesToolbar'.

Error in Plot2LaTeX2>ChangeInterpreter (line 464)
Obj(i).TickLabelInterpreter = Interpreter;

Error in Plot2LaTeX2 (line 156)
ChangeInterpreter(h,'Latex')

Philipp Buck

### Philipp Buck (view profile)

Hi Jan de Jong,
I have the some problem as Jo.
I am using Linux and the 2019a Matlab.

The first thing i had to change is a change from a backslash to a normals slash in the path of the result. (Line 359).
The second issue is that the status bar stays visible even if the skript is ended.
Now I get an output from inkscape.
But as Jp only with the X000-XNNN Labels.
Before running that command: plot2latex(h, output) everthing looks fine, butafter running that command, the figure in matlab also has the wrong labels.
If i start plot2latex again from commandlinei get:

Unrecognized method, property, or field 'XTickLabel' for class 'matlab.ui.controls.AxesToolbar'.

Error in Plot2LaTeX (line 227)
n_Str = length(AxeObj(i).XTickLabel);

If you send me your mail adress i would send to the figure.

Jan de Jong

### Jan de Jong (view profile)

Dear Jo,
Too bad it is not working for you. I cannot help you with Linux itself as I am not a user. But to me it seems that Matlab and Inkscape are communicating since the proper files are produced. So I expect that the problem lies somewhere else. Could it be that the figure is large such that matlab automatically switches to bitmap format? Could you send me the figure (.fig) you are testing? Hopefully can figure this out.

jo

### jo (view profile)

Hi Jan,
Thanks for the function.
Sadly, for me the replacement with the original text does not work at all.
All produced formats (svg, pdf) show X000 and I can't find any text in the pdf_tex either. I am using 2017a on linux and also tried the following: https://gist.github.com/diegoferigo/1c0a892e9f952be757e080e116e6cd6f
I tried to debug the function and the text is read-in but somehow the replacement does not work. No errors are produced by plot2latex

Olivier Caytan

Waleed Alasmary

Florian

### Florian (view profile)

Hi Jan,
thank you for with extremely helpful package! I have a problem with the name of the y-axis: it is positioned too far on the left side because of the long label names X0001, X0002, ...
Is it possible to use shorter labels so the distance between the y-axis and the y-axis name is normal?
Thank you!

Christian Koch

### Christian Koch (view profile)

Hey Jan,
Thanks for this script! It really helps to create a LaTeX usable Plot directly from MatLab. But i ran into some issues using your script.
The first problem appears when i am saving with a legend. There are 10 entries in my legend and the first one is always missing. Additionally the legend box is too small so the text is sticking out of the right sight.
Is there already a solution for this problem?

Jan de Jong

### Jan de Jong (view profile)

Hey Heleen,

Thanks for your comments. Regarding your question, if you use 2015b or higher you can use the solution of Ben Blaser, and posted below on 8 August 2016. Let me know if it works.

Heleen Fehervary

### Heleen Fehervary (view profile)

Hi Jan,
I have exponents in my xaxis (*10^-4) and these are lost with Plot2Latex. Is there a solution for this?

Heleen Fehervary

Very nice!

Dominik Puckert

### Dominik Puckert (view profile)

Thank you, Jan! Renderer and reducing the contour levels (thus size) fixed the problem. Keep up the good work!

Jan de Jong

### Jan de Jong (view profile)

Hey Dominik, Good to know that you like it. The problem arises that Matlab chooses its on renderer based on the size of the image. So what you could do is use the options to specify the renderer. See the help file how to do this. Be warned this will take a lot of time, therefore it is not set as the default.

options.Renderer = 'painters';
Plot2LaTeX(gcf, 'Test_painters',options)

Let me know if it works.

Dominik Puckert

### Dominik Puckert (view profile)

Good job! Works great for me exept for contours containing too much data. With R2017a this does not work for me:

Z = peaks(200);
contourf(Z,10)
Plot2LaTeX(gcf, 'Test')

It gives a bitmap-type .svg without recognizing the text anymore. However, Z = peaks(20) works fine! Do you have any idea how to fix this problem?

Peter Hurt

### Peter Hurt (view profile)

Works perfectly!
Had to change the Inkscape directory in the function but then it worked. Thanks!

Volker P.

### Volker P. (view profile)

For me it works perfect. Thank you!

Tobias Ammann

### Tobias Ammann (view profile)

Hello Jan de Jong,
yes that is correct. The polarplot function does not use cartesian axis. This is why matlab2tikz does not work too.
I got the script working without a legend by defining:

Labels = {}; right at the beginning of the script
and changing line 318 to if ~isempty(FoundLabelText) && ~isempty(Labels)

Well unfortunately i need the legend. But the result looks nice. Even with the polarplot axes.

PS: I use Matlab 2017a.

Jan de Jong

### Jan de Jong (view profile)

Hey Tobias, Sadly I was not able to reproduce your error as I work on an older matlab version. The polarplot function was introduced in 2016. I suspect they introduced a new axis type which requires some work to add. The older 'polar' works normally with the Plot2LaTeX function. Sorry that I will not able to help you in short notice.

Tobias Ammann

### Tobias Ammann (view profile)

Hello,
i have a problem using your skript. I tried to export a polar plot with and without a legend.
Unfortunately i get several errors.

with legend -> Expected one output from a curly brace or dot indexing expression, but there were 0 results.
Error in Plot2LaTeX (line 326)
'text-align:', Labels(iLabel).Alignment{1},...

without legend -> Undefined function or variable 'Labels'.

Error in Plot2LaTeX (line 321)
{Labels.LabelText},...

Any suggentions to solve this?

This is my minimal example to reproduce the error:

phi = linspace(0, 2*pi, 200);
polarplot(phi, sin(phi),'LineStyle', '-');
hold on
polarplot(phi, cos(phi),'LineStyle', '-.');
rlim([-1 1]);

%legend('bla' , 'blubb');
Plot2LaTeX(gcf , 'test');

Many Thanks!

Jan de Jong

### Jan de Jong (view profile)

Hey Laurenz,

Here is a solution which should work:

Include inside the for loop over all color bar object (before line 285) the following
% treat colorbar labels
iLabel = iLabel + 1;
Labels(iLabel).TrueText = ColObj(i).Label.String;
if isRightAx % if text is right aligned
Labels(iLabel).Alignment = PosAligmentSVG(1);
Labels(iLabel).Anchor = PosAnchSVG(1);
else % if text is left aligned
Labels(iLabel).Alignment = PosAligmentSVG(3);
Labels(iLabel).Anchor = PosAnchSVG(3);
end
Labels(iLabel).LabelText = LabelText(iLabel);
ColObj(i).Label.String = LabelText(iLabel);

And similarly in the restoration loop of the color bar (before Line 424)
iLabel = iLabel + 1;
ColObj(i).Label.String = Labels(iLabel).TrueText;

Laurenz Altenmüller

### Laurenz Altenmüller (view profile)

Hi Jan, I also have Mathias's colorbar label issue. Do you have a solution?

Murilo Marinho

Jan de Jong

### Jan de Jong (view profile)

Thanks Murilo for the comments. Could you send me your figure via email? Than I will take a look to see what is going on.

Murilo Marinho

### Murilo Marinho (view profile)

Hello! I'm having some trouble using this function. No error shows up, but final output .pdf file has the temporary labels, e.g. X20, instead of the real labels. Is there some workaround for this?
Thanks in advance, and nice script.

Daniel Bauer

MSleiman

### MSleiman (view profile)

Unlike in 'article' documentclass font is not well interpreted in 'IEEEtran.cls'...
Any thoughts why characters are not treated as Latex text in IEEEtran?

code for either options:
1- \documentclass[journal, onecolumn]{IEEEtran}
2- \documentclass[10pt]{article}

goldbattle

Nino

### Nino (view profile)

Works in general really well. thanks! Only thing I found: if you use "colorbar('eastoutside')", the alignment of the ticklabels is not correct in the svg output. any ideas? (R2016b)

Jan de Jong

### Jan de Jong (view profile)

Thanks Yukio Fukuzawa for the question. In my opinion the % sign (\% in latex) works quite well in Matlab -> Inkscape -> Latex. Can you send me an example in which it does not work?

Yukio Fukuzawa

### Yukio Fukuzawa (view profile)

Great work! Minor suggestion: the percent sign (%) needs to be escaped as well, otherwise it will result in invalid syntax for pdf_tex. (I know, this should be inkscape's job but currently it doesn't do it)

function strXML = EscapeXML(str)
% ESCAPEXML repaces special characters(<,>,',",&) -> (<,>,',",&)
escChar = {'&','<','>','''','"','%'};
repChar = {'&','<','>',''','"','\\%'};
strXML = regexprep(str,escChar,repChar);
end

Mathias

### Mathias (view profile)

Hey Jan,

thank you for this great work! I have one problem using your code with this script:
surf(peaks);
cb=colorbar;
cb.Label.String='$A_\mathrm{b}$';
cb.Label.Interpreter='latex';
Plot2LaTeX(gcf, 'test');

Everything runs normal (so no error or warning) but the result is the following (only if there is a label at the colorbar): In the generated PDF from Inkscape the Text still reads X000 and so on (As far as I understand your workflow no text should be present in the Inkscape generated PDF file).

I have an idea why this problem occurs: I assume Matlab saves the plot (or at least the text) in case of a present colorbar-label in another way than it does normally. One further indicator for that is that Inkscape apparently does not recognize the text labels (this is the reason why they are still in the inkscape exportet PDF file). Your script does also not recognize them because they are still labelled Xxyz in the .svg-file before the file is processed by Inkscape. One further thing I have noticed: Usually the PDF contains several pages (maybe the layers/groupings from the SVG-File?) but with the colorbar label enabled this is not the case.

I also noticed that the colorbar label is not replaced by an Xxyz string.

Do you have any ideas how this can be fixed?

I am using Matlab R2016b at the moment.

Greetings
Mathias

Jan de Jong

### Jan de Jong (view profile)

Hey Daniel,

Currently I am not able to access and modify the legend properties in a correct way. The ugly workaround used for vertical legends is not working for horizontal ones. Maybe in future releases of Matlab these properties can be fully controlled and this can be added to the Plot2Latex function.
Greetings,
Jan

Jan de Jong

### Jan de Jong (view profile)

Hey Zac,

That is indeed interesting, can you send me a sample fig, than I can try to figure out what is going on.

Regars,
Jan

Zac Giles

### Zac Giles (view profile)

Hi Jan,

I really like this package, its what I've been looking for for a while. I have found two places where it fails me though, and one failure lead to an interesting point on the other failure.
First thing I found was that the function crashes during the 'Restoring text in the .svg file', with the error:
Error in Plot2LaTeX (line 341)
StrCurrTemp = strrep(StrLine_old, ...
This is caused when I have titles spanning multiple lines within the plot, created by using sprintf and the newline character \n.
The second issue I have found is when trying to export uitables. plot2LaTeX doesn't try to turn the data in the tables into text (which is not a problem for me), but the problem I've found is that it doesn't fully populate the table with values. The interesting thing I found was when I have a multiline title, and it fails to run properly, the svg file that is left behind does have a fully populated table, but has the title X001, so somewhere between recreating the title, some of the svg is lost. I have tried exporting the table withought a header, but it seems as if plot2LaTeX still tries to create a header, and doesn't fully populate the table either. Sorry this comment has been so long, I didn't know how to explain it concisely. Let me know if you want some example files.

Zac Giles

Daniel S.

### Daniel S. (view profile)

Hello Jan, thank you for the great script! I have the same problems as Magnus Dam (05 Sep). Do you have a solution for legend frames in horizontal orientation?

jdruant

### jdruant (view profile)

Thank you Jan, great script!

Felix H.

### Felix H. (view profile)

Hello Jan,

I'm trying to use your function to convert a polar plot made with the mmpolar function (see https://de.mathworks.com/matlabcentral/fileexchange/38855-comprehensive-polar-plots). The figure contains labels with \circ and \pm symbols, which leads to errors when Plot2LaTeX is executed:

Warning: Error updating Text.

String must have valid interpreter syntax:
0\circ

Warning: Error updating Text.

String must have valid interpreter syntax:
15\circ

...

The resulting .pdf can not be included in a latex document.

Could you please tell me a solution to fix this problem?

Regards

Jan de Jong

### Jan de Jong (view profile)

Hey Magnus, Can you send me these figs? Than I can try to fix it.

Magnus Dam

### Magnus Dam (view profile)

I two problems with this script.
1. When I change the legend orientation to horizontal the legend frame becomes too small and it does not seem to get fixed by using \vspace{} or \hspace{} in the legend entry.
2. When I set the legend position (so Location becomes 'none') the figure can not be exported with Plot2LaTeX due to some error.

The first problem is the most problematic for me. Do anyone have a solution?

Florian Verbelen

### Florian Verbelen (view profile)

The problem mentioned by me has been solved by Jan de Jong. Thank you!

Jan de Jong

### Jan de Jong (view profile)

Hey Florian, can you maybe send an example to me?

Jan de Jong

### Jan de Jong (view profile)

Hey Florian,

Thanks for the comment. This is indeed not implemented in the code. Currently there is no simple work around. I am sorry, and will fix this in future release

Florian Verbelen

### Florian Verbelen (view profile)

Great script!

I just have one remark on contour plots. The positioning of the numbers next to the colorbar of the contourplot is bad (x-axis and y-axis labels are perfectly positioned). The only way to solve it is to manually replace them in Inkscape. Any solutions for that?

Jan de Jong

### Jan de Jong (view profile)

Hey Peachy Quant, Thanks for your questions. I am still working the axis exponent bug. Ben Blaser suggested this work-around (version 2015b or higher), the following code can be used. In earlier versions this axis exponent is not accessible. So I will get back to you on this.

---- Ben Blasers work ----
I put it just above

%% process options, first set default
yCorrFactor = 0.8; % default
% do not set default renderer

-------------
% check for Axis Exponents
if h.CurrentAxes.XAxis.Exponent
text(h.CurrentAxes.XLim(2), h.CurrentAxes.XAxis.Label.Position(2),...
['x $10^{\:{' num2str(h.CurrentAxes.XAxis.Exponent) '}}$'], ...
'VerticalAlignment', 'top','HorizontalAlignment', 'right', ...
'Interpreter', 'latex')
end

if h.CurrentAxes.YAxis.Exponent
text(0, 1, ...
['\times $10^{\:{' num2str(h.CurrentAxes.YAxis.Exponent) '}}$'], ...
'Units', 'Normalized', ...
'VerticalAlignment', 'bottom', 'HorizontalAlignment', 'left', ...
'Interpreter', 'latex')
end

PeachyQuant

### PeachyQuant (view profile)

I have had a problem in that in the graph produced, the y axis multiplier (i.e. x 10^-3 at the top of the y axis) is excluded. I then tried to prevent Matlab from using this format by using set(gca, 'YTickLabel', (num2str(round(get(gca,'YTick'),3)')) but this produced the error "Cell contents reference from a
non-cell array object.

Error in Plot2LaTeX (line 241)
Labels(iLabel).TrueText =
AxeObj(i).YTickLabel{j};"
when Plot2Latex was run. I then tried set(gca, 'YTickLabel', str2num(num2str(round(get(gca,'YTick'),3)'))) but this produced the same error.

Nevertheless, thanks for a great script!

Karmel Indych

Jakob

### Jakob (view profile)

How do I use it under Linux typ OS? I get the error that the inkscape.exe has not been found.

Saravana Kumar R

### Saravana Kumar R (view profile)

I get error when I the run the code:

Warning: No .pdf or .pdf_tex file produced, please check your Inkscape installation and specify installation directory correctly.
> In Plot2LaTeX (line 371)

If I add the add line suggested by @Nickolas I get another error:

Undefined function 'export' for input arguments of type 'char'.

Error in Plot2LaTeX (line 361)
export LANG=en_US.UTF-8;export LD_LIBRARY_PATH="";export DYLD_LIBRARY_PATH="";[status,cmdout] = system(['"', DIR_INKSC, '"',...

I have mentioned my Inkscape installations directories correctly.
Can someone tell me why am I getting these errors?

Jan de Jong

### Jan de Jong (view profile)

Thank you for the comment and thanks for the work around. We have tested the code only on one type of Unix system. We will look into this further.

Nickolas

### Nickolas (view profile)

Nice work! I had to modify the function slightly for it to work on my system ( Debian 8 Linux, Matlab 2015b ). There was a problem with the system call on line 361 of Plot2LaTeX---I see errors like: "/usr/bin/inkscape: /opt/matlab/R2015b/sys/os/glnxa64/libstdc++.so.6: version `GLIBCXX_3.4.20' not found (required by /usr/bin/inkscape)"

I added the following string at the beginning of the command on line 361: 'export LANG=en_US.UTF-8; export LD_LIBRARY_PATH=""; export DYLD_LIBRARY_PATH=""; ', and now it works great. FYI, in case others have this problem. Thanks again!

Jan de Jong

### Jan de Jong (view profile)

@Andrew Boysen, thank you for comments. Can you send me an email with your settings and documents? The demo should contain one page.

Andrew Boysen

### Andrew Boysen (view profile)

I also had to add quotes, as John mentioned. For some reason, my pdf_tex file calls for 11 pages, but my pdf only has 10 (or using the demo, it calls for 28 pages, but the pdf has 27). I haven't figured out what I have wrong yet.

Jan de Jong

### Jan de Jong (view profile)

@John Kurelek, Good to know you like the script. I will look into your comments and update this for the new release. Can you contact me via my profile, I have some questions about your second comment

John Kurelek

### John Kurelek (view profile)

Thanks for a great script! A couple of comments:
1) I ran into an issue with spaces within the figure directory when making the cmd call to Inkscape. This was fixed easily by adding quotes around DIR_FIG + filanme + .svg/.pdf on lines 333-338
2) For some reason, less than signs (<) did make into the svg file. Not sure why.

Jan de Jong

### Jan de Jong (view profile)

@Alton, thanks for the feedback. To answer your question, I need more information. Can you contact me using my profile?

Alton Vaughan

### Alton Vaughan (view profile)

I'm having trouble editing the .svg file in Inkscape and then exporting to .pdf for inclusion in my Latex file. Any tips?

Alton Vaughan

MSleiman

### MSleiman (view profile)

Great Work! Many Thanks...

Marijn Nijenhuis

### Marijn Nijenhuis (view profile)

Makes for a very quick workflow to get high-quality images in LaTeX. Now no longer need TikZ…

Marijn Nijenhuis

Ger Folkersma

### Ger Folkersma (view profile)

Great function for those who do not want the headaches of eps files combined with transparancy.
Replaces LaPrint for users of PDFTeX users.

 20 Apr 2016 1.2.0.0 - Made compatible for Unix systems - Added a waitbar - Corrected the help file - Fixed file names with spaces in the name. (Not advised to use in latex though) - Escape special characters in XML (<,>,',",&) -> (<,>,',",&) 27 Aug 2015 1.0.0.0 Changed logo 27 Aug 2015 1.0.0.0 Added Logo
##### MATLAB Release Compatibility
Created with R2014b
Compatible with any release
##### Platform Compatibility
Windows macOS Linux
##### Acknowledgements

Inspired by: LaPrint, matlabfrag


text:
# If a decision problem $A \in \text{NP}$ and there exists reduction so that $A \leq_p B$, for decision problem B, what can be deduced about B?

I think that it implies that B can be solved by a non-deterministic polynomial time or worse Turing machine, but I realise that there is possibly some greater result that I'm missing.

• This is a very vague question. $A$ might be in $\mathsf{P}$. In this case you have gained no information about $B$ at all. If $A$ is complete for $\mathsf{NP}$ then you know that $B$ is $\mathsf{NP}$-hard. But this is no proof that there is no deterministic polynomial time Turing machine deciding $B$. – ttnick May 17 '18 at 18:36

$B$ cannot be the language $\emptyset$ or the language $\Sigma^*$. Apart from that, you can conclude absolutely nothing about $B$.
So, the given condition doesn't rule out anything useful about $B$; just about everything remains possible. $B$ could be in $P$, or it could be in $NP$, it could be harder than anything in $NP$; you can't rule any of those out.


text:
#### Korbel, Jan; Rudolf Hanel and Stefan Thurner

Many stochastic complex systems are characterized by the fact that their configuration space doesn't grow exponentially as a function of the degrees of freedom. The use of scaling expansions is a natural way to measure the asymptotic growth of the configuration space volume in terms of the scaling exponents of the system. These scaling exponents can, in turn, be used to define universality classes that uniquely determine the statistics of a system. Every system belongs to one of these classes. Here we derive the information geometry of scaling expansions of sample spaces. In particular, we present the deformed logarithms and the metric in a systematic and coherent way. We observe a phase transition for the curvature. The phase transition can be well measured by the characteristic length r, corresponding to a ball with radius 2r having the same curvature as the statistical manifold. Increasing characteristic length with respect to size of the system is associated with sub-exponential sample space growth which is related to strongly constrained and correlated complex systems. Decreasing of the characteristic length corresponds to super-exponential sample space growth that occurs for example in systems that develop structure as they evolve. Constant curvature means exponential sample space growth that is associated with multinomial statistics, and traditional Boltzmann-Gibbs, or Shannon statistics applies. This allows us to characterize transitions between statistical manifolds corresponding to different families of probability distributions.


text:
# phi

0th

Percentile

##### Hubbell's phi

Hubbell's phi: counts of species abundances

Keywords
math
##### Usage
phi(x,addnames=TRUE)
unphi(freq, string="spp")
##### Arguments
x

Ecosystem vector; is coerced to class count

Boolean with default TRUE meaning to set the name of the $i$th element to the species with abundance $i$ if unique. Set to FALSE to suppress this, which is useful if the species names are long

freq

Frequency data (eg as returned by phi())

string

Character; species name to prepend (using NULL can be confusing)

##### Details

Function phi() coerces its argument to a count object and by default returns a named vector whose $i$th element is the number of species with $i$ individuals. The name of the $i$th element is the species with abundance $i$ if unique and empty otherwise. Function phi() is used by theta.prob().

Function unphi() does the reverse: given the output of phi(), it returns a corresponding count object. Note that species names are lost.

##### Note

The code for setting the names is a dog's breakfast

##### References

S. P. Hubbell 2001. “The Unified Neutral Theory of Biodiversity”. Princeton University Press.

preston

• phi
• unphi
##### Examples
# NOT RUN {
jj <- c(rep("oak",5) ,rep("ash",2),rep("elm",3),"pine","tea","yew")
a <- as.count(jj)

phi(a)
unphi(phi(a))   #should match 'a' except for species names (which are lost)

data(butterflies)


text:
## A Range Update Problem

View as PDF

Points: 7
Time limit: 2.0s
Memory limit: 64M

Author:
Problem type

You are given an array of length . There are updates of the form l r v, which means to add to all elements in the subarray .

You would like to know the array after these updates.

#### Input Specification

The first line will contain two integers, .

The second line will contain integers, , the initial array.

The next lines will each contain an update of the form described above. It is guaranteed and .

#### Output Specification

Output the array after these updates on a single line.

#### Subtasks

##### Subtask [80%]

No further constraints.

#### Sample Input

5 4
1 2 3 0 2
1 3 2
1 5 1
3 4 10
2 2 1

#### Sample Output

4 6 16 11 3

## Comments

There are no comments at the moment.


text:
# Diode Current Equation

Diode current equation expresses the relationship between the current flowing through the diode as a function of the voltage applied across it. Mathematically it is given as

Where,
I is the current flowing through the diode
I0 is the dark saturation current,
q is the charge on the electron,
V is the voltage applied across the diode,
η is the (exponential) ideality factor.
is the Boltzmann constant
T is the absolute temperature in Kelvin.
In this equation, two parameters require to be discussed in quite detail. They are

I0, the Dark Saturation Current
Dark saturation current indicates the leakage current density flowing through the diode in the absence of light (hence, ‘dark’). This parameter is the characteristic of the diode under consideration and indicates the amount of recombination which occurs within it. That is, I0 will be larger for a diode in which recombination rate is higher and vice versa. Further, its value is also seen to be directly proportional to the absolute temperature and inversely proportional to the material quality.
η, the (exponential) Ideality Factor
Ideality factor indicates the nearness with which the considered diode behaves with respect to the ideal diode. That is, if the diode under consideration behaves exactly as that of an ideal diode, then η will be 1. Its value increases from 1 as the difference between the behaviors of the ideal diode and diode under consideration increases: greater is the deviation, greater is the value of η.

The value of η is typically considered to be 1 for germanium diodes and 2 for silicon diodes. However, its exact value for the given diode depends on various factors like electron drift, diffusion, carrier recombination which occurs within the depletion region, its doping level, manufacturing technique and the purity of its materials. In addition, its value is also seen to vary with the value of current and voltage levels. Nevertheless, in most of the cases, its value is found to be within the range 1 to 2.
In forward biased condition, there will a large amount of current flow through the diode. Thus the diode current equation (equation 1) becomes

On the other hand, if the diode is reverse biased, then the exponential term in equation (1) becomes negligible. Thus we have

Now let us examine the mode the diode current equation takes its form when we have the diode operating at room temperature. In this case, T = 300 K, also, and . Thus

By reciprocating, one gets, 25.87 mV which is called thermal voltage. Thus the diode equation at room temperature becomes


text:
Song* , Chen** *** , and Sun**: Iris Ciphertext Authentication System Based on Fully Homomorphic Encryption

# Iris Ciphertext Authentication System Based on Fully Homomorphic Encryption

Abstract: With the application and promotion of biometric technology, biometrics has become more and more important to identity authentication. In order to ensure the privacy of the user, the biometrics cannot be stored or mani-pulated in plaintext. Aiming at this problem, this paper analyzes and summarizes the scheme and performance of the existing biometric authentication system, and proposes an iris-based ciphertext authentication system based on fully homomorphic encryption using the FV scheme. The implementation of the system is partly powered by Microsoft’s SEAL (Simple Encrypted Arithmetic Library). The entire system can complete iris authentication without decrypting the iris feature template, and the database stores the homomorphic ciphertext of the iris feature template. Thus, there is no need to worry about the leakage of the iris feature template. At the same time, the system does not require a trusted center for authentication, and the authentication is completed on the server side directly using the one-time MAC authentication method. Tests have shown that when the system adopts an iris algorithm with a low depth of calculation circuit such as the Hamming distance com-parison algorithm, it has good performance, which basically meets the requirements of real application scenarios.

Keywords: Fully Homomorphic Encryption , Iris Authentication , One-Time MAC , SEAL

## 1. Introduction

In recent years, the biometric authentication has gradually changed the way people live, the first of which is mobile payment. Compared with traditional password authentication, biological features are not easily lost or forgotten, while ensuring the uniqueness of authentication users. On the other hand, due to the high security of biological characteristics, once biometric data is stolen, it will have more serious consequences than other authentication methods. Therefore, it is very important to develop a solution to the biometric data with stronger protection force for the authentication system.

At present, researchers have put forward many different biological feature template protection schemes, which fall into two broad categories:

(1) Feature transformation method. This method transforms biometric data into random data using client-specific keys or passwords. Typical examples of this method are the Biohashing [1] and Robust Hashing [2]. This method is performance-wise, but it is no longer safe if the client-specific key is compromised.

(2) Biometric encryption method based on ECC. The method includes fuzzy vault (FV) [3] and fuzzy commitment [4]. Since this method requires strong restrictions on the accuracy of the authen¬tication, there are some practical and security issues.

Most of the existing authentication systems are based on the improvement of the above biometric template protection scheme, and there are few authentication systems based on fully homomorphic encryption. Because the fully homomorphic encryption can calculate the ciphertext arbitrarily without knowing the key, the decryption result is the same as the corresponding calculation for the plaintext. Therefore, it is necessary to guarantee the security of the biometric authentication system by combining the protection scheme of biometric template with fully homomorphic encryption technology. Blanton and Gasti [5] proposed a security protocol for iris and fingerprint, homomorphic encryption algorithm using DGK scheme [6], their scheme takes only 150 ms to complete 2048-bit binary iris feature template Hamming distance, but the homomorphic encryption ciphertext is shorter, it is difficult to guarantee the security. Kulkarni et al. [7] proposed an iris authentication scheme based on the SHE scheme [8]. For the 2048 iris, the execution time of the server was 58 seconds, but their agreement was only three rounds. Karabat and Namboodiri [9] proposed an authentication protocol that uses a pure threshold homing encryption, whose scheme runs on the server side for 6.1 seconds, and the client runs for 2.1 seconds. Therefore, the application of fully homomorphic encryption technology still needs to consider the actual problems such as performance and encryption data size. One might consider a simple way to store a hash template in a server through a one-way hash function, such as SHA3 [10]. However, because of the scanning noise, the biological characteristics are not identical in each capture, so it is impossible to have the same hash value, which is not feasible. The authors [11] proposed a biometric authentication method based on fully homomorphic encryption using Helib library. They exploit SIMD operations to split biometric plaintext to small size segments. However, we find the segmented ciphertext modulus de¬creases little and SIMD (single instruction multiple data) operations are cost. Therefore, the segmentation does not significantly improve the efficiency and safety of the system.

In this paper, the scheme of FV and SEAL library implements a design based on the iris features of fully homomorphic encryption ciphertext authentication system, it does not depend on reliable hardware, using one-time MAC authentication, can very good protect user iris feature template and complete the corresponding iris certification, greatly enhance the system security.

## 2. Certification Scheme Design

##### 2.1 FV Scheme

The FV scheme [12,13] is based on the polynomial ring R. It is used [TeX:] $$R=Z[x] /\left(x^{n}+1\right)$$. Not only that the scheme also involves several parameters. n is the degree of the polynomial and it is always a power of two. [TeX:] $$\lambda$$ is the safety parameter. q is a ciphertext modulus, which is used to reduce the coefficients of a ciphertext polynomial. t is a plaintext modulus, used to reduce the coefficients of a plaintext polynomial. Sample [TeX:] $$\alpha \leftarrow S$$ means that S is randomly selected uniformly from the finite set [TeX:] $$\alpha$$ and [TeX:] $$\chi$$ is an error probability distribution on R. [TeX:] $$\omega$$ is the basis of decomposition of the whole coefficient. [TeX:] $$\ell=\left\lfloor\log _{\omega} d\right\rfloor$$ means dividing the integer d into [TeX:] $$\ell$$ parts. The concrete algorithm of the scheme is as follows:

[TeX:] $$\operatorname{Kev} \operatorname{Gen}(\lambda): \text { Sample } s \leftarrow R_{2} \text { and output } s k=s . \text { sample } a_{1} \leftarrow R_{q} \text { and } e \leftarrow \chi, \text { output }(s k, p k)=\left(s,\left(a_{0}, a_{1}\right)\right)$$

[TeX:] \begin{aligned} &\text { EvKeyGen }(s k, \omega) \text { : For } i \in\{0, \ldots, \ell\}, \text { sample } a_{i} \leftarrow R_{q} \text { and } e_{i} \leftarrow \chi, \text { output } e v k=\left(\left(-\left(a_{i} s+e_{i}\right)+\omega^{i} s_{2}\right) m o d\right.\\ &\left.q, a_{i}\right) \end{aligned}).

[TeX:] \begin{aligned} &\text {Encrypt}(\boldsymbol{p k}, m): \operatorname{For} m \in R_{t} \text { let } \boldsymbol{p} \boldsymbol{k}=\left(a_{0}, a_{1}\right), \text { sample } u \leftarrow R_{2} \text { and } e_{1}, e_{2} \leftarrow \chi . \text { Compute } c_{0}=\left(\Delta m+a_{0} u\right.\\ &+e_{1} \text { ) } \bmod q \text { and } c_{1}=\left(a_{1} u+e_{2}\right) \text { mod } q . \text { Output } c t=\left(c_{0}, c_{1}\right) \end{aligned}

[TeX:] $$\text {Decrypt}(s k, c t): \text { Let } c t=\left(c_{0}, c_{1}\right)$$ and [TeX:] $$s k=s, \text { output } m^{\prime}=\left(\left(t / q\left(c_{0}+c_{1} s\right)\right) \bmod q\right) \bmod t$$

[TeX:] $$A d d\left(c t_{0}, c t_{1}\right): \text { Input } c t_{0}, c t_{1,} \text { output } c t_{0}+c t_{1}$$

[TeX:] $$\operatorname{Mul}\left(c t_{0}, c t_{1}\right): \text { Input } c t_{0}, c t_{1}, \text { output } c t_{0} \times c t_{1}$$

##### 2.2 Batching and Automorphism

Batching technique refers to the use of Chinese remainder theorem (CRT) and SIMD [14,15] to pack n numbers into a plaintext polynomial at a time, and to operate the polynomial is equivalent to a combination of the n number of the same operation (i.e., parallel).

The use of batching is conditional: plaintext mode t is prime and t = 1 (mod 2n). This means where t > 2n, which sometimes affects efficiency.

This condition ensures that the multiplicative group of the integer modulus t contains a subgroup with the number of elements 2n. That is: [TeX:] $$\zeta \in Z_{t} \mathrm{m}$$ make [TeX:] $$\zeta^{2 n}=1(\bmod t)$$, and for all 0 < m < 2n. The root of the 2n sub-primitive unit called the modulus t.

It is important to have such a primitive unit root, because the polynomial modulus [TeX:] $$x^{n}+1$$ can be decomposed into the product of the following factors at modulus t:

##### (1)
[TeX:] $$x^{n}+1=(x-\zeta)\left(x-\zeta^{3}\right) \ldots\left(x-\zeta^{2 n-1}\right)(\bmod t)$$

According to the CRT, the ring [TeX:] $$R_{t}$$ can be decomposed into:

##### (2)
[TeX:] $$\begin{array}{c} R_{t}=\frac{Z_{t}[x]}{\left(x^{n}+1\right)}=\frac{Z_{t}[x]}{\prod_{i=0}^{n-1}\left(x-\zeta^{2+1}\right)} \stackrel{C R \tau}{=} \prod_{i=0}^{n-1} \frac{Z_{t}[x]}{\left(x-\zeta^{2+1}\right)} \\ \cong \prod_{i=0}^{n-1} Z_{t}\left[\zeta^{2 t+1}\right] \cong \prod_{i=0}^{n-1} Z_{t} \end{array}$$

All of the isomorphisms are isomorphic on the ring, which means that both the addition and the multiplication structures are kept on both sides of the equation. The [TeX:] $$\prod_{i=0}^{n-1} Z_{t}$$ on the right, which can be expressed as [TeX:] $$Z_{t} \times Z_{t} \ldots \times Z_{t}$$, can also be regarded as an n-dimensional vector. So the addition of the two elements on the right needs to execute the addition of the n corresponding components. According to the isomorphism, the correspondence and the left are only the addition of the two polynomials on the ring [TeX:] $$R_{t}$$. The same multiplication is the same. Let [TeX:] $$\alpha_{i}=\zeta^{2 i+1}$$ have Decompose:

##### (3)
[TeX:] $$R_{t} \rightarrow \sum_{i=0}^{n-1} Z_{t}, m(\alpha) \rightarrow\left[m\left(\alpha_{0}\right) m\left(\alpha_{1}\right), \ldots, m\left(\alpha_{n-1}\right)\right]$$

The same is the same in the opposite direction, which is called Compose. Compose and Decompose can be called packing and unpacking.

Automorphisms technique is a way in which the plaintext corresponding to each plaintext slot can be replaced. When the plaintext is [TeX:] $$m(\alpha)$$, the plaintext corresponding to each plaintext slot is [TeX:] $$m\left(\alpha_{1}\right), m\left(\alpha_{2}\right), \ldots, m\left(\alpha_{n-1}\right)$$. By using Frobenius automorphism, [TeX:] $$m(\alpha) \rightarrow m\left(\alpha^{2}\right)$$ means that the plaintext slot moves i plaintext slots. For example, when i = 1, the plaintext slot of [TeX:] $$m(\alpha)$$ is cyclically moved by one position, and the plaintext corresponding to each plaintext slot becomes [TeX:] $$m\left(\alpha_{1}\right), m\left(\alpha_{2}\right), \ldots, m\left(\alpha_{n-1}\right)$$ [16].

Therefore, batching technique and automorphisms technique can be used to complete the cyclic movement operation of the plaintext in the corresponding plaintext slot in the case of ciphertext.

##### 2.3 OTM Authentication

The message authentication code (MAC) generally uses the hash function of the portable key to verify the integrity of the transmitted data. Commonly used hash functions are MD5, SHA-2, and SHA-3. The storage of the iris feature ciphertext in this paper can use the above method to compress the ciphertext, and then the database only needs to store the ciphertext compressed summary. However, the authentication strategy designed in this paper is that the cloud server decrypts the result after the ciphertext’s homomorphic operation, and the decryption operation can only be completed by the user. Therefore, the use of the hash function does not meet the needs of this design. Therefore, this paper designs a one-time MAC (OTM) authentication method, that is, the key generated by the message key algorithm in the MAC scheme can only be used once, and the user is secret. After decryption, the cloud server can authenticate the decryption result. The specific plan is as follows:

MKGen[TeX:] $$\left(Z_{i}\right)$$: Set [TeX:] $$m k=\left(r_{0}, r_{1}\right), r_{0} \text { and } r_{1}$$ are randomly selected from the [TeX:] $$Z_{I}$$, where [TeX:] $$Z_{I}$$ is a set of I-bit integers.

MACGen(mk, m): The information authentication code [TeX:] $$m_{c}$$ of the information m is obtained by calculating [TeX:] $$m_{c}=m \times r_{0}+r_{1}$$.

Verification(mk, m, [TeX:] $$m_{c}$$): Input mk, x and [TeX:] $$m_{c}$$, verify m is equal to [TeX:] $$\left(m_{c}-r_{0}\right) / r_{1}$$, if so, b is 1, otherwise b is 0.

##### 2.4 Iris Ciphertext Recognition Method

At present, there are few iris recognition products on the market, mainly because the recognition accuracy of iris is largely dependent on the hardware facilities and recognition algorithms of iris acquisition [17,18]. In order to simulate the real iris recognition scene, this paper selects the public iris database, CASIA-Iris [18], to replace the iris acquisition process, using the public MATRIB code provided by the School of Computer Science and Software Engineering of the University of Western Australia [19] to preprocess the iris data, and in order to weigh the performance of the homomorphic calculation, the final use of 2048 The binary vector of bits represents the iris feature template.

The iris recognition method in this paper uses Hamming distance calculation to compare the encoded iris feature templates. It is to measure the distance between the two templates by counting the number of corresponding codes on the two templates [20]. The smaller the distance, the more the two templates match.

80 1024 47.5
80 2048 95.4
80 4096 192
80 8192 392.1
80 16384 799.6
##### 4.1 Security Analysis

Network transmission security: An attacker can obtain only the homomorphic encrypted iris feature data or the data generated by the cloud server through random number calculation. Therefore, the network attacker can’t use the acquired data to decipher the original iris feature plaintext data, and also can resist the replay attack.

Server security: Even an attacker can access the server's database. Because the iris templates stored in the server database are encrypted. These ciphertext templates do not reveal any information about the user's iris characteristics. If the user registers in multiple authentication servers based on this protocol, the keys obtained by the user are definitely different, so the user does not leak information when storing multiple templates in multiple server databases. If you suspect that a template has been corrupted, you can generate a new template with a different key.

Client security: Even if an attacker has access to the client system, he cannot obtain the iris feature template and secret key and cannot authenticate. If an attacker uses brute force, the effort required is equal to randomly assigning a bit vector. If the attacker wants to obtain the iris feature information in the server database by modifying the bits to be sent to the server, the OTM authentication method adopted in this paper can solve this problem well. Even an attacker can send a modification (d, T) to pass the authentication test. However, it is basically impossible for an attacker to achieve both iris recognition success and authentication success.

##### 4.2 Homomorphic Performance

The following is the time taken for the system to test the fully homomorphic calculation process. The registration process is shown in Table 3.

Table 3.

Registration part (unit: ms)
Operations TN 1 TN 2 TN 3
CRT Compose 13.3 12.3 12.2
Encrypt 105.5 107.2 104.5
Total 1047.2 985.4 1000.8

The authentication part is used as shown in Table 4.

Table 4.

Authentication part (unit: ms)
Operation TN 1 TN 2 TN 3
Sequare 275.7 292.1 285.4
Sub 2.8 3.0 2.9
CRT Compose(r0, r1) 28.9 29.8 23.3
ctd * r0+r1 194.3 202.7 188.9
Decrypt (ctd, ctT) 245.1 273.5 231.6
Decompose (ctd, ctT) 24.1 29.0 26.0
Total 2446.5 2544.8 2439.1

The test results are as follows:

In the registration part, the average registration time is 1011.1 ms, while the iris template encryption only takes 105.7 ms on average, accounting for 10.5% of the total registration time.

In the authentication part, the total time of authentication is 2476.8 ms on average, while the average of homomorphism is 482.6 ms, accounting for 19.5% of the total authentication time, and the average time of encrypting and decrypting ciphertexts is 355.8 ms, accounting for 14.4% of the total authen-tication time.

Since the tests are conducted locally, the performance of the system depends on the processing power of the notebook CPU. Through analysis, the system loads and communicates part of the graphical interface with the longest time, while the homomorphic encryption and decryption and the total time spent less than 40%. Therefore, the iris ciphertext full homomorphic efficiency is still good.

Below we compare the results with paper [11]. The length of biometric is 630 bits in [11], while the length is 2048 in our scheme. The normal size of irises is 2048 bits. We study the 2048-bit binary vector segmentation. Table 1 shows that the segmented ciphertext modulus q decreases little, so the segmen¬tation does not significantly improve the efficiency and safety of the system. Therefore the 2048-bit binary vector segmentation is a good choice. In order to compare the performance with [11] at the same level, we also take 630 bits biometric of irises in our scheme. Table 5 shows that our results are better than the scheme [11].

Table 5.

Comparison of two schemes (unit: ms)
Operations Our scheme Ghostshe [11]
Encryption 13.3 16.16
Decryption 105.5 163.72
Addition 0.05 0.05
Multiplication 10.2 14.32

## 5. Conclusion

With the rapid development of information technology, information security has become the most concerned point. The system combines homomorphic encryption with biometrics to ensure the security and integrity of user feature templates. In real life, such as online payment, account login, etc., biometrics can be used for identity verification, and the system can perform ciphertext calculation in the cloud, which greatly improves the security of data processing. It can be seen from the performance analysis that the efficiency of the system is good when the circuit depth of the fully homomorphic encryption cal¬culation is not high. Despite this, the system is still far from the actual complex application requirements, and further research is needed.

## Acknowledgement

This paper is supported by the Natural Science Foundation of Zhejiang Province of China (No. LY17F020002), Public Projects of Zhejiang Province (No. 2017C33079, LGG18F020001), Ningbo Natural Science Foundation (No. 2017A610120, 2018A610159), and the State Key Laboratory of Cryptology (No. 2017-MS-18).

## Biography

##### Xinxia Song
https://orcid.org/0000-0003-4973-8295

She received the B.Sc. degree in mathematics from Kashgar University in 1995, and the M.Sc. degree in mathematics from the Zhejiang Normal University in 2005. She is an associate professor at Zhejiang Wanli University. Her research interests include algebra and cryptography.

## Biography

##### Zhigang Chen
https://orcid.org/0000-0001-5140-7319

He received the B.Sc. degree in mathematics from Kashgar University in 1995, the M.Sc. degree in computer software and theory from the Northwest University in 2004, and received Ph.D. in the Nanjing University of Aeronautics and Astronautics in 2015. From 2013 to 2014, he was an academic visitor at Information Security Group of Royal Holloway, University of London. He is a professor at Zhejiang Wanli University. He is also a visiting researcher at State Key Laboratory of Information Security, Institute of Information Engineering, Chinese Academy of Sciences now. Currently his researches focus on fully homomorphic encryption, lattice-based cryptography and blockchain.

## Biography

##### Dechao Sun
https://orcid.org/0000-0003-0771-093X

He received Ph.D. in School of Information Science and Engineering from Ningbo University in 2018. He is an associate professor in Wanli University. His current research interests include artificial intelligence and network security.

## References

• 1 R. Belguechi, V. Alimi, E. Cherrier, P. Lacharme, C. Rosenberger, "An overview on privacy preserving biometrics," in Recent Application in Biometrics. RijekaCroatia: InTech, p. 65-84, 2011.custom:[[[-]]]
• 2 N. K. Ratha, J. H. Connell, R. M. Bolle, "Enhancing security and privacy in biometrics-based authentication systems," IBM Systems Journal, vol. 40, no. 3, pp. 614-634, 2001.doi:[[[10.1147/sj.403.0614]]]
• 3 A. Juels, M. Sudan, "A fuzzy vault scheme," DesignsCodes and Cryptography, vol. 38, no. 2, pp. 237-257, 2006.doi:[[[10.1007/s10623-005-6343-z]]]
• 4 A. Juels, M. Wattenberg, "A fuzzy commitment scheme," in Proceedings of the 6th ACM Conference on Computer and Communications Security, Singapore, 1999;pp. 28-36. custom:[[[-]]]
• 5 M. Blanton, P. Gasti, "Secure and efficient protocols for iris and fingerprint identification," in European Symposium on Research in Computer Security. Heidelberg: Springer, pp. 190-209, 2011.custom:[[[-]]]
• 6 I. Damgard, M. Geisler, M. Kroigard, "Homomorphic encryption and secure comparison," International Journal of Applied Cryptography, vol. 1, no. 1, pp. 22-31, 2008.doi:[[[10.1504/IJACT.2008.017048]]]
• 7 R. Kulkarni, A. Namboodiri, "Secure hamming distance based biometric authentication," in Proceedings of 2013 International Conference on Biometrics (ICB), Madrid, Spain, 2013;pp. 1-6. custom:[[[-]]]
• 8 C. Gentry, "Fully homomorphic encryption using ideal lattices," in Proceedings of the 41st Annual ACM Symposium on Theory of Computing, Bethesda, MD, 2009;pp. 169-178. custom:[[[-]]]
• 9 C. Karabat, M. S. Kiraz, H. Erdogan, E. Savas, "THRIVE: threshold homomorphic encryption based secure and privacy preserving biometric verification system," EURASIP Journal on Advances in Signal Processing, vol. 2015, no. 71, 2015.doi:[[[10.1186/s13634-015-0255-5]]]
• 10 M. J. Dworkin, "SHA-3 Standard: permutation-based hash and extendable-output functions (NIST FIPS-202)," National Institute of Standards and TechnologyGaithersburg, MD, 2015.custom:[[[-]]]
• 11 J. H. Cheon, H. Chung, M. Kim, K. W. Lee, "Ghostshell: secure biometric authentication using Integrity-based homomorphic evaluations," IACR Cryptology ePrint Archive, vol. 2016, no. 484, 2016.custom:[[[-]]]
• 12 J. Fan, F. Vercauteren, "Somewhat practical fully homomorphic encryption," IACR Cryptology ePrint Archive, vol. 2012, no. 144, 2012.custom:[[[-]]]
• 13 H. Chen, K. Laine, R. Player, "Simple encrypted arithmetic library-SEAL v2.1," in Financial Cryptography and Data Security. Cham: Springer, pp. 3-18, 2017.custom:[[[-]]]
• 14 Z. Brakerski, C. Gentry, S. Halevi, "Packed ciphertexts in LWE-based homomorphic encryption," in Public Key Cryptography – PKC 2013. Heidelberg: Springer, pp. 1-13, 2013.custom:[[[-]]]
• 15 N. P. Smart, F. V ercauteren, "Fully homomorphic SIMD operations," DesignsCodes and Cryptography, vol. 71, no. 1, pp. 57-81, 2014.doi:[[[10.1007/s10623-012-9720-4]]]
• 16 J. Deng, C. Xu, H. Yang, "A secure computation scheme of inner product based on fully homomorphic encryption," Journal of University of Electronic Science and Technology of China, vol. 45, no. 5, pp. 808-811, 2016.custom:[[[-]]]
• 17 S. Thavalengal, P. Bigioi, P. Corcoran, "Iris authentication in handheld devices-considerations for constraint-free acquisition," IEEE Transactions on Consumer Electronics, vol. 61, no. 2, pp. 245-253, 2015.custom:[[[-]]]
• 18 CASIA iris database (Online). Available:, http://biometrics.idealtest.org
• 19 L. Masek, P. Kovesi, "MA TLAB source code for a biometric identification system based on iris patterns," School of Computer Science and Software EngineeringUniversity of Western Australia, 2003.custom:[[[-]]]
• 20 Q. Tian, Z. Liu., "Survey of iris recognition," Application Research of Computers, vol. 25, no. 5, pp. 1295-1300, 2008.custom:[[[-]]]
• 21 M. R. Albrecht, "On dual lattice attacks against small-secret LWE and parameter choices in HElib and SEAL," in Advanced in Cryptology – EUROCRYPT 2017. Cham: Springer, pp. 103-129, 2017.custom:[[[-]]]


text:
## Mapping the OEIS Database

#### 1. Overview

First of all, what is OEIS, and what is the image above? It certainly looks cool!

OEIS is short for The On-Line Encyclopedia of Integer Sequences, and is the go-to database to look up number sequences, and find math papers that talk about it. E.g. the sequence '2, 4, 8, 32', gives 24 results, one of which is $a(n) = 2^{\mathrm{Fibonacci}(n)}$. Good to know!

Q: What happens if you use this database to look up a single integer?
A: It returns all the sequences that contain that number

At the time of writing...

• the integer 101 has 12468 entries.
• the integer -340 has 1545 entries.

In a way, the number of entries for a particular number, is a measure for how interesting the number is.

As preposterous as it sounds to quantify something so subjective, I don't know how else to put it.

Imagine you had access to all the photographs taken by humans (pretend you're the NSA), and you counted all images where an apple was depicted, and counted all images where sharks were depicted. You could, in a sense, use this number as a relative measure for how interesting apples and sharks are (as the object of photography).

The second question -- the image above? It is a plot of the relative OEIS occurrence frequency, of each integer from -125 000 to +125 000 (not exactly, but close enough). Structured in a snake-like pattern with 0 in the center, positive values growing in the top half, and corresponding negative values mirrored in the lower half (see below).

#### 2. Plotting the Data

Initially I only looked at the positive integers, and had structured them in a spiral, wrapping around itself, clockwise.

Then I considered the negative integers as well, and the only meaningful way to lay out the numbers in a 'spiral like' way, was the the following:

The actual value plotted, $p_i$, for each integer, $x_i$, is:

$M = \log(\mathrm{max}(x_i + 1))$
$p_i = M^{-1}\log (x_i + 1)$

Using this color ramp to map the values from 0 to 1:

Which was created by linearly interpolating between the following HSL values:

|------+-----+-----+------|
|  Val |   H |   S |    L |
|------+-----+-----+------|
| 0.00 | 241 | 0.3 | 0.0  |
| 0.07 | 241 | 0.4 | 0.33 |
| 0.15 | 209 | 0.4 | 0.5  |
| 0.20 | 169 | 0.5 | 0.6  |
| 0.25 | 125 | 0.6 | 0.72 |
| 0.30 |  65 | 0.9 | 0.6  |
| 0.61 |  14 | 0.8 | 0.6  |
| 0.81 |   0 | 0.7 | 0.8  |
| 1.00 |   0 | 0.4 | 1.0  |
|------+-----+-----+------|

#### 3. Acquiring the Data

The quickest way I know to do this, is writing a bash-script using curl to get the html page, and unix tools sed and head to extract the value.

 Line 2: Gets the HTML source for the OEIS page. Line 3: Extracts all lines containing result or results Line 4: Ignores all matches except the first. Line 5-7: Isolates the value of interest. Line 8: Returns the value, or 0 if no results were found.
##### Parallelizing Queries

The goal was to get to a 1000 x 1000 image.

Using the above function in a large for-loop, it would have taken around 50 days. If running separately for positive and negative values, 25 days.

A better parallelized version was written, and can be found in this github gist , reducing it to a couple of days. Here it is in action:

NB: If you live in the US, think carefully before running such a script. Apparently, making HTTP requests with modified URLs could be a criminal offense. </tongueincheek>

Click to play

#### 4. Creating the Image

The best tool for generating the image would be processing, octave, matlab, gnuplot, or any other language with a library for pixel manipulation in images, or advanced 2D plotting.

I would definitely not recommend my choice: C++ and SDL. But hey, that's what I'm trying to learn these days, so why not? Here is the final image (click for full resolution), with over 1.4 million values from the OEIS database.

I'm also learning Blender, so here you have a 3D plot using the values as a displacement map.

#### 5. Thoughts & Conclusions

There are three things that surprised me about the data:

1. The sudden drop in entries for positive values. The first explanation that comes to mind is that the OEIS database itself limits the number of searchable entries for any given sequence. Many sequences like "natural numbers", "even numbers", "odd numbers", would mean that no integers should have zero entries, yet, this is not the case.
2. There is a peak for values ranging from around, let's see *crunches some numbers* 1970, to ...*crunches even more numbers* 2013.

*facepalm* Apparently I also searched the meta-data, and most sequences have references to findings and papers between 1970-2013.

3. The peaks close to the diagonals and "y-axis". I have no idea why they occur. Ironically, the integer sequences that correspond to the diagonals, are not themselves registered in the database.

The sequence corresponding to "y-axis", 0, 1, 8, 17, 32, 49, is registered as A077221.

This means that the sequence corresponding to the diagonal in the first, second, third, and fourth quadrants are ($a_1$, $a_2$, $a_3$, $a_4$, respectively): \begin{aligned} a_1(n) & = A_{077221}(n) - (-1)^{n} n \\ a_2(n) & = A_{077221}(n) + (-1)^{n} n \;\;\;\;\;\text{(offset by 1)} \\ a_3(n) & = -a_2(n) \\ a_4(n) & = -a_1(n) \end{aligned}

Lastly, I should point out that I didn't do this because I considered it important or valuable. It just seemed like a fun thing to do. I hope you enjoyed.

PS: If there is any interest, I'll upload the raw data.


text:
# Math Help - Force as a vector 2

1. ## Force as a vector 2

A steel wire 40 m long is suspended between two fixed points 20 m apart. A force of 375 pulls the wire down at a point 15 m from one end of the wire. State the tension in each part of the wire.

2. Originally Posted by skeske1234
A steel wire 40 m long is suspended between two fixed points 20 m apart. A force of 375 pulls the wire down at a point 15 m from one end of the wire. State the tension in each part of the wire.
Try drawing a diagram . I got a right angled triangle with horizontal length 20 , vertical length 15 and hypothenus 25 .

The force is pulling downwards from the end of the vertical side .

There will be 2 tensions , T1 and T2 .

T1 will be 375 N .

Resolve T2 vertically T2cos53.13 = 375 , T2=625 N

You can get 53.13 by doing some trigo .

I am not entirely sure with my answers though .

375 N, 0 N...........
and is the 40 m not significant in part of the drawing?

4. Originally Posted by skeske1234

375 N, 0 N...........
and is the 40 m not significant in part of the drawing?
I don see how the tension is 0 N . The wire of 40 m is divided into 2 parts
25m and 15 m ( where the pulling force is ) .

skeske1234, this gives a triangle with sides of lengths 25, 15, and 20. Since $15^2+ 20^2= 25^2$ this triangle satisfies the Pythagorean theorem and, as mathaddict said before, is a right triangle.