text:
# Combination is not my strong point

1. Aug 27, 2014

### SUXinPHY

1. The problem statement, all variables and given/known data

A small company gives bonuses to their employees at the end of the year. 15 employees are entitled to receive these bonuses of whom 7 employees will receive 100$bonus, 3 will receive 1000$ bonus and the rest will receive 3000$bonus. In how many possible ways these bonuses can be distributed? 2. Relevant equations nCr = n! / (r!(n-r)!) 3. The attempt at a solution But I am unsure if this correct. Would it simply be: 15C7 x 8C3 x 5C5 2. Aug 27, 2014 ### Ray Vickson Instead of "guessing", try to think it out logically. In how many ways can you distribute 7 bonuses of$100 and 8 "others" among the fifteen? After that....what?

3. Aug 27, 2014

### SUXinPHY

My problem when it comes to Combination and Permutation is that I have issue seeing/creating the logic.

Here was my logic when creating that formula.
1. Out of 15 people, 7 will receive $100. 2. Since 7 out of 15 people will get$100, 8 candidates are left and 3 will receive $1000. 3. lastly, there are 5 left over and since the order does not matter it will just equate to 1 (5C5) Am I correct? 4. Aug 27, 2014 ### SUXinPHY I was going to reply to your comments but decided to have a more in depth think about it as I am having a massive headache thinking about it. I just want to say thanks and hopefully when I get my thought together, I would have solved it. 5. Aug 28, 2014 ### Orodruin Staff Emeritus Just to try to offer a different approach that will end with the same result: Let us say that we give out the bonuses one by one. How many orders of giving out bonuses exist? For each given order, how many orders are equivalent in terms of how much bonus everyone gets? How do the two numbers above relate to the number of different ways of distributing the bonuses? 6. Aug 28, 2014 ### SUXinPHY The total of number of ways the bonuses can be distributed = 1515 So does this mean that "How many orders of giving out bonuses exist?" = 15? Or does 'How many orders of giving out bonuses exist' = 'Total number of ways' 7. Aug 28, 2014 ### Orodruin Staff Emeritus How many possibilities are there for who to give the bonus first? How many for the second? How many for the third? And so on. Remember that we are not going to give a bonus to someone who already got one. For the second question, consider that among the 3 who got$1000, it would have been equivalent if they would have gotten it in a different order. The same for the other amounts.

8. Aug 28, 2014

### SUXinPHY

15C7, 15C3, and 15C5
am I correct?

9. Aug 28, 2014

There are 7 out of 15 receiving $100 == There are 5 out of 15 receiving$3000== There are 3 out of 15 receiving $1000==.... (ABC=BCA=ACB=BAC=CAB=CBA) There are thus 6 ways. 10. Aug 28, 2014 ### Orodruin Staff Emeritus Exactly. Consider the group of 3. How many different ways can you order them? How many possibilities for the first person being chosen? How many for the second? How many for the third? (Note that we are now only concerned with the group of 3) 11. Aug 28, 2014 ### SUXinPHY That would be same as 'How many possibilities are there for who to give the bonus first?" right? so 3! 12. Aug 28, 2014 ### Medicol$100: 15 ways for the 1st person, 14for the second....
$1000:....$3000:...
This is not correct. Because the question is how many possible ways to deliver 3 groups of (700,1000,3000) among 15 people. So 15 must too be divided into 3 groups (7,8,5). Since no order is mentioned. This is thus a permutation of 3 which is 3!=6.

Last edited: Aug 28, 2014
13. Aug 28, 2014

### SUXinPHY

I am pretty sure it mean how many ways can the bonus be distributed to 15 people.

14. Aug 28, 2014

### Medicol

Yes, I believe it is 6.

15. Aug 28, 2014

### Orodruin

Staff Emeritus
No, this is a multinomial coefficient and it is certainly not 6. By your reasoning, there would be two different ways of splitting 545631 people in a group of 545600 and one of 31.

16. Aug 28, 2014

### Orodruin

Staff Emeritus
Yes. And for the other groups?

17. Aug 28, 2014

### SUXinPHY

7!, 3! and 5!

18. Aug 28, 2014

### Orodruin

Staff Emeritus

So, for each ordering of the entire set (of which there are 15!), there are how many equivalent orders? (Note that the equivalent orders within each group are independent)

19. Aug 28, 2014

### Medicol

Yes, because you can't change the amount of bonus one will get in a company after the CEO has signed the awards.
That John will get only $100 and Jess will receive$1000 is a fact. The way you split it will assign back Jess $100 and John$1000, which is incorrect and unfair and the company will go to court.

20. Aug 28, 2014

### SUXinPHY

I am not really sure if I get the question, so I would not try to answer it as any answer I give will be a guess.

But I am assuming you meant "How many of the 15! are the same?" am I right.

format: plain


text:
# How do you find the degree and leading coefficient of the polynomial 14b-25b^6?

Jan 14, 2017

Degree of polynomial: $6$
Leading coefficient: $- 25$

#### Explanation:

The degree of a polynomial expression is the largest degree of any term in the polynomial.

The degree of a term is the sum of the exponents of the variable factors of the term.

In this case
$\textcolor{w h i t e}{\text{XXX}} 14 b = 14 {b}^{\textcolor{b l u e}{1}}$ has degree $\textcolor{b l u e}{1}$
$\textcolor{w h i t e}{\text{XXX}} - 25 {b}^{\textcolor{b l u e}{6}}$ has degree $\textcolor{b l u e}{6}$
So the degree of the polynomial is $\textcolor{b l u e}{6}$

To determine the leading coefficient, it is first necessary to write the expression in standard form. This means that the expression should be written with the terms in descending degree sequence.
Therefore the given expression in standard form would be:
$\textcolor{w h i t e}{\text{XXX}} \textcolor{g r e e n}{- 25} {b}^{6} + 14 b$
The leading coefficient is the constant factor of the first term (when the expression is in standard form).
Therefore the leading coefficient is $\textcolor{g r e e n}{- 25}$


text:
# Mass lumosity relationship stars and bars

### The Sun and Stellar Structure

ble 2; note that the error bars are smaller than the plotted symbols. Relative to A91, 5 The mass-luminosity relation for the stars in Table 2. The correlation coefficients are 0~ for the i i~ high-mass stars (M ~ o~ I The empirical mass-luminosity relationship derived from data in Popper's review article'. show the mean error bars for the four groups of stars identified in the key. If you plot the masses for stars on the x-axis and their luminosities on the y-axis, you can calculate that the relationship between these two quantities is.

So what does this have to do with planets affecting solar variation? To understand this we need to consider why the Mass-Luminosity relation holds. From Penn State University: Given our theory for the structure of stars, you can understand where this relationship comes from. Stars on the Main Sequence must be using the energy generated via nuclear fusion in their cores to create hydrostatic equilibrium. The condition of hydrostatic equilibrium is that the pressure is balancing gravity.

If you increase the pressure inside a star, the temperature will also increase. So, the cores of massive stars have significantly higher temperatures than the cores of Sun-like stars. At higher temperatures, the nuclear fusion reactions generate energy much faster, so the hotter the core, the more luminous the star.

Why should there not be more massive and hence brighter and less massive hence fainter stars?

## The Mass-Luminosity Relationship

An 80 solar mass star is not that much bigger than the Sun, but its luminosity is times greater. This means that even a slight difference in the mass among stars produces a large difference in their luminosities.

For example, an O-type star can be only 20 times more massive than the Sun, but have a luminosity about 10, times as much as the Sun. Putting together the principle of hydrostatic equilibrium and the sensitivity of nuclear reaction rates to temperature, you can easily explain why. Massive stars have greater gravitational compression in their cores because of the larger weight of the overlying layers than that found in low-mass stars. The massive stars need greater thermal and radiation pressure pushing outward to balance the greater gravitational compression.

The greater thermal pressure is provided by the higher temperatures in the massive star's core than those found in low-mass stars. Massive stars need higher core temperatures to be stable! The nuclear reaction rate is very sensitive to temperature so that even a slight increase in temperature makes the nuclear reactions occur at a MUCH higher rate. This means that a star's luminosity increases a lot if the temperature is higher.

## Mass–luminosity relation

This also means that a slight increase in the mass of the star produces a large increase in the star's luminosity. Mass Cutoff Explained The principle of hydrostatic equilibrium and nuclear fusion theory also explain why stars have a certain range of masses. The stars have masses between 0. The potential energy of a spherical mass distribution is This and the volume are substituted in to give.

Here is the average mass of gas particles within the star. Substituting this equation into the initial luminosity equation, along with yields. A slightly more exact result can be achieved by considering that the above equation gives the average temperature based on the average pressure, but what is actually needed is the surface temperature. Because stars are much hotter in the center than near the surface, one also needs to estimate the relationship between the surface temperature and internal temperature.

Mass Luminosity relation

The center is so much hotter since energy takes a long time to escape, otherwise, thermodynamic equilibrium would be achieved quickly and the temperature would be nearly uniform throughout.

A random walk analysis can be used to estimate the "delay factor", i.

### Mass–luminosity relation - Wikipedia

In reality, the mean free pathof photons within the Sun depends on the density and temperature, but here it will be approximated as a constant. After N interactions, resulting in N vector displacements in random directions, the distance traveled is: The square of the net displacement is: Averaging over many random direction changes, the terms involving dot products cancel since the direction is random.

Hence, for largeThus, to escape from the Sun, on average steps are required.


text:
# Comparison of the Mandibular Foramen Position Among Different Skeletal Classes Using Panoramic Radiographs

AUTHORS

Zahra Dalili Kajan 1 , Ali Khalighi Sigaroudi 2 , Negar Khosravifard 1 , * , Nahid Farsam 3

1 Dental Sciences Research Center, Department of Maxillofacial Radiology, Faculty of Dentistry, Guilan University of Medical Sciences, Rasht, Iran

2 Dental Sciences Research Center, Department of Maxillofacial Surgery, Faculty of Dentistry, Guilan University of Medical Sciences, Rasht, Iran

3 Faculty of Dentistry, Guilan University of Medical Sciences, Rasht, Iran

How to Cite: Dalili Kajan Z, Khalighi Sigaroudi A, Khosravifard N, Farsam N. Comparison of the Mandibular Foramen Position Among Different Skeletal Classes Using Panoramic Radiographs, Iran J Ortho. 2019 ; 14(1):e65691. doi: 10.5812/ijo.65691.

ARTICLE INFORMATION

Iranian Journal of Orthodontics: 14 (1); e65691
Published Online: January 23, 2019
Article Type: Original Article
Revised: May 5, 2018
Accepted: May 7, 2018

# Crossmark

#### CHEKING

##### Abstract

Background: The mandibular foramen has often been considered as the most reliable reference point for several anesthetic and surgical procedures in the maxillofacial region. This study evaluated the position of the mandibular foramen in different skeletal classes.

Methods: A total of 90 panoramic and lateral cephalometric images belonging to class I (n = 30), class II (n = 30), and class III (n = 30) patients were used for this study. The position of the mandibular foramen in relation to the anterior and posterior borders of the mandibular ramus, inferior border of the mandible, sigmoid notch and occlusal plane was determined in each panoramic radiograph.

Results: The position of the mandibular foramen relative to the occlusal plane and the sigmoid notch significantly differed among the three skeletal groups; however, no significant difference existed among the skeletal classes with regard to the position of the mandibular foramen in relation to the anterior and posterior borders of the ramus and the inferior border of the mandible.

Conclusions: The position of the mandibular foramen tends to be lower in skeletal class II patients; therefore, it seems that lower injection heights in these patients could result in better outcomes.

## Keywords

Mandible Nerve Panoramic View Skeletal Class

Copyright © 2019, Iranian Journal of Orthodontics. This is an open-access article distributed under the terms of the Creative Commons Attribution-NonCommercial 4.0 International License (http://creativecommons.org/licenses/by-nc/4.0/) which permits copy and redistribute the material just in noncommercial usages, provided the original work is properly cited.

### 1. Background

The inferior alveolar nerve is the largest branch of the mandibular nerve that enters the mandibular foramen together with the inferior alveolar artery. The nerve supplies the pulps of ipsilateral mandibular teeth, periodontal ligaments, lower lip, and the chin skin (1).

The mandibular foramen is considered as the most reliable reference point for accessing the inferior alveolar nerve (2). Knowledge of the exact location of the mandibular foramen is crucial for successfully performing mandibular block anesthesia. Proper accomplishment of other procedures such as sagittal split ramus osteotomy, vertical ramus osteotomy, inverted L osteotomy, orthognathic surgery, mandibular trauma management, benign and malignant lesion removal, and preprosthetic surgery also depends on proper localization of the position and path of the mandibular foramen and canal (3, 4).

Radiography is considered as the only non-invasive method of diagnosing and treatment planning for the surgical procedures of the mandible. Among the various imaging modalities, panoramic radiographs are routinely used for screening, diagnosing and selecting the most appropriate surgical approach.

It has been postulated that the position of the mandibular foramen differs among various ethnic groups (1, 5-8); moreover, the mandibular foramen gradually changes its position corresponding to the growth of the mandibular ramus in children (4, 9).

### 2. Objectives

Considering the variations in mandibular morphology among different skeletal classes, the present study was aimed at evaluating the position of the mandibular foramen in class I, II and III skeletal groups using panoramic radiographs; thereby, reducing the risk of mislocalization of the foramen during surgical and anesthetic procedures.

### 3. Methods

Panoramic radiographs of 90 patients aged between 18 - 35 years were used for the present study. The radiographs belonged to 30 skeletal class I, 30 skeletal class II and 30 skeletal class III patients. The patients’ skeletal classes were determined by two skilled orthodontists based on the criteria of Steiner’s cephalometric analysis using patients’ lateral cephalograms. As the radiographs had already been taken for other purposes, no additional radiographic exposure was imposed on the patients for the performance of this study.

Radiographs of patients with systemic disorders, jaw asymmetry, prior orthognathic surgery and absence of mandibular molar teeth were not included in the investigation. Furthermore, radiographs that suffered from poor resolution, improper geometry, head rotation and motion artifacts were excluded from the study. In case the mandibular foramen could not be identified with certainty on the panoramic image, the radiograph was not included in the study sample.

All panoramic and lateral cephalometric images had been prepared by Cranex D machine (Soredex, Helsinki, Finland). The radiographs were printed with 1:1 magnification factor by Dry Laser printer (Dry Pro 873-Konica Minolta, Tokyo, Japan). The ethical approval number of this research was IR.GUMS.RED.1394.647 (registered by Guilan University of Medical Sciences).

#### 3.1. Identification of Lines and Points on Panoramic Radiographs

In each panoramic image, the anterior and posterior borders of the mandibular ramus, inferior margin of the sigmoid notch and inferior border of the mandible were drawn bilaterally on a tracing paper by a senior dental student and confirmed by a qualified maxillofacial radiologist with 15 years of professional experience.

The center of the mandibular foramen (point “O”) was identified by the radiologist on all panoramic images. A horizontal tangent line along the inferior margin of the sigmoid notch was drawn. A vertical line that passed through the center of the mandibular foramen was drawn perpendicular to the tangent of the sigmoid notch until it cut the tangent superiorly (point “S”) and the inferior border of the mandible inferiorly (point “R”) (Figure 1A). Another line passing horizontally through the center of the mandibular foramen was drawn parallel to the tangent of the sigmoid notch; the point at which this line met the anterior border of the ramus was named “A” and the point at which it reached the posterior border of the ramus was defined as “P” (Figure 1B).

Figure 1. A, Identification of points “S” and “R” on the traced panoramic images; B, identification of points “A” and “P” on the traced panoramic images

The occlusal plane was identified as a line passing through the distal cusp tip of the mandibular second molar tooth and parallel to the tangent to the sigmoid notch. The point at which the occlusal plane crossed the vertical line through the center of the mandibular foramen was named “B” (Figure 2).

Figure 2. Identification of the occlusal plane and point “B” on the traced panoramic images

#### 3.2. Measurement of Distances on Panoramic Radiographs

The following distances were defined and measured on both sides of each panoramic radiograph (Figure 2):

- OS: Distance from the center of the mandibular foramen to the sigmoid notch

- OA: Distance from the center of the mandibular foramen to the anterior border of mandibular ramus

- OP: Distance from the center of the mandibular foramen to the posterior border of mandibular ramus

- SR: Distance from the sigmoid notch to the inferior border of the mandible

- OR: Distance from the center of the mandibular foramen to the inferior border of the mandible

- OB: Distance from the center of the mandibular foramen to the occlusal plane

- SB: Distance from the sigmoid notch to the occlusal plane

#### 3.3. Determination of Horizontal and Vertical Ratios

The following ratios were calculated for both sides of each radiograph:

1. H ratio: Ratio of OA to AP $(OAOA+OP)$

2. V1 ratio: Ratio of OS to SR $(OSSR)$

3. V2 ratio: Ratio of OR to SR $(ORSR)$

4. V3 ratio: Ratio of OB to SB $(OBSB)$

The mean values for H, V1, V2 and V3 ratios in different skeletal classes were analyzed by means of ANOVA test. P value < 0.05 was considered to be statistically significant.

### 4. Results

Of the 90 cases studied, 19 (21.1%) were males and 71 (78.9%) were females. Mean age of the patients was 23.91 ± 4.1with the minimum age being 18 and the maximum age being 35 years.

The ANOVA test revealed no significant differences in OS (P = 0.41), OA (P = 0.21), OP (P = 0.33), SR (P = 0.35) and OR (P = 0.11) dimensions among the three skeletal classes; however, OB and SB dimensions showed significant differences among the skeletal groups (P = 0.001). Furthermore, only the V3 ratio differed significantly in class I, II and III skeletal groups (P = 0.001).

Tables 1 and 2 represent the distances and ratios in different skeletal classes respectively.

Table 1. Mean ± Standard Deviation (SD) of the Measured Distances in the Three Skeletal Groups
DistanceClass I PatientsClass II PatientsClass III PatientsP Value
OS13.20 ± 2.8313.69 ± 3.1014.16 ± 2.370.41
OA17.53 ± 2.0316.58 ± 2.2417.34 ± 2.320.21
OP9.89 ± 1.589.36 ± 1.429.97 ± 2.080.33
SR43.97 ± 3.5742.68 ± 6.4444.70 ± 5.810.35
OR30.78 ± 3.0428.62 ± 4.7330.37 ± 4.470.11
OBa10.27 ± 2.238.18 ± 2.5212.30 ± 3.860.001
SBa23.39 ± 3.6521.87 ± 4.5826.39± 4.870.001

a Statistically significant.

Table 2. Mean ± Standard Deviation (SD) of the Horizontal and Vertical Ratios in the Three Skeletal Groups
RatioClass I PatientsClass II PatientsClass III PatientsP Value
H62.85 ± 4.2963.02 ± 3.8862.91 ± 5.890.99
V129.92 ± 6.8331.93 ± 3.9431.33 ± 4.100.30
V268.87 ± 6.9965.83 ± 7.6467.53 ± 4.530.20
V3a44.90 ± 8.8036.57 ± 7.9845.5 ± 8.080.001

a Statistically significant.

Comparison of the distances and ratios among the skeletal classes based on patients’ right and left sides showed similar results as the above mentioned summated ones. In this regard, the ANOVA test revealed that in either side of the patients’ mandibles, there were statistically significant differences in OB dimension, SB dimension and V3 ratio among the skeletal classes (P = 0.001).

### 5. Discussion

It is obviously clear that precise localization of the mandibular foramen and lingula is essential for proper performance of several surgical and anesthetic procedures (10). Moreover, position of the mandibular foramen is of utmost importance for neurolysis in neuralgia (11). Failure to properly identify the location of lingula and mandibular foramen could result in complications such as hemorrhage and nerve injury during surgical procedures (12, 13). As there are considerable variations in the position of mandibular structures among different skeletal classes, the present study was conducted to determine the position of mandibular foramen in class I, II and III patients using panoramic radiographs.

In the study performed by Kaffe et al. (3), position of the mandibular foramen was evaluated on panoramic radiographs in comparison with the true position on dry skulls. In the mentioned study, panoramic radiographs were prepared by two different panoramic machines, namely Orthoralix SD and Panelipse. The mean distance from the mandibular foramen to the lowest point of the mandibular notch was calculated 21.89 mm on the dry skulls, 24.94 mm on the images taken with Orthoralix SD and 23.55 mm on the images taken with Panelipse. The aforementioned distance which was measured on panoramic images of Cranex D machine in our study was calculated 13.2 mm in class I, 13.69 mm in class II and 14.16 mm in class III patients. The dissimilarities in the obtained results could be explained by the differences in the panoramic devices used, the magnification value of the panoramic machines and perhaps most important, the ethnicity of the study patients.

Prado et al. (14) reported vertical distances of the mandibular foramen from the sigmoid notch and inferior border of the mandible in dentate and edentulous Brazilian mandibles. The upper vertical distances were greater than reported “OS” distances and the lower vertical distances were smaller than reported “OR” distances in the present study. The linear horizontal measurements between the mandibular foramen and posterior border of the ramus were significantly greater than reported “OP” distances in the current study.

Park and Lee (15) measured vertical distances of the mandibular foramen from the sigmoid notch on CBCT images of normal occlusion, skeletal class II and III malocclusion patients. Our results showed significantly lower values than their reports; 21.59 in normal occlusion, 20.49 in class II and 18.77 in class III malocclusion patients. They used reconstructed panoramic views for their measurements instead of three dimensional views. They also stated that the vertical length of the mandibular ramus in class III malocclusion patients was greater than the other two groups; this finding was in agreement with ours.

Kim et al. (6) measured the distance from the mandibular lingula to the anterior border of the ramus on dry skulls using a caliper. They found the mentioned distance to be 17.5 mm in dentulous patients which was almost similar to that of our study in which the distance between the mandibular foramen and the anterior border of the ramus was 17.53 in class I, 16.58 in class II and 17.34 in class III patients. These distances were lower than those reported by Park and Lee in their study on CBCT images (15) and also Seo et al. (16) in their study on panoramic radiographs.

In the study performed by Jansisyanont et al. (5) on the shape, height and position of the lingula in Thai dry skulls, the results were very close to our study; however, our study was performed on panoramic images of the patients rather than dry skulls.

Keros et al. (17) evaluated the distance of the mandibular foramen to the sigmoid notch and anterior border of the ramus in two groups of patients with and without successful inferior alveolar nerve anesthesia. Their measurements were to some extent different from those of our study, most likely due to different panoramic devices used.

In their text book of local anesthesia, Malamed (18) suggested that during inferior alveolar nerve block, the injection height should be 6 - 10 mm above the occlusal plane. In the current study, we came to the conclusion that the injection height ought to be 10.27 mm in class I, 8.18 in class II and 12.3 in class III patients.

To our knowledge, until now only limited researches have been performed on the position of the lingula and mandibular foramen in different skeletal classes. Our study revealed that the distance between the mandibular foramen and the occlusal plane is least in skeletal class II patients; therefore, less injection height from the sigmoid notch should be chosen during inferior alveolar nerve block in these patients in comparison with class I and class III groups. However, no significant differences exist between class I and III patients regarding the injection height in achieving inferior alveolar nerve anesthesia. Considering the position of the mandibular foramen in the horizontal plane, there is no substantial variation among the different skeletal classes; hence the injection is performed in an analogous antero-posterior location. Finally, it is suggested that the position of the mandibular foramen and its surrounding structures be evaluated via CBCT examinations to take advantage of images with less distortion and magnification.

#### 5.1. Conclusions

In conclusion, it seems that the position of the mandibular foramen tends to be lower in skeletal class II patients; therefor, lower injection heights in these patients might increase the success rate of inferior alveolar nerve blocks.

### References

• 1.

Lopes PT, Pereira GA, Santos AM. Morphological analysis of the lingula in dry mandibles of individuals in Southern Brazil. J Morphol Sci. 2010;27(3-4):136-8.

• 2.

Devi R, Arna N, Manjunath KY; Balasubramanyam. Incidence of morphological variants of mandibular lingula. Indian J Dent Res. 2003;14(4):210-3. [PubMed: 15328986].

• 3.

Kaffe I, Ardekian L, Gelerenter I, Taicher S. Location of the mandibular foramen in panoramic radiographs. Oral Surg Oral Med Oral Pathol. 1994;78(5):662-9. doi: 10.1016/0030-4220(94)90182-1. [PubMed: 7838477].

• 4.

Kanno CM, de Oliveira JA, Cannon M, Carvalho AA. The mandibular lingula's position in children as a reference to inferior alveolar nerve block. J Dent Child (Chic). 2005;72(2):56-60. [PubMed: 16294933].

• 5.

Jansisyanont P, Apinhasmit W, Chompoopong S. Shape, height, and location of the lingula for sagittal ramus osteotomy in Thais. Clin Anat. 2009;22(7):787-93. doi: 10.1002/ca.20849. [PubMed: 19644966].

• 6.

Kim HJ, Lee HY, Chung IH, Cha IH, Yi CK. Mandibular anatomy related to sagittal split ramus osteotomy in Koreans. Yonsei Med J. 1997;38(1):19-25. doi: 10.3349/ymj.1997.38.1.19. [PubMed: 9100479].

• 7.

Tuli A, Choudhry R, Choudhry S, Raheja S, Agarwal S. Variation in shape of the lingula in the adult human mandible. J Anat. 2000;197 ( Pt 2):313-7. doi: 10.1046/j.1469-7580.2000.19720313.x. [PubMed: 11005723]. [PubMed Central: PMC1468130].

• 8.

Fabian FM. Observation of the position of the lingula in relation to the mandibular foramen and the mylohyoid groove. Ital J Anat Embryol. 2006;111(3):151-8. [PubMed: 17312921].

• 9.

Ezoddini Ardakani F, Bahrololoumi Z, Zangouie Booshehri M, Navab Azam A, Ayatollahi F. The position of lingula as an index for inferior alveolar nerve block injection in 7-11-year-old children. J Dent Res Dent Clin Dent Prospects. 2010;4(2):47-51. doi: 10.5681/joddd.2010.013. [PubMed: 22991596]. [PubMed Central: PMC3429971].

• 10.

Sekerci AE, Cantekin K, Aydinbelge M. Cone beam computed tomographic analysis of the shape, height, and location of the mandibular lingula in a population of children. Biomed Res Int. 2013;2013:825453. doi: 10.1155/2013/825453. [PubMed: 24490173]. [PubMed Central: PMC3893742].

• 11.

Tsai HH. Panoramic radiographic findings of the mandibular foramen from deciduous to early permanent dentition. J Clin Pediatr Dent. 2004;28(3):215-9. doi: 10.17796/jcpd.28.3.gt48634942137234. [PubMed: 15163149].

• 12.

Monnazzi MS, Passeri LA, Gabrielli MF, Bolini PD, de Carvalho WR, da Costa Machado H. Anatomic study of the mandibular foramen, lingula and antilingula in dry mandibles, and its statistical relationship between the true lingula and the antilingula. Int J Oral Maxillofac Surg. 2012;41(1):74-8. doi: 10.1016/j.ijom.2011.08.009. [PubMed: 21955366].

• 13.

Aminabadi NA, Farahani RM, Oskouei SG. Site-specificity of pain sensitivity to intraoral anesthetic injections in children. J Oral Sci. 2009;51(2):239-43. doi: 10.2334/josnusd.51.239. [PubMed: 19550092].

• 14.

Prado FB, Groppo FC, Volpato MC, Caria PH. Morphological changes in the position of the mandibular foramen in dentate and edentate Brazilian subjects. Clin Anat. 2010;23(4):394-8. doi: 10.1002/ca.20973. [PubMed: 20235169].

• 15.

Park HS, Lee JH. A comparative study on the location of the mandibular foramen in CBCT of normal occlusion and skeletal class II and III malocclusion. Maxillofac Plast Reconstr Surg. 2015;37(1):25. doi: 10.1186/s40902-015-0024-2. [PubMed: 26301208]. [PubMed Central: PMC4539352].

• 16.

Seo BS, Lee JH, Kim KW. A comparative study on the location of the mandibular foramen in panoramic radiographs of normal occlusion and mandibular prognathism. J Korea Assoc Maxillofac Plast Reconstr Surg. 2002;24(3):244-51.

• 17.

Keros J, Kobler P, Baucic I, Cabov T. Foramen mandibulae as an indicator of successful conduction anesthesia. Coll Antropol. 2001;25(1):327-31. [PubMed: 11787558].

• 18.

Malamed SF. Handbook of local anesthesia. 6th ed. St. Louis: Mosby Co; 2013. p. 210-5.


text:
Halloween Party - ASIS CTF Quals 2019

tl;dr

1. Find Elliptic Curve parameters from given points on the curve
2. Find x-coordinate of 2*P, given y-coordinate of 2*P
3. Invert 2 over mod (P.order()) and multiply the result with 2*P to get P
4. Submit ASIS{P.x} as the flag

Challenge Points: 182
Challenge Solves: 20
Solved by: s0rc3r3r, v3ct0r, v4d3r

In case you are new to Elliptic Curves, you can read about them in my library here

Preliminary Analysis

We are given a script that implements a basic Elliptic Curve (Weierstraas model)
$y^2 \equiv x^3 + a*x + b\mod p$:

#!/usr/bin/env python

from fastecdsa.curve import Curve
from fastecdsa.point import Point
from Crypto.Util.number import *
from secret import EC_params, flag, Q

p, a, b, q, Px, Py = EC_params
C = Curve('halloween', p, a, b, q, Px, Py)
P = Point(Px, Py, curve = C)
P1 = Point(p + 1, 467996041489418065436268622304855825266338280723, curve = C)
P2 = Point(p - 1, 373126988100715326072483107245781156204485119489, curve = C)
P3 = Point(p + 3, 245091091146774561796627894715885724307214901148, curve = C)

assert (2*P).x == Q.x
assert bytes_to_long(flag) == P.x
assert ((-1) * Q).y == 621803439821606291947646422656643138592770518069

The script is importing EC parameters from a secret file, hence our first task becomes recovering the
Elliptic Curve parameters.

Notice that we are given three points on the curve: P1, P2 and P3, coordinates of which are known to us.
We can use these points to get the values of curve parameters.

Retrieving EC parameters

Let $P1 = (x_1, y_1)$, $P2 = (x_2, y_2)$ & $P3 = (x_3, y_3)$
This implies:
$y_1^2 = x_1^3 + a*x_1 + b \mod p$
$y_2^2 = x_2^3 + a*x_2 + b \mod p$
$y_3^2 = x_3^3 + a*x_3 + b \mod p$

Substituting values of P1 = (x1, y1), P2 = (x2, y2) & P3 = (x3, y3) and solving for a, b, p, we get:

p = 883097976585278660619269873521314064958923370261
b = 433481663214462017150295835098295925800218140157
a = 48029713913392144447486256568923103286673283937

There are a few assertions in the challenge script:

assert (2*P).x == Q.x
assert bytes_to_long(flag) == P.x
assert ((-1) * Q).y == 621803439821606291947646422656643138592770518069

As one can see, our goal is to find the x-coordinate of P, which is the flag.

It is given that x-coordinate of P’ = 2*P (scalar multiplication) is equal to x-coordinate of Q. Note, this can
only happen when y-coordinate of Q is an additive inverse of y-coordinate of P’.

Let us try to understand the reason behind the above:

1. Consider an Elliptic Curve $y^2\equiv x^3 + a*x + b\mod p$,
2. If two points A = (x1, y1) and B = (x2, y2) have same x-coordinate, then we can write:
• $y_1^2 \equiv c\mod p$
• $y_2^2 \equiv c\mod p$
3. Provided y1 != y2, we can say that $y_1 \equiv -y_2 \mod p$ as:
• $y_1^2 \equiv (-y_2)^2 \equiv c\mod p$

We are given y-coordinate of (-1)*Q, which implies that we are given the y-coordinate of P’

On the basis of observations above, we can draw the Elliptic Curve and mark relevant points:

Note that the above diagram is made for Curve over $\mathbb{R}$, whereas our Curve is defined over $GF(p)$,
but the idea remains the same! Also, $P+P == 2*P$

Finding x-coordinate of Q

Provided y-coordinate of a point on the curve, we can compute it’s corresponding x-coordinate by finding
solutions of the equation: $x^3 + a*x + (b-y^2) \equiv 0 \mod p$

Values of a, b, p in our challenge are as follows:

a = 48029713913392144447486256568923103286673283937
b = 433481663214462017150295835098295925800218140157
p = 883097976585278660619269873521314064958923370261

We computed the x-coordinate of Q by running the following function in Mathematica:

Solve[x^3 + 48029713913392144447486256568923103286673283937 x + 837637963235166117552443765282645351326329278968 == 0, x, Modulus ->883097976585278660619269873521314064958923370261]

Alternatively, you can also use roots() in sagemath:

a = 48029713913392144447486256568923103286673283937
b = 433481663214462017150295835098295925800218140157
p = 883097976585278660619269873521314064958923370261

P.<X> = PolynomialRing(GF(p))
f=X^3+a*X+b-Qiy^2
Qix=f.roots()[0][0]

Source: HATS SG team’s solution script - https://pastebin.com/cUAa6R9W

Recovered x-coordinate of Q as: 708927573459527177103235542148826237228344428002
Since x-coordinate of Q and that of P’=2*P is the same, we have both x and y-coordinates of P’.

Knowledge of both coordinates of 2*P would be adequate to get coordinates of P

Finding x-coordinate of P

Let the order of subgroup generated by P be ordP. We can then write:
$2*P = P’$
$P = ({2^{-1}\mod ord_P})*P’$

But, how do we find order of subgroup generated by P?

We know from Lagrange’s Theorem that order of the subgroup generated by a point P on the curve is a factor of cardinality of the curve.

But if P is a generator, then order of the subgroup generated by P is exactly equal to the cardinality of
the curve. We can find out cardinality of a curve E using the following function in sagemath:

E.cardinality()

Cardinality of our curve has several factors: [3, 5, 13, 257, 134021890447, 97090721460179,
1354215209508238123] and order of P can be a factor of combination of any of these factors.

But we went on further anyway, assuming that P is a generator for the curve given in this challenge and got
the correct coordinates :)

You can read the full solution script here:

from Crypto.Util.number import *
from sage.all import *

y1 = 467996041489418065436268622304855825266338280723
y2 = 373126988100715326072483107245781156204485119489
y3 = 245091091146774561796627894715885724307214901148

b = 433481663214462017150295835098295925800218140157
a = 48029713913392144447486256568923103286673283937
p = 883097976585278660619269873521314064958923370261
E = EllipticCurve(GF(p), [a, b])
P1 = E((p+1, y1))
P2 = E((p-1, y2))
P3 = E((p+3, y3))

Q_y = -621803439821606291947646422656643138592770518069 % p
_2P_y = 621803439821606291947646422656643138592770518069

# Use Mathematica to solve, sagemath's solve_mod shows overflow
# Solve[x^3 + 48029713913392144447486256568923103286673283937 x + 837637963235166117552443765282645351326329278968 == 0, x, Modulus ->883097976585278660619269873521314064958923370261]
Q_x = 708927573459527177103235542148826237228344428002L
_2P_x = Q_x

Q = E((Q_x, Q_y))
_2P = E((_2P_x, _2P_y))
print Q
print "\n"
print _2P

assert _2P[0] == Q[0]

list1 = [3, 5, 13, 257, 134021890447, 97090721460179, 1354215209508238123]
_cardinality = reduce(lambda i, j: i*j, list1)

tP = inverse_mod(2, _cardinality)*_2P
if 2*tP == _2P:
print "Voila! P:", tP

On running the above code, we got the coordinates of P as: (804028439497151963978256498500182891314861988389, 272052071247970914287181631972199909106801861256)

Flag: ASIS{804028439497151963978256498500182891314861988389}

In case of any query, feedback or suggestion, feel free to comment or reach me out on Twitter!


text:
# How to resize the following picture in LaTeX using pstricks?

\documentclass[a4paper, 12pt, oneside]{article}

\usepackage{pst-all}
\usepackage{pstricks}
\usepackage{tikz}
\begin{center}
\begin{figure}

%\bpsp(3,2.5)
%\psgrid[subgriddiv=1,griddots=10,gridlabels=10pt](-2,0)(8,3)
\vspace{3cm}
\rput(5.7,0.25){
\psline(0,1)(2,1)
\psline[linestyle=dashed](2,1)(3,1)
\psline(3,1)(4,1)
\psdot(0,1)
\psdot(1,1)
\psdot(2,1)
\psdot(3,1)
\psdot(4,1)
\pscurve[linestyle=dotted](5.3,1.59)(5.45,1.3)(5.4,1.04)
\pscurve[linestyle=dotted](5.3,.45)(5.45,.71)(5.4,.98)
\psline(4,1)(5,0)
\psline(4,1)(5,2)
\psline(5.4,1)(4,1)
\psline(-1,2)(0,1)(-1,0)
\psdot(-1,2)
\psdot(-1,0)
\psdot(5.4,1)
\psline(5.3,.4)(4,1)(5.3,1.6)
\psline(-1.3,1.5)(0,1)(-1.3,.5)
\psdot(-1.3,1.5)
\psdot(-1.3,.5)
\pscurve[linestyle=dotted](-1.1,2)(-1.5,1)(-1.1,0)
\psdot(5.3,1.6)
\psdot(5.3,.4)
\psdot(5,0)
\psdot(5,2)
\rput(0.1,.8){$u_0$}
\rput(1,.8){$u_1$}
\rput(2,.8){$u_2$}
\rput(3.8,.8){$u_{k-s-t}$}
\rput[l](-3.5,1){$s$ vertices $\Bigg\{$}
\rput[l](5.6,1){$\Bigg\} t$ vertices}
}
%epsp
\caption{The graph $\mathcal{P}(k,s,t)$}\label{pkst}

\end{figure}
\end{center}

I am trying to scale the size of the figure. How we can do that?

• Just a question: are the series of dots at both ends supposed to be on a circle? – Bernard Oct 13 '19 at 15:25
• You might need \psscalebox. – Who Save Me Save Entire World Oct 13 '19 at 15:57

No need for scaling. Just use the correct image size for pspicture:

\documentclass[a4paper, 12pt, oneside]{article}
\usepackage{pst-all}
\usepackage{tikz}
\begin{document}

\begin{figure}
\centering
\begin{pspicture}[showgrid=false](-3,0)(7.5,2)
\psline{*-*}(0,1)(2,1)\psdot(1,1)
\psline[linestyle=dashed]{-*}(2,1)(3,1)
\psline{-*}(3,1)(4,1)
\psarc[linestyle=dotted](0,1){1.5}{135}{225}
\psarc[linestyle=dotted](4,1){1.5}{-45}{45}
\rput(0,1){\psforeach{\iA}{135,157.5,205.5,225}{\psline{-*}(1.5;\iA)}}
\rput(4,1){\psforeach{\iA}{-45,-22.5,0,22.5,45}{\psline{-*}(1.5;\iA)}}
\uput{10pt}[-90](0,1){$u_0$}
\uput{10pt}[-90](1,1){$u_1$}
\uput{10pt}[-90](2,1){$u_2$}
\uput*{10pt}[-90](4,1){$u_{k-s-t}$}
\rput[r](-1.5,1){$s$ vertices $\Bigg\{$}
\rput[l](5.6,1){$\Bigg\} t$ vertices}
\end{pspicture}
\caption{The graph $\mathcal{P}(k,s,t)$}\label{pkst}
\end{figure}

\end{document}

• +1 for \psforeach... – user197952 Oct 14 '19 at 9:37

You can resize a pspicture, without resizing the text – which leads to inconsistent font sizes, using \psset{unit=...} at the beginning (the default unit is 1cm; I chose here unit=0.8cm). Here is an example. I took the opportunity to simplify your code, with a systematic use of psnodes, and the adjunction of the pst-eucl package/

    \documentclass[a4paper,, oneside]{article}

\usepackage{pst-all, pst-eucl}

\begin{document}

\begin{figure}
\psset{unit=0.8cm}
\centering
\begin{pspicture}(-3.5,-1.3)(7.5,1.3)
\pstGeonode[PointName={u_0,u_1,u_2,none, u_{k-s-t},none}, PosAngle=-90](0,0){U0}(1,0){U1}(2,0){U2}(3,0){U3}(4,0){U4}(5.4,0){B0}
\psline(U0)(U2)\psline[linestyle=dashed, dash=3pt 2pt](U2)(U3)\psline(U3)(B0)
\foreach \ang/\i in {-50/1,-30/2,30/3,50/4}{\dotnode[PointName=none](-1.4;\ang){A\i}\AtoB(A\i)(U4){B\i} \psline(A\i)\psline[arrows=-*](U4)(B\i)}
\pstArcOAB[linestyle=dotted]{U0}{A1}{A4}
\pstArcOAB[linestyle=dotted]{U4}{B2}{B3}
\pnodes[-0.8em, 0](A2){C2}(A3){C3}
\pnodes[0.8em, 0](B2){D2}(B3){D3}
\psset{braceWidth=1pt, braceWidthInner=3pt, braceWidthOuter=3pt}
\psbrace[ref=rC, nodesepA=-2pt](C2)(C3){$s$ vertices}
\psbrace[ref=lC, nodesepA= 2pt](D2)(D3){$t$ vertices}
\end{pspicture}
\caption{The graph $\mathcal{P}(k,s,t)$}\label{pkst}
\end{figure}

\end{document}


text:
# How to derive the weak form of a system of PDEs?

I'm trying to compute the weak form of a system of PDE's over a bounded domain $\Omega$ with boundary $\partial\Omega$. Let $u\in\mathbb{R}^3, p\in\mathbb{R}$. Then: $$-\nabla\cdot\left(\nabla u+pI\right)=f \text{ in }\Omega, \\ \nabla\cdot u=0 \text{ in }\Omega.$$ If $\partial\Omega=\Gamma_D\cup\Gamma_N$ and $\Gamma_D\cap\Gamma_N=\emptyset$, the boundary conditions are: $$u=u_0 \text{ in }\Gamma_D, \\ \nabla u\cdot n + p n = g \text{ in }\Gamma_N.$$ with $f,g:\mathbb{R}^3\rightarrow\mathbb{R}^3$, $I$ the matrix identity and $n$ the normal vector.

My fundamental question is: For the complete weak form, should I derive first the weak forms of the separate PDEs and then add them up to a single form?

For reference, this is taken from here. Thanks for your help!

-


text:
# Largest cages Killer Sudoku

Task 1: Find the maximum value of $n$ for which it is possible to create a regular uniquely-solvable Killer Sudoku (9x9) such that every cage has atleast $n$ cells in it.

Rules for killer sudoku

Quoting Wikipedia

The objective is to fill the grid with numbers from 1 to 9 in a way that the following conditions are met:

1. Each row, column, and nonet contains each number exactly once.
2. The sum of all numbers in a cage must match the small number printed in its corner.
3. No number appears more than once in a cage.

Task 2: What if rule number 3 was ignored?

• Why does this imply n <= 9? Hexadecimal sudoku's are entitely possible, is there Some theory that excludes them from being valid solutions or are you limiting them yourself? Dec 26 '15 at 7:19
• I must admit that I misread the question before, I'm now assuming that you only want this answered for a regular sudoku, (I didn't notice that n was the cage size, not the sudoku size) Dec 26 '15 at 9:28
• @DrunkWolf I meant a 3x3 Sudoku Dec 26 '15 at 10:13
• I am fairly sure that for task 1. n < 9 since for (3) to hold every cage would be constrained to containing all 9 numbers once each and the only possible cage arrangements would be the 9 nonets, the 9 rows or the 9 columns. Apr 23 '16 at 13:05
• @JonathanAllan As far as I can tell, the cages are not necessarily rectangle shaped (they might not even have to be contiguous). However, for a solution of an $n=9$ Killer, you could apply a permutation of the numbers 1-9 and still get a solution. Apr 23 '16 at 17:45

$n=36$

The approach

The biggest $n$ we could hope to find is $81$ with a single cage which is obviously not going to work.
The next biggest would be $40$ with two cages of $41$ and $40$ cells.
We need to get as close to this as possible while enforcing uniqueness, which means we need to first force some cell to be some value and then have that force another and so on cascading through the entire sudoku.

How to achieve that?

Make it so one cage has rows and columns containing $(1),(1,2),\dots,(1,2,3,4,5,6,7,8,9)$ overlapping on the highest numbers and the other has the rest (overlapping on the smallest numbers). The two cages will now be the cages with the smallest and largest possible sums for their sizes too.
Two separate ones and two separate nines will fall out first, then two pairs of "a one and a two" and two pairs of "a nine and an eight", and so on until the whole sudoku is filled in the only way possible.

The cage sums will be

For the $[1,9]$ ($45$ cells) $\sum_{i=1}^9(\sum_{j=1}^ij)=165$
For the $[1,8]$ ($36$ cells) $405-165=240=\sum_{i=1}^8(\sum_{j=10-i}^9j)$

That is

$165=(1)+(1+2)+(1+2+3)+(1+2+3+4)+(1+2+3+5)+(1+2+3+4+5+6)+(1+2+3+4+5+6+7)+(1+2+3+4+5+6+7+8)+(1+2+3+4+5+6+7+8+9)$

And

$240=(9)+(9+8)+(9+8+7)+(9+8+7+6)+(9+8+7+6+5)+(9+8+7+6+5+4)+(9+8+7+6+5+4+3)+(9+8+7+6+5+4+3+2)$

Can we do it?

Yes, here is one:

which has the unique solution:

The first cells to fall out are:
$A9$ (the only column in $165$ with one cell);
$I1$ (the only row in $165$ with one cell);
$A8$ (the only row in $240$ with one cell); and
$F1$ (the only column in $240$ with one cell)

Now the rows and columns with two cells for each are uniquely defined - they must have values $(1,2)$ and $(9,8)$ respectively and one of each pair cannot be the $1$ or $9$ due to those already placed in either the same row or column - these are (in the same order as before):
$(D8,D9)$;
$(F2, I2)$;
$(A7,D7)$; and
$(C1,C2)$

This same process then cascades through to completion.

• Brain hurts now; task 1 will be harder. Apr 24 '16 at 18:08
• Great answer. I'll probably award the bounty to you. I can award another 100 rep for solving the other task, if you (or anyone else) manages to do it Apr 25 '16 at 10:40

To get things going: a simple observation giving us an upper bound $n \leq 8$ for task 1.

Task 1 for $n=9$ (creating a uniquely solvable $9 \times 9$ killer Sudoku with cages of size $n=9$) can not be accomplished. This follows from the fact that if a solution would exist such that each row, each column, each nonet and each 9-cage contains the numbers $1, .. 9$, one could swap any two numbers across the grid (e.g. swap all $1$'s and $2$'s) and thereby obtain another solution.


text:
# You have just turned 22 years old. Now you must decide how much money to put into your retirement...

You have just turned 22 years old. Now you must decide how much money to put into your retirement plan. The plan works as follows: Every dollar in the plan earns 6.6% per year. You cannot make withdrawals until you retire on your 65th birthday. After that, you can make withdrawals as you see fit. You decide that you will plan to live until 100 and work until you turn 65. You estimate that to live comfortably in retirement, you will need $110,000 per year, starting at the end of the first year of retirement and ending on your 100th birthday. You will contribute the same amount to the plan at the end of every year that you work. How much will you need to contribute each year to fund your retirement? ## Saving for Retirement: Saving for retirement is one of the most important financial decisions in life. Retirement is often financed through periodic contributions to a saving account during one's working age. A critical piece of information is the future value of the contributions near retirement. ## Answer and Explanation: The annual contribution is$6,991.13.

The annual contribution, denoted by {eq}M{/eq}, must be such that the future value of these contributions (which are an annuity), will have a future value that is equal to the present value of the post-retirement expenses.

To find the required contribution, we first compute the present value (at retirement time) of future expenses. Annual expense is 110,000, and there are (100 - 65) = 35 years of expenses. The value of these expenses at retirement time is:

• {eq}\displaystyle \frac{110,000*(1 - (1 + 6.5\%)^{-35})}{6.5\%} = 1,505,565.24 {/eq}

Between 22 and 65, there are 43 annual contributions. For the contribution to support the expenses, we must have:

• {eq}\displaystyle \frac{M*((1 + 6.5\%)^{43} - 1)}{6.5\%} = 1,505,565.24 {/eq}

which yields:

• {eq}M = 6,991.13 {/eq}


text:
# How is volatility different from variance?

I always thought volatility was just variance ^ (1/2). Now I'm reading this book and it's saying that the two are different concepts. Excerpts include:

Partly due to its use in Black-Scholes, historically, volatility has been used as the measure of deviation for financial assets. However, the correct measure of deviation is variance (or volatility squared). Volatility should be considered to be a derivative of variance. The realisation that variance should be used instead of volatility led volatility indices, such as the VIX, to move away from ATM volatility (VXO index) towards a variance-based calculation.

There are three reasons why variance, not volatility, should be used as the correct measure for volatility. However, despite these reasons, even variance swaps are normally quoted as the square root of variance for an easier comparison with the implied volatility of options (but we note that skew and convexity mean the fair price of variance should always trade above ATM options).

What does that even mean? Why would variance be a be a better measure of volatility if it's just the square of volatility. Isn't that like saying feet are better than inches for measuring stuff?

Variance takes into account implied volatility at all stock prices. Variance takes into account the implied volatility of all strikes with the same expiry (while ATM implied will change with spot, even if volatility surface does not change).

How in the world does variance take into account the IV of all strikes? If I take the IV of a 30d Call and square it, suddenly that gives me more information than just the IV itself?

• You are getting confused because volatility and variance in your text do not mean times series volatility and time series variance. Those refer to implied volatility on one hand (which is defined for any option contract) whereas variance in the text context is meant to represent some measure of overall implied risk in the market. – Ezy Jan 10 at 1:27
• which book??? pls. give a reference – vonjd Jan 10 at 9:28

Let's skip calling it volatility and variance. Let us deal with variance and standard deviation.

For normally distributed variables, it is very important to distinguish between the true variance and the estimator of the variance and the estimator of the standard deviation.

Variance in its raw form is important in defining the statistical law that governs the sample data, while the standard deviation plays no role (unless you pretend to square it). Variance is the second central moment of the normal distribution. Variance, in its raw form, defines all mean-variance models.

That is great if you know it, but if you do not know it, then the estimators are a bit more of a headache than most people realize.

Finance models such as the CAPM, APT, Fama-French or Black-Scholes are strictly Frequentist models. Constructed in a Bayesian space, the results won't come out the same at all. So we need to remain inside Frequentist conceptualizations of a mean, a variance, and a standard deviation.

The minimum variance unbiased estimator of the mean is $$\bar{x}=\frac{\sum_{i=1}^n}{n}.$$ This is also the maximum likelihood estimator.

The maximum likelihood estimator of the variance is $$s^2_{MLE}=\frac{\sum_{i=1}^n(x_i-\bar{x})^2}{n}.$$ Jointly, with the sample mean, this is the most efficient estimator of the variance, but it is a biased estimator. As we are in the Frequentist mindset and not Fisher's likelihood-based model, we have to have an unbiased estimator. Because it would take up a lot of space, I am not going to provide a proof, though it is easy to find online, but the unbiased estimator of the variance is $$s^2_{MVUE}=\frac{\sum_{i=1}^n(x_i-\bar{x})^2}{n-1}.$$

So far, so good, we are in the same place as a first-semester statistics textbook. But what is different is that the unbiased estimator of the standard deviation is not $$s=\sqrt{\frac{\sum_{i=1}^n(x_i-\bar{x})^2}{n-1}}.$$ Instead, this is the sample standard deviation. It is a biased estimator because the square root is a concave function and it distorts the estimator. It isn't generally true that $$\mathbb{E}(f(\tilde{x}))=f(\mathbb{E}(\tilde{x}))$$.

There is a somewhat complicated correction required to make it unbiased. For small samples, the difference is quite large, but for very large samples the impact is nominal and could be ignored.

The issue is somewhat technical, but these models are somewhat fragile and depend strongly on how they are constructed. The mean-variance models are not supported empirically. They are built inside an axiom system and really do depend on it.

It might be better to think of volatility as the scale measurement of a distribution. For the normal distribution, this is the variance. However, not all distributions have a variance, but many still have a scale parameter. The variance is a somewhat narrow and very important conceptualization of scale. Where it exists it has deep mathematical meaning.

Informally, using the sample standard deviation is usually harmless, but if you are really modeling large sums of money, the small effects turn into real amounts of money. It is technically wrong and on large sums it is also a lot of money.

How in the world does variance take into account the IV of all strikes? If I take the IV of a 30d Call and square it, suddenly that gives me more information than just the IV itself?

If the theory is literally true, then the variance fully describes both all errors of commission and all errors of omission in every state of nature. This is why people like working with the normal model. You do not have to do anything else. Because the square root is concave, you actually do lose information within the theory. The statistic wouldn't be sufficient for the parameter. A statistic is sufficient if $$\Pr(\bf{X}|\boldsymbol{\theta})=\Pr(t(\mathbf{X})|\boldsymbol{\theta}),$$ where $$\bf{X}$$ is the sample, $$t$$ is some function of the data (a statistic), and $$\boldsymbol{\theta}$$ are the parameters. This isn't going to be true, so the information in the sample about the parameter is not the same as information in the statistic about the parameter. It can only be less.

• Could you elaborate on As we are in the Frequentist mindset and not Fisher's likelihood-based model, we have to have an unbiased estimator.? Is unbiasedness of an estimator somehow a basic requirement in frequentist statistics? – Richard Hardy Jan 15 at 13:15
• No, the unbiasedness isn't important, but the frequencies so regions exist is important. They can give rise to a decision function. Fisher gives you a p-value which implies no behavior. Actually, on re-read, I need to clean this up in a few places. The unbiasedness isn't incidental, but the universe won't vanish without it for theory purposes. However, the question was on the unbiasedness of the estimator and how it is linked to theory. – Dave Harris Jan 15 at 14:41

It's probably a good book, but I don't entirely agree with the excerpt.

Also, volatility and variance come in many flavours which is not sufficiently explained in the excerpt. For instance, depending on the flavour, the statement "volatility should be considered as a derivative of variance" is shaky at best.

In any case, the statement that variance (or actually expected variance) takes into account the IV of all strikes is correct, and is basically the formula for the variance swap strike as a weighted sum (integral) of implied variances, which you can find in eg Gatheral's book "The volatility surface".


text:
# 4 ways to read a file in R... by columns

##### Posted on June 23, 2012

Ever wonder how to read a file in R by columns? This question comes to mind when your analysis doesn’t require to import all the data in R, especially if the file is huge.

Sometimes you just want to read some columns, do some data manipulation, and plot some graphics. How can you do that in R? I’ll show you four different ways to do that without having to use a data base management system (DBMS) and SQL queries.

### Toy example

For this post let’s consider a toy dataset of 12 rows and 7 columns in csv (comma-separated value) format. For instance, a dataset like the following one:

### Option 1: cut and system

The first option consists of using a cut command with the desired columns, and calling this command within the system() function. The only “problem” is that the data will be stored in a vector. It is not the best solution if what you want is a data frame, but it can do the trick if you want to quickly inspect the columns.

### Option 2: cut and pipe

The second option is similar to the first one. It consists of calling a cut command but this time from the pipe() function, which in turn is contained inside a read.csv() function.

### Option 3: package colbycol

The third option consists of using the very handy function cbc.read.table() that comes with the package "colbycol" (by Carlos Gil)

### Option 4: package limma

The last option consists of using the function read.columns() that comes with the "limma" package (by Gordon Smyth et al). Just a small detail: "limma" is in Bioconductor, not in CRAN. In this case, you need to specify the names of the columns to be read.

Happy data analysis!

Published in categories how-to  Tagged with file  read  columns


text:
# ipkiss3.all.device_sim.CSTTDSimulation¶

class ipkiss3.all.device_sim.CSTTDSimulation(**kwargs)

Define a simulation for use with CST Studio Suite ® (Time Domain solver).

For the tutorial, please check CST Studio Suite tutorial.

The following parameters are exposed to CST Studio Suite (you can also see them in the “Parameter List” window):

• bbox_xmin, bbox_xmax, bbox_ymin, bbox_ymax, bbox_zmin, bbox_zmax: the bounding box geometry where the simulation is defined
• port_{{PORT_NAME}}_xmin, xmax, ymin, ymax, zmin, zmax : the port locations.
• start_freq, stop_freq, center_freq: start, stop and center frequency.
Parameters: geometry: SimulationGeometry, required The geometrical setup (objects, materials, …) we want to simulate cst_exe_path: str, optional Path to the cst exe ‘CST DESIGN ENVIRONMENT.exe’. By default guess from registry keys. iconified: optional Run the CST Studio Suite in iconified mode. material_folders: list and List with type restriction, allowed types: [], optional List of paths which contain native CST materials. project_folder: str, optional Path of the CST project folder (default = current working dir) project_template: str, optional Path of the CST project template. verbose: optional Log messages to the messages pane when set to True. monitors: list, optional Monitors to capture the fields within a simulation outputs: list, optional Outputs of the simulation. setup_macros: list and List with type restriction, allowed types: (, ), optional Tool-specific macros to run as part of the job setup. solver_material_map: dict, optional Mapping of ipkiss TECH.MATERIALS items onto names that represent a native material in a electromagnetic solver. If specified, this map is used to reuse the native materials in the solver. Default is empty, which means we use the information available from TECH.MATERIALS to create the different materials in the solver. engine: locked


text:
+0

+1
201
6
+507

Two rays with common endpoint O form a 30-degree angle. Point A lies on one ray, point B on the other ray, and AB=1. What is the maximum possible length of OB?

What I did so far, is I let AO=a and BO=b, and I used the Pythagorean theorem on AOD and AOB. I got b = sqrt(1-a^2/4)+a*sqrt(3)/2, but I'm not sure how to proceed from there.

Jul 21, 2019

#1
+28357
+3

As follows:

Let side OA (opposite angle B) be b, and side OB (opposite angle A) be a.

From the cosine rule we have:  $$1^2=a^2+b^2-2ab\frac{\sqrt3}{2}$$  remembering that $$cos(30\deg)=\frac{\sqrt3}{2}$$.

Rewrite as a quadratic in a:  $$a^2-\sqrt3ba+b^2-1=0$$

Solve for a in terms of b:  $$a=\frac{\sqrt3}{2}b+\frac{\sqrt{(2+b)(2-b)}}{2}$$  (This solution will give the largest value of a)

Differentiate a wrt b to get:  $$\frac{da}{db}=\frac{\sqrt3}{2}-\frac{b}{2\sqrt{(2+b)(2-b)}}$$

Set this to zero and solve for b to get:  $$b=\sqrt3$$

Substitute this back into the expression for a above to get:  $$a=2$$

.
Jul 21, 2019
edited by Alan  Jul 21, 2019
#2
+507
+2

How did you get that equation that would give you the largest value of a?

Also, why can't OB = 2, for example?

Jul 21, 2019
edited by Davis  Jul 21, 2019
#3
+106993
+1

I do not get that either Alan .

Melody  Jul 21, 2019
#4
+28357
+1

Deleted.

Alan  Jul 21, 2019
edited by Alan  Jul 21, 2019
edited by Alan  Jul 21, 2019
edited by Alan  Jul 21, 2019
edited by Alan  Jul 21, 2019
#5
+1

Consider a circle, radius 1 , with its centre on the line OB .

Move b' away from O.

The maximum distance Ob' will happen when the line OA is tangential to the circle.

When that happens the line from OA to OB will be at right angles to OA.

Ob' will then be the hypotenuse of a 30 deg right-angled triangle.

In that triangle, 1/Ob' = sin(30 deg) =1/2.

So 0b' = 2.

Jul 21, 2019
#6
+507
+1

Thanks!

Davis  Jul 21, 2019


text:
# prove inequality

• Sep 2nd 2008, 09:06 PM
Dubulus
prove inequality
ok heres the prob....the statement below is not always true for x, y (symbol for real numbers). give an example where it is false, and add a hypothesis on y that makes it true. "if x and y are nonzero real numbers and x>y then (-1/x)>(-1/y)"
• Sep 2nd 2008, 09:18 PM
Dubulus
(-1/-1) > (-1/-2) makes
1 > 1/2 which is true
• Sep 2nd 2008, 09:26 PM
particlejohn
Choose $x = 2, y = -1$. Add hypothesis: $y$ is same sign as $x$.
• Sep 3rd 2008, 08:33 AM
kwah
Consider the four cases {{ note: for some reason, > is showing as an upside down ? }}:

Quote:

$\begin{tabular}{c c l}
x & y & comment/result\\
+ & + & True\\
+ & - & LHS -ve and RHS +ve therefore false\\
- & + & in breach of x > y which is given\\
- & - & True (see particlejohn's post below)\\
\end{tabular}$

From this, you can see that both $x$ and $y$ must have the same sign.

EDIT: apologies.. particlejohn is correct and my post has been edited accordingly =]
• Sep 3rd 2008, 12:56 PM
particlejohn
Quote:

Originally Posted by kwah
Consider the four cases {{ note: for some reason, > is showing as an upside down ? }}:

From this, you can see that both $x$ and $y$ must be positive.

Choose $x = -3$ and $y = -4$ (e.g. $x > y$). Then $\frac{1}{3} > \frac{1}{4}$.


text:
## Background: The continuous seek out fresh lead compounds as viable inhibitors

Background: The continuous seek out fresh lead compounds as viable inhibitors of specific enzymes associated with carbohydrate metabolism has intensified. saturated (palmitic acidity and stearic acidity) essential fatty acids (Zhang et al., 1996). CE can be abundant with phosphorus and potassium (Belewu and Belewu, 2007). Ingredients of CE have already been utilized as anti-cancer, anti-microbial, anti-diarrhoea, anti-flatulence aswell as in the treating anaemia, urinary system attacks and hypercholesterolemia (Chevallier, 1996; Martinez, 2003; Mohammed et al., 2005; Borges et al., 2008; Adejuyitan et al., 2009; Anderson et al., 2009). Prior reports also uncovered CE to become nontoxic, practically secure, and with significant aphrodisiac properties (Ajani et al., 2016; Sabiu et al., 2016a). Diabetes mellitus (DM) can be a metabolic disorder with significant effect on the well-being and standard of living of humans. The condition is significantly rising among the biggest heath problems to individual (Vasim et al., 2012). The global occurrence of DM uncovered around 171 million people as victims of the condition in 2000, and it’s been projected how MK-0679 the prevalence increase to 366 million by 2030 if no practicable and lasting intervention is followed (Outrageous et al., 2004). A far more recent record on its global prevalence provides predicted a rise in this shape, pegging it at well above 438 million by 2030 (Colagiuri, 2010). With this prediction, somebody dies from its problems every 10 sec and 1 atlanta divorce attorneys 5 persons could be gravely affected. In sub-Saharan Africa, DM can be an important rising disease delivering South Africa as the utmost affected using a prevalence of 8.3% and closely accompanied by Nigeria (4.5%) (IDF, 2014). This exponential upsurge in the prevalence of DM could be either because of changes in diet plan (highly refined diet plans), maturing and lifestyle from the people (decreased exercise, urbanization etc.) or ravaging aftereffect of free of charge radicals (Crazy et al., 2004). While orthodox interventions have already been embraced and also have became effective in the treating DM, affordability, awareness and unwanted effects possess undermined their uses (Campbell et al., 1996). Oddly enough, the administration of diabetes via organic sources (as MK-0679 possible alternative) continues to be attained either by inhibiting free of charge radical occasions or/and inhibition of crucial enzymes (-amylase and -glucosidase) involved with starch digestive function (Sabiu and Ashafa, 2016). The occurrence of DM can be closely associated with elevated free MK-0679 of charge radical formation and malfunctioning antioxidant MK-0679 protection systems (Maritim et al., 2003). Additionally, the incident of oxidative tension is an essential event in both diabetogenic process and its own secondary problems (Lipinski, 2001). In light of the, antioxidant-rich resources could serve an excellent diet treatment in the administration of the condition. Besides being abundant with antioxidant minerals and vitamins (Belewu and Belewu, 2007) and its own flour routinely suggested among the diet control choices for the diabetics, components from CE have already been used to take care of and manage diabetes (Salwa et al., 2010). Nevertheless, there is info gap around the tentative system for the usage of the draw out to take care of such debilitating condition. This study, consequently looked into the appropriateness of CE draw out as a diet option for the administration of DM by analyzing its -amylase and -glucosidase inhibitory actions. The antioxidant house of CEE was also decided. Materials and Strategies Chemical substances and reagents Acarbose was procured from Bayer Medical Co., Germany. While porcine pancreatic -amylase, rat intestine acetone natural powder (RIAP), antioxidant assays DPPH radical inhibition The DPPH radical scavenging aftereffect of CEE was examined as previously explained (Turkoglu et al., 2007). In short, 1 mL of differing methanolic concentrations (0.2-1.0 mg/mL) from the CEE or silymarin (regular) was put into 1 mL of 0.2 mM methanolic solution of DPPH. Likewise, sterile distilled drinking water (1 mL) was blended with an aliquot (1 mL) of 0.2 mM methanolic DPPH and used as control. Pursuing an incubation amount of 30 min at space heat in each case, the absorbance was go through against empty Rabbit Polyclonal to Collagen III at 516 nm utilizing a spectrophotometer (Beckman, DU 7400, USA). The.


text:
## Sunday, September 24, 2006

### log (1 + x) = ∑ (n=1,∞) [(-1)n+1xn]/n

In today's blog, I use the fundamental theorem of calculus and the basic properties of derivatives to show that:
log (1 + x) = ∑ (n=1,∞) [(-1)n+1xn]/n

First, we need a lemma:

Lemma 1: 1/(x+1) = ∑ (i=1,∞) (-1)(i+1)*xi-1

for x ≠ -1

Proof:

(1) Let s = ∑ (i=1,∞) (-1)(i+1)*xi-1 which gives us:

s = 1 - x + x2 -x3 + ....

(2) xs = x - x2 + x3 - x4 + ...

(3) Then xs + s = 1

(4) Solving for s gives us:

s(x+1) = 1

so that:

s = 1/(x+1)

QED

Theorem: log (1 + x) = ∑ (n=1,∞) [(-1)n+1xn]/n

Proof:

(1) From Lemma 1 above;

1/(1+x) = ∑ (i=1,∞) (-1)(i+1)*xi-1

(2) d/dx(ln(1+x)) = 1/(1+x) since:

(a) Let g(x) = 1 + x

(b) Let h(x) = ln(x)

(c) Using the Chain Rule for Derivatives (see Lemma 2, here), we have:

d/dx(ln(1+x)) = d/dx(h(g(x)) = h'(g(x))*g'(x)

where:

h'(g(x)) = ln(1+x) = 1/(1+x) [see Lemma 1, here]

g'(x) = d/dx(1 + x) = d/dx(1) + d/dx(x) = 0 + 1 = 1

so:

d/dx(ln(1+x)) = [1/(1+x)]*1 = 1/(1+x)

(3) Since d/dx(ln(1+x)) = 1/(1+x), we know that ∫(1/(1+x)dx) = ln(1+x)+C [See Theorem 2, here]

(4) If we take the antiderivative of both sides (see Definition 2, here for definition of antiderivative), we have:

ln(1+x) = ∫(1 - x + x2 - x3 + ...)

(5) Using the linearity property of integrals (see Lemma, here) gives us:

ln(1+x) = ∫1 - ∫xdx + ∫x2dx - ∫x3dx + ...

(6) Using the power rule for integrals (see Lemma, here) gives us:

ln(1+x) = x - x2/2 + x3/3 -x4/4 + ....

QED

#### 1 comment :

hafiz said...

oh my god! you've really save me! I've forgot this.. thank you very much...


text:
This is the third blog post in a series - you can find the previous blog post here

In this blog post we are going to look at another spin-glass model. In the previous post we looked at the Sherrington-Kirkpatrick model which allowed us to study the spin-glass analytically. However there is a certain lack of "realism" in this model - the infinite interaction range means that the Sherrington-Kirkpatrick (in a sense) does not occupy any space, there is no concept of dimension nor geometry. While providing interesting mathematical results, some of which appear to be universal to spin-glass systems, we would like to look at a different model that captures more of the real world system and perhaps might uncover new behaviours.

## Introducing the Ising Model

One model that we can look at is the Edwards-Anderson Ising model. We have actually looked at these models achronologically: Edwards-Anderson proposed the Ising model before Sherrington-Kirkpatrick proposed theirs. In fact Sherrington-Kirkpatrick developed their model partly due to the difficulty in deal with the Ising model. I have presented the models in this order in this series of blog posts because it feels more natural to look at models in increasing complexity order rather than presenting a historical account.

The main difference between Ising and Sherrington-Kirkpatrick is the extent over which the interactions can occur, instead of an infinite range the Ising model only allows "nearest-neighbour" interactions. This relaxation means that there is a concept of dimension and geometry to an Ising spin-glass. For example we could think of spins oriented on a line segment (a finite 1d Ising model), a square lattice (a 2d Ising model) or something more exotic like spins oriented on the nodes of a 32 dimensional hexagonal lattice. Through careful use of limits we could also consider infinite-dimensional Ising models too. The Hamiltonian follows the form one would expect: $$H = - \sum_{\lt x,y \gt} J_{xy} \sigma_x \sigma_y - h \sum_x \sigma_x$$ Where we use the notation $\lt x,y \gt$ to denote the sum occuring over neighbour pairs.

As before the selection of $J_{xy}$ is somewhat arbitrary, however unlike the Sherrington-Kirkpatrick we do not have to scale this with lattice size to retain meaningful "average energy" or "average magnetism" measurements when we increase the size of the system. If we take $J_{xy} = J$ for some fixed $J$ we get the Ising model of Ferromagnetism, if we allow $J_{xy}$ to vary according to some distribution we get the Edwards-Anderson Ising Model. In this blog we will use the term "Ising model" to refer to either situation, the mathematics of moving from the fixed $J$ case usually involves integrating against the density function, this can lead to more complicated formulae so in this blog we will mainly focus on the ferromagnetic case unless otherwise stated.

As before spins can only take values $\pm 1$ - in some literature this is referred to as "Ising spins" (e.g. you can read references to "Sherrington-Kirkpatrick with Ising spins" - this means an infinite interaction range with binary spins).

A pictorial representation of a 3d square lattice Ising spin-glass can be seen below:

For the rest of this article we will limit ourselves to talking about "square" lattices since this is where the majority of research is focussed. Using different lattice types won't change the story too much.

In studying these models it is also worth noting what happens on the "boundary" of the lattice: for finite size systems this can become an issue. In this blog post we will skirt over the issue, where necessary we will assume periodic boundary conditions (i.e. there is a toroidal type geometry to the system) so each "edge" of the lattice is connected to an opposing one, so in a sense there are no boundary conditions to specify.

## 1D Ising Model

We will now consider a 1 dimensional Ising model where spins are located on a line segment. This simplication means that finding the ground state (minimal energy spin configuration) is trivial: we pick a site in the middle of the line segment (the origin) we will pick a spin ($\pm 1$) at random. We then propagate out from the origin in the left and right direction, we pick the spin for the next site according to the interaction strength for example: if $\sigma_0 = +1$ and $J_{0,1} > 0$ then $\sigma_1 = +1$ and so on. We can see that (as with all spin glass systems) there is a symmetry: if we flip all the spins direction we end up with an equivalent energy - we call these "pairs" of configurations. It doesn't take much convincing to realise that the pair of configurations we constructed is a unique minima for the system. To see this imagine we have only one pair of spins that opposes the direction indicated by the interaction strength. For a large enough system we can eventually find another interaction strength that is greater in magnitude (by definition having a spin pair as indicated by the sign of the interaction strength). By simply flipping the relative orientation of the pairs we will end up with a configuration of lower energy - which is a contradiction.

We will now look to solve the 1d Ising model analytically. For simplicity we will assume no external magnetic field, this just makes the formulae look "prettier". The crux of understanding any spin glass system is finding the Gibbs distribution, as before: $$P(\sigma) = \frac{exp(-\beta H_{\sigma})}{Z_{\beta}}$$ Where: $$H = - \sum_{\lt x,y \gt} J_{xy} \sigma_x \sigma_y$$ And $\beta$ is the inverse temperature. We can write an expression for the partition function as: $$Z_{\beta} = \sum_{\sigma} exp(-\beta H_{\sigma}) = \sum_{\sigma} exp(-\beta \sum_{\lt x,y \gt} J_{xy} \sigma_x \sigma_y)$$ Suppose we look at a line segment with $N$ spins, we can then write this as: $$Z_{\beta} =\sum_{\sigma_1, ..., \sigma_N} exp(-\beta (J_{1,2}\sigma_1 \sigma_2 + J_{2,3}\sigma_2 \sigma_3 + ... + J_{N-1,N}\sigma_{N-1}\sigma_N))$$ We notice that we can factorise this summation as: $$Z_{\beta} =\sum_{\sigma_1, ..., \sigma_{N-1}} exp(-\beta (J_{1,2}\sigma_1 \sigma_2 + ... + J_{N-2,N-1}\sigma_{N-2}\sigma_{N-1}))\sum_{\sigma_N}exp(-\beta J_{N-1,N} \sigma_{N-1} \sigma_N)$$ The internal sum can then be evaluated: $$\sum_{\sigma_N}exp(-\beta J_{N-1,N} \sigma_{N-1} \sigma_N) = exp(\beta J_{N-1,N} \sigma_{N-1} ) + exp(-\beta J_{N-1,N} \sigma_{N-1} ) = 2cosh(\beta J_{N-1,N} \sigma_{N-1}) = 2cosh(\beta J_{N-1,N})$$ The last equality making use of the fact $\sigma_{N-1} = \pm 1$ and that $cosh(x) = cosh(-x)$. By repeating this process we can express the partition function as: $$Z_{\beta} = 2 \prod_{i=1}^{N-1} 2 cosh(\beta J_{i,i+1})$$ We can evaluate this exactly. If we are sampling the interaction strengths according to some distribution we can find expected values (or other statistical properties) by integrating against the density function as usual, since this adds to notational complexity we will assume that the interaction strengths are fixed for now. We can then calculate thermal properties using the equations:

\begin{align} F &= - \frac{1}{\beta} ln Z_{\beta} = - T ln 2 - T \sum_{i=1}^{N-1} ln (2 cosh(\beta J_{i,i+1})) \\ U &= - \frac{\partial}{\partial \beta} ln Z_{\beta} = - \sum_{i=1}^{N-1} J_{i,i+1} tanh(\beta J_{i,i+1}) \\ C &= \frac{\partial U}{\partial T} = \sum_{i=1}^{N-1} (\beta J_{i,i+1})^2 sech^2(\beta J_{i,i+1}) \\ S &= \frac{U - F}{T} = ln2 + \sum_{i=1}^{N-1} \left( -\beta J_{i,i+1} tanh(\beta J_{i,i+1}) + ln(2cosh(\beta J_{i,i+1}) \right) \end{align}

Where:
F - is the Helmholtz-Free Energy
U - is the thermodynamic energy (ensemble average)
C - is the heat capacity
S - is the entropy

We can find the expected value of a given instantiation of interactions through an integral such as: $$\mathbb{E}(U) = - \sum_{i=1}^{N-1} \int J_{i,i+1} tanh(\beta J_{i,i+1}) Q(J_{i,i+1}) dJ_{i,i+1}$$ With $Q(J)$ being the density function of the distribution and the integral occuring over its support. Similar formulae exist for the other thermodynamic variables and you can calculate other statistics (e.g. variance) in the usual way.

We can plot the values of these variables for a given set of interaction weights:

# This code creates a 4 figure plot showing how
# Thermodynamic variables change with temperature
# For a 1d Ising Model with Gaussian interactions

import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline

# Fix seed
np.random.seed(123)

# Fix number of points
N = 100

# Instantiate interaction strength
J = np.random.normal(0,1,size=N-1)

# Set temperature ranges
T_min = 1e-4
T_max = 5
T_steps = 1000
T = np.arange(T_steps)/T_steps *(T_max - T_min) + T_min
beta = 1 / T

# Set up holders for variables
F = np.zeros(T_steps)
U = np.zeros(T_steps)
C = np.zeros(T_steps)
S = np.zeros(T_steps)

# Loop over T_steps and calculate at each step
for i in range(T_steps):
F[i] = - T[i] * np.log(2) - T[i] * (np.log(2*np.cosh(beta[i]*J))).sum()
U[i] =  - (J * np.tanh(J * beta[i])).sum()
C[i] = ((beta[i] * J)**2 * (np.cosh(beta[i] * J))**-2).sum()
S[i] = (U[i] - F[i]) / T[i]

# Divide by number of points to give a scale invariant measure
F = F / N
U = U / N
C = C / N
S = S / N

# Create plots
fig, axs = plt.subplots(2, 2, figsize=(10,10), gridspec_kw={'hspace': 0.25, 'wspace': 0.25})
axs[0, 0].plot(T, F)
axs[0, 0].set_title("Free Energy")
axs[0, 0].set(xlabel="T", ylabel="F / N")

axs[0, 1].plot(T, U)
axs[0, 1].set_title("Average Energy")
axs[0, 1].set(xlabel="T", ylabel="U / N")

axs[1, 0].plot(T, C)
axs[1, 0].set_title("Heat Capacity")
axs[1, 0].set(xlabel="T", ylabel="C / N")

axs[1, 1].plot(T, S)
axs[1, 1].set_title("Entropy")
axs[1, 1].set(xlabel="T", ylabel="S / N")

plt.show()

From these plots we can see there is no phase transition taking place - this is true for all 1d Ising models.

We can also calculate the correlation function for the system. By following a similar line of logic as before we find: $$\langle \sigma_n \sigma_{n+r} \rangle = \prod_{i=0}^{r} tanh(\beta J_{n+i, n+i+1})$$

We can plot this as a function of $r$ starting at the first position:

# This code creates a plot displaying
# The correlation function
# For a 1d Ising Model with Gaussian interactions

import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline

# Fix seed
np.random.seed(123)

# Fix number of points
N = 100

# Instantiate interaction strength
J = np.random.normal(0,1,size=N-1)

# Create holders for variables
r = np.arange(N)
corr_array = np.zeros(N)

# Fix beta
beta = 1

# Calculate correlations
tanh_array = np.tanh(beta * J)

for i in range(N):
corr_array[i] = tanh_array[:i].prod()

plt.plot(r[0:20], corr_array[0:20])
plt.title("Correlation Function")
plt.ylabel(r"$\langle \sigma_{1} \sigma_{r} \rangle$")
plt.xlabel("r")
plt.xticks(np.arange(11)*2)
plt.ylim((-1,1))
plt.xlim((0,20))
plt.show()

As we can see there is a specific "structure" to the correlation function given an instantiation - this is not particularly surprising. If we picked an alternate starting state (e.g. the 2nd site) this graph can look totally different, the decay in absolute value will be similar however. We also notice that the correlation decays to zero fairly rapidly suggesting there isn't a long range structure to the model.

## 2d Ising Model

We now turn our attention to the 2d Ising model. The mathematics here will, understandably, get more complicated. We will require a bit more sophistication to solve this system. The solution was originally published by Lars Onsager in 1944, with alternative proofs and derivations published later. The derivation itself is fairly involved and would take a blog post (at least) by itself to cover - I may come back to this at a later date. For now I will simply present the result for the free energy (F) in absence of a magnetic field ($h=0$): $$- \frac{\beta}{N} F = ln2 + \frac{1}{8\pi^2} \int^{2\pi}_{0} \int^{2\pi}_{0} ln \left[ cosh(2 \beta J_H) cosh(2 \beta J_V) - sinh(2 \beta J_H)cos(\theta_1) - sinh(2 \beta J_V)cos(\theta_2) \right]d\theta_1 d\theta_2$$ Where instead of $J_{xy}$ being sampled from a gaussian distribution we assume fixed interaction strengths $J_H$ and $J_V$ in the horizontal and vertical directions.

For simplicity we will take: $J_H = J_V = J$ and we can derive the thermodynamic properties (per site - e.g. $f=\frac{F}{N}$) of this system as: \begin{align} f &= \frac{-ln2}{2\beta} - \frac{1}{2\pi\beta} I_0(\beta, J) \\ u &= -J coth(2\beta J) \left[ 1 + \frac{2}{\pi} \left( 2tanh^2(2\beta J) -1 \right) I_1(\beta, J) \right] \\ c &= 2J\beta^2 \left[U csch(2\beta J)sech(2\beta J) + \frac{8J}{\pi} sech^2(2\beta J) I_1(\beta, J) - \frac{2 \beta J}{\pi}(cosh(4\beta J)-3)^2 sech^6(2\beta J) I_2(\beta, J) \right] \\ s &= \frac{U - F}{T} \end{align}

For convenience I created 3 new functions $I_0(\beta,J), I_1(\beta, J)$ and $I_2(\beta, J)$ to make the equations a little shorter. These functions are defined as: \begin{align} I_0(\beta, J) &= \int^\pi_0 ln \left[ cosh^2(2 \beta J) + sinh^2(2 \beta J) \sqrt{1 + csch^4(2 \beta J) - 2 csch^2(2 \beta J) cos(2\theta)} \right] d\theta \\ I_1(\beta, J) &= \int^{\frac{\pi}{2}}_0 \left[1 - 4csch^2(2\beta J)( 1 + csch^2(2\beta J))^{-2} sin^2(\theta) \right]^{-\frac{1}{2}} d\theta \\ I_2(\beta, J) &= \int^{\frac{\pi}{2}}_0 sin^2(\theta)\left[1 - 4csch^2(2\beta J)( 1 + csch^2(2\beta J))^{-2} sin^2(\theta) \right]^{-\frac{3}{2}} d\theta \end{align}

As before we can produce plots of these:

# This code creates a 4 figure plot showing how
# Thermodynamic variables change with temperature
# For a 2d Ferromagnetic Ising Model with fixed interaction

import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline

# Fix seed
np.random.seed(123)

# Instantiate interaction strength
J = 1

# Set temperature ranges
T_min = 1e-4
T_max = 5
T_steps = 1000
T = np.arange(T_steps)/T_steps *(T_max - T_min) + T_min
beta = 1 / T

# Set up holders for variables
f = np.zeros(T_steps)
u = np.zeros(T_steps)
c = np.zeros(T_steps)
s = np.zeros(T_steps)

# Set up integrands for I0, I1, I2
def integrand0(x, b, j):
return np.log(np.cosh(2*b*j)**2 + np.sinh(2*b*j)**2 * np.sqrt(1 + np.sinh(2*b*j)**(-4) - 2*np.sinh(2*b*j)**(-2) * np.cos(2*x)))

def integrand1(x, b, j):
return (1 - 4*np.sinh(2*b*j)**(-2)*(1 + np.sinh(2*b*J)**(-2))**(-2)*np.sin(x)**2)**(-0.5)

def integrand2(x, b, j):
return np.sin(x)**2 * integrand1(x, b, j)**3

# Loop over T_steps and calculate at each step
for i in range(T_steps):
bt = beta[i]
I0 = quad(integrand0, 0, np.pi, args=(bt, J))
I1 = quad(integrand1, 0, np.pi/2, args=(bt, J))
I2 = quad(integrand2, 0, np.pi/2, args=(bt, J))
f[i] = - np.log(2) / (2 * bt) - I0[0] / (2 * np.pi * bt)
u[i] = -J*np.tanh(2*bt*J)**(-1) * ( 1 + (2/np.pi)*(2*np.tanh(2*bt*J)**2 -1)*I1[0])
c[i] = 2*bt**2*J*( u[i]*np.sinh(2*bt*J)**(-1)*np.cosh(2*bt*J)**(-1) + (8*J / np.pi)*np.cosh(2*bt*J)**(-2)*I1[0] - (2*bt*J/np.pi)*((np.cosh(4*bt*J)-3)**2)*np.cosh(2*bt*J)**(-6)*I2[0] )
s[i] = (u[i] - f[i])*bt

# Create plots
fig, axs = plt.subplots(2, 2, figsize=(10,10), gridspec_kw={'hspace': 0.25, 'wspace': 0.25})
axs[0, 0].plot(T, f)
axs[0, 0].set_title("Free Energy")
axs[0, 0].set(xlabel="T", ylabel="f")

axs[0, 1].plot(T, u)
axs[0, 1].set_title("Average Energy")
axs[0, 1].set(xlabel="T", ylabel="u")

axs[1, 0].plot(T, c)
axs[1, 0].set_title("Heat Capacity")
axs[1, 0].set(xlabel="T", ylabel="c")

axs[1, 1].plot(T, s)
axs[1, 1].set_title("Entropy")
axs[1, 1].set(xlabel="T", ylabel="s")

plt.show()

We find there is a critical temperature $T_c$ where the specific heat equation diverges. We can compute the value of this as satisfying: $$sinh\left(\frac{2J_H}{T_c}\right)sinh\left(\frac{2J_V}{T_c}\right) = 1$$ In the case where $J_H = J_V = J$ we have: $$T_c = \frac{2 J}{ln\left(1+\sqrt{2}\right)}$$ This is an example of a second order phase transition since the discontinuity only arises under a second derivative.

For temperatres under this critical temperature we have that the spontaneous magnetization can be calculated as: $$m = \left[ 1 - csch^2\left(\frac{2J_H}{T}\right)csch^2\left(\frac{2J_V}{T}\right) \right]^{\frac{1}{8}}$$

We can plot this (for $J_H = J_V = J = 1$) as:

# This code plots the spotaneous magnetization of
# a 2d Ising model on a square-lattice

import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline

# Set up temperature array
T_min = 1e-4
T_max = 5
T_steps = 1000
T = np.arange(T_steps)/T_steps *(T_max - T_min) + T_min

# Fix interaction strength constant
J = 1

m = np.power(np.maximum(1 - np.sinh(2*J/T)**-4,0), 1/8)

plt.plot(T,m)
plt.xlabel("T")
plt.ylabel("Magnetization")
plt.title("2d Ising Model Spontaneous Magnetization")
plt.xlim((0,5))
plt.show()

print("Critical Temp (Tc):", (2*J) / np.log(1 + np.sqrt(2)))

Critical Temp (Tc): 2.269185314213022

The correlation function is harder to compute, here we just present the correlation function between elements on the diagonal of the lattice:

$$\langle \sigma_{0,0} \sigma_{N,N} \rangle = det \left[ A_N \right]$$ Where $A_N = (a_{n,m})_{n,m=1}^N$ is an $NxN$ matrix with entries: $$a_{n,m} = \frac{1}{2 \pi} \int_0^{2\pi} e^{i(n-m)\theta} \sqrt{\frac{sinh^2(2\beta J) - e^{-i\theta}}{sinh^2(2\beta J) - e^{i\theta}} } d\theta$$

We can plot this as so:

# This code plots the diagnoal correlation function
# For the 2d square-lattice Ising model
# Lattice size = NxN
# At the critical temperature

import numpy as np
import matplotlib.pyplot as plt
%matplotlib inline

# Set up integrand function
imag = complex(0,1)
def integrand(x, n, m, beta, J):
return np.exp(imag*(n-m)*x)*np.sqrt((np.sinh(2*beta*J)**2-np.exp(-imag*x))/(np.sinh(2*beta*J)**2-np.exp(imag*x)))

# Set up constants
J = 1
beta = np.log(1 + np.sqrt(2)) / (2*J)

# Set up arrays
N_max = 20
N_array = np.arange(N_max+1)
correl_array = np.zeros(N_max+1)

for x in range(N_max + 1):
N = N_array[x]
A_N = np.zeros((N, N))

for n in range(N):
for m in range(N):
I = quad(integrand, 0, 2*np.pi, args=(n, m, beta, J))
A_N[n,m] = I[0]/(2*np.pi)

correl_array[x] = np.linalg.det(A_N)

# Plot correlations
plt.plot(N_array, correl_array)
plt.xlabel("N")
plt.ylabel(r"$\langle \sigma_{0,0} \sigma_{N,N} \rangle$")
plt.title("Correlation Function")
plt.xticks(np.arange(11)*2)
plt.ylim((0,1))
plt.xlim((0,20))
plt.show()

We can see that even though we have short range interactions (nearest neighbour) this gives rise to longer-range structure within the model. In fact we find for temperatures below the critical temperature there is an infinite correlation length, whereas for temperatures above the critical temperature the correlation length is finite.

## Infinte Dimension Ising Model

Next we consider the situation where the Ising model exists in infinite dimensions. In this case each site has infinitely many neighbours, as such a mean-field approximation is valid and we have a model that is somewhat similar to the Sherrington-Kirkpatrick fully connected geometry. (Please excuse the lack of rigour here; one has to be careful in how limits are defined and it is a non-trivial exercise. For this blog post I don't want to go down into that sort of detail.)

If each site has infinitely many neighbours we only need to concern ourselves with the ratio of positive and negative spin neighbours. By mean field if we take the probability of a positive spin as $p$ then via the Gibbs distribution we have: $$\frac{p}{1-p} = exp(2\beta H)$$ The average magnetization can then be calculated: $$\mathbb{E}\left[M\right] = (1)p + (-1)(1-p) = 2p - 1 = \frac{1 - exp(2\beta H)}{1 + exp(2\beta H)} = tanh(2 \beta H)$$

By investigating this function we can gain insight into spontaenous magnetization. Other similar arguments can be invoked for the other themodynamic properties. It is possible to show, as with the Sherrington-Kirkpatrick, that a phase transition occurs.

## n-d Ising Model ($n\geq3$)

Finally we look at the case where the dimension of the model is finite but strictly greater than 2. In this situation things get much trickier, in fact there are not many defined mathematical results in these systems and this is the subject of current research. As such I will just briefly outline some of the approaches that have been suggested to study these systems and their properties (presented in chronological order from when they were proposed):

• Replica-Symmetry Breaking - From our previous post on Sherrington-Kirkpatrick models we briefly looked at this sort of method. They were an obvious first choice in trying to deal with short range interactions. It has been shown that the "standard" techniques are insufficient but there have been extensions proposed that have shown some promise. Like in the infinite range model it suggests states have an ultrametric structure and uncountably many pure states.
• Droplet Scaling - The first such argument being presented by Rudolf Peierls. The main idea is to consider the arisal of "loops" or "islands" of spins (clusters of atoms all with the same spin being enclosed by some boundary). We then aim to count the number of such loops, often in high or low temperature ranges via approximation. This leads to only 2 pure states.
• Chaotic Pairs - Has properties somewhat similar to a combination of the preceeding 2 methods, like replica symmetry breaking there are infinitely many thermodynamic states however the relationship between them is much simpler and has simple scaling behaviour - much like droplet scaling.
• TNT - This interpretation does not itself specify the number of pure states, however it has been argued that it most naturally exists with 2 pure states - much like droplet scaling. However it has scaling properties more similar to that of replica symmetry breaking.

For completeness: a pure state of a system is a a state that cannot be expressed as a convex combination of other states.

As far as I am aware there is currently no conesensus on which (if any) of the options presented is the correct interpretation.

One of the main questions that we would like to answer is whether there is a phase transition (first order). This is unresolved currently. Another question we might ask is whether there exists multiple ground state pairs (i.e. we can find 2 different configurations that have minimal energy that are not merely negative images of each other) - again this is unresolved. In infinite dimensions we can see this would be true, in 1d we know this cannot be true - for other dimensions it is unclear (although it is believed it is probably not true for d=2).

In addition to this there are many other unanswered questions that are the subject of current research into Ising type models.

## Conclusion

In this blog post we have investigated some of the properties of square-lattice Ising models in various dimensions. In particular we have seen that there is no phase transition in 1d, a second order phase tranisition in 2d, a phase transition in infinite dimension and currently other dimensions are unresolved. We can see that the short-range interactions cause a lot of headaches when trying to analyse these systems. In the next blog post in this series we will begin to look at ways of simulating Ising models (and other spin glass models generally).

This is the third blog post in a series - you can find the next blog post here