arxiv_id
stringlengths 0
16
| text
stringlengths 10
1.65M
|
|---|---|
# Next-generation phenotyping using computer vision algorithms in rare genomic neurodevelopmental disorders
## Abstract
### Purpose
The interpretation of genetic variants after genome-wide analysis is complex in heterogeneous disorders such as intellectual disability (ID). We investigate whether algorithms can be used to detect if a facial gestalt is present for three novel ID syndromes and if these techniques can help interpret variants of uncertain significance.
### Methods
Facial features were extracted from photos of ID patients harboring a pathogenic variant in three novel ID genes (PACS1, PPM1D, and PHIP) using algorithms that model human facial dysmorphism, and facial recognition. The resulting features were combined into a hybrid model to compare the three cohorts against a background ID population.
### Results
We validated our model using images from 71 individuals with Koolen–de Vries syndrome, and then show that facial gestalts are present for individuals with a pathogenic variant in PACS1 (p = 8 × 10−4), PPM1D (p = 4.65 × 10−2), and PHIP (p = 6.3 × 10−3). Moreover, two individuals with a de novo missense variant of uncertain significance in PHIP have significant similarity to the expected facial phenotype of PHIP patients (p < 1.52 × 10−2).
### Conclusion
Our results show that analysis of facial photos can be used to detect previously unknown facial gestalts for novel ID syndromes, which will facilitate both clinical and molecular diagnosis of rare and novel syndromes.
## INTRODUCTION
Rare sporadic (de novo) pathogenic variants are a major cause of developmental disorders such as intellectual disability (ID) and autism spectrum disorders.1 Using next-generation sequencing strategies, a disease-causing genetic variant can now be identified in ~60% of individuals with ID, and to date approximately 750 of the predicted 2000 genes causing ID have been identified.1,2,3 In 30–40% of cases, ID is observed as part of a broader syndrome consisting of facial dysmorphology in conjunction with additional congenital abnormalities.4 In addition, we have previously shown that individuals with ID who present with facial dysmorphology are significantly enriched in both pathogenic and likely pathogenic variants.5 Despite the distinctive, although sometimes subtle facial features, phenotyping of individuals with ID (and their parents) currently relies on a clinician’s ability to recognize a syndrome based on its related dysmorphology.
The implementation of high-throughput sequencing technologies such as exome sequencing has facilitated the ability to detect individuals with increasingly rare novel disorders;2 this calls for novel methods for collecting phenotypic information. Facial recognition and matching algorithms have matured in recent years and can be exploited in a clinical setting to automate and objectively measure a person’s dysmorphology with minimal impact on the person.6,7,8,9,10,11,12,13,14,15,16,17,18 The advantages of these methods are that they also include subtle features that may be difficult for clinicians to identify or recognize features that may not necessarily be considered dysmorphic. Moreover, they can be used to identify additional individuals with a known syndrome or aid the characterization of novel ID syndromes. Alternatively, they can support the interpretation of variants for which functional impact may be uncertain, such as missense variants in a gene known to cause disease when mutated but for which clinical presentation is variable and/or includes a broad clinical spectrum. In this study, we created a novel hybrid learning model for detecting facial similarity within small subsets of individuals with the same ID syndrome (n < 15) and compared them with the general ID population. Our new model was able to successfully detect facial similarity in all three examined novel ID syndromes by incorporating both dysmorphic and generic facial features from two different facial analysis algorithms in combination with a unique collection of photos of control individuals with ID.12,19 We show that our new hybrid model is more sensitive than individual facial analysis algorithms and that it can lead to novel clinical diagnosis for individuals with missense variants of uncertain significance.
## MATERIALS AND METHODS
### Data collection
For this study one validation set and three test sets were generated. Each set consisted of facial photos of individuals with a specific ID syndrome and of matched ID controls. All facial photographs used in the study were taken from an approximately frontal position under uncontrolled conditions. The majority of the individuals with a specific ID syndrome used in this study are previously published cases. In addition some novel unpublished cases were included. The individuals selected as ID controls are previously unpublished individuals who were enrolled in the study from routine clinical diagnostics at the Department of Human Genetics at the Radboud University Medical Center (Radboudumc). To ensure anonymity all photographs were converted into unidentifiable feature vectors before analysis. This study was approved by the RadboudUMC under the realm of diagnostic process.
#### Validation set
The validation set consisted of 71 facial photos of Caucasian individuals with Koolen–de Vries syndrome (KdVS) (OMIM ID 610443), a syndrome with relatively high number of patients and a known facial gestalt. For each patient, one ID control was selected matching in gender, ethnicity, and age (measured in years) at the time of the photo. This resulted in a validation set consisting of 71 individuals with KdVS and 71 matched ID controls. (Supplemental Table S1).
#### Test sets
Three test sets were collected, each containing photos of Caucasian individuals with variants in a specific novel ID gene (PACS1 [Schuurs–Hoeijmakers syndrome, OMIM 615009; N = 14], PPM1D [OMIM 617450; N = 11], and PHIP [OMIM 612870; N = 16]) and matched ID controls. For each patient five ID controls were selected matching in gender, ethnicity, and age (measured in years) at the time of the photo. This resulted in three separate test sets: (1) PACS1 test set consisting of 14 individuals with Schuurs–Hoeijmakers syndrome and 70 matched ID controls, (2) a PPM1D test set consisting of 11 individuals with a pathogenic truncating variant in the last or penultimate exon of PPM1D with 55 matched ID controls, and (3) a PHIP test set consisting of 16 individuals with a pathogenic variant in PHIP and 80 matched ID controls (Supplemental Table S2S4).
The PACS1 individuals all had the identical pathogenic de novo missense variant in PACS1 (NM_018026.2:c.607 C>T; p.[Arg203Trp]),20,21 the 11 PPM1D individuals all had pathogenic truncating variants in the last or penultimate exon of PPM1D (NM_003620.3) (ref. 22), whereas the individuals with variants in PHIP (NM_017934.6) formed a more heterogeneous population, consisting of frameshifts, nonsense, splice site, and missense variants.23 The four PHIP missense variant (of uncertain significance) patients and their controls were excluded from the gestalt analysis of PHIP patients and were separately analyzed in a later stage, to test if their faces match the PHIP facial phenotype.
### ID control population
The control population consisted of ID patients referred to the clinical genetics center of the RadboudUMC, Nijmegen due to unexplained ID without a clearly recognizable syndromic form of ID. From these ID patients, 15% had a definitive genetic diagnosis, a possible cause was identified in 24% of cases (e.g., a variant of uncertain significance), and for 61% of the control cohort the genetic cause remained unknown. Instead of using healthy control, ID controls were used to examine if we can distinguish a specific ID syndrome from the general ID population on the basis of facial features. As described above, controls were selected to match the patient in gender, ethnicity, and age (measured in years) at the time of the photo. Of all patients in the validation and test sets, 86% had corresponding controls that were an exact age match, whereas for the remaining 14% perfect age matches were not available and the closest available ages were selected (Supplemental Table S1S4). Patients were excluded from the study if the age difference between patient and control was greater than one-third of the patient’s age.
### Feature extraction
A hybrid face description vector was extracted for each portrait photo by combining the output of two computer vision algorithms: the Clinical Face Phenotype Space (CFPS)12 and OpenFace.19 Both these pipelines analyze a portrait photo to extract a feature vector describing the facial characteristics. In brief, the CFPS pipeline12 first uses face detection, landmark annotation, and shape and appearance extraction to obtain a face representation and transforms this face representation into a 340-dimensional feature vector that represents the patient’s facial features. The resulting space places two individuals closer together if they have similar dysmorphic features and farther apart if they do not. The OpenFace pipeline19 is a system designed for facial recognition. It uses face detection, landmark annotation, and affine transformation to convert a portrait photo into a standardized 96 × 96 pixel image. This image is then used as input for a pretrained facial recognition deep neural network of which the output is a 128-dimensional feature vector that describes the facial characteristics relevant to facial recognition. It creates an abstract space in which people with similar faces are located closer together, while people with dissimilar faces are located farther apart.
We applied both the CFPS and OpenFace pipeline to our KdVS, PACS1, PPM1D, and PHIP data sets, resulting in two feature vectors for each photo. Because both feature extraction methods are trained for a different purpose they are sensitive to different facial features. The two feature vectors are then combined into one hybrid vector, thus incorporating dysmorphic information as well as general facial characteristics. Before combining the vectors, normalization was applied to give both models an equal weight. The mathematical expression for the resulting hybrid feature vector is described by
$$Hybrid\,feature\,vector = \left[ {\frac{{{\boldsymbol{f}}_{\boldsymbol{o}}}}{{\left\| {{\boldsymbol{f}}_{\boldsymbol{o}}} \right\|_2}}\frac{{{\boldsymbol{f}}_C}}{{\left\| {{\boldsymbol{f}}_{\boldsymbol{C}}} \right\|_2}}} \right]$$
Where fO is the 128-dimensional OpenFace feature vector, fC is the 340-dimensional CFPS feature vector, and $$\left\| z \right\|_2$$ is the Euclidean norm of z. This process results in one 468-dimensional hybrid feature vector describing the facial features for each individual in the data sets.
### Gestalt analysis
The similarity between patients with the same novel ID syndrome was analyzed by calculating the clustering improvement factor (CIF) for each of the four novel ID syndromes, using the patients as positives and the controls as negatives. The CIF gives an estimate of the search space reduction.12 In summary, the CIF estimates how well a group of positives (e.g., patients) cluster within a group of negatives (e.g., the controls) compared with what would be expected by random chance. The CIF is calculated by determining for each positive (e.g., patient), the rank of the nearest other positive (e.g., patient) and then comparing the average of these observed ranks O(r) to the expected rank of the nearest other positive E(r). And described by
$$CIF = \frac{{E(r)}}{{O(r)}}$$
Where the expected rank is described as
$$E\left( r \right) = 1 + \mathop {\sum }\limits_{j = 1}^{N_n} \left( {1 - \frac{j}{{N_n + 1}}} \right)^{N_p - 1}$$
And where Nn is the number of negative instances and Np is the number of positive instances.
After determining the CIF for each syndrome we randomly labeled (while maintaining the patient–control ratio) the patients and controls in each data set 10,000 times and calculated the corresponding CIF for every permutation. For each syndrome a right-tailed Mann–Whitney U test was performed to determine if the CIF for the syndrome is significantly higher than expected by random chance. This process is performed for each of the three feature types: CFPS, OpenFace, and hybrid. We also compared the performance of these feature types on smaller numbers of patients. For this purpose, we calculated the CIF for each possible combination of N patients in each test set. Then we compared the median CIF of all possible combinations with the CIFs for 1000 random permutations for each N as described above. In addition, the distribution of the hybrid feature vectors of the patients and controls are visualized for each data sets using t-distributed stochastic neighbor embedding (t-SNE) to reduce dimensionality.
Additionally, an experiment was performed to evaluate the effect that the number of patients versus controls had on the resulting CIF and p values. For each test set the corresponding controls were divided into five disjoint subsets resulting in subsets containing one matched ID control for each patient in the test set, thus matching the patient-to-control ratio used in the validation set. Then across each syndrome the CIF and p value were calculated for each of the five control subsets using the hybrid model and evaluated via the mean p value and resulting confidence interval.
## RESULTS
To examine whether a similar facial gestalt is present within three novel ID syndromes using computational analysis, we propose a descriptive facial feature vector that combines the OpenFace and CFPS feature vector. Next, we calculated the CIF to detect significant similarity. The CIF is a factor that estimates how well the patients cluster within the group of controls.
### Model validation using a known syndrome
We first validated our model on patients with KdVS syndrome, which is known to have associated and consistent facial dysmorphology, including a long hypotonic face and a bulbous nasal tip.24 The CFPS, OpenFace, and hybrid feature vectors were extracted and compared between the 71 KdVS patients and their age- and gender-matched controls. The faces of the KdVS patients had a higher CIF than expected by random chance, both when using the CFPS (CIF = 0.993, p = 4.26 × 10−2) and the OpenFace (CIF = 1.143, p = 2 × 10−4) features, meaning both feature types can detect the facial similarity in KdVS patients. Our novel hybrid feature vector also showed a higher CIF than expected by random chance (CIF = 1.191, p < 1 × 10−4). The CIF for the hybrid model is higher than for the individual feature types, indicating an improvement in clustering when combining the two feature vectors (Table 1).
### Model application to novel ID syndromes
We performed a similar analysis for the three novel ID syndromes, with five age-matched controls per patient, using either the CFPS, OpenFace, or our novel hybrid model to describe the facial characteristics. Using only the CFPS features significant similarity was detected for PACS1 (CIF = 1.908, p = 1.90 × 10−2) and PHIP (CIF = 2.399, p = 7.1 × 10−3), but not for PPM1D (CIF = 1.011, p = 4.77 × 10−1). Using the OpenFace features found significant similarity for PACS1 (CIF = 1.955, p = 7.6 × 10−3) and PPM1D (CIF = 1.667, p = 4.80 × 10−2), but not for PHIP (CIF = 1.101, p = 3.20 × 10−1). Our novel hybrid model was the only model that showed significant facial similarity for all three syndromes: PACS1 (CIF = 2.523, p = 8 × 10−4), PPM1D (CIF = 1.713, p = 4.65 × 10−2), and PHIP (CIF = 2.239, p = 6.3 × 10−3) (Table 1). For all three novel ID genes the highest significance was achieved when using the hybrid feature vectors. A t-SNE plot of the different test sets illustrates the similarity between the patients with the same syndrome compared with the matched ID control population using our novel hybrid model (Fig. 1).
### Application to missense variants of uncertain significance
We examined whether the four patients with a de novo missense variant in the PHIP gene (individual A: NM_017934.6:c.328C>T, individual B: NM_017934.6:c.328C>A, individual C: NM_017934.6:c.1562A>G, and individual D: NM_017934.6:c.2888A>G) show significant similarity to the 12 individuals with a presumed loss-of-function variant in PHIP. When visualizing the complete PHIP data set, we observed that all four missense patients were located in the vicinity of the other PHIP patients. Individuals A and D displayed a stronger association to other PHIP patients compared with individuals B and C (Fig. 1c). To quantify this, we compared the Euclidean distance from the hybrid feature vectors of the missense patients with their nearest PHIP patient with the Euclidean distances between the controls and their nearest PHIP patient using a right-tailed Mann–Whitney U test (Table 2). The distance from individuals A and D to the nearest PHIP patient was significantly smaller than expected by random chance (both p < 1.52 × 10−2), thus showing that the facial phenotypes of individuals A and D are significantly similar to the facial phenotype of other PHIP patients. Whereas individuals B and C were not significantly closer to other PHIP patients than expected by random chance (p = 1.82 × 10−1 and p = 6.06 × 10−2 respectively).
## DISCUSSION
The development of the face and the brain are tightly linked and craniofacial anomalies are reported in 30–40% of individuals with ID.4 This link has been used in clinical setting for decades to establish a syndromic diagnosis in individuals with ID. Developments in facial phenotyping through computational analysis of facial images have shown that it is possible to train an algorithm to recognize patients with a number of known dysmorphic syndromes.6,7,8,9,10,11,12,13,14,15,16,17,18 In this study we used facial image analysis to answer two different questions, namely (1) is there a shared facial gestalt present for a novel ID syndrome without clear clinically recognizable facial features, and (2) do patients with a variant of uncertain significance exhibit significant facial similarity to patients with a pathogenic variant within the same gene. To answer these questions, in contrast to previous studies, we used a background control set of individuals with ID, and not healthy individuals. Thereby presenting the algorithm with a relevant classification problem close to the clinical question, namely to recognize subgroups of individuals within the ID population. In addition, we matched the controls to exclude age-, gender-, or ethnicity biases.
Information contained in human faces can be used in the delineation of genetic entities.18 For this reason, we selected four different cohorts of individuals with syndromes caused by different pathophysiological mechanisms. Firstly, for validation purposes we selected a large cohort of KdVS patients representing a homogeneous set of patients with loss-of-function variants correlating to a known syndrome with dysmorphic features. Our model also showed that the faces of individuals with KdVS were significantly similar when compared with the general ID population. Similarly the patients with a de novo PACS1 variant represent a cohort in which all members had an identical pathogenic de novo variant in PACS1 (NM_018026.2:c.607C>T; p.[Arg203Trp])20,21 and for which computational analysis had recently been performed on a subset of the individuals showing that a facial gestalt is present.12,16 Notably in comparison with the first two index patients, the facial phenotype has broadened as the cohort has expanded, and more variation has been introduced while still showing that significant facial similarity exists between individuals (Supplemental Figure S1). Our model achieved higher CIF values for the test cohorts compared with the validation cohort, in part due to the difference in patient-to-control ratio, which results in a higher maximum achievable CIF. Retrospective analysis illustrated that selecting one matched ID control per test subject influenced the resulting CIF values and had insufficient power to generate statistically robust results (Supplemental Table S5). The last two cohorts consist of patients without a clearly clinically recognizable facial dysmorphology; PPM1D patients all had pathogenic truncating variants in the last or penultimate exon of PPM1D (NM_003620.3) (ref. 22) and the cohort of PHIP patients had variants (NM_017934.6) consisting of loss-of-function variants (frameshifts, nonsense, splice sites) leading to haploinsufficiency.23 This final cohort of PHIP patients allowed us to test the ability to classify patients with a de novo missense variant of uncertain significance within the clinical context of the remainder of PHIP patients with a presumed loss-of-function variant. The pathophysiological effect of a missense variant is often less clear than that of truncating variants. Our analysis helped interpret the phenotypic effect of two of four missense variants, demonstrating in two individuals (A and D) significant similarity to other PHIP patients with a loss-of-function variant. Whereas individuals B and C showed a trend toward facial similarity, which may become significant with a larger cohort of PHIP individuals.
While choosing not to retrain the algorithms, our model does combine the CFPS feature space trained to recognize dysmorphic features in patients with the features from OpenFace trained to perform face recognition. We show that the two feature spaces are sensitive to different characteristics and only their combined power was able to detect the sometimes-subtle features within our small patient cohorts (Supplemental Figure S2). For example, CFPS detected similarity in the PHIP patient group, whereas OpenFace detected similarity in the PPM1D patient group. This most likely reflects the more distinct facial features of individuals with a pathogenic variant in PHIP compared with the subtler facial features of individuals with a pathogenic PPM1D variant. The disadvantage of both models is that it results in an abstract representation of the face and it is difficult to translate the results of the classification back to individual facial features and hence underlying biology. However, computer-based models do perform objective facial analysis, compared with the more subjective interpretations of clinicians. One challenge that needs to be faced in future research is the comparison of facial features between patients with different ethnicities.25,26,27,28,29
In conclusion we present a model that combines a facial recognition algorithm with an algorithm trained to recognize dysmorphic features. We show that patients with a pathogenic variant in one of three novel ID genes (PACS1, PPM1D, and PHIP), identified via genotype-first approach, have an associated facial gestalt, thus demonstrating that information contained in the face can be used to delineate genetic entities including in novel ID syndromes with no previously known knowledge of a facial phenotype. Notably our model provides significant results with a small number of patients (n < 15) and provides a phenotypic readout to interpret variants of uncertain significance. The implementation of next-generation sequencing in the clinic has resulted in the identification of increasingly rare syndromes, and the orthogonal use of computational analysis of facial features will be key for linking variants to patients’ novel and yet unknown phenotypes leading to a clinical diagnosis.
## References
1. 1.
Gilissen C, Hehir-Kwa JY, Thung DT, et al. Genome sequencing identifies major causes of severe intellectual disability. Nature. 2014;511:344.
2. 2.
Vissers LE, Gilissen C, Veltman JA. Genetic studies in intellectual disability and related disorders. Nat Rev Genet. 2016;17:9–18.
3. 3.
Chiurazzi P, Pirozzi F. Advances in understanding–genetic basis of intellectual disability. F1000Research. 2016;5:599.
4. 4.
Hart TC, Hart PS. Genetic studies of craniofacial anomalies: clinical implications and applications. Orthod Craniofac Res. 2009;12:212–220.
5. 5.
Vulto‐van Silfhout AT, Hehir‐Kwa JY, Bon BW, et al. Clinical significance of de novo and inherited copy‐number variation. Hum Mutat. 2013;34:1679–1687.
6. 6.
Loos HS, Wieczorek D, Wurtz RP, von der Malsburg C, Horsthemke B. Computer-based recognition of dysmorphic faces. Eur J Hum Genet. 2003;11:555–560.
7. 7.
Hammond P, Hutton TJ, Allanson JE, et al. Discriminating power of localized three-dimensional facial morphology. Am J Hum Genet. 2005;77:999–1010.
8. 8.
Boehringer S, Vollmar T, Tasse C, et al. Syndrome identification based on 2D analysis software. Eur J Hum Genet. 2006;14:1082–1089.
9. 9.
Dalal AB, Phadke SR. Morphometric analysis of face in dysmorphology. Comput Methods Programs Biomed. 2007;85:165–172.
10. 10.
Vollmar T, Maus B, Wurtz RP, et al. Impact of geometry and viewing angle on classification accuracy of 2D based analysis of dysmorphic faces. Eur J Med Genet. 2008;51:44–53.
11. 11.
Boehringer S, Guenther M, Sinigerova S, Wurtz RP, Horsthemke B, Wieczorek D. Automated syndrome detection in a set of clinical facial photographs. Am J Med Genet A. 2011;155A:2161–2169.
12. 12.
Ferry Q, Steinberg J, Webber C, et al. Diagnostically relevant facial gestalt information from ordinary photos. eLife. 2014;3:e02020.
13. 13.
Balliu B, Wurtz RP, Horsthemke B, Wieczorek D, Bohringer S. Classification and visualization based on derived image features: application to genetic syndromes. PLoS One. 2014;9:e109033.
14. 14.
Wang K, Luo J. Detecting visually observable disease symptoms from faces. EURASIP J Bioinform Syst Biol. 2016;2016:13.
15. 15.
Cerrolaza JJ, Porras AR, Mansoor A, Zhao Q, Summar M, Linguraru MG. Identification of dysmorphic syndromes using landmark-specific local texture descriptors. Paper presented at: IEEE 13th International Symposium on Biomedical Imaging (ISBI). April 13–16, 2016; Prague, Czech Republic.
16. 16.
Dudding-Byth T, Baxter A, Holliday EG, et al. Computer face-matching technology using two-dimensional photographs accurately matches the facial gestalt of unrelated individuals with the same syndromic form of intellectual disability. BMC Biotechnol. 2017;17:90.
17. 17.
Liehr T, Acquarola N, Pyle K, et al. Next generation phenotyping in Emanuel and Pallister Killian syndrome using computer-aided facial dysmorphology analysis of 2D photos. Clin Genet. 2018;93:378–381.
18. 18.
Knaus A, Pantel JT, Pendziwiat M, et al. Characterization of glycosylphosphatidylinositol biosynthesis defects by clinical features, flow cytometry, and automated image analysis. Genome Med. 2018;10:3.
19. 19.
Amos B, Ludwiczuk B, Satyanarayanan M. Openface: A general-purpose face recognition library with mobile applications. CMU School of Computer Science. 2016.
20. 20.
Schuurs-Hoeijmakers JH, Oh EC, Vissers LE, et al. Recurrent de novo mutations in PACS1 cause defective cranial-neural-crest migration and define a recognizable intellectual-disability syndrome. Am J Hum Genet. 2012;91:1122–1127.
21. 21.
Schuurs-Hoeijmakers JH, Landsverk ML, Foulds N, et al. Clinical delineation of the PACS1-related syndrome—report on 19 patients. Am J Med Genet A. 2016;170:670–675.
22. 22.
Jansen S, Geuer S, Pfundt R, et al. De novo truncating mutations in the last and penultimate exons of PPM1D cause an intellectual disability syndrome. Am J Hum Genet. 2017;100:650–658.
23. 23.
Jansen S, Hoischen A, Coe BP, et al. A genotype-first approach identifies an intellectual disability-overweight syndrome caused by PHIP haploinsufficiency. Eur J Hum Genet. 2018;26:54–63.
24. 24.
Koolen DA, Vissers LE, Pfundt R, et al. A new chromosome 17q21.31 microdeletion syndrome associated with a common inversion polymorphism. Nat Genet. 2006;38:999–1001.
25. 25.
Lumaka A, Cosemans N, Lulebo Mampasi A, et al. Facial dysmorphism is influenced by ethnic background of the patient and of the evaluator. Clin Genet. 2017;92:166–171.
26. 26.
Kruszka P, Addissie YA, McGinn DE, et al. 22q11.2 deletion syndrome in diverse populations. Am J Med Genet A. 2017;173:879–888.
27. 27.
Kruszka P, Porras AR, Addissie YA, et al. Noonan syndrome in diverse populations. Am J Med Genet A. 2017;173:2323–2334.
28. 28.
Kruszka P, Porras AR, Sobering AK, et al. Down syndrome in diverse populations. Am J Med Genet A. 2017;173:42–53.
29. 29.
Kruszka P, Porras AR, de Souza DH, et al. Williams-Beuren syndrome in diverse populations. Am J Med Genet A. 2018;176:1128–1136.
## Acknowledgements
We thank the individuals and their parents for participating in this study. We thank the clinicians for referring cases. We thank Milan Baars, Alexander Currie, and Martijn Mandigers for their contribution in collecting patient photographs. This work was financially supported by grants from the Netherlands Organization for Scientific Research (NWO) (916-16-015 to J.Y.H.-K. and 912-12-109 to L.E.L.M.V. and B.B.A.d.V.). The Medical Research Council (UK) has funded C.N. through a MRC Methodology Research Fellowship MR/M014568/1. The patient images used in this study cannot be made openly available due to patient privacy concerns. Please contact the authors with specific queries regarding data access.
## Author information
Correspondence to Bert B. A. de Vries MD, PhD or Jayne Y. Hehir-Kwa PhD.
## Ethics declarations
### Disclosure
The authors declare no conflicts of interest.
Publisher’s note: Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.
## Rights and permissions
Reprints and Permissions
• #### DOI
https://doi.org/10.1038/s41436-018-0404-y
### Keywords
• facial phenotyping
• phenotyping
• facial image processing
• ### De Novo and Inherited Pathogenic Variants in KDM3B Cause Intellectual Disability, Short Stature, and Facial Dysmorphism
• Illja J. Diets
• , Roos van der Donk
• , Kristina Baltrunaite
• , Esmé Waanders
• , Margot R.F. Reijnders
• , Alexander J.M. Dingemans
• , Rolph Pfundt
• , Anneke T. Vulto-van Silfhout
• , Laurens Wiel
• , Christian Gilissen
• , Julien Thevenon
• , Laurence Perrin
• , Alexandra Afenjar
• , Caroline Nava
• , Boris Keren
• , Sarah Bartz
• , Bethany Peri
• , Gea Beunders
• , Nienke Verbeek
• , Koen van Gassen
• , Isabelle Thiffault
• , Lina Huerta-Saenz
• , Matias Wagner
• , Vassiliki Konstantopoulou
• , Julia Vodopiutz
• , Matthias Griese
• , Annekatrien Boel
• , Bert Callewaert
• , Han G. Brunner
• , Tjitske Kleefstra
• , Nicoline Hoogerbrugge
• , Bert B.A. de Vries
• , Vivian Hwa
• , Andrew Dauber
• , Jayne Y. Hehir-Kwa
• , Roland P. Kuiper
• & Marjolijn C.J. Jongmans
The American Journal of Human Genetics (2019)
|
|
# Archimedean Principle
## Theorem
Let $x$ be a real number.
Then there exists a natural number greater than $x$.
$\forall x \in \R: \exists n \in \N: n > x$
That is, the set of natural numbers is unbounded above.
### Variant
Let $x$ and $y$ be a natural numbers.
Then there exists a natural number $n$ such that:
$n x \ge y$
## Proof
Let $x \in \R$.
Let $S$ be the set of all natural numbers less than or equal to $x$:
$S = \set {a \in \N: a \le x}$
It is possible that $S = \O$.
Suppose $0 \le x$.
Then by definition, $0 \in S$.
But $S = \O$, so this is a contradiction.
From the Trichotomy Law for Real Numbers it follows that $0 > x$.
Thus we have the element $0 \in \N$ such that $0 > x$.
Now suppose $S \ne \O$.
Then $S$ is bounded above (by $x$, for example).
Thus by the Continuum Property of $\R$, $S$ has a supremum in $\R$.
Let $s = \map \sup S$.
Now consider the number $s - 1$.
Since $s$ is the supremum of $S$, $s - 1$ cannot be an upper bound of $S$ by definition.
So $\exists m \in S: m > s - 1 \implies m + 1 > s$.
But as $m \in \N$, it follows that $m + 1 \in \N$.
Because $m + 1 > s$, it follows that $m + 1 \notin S$ and so $m + 1 > x$.
## Also known as
This result is also known as:
• the Archimedean law
• the Archimedean property (of the natural numbers)
• the Archimedean ordering property (of the real line)
• the axiom of Archimedes.
## Also see
Not to be confused with the better-known (outside the field of mathematics) Archimedes' Principle.
## Source of Name
This entry was named for Archimedes of Syracuse.
## Historical Note
The Archimedean Principle appears as Axiom $\text V$ of Archimedes' On the Sphere and Cylinder.
The name axiom of Archimedes was given by Otto Stolz in his $1882$ work: Zur Geometrie der Alten, insbesondere über ein Axiom des Archimedes.
|
|
# §32.11 Asymptotic Approximations for Real Variables
## §32.11(i) First Painlevé Equation
There are solutions of (32.2.1) such that
where
and and are constants.
There are also solutions of (32.2.1) such that
32.11.3.
Next, for given initial conditions and , with real, has at least one pole on the real axis. There are two special values of , and , with the properties , , and such that:
1. (a)
If , then for , where is the first pole on the negative real axis.
2. (b)
If , then oscillates about, and is asymptotic to, as .
3. (c)
If , then changes sign once, from positive to negative, as passes from to 0.
For illustration see Figures 32.3.1 to 32.3.4, and for further information see Joshi and Kitaev (2005), Joshi and Kruskal (1992), Kapaev (1988), Kapaev and Kitaev (1993), and Kitaev (1994).
## §32.11(ii) Second Painlevé Equation
Consider the special case of with :
32.11.4
with boundary condition
32.11.5.
Any nontrivial real solution of (32.11.4) that satisfies (32.11.5) is asymptotic to , for some nonzero real , where denotes the Airy function (§9.2). Conversely, for any nonzero real , there is a unique solution of (32.11.4) that is asymptotic to as .
If , then exists for all sufficiently large as , and
where
and , are real constants. Connection formulas for and are given by
where is the gamma function (§5.2(i)), and the branch of the function is immaterial.
If , then
32.11.10.
If , then has a pole at a finite point , dependent on , and
32.11.11.
For illustration see Figures 32.3.5 and 32.3.6, and for further information see Ablowitz and Clarkson (1991), Bassom et al. (1998), Clarkson and McLeod (1988), Deift and Zhou (1995), Segur and Ablowitz (1981), and Suleĭmanov (1987). For numerical studies see Miles (1978, 1980) and Rosales (1978).
## §32.11(iii) Modified Second Painlevé Equation
Replacement of by in (32.11.4) gives
32.11.12
Any nontrivial real solution of (32.11.12) satisfies
where
with and arbitrary real constants.
In the case when
with , we have
where is a nonzero real constant. The connection formulas for are
## §32.11(iv) Third Painlevé Equation
For , with and ,
where is an arbitrary constant such that , and
32.11.26,
where and are arbitrary constants such that and . The connection formulas relating (32.11.25) and (32.11.26) are
32.11.27
See also Abdullaev (1985), Novokshënov (1985), Its and Novokshënov (1986), Kitaev (1987), Bobenko (1991), Bobenko and Its (1995), Tracy and Widom (1997), and Kitaev and Vartanian (2004).
## §32.11(v) Fourth Painlevé Equation
Consider with and , that is,
32.11.29
and with boundary condition
32.11.30.
Any nontrivial solution of (32.11.29) that satisfies (32.11.30) is asymptotic to as , where is a constant. Conversely, for any there is a unique solution of (32.11.29) that is asymptotic to as . Here denotes the parabolic cylinder function (§12.2).
Now suppose . If , where
32.11.31
then has no poles on the real axis. Furthermore, if , then
Alternatively, if is not zero or a positive integer, then
where
and and are real constants. Connection formulas for and are given by
where
and the branch of the function is immaterial.
Next if , then
32.11.38,
and has no poles on the real axis.
Lastly if , then has a simple pole on the real axis, whose location is dependent on .
For illustration see Figures 32.3.732.3.10. In terms of the parameter that is used in these figures .
|
|
ISSN 0439-755X
CN 11-1911/B
›› 2009, Vol. 41 ›› Issue (12): 1175-1188.
### Deficient Inhibition of Return for Emotional Faces in Depression
DAI Qin, FENG Zheng-Zhi
1. Educational Center of Mental Health, Third Military Medical University, Chongqing 400038, China
• Received:2008-11-17 Revised:1900-01-01 Published:2009-12-30 Online:2009-12-30
• Contact: FENG Zheng-Zhi
Abstract: Depression is a commonly-occurred mental disorder. Researchers have highlighted the attentional bias of depressive disorders, although results have been mixed. The cue-target task has often been used to explore attentional bias; a particular phenomenon revealed by such studies is the inhibition of return (IOR). However, cue-target task has seldom been used so far in the study of depressed patients. The aim of the present study was to investigate the IOR phenomenon in depressed individuals in cue-target task using emotional faces as cues.
Control participants who had never suffered depression (NC), participants who had experienced at least two depressive episodes in their lives but were currently remitted (RMD), and participants diagnosed with a current major depressive disorder (MDD), were recruited using BDI, SDS, HAMD and CCMD-3 as tools. Seventeen participants in each group completed a cue-target task in a behavioral experiment that comprised three kinds of experimental condition, two cue types and four face types. Each participant also completed a simpler cue-target task in an event-related potential (ERP) experiment. In this task, a target appeared after a cue and the participant responded to its location.
In the behavioral experiment, it was found that when the stimulus onset asynchrony (SOA) was 14 ms, the NC and RMD participants had IOR effects for all faces and MDD participants for angry and sad faces. When the SOA was 250 ms, all three groups all had cue validity for sad faces but the effect was much more marked for the MDD group. When the SOA was 750 ms, the NC participants had an IOR effect for sad faces, the RMD participants had cue validity for angry, happy and sad faces, and the MDD participants had cue validity for sad faces and an IOR effect for angry faces. In the ERP experiment, the NC participants showed a bigger P3 amplitude for happy cue than the other groups, a smaller P1 amplitude for happy faces in the invalid cue condition than for other faces, a smaller P1 amplitude for sad faces in the valid cue condition than for other faces, a bigger P3 amplitude for happy faces in the valid cue condition compared with MDD participants, and a bigger P3 amplitude for sad faces in the invalid cue condition compared with other groups. The RMD participants had larger P3 amplitude for sad cue than for other faces, larger P3 amplitude for happy faces in the valid cue condition compared with MDD participants, and smaller P3 amplitude for sad faces in the invalid cue condition compared with NC participants. The MDD participants had a larger P1 amplitude for sad cue compared with other groups, a larger P3 amplitude for sad cue than for other face cues, a smaller P3 amplitude for sad faces in the invalid cue condition compared with NC participants, and a smaller P3 amplitude for happy faces in the valid cue condition compared with other groups.
It can be concluded that the MDD participants had cue validity and deficient IOR for negative stimuli. The deficient inhibition of negative stimuli renders them unable to eliminate the interference of negative stimuli and causes the maintenance and development of depression. The RMD participants had cue validity and deficient IOR for both positive and negative stimuli, which enables them to perceive positive and negative stimuli sufficiently and to maintain emotional balance.
|
|
# Equation Graphing Difficulties
1. Nov 29, 2013
### kyledixon
Hi everybody,
I am having some difficulties graphing this decaying trig function:
((e^(((.175(1-(y/10))+((y/10)-.001))t)/(2000)))(10cos((sqrt(((.175(1-(y/10))+((y/10)-.001))^(2))-400000000))t)+10sin((sqrt(((.175(1-(y/10))+((y/10)-.001))^(2))-400000000))t))
I have checked over the parentheses three times now, and I don't see any errors there. I am assuming I am just timing out the graphing programs, because WolframAlpha is having difficulty, and I don't know how else I can graph this. So does anybody know how I can graph this? Or do you see any errors I have made?
2. Nov 29, 2013
### scurty
$\displaystyle \exp\left(at/2000\right) \cdot \left( 10 \cos \left( t \cdot \sqrt{a^2 - 400000000} \right) + 10 \sin \left( t \cdot \sqrt{a^2 - 400000000} \right) \right)$
where
$a = 0.175 (1-y/10)+(y/10-0.001)$
Your original expression had many superfluous parentheses in it. For example, 1-(y/10) and ^(2). Also, I noticed that Wolfram didn't know how to recognize ()t, once I inputted several * into the expression a result was shown (indicating errors in parentheses). There was one error near the end, that I fixed when rewriting the expression but I don't know what parens it was. Here is what I can use for Wolfram:
exp(t*(0.175*(1-y/10)+(y/10-0.001))/2000)*(10*cos(t*sqrt((0.175*(1-y/10)+(y/10-0.001))^2-400000000))+10*sin(t*sqrt((0.175*(1-y/10)+(y/10-0.001))^2-400000000)))
No graph shows up however.
3. Nov 29, 2013
### kyledixon
Yes! You nailed the equation exactly. Sorry about the extra parentheses, I became used to adding things like ^(2) after I kept getting inaccurate answers because Wolfram misunderstood what I meant. I can't thank you enough for fixing the equation. Do you think Mathematica 9 would plot it? If so, would you know how to input it appropriately?
4. Nov 29, 2013
### scurty
You can actually simplify the expression down further. Using the fact that $\sin(x) + \cos(x) = \sqrt{2} \sin(x + \pi/4)$, the expression can be rewritten as
$\displaystyle 10\sqrt{2} \cdot \exp\left(at/2000\right) \cdot \sin \left( t \cdot \sqrt{a^2 - 400000000} + \pi/4 \right)$
where a is as defined previously. The sin term is too complex for Wolfram to graph, but you can try it with Mathematica and see if the extra time allowed can plot it. (Wolfram basic only allows so much computation time)
10*sqrt(2)*e^(a*t/2000)*sin(t*sqrt(a^2-400000000+pi/4))
5. Dec 1, 2013
### kyledixon
I gotcha. Thanks so much for your help, now I just need to learn how to use Mathematica and hopefully I will be good to go!
6. Dec 1, 2013
### Bill Simpson
Code (Text):
In[1]:= a = 0.175*(1 - y/10) + (y/10 - 0.001);
expr = 10*Sqrt[2]*Exp[a*t/2000]*Sin[t*Sqrt[a^2 - 4*10^8] + Pi/4];
Plot3D[{Re[expr], Im[expr]}, {t, -10^-4, 10^-4}, {y, -10, 10}]
Out[3]= ...PlotSnipped...
expr is HUGE for values of t much bigger than +/- 10^-4. Try
Code (Text):
Table[expr, {t, -20, 20, 5}, {y, -1, 1}]
to see what I mean.
expr is Complex for many or most values of t.
The plot is almost unchanged by the range of y until y is beyond +/-10^5.
Overlaying two plots, one the Real part and the other the Imaginary part,
and suitably restricting the Plot range lets you see a plot.
Mathematica is fanatic about correct capitalization and () versus [] versus {} while WolframAlpha doesn't care.
Mathematica allows you to define functions and assign values to variables while WolframAlpha doesn't.
Be very very careful to verify that any plot which includes numbers like 400000000 is correct because Plot is not perfect and with wildly large or wildly small numbers it can often show you something that is misleading or simply wrong, increase the range of t in that plot by 10x or 100x and look at the result to see examples of this.
Getting a graph to be exactly the way you want it to be can take ten times as long as it takes to get the math to be really correct.
You can get WolframAlpha to plot the Real or Imaginary part, but the line of code is so long that it barely fits within the limits.
http://www.wolframalpha.com/input/?i=Plot3D%5B%7BRe%5B10*Sqrt%5B2%5D*Exp%5Bt*%280.175*%281-y%2F10%29%2B%28y%2F10-0.001%29%29%2F2000%5D*Sin%5Bt*Sqrt%5B%280.175*%281-y%2F10%29%2B%28y%2F10-0.001%29%29%5E2-4*10%5E8%5D%2BPi%2F4%5D%5D%7D%2C%7Bt%2C-10%5E-4%2C10%5E-4%7D%2C%7By%2C-10%2C10%7D%5D
Change the Re to Im at the beginning of that line to see the Imaginary plot.
Hopefully I haven't broken any of this with copy and paste.
Test all this very carefully before you depend on any of it.
Last edited: Dec 1, 2013
|
|
# Depression of Water Surface by a Needle
Given a needle of mass $m$ modeled by a cylinder of length $l$ and radius $r$ placed on an infinitely large water surface, what is
1. The maximum depression in the water surface; and
2. The equation of the shape of the water surface when depressed?
I'm quite sure this is a simple question that already has been modeled theoretically somewhere, but I haven't been able to find a theoretical treatment of the problem with experimentally verifiable quantities.
In addition, can the treatment of the problem be extended to thin films, for example a thin soap film?
-
Given the volume of the needle and it's mass density, you can calculate the surface tension force based on a simple free body diagram. You might need to use the concept of a contact angle perhaps and some trigonometry to figure out what the depression is. – drN Mar 1 at 20:21
@drN wouldn't both the contact angle and the amount of needle in contact with water affect things? mathematically I can think of two configurations where the contact angle is identical but the surface area in contact is different, and thus the angle between the surface tension force and the weight of the needle is different. – Vincent Tjeng Mar 2 at 1:57
Here is a link on surface tension that treats the needle example with an equation of balance of forces.
And here is another one .
-
Hi there, I think both links provided do not specifically give a value for the amount the needle depresses the water surface by. Would it be correct to say that the needle is essentially "floating" in the water i.e. not depressing the water at all? It seems rather counter-intuitive to me. – Vincent Tjeng Jan 31 at 5:44
In addition, the first link suggests that the force due to surface tension can be exactly anti-parallel to the weight of the needle. Is this in fact physically possible? – Vincent Tjeng Jan 31 at 5:45
it is the vector sum of the ST force on the two sides that HAS to compensate the weight of the needle to float. wikipremed.com/… . to get a specific value you would need to enter all the constants in the formula in the link . – anna v Jan 31 at 6:02
thank you for your time. are you referring to equation 4.9 in your link? If so, based on my understanding, θ could be calculated by taking the vector sum of the forces due to surface tension and the weight of the needle. However, that still doesn't answer the question of the depression of the surface below the needle or the shape of the surface close to the needle, since the shape of the curve is not determined. – Vincent Tjeng Jan 31 at 7:25
– anna v Jan 31 at 7:39
|
|
# homomorphism :))
Printable View
• November 15th 2009, 10:34 PM
GTK X Hunter
homomorphism :))
Suppose $GL(n,\mathbb{R})$ is a multiplicative group of invertible matrix ( $n$x $n$). Let $\mathbb{R}$ be an additive group of real numbers. Given $g:GL(n,\mathbb{R})\rightarrow\mathbb{R}$ with $g(A)=tr(A)$.
Is $g$ homomorphism? If yes then prove it! (Rofl)
• November 16th 2009, 01:46 AM
Defunkt
You should really be able to solve these by yourself!
For g to be a homomorphism, we need that for every $A,B \in GL_n(\mathbb{R}), tr(A)tr(B) = tr(AB)$
I'll leave the rest for you.
|
|
#### How to assign string value to dropdownlist when selected value field is an int(id of item)
Hi i have a problem.In one of my application i am maintaining all controlvalues
on a page in session using AJAX.i have done it.My page contain two
dropdownlist.Data value field of items in dropdownlist is nothing but
the idof items,i am retriving an selected item name from database using its id fromdatabase.once i got name the problem is that how can i give selected item of ddlistis the item name. i am triedddlist.SelectedValue=session("name")\\it gives nullddlist.SelectedItem.Text=session("name")\\\it gives object reference not set to instance of object error.How can i do this.Please guide me.Thanks
0
rahuldotnet
7/7/2007 2:33:42 PM
asp.net.web-forms 93655 articles. 6 followers.
2 Replies
1754 Views
Similar Articles
[PageSpeed] 42
You're close. You should just need to us the "SelectedItem" property.ddlist.SelectedItem = "100";
As long as the value you're assigning is a string (and exists in the list) you should be good. You shouldn't have to go through the Session. Just assignto the control directly.
0
Bravo9
7/7/2007 4:04:52 PM
Try
' make sure you have the value in session
Dim _selectValue As String = Session("name").ToString()
' try to set the selected item of dropdownlist as _selectValue
ddlist.Items.FindByValue(_selectValue).Selected = True
' alternatively if you know the text value, you can use
' ddlist.Items.FindByText(_selectText).Selected = true;
Catch
' if the value is not found, then set the default value as
' selected
ddlist.Items.FindByValue(defaultValue).Selected = True
End TryThanksMark post(s) as "Answer" that helped youElectronic ScrewWebsite||Blog||Dub@i.net
0
e_screw
7/7/2007 8:02:56 PM
Similar Artilces:
Dropdownlist selected value passes first value in list no matter what value is selected. why ?
HI . I have a dropdownlist. Databinds ok but when I must pass a value as a Selected value it always passes the first value in the list even if I select another value. I tried to set the ddl to enableviewstate false but it doesn't change anything. Any ideas ? Code below, thanksLoading the ddl: productCategories = CatalogAdmin.Admin_Product_Categories_NotIn(productId); for (int i = 0; i < productCategories.Rows.Count; i++) { &...
Selecting value in one field then causes value in another field to be selected.
I have a web form which contains a date field, the date is populated using a DatePicker which is Javascript based. The form also has a drop down box containing 3 values. What I want to do is when a date has been selected that this will cause the dropdown list value to change to dated which is one of its 3 values. i.e. when the date field is not blank then the value will be selected in the dropdown. What I also want to happen is when the date has been selected and the dropdown value is dated then the date field and the dropdown field will be set to read only.Anyone any ideas how to this usin...
How Select one dropdownlist value using down arrows corresponding other dropdownlist value are select
I am using two dropdownlist box.One is used for country selection. other one is used for state selection.I am using dropdown selectedindexchanged event. when i click country dropdownlist corresponding state is selected in state dropdownlist box. How select the country in country dropdownlist using down arrow keys at the same time corresponding state is select in state dropdown list.R.Karthikeyan kartmca: How select the country in country dropdownlist using down arrow keys at the same time corresponding state is select in state dropdown list.Generally, we don't implmenet...
DropDownList selected value determines value of second DropDownList
I have a quick question that I'm sure has been addressed before, but I can't seem to find a solution. I have two drop down list fields: startTime and endTime coded as such: <asp:DropDownList id="startTime" runat="server"> <asp:ListItem Value="00:00">12:00 A.M.</asp:ListItem> <asp:ListItem Value="00:30">12:30 A.M.</asp:ListItem> <asp:ListItem Value="01:00">1:00 A.M.</asp:ListItem> <asp:ListItem Value="...
dropdownlist's selected index value is not printing the selected value
Here iS my code .Aspx Page <asp:DropDownList ID="ddlkeyword" runat="server" Width="204px" DataTextField="Form" DataValueField="Form" OnSelectedIndexChanged="ddlkeyword_SelectedIndexChanged" > </asp:DropDownList> <asp:Button ID="Button1" runat="server" Text="Submit" Width="110px" OnClick="Button1_Click" /> my aspx.cs protected void Page_Load(object sender, EventArgs e) { fillddlkeyword(); }protected void Page_Init(object sender, EventArgs e) { ...
Form: Focus on selected values in dropdownlists, Refresh after selection and hidding formfields based on selection.
Hello again,I have a form with several dropdown lists. Depending on the selected value in the dropdown lists other fields become available in that same form. It is working in classic ASP in combination of JavaScript. I want to migrate it to ASP.NET. I have posted a part of the form at the end of this post.My questions:1. I use <option <%If iFood="0" then%>selected<%End If%> value="0">No value selected</OPTION> to select the selected item when the form is reloaded after the selecting. I know that this also works in ASP.NET, but isn't there a typical ASP....
Handling DBNull Values in DropDownList Selected Value
I have a dropdown list inside a formview that is used to update a business opportunities table. Each opportunity may or may not have a salesperson assigned. On the update page I want to set the current value in the database as the selected value in the dropdown list. But if there is no salesperson assigned i need to handle the dbnull value and not try to set the selected value. Can someone give me some pointers? Should i handle this in the Formview_databinding event or in the Datasource for the opportunity Databinding event? How do i get at the cell of the datasource that i need to test for ...
DropDownList value selected base on database value?
Hi, is there anyway how I can allow my dropdownlist (on pageload event) to select the value base on the value found in the database, in addition I also want the dropdownlist to contain other values too however the selectedValue must be the one found in the database. Sorry if it sounds confusing. I'm using VB.NET 2003 with ASP.NET Thanks. Hi,Whatever you want to get selected for your dropdown use following code.if(dropdownid.items.findbyvalue("value") != null){ dropdownid.items.selecteditem = false; dropdownid.items.findbyvalue("value").selected = t...
Setting a label value to a dropdownlist selected value
I am trying to set the value of a label to the selected value from a hidden dropdown list. This code is not working and the label value remians at its default. Any ideas? Thanks very much. Protected Sub DetailsView1_DataBound(ByVal sender As Object, ByVal e As System.EventArgs) Dim mylabel As Label Dim myddl As DropDownList If (DetailsView1.CurrentMode = DetailsViewMode.ReadOnly) Then mylabel = DetailsView1.FindControl("Label1") myddl = DetailsView1.FindControl("DropDownListViewOffice") mylabel.Text = myddl.SelectedValue.ToString End If I have now put this code in the Page_Load su...
How to take selected value of dropdownlist in web method using cascading dropdownlist
Hi All,I am using C# asp.net 2.0 and ajax1.0.I am trying to fill dropdownlist using ajax cascading toolkit but I am not able to populate the dropdownlist. My question is how do I take input value of parent dropdownlist in web service the fill the data that is in my senario I have subprod parent (fill on page load) and then Prod fill on subprod selection. The web service method I used is public CascadingDropDownNameValue[] GetProd(string knownCategoryValues, string category) { StringDictionary kv = CascadingDropDown.ParseKnownCategoryValuesString(known...
Dropdownlist assign selected value
I have a dropdownlist which I populate from a db table and its value is in one column and the display text is in another. When I run my report I do a join to get the text to display on the page based on the value column. Here is my query: SELECT fcomp_assign, (SELECT fcode_cmmt FROM fcode_mstr WHERE fcode_value = fcomp_assign AND fcode_fldname = 'fcomp_assign') AS AssignedTo FROM fcomp_mstr WHERE fcomp_comp_id = 8 This returns what I expect: 6 and Customer Service Problem is I want to populate the list with this query:SELECT fcode_cmmt, fcode...
Getting the Selected Item of dropdownlist inside Web User Control on a Web Form
Ive got a dropdownlist control inside a web user control called Entity.ascx. This web user control is on a webform.aspx. In Entity.ascx class I created a SelectedEntity property that returns the selected item in the dropdownlist. Inside webform.aspx when btnGo is pushed I set a string and pass it in the url. I am trying to get the entity they selected via the property (SelectedEntity) inside Entity.ascx. As the SelectedEntity property tries to return the selected item in the dropdownlist I get this error: System.NullReferenceException: Object reference not set to an instance...
Passing Values from a Web Form to Another Web Form
Hello All! I am trying to pass values from one web form to another web form. I know that there are 3 ways of doing this: queryString, Server.Transfer and Session. I am using the Server.Transfer method. But I am not able to create, in my 2nd web form, an instance of my 1st web form. My 1st Web form is named CallTrack.aspx and my 2nd is named Export.aspx. What I mean is something like this: Public value as CallTrack. I can't create it in my 2nd web form because when the intellisense is displayed, there's no CallTrack in the options. Thanks! How about using cross-...
Based on selected value from HTML.Dropdownlist, the values to be fetched
Hi, I'm using Html.DropDownList. When selection within this box changes, I need to retrieve the values from table based on the selected id(datavaluefield) of dropdownlist. Here my code ViewPost.cs viewpage <%=Html.DropDownList("CategoryID",ViewData["CategoryID"])%> ---- based on selected value from the user the below table should fetch the value the db <table> <tr> ...
Web resources about - How to assign string value to dropdownlist when selected value field is an int(id of item) - asp.net.web-forms
Tag Synonyms - Stack Overflow
Q&A for professional and enthusiast programmers
Accidental entities - what about the UI?
This post is a follow-up to my previous blog post " Accidental entities - you don't need that identity ". In that post, we followed a consultant ...
Flash Builder Plug-in for SAP Netweaver Gateway - Adobe Labs
Search Navigation Labs Home Wiki Home Technologies Alchemy Blueprint Camera Profiles and DNG Profile Editor Cirrus ColdFusion 10 DNG Codec Fireworks ...
Thank you for considering membership of Nomad Club – Kazakhstan’s first Frequent Flyer Program. You could soon be on your way to earning free ...
Languages -> C# Articles, Tutorials, Examples: ASP Alliance
Blog - Avisra
Avisra Web Development Home Blog Services Contact The Blog Latest Module Builder: How can we make it better? Sitefinity by Chris on July 2, 2013 ...
Online Booking Tool Support
This Online Booking Tool Support page might help you as you navigate through the process of booking travel through your OBT provided by CWT. ...
@Html and beyond
... ); } return string .Format( “{0}{1}” , me.Member.Name, id); } The Html building methods are quite simple. Building a dropdownlist for a ...
Top Ranked Articles
Top Ranked Articles - Free source code and tutorials for Software developers and Architects.; Updated: 23 Feb 2013
Unit Testing DateTime.Now Without Isolation
public virtual void SeedWithYearsSince(DropDownList list, int year){ for (int index = year; index
Resources last updated: 12/18/2015 6:39:01 AM
|
|
Item Successfully Added to Cart
An error was encountered while trying to add the item to the cart. Please try again.
Please make all selections above before adding to cart
The following link can be shared to navigate to this page. You can select the link to copy or click the 'Copy To Clipboard' button below.
Copy To Clipboard
Successfully Copied!
Nonlinear Systems of Partial Differential Equations in Applied Mathematics, Part 1
Edited by: Basil Nicolaenko
Available Formats:
Hardcover ISBN: 978-0-8218-1125-2
Product Code: LAM/23.1
List Price: $83.00 MAA Member Price:$74.70
AMS Member Price: $66.40 Click above image for expanded view Nonlinear Systems of Partial Differential Equations in Applied Mathematics, Part 1 Edited by: Basil Nicolaenko Available Formats: Hardcover ISBN: 978-0-8218-1125-2 Product Code: LAM/23.1 List Price:$83.00 MAA Member Price: $74.70 AMS Member Price:$66.40
• Book Details
Lectures in Applied Mathematics
Volume: 231986; 470 pp
MSC: Primary 35; Secondary 00;
These two volumes of 47 papers focus on the increased interplay of theoretical advances in nonlinear hyperbolic systems, completely integrable systems, and evolutionary systems of nonlinear partial differential equations. The papers both survey recent results and indicate future research trends in these vital and rapidly developing branches of PDEs. The editor has grouped the papers loosely into the following five sections: integrable systems, hyperbolic systems, variational problems, evolutionary systems, and dispersive systems. However, the variety of the subjects discussed as well as their many interwoven trends demonstrate that it is through interactive advances that such rapid progress has occurred.
These papers require a good background in partial differential equations. Many of the contributors are mathematical physicists, and the papers are addressed to mathematical physicists (particularly in perturbed integrable systems), as well as to PDE specialists and applied mathematicians in general.
This item is also available as part of a set:
• Request Review Copy
• Get Permissions
Volume: 231986; 470 pp
MSC: Primary 35; Secondary 00;
These two volumes of 47 papers focus on the increased interplay of theoretical advances in nonlinear hyperbolic systems, completely integrable systems, and evolutionary systems of nonlinear partial differential equations. The papers both survey recent results and indicate future research trends in these vital and rapidly developing branches of PDEs. The editor has grouped the papers loosely into the following five sections: integrable systems, hyperbolic systems, variational problems, evolutionary systems, and dispersive systems. However, the variety of the subjects discussed as well as their many interwoven trends demonstrate that it is through interactive advances that such rapid progress has occurred.
These papers require a good background in partial differential equations. Many of the contributors are mathematical physicists, and the papers are addressed to mathematical physicists (particularly in perturbed integrable systems), as well as to PDE specialists and applied mathematicians in general.
|
|
# Of monodromy, parallelization, and numerical hell
In a previous blog post, we described a software package that exploits the monodromy action for solving polynomial systems in a parametric family. We’re happy to report that the original paper accompanying this package is now published in the IMA Journal of Numerical Analysis. In this paper, we laid out the basic framework for monodromy solvers and highlight potential strengths of this approach, both by analyzing its complexity (conditional on strong randomness assumptions!) and testing our package against other solvers.
In this post, we will describe the sequel to this paper, presented at ISSAC 2018.
Many of the celebrated approaches to numerically solving polynomial systems employ a methodology in which a start system and a target system are both fixed. Numerical solutions to the target system are realized by numerical continuation along a fixed number of solution paths. This paradigm is ripe for speeeding up via parallel computing.
In the cartoon above, H(t) denotes a homotopy connecting the solutions between two fictitious polynomial systems. For two solution paths to be tracked, zero communication is needed from the two path trackers. Thus, four parallel processors result in a perfect speedup. This phenomenon is known as embarrassing parallelism.
With monodromy solvers, one structural property of systems we wish to exploit is lack of sharpness in the number of paths needed to find all solutions. For instance, the homotopy M(t) in the image above has two diverging solution paths. In some sense, an optimal homotopy for the system M(1) would track only two paths. The goal of our monodromy approach is essentially to produce an optimal start system for a given family of systems. However, such a start system may not be easily accessible by deterministic calculation. Our approach is fundamentally randomized—for a family with generically $d$ solutions, we allow for
$O \big(|G| \cdot d \big)$
path-tracking steps, where $|G|$ measures the size of an underlying data structure we call the homotopy graph. Our desired output is a generic system with $d$ solutions. In our parlance, we may visualize the homotopy graph connecting some systems in the parameter space and a solution graph of size $|G| \cdot d$ lying above it.
In reality, our goal is to track as few paths along the homotopy graph as possible. With this goal in mind, we may observe that devising a scheduling algorithm for a parallel incarnation of monodromy is not a trivial task. One of our main contributions is a description of such an algorithm and numerous simulations indicating its potential to provide substantial speedups. If you’re curious, check out the paper or the accompanying github repository.
Another factor complicating the aforementioned scheduling algorithm: in reality, path-tracking can fail. In theory, paths in the parameter space which are suitably randomized will avoid the locus of ill-conditioned systems with probability $1.$ In reality, the core numerics may be unable (or simply unwilling) to distinguish nearly-singular systems from those that truly are. We may imagine, in the worlds inhabited by our graphs, several scattered regions of numerical hell, as depicted below.
In the ISSAC paper, we consider a simplified model of path-tracking failures, and describe its implications for the scheduling algorithm as well as robustness of our approach to a few failures—namely, if our graph is a clique as in two images above, we may tolerate a certain number of failures and still expect to produce the correct number of solutions, under suitable randomness assumptions.
One final word on randomness assumptions—despite being demonstrably false, they turn out to be useful in practice. For a different, but related, perspective, check out this nice lecture on sampling in numerical algebraic geometry.
|
|
## LaTeX forum ⇒ General ⇒ listings | Color in HTML Code
LaTeX specific issues not fitting into one of the other forums of this category.
nifty
Posts: 16
Joined: Sat Oct 09, 2010 4:24 pm
### listings | Color in HTML Code
I have a document from the author and he is using the listings package. He has this code:
\lstinputlisting[language=HTML]{scr/html/roll.html}
roll.html has this:
<!doctype html><html> <head> <meta charset="UTF-8"/> <title>JavaScript Temperature Converter</title> </head> <body> <h1>Temperature Conversion</h1> <p> <input type="text" id="temperature" /> <input type="button" id="f_to_c" value="F to C" /> <input type="button" id="c_to_f" value="C to F" /> </p> <p id="result"></p> <script src="temperature.js"></script> </body></html>
His PDF looks like this:
author.png (149.26 KiB) Viewed 3950 times
My file looks like this:
myfile.png (146.58 KiB) Viewed 3950 times
Notice the coloring of "charset," "id," and the words between <title> and </title>. Any ideas on why the difference in color? He is also using a lot of Java code and that coloring seems to be correct. It is just when he uses the language=html.
Last edited by localghost on Mon Oct 10, 2011 5:34 pm, edited 1 time in total.
Reason: Preferably no external links (see Board Rules). Attachments go onto the forum server where possible.
localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm
nifty wrote:I have a document from the author and he is using the listings package. […]
Can't the author just leave the concerned piece of code to you so that you can reproduce the appearance? Nevertheless, a minimal example that shows your recent efforts would be good to get closer to a solution.
Anyway, you have to set the colors for identifiers and strings explicitly. From what I can see on the pictures you attached, I tried to reproduce the desired output.
\documentclass[11pt]{article}\usepackage[T1]{fontenc}\usepackage{listings}\usepackage[dvipsnames]{xcolor} \lstset{% basicstyle=\small\ttfamily, breaklines=true, columns=fullflexible, frame=single, frameround=tttt, showstringspaces=false} \begin{document} \lstinputlisting[% language=HTML, backgroundcolor=\color{Apricot!25}, identifierstyle=\color{magenta!50!black}, stringstyle=\color{blue} ]{scr/html/roll.html}\end{document}
It goes without saying that this is only a basic example which needs some adjustments, especially regarding the colors. Since you didn't provide any code, I can't explain why the pieces of text you mentioned are colored in your example.
And next time please upload attachments to the forum sever. External links can get lost with time and make a problem incomprehensible later. If necessary, convert and scale images to match the 256kb limit for single attachments.
Thorsten
Attachments
The output as obtained by the given code.
reproduction.png (67.72 KiB) Viewed 3950 times
LaTeX Community Moderator
¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1
johnkimber
Posts: 1
Joined: Thu Apr 25, 2019 8:15 am
Check with this..color codes
|
|
Acute Coronary ..
### Make the Diagnosis: Acute Coronary Syndrome
#### Prior Probability of Acute Coronary Syndrome
About 13% of patients presenting to the emergency department (ED) with acute chest pain will prove to have acute coronary syndrome (ACS).
#### Population in Whom Acute Coronary Syndrome Should Be Considered
The use of cardiac biomarkers for ED patients with acute chest pain is now ubiquitous. This is done because the biomarkers have high sensitivity and ED physicians do not want to miss ACS. Using biomarkers, history, and electrocardiogram (ECG), ED physicians seek to categorize patients presenting to the ED with chest pain into 1 of 3 groups: ST-segment elevation myocardial infarction (STEMI), non-ST-segment elevation ACS (which includes non-STEMI and unstable angina), and noncardiac chest pain. The ECG alone is usually sufficient for diagnosing STEMI. Identifying patients with non-ST-segment elevation ACS requires the combination of clinical information and biomarkers. Biomarkers alone are not sufficient, since some patients with elevated biomarkers do not have ACS, and some patients with ACS do not have elevated biomarkers.
#### Assessing the Likelihood of Acute Coronary Syndrome
Individual risk factors and chest pain features do have some utility in assessing the likelihood of ACS; a prior abnormal stress test (specificity, 96%; likelihood ratio [LR], 3.1; 95% CI, 2.0-4.7), peripheral arterial disease (specificity, 97%; LR, 2.7; 95% CI, 1.5-4.8), and pain radiation to both arms (specificity, 96%; LR, 2.6; 95% CI, 1.8-3.7) were the clinical findings most suggestive of ACS, and ST-segment depression (specificity, 95%; LR, 5.3; 95% CI, 2.1-8.6) and any ischemia on ECG (specificity, 91%; LR, 3.6; 95% CI, 1.6-5.7) were the most useful ECG findings (see Table 99-1). However, no individual finding is, by itself, sufficient for diagnosing or ruling out ACS. Furthermore, several studies have demonstrated that clinician gestalt alone is not sufficiently sensitive to exclude ACS or significant coronary artery disease at a clinically relevant threshold.1,2
Table 99-1.Useful Findings for Assessing the Likelihood of Acute Coronary Syndrome
Because individual historical and ECG findings are not adequate for ruling out or diagnosing ACS, risk scores have been developed (Table 99-2). Some of the features in risk scores require the clinician to interpret the meaning of patient symptoms, and those features must be assessed by ...
Sign in to your MyAccess profile while you are actively authenticated on this site via your institution (you will be able to verify this by looking at the top right corner of the screen - if you see your institution's name, you are authenticated). Once logged in to your MyAccess profile, you will be able to access your institution's subscription for 90 days from any location. You must be logged in while authenticated at least once every 90 days to maintain this remote access.
Ok
## Subscription Options
### JAMAevidence Full Site: One-Year Subscription
Connect to the full suite of JAMAevidence content and resources including interactive self-assessment, videos, and more.
|
|
A quick guide to HTML/CSS Frameworks
Make sure your framework has the functionality you need without bloated code to slow you down
November 22, 2015
Framework inside the Seattle Public Library (source: Jan Tik via Flickr)
Key Concepts
Before we dive into frameworks, let’s first go over a few general ideas. We don’t have to agree on everything; all we want is to prevent misunderstandings over the course of this book.
First, there are a handful of terms that may be used differently in other contexts:
Learn faster. Dig deeper. See farther.
Join the O'Reilly online learning platform. Get a free trial today and find answers on the fly, or master something new and useful.
External (also known as public or open)
Anything that comes from outside ourselves or our organization and is out of our control. In web development, social site widgets or frameworks are often external.
Internal (or in-house)
Anything that originates from within our organization and is within our control. In web development, site designs, or site style sheets, are often internal.
Pattern
A classical design pattern. In web development, the individual elements of a document or app are patterns, but so are document types like a three-column article page.
Cost
A measure of any negative consequence. Typically expenditures of work, time, or money, but possibly negative changes in, for example, perception, satisfaction, or reputation. In web development, for instance, any element added to a page has a cost in terms of reduced page performance.
Tailoring
The producing and adjusting to precise dimensions and needs. In web development, tailored code is all code that’s needed—or going to be needed—by a project, but not more.
Second, some assumptions:
• Code has a cost. For example, there is the cost of development, performance, maintenance, documentation, process, quality, and conversion (though not all of them always apply, and not all of them affect the same groups). Unnecessary code has an unnecessary cost.
• Site owners and developers want to save cost. In particular, they want to save unnecessary cost.
• Tailoring code means removing or, better, not even writing or embedding unnecessary code.
• Good code is code that is of measurably or arguably high quality, where arguably means conforming to common best practices.
High-quality code can be said to be tailored, but it doesn’t follow that high-quality code saves cost, at least not as a general rule. Tailored code itself, however, always saves cost. With this first insight, let’s begin.
Understanding Frameworks
What Is a Framework?
“Framework” is a broad term, often misunderstood. Conceptually, a framework in the web development sense can be likened to a library: a library not of books but of design patterns, complete with all needed functionality.
For example, the Pure framework knows, with overlap, the following button types:
• Default
• Primary
• Icon
• Active
• Disabled
• Customized
Functionality usually means presentation (styling via CSS) and sometimes also behavior (scripting via JavaScript). The advantage of using a library is that we don’t have to code this functionality ourselves, or do so repeatedly. We instead follow the library’s instructions for the structural side (markup via HTML).
For example, YAML requires the following HTML code for a horizontal navigation menu:
<nav class="ym-hlist">
<ul>
<li class="active"><strong>Active</strong></li>
</ul>
</nav>
The only missing piece or, literally, link, is connecting the library so to have it apply the functionality to the chosen patterns, on basis of the mandated markup.
For example, to use Bootstrap, we must reference something like:
<link rel="stylesheet"
href="https://maxcdn.bootstrapcdn.com/bootstrap/
3.3.1/css/bootstrap.min.css">
Now that we compared frameworks to fully functional pattern libraries, here’s another view. Frameworks can also be seen as just the style sheets and scripts they are, and external frameworks as shared style sheets and scripts that get lifted to a higher status. We could indeed pick any style sheet or script or both and declare it a framework!
The implications of this second insight are far-reaching. Although rather trivial, it’s one of the keys to understanding frameworks. We’ll keep the term “framework” to use common industry language but will at times look at the idea of elevated style sheets and scripts for guidance.
Why Frameworks?
Frameworks promise to save both development and design time. The thinking goes that many of the things site owners and developers want have been done a thousand times, and thus there is no need to reinvent the wheel. Internal frameworks commonly enjoy a more sober regard, so this particularly applies to external frameworks.
If frameworks come with this promise, the question arises whether or not they live up to it. The answer boils down to a cost calculation that is, unfortunately, different for every framework and project. How much development cost was saved? How much was, in turn, spent on training, customization, and upgrades?
Apart from suggesting that we do the math and think through every project, the following pages cover frameworks in the necessary detail to empower everyone to form their own theory about the raisons d’être of frameworks.
Types and Uses of Frameworks
While all frameworks provide patterns, we must note general distinctions. For one, there is a difference between internal and external frameworks—the external ones are those that typically get referred to as frameworks. Then, there is a difference between using and developing a framework (note that developers can be users, which makes for some blurriness). And finally, there is a difference between experts and amateurs.
Let’s chart this up.
Expert Beginner Use Develop Use Develop Internal framework ? ? ? ? External framework ? ? ? ?
What do you think? Should either type of framework be managed either way, by either group?
Here’s what I think. Let’s compare.
Expert Beginner Use Develop Use Develop Internal framework Yes Yes Yes Yes External framework No Yes Yes No
Please note that developing an internal framework and making it public, as we could even apply to blog themes, is here not considered developing an external framework. The decisive factor is the goal during the initial development process. A thorough revision and overhaul of an framework to make it external or internal-only, however, constitutes a development phase, and would be acceptable.
Reflected in the table is the idea that frameworks can be used and developed liberally, with two exceptions. One exception is that experts shouldn’t use external frameworks; the other is that beginners shouldn’t develop external frameworks.
The two exceptions stem from a violation of quality standards: while the external framework violates the ideals of the expert (which I will later describe), it is the beginner who would not even know the necessary ideals to create a quality framework.
The internal framework is safe to use or develop in every case because that’s the preferred way of developing web documents and apps. Internal beats external every time because external cannot, by definition, know all the needs of the organization and fails many quality standards. Second, internal solutions are the better route for both experts and beginners to stay sharp and to learn, since their mistakes have a smaller impact.
The development of an external framework is safest only with an experienced web developer, who can, following the principles outlined in this book, skillfully build and document it so that it has a better chance to be useful, at a low cost-benefit ratio. For the less experienced developer or the one in a hurry, use of an external framework is thought to be more viable simply because things matter a lot less for him; he may discern few impacts in quality, and he may not yet have a long-term vision for his project.
Attributes of a Good Framework
Now, what is a “good” framework? What does a framework have that we want to use? What constitutes the framework we may want to build? I’ve thought about and worked with and discussed this question many times.
In a professional or expert context, “good” usually refers to quality. We can establish this for frameworks as well. A framework should, especially when it’s an external one, meet the highest applicable quality standards.
Frameworks tend to be only used after a project reaches a certain size and complexity (a one-pager doesn’t need Bootstrap or YAML). They’re also done by third parties. As size and complexity makes issues weigh heavier (and since third parties, as we have seen, cannot know a project’s full needs), we’re in need of some guarantees and safeties.
We can get one such safety if we can curb the bloat that external frameworks in particular bring. We know what helps: tailoring. So a good framework should expressly be tailored.
If we assume a complex project, we’re likely not alone working with or on the framework; and if it’s an external one, we have no idea whether the developers of that framework speak our language (literally and metaphorically). What helps here is usability. A good framework should be usable.
And then, requirements change just as the times: how do we work with the framework going forward? What if we need to add something, perhaps in a pinch? What helps with that is extensibility. And thus a framework should also be extensible. At least we or the framework should be clear how to extend it.
We’re just being professional and reasonable when we demand quality. We gain extra confidence, then, by wanting frameworks that are also tailored, usable, and extensible. Let’s look at these three special attributes a little closer and point out the options developers have to get frameworks to that state.
1. A Framework Should Be Tailored
We defined tailoring as “producing and adjusting to precise dimensions and needs.” Producing refers to developing a framework—whether internal or external—while adjusting commonly means fitting an external framework. The key here is “precise dimensions and needs.” We need to know our needs—otherwise we can neither produce nor adjust something to fit.
One view of tailored code, by the way, is to compare needed code with overall code. That can be hard to measure, because the number of characters or lines in our code doesn’t do the trick. But conceptually, tailoring means using as little and yet as effective code as possible, and not more.
What can we do to tailor? The approach depends on the origin of the framework, and that origin makes for a big difference.
An internal framework is relatively simple to tailor: We develop to the needs of our project from the beginning. These needs may be defined by comps (comprehensive layouts) and mocks (mock-ups) or, better, a style guide. Once all needed page types and elements have been specified, they’re coded up. If they’re all used by the later site or app, the code cannot be anything but tailored (although it can possibly still be optimized and compressed).
An external framework, however, is much more difficult to tailor (by the receiving side, because it’s impossible for the originator). In a basic sense, we need to deduct all needed functionality from all offered functionality, and then remove the code that remains. That leads us to the key issues with external frameworks: removing code may not even be possible, and tailoring then depends on the quality of the framework code and its documentation (e.g., tailoring will require testing, might break the framework, and could make the same work necessary for later updates, if not outright thwarting the ability to move to newer frameworks).
These are big issues that make for good reasons why few people actually go to the length of customizing or tailoring external frameworks (or any external code, for that matter). Yet the outcome—non-tailored and lower-quality code—is not very expert-like, and inferior. And so we see with more clarity why in a professional context, external frameworks shouldn’t be preferred. They promise to save cost, only to come with a stiff hidden tax or else bring down the quality of our work.
Now, some frameworks like Bootstrap or Gumby have begun to address these problems by offering sophisticated customization wizards. This is smart, because it significantly alleviates the issues of non-tailored solutions. Framework developers should offer and users use such functionality.
By the way, there’s another problem we need to consider: while we’re benefiting from either our decision to save cost or to improve quality, our end users benefit mostly from quality. Technically speaking, they are rarely on the list of beneficiaries if we decide to deploy a framework that’s bloated but easy to churn out.
To tailor internal frameworks:
• Build the framework to these needs.
To tailor external frameworks:
• Customize or modify the framework to these needs (or abstain from the framework).
2. A Framework Should Be Usable
A good framework is not only tailored but also usable. But what is usability for frameworks? It starts with applying the common definition of usability: ease of use and learnability. And with a universal rule: keep it simple. Simplicity helps everything.
But that’s not quite a complete answer, and so we need to differentiate again. The distinction that serves us here is not one between frameworks, but between roles: framework users and framework developers.
For the framework user (who may be a developer himself but is now concerned with working with the framework), a usable framework is also easy to understand. That ease of understanding is primarily achieved through clear framework documentation and, where applicable, concise code.
For the framework developer, there’s much more emphasis on usable code. Luckily, there are two things we can firmly link with helping code usability: maintainability practices and code conventions (coding guidelines). Adherence to maintainability practices and consistent style are the backbone for usable code.
With slightly smaller boundaries than developer experience, I generally believe there is a subfield of usability: developer usability. It could be defined as “the ease of use and learnability of code.” Perhaps this field doesn’t get much attention because usable code goes under different names, as we just found, but perhaps it would benefit from being treated separately.
To make frameworks more usable for users:
• Keep it simple.
• Perform usability tests.
• Provide documentation for framework users.
To make frameworks more usable for developers:
• Keep it simple.
• Aim for self-explanatory code.
• Format code legibly and consistently.
• Provide documentation for framework developers.
3. A Framework Should Be Extensible
The final attribute to underscore is extensibility. Extensibility for a framework means that it’s not just possible, but well-defined and easy to extend it.
Extensibility is necessary for two reasons. First, external frameworks in particular won’t offer everything we need, so there needs to be a way to add functionality. Second, especially in large projects, there’s a tendency for new patterns to pop up. The problem with these is their uncertainty and uniqueness: they may only be used once or twice and don’t warrant a place in the framework core or even near more common extensions. Both their location and handling have to be thought of.
To make up for lacking functionality in a framework, users typically help themselves by pretending they don’t use a framework in the first place. That is, they have a style sheet or script that handles everything the framework doesn’t cover. That’s actually quite OK; the point here is to be clear about how such “non-framework functionality” or extensions are handled (and we notice how extensibility is also a user responsibility). If nothing else, extensibility stresses the need for the most basic of all code safeties: a namespace (a framework-specific ID and class name prefix, and the same namespace in JavaScript).
Next, new and rarely used patterns are a challenge that runs in the best families. There tends to always be a need for something new, and there are always document types or elements that are used infrequently. They’re one of the biggest contributing factors to code bloat. They are hard to control if they don’t get watched and reigned in vigorously. Though I could give a longer dissertation about the matter, an effective counter-practice is to either designate style sheet and script sections for new and experimental code, as well as rare elements—or to even put aside a separate style sheet and script for such purposes. The framework developers should anticipate this and make recommendations, but users should come up with their own guidelines if this piece has not been covered. A documented standard for new code allows better monitoring and better decisions on whether to keep (and relocate) the code, or to remove it.
We’ve very successfully applied this principle with Google’s HTML/CSS framework Go—not to be confused with the programming language, which was conceived two years later. Go came with a “backpack” library, Go X, which included elements that we used only occasionally. This kept the core very small—4,250 bytes including the Google logo—but offered the use of additional, common-enough elements. Project-specific code made for a third layer that had to be carried by each project style sheet itself.
To make frameworks more extensible:
• Use a framework namespace.
• Define handling of non-framework code.
• Specify where new and rarely used code should be located (also a framework-user responsibility).
• Regularly review new and rarely used code, to either make part of framework or remove (also a framework-user responsibility).
Note
Please note that despite all my experience and convictions, I’ve phrased these rules as strong suggestions. I was tempted to say “must,” “must,” “must.” Whenever we like more dogma in our web development life, we use this verb.
Another thing before we move on: note that no matter the quality of the framework, the goal for its use is always on the owners and developers. Frameworks can be likened to cars: a good car should be, say, safe, easy to handle, and economical. And so a good framework should be tailored and usable and extensible. But just as we look at the driver to know the destination for her car, we look at the developer to know the goals for the framework she’s using. We can drive a framework against the wall just as we can a car, which is the reason we differentiate between experts and novices. Just to get this out there: a framework doesn’t drive itself.
Using Frameworks
Two ways we’ve been exposed to frameworks are by using and developing them (with some inherent overlap). Our initial definition gives this an interesting spin, as we have seen that we can regard any style sheet or script as a “framework.” So anyone who has worked with style sheets and scripts already has a basic idea of how to use frameworks.
After all that we’ve learned, using can’t be as complicated as developing, and must mostly depend on the framework. It requires a choice of framework, and then demands two ground rules.
Choosing a Framework
The “pro-quality” choice has been explained as using or developing an internal framework, and choosing a framework generally applies to external ones. The choice of an external framework depends on two factors:
1. Which one meets our needs the best?
2. Which one is of the best quality (that is, which one is as tailored/customizable, usable, and extensible as possible)?
These questions underline the importance of knowing our precise needs. It is even important in order to pick a framework, as knowing our needs helps determine which framework fits better (tailoring) and comes closer to our extensibility needs (though simple needs don’t require extensibility as frequently as comprehensive needs).
The Two Ground Rules of Using a Framework
And of any framework at that. These two rules are golden:
Whether internal or external framework, whether expert or beginner, read and follow the documentation.
This rule is paramount because the second source of quality issues with frameworks and the works created with them (after framework bloat) is user and developer error. Or user and developer misconduct! Some scenarios that illustrate this might be when a pattern is hacked to work, when something has been developed that’s actually already part of the framework, when things get overwritten without regard for framework updates, or when something has just been “made working.”
When using frameworks, always follow the documentation.
2. Don’t overwrite framework code
For reasons that will become clearer in the next section, never overwrite framework code.
Contributing to the expert’s dilemma with external frameworks, overwriting framework code can have unforeseen consequences and break things with future updates. Here’s an example:
Framework:
header {
/* No layout declarations */
}
Overwrite:
header {
position: relative;
top: 1em;
}
Framework update:
header {
left: 0;
position: absolute;
top: 0;
}
The example, simplified as it is, shows how a seemingly innocent change can have acute consequences. Here, a header is moved by one em. (Note that the example constitutes an overwrite because the framework header is inherently “positioned” and also rests on the initial values for position and top.) The next framework update, however, switches to absolute positioning. As the overwriting rules come later in the cascade, they prevent the update from working (with the exception of left: 0;). In cases like this, overwrites are unpredictable. Overwrites should hence be avoided where possible.
The remedy: For internal frameworks, update the framework, or leave things as they are (as in, no overwriting). For external frameworks, leave things as they are, or create a separate pattern that does the job (like an alternative header, with different markup). Stay away from forking or “patch improvements”; solve issues at the core, or not at all.
Note
The more complex the project and the bigger the organization, the harder it can be to display the necessary discipline. Everyone working with a framework needs to follow these two rules, however, to achieve the highest levels of quality and consistency possible.
Developing Frameworks
Developing frameworks is an art form that comes with a lot of responsibility. For external frameworks, it comes with the aura of a daredevil (though naiveté rears a head, too). As we’ve seen throughout this book, it’s by necessity most difficult to build an external framework because we cannot know the needs of other projects. And hence, we can hardly avoid shipping something that is incomplete—or that may mutate into bloat.
The following pages describe the basics of writing a framework. The ideas describe the situation of an experienced web developer leading a framework effort in a large organization.
Principles
We’ve already done our assignment and fleshed out the principles for framework development. A framework should aim for the highest quality standards, and then:
1. A framework should be tailored.
2. A framework should be usable.
3. A framework should be extensible.
These shall serve as every framework’s core values (for which we can use the avenues outlined earlier).
Customization, as identified under 1. A Framework Should Be Tailored, plays a special role here, for it is the secret weapon—and last line of defense—of the external framework developer. Offering framework customization options is the only way to get closer to tailoring for outside users, users whose projects we will never know.
I decided against including a section about customization because it’s not a magic pill for external frameworks, and can stack the whole deck against the framework developer instead of the framework user. This is because the more customization options there are, the more complex the framework gets. Yet that’s still only talking framework development. The framework and all its customized subversions, as we’ll see shortly, still need to be tested, quality-managed, maintained, and so on.
Prototype
The single most important thing we need to build a successful framework is a prototype. Here we benefit from our recognition that we’re really only talking about plain-vanilla style sheets and scripts. Large projects—projects like those for which we now talk frameworks—have always benefited from prototypes.
What do we mean by prototype? In its simplest form, it is a static (internal) website or demo site. It should contain all document types and elements we need in production: the prototype is where we code all the structure (HTML), presentation (CSS), and behavior (JavaScript). And the prototype should include realistic (occasionally intermingled with extreme) sample contents: that’s how we test that everything works.
A prototype is an irreplaceable testing ground that we need to obtain the end result we want.
Prototypes follow their own principles, however. They must be, as I attempted to summarize in earlier years (slightly reworded):
• Complete
• Current
• Realistic
• Focused
• Accessible/available
• Managed with discipline
• Maintained
• Communicated/promoted
• Documented
Each of these points is important, but the first three are critical. The prototype has to include everything (all document types and elements), it must be current (any functionality changes must be reflected immediately), and it needs to be realistic (the sample data must be an as-good-as-possible approximation of how the framework is going to be used outside of the prototype).
Quality Management
In order to be sure that we deliver the quality we’re committing to as professionals, we need to verify it. This is done through quality assurance (which aims to prevent issues by focusing on the process), and quality control (which aims to find and fix issues in the end product).
Web development, as a still rather young discipline, knows more quality control than quality assurance. Good examples are validation, accessibility, and performance checks, of which there are plenty. On the quality assurance end, the most prominent example is the enactment of coding guidelines, but some organizations and individuals go so far as to use elaborate infrastructure to continuously test and improve their code. (This is all related to web rather than software development, since in software development, there is a longer history and strong tradition of working with tests.)
For quality assurance, it’s useful to:
• Establish coding guidelines
• Define output quality criteria
• Run regular tests (over prototype and live implementations)
For quality control, test:
• Accessibility
• Performance
• Responsiveness
• Maintainability
• Validation
• Linting
• Formatting
(Incidentally, I run a website hub dedicated to web development testing tools. Check uitest.com/en/analysis/ for a large selection of them.)
To take a page out of Google’s book, it’s best to automate such checks. Reviewing tool documentation can give valuable pointers, as a number of tools can be installed locally or come with an API. In addition, there are instruments like Selenium and ChromeDriver that facilitate automated browser testing. As with many of the more complex topics, this book will resort to just showing directions.
Maintenance
We’ve so far noted how principles, a prototype, and quality management are important in framework development. The last key item to stress is maintenance. Maintenance here primarily means (similar to prototypes) a strong commitment to move forward with a framework. This is important for two reasons.
For one, in the case of external frameworks, maintenance is crucial because publishing a framework is a promise to the user base. That promise is precisely that it’s going to be maintained. It’s also a promise in how it’s going to be maintained, in that we do everything in our power not to change any structure, but only the framework style sheets and scripts.
For another, in any framework, a commitment to maintenance acts like another form of safety. The general idea in web development is that the HTML is most important to get right, because it’s more expensive—think our cost definition—to change than style sheets and scripts. An explicit commitment to maintenance will keep us from discarding a framework to just “build another,” and thus lives up to the vision of CSS-only design iterations and refactorings. (Of course, true structural changes will still always require HTML changes, and with that, eventually, CSS and JavaScript edits.)
A framework, solving widespread and complex development and design issues, comes with an express obligation to maintenance.
The handling of framework updates is delicate enough to deserve a separate section. Updates are generally easier to manage for internal frameworks than for external ones, though updates in a large organization with many developers spread out over many places can be challenging, too.
Here are a few tricks to make framework updates easier:
• Try to avoid HTML changes because of their comparatively high cost. An update should only consist of styling or scripting changes and impart no actual work for users (which, to counter the aforementioned definition blurriness, also means developers who work with the framework). The update of framework references can be OK.
• Provide a way to test whether the update would have any ill effects. This can happen through something simple like bookmarklets (see undefined ‘1-5’), or something more sophisticated like proxying (using a proxy to intercept and change requests to framework files in order to feed updated files for testing).
• Inform users about possible side effects (and use this as an opportunity to educate them about, for example, the problems of overwrites, as explained in 2. Don’t overwrite framework code).
• Communicate the status of ongoing updates.
What we’re assuming here is that we’re not just “versioning” frameworks. That’s the practice of shipping a framework—let’s say, foo—and when the first changes come, not updating foo, but shipping foo-2. And then foo-3. And so on. This practice may be an option for us, but not a rule. The rule should be to update the framework itself, per the ideas listed here. The reason is that versioning defeats the purpose and advantage of CSS (similarly for JavaScript), which are immediate changes, supported by separation of concerns (HTML for structure, CSS for presentation, and JavaScript for behavior). We’ll touch on the vision behind this shortly, but we should strive to do all updates through what we already have. And only for major changes do we look into our toolbox and, always carefully, reconsider versioning.
Documentation
Though not technically a part of the development process, documentation must be discussed. Anchoring documentation where the development happens has many advantages, from increasing the chances that it’s actually done, to being more comprehensive and accurate because it’s fresh on the mind.
There are several ways to document, but one of the more effective ones is using a prototype for this purpose too. Sample contents can be turned into documentation describing the page types and elements they’re forming, but it’s also possible to use hover-style info boxes that share background information and explain the code. (A properly maintained prototype enriched this way may even do most of the lifting of any framework site!)
Documentation begins in the code, however, and there, too, we need to exercise discipline. Our coding guidelines should underline this; documentation standards like CSSDOC and JSDOC, as well as tools that automatically pull such documentation from our code, can be of great help.
The idea behind documentation is to make life easier for ourselves, our colleagues, framework users, and any people interested in the work. Thus, making it part of the development process goes a long way.
Logistics
Our journey, now that we diligently worked through everything relevant to frameworks, is soon over. A bonus aspect concerns logistics. We have covered a few pieces that can be considered logistics:
• Coding guidelines
• Quality-control tools
• Documentation
What we haven’t touched are:
• Framework development plans or roadmaps
• Version control systems (like Git, Mercurial, or Subversion)
• Request and bug management systems (like Bugzilla)
• Framework sites (public for external frameworks) with news feeds
• Mailing lists for
• Developers (framework development team)
• Users (open to everyone interested)
• Announcements (low-volume essentials which should go to the developers and users lists, too)
• Trackers for live implementations
A framework site and an announcements list are particularly noteworthy, as they can pay good dividends to framework owners and developers. The site serves as a hub for information and documentation. An announcements list is indispensable to inform customers about new releases and guide framework users.
Support also falls into the logistics category. It does not get more attention here because, for one, we “embed” support at several landmarks along the way—in quality goals and principles, in documentation and logistics—and for another, support is more of a tangential topic that depends on the complexity and circumstances of the framework and the problems it tries to solve.
Note
To repeat, for expert framework development, we need to pay special attention to:
• Principles
• A prototype
• Quality management
• Maintenance
• Documentation
• Logistics
As these are ordered in descending order of importance, our frameworks can probably survive with poor support and gaping docs, but sacrifices in vision, testing, and commitment will break their necks.
Common Problems
Since frameworks are most useful in larger projects, problems involving frameworks tend to be bigger, too. Here are a few of the most common and gravest issues, along with ideas on how to address them.
Lack of Discipline
One of the most severe issues is lack of discipline. For the user, this most commonly means not using frameworks as intended and violating the two ground rules (following documentation and not overwriting framework code). For the developer, this usually means becoming sloppy with quality standards, the prototype, or documentation. The result is the same: sabotage, just from opposite sides of the table.
The solution is not easy to come by. Users of external frameworks are free to do what they want anyway; they may not even notice that an external framework is very difficult to ride in the first place. It’s a bit easier internally, where rules can be established, communicated, and enforced. Personally, while I have observed many issues in practice, I haven’t found a cure for this one yet. People are just very creative, and watching how frameworks end up being used is like looking right into the face of human nature (and Murphy’s Law).
Lack of a Prototype
Not having a prototype is an equally critical problem, for all the benefits outlined in Prototype. Apart from the fact that framework development is so much harder without a contained environment, maintenance complexity increases by the minute if there is no prototype. A framework without a prototype is essentially freewheeling, out of control. As suggested earlier, a mere collection of static pages—as long as it’s complete, current, and realistic—does help.
Lack of Maintenance
If we do not maintain (or stop to maintain), outside of major structural changes or prolonged resource shortages, we miss great opportunities. In the case of external frameworks, it can damage the reputation of those providing the framework. In the case of internal frameworks, it can mean giving up control over the framework-managed docs and apps, and thus slowly being forced into a costly, full-blown relaunch.
Maintenance doesn’t mean we should continuously change a framework—that may even be hurtful, especially for external frameworks because of the nuisance it creates. Rather, we should regularly monitor, test, and tweak the framework to keep it current. Such care pays off in many ways, be it because it reduces the need for more drastic changes (relaunches, which are pricey) or because everyone’s staying in touch and familiar with the framework.
Lack of Accuracy
An assumption we’ve made thus far is that what our frameworks do is accurate—that is, that they match the underlying needs and designs. That latter part can be a potential source of error if the frameworks we coded or found ourselves using don’t match the specs our designer friends sent us (if we’re not the designers ourselves). This can lead to all kinds of issues: from not being able to accommodate the original plan (no use for our external framework) to needing structural changes (ouch) to asking the designer folks to rationalize and Photoshop the differences away instead of fixing the framework. We need to watch out for design and style guide divergence.
Lack of Guts
The last big issue is to not have what it takes—even if that’s manager support—to pull the plug. Clinging on to something that’s not relevant anymore. Something that’s not used anymore. That’s used wrong. That’s a construction ruin. That can’t be maintained or extended. Something like that.
Sticking with a broken framework, a failed one, or perhaps a glorious one that has just reached the end of its lifetime can be a challenge. When that happens to us, we need to get over it. As professionals, we have big goals and we want our code to last—but sometimes we fail, and then we need to…suck it up.
Fortunately, there’s always more code to write. The next framework—or style sheet, or script—is already waiting for us.
Summary
Frameworks are deceptive. They seem easy. They look like a pretty isolated special topic. And now we’ve seen how common and complicated they are, like a not-entirely-small meteoroid that passes every single planetary object in our web development solar system. Frameworks are not trivial. If I may distract from the speed with which I typed this down, with brevity as an excuse goal, then any question still open is due to that very fact that they’re not.
But I want to recap. Professional web development is about quality. Quality is not easy to define, but one part of it is tailored code. External frameworks without customization options are impossible for users to tailor, and a pain for developers. Internal frameworks are much easier to handle and generally the way to go. Good frameworks aim for the highest quality—to be tailored, usable, and extensible. Framework users should follow the documentation and not overwrite framework code. Framework developers should have principles, a prototype, quality management tools, a maintenance plan, and healthy interest in documentation. And still, things can go wrong.
If they don’t, we may be on to the one framework. The one framework for us. Well done.
Post topics: Web Programming
Share:
|
|
# Background
Colony PCR verification, or whole colony PCR, is a now standard method to verify the modification of plasmid and/or chromosomal DNA replacing older methods such as radio-labeled hybridization. The method works by using the cellular DNA (chromosomal and/or plasmid) of selected colonies as template and using specific primers to generate PCR products to verify the presence of DNA manipulations. The selection of appropriate primers is essential for this technique to work well and to provide useful information to the investigator. The primary advantage of this technique is speed; the investigator can screen 10's to sometimes 100's of colonies quickly and with adequate precision and accuracy.
# You'll Need
• PCR tubes (0.2 mL) - Strips of 8 are nice.
• Pos/Neg control vector
• Set of primers that will give you a UNIQUE product for your DNA manipulation.
• Don't select primers that will tell you just whether your insert/new DNA is present. Use something that will tell you about its location. If you need help with this... ask someone.
• 2X Taq mastermix (Promega, Invitrogen, etc. make good ones)
• Purified water
• 1 plate for each appropriate anti-biotic you have selected with.
• Tips and your P20 pipetman (20-$\mu$L pipeter for all you non-Rainin users)
# Procedure
• Make sure you have enough tubes for at least 3 or 4 verifications per plate + 1 for each control
• Fill all the PCR tubes with 14.5-$\mu$L including your controls
• MAKE SURE YOU LABEL YOUR TUBES NOW!
• On the plate make rows/regions/number squares/whatever will keep track of your selected colonies.
|
|
# How to split bedfile into non-overlapping regions and compute aggregation function on duplicate segments
I have a bed-like file in which I have several overlapping regions with associated features. I want to split the overlapping regions into disjoint regions in order to process the file (e.g. with pandas), group by regions and compute an aggregate function.
The input data format is the following (overlapping are marked with *):
chr9 8855925 8986425 -1 *
chr9 8855965 8986325 0 *
chr9 8893857 9022105 -1
I want to split into disjoint intervals, then I want to groupby per-interval and compute an aggregation function (e.g. the mean of the last field):
chr9 8855925 8855965 -1
chr9 8855965 8893857 -0.5
chr9 8893857 8986325 -0.67
chr9 8986325 8986425 -1
chr9 8986425 9022105 -1
I was thinking of using bedtools and pandas to aggregate. However, I was unable to find the right tool to do this job in the bedtools/pybedtools documentation.
To make disjoint intervals, you could use BEDOPS bedops --partition, piping to bedmap --mean to get the mean signal over disjoint regions.
Starting with the input bedgraph file, convert it to five-column BED with GNU awk, putting the signal in the fifth column per UCSC convention:
$awk -vOFS="\t" '{ print$1, $2,$3, ".", $4 }' /tmp/in.bedgraph | sort-bed - > /tmp/in.bed$ cat in.bed
chr9 8855925 8986425 . -1
chr9 8855965 8986325 . 0
chr9 8893857 9022105 . -1
The disjoint set from these intervals would look like this:
$bedops --partition /tmp/in.bed chr9 8855925 8855965 chr9 8855965 8893857 chr9 8893857 8986325 chr9 8986325 8986425 chr9 8986425 9022105 We can pipe these intervals to bedmap --mean with the original five-column BED file as a "map" file, calculating the mean signal over the disjoint intervals: $ bedops --partition /tmp/in.bed | bedmap --echo --mean --delim '\t' - /tmp/in.bed > /tmp/answer.bedgraph
$cat /tmp/answer.bedgraph chr9 8855925 8855965 -1.000000 chr9 8855965 8893857 -0.500000 chr9 8893857 8986325 -0.666667 chr9 8986325 8986425 -1.000000 chr9 8986425 9022105 -1.000000 The --mean option calculates the arithmetic mean. Other aggregation functions are available to process the signal or score (fifth) column in map BED files, like --stdev, --median, --mad, etc. When calculating statistics, the default precision is six digits. The --prec <n> option can be used to specify desired precision in the score result. See bedmap --help or the online documentation for a full description. To avoid making and cleaning up intermediate files, bash process substitutions could be used to generate a one-liner: $ bedops --partition <(sort-bed in.bedgraph | awk -vOFS="\t" '{ print $1,$2, $3, ".",$4 }') | bedmap --echo --mean --delim '\t' - <(sort-bed in.bedgraph | awk -vOFS="\t" '{ print $1,$2, $3, ".",$4 }') > answer.bedgraph
This can be useful for cleaner pipelines or with processing very large, whole-genome scale inputs on systems with limited disk space.
• Thanks for the detailed answer. I got confused with the numbers, I should have used very simple segment start and end. Your answer has the expected solution. I'll update my question.
– gc5
May 24, 2018 at 19:35
• On macOS, use gawk instead of awk since the -v option is invalid. With homebrew brew install gawk.
– gc5
May 24, 2018 at 19:49
|
|
# Why do Czech Airlines have the airline code (IATA airline designator) “OK”?
Is there any specific reason why Czech Airlines have OK as the IATA airline designator?
According to an urban legend:
Urban legend says that when airline names were awarded -- I believe in 1946/46 -- the Czechoslovak delegation, not versed too much in English, just said OK to the questions asked. So the name stuck.
I do not much believe in the legend, but still the question remains.
I would expect that at the time when the (then) Czechoslovak Airlines were assigned the code, there were not so many airline operators as nowadays and that CS (or something similar) must have been available.
It starts with the International Telecommunications Union, which assigned radio call sign prefixes for each country in 1927. The OK prefix was assigned to Czechoslovakia. Other than the largest countries (US, USSR, UK, France, etc.) there seems to be no specific pattern to the assignments. When ICAO assigned aircraft registration prefixes for each country it usually based them on the ITU prefixes. In 1947, when ICAO assigned 2-digit airline identifiers they chose to use the country’s registration prefix for Czechoslovakia’s flag carrier. IATA originally based their airline ID’s on ICAO’s 2-letter ID’s. In 1982 ICAO changed to their current 3-letter format.
• IATA codes don't always bear much relationship to the airline name... AF for Air France and AA for American Airlines make sense. But then there is Spirit Airlines = NK, JetBlue = B6, go figure. Also, "CS" right now is Continental Micronesia... again, go figure. – Ralph J Jan 8 '18 at 21:26
• Federal Express had to accept FM initially. When FX became available they grabbed it. FM was then assigned to Lufthansa Cargo as they had a separate AOC from the passenger ops. – Anilv Jan 9 '18 at 1:16
• @Anilv I’ve always been curious who had FX before. Do you know who it was? – TomMcW Jan 9 '18 at 1:18
• Do you know how the ITU codes were assigned? – Notts90 is off to codidact.org Jan 9 '18 at 7:45
• Hi TomMcW..refer avcodes.co.uk/airlcoderes.asp the main site will give have a box to click if you want to check historical data. – Anilv Jan 10 '18 at 0:55
|
|
# Leveraging OOP
This topic is 4401 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.
## Recommended Posts
Given the following classes and inheritance that is in place, how can I assign the appropriate icons to each KIND of Robot (as you can see I am doing with the MasterRobot) without having to duplicate the same code in the constructor for each class?
public class Object
{
public Image icon;
}
public class Robot : Object
{
public string owner;
public bool is_enemy;
}
public class MasterRobot : Robot
{
public MasterRobot()
{
if(!is_enemy)
{
icon = Image.FromFile("images\\mr_friendly.bmp");
}
else
{
icon = Image.FromFile("images\\mr_enemy.bmp");
}
}
}
public class Medic : Robot
{
}
public class Engineer : Robot
{
}
public class Destroyer : Robot
{
}
public class Wall : Object
{
}
##### Share on other sites
I suggest that you create a base class constructor that receives the 'enemy' and 'friend' filenames, and pass them to this constructor from the constructor of the derived classes.
##### Share on other sites
Quote:
Original post by ToohrVykI suggest that you create a base class constructor that receives the 'enemy' and 'friend' filenames, and pass them to this constructor from the constructor of the derived classes.
Can you give me a source code example? I don't quite see how this helps.
##### Share on other sites
You will need to write at least two things: the names of the files and a short command to explain what to do with them. You will not be able to make things any shorter. My suggestion is to use:
class BaseClass { protected BaseClass( string friend, string enemy ) { if( friendly ) { /* load friend */ } else { /* load enemy */ } } public BaseClass( ) : this( "BaseFriend.tga", "BaseEnemy.jpg" ) { }}class Derived : public BaseClass { public Derived( ) : base( "DerivedFriend.tiff", "DerivedEnemy.gif" ) { }}
This reduces the amount of additional characters to be typed to :base(,) for each derived class.
##### Share on other sites
Quote:
Original post by ToohrVykYou will need to write at least two things: the names of the files and a short command to explain what to do with them. You will not be able to make things any shorter. My suggestion is to use:*** Source Snippet Removed ***This reduces the amount of additional characters to be typed to :base(,) for each derived class.
So like this?
public class Object{ public Image icon;}public class Robot : Object{ public string owner; public bool is_enemy; public Robot() { } protected Robot(string friendly_image, string enemy_image) { if(!is_enemy) { icon = Image.FromFile(friendly_image); } else { icon = Image.FromFile(enemy_image); } } }public class MasterRobot : Robot{ public MasterRobot( ) : base( "images\\mr_friendly.bmp", "images\\mr_enemy.bmp" ) { }} public class Medic : Robot{ public Medic( ) : base( "images\\med_friendly.bmp", "images\\med_enemy.bmp" ) { }}public class Engineer : Robot{ public Engineer( ) : base( "images\\eng_friendly.bmp", "images\\eng_enemy.bmp" ) { } }public class Destroyer : Robot{ public Destroyer( ) : base( "images\\dest_friendly.bmp", "images\\dest_enemy.bmp" ) { }}public class Wall : Object{ public Wall() { icon = Image.FromFile("images\\wall.bmp"); }}
Yes.
##### Share on other sites
class Robot:public Object { *insert base robot code here*public: Rect rect;};class ImageView: public View { Image image; Object& object;public: ImageView(std::string filename, Object& object_):image(filename), object(object_) {} void render(Surface& screen) { screen.draw(image, object.rect); }};...Robot* robots = {new MasterRobot(), new Medic()};ImageView robot_views = {ImageView("master_robot.png"), ImageView("medic.png")};
##### Share on other sites
bytecoder: the OP wants to specify the graphics per-class, not per-instance. (and is using C#, not C++)
##### Share on other sites
Quote:
Original post by ToohrVykbytecoder: the OP wants to specify the graphics per-class, not per-instance. (and is using C#, not C++)
Correct on both counts. I think I have my answer now....I tested and it seems to be working just fine.
//Instead of doing this:public class Destroyer : Robot{ public Destroyer( ) : base( "images\\dest_friendly.bmp", "images\\dest_enemy.bmp" ) { }}//Can I somehow do THIS:public class Destroyer : Robot{ public Destroyer( ) : base( iType.DestroyerFriendly, iType.DestroyerEnemy) { }}iType.DestroyerFriendly = "images\\dest_friendly.bmp"iType.DestroyerEnemy = "images\\dest_enemy.bmp"
What is a nice way to do this...make things a little cleaner?
##### Share on other sites
Quote:
Original post by ToohrVykbytecoder: the OP wants to specify the graphics per-class, not per-instance. (and is using C#, not C++)
That's what mine does (it's actually even more flexible). Look into Model-View-Controllers.
##### Share on other sites
OP: yes, you can, and it's even quite recommended. You could also use a static hashtable member of Robot to store the strings (indexed by derived class type) and query that table upon creation of a Robot.
bytecoder: in that case I'm afraid I didn't understand your code. Would the following code work as is? And if yes, please explain how the constructor for Medic( ) becomes aware of the name of the file from which to load the graphic.
Robot medic = new Medic( );assert( medic.icon == Image.FromFile( "medic.png" ) );
##### Share on other sites
Quote:
Original post by ToohrVykOP: yes, you can, and it's even quite recommended. You could also use a static hashtable member of Robot to store the strings (indexed by derived class type) and query that table upon creation of a Robot. bytecoder: in that case I'm afraid I didn't understand your code. Would the following code work as is? And if yes, please explain how the constructor for Medic( ) becomes aware of the name of the file from which to load the graphic.*** Source Snippet Removed ***
No, it wouldn't. The Robot class (the model) has absolutely no knowledge of anything other than abstract robot tasks. The ImageView class is what does the rendering based on 1) the robot's position and 2) the image you gave it. To get input from the user or ai, you would have a RobotController class that controls the robot. If you did for some reason want to create more work for yourself, you could create specific RobotXViews that sets the image in the constructor, but my way is shorter and more flexible.
##### Share on other sites
The topic of this thread is on ways to bind a resource (eg. a pair of filenames) to a class in a concise way, based on an existing code framework. Your proposed solution:
1. Does not bind a resource to a class in any way. You first asserted that I was wrong and that your code did perform this per-class binding. Then, you contradicted that initial statement and said that per-class binding would require the creation of an additional class for each class for which you want to perform the binding — which falls short of the request for a concise solution, as per the original post.
2. Does not use the existing code framework provided in the original post, and instead proposes a heavy reworking. Your code is also written in another language which the original poster might not understand, and which does not compile (check the number of required arguments for the ImageView constructor). It uses a basic design that is different from that of the original post: Model-View-Controller, a design with which I happen to be familiar, having used it often in the past.
As a consequence, it seems clear enough to me that your proposal is not an acceptable answer to the question and problem described in the original post of this thread. Your implying that I do not know enough to judge your post — directing me to look up the Model-View-Controller pattern — is something I would consider downright insulting if not for the irony of your contradictions in your third post.
Your initial post does offer some good insight by giving an example of Model-View-Controller, which I agree is a very good thing to use. However, you never stated that your purpose of showcasing an alternative design, which was quite different from the meaning of answering the original question that the format of your post (a blob of code with no accompannying explanations) implied. Moreover, you insisted that your post did answer the original question of the thread, which it does not as you seemed to agree later on. Why not simply begin your post with "This does not answer your question, but a better design would be: ...", maybe followed by a short argumentation of why that design is better.
You don't appear to have read the original question (or deliberately chose to ignore it), you do not answer the original question, and instead make an unsupported, unexplained post that, after thorough reading, seems to scornfully throw away the entire work of the original poster and unilaterally replace it with a half-described and crippled design that has no logical relationship whatsoever to the question, but which you appear to put forward as if it was the best thing that happened to man since the AZERTY keyboard; only to follow up by implying that I am a know-nothing idiot who does not see in which way your post helps solving a problem that it (fact) does not solve.
Your participation is not an answer to the problem, only a suggestion for a better design that is completely orthogonal to the problem, so accept that it is only that, and nothing more.
Quote:
If you did for some reason want to create more work for yourself, you could create specific RobotXViews that sets the image in the constructor, but my way is shorter and more flexible.
There are two errors in the above comment.
1. Consider the following line of code:
int main( ) { return 0; }
Neither this line nor your proposal are acceptable solutions to the problem. My proposal is shorter. Therefore, I suggest we do not create too much work for ourselves, so we keep my solution and throw yours away.
Before saying that your solution is shorter, you should begin by providing an actual solution.
2. The you could create specific RobotXViews that set the image in the constructor part of your answer has the quite ironic property of being, word for word, what the original poster wants to know how to do. Is this what you call a solution? Commenting on the general design of the code, giving a design of your own that you insist on being superior without supporting your claims, while leaving the original question unanswered?
Great, cool, you won. Your method is the best, shortest, most easily maintained and most easy to write. Here's your medal. Now, stop interfering with the actual answering of the question.
##### Share on other sites
Quote:
# Does not bind a resource to a class in any way. You first asserted that I was wrong and that your code did perform this per-class binding. Then, you contradicted that initial statement and said that per-class binding would require the creation of an additional class for each class for which you want to perform the binding — which falls short of the request for a concise solution, as per the original post.
Per-class binding can easily be done informally using per-instance binding. By creating a separate class you get strict class binding, but you also get more work and less flexibility.
Quote:
Does not use the existing code framework provided in the original post, and instead proposes a heavy reworking.
I didn't force him to use it. I merely presented the method that I would use. If it doesn't fit in with his overall design, he's free to chose a different method.
Quote:
Your code is also written in another language which the original poster might not understand, and which does not compile (check the number of required arguments for the ImageView constructor).
Didn't notice that he wasn't using C++; guess I filtered out the 'public' keywords before the classes. In any event, the code I posted was more of a demonstration than anything. It didn't have to be production quality to get the point across.
Quote:
As a consequence, it seems clear enough to me that your proposal is not an acceptable answer to the question and problem described in the original post of this thread.
That's something only the OP needs to decide. Arguing about what is "acceptable" and what isn't doesn't seem very productive, in my opinion.
Quote:
Your implying that I do not know enough to judge your post — directing me to look up the Model-View-Controller pattern — is something I would consider downright insulting if not for the irony of your contradictions in your third post.
Your direct attack on the "acceptableness" of my post is something I would consider downright insulting, if not for the irony that your post is completely unrelated to the (already solved) question at hand.
Quote:
Great, cool, you won. Your method is the best, shortest, most easily maintained and most easy to write. Here's your medal. Now, stop interfering with the actual answering of the question.
I fail to see how my solution to the problem, even if it might not be completely appropriate for the OP's situation, interferes any more than your post. If you feel that my post was completely off topic and wouldn't help the OP at all, then rate me down; that is, after all, what the rating system is for. Otherwise, I recommend you leave it to the OP to decide what is appropriate and what is not.
##### Share on other sites
This topic is 4401 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.
## Create an account
Register a new account
|
|
# How can we explain that beryllium has positive charge carriers as a metal (from Feynman Lectures)?
This question naturally arises from reading Feynman Lectures Vol III 14-3 The Hall effect, online available here, where Feynman states the following:
The original discovery of the anomalous sign of the potential difference in the Hall effect was made in a metal rather than a semiconductor. It had been assumed that in metals the conduction was always by electron; however, it was found out that for beryllium the potential difference had the wrong sign. It is now understood that in metals as well as in semiconductors it is possible, in certain circumstances, that the “objects” responsible for the conduction are holes. Although it is ultimately the electrons in the crystal which do the moving, nevertheless, the relationship of the momentum and the energy, and the response to external fields is exactly what one would expect for an electric current carried by positive particles.
I do understand how the hall effect suggests positive charge carriers, you may also compare this question and its very good answers about the behavior of holes in magnetic fields for clarification.
However, beryllium is a metal and more importantly not a semiconductor, thus (1) there is no obvious significance of the valence band and (2) the concepts of dispersion relation and effective mass are unclear to me (as this is a metal). How can one explain the Hall effect suggesting positive charge carriers in beryllium considering it is a metal?
I did search for papers and also general information about beryllium, but I was even unable to confirm the statement that beryllium shows reverse polarity in hall effect. I also did not find any other comment on the charge carriers being positive.
Edited based on a comment which may make less sense now without original context. The comment made me think that me imagining electrons in a metal as a free electron gas may be what I'm oversimplyfing here. Is thinking of the electrons in a metal as a gas under certain constraints more appropriate and necessary to explain this?
• Of course their is a valence band. Of course there are dispersion relations in metals. A closer look at the Fermi surface might answer parts of the question (I think Ashcroft and Mermin show it, but I’m socially distancing at the moment). Note a positive sign for the Hall coefficient occurs under some conditions for Al. – Jon Custer Mar 26 '20 at 18:49
• Of some interest might be journals.aps.org/pr/pdf/10.1103/PhysRev.133.A819 that shows the Be Fermi surface (and it looks nothing like a free-electron-like band structure), The connection of that structure to the Hall effect is covered in iopscience.iop.org/article/10.1088/0305-4608/5/3/008/pdf. Recall that Be is an HCP metal, and the in-plane and out-of-plane Hall coefficients are of different sign since they see very different transport paths. None of the answers below cover this in any detail. – Jon Custer Mar 27 '20 at 14:10
• Your comment that the in-plane and out-of-plane Hall coefficients are of different sign amazes me. I was unaware that this is observed behavior for any material, and I never thought about this being physically possible. This comment changes the whole picture and adds the question: why is it different for different transport paths. It seems you could expand your comment to an excellent answer going even beyond Feynmans intentions, if I may ask for this favor. – fruchti Mar 27 '20 at 14:24
Of some interest might be Loucks and Cutler, Phys Rev that shows the calculated Be Fermi surface, shown here:
Note that this looks nothing like a free-electron-like band structure that most of us kind of assume for a metal. Two things stand out: one, the Fermi surface is not a sphere, and two, there is a very large anisotropy between in-plan and out-of-plane electronic structure for the hcp Be crystal.
This connection of that structure to the Hall effect is covered in Shiozaki, J. Phys. F. The in-plane and out-of-plane Hall coefficients are of different sign since they see very different transport paths. Figure on, below, shows the parallel and perpendicular Hall coefficients measured for single crystal Be.
To quote from the abstract,
It is found that the large absolute values of R$$_{Hparallel}$$, and R$$_{Hperp}$$ are due to light electrons and light holes respectively.
In particular, looking at FIg. 3 in the paper one sees that the 'coronet' has hole conduction and the 'cigar' has electron conduction. These two very different Fermi surfaces then lead to two very different Hall behaviors.
There is also some discussion in Ashcroft and Mermin in Chapter 15 where there is a short section on "The Hexagonal Divalent Metals".
This should serve as a reminder that the very simplified pictures of 'band structure' that we keep in our heads often have little to do with the complex realities of crystals. Every once in a while it is useful to run up against things like Be (as here) or Fe (https://chemistry.stackexchange.com/a/80673/5677).
• This is a very good candidate for the proper full answer. I will check out the papers you referenced in the hopes of better understanding why the fermi surface looks like this - as far as I can tell the only missing link for a full explanation. However, I may need a couple of days to digest and process all this, as I'm clearly not an expert in this field. – fruchti Mar 27 '20 at 14:36
• @fruchti - I added the last bit because, for better or worse, most solid state physics courses focus on the band structures closest to 'free-electron-like'. Then we keep those simple pictures in our heads, ignoring all the weirdness that is actually out there. In semiconductor physics people get bitten bad when they go to heterostructures or band-gap engineered structures for similar reasons - reality is more complex than our introductory mental models. – Jon Custer Mar 27 '20 at 14:40
The difference between a metal and a semiconductor is that a metal has its upper energy band partially filled with electrons, whereas in a semiconductor we distinguish the valence band, filled to the top, and the conduction band, that is empty (at zero temperature). The partially filled band in a metal is usually called conduction band, however, the analogy with the conduction band of a semiconductor is correct only, if less than a half of this band is filled. On the other hand, if more than a half of this band is filled, the electrons will be moving in the part of the band with the negative curvature, i.e. their behavior will be more like that of the holes in the valence band of a semiconductor. I don't know whether this is the case for Berillium, but I believe that the answer by @Agnius Vasiliauskas is making this point.
Note on the band energy
For free electrons the energy is given by $$\epsilon(k) = \frac{\hbar^2k^2}{2m},$$ but for band electrons it is not the case, since the band energy is bounded from the bottom and from the top. A good way to visualize it is the one-dimensional tight-binding model, where $$\epsilon(k) = -\Delta\cos(ka),$$ where $$2\Delta$$ is the band width and $$a$$ is the lattice constant. When the concentration of the electrons is low, we are justified in expanding this energy near its minimim, $$k=0$$: $$\epsilon(k)\approx -\Delta + \frac{\Delta k^2 a^2}{2}.$$ We then can define the effective mass $$m^* = \hbar^2/(\Delta a^2)$$ (effective mass apprroximation) and treat the electrons, as if they were a free electron gas.
However, if the band is almost filled, we are more justified in expanding the band energy near its top point, $$k = \pi + q/a$$, with the result $$\epsilon(k)\approx \Delta - \frac{\Delta q^2a^2}{2}.$$ In this case one talks about negative effective mass, which leads to the whole-like behavior of the conductance properties.
Another way to look at it is by noting that the electron velocity that enters the expression for the current is defined as the group velocity of the probability waves: $$v(k) = \frac{1}{\hbar}\frac{d \epsilon(k)}{d k},$$ which gives us familiar momentum over mass for free electrons $$v(k)= \hbar k/m$$, but looks quite different for electrons in the band, where it can take negative values (i.e. exhibit hole-like behavior): $$v(k) = \Delta a\sin(ka)/\hbar$$.
• Would you mind elaborating on why the band in a metal is curved in the first place? It seems to me there are two ways of describing it: via electron gas as described by @Agnius Vasiliauskas and via band structure, and I don't see how they overlap – fruchti Mar 27 '20 at 13:49
• @fruchti I have added more material. It is really too brief for an introduction to the band theory, but I hope it will help. – Vadim Mar 27 '20 at 14:12
As positive charge carriers can be holes and ions. If you take a look at first ionization energies of metals :
You will see that smallest first ionization energy $$\leq 5 \,\text{eV}$$ has Alkali metal group:
lithium (Li), sodium (Na), potassium (K),rubidium (Rb), caesium (Cs), francium (Fr).
Alkaline earth metal group has first ionization energies between $$(10\,\text{eV} \geq E_{\text{ionization}} \geq 5\,\text{eV})$$. To this group belongs :
beryllium (Be), magnesium (Mg), calcium (Ca), strontium (Sr), barium (Ba), radium (Ra).
Low ionization thresholds in Alkali and Alkaline metals can be seen as a good support for greater concentration of free electrons in such metals and this implies of greater concentration of positive charges - holes & ions in them too, because when atom is ionized - loosely coupled electron is removed from it and becomes a free electron, thus atom becomes positively charged ion, or in other terms - in a place where electron was before, now is a hole, $$𝑒^+_Ø$$ charge.
EDIT
As about why in this case positive charges are the main charge carrier,- I don't know the exact cause, but my physical intuition tells this. According to kinetic theory of gasses, mean free path of particle is defined as : $$\ell ={\frac {k_{\text{B}}T}{{\sqrt {2}}\pi d^{2}p}}$$ For $$\pi d^{2}$$ you can take effective cross-section area of free electron-atom collision. And because free electrons forms a Fermi gas, for pressure you can take electron degeneracy pressure, which is : $$p={\frac {(3\pi ^{2})^{2/3} \,n^{5/3}\, \hbar^{2}}{5m}}$$
where $$n$$ is free electron number density.
So when number density increases (as it does, in these easy-ionizable materials), then degenerate electron gas pressure increases too. As fermi gas pressure increases, then mean free path of electron - decreases, meaning that for greater electron concentrations is far harder to move for them freely. Thus, because holes are bound to an atom and are not a subject for atom scattering effects - they react to Hall effect more uniformly. That's my 2 cents guess.
• Can you go into more detail about how a greater concentration of free electrons leads to a greater concentration of holes and ions? Also, if we have plenty of both, why do the holes transport the charges, not the electrons? – fruchti Mar 27 '20 at 7:46
• I've modified my answer. – Agnius Vasiliauskas Mar 27 '20 at 10:38
• If I am understand well your arguments, you would predict a positive Hall coefficient for the alkhali metals? But this is not what is observed. Also I am astonished to read that holes are bound to an atom. Could you please explain more in details what you have in mind? – AccidentalBismuthTransform Mar 27 '20 at 14:10
• I mean holes are not like free electrons. Free electrons are not bound to some atom, but holes are, they can move between atoms, but they can't leave any atom, because by definition hole lives in a place where electron was binded to an atom. – Agnius Vasiliauskas Mar 27 '20 at 15:34
• Then I think this is wrong. What about my first comment, does your answer implies a positive Hall coefficient for alkhali metals? – AccidentalBismuthTransform Mar 27 '20 at 16:22
Ziman offers the solution in "Electrons in Metals: A short guide to the Fermi Surface", in part III.
The short answer is "because of the interaction between the electrons and the lattice."
This implies the free electron model (leading to a spherical Fermi surface) is not able to explain this behavior.
The slightly more involved answer could be: If there was no interaction between free electrons and the lattice, the Fermi surface (determined by $$E(\vec k)$$) would be a perfect sphere and the velocity of the electrons that contribute to conduction would be parallel to the (crystal) momentum $$\vec k$$ and it is always normal to the Fermi surface. However the presence of the lattice modifies the shape of the Fermi surface (distorts it) so that the velocity of the (quasi)electrons, $$\vec v (\vec k)=\frac{1}{\hbar}\nabla_\vec k E(\vec k)$$, can be seriously altered due to the interaction between the electrons and the lattice, which makes them having a velocity not parallel to the crystal momentum, yet still perpendicular to the Fermi surface.
Now when an electric field is applied perpendicularly to a magnetic field (Hall effect), the electrons are going to be under a Lorentz force. Combining the Lorentz force with the velocity formula written above, one arrives at the conclusion that it is as if some of the electrons had a negative effective mass. These can be thought of as "holes".
This argument can be used to explain why Be, Zn, Cd, Sn and Pb display positive Hall coefficients despite being "metals".
|
|
# Eureka!
An incandescent light bulb in a room with an air temperature of $$300~\mbox{K}$$ radiates with a peak wavelength of $$10^{-6}~\mbox{m}$$. The bulb draws $$0.5~\mbox{Amperes}$$ from the $$120~\mbox{Volt}$$ wall electrical outlet. What is the surface area of the filament in the bulb in $$\mbox{m}^2$$?
Assumption
The filament may be modeled as a perfect "black body".
×
|
|
# Locally inner automorphism
## Contents
BEWARE! This term is nonstandard and is being used locally within the wiki. [SHOW MORE]
This article defines an automorphism property, viz a property of group automorphisms. Hence, it also defines a function property (property of functions from a group to itself)
View other automorphism properties OR View other function properties
## Definition
QUICK PHRASES: inner on finite tuples, inner on finitely generated subgroups
### Definition with symbols
An automorphism $\sigma$ of a group $G$ is termed a locally inner automorphism if, for any elements $x_1,x_2,\dots,x_n \in G$, there exists $g \in G$ such that $gx_ig^{-1} = \sigma(x_i)$ for $1 \le i \le n$.
## Relation with other properties
### Stronger properties
Property Meaning Proof of implication Proof of strictness (reverse implication failure) Intermediate notions
Inner automorphism
### Weaker properties
Property Meaning Proof of implication Proof of strictness (reverse implication failure) Intermediate notions
Class-preserving automorphism sends every element to within its conjugacy class locally inner implies class-preserving class-preserving not implies locally inner |FULL LIST, MORE INFO
Center-fixing automorphism fixes every element of the center (via class-preserving) (via class-preserving) Class-preserving automorphism|FULL LIST, MORE INFO
IA-automorphism induces identity map on the abelianization (via class-preserving) (via class-preserving) Automorphism that preserves conjugacy classes for a generating set, Class-preserving automorphism|FULL LIST, MORE INFO
Normal automorphism sends every normal subgroup to itself Class-preserving automorphism|FULL LIST, MORE INFO
Weakly normal automorphism sends every normal subgroup to a subgroup of itself Class-preserving automorphism|FULL LIST, MORE INFO
|
|
# Math Help - help with derivative
1. ## help with derivative
can someone help me please to find the derivative of the next equation :
f(x) = (1/x)*sin(x^(1/3))
f '(x) = ?
thnx
2. Originally Posted by tukilala
can someone help me please to find the derivative of the next equation :
f(x) = (1/x)*sin(x^(1/3))
f '(x) = ?
thnx
$f(x) = \frac{sin(x^{\frac{1}{3}})}{x}$
Use the quotient rule and bear in mind you'll need to use the chain rule on the numerator
Quotient Rule $\frac{dy}{dx} = \frac{v \frac{du}{dx} - u \frac{dv}{dx}}{v^2}$
Chain Rule: $\frac{d}{dx}f[g(x)] = f'[g(x)] \times g'(x)$
|
|
## Found 50 Documents (Results 1–50)
### Minicrypt primitives with algebraic structure and applications.(English)Zbl 07638790
MSC: 94A60 94A62
Full Text:
### MPC-friendly symmetric cryptography from alternating moduli: candidates, protocols, and applications.(English)Zbl 1489.94095
Malkin, Tal (ed.) et al., Advances in cryptology – CRYPTO 2021. 41st annual international cryptology conference, CRYPTO 2021, virtual event, August 16–20, 2021. Proceedings. Part IV. Cham: Springer. Lect. Notes Comput. Sci. 12828, 517-547 (2021).
MSC: 94A60 94A62
Full Text:
### Collusion resistant watermarkable PRFs from standard assumptions.(English)Zbl 07614552
Micciancio, Daniele (ed.) et al., Advances in cryptology – CRYPTO 2020. 40th annual international cryptology conference, CRYPTO 2020, Santa Barbara, CA, USA, August 17–21, 2020. Proceedings. Part I. Cham: Springer. Lect. Notes Comput. Sci. 12170, 590-620 (2020).
MSC: 94A60 94A62
Full Text:
### Statistical ZAP arguments.(English)Zbl 1479.94120
Canteaut, Anne (ed.) et al., Advances in cryptology – EUROCRYPT 2020. 39th annual international conference on the theory and applications of cryptographic techniques, Zagreb, Croatia, May 10–14, 2020. Proceedings. Part III. Cham: Springer. Lect. Notes Comput. Sci. 12107, 642-667 (2020).
MSC: 94A60
Full Text:
### Friet: an authenticated encryption scheme with built-in fault detection.(English)Zbl 1479.94343
Canteaut, Anne (ed.) et al., Advances in cryptology – EUROCRYPT 2020. 39th annual international conference on the theory and applications of cryptographic techniques, Zagreb, Croatia, May 10–14, 2020. Proceedings. Part I. Cham: Springer. Lect. Notes Comput. Sci. 12105, 581-611 (2020).
MSC: 94A62 94A60
Full Text:
Full Text:
### Estimating the cost of generic quantum pre-image attacks on SHA-2 and SHA-3.(English)Zbl 1418.94028
Avanzi, Roberto (ed.) et al., Selected areas in cryptography – SAC 2016. 23rd international conference, St. John’s, NL, Canada, August 10–12, 2016. Revised selected papers. Cham: Springer. Lect. Notes Comput. Sci. 10532, 317-337 (2017).
MSC: 94A60 81P94
Full Text:
Full Text:
### Design of crypto primitives based on quasigroups.(English)Zbl 1397.94088
MSC: 94A60 20N05 68P25
### On the homomorphic computation of symmetric cryptographic primitives.(English)Zbl 1317.94124
Stam, Martijn (ed.), Cryptography and coding. 14th IMA international conference, IMACC 2013, Oxford, UK, December 17–19, 2013. Proceedings. Berlin: Springer (ISBN 978-3-642-45238-3/pbk). Lecture Notes in Computer Science 8308, 28-44 (2013).
MSC: 94A60
Full Text:
### Feebly secure cryptographic primitives.(English. Russian original)Zbl 1262.94023
J. Math. Sci., New York 188, No. 1, 17-34 (2013); translation from Zap. Nauchn. Semin. POMI 399, 32-64 (2012).
MSC: 94A60 94C10
Full Text:
### Shapeless quasigroups derived by Feistel orthomorphisms.(English)Zbl 1269.94027
MSC: 94A60 20N05 94A55
Full Text:
Full Text:
### Encoding cryptographic primitives in a calculus with polyadic synchronisation.(English)Zbl 1216.68194
MSC: 68Q85 94A60
Full Text:
### On the prop ratio tables of extended Feistel networks and their quasigroups.(English)Zbl 1342.20064
MSC: 20N05 94A60
Full Text:
### Algebraic cryptography: new constructions and their security against provable break.(English. Russian original)Zbl 1206.94069
St. Petersbg. Math. J. 20, No. 6, 937-953 (2009); translation from Algebra Anal. 20, No. 6, 119-147 (2008).
Full Text:
### Improvement of authentication test based on strand spaces model.(Chinese. English summary)Zbl 1171.68354
MSC: 68M12 68M10
Full Text:
### Communication on inductively coupled channels: overview and challenges.(English)Zbl 1166.94300
Barbero, Ángela (ed.), Coding theory and applications. Second international castle meeting, ICMCTA 2008, Castillo de La Mota, Medina del Campo, Spain, September 15–19, 2008. Proceedings. Berlin: Springer (ISBN 978-3-540-87447-8/pbk). Lecture Notes in Computer Science 5228, 186-195 (2008).
MSC: 94A05 94A60
Full Text:
### Computationally private randomizing polynomials and their applications.(English)Zbl 1143.94009
MSC: 94A60 68Q15
Full Text:
### Constructing single- and multi-output Boolean functions with maximal algebraic immunity.(English)Zbl 1133.94308
Bugliesi, Michele (ed.) et al., Automata, languages and programming. 33rd international colloquium, ICALP 2006, Venice, Italy, July 10–14, 2006. Proceedings, Part II. Berlin: Springer (ISBN 978-3-540-35907-4/pbk). Lecture Notes in Computer Science 4052, 180-191 (2006).
MSC: 94A60 06E30
Full Text:
### Cryptography in NC$$^0$$.(English)Zbl 1126.94014
MSC: 94A60 68P25 68Q15
Full Text:
### On robust combiners for private information retrieval and other primitives.(English)Zbl 1129.94030
Dwork, Cynthia (ed.), Advances in cryptology – CRYPTO 2006. 26th annual international cryptology conference, Santa Barbara, California, USA, August 20–24, 2006. Proceedings. Berlin: Springer (ISBN 3-540-37432-9/pbk). Lecture Notes in Computer Science 4117, 555-569 (2006).
MSC: 94A60 68P20
Full Text:
MSC: 94A60
### The impossibility of basing one-way permutations on central cryptographic primitives.(English)Zbl 1096.94024
MSC: 94A60 68P25
Full Text:
### General principles of algebraic attacks and new design criteria for cipher components.(English)Zbl 1117.94315
Dobbertin, Hans (ed.) et al., Advanced encryption standard – AES. 4th international conference, AES 2004, Bonn, Germany, May 10–12, 2004. Revised selected and invited papers. Berlin: Springer (ISBN 3-540-26557-0/pbk). Lecture Notes in Computer Science 3373, 67-83 (2005).
MSC: 94A60
Full Text:
### Quantum lower bounds for the collision and the element distinctness problems.(English)Zbl 1169.68406
MSC: 68Q05 68Q17 68Q25 81P68
Full Text:
### Efficient forward and provably secure ID-based signcryption scheme with public verifiability and public ciphertext authenticity.(English)Zbl 1092.94505
Lim, Jong In (ed.) et al., Information security and cryptology – ICISC 2003. 6th international conference, Seoul, Korea, November 27–28, 2003. Revised papers. Berlin: Springer (ISBN 3-540-21376-7/pbk). Lecture Notes in Computer Science 2971, 352-369 (2004).
MSC: 94A60
Full Text:
### Threshold MACs.(English)Zbl 1031.94522
Lee, Pil Joong (ed.) et al., Information security and cryptology - ICISC 2002. 5th international conference, Seoul, Korea, November 28-29, 2002. Revised papers. Berlin: Springer. Lect. Notes Comput. Sci. 2587, 237-252 (2003).
MSC: 94A60 94A62
Full Text:
### On the universal hash functions in Luby-Rackoff cipher.(English)Zbl 1031.94518
Lee, Pil Joong (ed.) et al., Information security and cryptology - ICISC 2002. 5th international conference, Seoul, Korea, November 28-29, 2002. Revised papers. Berlin: Springer. Lect. Notes Comput. Sci. 2587, 226-236 (2003).
MSC: 94A60 68P25
Full Text:
### On the efficiency of the clock control guessing attack.(English)Zbl 1031.94531
Lee, Pil Joong (ed.) et al., Information security and cryptology - ICISC 2002. 5th international conference, Seoul, Korea, November 28-29, 2002. Revised papers. Berlin: Springer. Lect. Notes Comput. Sci. 2587, 200-212 (2003).
MSC: 94A60 94A55
Full Text:
### How to play Sherlock Holmes in the world of mobile agents.(English)Zbl 1024.94516
Batten, Lynn (ed.) et al., Information security and privacy. 7th Australasian conference, ACISP 2002, Melbourne, Australia, July 3-5, 2002. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2384, 449-463 (2002).
MSC: 94A62 68U35
Full Text:
### On the impossibilities of basing one-way permutations on central cryptographic primitives.(English)Zbl 1065.94542
Zheng, Yuliang (ed.), Advances in cryptology - ASIACRYPT 2002. 8th international conference on the theory and application of cryptology and information security, Queenstown, New Zealand, December 1–5, 2002. Proceedings. Berlin: Springer (ISBN 3-540-00171-9). Lect. Notes Comput. Sci. 2501, 110-124 (2002).
MSC: 94A60 65C10 68P25
Full Text:
### Blockwise-adaptive attackers. Revisiting the (in)security of some provably secure encryption modes: CBC, GEM, IACBC.(English)Zbl 1026.94531
Yung, Moti (ed.), Advances in cryptology - CRYPTO 2002. 22nd annual international cryptology conference, Santa Barbara, CA, USA, August 18-22, 2002. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2442, 17-30 (2002).
MSC: 94A60 68P25
Full Text:
### Minimal complete primitives for secure multi-party computation.(English)Zbl 1015.94541
Kilian, Joe (ed.), Advances in cryptology - CRYPTO 2001. 21st annual international cryptology conference, Santa Barbara, CA, USA, August 19-23, 2001. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2139, 80-100 (2001).
MSC: 94A60
### Distinguishing TEA from a random permutation: reduced round versions of TEA do not have the SAC or do not generate random numbers.(English)Zbl 1002.68810
Honary, Bahram (ed.), Cryptography and coding. 8th IMA international conference, Cirencester, GB, December 17-19, 2001. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2260, 374-377 (2001).
MSC: 94A60
Full Text:
### Generalized oblivious transfer protocols based on noisy channels.(English)Zbl 0995.94543
Gorodetski, V. I. (ed.) et al., Information assurance in computer networks. Methods, models and architectures for network security. International workshop MMM-ACNS 2001, St. Petersburg, Russia, May 21-23, 2001. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2052, 219-229 (2001).
MSC: 94A60
Full Text:
### A survey on IQ cryptography.(English)Zbl 0983.94034
Alster, Kazimierz (ed.) et al., Public-key cryptography and computational number theory. Proceedings of the international conference organized by the Stefan Banach International Mathematical Center, Warsaw, Poland, September 11-15, 2000. Berlin: de Gruyter. 1-15 (2001).
MSC: 94A60 11R04 11R29
### Analysis of SHA-1 in encryption mode.(English)Zbl 0995.94541
Naccache, David (ed.), Topics in cryptology - CT-RSA 2001. The cryptographer’s track at RSA conference 2001, San Francisco, CA, USA, April 8-12, 2001. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 2020, 70-83 (2001).
MSC: 94A60 68P25
MSC: 94A60
Full Text:
### Spectral bounds on general hard core predicates. (Extended abstract).(English)Zbl 0991.94036
Reichel, Horst (ed.) et al., STACS 2000. 17th annual symposium on Theoretical aspects of computer science. Lille, France, February 17-19, 2000. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 1770, 614-625 (2000).
MSC: 94A60 06E30 94C10
### A top-down look at a secure message.(English)Zbl 0983.94511
Pandu Rangan, C. (ed.) et al., Foundations of software technology and theoretical computer science. 19th conference, Chennai, India, December 13-15, 1999. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 1738, 122-141 (1999).
MSC: 94A60 68P25
### Recent developments in the design of conventional cryptographic algorithms.(English)Zbl 0955.94016
Preneel, Bart (ed.) et al., State of the art in applied cryptography. Course on computer security and industrial cryptography, Leuven, Belgium, June 3-6, 1997. Revised lectures. Berlin: Springer. Lect. Notes Comput. Sci. 1528, 105-130 (1998).
MSC: 94A60 68P25
### Cryptographic primitives for information authentication – State of the art.(English)Zbl 0954.94018
Preneel, Bart (ed.) et al., State of the art in applied cryptography. Course on computer security and industrial cryptography, Leuven, Belgium, June 3-6, 1997. Revised lectures. Berlin: Springer. Lect. Notes Comput. Sci. 1528, 49-104 (1998).
MSC: 94A62 94-02 94A60
### Highly nonlinear balanced Boolean functions with a good correlation-immunity.(English)Zbl 0919.94014
Nyberg, Kaisa (ed.), Advances in Cryptology. International conference on the Theory and application of cryptographic techniques. Espoo, Finland, May 31 - June 4, 1998. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 1403, 475-488 (1998).
MSC: 94A60 06E30
MSC: 94A60
Full Text:
### Correlated pseudorandomness and the complexity of private computations.(English)Zbl 0917.94012
Proceedings of the 28th annual ACM symposium on the theory of computing (STOC). Philadelphia, PA, USA, May 22–24, 1996. New York, NY: ACM, 479-488 (1996).
MSC: 94A60 68Q25 68P25
### On the need for multipermutations: cryptanalysis of MD4 and SAFER.(English)Zbl 0939.94542
Preneel, Bart (ed.), Fast software encryption. 2nd international workshop, Leuven, Belgium, December 14-16, 1994. Proceedings. Berlin: Springer-Verlag. Lect. Notes Comput. Sci. 1008, 286-297 (1995).
MSC: 94A60 05A05
Full Text:
### Incremental cryptography: The case of hashing and signing.(English)Zbl 0939.94530
Desmedt, Yvo G. (ed.), Advances in cryptology - CRYPTO ’94. 14th annual international cryptology conference, Santa Barbara, CA, USA, August 21-25, 1994. Proceedings. Berlin: Springer. Lect. Notes Comput. Sci. 839, 216-233 (1994).
MSC: 94A60
### Necessary and sufficient conditions for collision-free hashing.(English)Zbl 0817.94014
Brickell, Ernest F. (ed.), Advances in cryptology - CRYPTO ’92. 12th annual international cryptology conference, Santa Barbara, CA, USA, August 16-20, 1992. Proceedings. Berlin: Springer-Verlag. Lect. Notes Comput. Sci. 740, 433-441 (1993).
MSC: 94A60
### Duality between two cryptographic primitives.(English)Zbl 0729.94014
Applied algebra, algebraic algorithms and error-correcting codes, Proc. 8th Int. Conf., AAECC-8, Tokyo/Jap. 1990, Lect. Notes Comput. Sci. 508, 379-390 (1991).
MSC: 94A60
all top 5
all top 5
all top 3
all top 3
|
|
Assigned To
None
Authored By
Theklan Nov 20 2018, 6:46 PM2018-11-20 18:46:49 (UTC+0)
Referenced Files
F31320183: Screen Shot 2019-11-27 at 3.55.25 PM.png Nov 27 2019, 9:57 PM2019-11-27 21:57:24 (UTC+0)
# Description
Hello!
In the Basque project Txikipedia we use the font-face "Gochi Hand" for making things more interesting to kids. This font is loaded in MediaWiki:Gadget-TxikipediaTab.css to import it from toolforge, instead of from Google Fonts:
Previous code
@import url('https://fonts.googleapis.com/css?family=Gochi+Hand');
Current code
@import url(https://tools-static.wmflabs.org/fontcdn/css?family=Gochi+Hand);
Currently the only way we have to put this font (that has been decided to use in Txikipedia) is using the toolforge fontcdn tool, because is the only way to have fonts without information being tracked.
If we can't have this call to a font in toolforge, we would need another way to have this typography deployed in our wiki, but I want to be sure that this is really a security breach before proceeding.
### Event Timeline
Restricted Application added a subscriber: Aklapper. Nov 20 2018, 6:46 PM
Hi @Theklan - I am not a Security member so you can disregard my opinion outright should you wish. However, as far as I know, importing external resources from domains we do not control is highly discouraged because it can result on outages or more serious things like privacy or security violations. If the font does exist within Wikimedia repositories, I'd say you should consider using those. If the font does not exist, maybe we could ask to bring it to our repos so it can be used withing the projects if there are no licensing concerns. But like I said, this is just my personal opinion. Best regards.
I think to deploy we'd need a Debian package which offers this font. (If I understand correctly.)
Thanks @MarcoAurelio! AFAIK using fontcdn is recommended exactly for this issue. And that's why we were advised to use it. I don't know if there are further problems with using the fonts there, but the project should specify that it can't be used inside Wikimedia if this is a real problem.
the project should specify that it can't be used inside Wikimedia if this is a real problem.
What is "the project" and what is "it"?
wmflabs.org and eu.wikipedia.org are both Wikimedia controlled. I don't see a "privacy break" here because no third party is involved.
If I misunderstand what this task is about, please elaborate and explain more what the potential problem is. Thanks!
Krenair assigned this task to Legoktm.
@Aklapper: wmflabs.org may be Wikimedia-owned but that's not enough to enable inclusion in wikimedia production JS. Indeed most wmflabs.org stuff would be unacceptable, though tools-static.wmflabs.org/fontcdn appears to be controlled by @zhuyifei1999 who is also in the admin tool, so I think they have an NDA. @Legoktm is there anything I'm missing here since you asserted non-NDA users have access?
Ah, thanks for clarifying! In that case these might also be checked?:
https://ar.wikipedia.org/wiki/MediaWiki:Common.js: mw.loader.load( '//tools.wmflabs.org/imagemapedit/ime.js' );
https://he.wikipedia.org/wiki/MediaWiki:Common.js: mw.loader.load( '//tools.wmflabs.org/imagemapedit/ime.js' );
Honestly, since when UA by itself is private information? If that were the case, the vast majority of toolforge tools would violate cloud ToU in this clause:
You should not collect or store private data or personally identifiable information [...] (“Private Information”) from the individuals using your Cloud Services Project (“End Users”), except when complying with the conditions listed below.
1. Clearly communicate to End Users a) that Private Information is being collected, b) how you will use it, and c) when you will delete it;
2. Inform the End Users that their information may be available to the Wikimedia Foundation, its volunteers, other Wikimedia Cloud Services users, or to the public;
3. Get express authorization from the End Users for the collection;
4. Hash, encrypt, or otherwise properly secure any Private Information you store;
5. Purge, anonymize, or aggregate any Private Information you store no more than 30 days after storing it;
(The sad thing is, the policy was never clarified T140486)
Regarding the technical side, tools-static.wmflabs.org/fontcdn routes directly to the static proxy (config added in T110027), with current config acting as a reverse proxy to google. UA is not removed in the process since we did not see it as a concern of privacy, and it is used by google to dynamically determine what font types a browser supports.
Honestly, since when UA by itself is private information?
To clarify this, my understanding is that the association of UA and other information, such as referrer, usernames, IPs, should be private. Without that, UA is essentially anonymous statistics.
The Wikimedia Privacy Policy explicitly says that user-agents are "personal information" (see https://meta.wikimedia.org/wiki/Privacy_policy#Definitions). Whether it truly is private information is out of scope - we have to follow the privacy policy here.
Toolforge maintainers have access to the UA, so while for now if @zhuyifei1999 remains the sole maintainer (or only NDA maintainers are added) it might be permissible, but sending it onto Google would make it definitely not. I would expect that Toolforge will be blocked using CSP in the future, so this isn't a sustainable solution in any case.
So, to respond to the original question on how to resolve the issue of needing a web font - first, we should see if the font is suitable for inclusion in UniversalLanguageSelector. If not, we can figure out an alternative way to deploy it, maybe something like the MontserratFont extension.
@zhuyifei1999 remains the sole maintainer (or only NDA maintainers are added) it might be permissible
The reverse proxy (tools-static) is only accessible to toolforge maintainers.
thanks @Legoktm, putting the assignee back
This comment was removed by sbassett.
JFishback_WMF moved this task from Intake to Backlog on the Privacy board.
Loading fonts from the Toolforge Font CDN is a violation of the Wikimedia privacy policy as it exposes users' User-Agent to Google. If a steward explicitly removed the font, you should not be reinstating it without discussing it with them.
That's why I'm not reinstating it, I'm trying to discuss it and find a solution, because that typeface is part of the project's visual identity.
Hello, removing steward speaking. I have removed the import statement, because it causes users to download the font from Toolforge, a place which is not covered by Wikimedia Privacy. As such, users have to be informed that if they do load this file, their PII may be forwarded to third parties (in this case, Toolforge, which forwards user agent, which is considered PII by Wikimedia Privacy policy, to Google).
If the font is freely licensed, it might get approved and installed at Wikimedia sites, at which point you would be able to use with no further issues. If it is not freely licensed, I'm afraid you would need to change your identity.
I believe this makes sense. Feel free to ask any questions here.
Best,
Martin Urbanec
Nintendofan885 renamed this task from Possible privacy break when loading font from toolserver (https://tools-static.wmflabs.org/fontcdn/) to Possible privacy break when loading font from toolforge (https://tools-static.wmflabs.org/fontcdn/).Oct 30 2020, 11:02 PM
Nintendofan885 updated the task description. (Show Details)
Assuming this can be closed nowadays
Aklapper renamed this task from Possible privacy break when loading font from toolforge (https://tools-static.wmflabs.org/fontcdn/) to Privacy break on eu.wikipedia.org loading font from toolforge (https://tools-static.wmflabs.org/fontcdn/).Jul 23 2022, 9:01 AM
|
|
Suggested languages for you:
Americas
Europe
Q13E
Expert-verified
Found in: Page 224
### Modern Physics
Book edition 2nd Edition
Author(s) Randy Harris
Pages 633 pages
ISBN 9780805303087
# Show that ${\mathbit{\psi }}\left(x\right){\mathbf{=}}{\mathbit{A}}{\mathbf{\text{'}}}{{\mathbit{e}}}^{\mathbf{i}\mathbf{k}\mathbf{x}}{\mathbf{+}}{\mathbit{B}}{\mathbf{\text{'}}}{{\mathbit{e}}}^{\mathbf{-}\mathbf{i}\mathbf{k}\mathbf{x}}$ is equivalent to ${\mathbit{\psi }}{\mathbf{\left(}}{\mathbit{x}}{\mathbf{\right)}}{\mathbf{=}}{\mathbit{A}}{\mathbit{s}}{\mathbit{i}}{\mathbit{n}}{\mathbit{k}}{\mathbit{x}}{\mathbf{+}}{\mathbit{B}}{\mathbit{c}}{\mathbit{o}}{\mathbit{s}}{\mathbit{k}}{\mathbit{x}}$, provided that ${\mathbit{A}}{\mathbf{\text{'}}}{\mathbf{=}}\frac{\mathbf{1}}{\mathbf{2}}\left(B-iA\right)$ ${\mathbit{B}}{\mathbf{\text{'}}}{\mathbf{=}}\frac{\mathbf{1}}{\mathbf{2}}\left(B+iA\right)$.
Hence, the proof for the equation is obtained.
See the step by step solution
## Step 1: Concept involved
According to the Euler’s formula in complex numbers, it can be written that:
${{\mathbit{e}}}^{\mathbf{i}\mathbf{\phi }}{\mathbf{=}}{\mathbit{c}}{\mathbit{o}}{\mathbit{s}}{\mathbit{\phi }}{\mathbf{+}}{\mathbit{i}}{\mathbit{s}}{\mathbit{i}}{\mathbit{n}}{\mathbit{\phi }}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{}}{\mathbf{\dots }}{\mathbf{\dots }}{\mathbf{}}{\mathbf{\left(}}{\mathbf{1}}{\mathbf{\right)}}$
## Step 2: Given/known parameters
Consider the given function:
$\psi \left(x\right)=A\text{'}{e}^{ikx}+B\text{'}{e}^{-ikx}$
Consider the equations:
$A\text{'}=\frac{1}{2}\left(B-iA\right)\dots \dots \left(2\right)$
$B\text{'}=\frac{1}{2}\left(B+iA\right)\dots \dots \left(3\right)$
## Step 3: Solution
Apply Euler’s formula from equation (1) and solve:
$\psi \left(x\right)=A\text{'}\left(\mathrm{cos}\left(kx\right)+i\mathrm{sin}\left(kx\right)\right)+B\text{'}\left(\mathrm{cos}\left(kx\right)-i\mathrm{sin}\left(kx\right)\right)$
Rewrite the above equation as,
$\psi \left(x\right)=\left(A\text{'}+B\text{'}\right)\mathrm{cos}kx+\left(A\text{'}-B\text{'}\right)\mathrm{sin}\left(kx\right)\dots ..\left(4\right)$
Now, by using equation (2) and (3) in equation (4) solve as:
$\psi \left(x\right)=\left(\frac{1}{2}\left[B-iA\right]+\frac{1}{2}\left[B+iA\right]\right)\mathrm{cos}\left(kx\right)-\left(\frac{1}{2}\left[B-iA\right]-\frac{1}{2}\left[B+iA\right]\right)\mathrm{sin}\left(kx\right)\phantom{\rule{0ex}{0ex}}\psi \left(x\right)=B\mathrm{cos}\left(kx\right)+A\mathrm{sin}\left(kx\right)$
Thus, you can say that: $\psi \left(x\right)=A\text{'}{e}^{ikx}+B\text{'}{e}^{-ikx}$ is equivalent to
$\psi \left(x\right)=B\mathrm{cos}\left(kx\right)+A\mathrm{sin}\left(kx\right)$ provided that $A\text{'}=\frac{1}{2}\left(B-iA\right)$ and $B\text{'}=\frac{1}{2}\left(B+iA\right)$
|
|
# Why is enabling GL_FRAMEBUFFER_SRGB making the colours brighter?
My understanding of gamma correction is as follows: We want to do colour math in linear space so we can lerp etc. between colour values and get the results we expect. But human eyes don't have a linear response to light, so we need to modify the colours just before displaying them. sRGB is then commonly used colour space for this. Furthermore, since paint programs and colour pickers talk about colour in sRGB, the colours typically need to be linearized before math is performed on them.
EDIT 2: Turns out I had the following conversions backwards. The rest of the question is left unchanged for context, but I don't want to lead someone else down the same incorrect path.
The actual curve mapping sRGB to linear space is an exponential curve over the range 0 to 1. Linear to sRGB is raising the colour to the power of 2.2. sRGB to linear is taking the 2.2th root of the colour. So since we are in the range 0 to 1 Linear to sRGB make the colours less bright, and sRGB to linear does the opposite.
In my program I'm pulling values out of an GL_R8 texture, interpreting them as alpha values and taking a vec4 as a vertex attribute we'll call colour and multiplying it by vec4(1.0, 1.0, 1.0, alpha) to produce the final colour in the fragment shader. If I set the colour attribute to a known colour and enable the GL_FRAMEBUFFER_SRGB flag, then the colour I get is too bright, and it is exactly as bright as it would be if the sRGB to linear conversion was not applied.
For example if I pass in the colour #222222 I get #666666 actually rendered to the screen according to an external colour picking tool. If I convert the colour #222222 to three floats by dividing by 255.0 I get three copies of 0.13333333. 0x22 = 34 in base 10, 34.0 / 255.0 = 0.13333333. The 2.2th root of 0.13333333 is 0.40017032. 0.40017032 * 255.0 gives us 102. 102 in hex is the 0x66 we were expecting.
At first I thought that the problem was that it wasn't applying the linear to sRGB conversion to the output of the shader for some reason, since things were too bright. So I did some searching and found this answer but that states that the only way that the linear to sRGB conversion will only be applied if GL_FRAMEBUFFER_SRGB is enabled. I'm getting the opposite behavior: the colours are too bright only if GL_FRAMEBUFFER_SRGB is enabled!
I then realized that openGL can't magically know what the semantics of my colour vertex attribute are. So it can't be automatically converting my colour to linear space, unless it's doing something weird and error prone like checking the name of the attribute or just converting every vec3 or vec4. If that was a desired feature, a shader keyword or something would have been a better way to do that.
So I'm confused as to how I'm getting this result. I'm not currently doing any colour math in the shader besides what I've already mentioned, besides alpha blending. But I might want to do more of that later, including loading more textures in the fragment shader so I would like to sort out this weirdness, rather than just disabling GL_FRAMEBUFFER_SRGB and leaving the same mess for myself if I do end up doing more complicated stuff later.
EDIT 1: My windowing library says that my pixel format is sRGB so I don't think that is the issue. If I run glGetFramebufferAttachmentParameteriv(GL_FRAMEBUFFER, GL_FRONT_LEFT, GL_FRAMEBUFFER_ATTACHMENT_COLOR_ENCODING, &result), result gets set to GL_SRGB. If I check GL_FRONT_RIGHT, GL_BACK_LEFT, and GL_BACK_RIGHT I get GL_LINEAR, GL_SRGB, and GL_LINEAR respectively. But according to this page since I didn't set any stereo rendering settings, then the RIGHT buffers shouldn't matter.
• Is the texture in the GL_SRGB format? – Bálint Oct 30 '19 at 13:30
• @Bálint The texture I'm reading from? That's in GL_R8 since that's what I pass as the third param to glTexImage2D. – Ryan1729 Oct 30 '19 at 21:56
• You have your mappings backwards, see here: entropymine.com/imageworsener/srgbformula. Also the "known colour" you are passing in is probably in srgb space already, so when you apply the linear to srgb mapping you get a colour that you think is too bright. – Alex Oct 30 '19 at 22:20
• @Alex Ah! Thank you. In that case I think I must be in case three in that other answer I mentioned: "The source buffer has NON-sRGB format, the destination has sRGB format. Conversion from linear to sRGB will be done if, and only if GL_FRAMEBUFFER_SRGB is enabled." Because I'm not reading colours out of a texture at all, there's no place for it to do the sRGB to Linear transformation. It makes sense now. – Ryan1729 Oct 30 '19 at 22:37
It's not the display colors that got brighter, only the textures. You need to set the internal format of them to GL_SRGB:
glTexImage2D(GL_TEXTURE_2D, 0, GL_SRGB, ...)
• Do you mean the texture I'm reading from? But I'm only using the values in there as alpha values, which AFAIK should not be ever modified due to sRGB settings. So since they won't be converted from linear to sRGB, I don't want them to be converted from sRGB to linear. Sure enough I tried it on those textures anyway and the colours were unchanged but the alpha values got smaller, making the edges of the light things I am rendering against a dark background noticeably dark. If you mean the final framebuffer, I've already enabled sRGB on the windowing library I'm using. I'll look closer at that. – Ryan1729 Oct 30 '19 at 20:02
• @Ryan1729 If you output your own colors, you need to apply the srgb conversion yourself: learnopengl.com/Advanced-Lighting/Gamma-Correction – Bálint Oct 30 '19 at 23:04
My shaders work in the linear space, and I rely on glEnable( GL_FRAMEBUFFER_SRGB ) to do the conversion.
To drive the monitor (which has a very low response for dark/low values,) OpenGL needs to increase the (dark) values in my framebuffer.
So yes, enabling GL_FRAMEBUFFER_SRGB is supposed to make your rendered image brighter.
Now, where it gets interesting is, that as far as I am aware, none of the 3D graphics fileformats properly specifies the colour space for the colour-per-vertex or colour-per-face that are in the file. So you typically assume them to be non-linear.
So, as you load an OBJ file, you should expect that the author intended the colours to be in non-linear space. Hence, before using them in your shaders, you need to convert them to linear (make them darker.)
OpenGL will then take your framebuffer output and make them lighter again (as you observed.)
I recommend the following sanity check for you:
• Just render a picture with nothing in it, other than glClear() with colour (0.05, 0.05, 0.05)
• With GL_FRAMEBUFFER_SRGB disabled, it should be nearly indistinguishable from black.
• With GL_FRAMEBUFFER_SRGB enabled, it should be grey, because 0.05 is then considered linear, and hence produce 5% of the photons that pure white does: This is plenty of light to be discernible from black.
So, yes, with a linear-colour mind-space, you need to be aware that low values in the framebuffer (or low values in your object's model) are actually a lot brighter than what you are used to in the traditional gamma-curved colour space or CRTs and LCDs.
Let me conclude by linking to Tom Forsyth's excellent article on SRGB.
|
|
# GLSL light coloring blocked surfaces
I have created a very simple lighting shader. It currently only supports point lights, but it lights up surfaces that are completely blocked from the light. I know why, but I want to know how I can fix it. I was thinking of using a form of shadow mapping to darken those areas, but shadow mapping is difficult for me to understand and has very major performance issues. I was hoping for a more elegant and efficient version, even if it is not as nice.
Until something like that exists, I need a nice, efficient way of checking to see if a fragment or vertex is visible and computing things from there. I would also like to add that I intent to support semi-transparent objects, which should block light based on and alpha value.
The things I want:
• Fast (25+ fps with the modified shaders, I currently run at 82)
• Easily modified to incorporate more lights (three or four at most, probably).
• Support for edge smoothing (user can enable it, but will lose performance)
The things I do not want:
• Pulling information from the GPU during rendering (view stuttering is always visible when that happens)
• Visible/noticeable moving of lighting when scene is stationary (like the light is moving when it really isn't, due to randomizing)
• Expensive operations when the scene first renders.
I do not expect anybody to implement these things - just to leave room and maybe a comment where these would be done. I know this is the "holy grail" of rendering when combined with bump maps and such, but if you tone down the quality a bit, I hope it is possible. I may have to do some extra work on the CPU, but that is acceptable.
Now for the shaders I currently have working:
varying vec4 color;
varying vec3 normal;
varying vec4 position;
void main (void) {
color = gl_Color; // pass color to the fragment shader
normal = normalize(gl_NormalMatrix * gl_Normal); // calculate useable normals from the basic normal data.
gl_Position = gl_ModelViewProjectionMatrix * gl_Vertex; // set position
gl_TexCoord[0] = gl_MultiTexCoord0; // set texture coordinates
position = gl_Vertex; // pass gl_Vertex to the fragment shader for light calculations.
}
varying vec4 color;
varying vec3 normal;
varying vec4 position;
uniform sampler2D texture;
uniform vec4 light; // position of the light, same coordinate system as non-transformed objects
void main (void) {
vec3 vector = light.xyz - position.xyz; // get the vector needed to determine length
float distance = sqrt((vector.x * vector.x) + (vector.y * vector.y) + (vector.z * vector.z)); // determine length
vec4 final = color; // set color
final.xyz *= (1.0 / distance); // calculate light intensity on pixel
gl_FragColor = final * texture2D(texture, gl_TexCoord[0].st); // multiply by texture color
}
I can do a lot of extra cool things with this current code, such as giving lights their own colors and giving objects their own material properties, but that is not the point now. I just want basic code, preferably without needing more buffers and shaders, to determine visibility. From my research, it sounds like the stencil and depth buffers may be of use here, and they already setup, so they may be a better way to do it.
I can not stress enough that I only need the bare essentials here - nothing overly fancy. Thanks in advance for your help.
• You want light occlusion (shadows) that uses only a single pass forward rendering algorithm using only a single vertex+fragment shader combination? Impossible, end of story. – Sean Middleditch Jan 6 '13 at 5:14
• That is not what I said. I simply said I would prefer that. I am open to doing whatever I need to. – Justin Jan 6 '13 at 14:48
• In that case,the easiest option by far is to just use shadow maps. Some good tutorials you might like are fabiensanglard.net/shadowmapping/index.php and opengl-tutorial.org/intermediate-tutorials/… – Sean Middleditch Jan 6 '13 at 19:14
• I am working on implementing this now. That second tutorial is very thorough and geared toward beginners, so it is already giving me nice results. I've also combined the multisample and shadow shaders and buffers, so performance is now barely effected! Can you add this as an answer so I can mark it? – Justin Jan 7 '13 at 15:09
Shadow mapping is the way to go. There is no way to have shadows without adding some more shaders and passes to rendering. GPU rendering works by taking a list of triangles to render, and it does not have a list of the other triangles/occluded in the scene; even if you added them in a buffer, querying them would be much slower than shadow mapping on today's GPU hardware. You aren't going to find a simpler method of shadow generation that actually works than shadow mapping.
Some good tutorials are at:
You do not use the normal at all, so nothing will tell the light calculation that the current fragment is facing away from the light. Instead of this:
final.xyz *= (1.0 / distance);
You can try this, using Lambert’s cosine law:
final.xyz *= max(0.0, dot(normalize(vector), normalize(normal))) / distance;
Also note that length(vector) will do exactly what your sqrt call does.
Edit: another problem is that vector is computed in object space, whereas normal is in view space. This page has more information. I suggest doing the light calculations in view space (as the fixed-pipeline OpenGL does), therefore multiplying position by the view matrix and providing light in view space. Instead of:
position = gl_Vertex;
You need:
position = gl_ModelView * gl_Vertex;
You should also multiply light with the view matrix, but that is more easily done in the C/C++ code. You will need to change a lot of things in the client code anyway, because most of the gl_* builtin variables are deprecated and you need to send them yourself.
It seems to me that you can find the kind of information you are looking for in the book “OpenGL 4.0 Shading Language Cookbook”. As the name suggests it targets GL 4.0, but most of the shaders, especially the ones covering lighting, only use backwards-compatible language features. It’ll also teach you to do shadows, which isn’t as difficult as you appear to think, and to get rid of deprecated features such as gl_TexCoord.
• I have found a bit of a problem with that. As the scene rotates, the light appears to illuminate things differently. Instead of giving me a smooth, circular lighting pattern, it seems to simply apply light in a cone shape from the center of each object to the edge pointing toward the light. You would expect that, but while the objects and the light are not moving, the lighting patter changes based on the rotation and scaling of the matrices. – Justin Jan 6 '13 at 5:15
• @Justin Ah, there is also the model space / view space inconsistency. I added more information about that, I hope it makes sense. – sam hocevar Jan 6 '13 at 5:28
|
|
# Checking feasibility of a system of inequalities
Consider the following system of inequalities:
$$Ax=b \\ x\geq 0$$
$A$ is a $m\times n$ (non-square) and sparse matrix in which some part of entries are rational.
1. How feasibility of this system can be checked without using linear programming?
2. Is the ellipsoid method useful for checking feasibility of the corresponding polyhedral?
-
I would guess that finding feasible points to this system is almost equivalent to LP. The ellipsoid method is not considered to be effective practically. Primal-dual interior methods are (but also, simplex is still pretty good). – copper.hat Jul 19 '12 at 16:03
The question is whether feasibility of this polyhedral can be checked using ellipsoid method. Since in my problem entries are partly rational. If yes, what is the running time. I need it for theoretical part not practical side. – Star Jul 19 '12 at 16:13
|
|
Re: Need Verdana font for the PDF generated from Lyx
```Hi Ingar, Guenter,
Thanks very much for your inputs.```
```
I finally used Xelatex to generate the PDF with Verdana font. It works very
well, except that it does not support the `attachfile' package that I use
to attach files to the PDF document. Do you know of any other packages that
Xelatex supports, that can be used to attach files to the PDF.
I first generated a tex file from my Lyx file, and then added the following
lines to the tex file before running the Xelatex command to generate the
PDF.
*\usepackage{fontspec}
\setmainfont{Verdana}*
I got the following warning (however, the PDF got generated without any
attachments) -
"Package attachfile Warning: attachfile works _only_ with pdfLaTeX and
_only_ in
(attachfile) PDF-generating mode. For this run, placeholders
wil
l
(attachfile) be substituted for all attachfile commands.."
Parul
On Sat, Jun 13, 2009 at 8:16 PM, Guenter Milde <mi...@users.berlios.de>wrote:
> If you really need Verdana, you must use XeTeX. This is not officially
> supported (yet) but there are workarounds. Search for XeTeX at the wiki
> (http://wiki.lyx.org).
>
> On 2009-06-13, Richard Talley wrote:
>
> > It can be hard to find typefaces that look excellent on paper and on
> > screen (and on both Windows and OS X). Sometimes I'll reset a document
> > in a different typeface when I print it out. The technical documents
> > I'm producing right now I'm putting in Bera (based on Vera Bitstream,
> > realist family) as a reasonable compromise.
>
> Bitstream Vera (or the extended version DejaVy) is the font used by
> OpenOffice: like Verdana it is designed for good appearance in both
> on-screen and printed documents. It is supported in LaTeX by the two
> packages 'bera' (Vera serif) and 'arev' (sans serif with math support).
>
> Günter
>
>
```
|
|
## Filters
Q&A - Ask Doubts and Get Answers
Q
# Nazma's sister also has a trapeziumshaped plot. Divide it into three parts as shown (Fig 11.4). Show that the area of a trapezium
1 Nazma’s sister also has a trapezium-shaped plot. Divide it into three parts as shown (Fig 11.4). Show that the area of a trapezium
$WXYZ=h\frac{(a+b)}{2}$.
Answers (1)
Views
Area of trapezium WXYZ = Area of triangle with base 'c' + area of rectangle + area of triangle with base'd'
$=(\frac{1}{2}\times c\times h)+(b\times h)+\left ( \frac{1}{2}\times d\times h \right )$
Taking 'h' common, we get
$=(\frac{c}{2}+b+\frac{d}{2})h$
$=h(\frac{c+d}{2}+b)$
Replacing $c+d =a-b$
$=h(\frac{a-b}{2}+b)$
$=h(\frac{a+b}{2})$
Hence proved that the area of a trapezium
$WXYZ=h\frac{(a+b)}{2}$..
Exams
Articles
Questions
|
|
This functions checks whether a string or character vector x contains the string pattern. By default, this function is case sensitive.
str_contains(x, pattern, ignore.case = FALSE, logic = NULL, switch = FALSE)
Arguments
x
Character string where matches are sought. May also be a character vector of length > 1 (see 'Examples').
pattern
Character string to be matched in x. May also be a character vector of length > 1 (see 'Examples').
ignore.case
Logical, whether matching should be case sensitive or not.
logic
Indicates whether a logical combination of multiple search pattern should be made.
• Use "or", "OR" or "|" for a logical or-combination, i.e. at least one element of pattern is in x.
• Use "and", "AND" or "&" for a logical AND-combination, i.e. all elements of pattern are in x.
• Use "not", "NOT" or "!" for a logical NOT-combination, i.e. no element of pattern is in x.
• By default, logic = NULL, which means that TRUE or FALSE is returned for each element of pattern separately.
switch
Logical, if TRUE, x will be sought in each element of pattern. If switch = TRUE, x needs to be of length 1.
Value
TRUE if x contains pattern.
Details
This function iterates all elements in pattern and looks for each of these elements if it is found in any element of x, i.e. which elements of pattern are found in the vector x.
Technically, it iterates pattern and calls grep(x, pattern[i], fixed = TRUE) for each element of pattern. If switch = TRUE, it iterates pattern and calls grep(pattern[i], x, fixed = TRUE) for each element of pattern. Hence, in the latter case (if switch = TRUE), x must be of length 1.
Examples
str_contains("hello", "hel")
#> [1] TRUE
str_contains("hello", "hal")
#> [1] FALSE
str_contains("hello", "Hel")
#> [1] FALSE
str_contains("hello", "Hel", ignore.case = TRUE)
#> [1] TRUE
# which patterns are in "abc"?
str_contains("abc", c("a", "b", "e"))
#> [1] TRUE TRUE FALSE
# is pattern in any element of 'x'?
str_contains(c("def", "abc", "xyz"), "abc")
#> [1] TRUE
# is "abcde" in any element of 'x'?
str_contains(c("def", "abc", "xyz"), "abcde") # no...
#> [1] FALSE
# is "abc" in any of pattern?
str_contains("abc", c("defg", "abcde", "xyz12"), switch = TRUE)
#> [1] FALSE TRUE FALSE
str_contains(c("def", "abcde", "xyz"), c("abc", "123"))
#> [1] TRUE FALSE
# any pattern in "abc"?
str_contains("abc", c("a", "b", "e"), logic = "or")
#> [1] TRUE
# all patterns in "abc"?
str_contains("abc", c("a", "b", "e"), logic = "and")
#> [1] FALSE
str_contains("abc", c("a", "b"), logic = "and")
#> [1] TRUE
# no patterns in "abc"?
str_contains("abc", c("a", "b", "e"), logic = "not")
#> [1] FALSE
str_contains("abc", c("d", "e", "f"), logic = "not")
#> [1] TRUE
|
|
# Homework Help: Simple Moment of Inertia Question
1. Dec 1, 2009
### driven4rhythm
Here is the picture of the problem: http://yfrog.com/3uwtfup
I understand every other step except for the equation for moment of inertia. In my book the most basic equation for moment is ΔI = (r)^2 Δm but for this problem ΔI = (1/2)(r)^2 Δm. Why is that? Does it have something to do with the method of integration?
2. Dec 1, 2009
When you are integrating to calculate the moment of inertia (MOI), you take the MOI of a tiny mass and sum all of those to get the total. MOI of a point mass is mr^2. In this case the tiny mass is a disk. MOI of a solid cylinder, disk etc is 1/2 mr^2.
3. Dec 2, 2009
### driven4rhythm
How would you go about deriving the constant that's out front, in this case 1/2?
4. Dec 2, 2009
Using integration :)
There is an example or two in almost every physics text that i have seen. Check out some other books if your book doesn't have it.
5. Dec 2, 2009
### GRB 080319B
The constant comes from the fact that a solid cone is made up of many thin disks (horizontal cross-sections of the cone wrt axis of rotation). So the rotational inertia of the solid cone is equal to the total rotational inertia of all these thin disks. The rotational inertia of a disk of radius R about its center of mass is
$$I_{disk}$$ = 1/2 M$$R^{2}$$
Which is derived from the rotational inertia of a ring of radius R about its center of mass
$$I_{ring}$$ = M$$R^{2}$$
Which is derived from the rotational inertia of a point mass at a radius R from the axis of rotation.
$$I$$ = M$$R^{2}$$
So a small part of the rotational inertia of the cone (d$$I_{cone}$$) is equal to the rotational inertia of a thin disk of radius y, 1/2 dm$$y^{2}$$.
|
|
### JEE Mains Previous Years Questions with Solutions
4.5
star star star star star
1
### AIEEE 2003
Which of the following radiations has the least wavelength ?
A
$\gamma$ - rays
B
$\beta$ - rays
C
$\alpha$ - rays
D
$X$ - rays
## Explanation
The electromagnetic spectrum is as follows
$\therefore$ $\gamma$-rays has least wavelength.
2
### AIEEE 2002
If ${N_0}$ is the original mass of the substance of half-life period ${t_{1/2}} = 5$ years, then the amount of substance left after $15$ years is
A
${N_0}/8$
B
${N_0}/16$
C
${N_0}/2$
D
${N_0}/4$
## Explanation
After every half-life, the mass of the substance reduces to half its initial value.
${N_0}\mathop \to \limits^{5\,years} \,\,{{{N_0}} \over 2}\mathop \to \limits^{5\,years} {{{N_0}} \over {{2^2}}}\mathop \to \limits^{5\,years} {{{N_0}} \over 8}$
3
### AIEEE 2002
At a specific instant emission of radioactive compound is deflected in a magnetic field. The compound can emit
\eqalign{ & \left( i \right)\,\,\,\,\,\,\,electrons\,\,\,\,\,\,\,\,\,\,\,\,\left( {ii} \right)\,\,\,\,\,\,\,protons \cr & \left( {iii} \right)\,\,\,H{e^{2 + }}\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\,\left( {iv} \right)\,\,\,\,\,\,\,neutrons \cr}
The emission at instant can be
A
$i, ii, iii$
B
$i, ii, iii, iv$
C
$iv$
D
$ii, iii$
## Explanation
Charged particles are deflected in magnetic field.
4
### AIEEE 2002
If $13.6$ $eV$ energy is required to ionize the hydrogen atom, then the energy required to remove an electron from $n=2$ is
A
$10.2$ $eV$
B
$0$ $eV$
C
$3.4$ $eV$
D
$6.8$ $eV.$
## Explanation
KEY CONCEPT :
The energy of nth orbit of hydrogen is given by
${E_n} = {{13.6} \over {{n^2}}}eV/$ atom
For $n=2,$ ${E_n} = {{ - 13.6} \over 4} = - 3.4eV$
Therefore the energy required to remove electron from
$n = 2$ is $+3.4eV.$
|
|
## Silver trifluoromethanesulfonate 三氟甲烷磺酸银
##### 规格: 98%
CAS: 2923-28-6
MDL: MFCD00013226
Chemical Name Silver trifluoromethanesulfonate SILVERTRIFLUOROMETHANESULFONATE 220-882-2 3598402 Ag(OTf) Silver (trifluoromethyl)sulfonate 三氟甲磺酸 银盐 三氟甲磺酸银 AgOTf cpd Al(OTf)3 As(otf)2 Cu(OTf)2 Eu(OTf)3 In(OTf)3 SILVER (I) TRIFLUOROMETHANE SULFONATE SILVER TRIFLUOROMETHANESULFONATE, 99+% Silver triflate Silver(I) triflate~Trifluoromethanesulphonic acid silver(I) salt Silver(I) trifluoromethanesulfonate {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} {} { 76223 3598402 三氟甲烷磺酸银 QRUBYZBWAOOHSV-UHFFFAOYSA-M LN00115656 MFCD00013226 2923-28-6 InChI=1S/CHF3O3S.Ag/c2-1(3,4)8(5,6)7;/h(H,5,6,7);/q;+1/p-1 O=S(C(F)(F)F)([O-])=O.[Ag+]
GHS Symbol
Warnings LIGHT SENSITIVE, CORROSIVE Warning 3 S26 In case of contact with eyes, rinse immediately with plenty of water and seek medical advice 眼睛接触后,立即用大量水冲洗并征求医生意见;S36 Wear suitable protective clothing 穿戴适当的防护服;S36/37/39 Wear suitable protective clothing, gloves and eye/face protection 穿戴适当的防护服、手套和眼睛/面保护;S45 In case of accident or if you feel unwell seek medical advice immediately (show the label where possible) 发生事故时或感觉不适时,立即求医(可能时出示标签);S61 Avoid release to the environment. Refer to special instructions/safety data sheet 避免释放到环境中,参考特别指示/安全收据说明书; R34 Causes burns 会导致灼伤R36/37/38 Irritating to eyes, respiratory system and skin 对眼睛、呼吸系统和皮肤有刺激性R50 Very toxic to aquatic organisms 对水生生物极毒 P260 Do not breathe dust/fume/gas/mist/vapours/spray. 不要吸入粉尘/烟/气体/烟雾/蒸汽/喷雾。P261 Avoid breathing dust/fume/gas/mist/vapours/spray. 避免吸入粉尘/烟/气体/烟雾/蒸汽/喷雾。P264 Wash hands thoroughly after handling. 处理后要彻底洗净双手。P271 Use only outdoors or in a well-ventilated area.? 只能在室外或通风良好的地方使用。P273 Avoid release to the environment. 避免释放到环境中。P280 Wear protective gloves/protective clothing/eye protection/face protection. 戴防护手套/防护服/眼睛的保护物/面部保护物。P301+P330+P331 P302+P350 P302+P352 P302+P352+P332+P313+P362+P364 P303+P361+P353 P304+P340 P305+P351+P338 P305+P351+P338+P337+P313 P310 Immediately call a POISON CENTER or doctor/physician. 立即呼救解毒中心或医生/医师。P312 Call a POISON CENTER or doctor/physician if you feel unwell. 如果你感觉不适,呼叫解毒中心或医生/医师。P321 Specific treatment (see … on this label). 具体治疗(见本标签上的)。P332+P313 P337+P313 P362 Take off contaminated clothing and wash before reuse. 脱掉污染的衣服,清洗后方可重新使用P363 Wash contaminated clothing before reuse. 被污染的衣服洗净后方可重新使用。P403+P233 P405 Store locked up. 上锁保管。P501 Dispose of contents/container to..… 处理内容物/容器..... H314 Causes severe skin burns and eye damage 导致严重的皮肤灼伤和眼睛损伤H315 Causes skin irritation 会刺激皮肤H319 Causes serious eye irritation 严重刺激眼睛H335 May cause respiratory irritation 可能导致呼吸道刺激 dust mask type N95 (US), Eyeshields, Gloves III 3260 UN3260 2-8°C, protect from light, stored under nitrogen Light Sensitive 易吸潮,密封保存 8
• {ALF} Silver salt soluble in ether, fairly soluble in benzene and toluene, less soluble in acetonitrile and insoluble in chloroform and dichloromethane; useful, e.g. in promotion of the leaving ability of halogens. For use in the conversion of alkyl halides to triflates, see: J. Chem. Soc., 173 (1956); J. Am. Chem. Soc., 90, 1598 (1968); Tetrahedron Lett., 3159 (1970); J. Chem. Soc., Perkin 1, 2887 (1980). Review: Synthesis, 85 (1982).
• {ALF} For use as a catalyst for the oxy-Cope rearrangement of allyl alkynyl carbinols, where other silver salts are ineffective, see: Tetrahedron Lett., 25, 2873 (1984):
• {ALF} Acyl halides are converted to acyl triflates, powerful acylating reagents, which can bring about Friedel-Crafts-type acylation without added Lewis acid catalyst: Chem. Ber., 116, 1195 (1983).
• {ALF} Reaction with chlorosilanes gives silyl triflates, powerful silylating reagents, and, likewise trialkyltin halides are converted to the corresponding triflates: Chem. Ber., 103, 868 (1970).
• {ALD} Beilstein:3(4)34
• {SNA}
• #### 化学属性
Melting Point 286°C 1.876 T CAgF3O3S 256.94 off-white pwdr. light sensitive, hygroscopic
|
|
# Spring-mass system with variable stifness $m \ddot{x}+k(x)x=0$, time period is known, stifness is unknown
This question is somewhat related to my previous question: What is the time period of an oscillator with varying spring constant?
In that question, time period of mass-spring system with variable stiffness was asked. Answers were really helpful, and with help of answers I managed to derive time period of certain oscillator system $$m \ddot{x}+b \dot{x}+k(x)x=0 \, .$$ This stiffness $k(x)$ had dependence on displacement which was assumed to be second order polynomial. I also put a small attenuation term $b$ to spring equation, but that's just to check how attenuation term effect the system. In reality, this term is quite small and can be dismissed. Equation I got is
$$k(x) = \alpha + \beta x +\gamma x^2$$
from which we find
$$T = 4 \int_{x_0}^{x_\text{max}} \frac{dx}{\sqrt{\left(v_0^2 - \dfrac{2}{m} \left(\dfrac{\alpha x^2}{2} + \dfrac{\beta x^3}{3} + \dfrac{\gamma x^4}{4}\right) - \dfrac{bx^2}{m}\right)}}$$
From this equation I got quite nice results when I calculated it numerically with Wolfram Alpha. However something came to my mind: If we do not know the stiffness of spring a-priori, but we know time period of the spring we get into trouble. Approaches mentioned in last post seem not to work in this situation. If we have variable stiffness mass-spring system $m \ddot{x} + k(x) x = 0$ and we know always it's period of oscillation, initial values $x(0)$ and $\dot{x}(0)$ and even $x(t)$, what is it's stiffness? So what is function $K=f(T)$? I am quite sure that $T=2 \pi \sqrt{\dfrac{m}{K}}$ is no good in this case.
• What do you mean by "we know its period of oscillation with any $x$"? Most oscillations will go through many different values of $x$. Do you mean "as a function of amplitude"? – Michael Seifert Aug 27 '15 at 13:58
• I suspect that the answer will not be unique. – march Aug 27 '15 at 16:47
• Michael Seifert: Good question. "We know its period of oscillation with any x" is now changed to “we know always it's period of oscillation, initial values x(0) and x'(0) and even x(t)”.. Originally I was trying to say something like “we know always x(t)”, but wrote some weird stuff instead. – dr_mushroom Aug 28 '15 at 7:03
|
|
Large powers
Number Theory Level 4
Find the last three digits of the sum of the distinct prime factors of $$3^{12}+2^{14}$$.
×
|
|
# source:Deliverables/D4.4/report.tex@3248
Last change on this file since 3248 was 3248, checked in by sacerdot, 7 years ago
Typos fixed.
File size: 5.9 KB
RevLine
[3222]1\documentclass[12pt]{article}
[3143]2
3\usepackage{../style/cerco}
4\usepackage{pdfpages}
5
6\usepackage{amsfonts}
7\usepackage{amsmath}
8\usepackage{amssymb}
9\usepackage[english]{babel}
10\usepackage{graphicx}
11\usepackage[utf8x]{inputenc}
12\usepackage{listings}
13\usepackage{stmaryrd}
14\usepackage{url}
15\usepackage{bbm}
16
17\title{
18INFORMATION AND COMMUNICATION TECHNOLOGIES\\
19(ICT)\\
20PROGRAMME\\
21\vspace*{1cm}Project FP7-ICT-2009-C-243881 \cerco{}}
22
23\lstdefinelanguage{matita-ocaml}
24 {keywords={ndefinition,ncoercion,nlemma,ntheorem,nremark,ninductive,nrecord,nqed,nlet,let,in,rec,match,return,with,Type,try},
25 morekeywords={[2]nwhd,nnormalize,nelim,ncases,ndestruct},
26 morekeywords={[3]type,of},
27 mathescape=true,
28 }
29
30\lstset{language=matita-ocaml,basicstyle=\small\tt,columns=flexible,breaklines=false,
31 keywordstyle=\color{red}\bfseries,
32 keywordstyle=[2]\color{blue},
33 keywordstyle=[3]\color{blue}\bfseries,
35 stringstyle=\color{blue},
36 showspaces=false,showstringspaces=false}
37
38\lstset{extendedchars=false}
39\lstset{inputencoding=utf8x}
40\DeclareUnicodeCharacter{8797}{:=}
41\DeclareUnicodeCharacter{10746}{++}
42\DeclareUnicodeCharacter{9001}{\ensuremath{\langle}}
43\DeclareUnicodeCharacter{9002}{\ensuremath{\rangle}}
44
45\date{}
46\author{}
47
48\begin{document}
[3222]49\pagenumbering{roman}
[3143]50\thispagestyle{empty}
51
52\vspace*{-1cm}
53\begin{center}
54\includegraphics[width=0.6\textwidth]{../style/cerco_logo.png}
55\end{center}
56
57\begin{minipage}{\textwidth}
58\maketitle
59\end{minipage}
60
61\vspace*{0.5cm}
62\begin{center}
63\begin{LARGE}
64\textbf{
65Report n. D4.4\\
66Back-end Correctness Proof}
67\end{LARGE}
68\end{center}
69
70\vspace*{2cm}
71\begin{center}
72\begin{large}
73Version 1.0
74\end{large}
75\end{center}
76
77\vspace*{0.5cm}
78\begin{center}
79\begin{large}
80Main Authors:\\
[3213]81Jaap Boender, Dominic P. Mulligan, Mauro Piccolo,\\ Claudio Sacerdoti Coen and
82Paolo Tranquilli
[3143]83\end{large}
84\end{center}
85
86\vspace*{\fill}
87
88\noindent
89Project Acronym: \cerco{}\\
90Project full title: Certified Complexity\\
91Proposal/Contract no.: FP7-ICT-2009-C-243881 \cerco{}\\
92
93\clearpage
95\markright{\cerco{}, FP7-ICT-2009-C-243881}
96
97\newpage
[3213]99\paragraph{Summary}
100The deliverable D4.4 is composed of the following parts:
[3143]101
[3213]102\begin{enumerate}
[3143]103
[3213]104\item This summary.
[3143]105
[3213]106\item The paper \cite{simulation}.
[3143]107
[3213]108\item The paper \cite{backend}.
[3143]109
[3213]110\item The paper \cite{asm}.
[3143]111
[3213]112\item The paper \cite{policy}.
113
114\end{enumerate}
115
116This document and all the related \textsf{matita} developments can be downloaded at the
117page:
118\begin{center}
119{\tt http://cerco.cs.unibo.it/}
120\end{center}
121
122\bibliographystyle{unsrt}
123{\scriptsize\bibliography{report}}
124
[3143]125\newpage
126
[3213]127\paragraph{Aim}
128The aim of WP4 is is to build the trusted version of the compiler back-end,
129from the intermediate \textsf{RTLabs} language down to assembly. The development
[3248]130is made in \textsf{matita}, and it allows the trusted compiler to be extracted
[3213]131to \textsf{OCaml}.
132
133The main planned contributions of deliverable D4.4 are formally checked proof
134of the semantics correspondence between the intermediate code and the target
135code, and of the preservation/modification of the control flow for complexity
136analysis.
137
138\paragraph{Preservation of structure}
139In \cite{simulation} we present a genric approach to proving a forward
140simulation preserving the intensional structure of traces.
141
142When a language
143starts to be able to meddle with return addresses that live in memory, the call structure
144is no more guaranteed to be preserved after the high-level, structured
[3248]145languages. This has little meaning as far as pure extensional semantic
[3213]146preservation is required---after all, if the source language meddles with the
147call structure there is no problem as long as the target language will follow.
148However in our approach we have cost labels spanning multiple calls, so that
149the cost of what follows a call is paid'' in advance. This has no hope of
150being correct if there is no guarantee that upon return from a call we land
151after the call itself.
152
153In this part of the deliverable we will present our approach to this problem,
154which goes by including in semantic traces structural conditions, and giving
155generic proof obligations that enrich the classic step-by-step extensional
156preservation proof with the necessary hypotheses to ensure the preservation
157of the call and label structures. This approach can be applied on all passes
158starting from the \textsf{RTLabs} to \textsf{RTL} down to the assembly one.
159
160\paragraph{The back-end correctness proof}
161In \cite{backend}, we give an outline of the actual correctness proof for the
162passes from \textsf{RTLabs} down to assembly. We skip the details of the
163extensional parts of each pass and we concentrate on two main aspects:
164how we deal with stack and how we ensure the conditions explained in
165\cite{simulation} in the passes involving graph languages.
166
167\paragraph{The assembler correctness proof}
168In \cite{asm}, we present a proof of correctness of our assembler to object
169code, given a correct policy for branch expansion (see next paragraph).
170
171\paragraph{A branch expansion policy maker}
172In \cite{policy} we finally present our algorithm for branch expansion, that is
173how generic assembly jumps are expanded to the different type of jumps
174available in the 8051 architecture (short, absolute and long). The correctness
175of this algorithm is proved, and is what required by the correctness of the
176whole assembler.
177
[3222]178\includepdf[pages={-},addtotoc={1,section,1,Certification of the preservation of structure by a compiler's back-end pass,simulation}]{itp2013.pdf}
179\includepdf[pages={-},addtotoc={1,section,1,Certifying the back-end pass of the CerCo annotating compiler,backend}]{paolo.pdf}
180\includepdf[pages={-},addtotoc={1,section,1,On the correctness of an optimising assembler for the Intel MCS-51 microprocessor,asm}]{cpp-2012-asm.pdf}
181\includepdf[pages={-},addtotoc={1,section,1,On the correctness of a branch displacement algorithm,policy}]{cpp-2012-policy.pdf}
[3143]182
183\end{document}
Note: See TracBrowser for help on using the repository browser.
|
|
Example of a module that is finitely generated, finitely cogenerated and linearly compact, but not Artinian! [closed]
I need an example of a module that is finitely generated, finitely cogenerated and also linearly compact (in discrete topology) but not Artinian.
In fact I proved a theorem with this strong assumptions and I am not sure that there is such a module except finitely generated Artinian modules (and my result for finitely generated Artinian modules is obvious). For the definition of finitely cogenerated modules one can see https://en.wikipedia.org/wiki/Finitely_generated_module. Can anyone give me such an example. Thanks a lot.
closed as off-topic by user26857, user99914, JonMark Perry, TheSimpliFire, user223391 Feb 4 '18 at 2:36
This question appears to be off-topic. The users who voted to close gave this specific reason:
• "This question is missing context or other details: Please improve the question by providing additional context, which ideally includes your thoughts on the problem and any attempts you have made to solve it. This information helps others identify where you have difficulties and helps them write answers appropriate to your experience level." – user26857, Community, JonMark Perry, TheSimpliFire, Community
If this question can be reworded to fit the rules in the help center, please edit the question.
• Now that we have your "needs" out of the way, perhaps we can briefly look at what you've considered, and how you came about the question? – rschwieb Feb 2 '18 at 17:20
• @rschwieb Ok, i proof a theorem with this assumptions: Let $M$ be an $R$-module that is finitely generated, finitely cogenerated and linearly compact! I am not sure that is there any module with this strong assumptions except finitely generated Artinian module. – S Ali Mousavi Feb 2 '18 at 17:30
If you take a Noetherian commutative local ring $R$, complete in the $\mathfrak{m}$-adic topology ($\mathfrak{m}$ the maximal ideal and $E$ the injective envelope of $R/\mathfrak{m}$, then the canonical embedding $R\to\operatorname{End}(E_R)$ is an isomorphism (Matlis, 1958). The trivial extension of $E$ by $R$, that is the ring $A=R\times E$ with operations $$(r,x)+(s,y)=(r+s,x+y),\qquad (r,x)(s,y)=(rs,ry+xs)$$ is then a ring with a Morita duality induced by the bimodule $_AA_A$ (Dikranjan, Gregorio and Orsatti, 1991, Example 1.13). In particular it is finitely cogenerated and also linearly compact in the discrete topology (Müller, 1970).
There are three examples in this search of rings which, considered as modules over themselves, have that property.
The easiest one to re-describe here is the trivial extension of the Prufer group $\mathbb Z(p^\infty)$ by $\mathbb Z$. (Its label there is "Finitely cogenerated, not semilocal ring".)
• Thanks a lot. I saw these examples. Are these also linearly compact? Of course, i know $F[|x|]$ is linearly compact, but what about the field of fractions of this ring? – S Ali Mousavi Feb 2 '18 at 17:53
• @SAliMousavi Sorry, I'm not familiar enough with linearly compact modules. I also don't know what you mean by $F[|x|]$: is that your notation for $F[[x]]$? – rschwieb Feb 2 '18 at 19:31
• Excuse me. Yes. your notation is correct. $F[[x]]$ – S Ali Mousavi Feb 2 '18 at 20:43
|
|
Why is my target above/below the horizon at the rise/set time?¶
Rise/set/meridian transit calculations in astroplan are designed to be fast while achieving a precision comparable to what can be predicted given the affects of the changing atmosphere. As a result, there may be some counter-intuitive behavior in astroplan methods like astroplan.Observer.target_rise_time, astroplan.Observer.target_set_time and astroplan.Observer.target_meridian_transit_time, that can lead to small changes in the numerical values of these computed timed (of order seconds).
For example, to calculate the rise time of Sirius, you might write:
from astroplan import Observer, FixedTarget
from astropy.time import Time
# Set up observer, target, and time
keck = Observer.at_site("Keck")
sirius = FixedTarget.from_name("Sirius")
time = Time('2010-05-11 06:00:00')
# Find rise time of Sirius at Keck nearest to time
rise_time = keck.target_rise_time(time, sirius)
You might expect the altitude of Sirius to be zero degrees at rise_time, i.e. Sirius will be on the horizon, but this is not the case:
>>> altitude_at_rise = keck.altaz(rise_time, sirius).alt
>>> print(altitude_at_rise.to('arcsec'))
2.70185arcsec
The altitude that you compute on your machine may be different from the number above by a small amount – for a detailed explanation on where the difference arises from, see What are the IERS tables and how do I update them?. The rise and set time methods use the following approximation:
• A time series of altitudes for the target is computed at times near time
• The two times when the target is nearest to the horizon are identified, and a linear interpolation is done between those times to find the horizon-crossing
This method has a precision of a few arcseconds, so your targets may be slightly above or below the horizon at their rise or set times.
|
|
# Two limited integration questions
1. Dec 13, 2004
### hhegab
Peace!
I want to know the conditions that must be satisfied by a function
$$f(x)$$ for any of the following two cases to be true (each case independent from the other);
1- $$\int^a_{-a} f(x) dx = 2 \int^a_0 f(x) dx$$
2- $$\int^a_0 f(x) dx = \int^0_a f(x) dx$$
They gave me confusion when I was solving problems related to electric field and electric potential.
2. Dec 13, 2004
### quasar987
I don't know if this condition is sufficient but a condition would be, if we write the integrals in terms of their primitives,
$$\int^a_{-a} f(x) dx = 2 \int^a_0 f(x) dx \Leftrightarrow \mathcal{F}(a) - \mathcal{F}(-a) = 2\mathcal{F}(a) \Leftrightarrow \mathcal{F}(-a) = -\mathcal{F}(a)$$
The condition is that it is true iff the primitive of f is a function F such that F(-a) = -F(a)
3. Dec 13, 2004
### marlon
First case...
$$\int^a_{-a} f(x) dx = \int^0_{-a} f(x) dx + \int^a_0 f(x) dx$$
Then use the fact that :
$$\int^0_{-a} f(x) dx = - \int^{-a}_0 f(x) dx$$
and replace x by -x...the limit -a will then change to a because of this substitution. and dx will become -dx. Now f(x) becomes f(-x) and there are two possibilities. Either f(-x) = -f(x) or f(-x) = f(x)....you know what you will need to achieve so which one of the two is it...
Question 2 :
Just put the integral in right hand side to the left hand side and use the above property to get rid of the minus-sign...what do you get ???
regards
marlon
4. Dec 13, 2004
### hhegab
Can you put like , first case is true if f(x) is even and if such and such....
|
|
+0
# Help!
0
150
1
+144
The line $$l_1$$ passes through the points $$(3,-3)$$ and $$(-5,2)$$ . The line is the graph of the equation $$Ax + By = C$$, where $$A$$, $$B$$ , and $$C$$ are integers with greatest common divisor 1, and A is positive. Find $$A + B + C$$.
Sep 28, 2018
#1
+7348
+1
slope of the line that passes through (3, -3) and (-5, 2) = $$\frac{y_2-y_1}{x_2-x_1}\,=\,\frac{2--3}{-5-3}\,=\,-\frac{5}{8}$$
The line l1 passes through the point (3, -3) and has a slope of $$-\frac58$$ .
So the equation of l1 in point-slope form is...
y - -3 = $$-\frac58$$(x - 3) Now we just have to get this equation in the form Ax + By = C
y + 3 = $$-\frac58$$(x - 3)
Multiply both sides of the equation through by 8 .
8y + 24 = -5(x - 3)
Distribute the -5 to the terms in parenthesees.
8y + 24 = -5x + 15
Subtract 24 from both sides of the equation.
8y = -5x + 15 - 24
8y = -5x - 9
Add 5x to both sides of the equation.
5x + 8y = -9
5 , 8 , and -9 are integers with the greatest common divisor 1 , and 5 is positive.
5 + 8 + -9 = 4
Sep 29, 2018
|
|
Let $(M,m)$ be a connected Riemannian manifold. In this lecture we turn $M$ into a metric space by declaring that
$$d_m(x,y) := \inf \left\{ \mathbb{L}_m( \gamma) \mid \gamma \in \mathcal{P}_{xy} \right\},$$
where $\mathcal{P}_{xy}$ denotes the set of all piecewise smooth maps $\gamma \colon [a,b] \to M$ such that $\gamma(a) = x$ and $\gamma(b) = y$. We prove moreover that the metric space topology $d_m$ induces on $M$ coincides with its original topology. We also show that any geodesic is locally length-minimising with respect to $d_m$ (which explains the name “geodesic”).
Next lecture we will prove that $(M , d_m)$ is complete as a metric space if and only if $m$ is complete as a metric (i.e. all geodesics are defined on the entire real line). This is the Hopf-Rinow Theorem.
|
|
# zbMATH — the first resource for mathematics
## Poor, Cris
Compute Distance To:
Author ID: poor.cris Published as: Poor, C.; Poor, Cris
Documents Indexed: 36 Publications since 1992
all top 5
#### Co-Authors
3 single-authored 31 Yuen, David S. 5 Shurman, Jerry 2 Gritsenko, Valeriĭ Alekseevich 2 Ibukiyama, Tomoyoshi 2 Oura, Manabu 2 Schmidt, Ralf 1 Boehm, Alexandria B. 1 Breeding, Jeffery II 1 Brumer, Armand 1 Grant, Stanley B. 1 Katsurada, Hidenori 1 King, Oliver Davis 1 Pacetti, Ariel 1 Ryan, Nathan C. 1 Salvati Manni, Riccardo 1 Tornaría, Gonzalo 1 Voight, John Michael 1 Yuen, Shoji
all top 5
#### Serials
5 Bulletin of the Australian Mathematical Society 4 Abhandlungen aus dem Mathematischen Seminar der Universität Hamburg 4 Journal of the Korean Mathematical Society 3 Mathematics of Computation 3 Journal of Number Theory 3 Mathematische Annalen 3 International Journal of Number Theory 2 Proceedings of the American Mathematical Society 1 Bulletin of the London Mathematical Society 1 Duke Mathematical Journal 1 Geometriae Dedicata 1 Journal of the Mathematical Society of Japan 1 IMRN. International Mathematics Research Notices 1 Journal of Physics A: Mathematical and General 1 Far East Journal of Mathematical Sciences 1 Algebra & Number Theory 1 Moscow Journal of Combinatorics and Number Theory
all top 5
#### Fields
32 Number theory (11-XX) 8 Algebraic geometry (14-XX) 2 Functions of a complex variable (30-XX) 2 Several complex variables and analytic spaces (32-XX) 2 Quantum theory (81-XX) 1 Statistical mechanics, structure of matter (82-XX) 1 Information and communication theory, circuits (94-XX)
#### Citations contained in zbMATH Open
30 Publications have been cited 174 times in 99 Documents Cited by Year
Paramodular cusp forms. Zbl 1392.11028
Poor, Cris; Yuen, David S.
2015
Linear dependence among Siegel modular forms. Zbl 0972.11035
Poor, Cris; Yuen, David S.
2000
Dimensions of cusp forms for $$\Gamma_0(p)$$ in degree two and small weights. Zbl 1214.11059
Poor, C.; Yuen, D. S.
2007
Borcherds products everywhere. Zbl 1380.11050
Gritsenko, Valery; Poor, Cris; Yuen, David S.
2015
The cusp structure of the paramodular groups for degree two. Zbl 1329.11042
Poor, Cris; Yuen, David S.
2013
The hyperelliptic locus. Zbl 0832.14020
Poor, Cris
1994
Computations of spaces of paramodular forms of general level. Zbl 1416.11063
Breeding, Jeffery Ii; Poor, Cris; Yuen, David S.
2016
Computations of spaces of Siegel modular cusp forms. Zbl 1114.11045
Poor, Cris; Yuen, David S.
2007
Jacobi forms that characterize paramodular forms. Zbl 1297.11037
Ibukiyama, Tomoyoshi; Poor, Cris; Yuen, David S.
2013
Siegel paramodular forms of weight 2 and squarefree level. Zbl 1428.11087
Poor, Cris; Shurman, Jerry; Yuen, David S.
2017
Modular forms of weight 8 for $$\Gamma_g(1, 2)$$. Zbl 1244.11050
Oura, Manabu; Poor, Cris; Salvati Manni, Riccardo; Yuen, David S.
2010
Congruences to Ikeda-Miyawaki lifts and triple $$L$$-values of elliptic modular forms. Zbl 1322.11042
Ibukiyama, Tomoyoshi; Katsurada, Hidenori; Poor, Cris; Yuen, David S.
2014
Theta block Fourier expansions, Borcherds products and a sequence of Newman and Shanks. Zbl 1422.11111
Poor, Cris; Shurman, Jerry; Yuen, David S.
2018
Paramodular forms of level $$8$$ and weights $$10$$ and $$12$$. Zbl 1420.11084
Poor, Cris; Schmidt, Ralf; Yuen, David S.
2018
Restriction of Siegel modular forms to modular curves. Zbl 1021.11012
Poor, Cris; Yuen, David S.
2002
On the paramodularity of typical abelian surfaces. Zbl 07083104
Brumer, Armand; Pacetti, Ariel; Poor, Cris; Tornaría, Gonzalo; Voight, John; Yuen, David
2019
Lifting puzzles in degree four. Zbl 1234.11062
Poor, Cris; Ryan, Nathan C.; Yuen, David S.
2009
Towards the Siegel ring in genus four. Zbl 1166.11016
Oura, Manabu; Poor, Cris; Yuen, David S.
2008
The extreme core. Zbl 1082.11026
Poor, C.; Yuen, S.
2005
Estimates for dimensions of spaces of Siegel modular cusp forms. Zbl 0867.11033
Poor, C.; Yuen, D. S.
1996
Dimensions of spaces of Siegel modular forms of low weight in degree four. Zbl 0865.11039
Poor, Cris; Yuen, David S.
1996
Schottky’s form and the hyperelliptic locus. Zbl 0855.11023
Poor, Cris
1996
Binary forms and the hyperelliptic superstring ansatz. Zbl 1293.11069
Poor, Cris; Yuen, David S.
2012
The Bergé-Martinet constant and slopes of Siegel cusp forms. Zbl 1104.11039
Poor, Cris; Yuen, David S.
2006
Slopes of integral lattices. Zbl 1041.11033
Poor, Cris; Yuen, David S.
2003
Nonlift weight two paramodular eigenform constructions. Zbl 1452.11055
Poor, Cris; Shurman, Jerry; Yuen, David S.
2020
Paramodular forms of level 16 and supercuspidal representations. Zbl 1447.11061
Poor, Cris; Schmidt, Ralf; Yuen, David S.
2019
Using Katsurada’s determination of the Eisenstein series to compute Siegel eigenforms. Zbl 1432.11051
King, Oliver D.; Poor, Cris; Shurman, Jerry; Yuen, David S.
2018
Relations on the period mapping giving extensions of mixed Hodge structures on compact Riemann surfaces. Zbl 0889.32023
Poor, Cris; Yuen, David S.
1996
Fay’s trisecant formula and cross-ratios. Zbl 0741.30036
Poor, Cris
1992
Nonlift weight two paramodular eigenform constructions. Zbl 1452.11055
Poor, Cris; Shurman, Jerry; Yuen, David S.
2020
On the paramodularity of typical abelian surfaces. Zbl 07083104
Brumer, Armand; Pacetti, Ariel; Poor, Cris; Tornaría, Gonzalo; Voight, John; Yuen, David
2019
Paramodular forms of level 16 and supercuspidal representations. Zbl 1447.11061
Poor, Cris; Schmidt, Ralf; Yuen, David S.
2019
Theta block Fourier expansions, Borcherds products and a sequence of Newman and Shanks. Zbl 1422.11111
Poor, Cris; Shurman, Jerry; Yuen, David S.
2018
Paramodular forms of level $$8$$ and weights $$10$$ and $$12$$. Zbl 1420.11084
Poor, Cris; Schmidt, Ralf; Yuen, David S.
2018
Using Katsurada’s determination of the Eisenstein series to compute Siegel eigenforms. Zbl 1432.11051
King, Oliver D.; Poor, Cris; Shurman, Jerry; Yuen, David S.
2018
Siegel paramodular forms of weight 2 and squarefree level. Zbl 1428.11087
Poor, Cris; Shurman, Jerry; Yuen, David S.
2017
Computations of spaces of paramodular forms of general level. Zbl 1416.11063
Breeding, Jeffery Ii; Poor, Cris; Yuen, David S.
2016
Paramodular cusp forms. Zbl 1392.11028
Poor, Cris; Yuen, David S.
2015
Borcherds products everywhere. Zbl 1380.11050
Gritsenko, Valery; Poor, Cris; Yuen, David S.
2015
Congruences to Ikeda-Miyawaki lifts and triple $$L$$-values of elliptic modular forms. Zbl 1322.11042
Ibukiyama, Tomoyoshi; Katsurada, Hidenori; Poor, Cris; Yuen, David S.
2014
The cusp structure of the paramodular groups for degree two. Zbl 1329.11042
Poor, Cris; Yuen, David S.
2013
Jacobi forms that characterize paramodular forms. Zbl 1297.11037
Ibukiyama, Tomoyoshi; Poor, Cris; Yuen, David S.
2013
Binary forms and the hyperelliptic superstring ansatz. Zbl 1293.11069
Poor, Cris; Yuen, David S.
2012
Modular forms of weight 8 for $$\Gamma_g(1, 2)$$. Zbl 1244.11050
Oura, Manabu; Poor, Cris; Salvati Manni, Riccardo; Yuen, David S.
2010
Lifting puzzles in degree four. Zbl 1234.11062
Poor, Cris; Ryan, Nathan C.; Yuen, David S.
2009
Towards the Siegel ring in genus four. Zbl 1166.11016
Oura, Manabu; Poor, Cris; Yuen, David S.
2008
Dimensions of cusp forms for $$\Gamma_0(p)$$ in degree two and small weights. Zbl 1214.11059
Poor, C.; Yuen, D. S.
2007
Computations of spaces of Siegel modular cusp forms. Zbl 1114.11045
Poor, Cris; Yuen, David S.
2007
The Bergé-Martinet constant and slopes of Siegel cusp forms. Zbl 1104.11039
Poor, Cris; Yuen, David S.
2006
The extreme core. Zbl 1082.11026
Poor, C.; Yuen, S.
2005
Slopes of integral lattices. Zbl 1041.11033
Poor, Cris; Yuen, David S.
2003
Restriction of Siegel modular forms to modular curves. Zbl 1021.11012
Poor, Cris; Yuen, David S.
2002
Linear dependence among Siegel modular forms. Zbl 0972.11035
Poor, Cris; Yuen, David S.
2000
Estimates for dimensions of spaces of Siegel modular cusp forms. Zbl 0867.11033
Poor, C.; Yuen, D. S.
1996
Dimensions of spaces of Siegel modular forms of low weight in degree four. Zbl 0865.11039
Poor, Cris; Yuen, David S.
1996
Schottky’s form and the hyperelliptic locus. Zbl 0855.11023
Poor, Cris
1996
Relations on the period mapping giving extensions of mixed Hodge structures on compact Riemann surfaces. Zbl 0889.32023
Poor, Cris; Yuen, David S.
1996
The hyperelliptic locus. Zbl 0832.14020
Poor, Cris
1994
Fay’s trisecant formula and cross-ratios. Zbl 0741.30036
Poor, Cris
1992
all top 5
#### Cited by 107 Authors
22 Poor, Cris 20 Yuen, David S. 8 Ibukiyama, Tomoyoshi 6 Gritsenko, Valeriĭ Alekseevich 5 Salvati Manni, Riccardo 5 Shurman, Jerry 4 Kikuta, Toshiyuki 4 Raum, Martin 4 Schmidt, Ralf 4 Wang, Haowu 3 Dummigan, Neil 3 Katsurada, Hidenori 3 Kodama, Hirotaka 3 Matone, Marco 3 Nagaoka, Shoyu 3 Oura, Manabu 3 Piazza, Francesco Dalla 3 Richter, Olav K. 3 Ryan, Nathan C. 2 Ash, Avner 2 Bergström, Jonas 2 Böcherer, Siegfried 2 Bruinier, Jan Hendrik 2 Cacciatori, Sergio Luigi 2 Ghitza, Alexandru 2 Grushevsky, Samuel 2 Gunnells, Paul E. 2 Ionica, Sorina 2 Lauter, Kristin Estella 2 McConnell, Mark 2 Pacetti, Ariel 2 Shukla, Alok Kumar 2 Takemori, Sho 2 Tornaría, Gonzalo 2 Vincent, Christelle 2 Wang, Juping 1 Atobe, Hiraku 1 Balakrishnan, Jennifer S. 1 Berger, Tobias 1 Bogatyrev, Andrei Borisovich 1 Bringmann, Kathrin 1 Brumer, Armand 1 Calegari, Frank 1 Cheng, Miranda C. N. 1 Chidambaram, Shiva 1 Choi, Dohoon 1 Choie, YoungJu 1 Cléry, Fabien 1 Cohen, Henri 1 Dalla Piazza, F. 1 Dembélé, Lassina 1 Dewar, Michael C. 1 Duan, Lian 1 Duncan, John F. R. 1 Dunin-Barkovskiĭ, Petr Igorevich 1 Farmer, David W. 1 Ferapontov, Evgeny Vladimirovich 1 Fiorentino, Alessio 1 Freitag, Eberhard 1 Girola, Davide 1 Grigor’ev, O. A. 1 Gun, Sanoli 1 Harvey, Jeffrey A. 1 Hassett, Brendan 1 Heim, Bernhard Ernst 1 Ichikawa, Takashi 1 Johnson-Leung, Jennifer 1 Kaenders, Rainer H. 1 Kane, Benjamin 1 Kılıçer, Pınar 1 King, Oliver Davis 1 Kohnen, Winfried 1 Koutsoliotas, Sally 1 Kresch, Andrew 1 Lemurell, Stefan 1 Lorenzini, Dino J. 1 Lorenzo García, Elisa 1 Mânzăţeanu, Adelina 1 Marrani, Alessio 1 Marzec, Jolanta 1 Massierer, Maike 1 Mégarbané, Thomas 1 Miyazaki, Takuya 1 Mizumoto, Shin-ichiro 1 Mizuno, Yoshinori 1 Nakamura, Yoshitsugu 1 Noja, Simone 1 Okuda, Kenji 1 Oyono, Roger 1 Panchishkin, Alexei A. 1 Re, Riccardo 1 Roberts, Brooks 1 Sawatani, Kazuomi 1 Schulze-Pillot, Rainer 1 Şengün, Mehmet Haluk 1 Sengupta, Jyoti 1 Skoruppa, Nils-Peter 1 Sleptsov, Alexey 1 Stern, Abel B. 1 Sulon, David W. ...and 7 more Authors
all top 5
#### Cited in 45 Serials
10 Journal of Number Theory 9 Mathematics of Computation 8 Abhandlungen aus dem Mathematischen Seminar der Universität Hamburg 7 International Journal of Number Theory 4 Bulletin of the Australian Mathematical Society 4 Proceedings of the American Mathematical Society 4 Journal of High Energy Physics 3 Nuclear Physics. B 3 Annales de l’Institut Fourier 3 Mathematische Annalen 3 Experimental Mathematics 2 Communications in Mathematical Physics 2 Russian Mathematical Surveys 2 Science in China. Series A 2 International Journal of Mathematics 2 Journal de Théorie des Nombres de Bordeaux 2 Selecta Mathematica. New Series 2 Research in Number Theory 1 Israel Journal of Mathematics 1 Rocky Mountain Journal of Mathematics 1 Duke Mathematical Journal 1 International Journal of Mathematics and Mathematical Sciences 1 Journal of the Korean Mathematical Society 1 Journal of the London Mathematical Society. Second Series 1 Journal of the Mathematical Society of Japan 1 Journal of Pure and Applied Algebra 1 Manuscripta Mathematica 1 Mathematische Zeitschrift 1 Nagoya Mathematical Journal 1 Pacific Journal of Mathematics 1 Rendiconti del Circolo Matemàtico di Palermo. Serie II 1 Transactions of the American Mathematical Society 1 Journal of Symbolic Computation 1 Journal of the Ramanujan Mathematical Society 1 Sbornik: Mathematics 1 LMS Journal of Computation and Mathematics 1 SIGMA. Symmetry, Integrability and Geometry: Methods and Applications 1 Proceedings of the Steklov Institute of Mathematics 1 Journal of Physics A: Mathematical and Theoretical 1 Algebra & Number Theory 1 Kyoto Journal of Mathematics 1 Moscow Journal of Combinatorics and Number Theory 1 Forum of Mathematics, Pi 1 Research in the Mathematical Sciences 1 European Journal of Mathematics
all top 5
#### Cited in 16 Fields
84 Number theory (11-XX) 24 Algebraic geometry (14-XX) 8 Quantum theory (81-XX) 4 Relativity and gravitational theory (83-XX) 3 Several complex variables and analytic spaces (32-XX) 2 Group theory and generalizations (20-XX) 2 Information and communication theory, circuits (94-XX) 1 Nonassociative rings and algebras (17-XX) 1 Category theory; homological algebra (18-XX) 1 Special functions (33-XX) 1 Partial differential equations (35-XX) 1 Dynamical systems and ergodic theory (37-XX) 1 Harmonic analysis on Euclidean spaces (42-XX) 1 Functional analysis (46-XX) 1 Fluid mechanics (76-XX) 1 Geophysics (86-XX)
|
|
## Search Result
### Search Conditions
Years
All Years
for journal 'PTP'
author 'O.* Tanimura' : 6
total : 6
### Search Results : 6 articles were found.
1. Progress of Theoretical Physics Vol. 46 No. 6 (1971) pp. 1738-1748 : (4)
Analysis of $\alpha$-Nucleus Scattering by Regge-Pole Model
Osamu Tanimura
2. Progress of Theoretical Physics Vol. 53 No. 4 (1975) pp. 1006-1021 : (4)
Backward Angle Anomaly in Alpha-Nucleus Scattering and Parity-Dependent Optical Model
Yosio Kondō, Sinobu Nagata, Shigeo Ohkubo and Osamu Tanimura
3. Progress of Theoretical Physics Vol. 99 No. 5 (1998) pp. 783-799 : (3)
Solution with Real Value of Deformation Parameter for Ernst Equation in Gravitational Field Caused by Rotating Source
Osamu Tanimura and Shoichi Hori
4. Progress of Theoretical Physics Vol. 100 No. 3 (1998) pp. 523-533 : (3)
Solution of the Ernst Equation for a Real Value
of the Deformation Parameter
Osamu Tanimura
5. Progress of Theoretical Physics Vol. 101 No. 2 (1999) pp. 329-344 : (3)
A Solution of the Einstein Equation in a Stationary Gravitational Field Due to a Rotating Source
Osamu Tanimura and Shoichi Hori
6. Progress of Theoretical Physics Vol. 102 No. 6 (1999) pp. 1103-1117 : (3)
Complete Solution of the Ernst Equation in a Stationary and Axially Symmetric Gravitational Field Due to a Rotating Source
Osamu Tanimura and Shoichi Hori
|
|
# The equation of line through given conditions.
### Precalculus: Mathematics for Calcu...
6th Edition
Stewart + 5 others
Publisher: Cengage Learning
ISBN: 9780840068071
### Precalculus: Mathematics for Calcu...
6th Edition
Stewart + 5 others
Publisher: Cengage Learning
ISBN: 9780840068071
#### Solutions
Chapter 1, Problem 20T
(a)
To determine
## To find: The equation of line through given conditions.
Expert Solution
The equation of parallel line is 3x+y3=0 .
### Explanation of Solution
Given:
The coordinates of point is (3,6) and parallel to the line is,
3x+y10=0
Formula used:
The formula of slope-intercept form of line is,
y=mx+b
Where
m is slope of line.
b is y-intercept of line.
Calculation:
Solve the given line in slope-intercept form.
y=3x+10 .
Compare the above equation with formula to get the value of slope that is,
m=3 .
Two non-vertical lines are parallel if their slopes are equal so that the slope of parallel line is also 3 .
The point-slope formula of line is,
yy1=m(xx1) .
Substitute 6 for y1 , 3 for x1 and 3 for m in the above equation to get the equation of line,
y(6)=3(x3)y+6=3x+93x+y3=0
Thus, the equation of parallel line is 3x+y3=0 .
(b)
To determine
### To find: The equation of line through given conditions.
Expert Solution
The equation of line is 2x+3y12=0 .
### Explanation of Solution
Given:
The x-intercept of line is 6 and y-intercept is 4.
Calculation:
The intercepts give the two points of line that is (6,0) and (0,4) .
The formula to find the slope of line passes through two given points is,
m=y2y1x2x1 .
In the above formula (x1,y1) and (x2,y2) are two points of line.
Substitute 4 for y2 , 0 for y1 , 0 for x2 and 6 for x1 in above equation to get the slope of line,
m=4006m=46m=23
Use the point-slope form to get the equation of line, and the formula is,
yy1=m(xx1) .
Substitute 0 for y1 , 6 for x1 and 23 for m to get equation for line,
y0=23(x6)3y0=2x+122x+3y12=0
Thus, the equation of line is 2x+3y12=0 .
### Have a homework question?
Subscribe to bartleby learn! Ask subject matter experts 30 homework questions each month. Plus, you’ll have access to millions of step-by-step textbook answers!
|
|
## John H. Johnson Jr.
### The Ohio State University
Welcome to my website A Little Ink!
I’m a mathematician at the Ohio State University. My research interest is on the interplay between the algebraic structure of the Stone–Čech compactification, dynamics, and combinatorics related to Ramsey theory. Connected to this work, I’ve written papers with Vitaly Bergelson, Neil Hindman (my PhD advisor), Joel Moreira, and Florian Karl Richter. See my Publications section for links to these papers.
My teaching interest is centered around using active learning and inclusive practices to promote and cultivate an environment which improves students’ abilities to construct, organize, and demonstrate their knowledge of mathematics. Recently, I’ve been working with my colleague Ranthony A.C. Edmonds developing a new service-learning course based on Margot Lee Sterley’s book Hidden Figures: The American Dream and the Untold Story of the Black Women Mathematicians Who Helped Win the Space Race. I’m also currently serving as PI for the Building a Buckeye Calculus Community as part of Ohio State’s participation as a Phase II institution in SEMINAL (Engagement in Mathematics through an Institutional Network for Active Learning).
Of course, you can get a fuller sense of my professional background via my Curriculum Vitae .
### Interests
• Topological algebra
• Stone–Čech compactification
• Ramsey theory
### Education
• PhD in Mathematics, 2011
Howard University
• BS in Applied Mathematics, 2005
Texas A&M University
Current and Previous
#### The Ohio State University
Sep 2017 – Present Ohio
#### The Ohio State University
Sep 2015 – May 2017 Ohio
#### The Ohio State University
Sep 2012 – May 2015 Ohio
#### Visiting Assistant Professor
Sep 2011 – May 2012 Virginia
# Recent & Upcoming Talks
### Composing some notions of largeness and a classification problem for certain structured sets
Syndetic and thick subsets of a discrete semigroup $S$ are two well-known (and classical) "notions of largeness" that have nice algebraic characterizations in $\beta S$ related to the smallest ideal $K(\beta S)$. Moreover, the connections between these notions of largeness and van der Waerden's theorem on arithmetic progressions are among some of the earliest results in Ramsey Theory.
We'll state generalizations for both syndetic and thick subsets and show how these notions of largeness can be "composed" to produce different (and possibly new) notions of largeness. (The generalization of syndetic subset that we state is due to Shuungula, Zelenyuk, and Zelenyuk, but this notion has appeared, more or less, implicitly if unnamed in the literature connected to the algebraic structure of $\beta S$.) Some of these composite notions are well known, such as piecewise syndetic sets. Other composite notions are trivial, reducing to the collection $\{S\}$. While a few others appear to be new.
We'll sketch a suggestive visualization of these notions, outline the proof of some characterizations of these generalizations, under certain relatively mild conditions, formulate a classification problem, and outline some connections to Ramsey Theory.
### Using Data in STEM Course Redesign
A STEM course redesign project has been implemented to improve retention of students in STEM majors (particularly underrepresented students). The Center for Life Sciences Education focused on Biology 1113 (first semester Intro Bio), with four project components: a summer institute for faculty to learn about student-centered course design; a shared database of active learning resources; peer-led team learning; and embedded undergraduate research experiences. The Department of Mathematics is conducting a redesign of first-year calculus. This project consists of multiple interventions (sections employing active learning, flipped classroom pilots, open access textbooks) viewed through many lenses (including affective surveys and conceptual pre- and post-tests) and development of a framework for the cohesive interaction of the involved faculty and staff. Data that led to redesign of specific STEM courses, the status of these course redesign projects, and recent assessment efforts regarding the success of students in the redesigned courses will be discussed.
# Recent Publications
### Revisiting the nilpotent polynomial Hales--Jewett theorem
Answering a question posed by Bergelson and Leibman in [6], we establish a nilpotent version of the Polynomial Hales–Jewett Theorem that contains the main theorem in [6] as a special case. Important to the formulation and the proof of our main theorem is the notion of a relative syndetic set (relative with respect to a closed non-empty subsets of $\beta\mathbf{G}$) [25]. As a corollary of our main theorem we prove an extension of the restricted van der Waerden Theorem to nilpotent groups, which involves nilprogressions.
### New polynomial and multidimensional extensions of classical partition results
In the 1970s Deuber introduced the notion of $(m,p,c)$-sets in $\mathbb{N}$ and showed that these sets are partition regular and contain all linear partition regular configurations in $\mathbb{N}$. In this paper we obtain enhancements and extensions of classical results on $(m,p,c)$-sets in two directions. First, we show, with the help of ultrafilter techniques, that Deuber's results extend to polynomial configurations in abelian groups. In particular, we obtain new partition regular polynomial configurations in $\mathbb{Z}^d$. Second, we give two proofs of a generalization of Deuber's results to general commutative semigroups.
We also obtain a polynomial version of the central sets theorem of Furstenberg, extend the theory of $(m,p,c)$-systems of Deuber, Hindman and Lefmann and generalize a classical theorem of Rado regarding partition regularity of linear systems of equations over $\mathbb{N}$ to commutative semigroups.
### A new and simpler noncommutative central sets theorem
Using dynamics, Furstenberg defined the concept of a central subset of positive integers and proved several powerful combinatorial properties of central sets. Later using the algebraic structure of the Stone–Čech compactification, Bergelson and Hindman, with the assistance of B. Weiss, generalized the notion of a central set to any semigroup and extended the most important combinatorial property of central sets to the central sets theorem. Currently the most powerful formulation of the central sets theorem is due to De, Hindman, and Strauss in [3, Corollary 3.10]. However their formulation of the central sets theorem for noncommutative semigroups is, compared to their formulation for commutative semigroups, complicated. In this paper I prove a simpler (but still equally strong) version of the noncommutative central sets theorem in Corollary 3.3.
### Images of $$C$$ sets and related large sets under nonhomogeneous spectra
Let $\alpha > 0$ and $0 < \gamma < 1$. Define $g_{\alpha, \gamma} \colon \mathbb{N} \to \mathbb{N}$ by $g_{\alpha, \gamma}(n) = \lfloor \alpha n + \gamma \rfloor$. The set $\{ g_{\alpha, \gamma}(n) {\,:\,} n \in \mathbb{N}\}$ is called the nonhomogeneous spectrum of $\alpha$ and $\gamma$. By extension, we refer to the maps $g_{\alpha, \gamma}$ as spectra. Bergelson, Hindman, and Kra showed that if $A$ is an $IP$-set, a central set, an $IP^*$-set, or a central$^*$-set, then $g_{\alpha, \gamma}[A]$ is the corresponding object. We extend this result to include several other notions of largeness: $C$-sets, $J$-sets, strongly central sets, and piecewise syndetic sets. Of these, $C$-sets are particularly interesting, because they are the sets which satisfy the conclusion of the central sets theorem (and so have many of the strong combinatorial properties of central sets) but have a much simpler elementary description than do central sets.
### A dynamical characterization of $C$ sets
Furstenberg, using tools from topological dynamics, defined the notion of a central subset of positive integers, and proved a powerful combinatorial theorem about such sets. Using the algebraic structure of the Stone-Čech compactification, this combinatorial theorem has been generalized and extended to the Central Sets Theorem. The algebraic techniques also discovered many sets, which are not central, that satisfy the conclusion of the Central Sets Theorem. We call such sets C sets. Since C sets are defined combinatorially, it is natural to ask if this notion admits a dynamical characterization similar to Furstenberg’s original definition of a central set? In this paper we give a positive answer to this question by proving a dynamical characterization of C sets.
|
|
# Maximum Volume
Calculus Level 4
In a hemisphere with radius $$R=\sqrt{3}$$ units is inserted a cuboid with a square base as shown in the picture below. Find the maximum volume of the cuboid in cubic units.
×
|
|
dc.creator Gesenberg, Christoph 2007-08-21T01:46:52Z 2007-08-21T01:46:52Z 1997 https://hdl.handle.net/1911/19162 New synthetic routes leading to 1-vinylcyclopropene and methylenecyclopropene were established making use of the Vacuum Gas-Solid Reaction (VGSR) technique. Both syntheses were planned in a way that allowed the use of solid fluoride as the dehalosilylation inducing reagent in the last step. The decomposition of methylenecyclopropene at temperatures above $-$75$\sp\circ$C was investigated and a dimer of methylenecyclopropene was proposed as the initial decomposition product. Fullerenes have been synthesized and separated using chromatographic techniques. Helium containing isomers of higher fullerenes were analyzed by $\sp3$He NMR spectroscopy and signals were assigned to isomers of C$\sb{76}$, C$\sb{78}$ and C$\sb{84}$. A novel C$\sb{60}$ derivative has been synthesized by the reaction of C$\sb{60}$ with cyclopropa (b) naphthalene and the product of the reaction with $\sp3$He@C$\sb{60}$ revealed the signal of the new compound in the $\sp3$He NMR. Fullerene hydrides $\sp3$He@C$\sb{60}$H$\sb{36}$ and $\sp3$He@C$\sb{60}$H$\sb{18}$ were synthesized by Birch reduction or reaction of $\sp3$He@C$\sb{60}$ with dihydroanthracene and the products were analyzed by $\sp3$He NMR. The spectra revealed one isomer for C$\sb{60}$H$\sb{18}$ and two isomers for C$\sb{60}$H$\sb{36}$. The most intense signal for C$\sb{60}$H$\sb{36}$ was assigned to the isomer with D$\sb{\rm 3d\sp\prime}$ symmetry based on the $\sp3$He NMR chemical shift value. application/pdf eng Organic chemistry Synthesis of cyclopropene derivatives and chemistry of fullerenes Thesis Text Chemistry Natural Sciences Rice University Doctoral Doctor of Philosophy Gesenberg, Christoph. "Synthesis of cyclopropene derivatives and chemistry of fullerenes." (1997) Diss., Rice University. https://hdl.handle.net/1911/19162.
|
|
## Gondzio, Jacek
Compute Distance To:
Author ID: gondzio.jacek Published as: Gondzio, Jacek; Gondzio, J. External Links: MGP
Documents Indexed: 94 Publications since 1986 Co-Authors: 71 Co-Authors with 78 Joint Publications 1,151 Co-Co-Authors
all top 5
### Co-Authors
16 single-authored 9 Grothey, Andreas 6 Pougkakiotis, Spyridon 6 Sarkissian, Robert 6 Vial, Jean-Philippe 5 Bellavia, Stefania 5 Fragnière, Emmanuel 5 Woodsend, Kristian 4 Bergamaschi, Luca 4 Colombo, Marco 4 Fountoulakis, Kimon 4 García, Sergio 4 González-Brevis, Pablo 4 Kalcsics, Jörg 4 Munari, Pedro Augusto 4 Pearson, John W. 3 Altman, Anna 3 Delorme, Maxence 3 Manlove, David F. 3 Morini, Benedetta 3 Pettersson, William 3 Zilli, Giovanni 2 Al-Jeiroudi, Ghussoun 2 Hogg, Jonathan D. 2 Kouwenberg, Roy 2 Mészáros, Csaba 2 Porcelli, Margherita 2 Ruszczyński, Andrzej 2 Schork, Lukas 2 Venturin, Manolo 1 Andersen, Erling D. 1 Barkhagen, Mathias 1 Chung, Pei-Jung 1 Dassios, Ioannis K. 1 De Simone, Valentina 1 di Serafino, Daniela 1 Du, Huiqin 1 Ezhov, Vladimir Vladimirovich 1 Filar, Jerzy A. 1 Goffin, Jean-Louis 1 Gonçalves, João P. M. 1 Gruca, Jacek A. 1 Hall, J. A. Julian 1 Hall, Julian 1 Kroeske, J. 1 Laskowski, Wiesław 1 Lassas, Matti J. 1 Latva-Äijö, Salla-Maaria 1 Leveque, Santolo 1 Makowski, Marek S. 1 Martínez, Ángeles 1 Nabona, Narcís 1 Pagès, Adela 1 Richtárik, Peter 1 Sabanis, Sotirios 1 Siltanen, Samuli 1 Sobral, F. N. C. 1 Staal, Andrew P. 1 Storer, Robert H. 1 Tachat, Dominique 1 Tappenden, Rachael 1 Terlaky, Tamás 1 Trimble, James 1 Viola, Marco 1 Vorst, Ton C. F. 1 Weldeyesus, Alemseged Gebrehiwot 1 Xu, Xiaojie 1 Yang, Xi 1 Yildirim, Emre Alper 1 Zanetti, Filippo 1 Zhlobich, Pavel 1 Żukowski, Marek
all top 5
### Serials
13 Computational Optimization and Applications 11 European Journal of Operational Research 7 Mathematical Programming. Series A. Series B 5 Journal of Optimization Theory and Applications 4 Mathematical Programming Computation 3 Control and Cybernetics 3 Optimization 3 Computers & Operations Research 3 Annals of Operations Research 3 Journal of Global Optimization 3 SIAM Journal on Optimization 3 Numerical Linear Algebra with Applications 3 Optimization Methods & Software 2 SIAM Journal on Scientific Computing 2 INFORMS Journal on Computing 1 Inverse Problems 1 Journal of Computational and Applied Mathematics 1 Management Science 1 Numerische Mathematik 1 Operations Research 1 RAIRO. Recherche Opérationnelle 1 Journal of Economic Dynamics & Control 1 SIAM Journal on Matrix Analysis and Applications 1 Journal of Scientific Computing 1 IEEE Transactions on Signal Processing 1 ORSA Journal on Computing 1 Linear Algebra and its Applications 1 SIAM Review 1 Archives of Control Sciences 1 Journal of Machine Learning Research (JMLR) 1 Computational Management Science
all top 5
### Fields
86 Operations research, mathematical programming (90-XX) 29 Numerical analysis (65-XX) 6 Computer science (68-XX) 6 Game theory, economics, finance, and other social and behavioral sciences (91-XX) 5 Calculus of variations and optimal control; optimization (49-XX) 5 Systems theory; control (93-XX) 2 Information and communication theory, circuits (94-XX) 1 History and biography (01-XX) 1 Combinatorics (05-XX) 1 Linear and multilinear algebra; matrix theory (15-XX) 1 Partial differential equations (35-XX) 1 Statistics (62-XX) 1 Mechanics of deformable solids (74-XX) 1 Quantum theory (81-XX)
### Citations contained in zbMATH Open
80 Publications have been cited 1,051 times in 584 Documents Cited by Year
Interior point methods 25 years later. Zbl 1244.90007
Gondzio, Jacek
2012
Preconditioning indefinite systems in interior point methods for optimization. Zbl 1056.90137
Bergamaschi, Luca; Gondzio, Jacek; Zilli, Giovanni
2004
Multiple centrality corrections in a primal-dual method for linear programming. Zbl 0860.90084
Gondzio, Jacek
1996
Implementation of interior-point methods for large scale linear programs. Zbl 0874.90127
Andersen, Erling D.; Gondzio, Jacek; Mészáros, Csaba; Xu, Xiaojie
1996
Regularized symmetric indefinite systems in interior point methods for linear and quadratic optimization. Zbl 0957.90101
Altman, Anna; Gondzio, Jacek
1999
HOPDM (version 2. 12) – a fast LP solver based on a primal-dual interior point method. Zbl 0925.90284
Gondzio, Jacek
1995
Matrix-free interior point method. Zbl 1241.90179
Gondzio, Jacek
2012
Solving nonlinear multicommodity flow problems by the analytic center cutting plane method. Zbl 0881.90050
Goffin, J.-L.; Gondzio, J.; Sarkissian, R.; Vial, J.-P.
1997
Parallel interior-point solver for structured linear programs. Zbl 1023.90039
Gondzio, Jacek; Sarkissian, Robert
2003
Inexact constraint preconditioners for linear systems arising in interior point methods. Zbl 1148.90349
Bergamaschi, Luca; Gondzio, Jacek; Venturin, Manolo; Zilli, Giovanni
2007
New developments in the primal-dual column generation technique. Zbl 1292.90318
Gondzio, Jacek; González-Brevis, Pablo; Munari, Pedro
2013
Warm start of the primal-dual method applied in the cutting-plane scheme. Zbl 0920.90102
Gondzio, Jacek
1998
High-performance computing for asset-liability management. Zbl 1163.90548
Gondzio, Jacek; Kouwenberg, Roy
2001
Presolve analysis of linear programs prior to applying an interior point method. Zbl 0890.90143
Gondzio, Jacek
1997
Reoptimization with the primal-dual interior point method. Zbl 1101.90401
Gondzio, Jacek; Grothey, Andreas
2003
Further development of multiple centrality correctors for interior point methods. Zbl 1168.90643
Colombo, Marco; Gondzio, Jacek
2008
Inexact coordinate descent: complexity and preconditioning. Zbl 1350.65062
Tappenden, Rachael; Richtárik, Peter; Gondzio, Jacek
2016
Parallel interior-point solver for structured quadratic programs: Application to financial planning problems. Zbl 1144.90510
Gondzio, Jacek; Grothey, Andreas
2007
Using the primal-dual interior point algorithm within the branch-price-and-cut method. Zbl 1348.90478
Munari, Pedro; Gondzio, Jacek
2013
A second-order method for strongly convex $$\ell _1$$-regularization problems. Zbl 1364.90255
Fountoulakis, Kimon; Gondzio, Jacek
2016
A new unblocking technique to warmstart interior point methods based on sensitivity analysis. Zbl 1177.90411
Gondzio, Jacek; Grothey, Andreas
2008
Matrix-free interior point method for compressed sensing problems. Zbl 1304.90137
Fountoulakis, Kimon; Gondzio, Jacek; Zhlobich, Pavel
2014
Exploiting structure in parallel implementation of interior point methods for optimization. Zbl 1170.90518
Gondzio, Jacek; Grothey, Andreas
2009
Solving nonlinear portfolio optimization problems with the primal-dual interior point method. Zbl 1121.90117
Gondzio, Jacek; Grothey, Andreas
2007
A preconditioner for a primal-dual Newton conjugate gradient method for compressed sensing problems. Zbl 1371.65049
Dassios, Ioannis; Fountoulakis, Kimon; Gondzio, Jacek
2015
Convergence analysis of an inexact feasible interior point method for convex quadratic programming. Zbl 1286.65075
Gondzio, Jacek
2013
Preconditioning indefinite systems in interior point methods for large scale linear optimisation. Zbl 1162.90510
Al-Jeiroudi, Ghussoun; Gondzio, Jacek; Hall, Julian
2008
A matrix-free preconditioner for sparse symmetric positive definite systems and least-squares problems. Zbl 1264.65036
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2013
Large-scale optimization with the primal-dual column generation method. Zbl 1334.90072
Gondzio, Jacek; González-Brevis, Pablo; Munari, Pedro
2016
Direct solution of linear systems of size $$10^{9}$$ arising in optimization with interior point methods. Zbl 1182.65050
Gondzio, Jacek; Grothey, Andreas
2006
Hedging options under transaction costs and stochastic volatility. Zbl 1178.91196
Gondzio, Jacek; Kouwenberg, Roy; Vorst, Ton
2003
Fast interior point solution of quadratic programming problems arising from PDE-constrained optimization. Zbl 1379.65042
Pearson, John W.; Gondzio, Jacek
2017
Building and solving large-scale stochastic programs on an affordable distributed computing system. Zbl 0990.90083
Fragnière, Emmanuel; Gondzio, Jacek; Vial, Jean-Philippe
2000
Hybrid MPI/OpenMP parallel linear support vector machine training. Zbl 1235.68205
Woodsend, Kristian; Gondzio, Jacek
2009
Warm start and $$\varepsilon$$-subgradients in a cutting plane scheme for block-angular linear programs. Zbl 0958.90057
Gondzio, J.; Vial, J.-P.
1999
Using an interior point method for the master problem in a decomposition approach. Zbl 0916.90220
Gondzio, J.; Sarkissian, R.; Vial, J.-P.
1997
A computational view of interior point methods. Zbl 1010.90524
Gondzio, Jacek; Terlaky, Tamás
1996
A warm-start approach for large-scale stochastic linear programs. Zbl 1216.90063
Colombo, Marco; Gondzio, Jacek; Grothey, Andreas
2011
An efficient implementation of a higher order primal-dual interior point method for large sparse linear programs. Zbl 0799.90083
Altman, Anna; Gondzio, Jacek
1993
Performance of first- and second-order methods for $$\ell_1$$-regularized least squares problems. Zbl 1357.90107
Fountoulakis, Kimon; Gondzio, Jacek
2016
Exploiting separability in large-scale linear support vector machine training. Zbl 1219.90210
Woodsend, Kristian; Gondzio, Jacek
2011
Mathematical models for stable matching problems with ties and incomplete lists. Zbl 1431.91252
Delorme, Maxence; García, Sergio; Gondzio, Jacek; Kalcsics, Jörg; Manlove, David; Pettersson, William
2019
Splitting dense columns of constraint matrix in interior point methods for large scale linear programming. Zbl 0814.65056
Gondzio, J.
1992
Implementing Cholesky factorization for interior point methods of linear programming. Zbl 0819.65097
Gondzio, J.
1993
Convergence analysis of the inexact infeasible interior-point method for linear optimization. Zbl 1176.90647
Al-Jeiroudi, G.; Gondzio, J.
2009
A structure-conveying modelling language for mathematical and stochastic programming. Zbl 1191.68140
Colombo, Marco; Grothey, Andreas; Hogg, Jonathan; Woodsend, Kristian; Gondzio, Jacek
2009
A structure-exploiting tool in algebraic modeling languages. Zbl 1232.90307
Fragnière, Emmanuel; Gondzio, Jacek; Sarkissian, Robert; Vial, Jean-Philippe
2000
HOPDM - a higher order primal-dual method for large scale linear programming. Zbl 0775.90285
Altman, Anna; Gondzio, Jacek
1993
An interior point heuristic for the Hamiltonian cycle problem via Markov decision processes. Zbl 1133.90413
Ejov, Vladimir; Filar, Jerzy; Gondzio, Jacek
2004
An interior point-proximal method of multipliers for convex quadratic programming. Zbl 1469.90158
Pougkakiotis, Spyridon; Gondzio, Jacek
2021
Regularization and preconditioning of KKT systems arising in nonnegative least-squares problems. Zbl 1224.65151
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2009
An inexact dual logarithmic barrier method for solving sparse semidefinite programs. Zbl 1431.90108
Bellavia, Stefania; Gondzio, Jacek; Porcelli, Margherita
2019
Dynamic non-diagonal regularization in interior point methods for linear and convex quadratic programming. Zbl 1420.90082
Pougkakiotis, Spyridon; Gondzio, Jacek
2019
Erratum to: Inexact constraint preconditioners for linear systems arising in interior point methods. Zbl 1279.90192
Bergamaschi, Luca; Gondzio, Jacek; Venturin, Manolo; Zilli, Giovanni
2011
Operations risk management by optimally planning the qualified workforce capacity. Zbl 1175.90250
Fragnière, Emmanuel; Gondzio, Jacek; Yang, Xi
2010
A family of linear programming algorithms based on an algorithm by von Neumann. Zbl 1169.90397
Gonçalves, João P. M.; Storer, Robert H.; Gondzio, Jacek
2009
A new warmstarting strategy for the primal-dual column generation method. Zbl 1327.90389
Gondzio, Jacek; González-Brevis, Pablo
2015
Stable algorithm for updating dense LU factorization after row or column exchange and row and column addition or deletion. Zbl 0814.65029
Gondzio, J.
1992
Parallel implementation of a central decomposition method for solving large-scale planning problems. Zbl 1064.90025
Gondzio, J.; Sarkissian, R.; Vial, J.-Ph.
2001
Another simplex-type method for large scale linear programming. Zbl 0865.90092
Gondzio, Jacek
1996
A new preconditioning approach for an interior point-proximal method of multipliers for linear and convex quadratic programming. Zbl 07396244
Bergamaschi, Luca; Gondzio, Jacek; Martínez, Ángeles; Pearson, John W.; Pougkakiotis, Spyridon
2021
A relaxed interior point method for low-rank semidefinite programming problems with applications to matrix completion. Zbl 1479.90152
Bellavia, Stefania; Gondzio, Jacek; Porcelli, Margherita
2021
Sensitivity method for basis inverse representation in multistage stochastic linear programming problems. Zbl 0795.90045
Gondzio, J.; Ruszczyński, A.
1992
A structure conveying parallelizable modeling language for mathematical programming. Zbl 1156.65311
Grothey, Andreas; Hogg, Jonathan; Woodsend, Kristian; Colombo, Marco; Gondzio, Jacek
2009
Quasi-Newton approaches to interior point methods for quadratic problems. Zbl 1427.90290
Gondzio, J.; Sobral, F. N. C.
2019
Solving a class of LP problems with a primal-dual logarithmic barrier method. Zbl 0928.90064
Gondzio, Jacek; Makowski, Marek
1995
The design and application of IPMLO. A Fortran library for linear optimization with interior point methods. Zbl 0860.90085
Gondzio, J.; Tachat, D.
1994
Simplex modifications exploiting special features of dynamic and stochastic dynamic linear programming problems. Zbl 0682.90095
Gondzio, Jacek
1988
Global solutions of nonconvex standard quadratic programs via mixed integer linear programming reformulations. Zbl 07403110
Gondzio, Jacek; Yıldırım, E. Alper
2021
Addendum to “Presolve analysis of linear programs prior to applying an interior point method”. Zbl 1238.90095
Mészáros, Csaba; Gondzio, Jacek
2001
Computational experience with numerical methods for nonnegative least-squares problems. Zbl 1249.65080
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2011
A sensitivity method for solving multistage stochastic linear programming problems. Zbl 0759.90075
Gondzio, Jacek; Ruszczynski, Andrzej
1989
Solving large-scale optimization problems related to Bell’s theorem. Zbl 1293.81011
Gondzio, Jacek; Gruca, Jacek A.; Hall, J. A. Julian; Laskowski, Wiesław; Żukowski, Marek
2014
On exploiting original problem data in the inverse representation of linear programming bases. Zbl 0806.90083
Gondzio, Jacek
1994
High-performance parallel support vector machine training. Zbl 1183.68117
Woodsend, Kristian; Gondzio, Jacek
2009
Warmstarting for interior point methods applied to the long-term power planning problem. Zbl 1157.90498
Pagès, Adela; Gondzio, Jacek; Nabona, Narcís
2009
A probabilistic constraint approach for robust transmit beamforming with imperfect channel information. Zbl 1392.94805
Chung, Pei-Jung; Du, Huiqin; Gondzio, Jacek
2011
On block triangular preconditioners for the interior point solution of PDE-constrained optimization problems. Zbl 1450.65175
Pearson, John W.; Gondzio, Jacek
2018
A specialized primal-dual interior point method for the plastic truss layout optimization. Zbl 1404.74138
Weldeyesus, Alemseged Gebrehiwot; Gondzio, Jacek
2018
A note on the primal-dual column generation method for combinatorial optimization. Zbl 1268.90069
Munari, Pedro; González-Brevis, Pablo; Gondzio, Jacek
2011
An interior point-proximal method of multipliers for convex quadratic programming. Zbl 1469.90158
Pougkakiotis, Spyridon; Gondzio, Jacek
2021
A new preconditioning approach for an interior point-proximal method of multipliers for linear and convex quadratic programming. Zbl 07396244
Bergamaschi, Luca; Gondzio, Jacek; Martínez, Ángeles; Pearson, John W.; Pougkakiotis, Spyridon
2021
A relaxed interior point method for low-rank semidefinite programming problems with applications to matrix completion. Zbl 1479.90152
Bellavia, Stefania; Gondzio, Jacek; Porcelli, Margherita
2021
Global solutions of nonconvex standard quadratic programs via mixed integer linear programming reformulations. Zbl 07403110
Gondzio, Jacek; Yıldırım, E. Alper
2021
Mathematical models for stable matching problems with ties and incomplete lists. Zbl 1431.91252
Delorme, Maxence; García, Sergio; Gondzio, Jacek; Kalcsics, Jörg; Manlove, David; Pettersson, William
2019
An inexact dual logarithmic barrier method for solving sparse semidefinite programs. Zbl 1431.90108
Bellavia, Stefania; Gondzio, Jacek; Porcelli, Margherita
2019
Dynamic non-diagonal regularization in interior point methods for linear and convex quadratic programming. Zbl 1420.90082
Pougkakiotis, Spyridon; Gondzio, Jacek
2019
Quasi-Newton approaches to interior point methods for quadratic problems. Zbl 1427.90290
Gondzio, J.; Sobral, F. N. C.
2019
On block triangular preconditioners for the interior point solution of PDE-constrained optimization problems. Zbl 1450.65175
Pearson, John W.; Gondzio, Jacek
2018
A specialized primal-dual interior point method for the plastic truss layout optimization. Zbl 1404.74138
Weldeyesus, Alemseged Gebrehiwot; Gondzio, Jacek
2018
Fast interior point solution of quadratic programming problems arising from PDE-constrained optimization. Zbl 1379.65042
Pearson, John W.; Gondzio, Jacek
2017
Inexact coordinate descent: complexity and preconditioning. Zbl 1350.65062
Tappenden, Rachael; Richtárik, Peter; Gondzio, Jacek
2016
A second-order method for strongly convex $$\ell _1$$-regularization problems. Zbl 1364.90255
Fountoulakis, Kimon; Gondzio, Jacek
2016
Large-scale optimization with the primal-dual column generation method. Zbl 1334.90072
Gondzio, Jacek; González-Brevis, Pablo; Munari, Pedro
2016
Performance of first- and second-order methods for $$\ell_1$$-regularized least squares problems. Zbl 1357.90107
Fountoulakis, Kimon; Gondzio, Jacek
2016
A preconditioner for a primal-dual Newton conjugate gradient method for compressed sensing problems. Zbl 1371.65049
Dassios, Ioannis; Fountoulakis, Kimon; Gondzio, Jacek
2015
A new warmstarting strategy for the primal-dual column generation method. Zbl 1327.90389
Gondzio, Jacek; González-Brevis, Pablo
2015
Matrix-free interior point method for compressed sensing problems. Zbl 1304.90137
Fountoulakis, Kimon; Gondzio, Jacek; Zhlobich, Pavel
2014
Solving large-scale optimization problems related to Bell’s theorem. Zbl 1293.81011
Gondzio, Jacek; Gruca, Jacek A.; Hall, J. A. Julian; Laskowski, Wiesław; Żukowski, Marek
2014
New developments in the primal-dual column generation technique. Zbl 1292.90318
Gondzio, Jacek; González-Brevis, Pablo; Munari, Pedro
2013
Using the primal-dual interior point algorithm within the branch-price-and-cut method. Zbl 1348.90478
Munari, Pedro; Gondzio, Jacek
2013
Convergence analysis of an inexact feasible interior point method for convex quadratic programming. Zbl 1286.65075
Gondzio, Jacek
2013
A matrix-free preconditioner for sparse symmetric positive definite systems and least-squares problems. Zbl 1264.65036
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2013
Interior point methods 25 years later. Zbl 1244.90007
Gondzio, Jacek
2012
Matrix-free interior point method. Zbl 1241.90179
Gondzio, Jacek
2012
A warm-start approach for large-scale stochastic linear programs. Zbl 1216.90063
Colombo, Marco; Gondzio, Jacek; Grothey, Andreas
2011
Exploiting separability in large-scale linear support vector machine training. Zbl 1219.90210
Woodsend, Kristian; Gondzio, Jacek
2011
Erratum to: Inexact constraint preconditioners for linear systems arising in interior point methods. Zbl 1279.90192
Bergamaschi, Luca; Gondzio, Jacek; Venturin, Manolo; Zilli, Giovanni
2011
Computational experience with numerical methods for nonnegative least-squares problems. Zbl 1249.65080
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2011
A probabilistic constraint approach for robust transmit beamforming with imperfect channel information. Zbl 1392.94805
Chung, Pei-Jung; Du, Huiqin; Gondzio, Jacek
2011
A note on the primal-dual column generation method for combinatorial optimization. Zbl 1268.90069
Munari, Pedro; González-Brevis, Pablo; Gondzio, Jacek
2011
Operations risk management by optimally planning the qualified workforce capacity. Zbl 1175.90250
Fragnière, Emmanuel; Gondzio, Jacek; Yang, Xi
2010
Exploiting structure in parallel implementation of interior point methods for optimization. Zbl 1170.90518
Gondzio, Jacek; Grothey, Andreas
2009
Hybrid MPI/OpenMP parallel linear support vector machine training. Zbl 1235.68205
Woodsend, Kristian; Gondzio, Jacek
2009
Convergence analysis of the inexact infeasible interior-point method for linear optimization. Zbl 1176.90647
Al-Jeiroudi, G.; Gondzio, J.
2009
A structure-conveying modelling language for mathematical and stochastic programming. Zbl 1191.68140
Colombo, Marco; Grothey, Andreas; Hogg, Jonathan; Woodsend, Kristian; Gondzio, Jacek
2009
Regularization and preconditioning of KKT systems arising in nonnegative least-squares problems. Zbl 1224.65151
Bellavia, Stefania; Gondzio, Jacek; Morini, Benedetta
2009
A family of linear programming algorithms based on an algorithm by von Neumann. Zbl 1169.90397
Gonçalves, João P. M.; Storer, Robert H.; Gondzio, Jacek
2009
A structure conveying parallelizable modeling language for mathematical programming. Zbl 1156.65311
Grothey, Andreas; Hogg, Jonathan; Woodsend, Kristian; Colombo, Marco; Gondzio, Jacek
2009
High-performance parallel support vector machine training. Zbl 1183.68117
Woodsend, Kristian; Gondzio, Jacek
2009
Warmstarting for interior point methods applied to the long-term power planning problem. Zbl 1157.90498
Pagès, Adela; Gondzio, Jacek; Nabona, Narcís
2009
Further development of multiple centrality correctors for interior point methods. Zbl 1168.90643
Colombo, Marco; Gondzio, Jacek
2008
A new unblocking technique to warmstart interior point methods based on sensitivity analysis. Zbl 1177.90411
Gondzio, Jacek; Grothey, Andreas
2008
Preconditioning indefinite systems in interior point methods for large scale linear optimisation. Zbl 1162.90510
Al-Jeiroudi, Ghussoun; Gondzio, Jacek; Hall, Julian
2008
Inexact constraint preconditioners for linear systems arising in interior point methods. Zbl 1148.90349
Bergamaschi, Luca; Gondzio, Jacek; Venturin, Manolo; Zilli, Giovanni
2007
Parallel interior-point solver for structured quadratic programs: Application to financial planning problems. Zbl 1144.90510
Gondzio, Jacek; Grothey, Andreas
2007
Solving nonlinear portfolio optimization problems with the primal-dual interior point method. Zbl 1121.90117
Gondzio, Jacek; Grothey, Andreas
2007
Direct solution of linear systems of size $$10^{9}$$ arising in optimization with interior point methods. Zbl 1182.65050
Gondzio, Jacek; Grothey, Andreas
2006
Preconditioning indefinite systems in interior point methods for optimization. Zbl 1056.90137
Bergamaschi, Luca; Gondzio, Jacek; Zilli, Giovanni
2004
An interior point heuristic for the Hamiltonian cycle problem via Markov decision processes. Zbl 1133.90413
Ejov, Vladimir; Filar, Jerzy; Gondzio, Jacek
2004
Parallel interior-point solver for structured linear programs. Zbl 1023.90039
Gondzio, Jacek; Sarkissian, Robert
2003
Reoptimization with the primal-dual interior point method. Zbl 1101.90401
Gondzio, Jacek; Grothey, Andreas
2003
Hedging options under transaction costs and stochastic volatility. Zbl 1178.91196
Gondzio, Jacek; Kouwenberg, Roy; Vorst, Ton
2003
High-performance computing for asset-liability management. Zbl 1163.90548
Gondzio, Jacek; Kouwenberg, Roy
2001
Parallel implementation of a central decomposition method for solving large-scale planning problems. Zbl 1064.90025
Gondzio, J.; Sarkissian, R.; Vial, J.-Ph.
2001
Addendum to “Presolve analysis of linear programs prior to applying an interior point method”. Zbl 1238.90095
Mészáros, Csaba; Gondzio, Jacek
2001
Building and solving large-scale stochastic programs on an affordable distributed computing system. Zbl 0990.90083
Fragnière, Emmanuel; Gondzio, Jacek; Vial, Jean-Philippe
2000
A structure-exploiting tool in algebraic modeling languages. Zbl 1232.90307
Fragnière, Emmanuel; Gondzio, Jacek; Sarkissian, Robert; Vial, Jean-Philippe
2000
Regularized symmetric indefinite systems in interior point methods for linear and quadratic optimization. Zbl 0957.90101
Altman, Anna; Gondzio, Jacek
1999
Warm start and $$\varepsilon$$-subgradients in a cutting plane scheme for block-angular linear programs. Zbl 0958.90057
Gondzio, J.; Vial, J.-P.
1999
Warm start of the primal-dual method applied in the cutting-plane scheme. Zbl 0920.90102
Gondzio, Jacek
1998
Solving nonlinear multicommodity flow problems by the analytic center cutting plane method. Zbl 0881.90050
Goffin, J.-L.; Gondzio, J.; Sarkissian, R.; Vial, J.-P.
1997
Presolve analysis of linear programs prior to applying an interior point method. Zbl 0890.90143
Gondzio, Jacek
1997
Using an interior point method for the master problem in a decomposition approach. Zbl 0916.90220
Gondzio, J.; Sarkissian, R.; Vial, J.-P.
1997
Multiple centrality corrections in a primal-dual method for linear programming. Zbl 0860.90084
Gondzio, Jacek
1996
Implementation of interior-point methods for large scale linear programs. Zbl 0874.90127
Andersen, Erling D.; Gondzio, Jacek; Mészáros, Csaba; Xu, Xiaojie
1996
A computational view of interior point methods. Zbl 1010.90524
Gondzio, Jacek; Terlaky, Tamás
1996
Another simplex-type method for large scale linear programming. Zbl 0865.90092
Gondzio, Jacek
1996
HOPDM (version 2. 12) – a fast LP solver based on a primal-dual interior point method. Zbl 0925.90284
Gondzio, Jacek
1995
Solving a class of LP problems with a primal-dual logarithmic barrier method. Zbl 0928.90064
Gondzio, Jacek; Makowski, Marek
1995
The design and application of IPMLO. A Fortran library for linear optimization with interior point methods. Zbl 0860.90085
Gondzio, J.; Tachat, D.
1994
On exploiting original problem data in the inverse representation of linear programming bases. Zbl 0806.90083
Gondzio, Jacek
1994
An efficient implementation of a higher order primal-dual interior point method for large sparse linear programs. Zbl 0799.90083
Altman, Anna; Gondzio, Jacek
1993
Implementing Cholesky factorization for interior point methods of linear programming. Zbl 0819.65097
Gondzio, J.
1993
HOPDM - a higher order primal-dual method for large scale linear programming. Zbl 0775.90285
Altman, Anna; Gondzio, Jacek
1993
Splitting dense columns of constraint matrix in interior point methods for large scale linear programming. Zbl 0814.65056
Gondzio, J.
1992
Stable algorithm for updating dense LU factorization after row or column exchange and row and column addition or deletion. Zbl 0814.65029
Gondzio, J.
1992
Sensitivity method for basis inverse representation in multistage stochastic linear programming problems. Zbl 0795.90045
Gondzio, J.; Ruszczyński, A.
1992
A sensitivity method for solving multistage stochastic linear programming problems. Zbl 0759.90075
Gondzio, Jacek; Ruszczynski, Andrzej
1989
Simplex modifications exploiting special features of dynamic and stochastic dynamic linear programming problems. Zbl 0682.90095
Gondzio, Jacek
1988
all top 5
### Cited by 1,007 Authors
50 Gondzio, Jacek 18 Oliveira, Aurelio Ribeiro Leite 14 Castro, Jordi 11 Bergamaschi, Luca 11 Morini, Benedetta 10 Terlaky, Tamás 9 Mészáros, Csaba 9 Munari, Pedro Augusto 8 Bellavia, Stefania 8 De Simone, Valentina 8 di Serafino, Daniela 7 Grothey, Andreas 7 Roos, Cornelis 6 Carrizosa, Emilio 6 Ferronato, Massimiliano 6 Orban, Dominique 6 Porcelli, Margherita 6 Richtárik, Peter 6 Romero Morales, Dolores 6 Toh, Kim Chuan 5 Altman, Anna 5 Blomvall, Jörgen 5 Fountoulakis, Kimon 5 González-Lima, María D. 5 Haeser, Gabriel 5 Pearson, John W. 5 Petra, Cosmin G. 5 Samaras, Nikolaos 5 Simoncini, Valeria 5 Vial, Jean-Philippe 5 Ye, Yinyu 4 Anjos, Miguel F. 4 Colombo, Marco 4 Cuesta, Jordi 4 D’Apuzzo, Marco 4 El Ghami, Mohamed 4 Frangioni, Antonio 4 Gambolati, Giuseppe 4 Kanno, Yoshihiro 4 Lubin, Miles 4 Lyra Filho, Christiano 4 Martínez, Ángeles 4 Nasini, Stefano 4 Nocedal, Jorge 4 Ouorou, Adam 4 Peng, Jiming 4 Pougkakiotis, Spyridon 4 Qiu, Songqiang 4 Rinaldi, Francesco 4 Ruszczyński, Andrzej 4 Sun, Defeng 4 Tappenden, Rachael 4 Zavala, Victor M. 3 Anitescu, Mihai 3 Armand, Paul 3 Bai, Yanqin 3 Bocanegra, Silvana 3 Caboussat, Alexandre 3 Cafieri, Sonia 3 Cheng, Wanyou 3 Curtis, Frank E. 3 Dai, Yu-Hong 3 Elhedhli, Samir 3 Engau, Alexander 3 Fábián, Csaba I. 3 Fasano, Giovanni 3 Filar, Jerzy A. 3 Gaudioso, Manlio 3 González-Brevis, Pablo 3 Gorgone, Enrico 3 Gould, Nicholas Ian Mark 3 Guerrero, Vanesa 3 Hall, J. A. Julian 3 Kalinowski, Thomas 3 Kiwiel, Krzysztof Czesław 3 Kouwenberg, Roy 3 Li, Xudong 3 Lindberg, Per Olov 3 Liu, Changhe 3 Liu, Hongwei 3 Lupuleac, Sergey 3 Makowski, Marek S. 3 Molero-Río, Cristina 3 Morabito, Reinaldo 3 Naoum-Sawaya, Joe 3 Ortega, Fernando 3 Paparrizos, Konstantinos 3 Park, Soondal 3 Porumbel, Daniel Cosmin 3 Robinson, Daniel P. 3 Roma, Massimo 3 Salahi, Maziar 3 Santos, Luiz-Rafael 3 Schmidt, Martin 3 Stanimirović, Predrag S. 3 Stefanova, Maria 3 Steihaug, Trond 3 Stojković, Nebojša V. 3 Takáč, Martin 3 Wang, Guoqiang ...and 907 more Authors
all top 5
### Cited in 124 Serials
69 Computational Optimization and Applications 64 European Journal of Operational Research 33 Mathematical Programming. Series A. Series B 33 Optimization Methods & Software 23 Computers & Operations Research 23 Annals of Operations Research 20 Journal of Optimization Theory and Applications 15 Mathematical Programming Computation 13 Journal of Computational and Applied Mathematics 13 SIAM Journal on Optimization 10 Journal of Global Optimization 9 Optimization Letters 8 SIAM Journal on Scientific Computing 7 Computer Methods in Applied Mechanics and Engineering 7 Journal of Computational Physics 7 Applied Mathematics and Computation 7 Optimization 7 INFORMS Journal on Computing 7 Optimization and Engineering 6 Operations Research Letters 6 Numerical Algorithms 6 Mathematical Methods of Operations Research 6 Quantitative Finance 6 Computational Management Science 5 Linear Algebra and its Applications 5 Top 4 Automatica 4 Mathematics of Operations Research 4 Applied Numerical Mathematics 4 SIAM Journal on Matrix Analysis and Applications 4 Multidimensional Systems and Signal Processing 4 International Journal of Computer Mathematics 4 Numerical Linear Algebra with Applications 4 RAIRO. Operations Research 3 Computers & Mathematics with Applications 3 International Journal of Control 3 Information Sciences 3 Nonlinear Analysis. Theory, Methods & Applications. Series A: Theory and Methods 3 Numerische Mathematik 3 Journal of Economic Dynamics & Control 3 Neural Computation 3 4OR 3 Annali dell’Università di Ferrara. Sezione VII. Scienze Matematiche 3 EURO Journal on Computational Optimization 3 SN Operations Research Forum 2 Discrete Applied Mathematics 2 Journal of the Franklin Institute 2 Calcolo 2 Computing 2 Journal of Scientific Computing 2 SIAM Review 2 Computational and Applied Mathematics 2 CEJOR. Central European Journal of Operations Research 2 Dynamics of Continuous, Discrete & Impulsive Systems. Series A. Mathematical Analysis 2 Journal of Machine Learning Research (JMLR) 2 JMMA. Journal of Mathematical Modelling and Algorithms 2 Journal of Applied Mathematics and Computing 2 European Series in Applied and Industrial Mathematics (ESAIM): Mathematical Modelling and Numerical Analysis 2 Set-Valued and Variational Analysis 2 Statistics and Computing 2 Axioms 1 Acta Mechanica 1 Artificial Intelligence 1 Computer Physics Communications 1 International Journal of Systems Science 1 Inverse Problems 1 Linear and Multilinear Algebra 1 Periodica Mathematica Hungarica 1 Mathematics of Computation 1 International Journal for Numerical Methods in Engineering 1 Journal of Applied Probability 1 Journal of Computer and System Sciences 1 Journal of Multivariate Analysis 1 Mathematics and Computers in Simulation 1 Networks 1 Operations Research 1 SIAM Journal on Numerical Analysis 1 Circuits, Systems, and Signal Processing 1 ACM Transactions on Graphics 1 Constructive Approximation 1 Applied Mathematics Letters 1 Mathematical and Computer Modelling 1 Machine Learning 1 Japan Journal of Industrial and Applied Mathematics 1 Computational Geometry 1 Applied Mathematical Modelling 1 Pattern Recognition 1 Journal of Mathematical Imaging and Vision 1 Applied and Computational Harmonic Analysis 1 Advances in Computational Mathematics 1 Revista Investigación Operacional 1 Constraints 1 Vietnam Journal of Mathematics 1 Journal of Inequalities and Applications 1 Journal of Shanghai University 1 International Journal of Applied Mathematics and Computer Science 1 Far East Journal of Mathematical Sciences 1 Dynamics of Continuous, Discrete & Impulsive Systems. Series B. Applications & Algorithms 1 Journal of Applied Mathematics 1 OR Spectrum ...and 24 more Serials
all top 5
### Cited in 30 Fields
485 Operations research, mathematical programming (90-XX) 171 Numerical analysis (65-XX) 48 Game theory, economics, finance, and other social and behavioral sciences (91-XX) 47 Calculus of variations and optimal control; optimization (49-XX) 42 Computer science (68-XX) 16 Statistics (62-XX) 16 Mechanics of deformable solids (74-XX) 14 Systems theory; control (93-XX) 13 Information and communication theory, circuits (94-XX) 9 Linear and multilinear algebra; matrix theory (15-XX) 8 Combinatorics (05-XX) 8 Partial differential equations (35-XX) 7 Probability theory and stochastic processes (60-XX) 7 Fluid mechanics (76-XX) 7 Biology and other natural sciences (92-XX) 4 History and biography (01-XX) 4 Number theory (11-XX) 3 Quantum theory (81-XX) 2 Operator theory (47-XX) 2 Convex and discrete geometry (52-XX) 2 Classical thermodynamics, heat transfer (80-XX) 1 Real functions (26-XX) 1 Dynamical systems and ergodic theory (37-XX) 1 Difference and functional equations (39-XX) 1 Approximations and expansions (41-XX) 1 Harmonic analysis on Euclidean spaces (42-XX) 1 Mechanics of particles and systems (70-XX) 1 Optics, electromagnetic theory (78-XX) 1 Geophysics (86-XX) 1 Mathematics education (97-XX)
|
|
## EDP9 — a change of focus
The discussion in the last thread has noticeably moved on to new topics. In particular, multiplicative functions have been much less in the spotlight. Some progress has been made on the question of whether the Fourier transform of a sequence of bounded discrepancy must be very large somewhere, though the question is far from answered, and it is not even clear that the answer is yes. (One might suggest that the answer is trivially yes if EDP is true, but that is to misunderstand the question. An advantage of this question is that there could in theory be a positive answer not just for $\pm 1$-valued functions but also for $[-1,1]$-valued functions with $L_2$ norm at least $c>0$, say.)
Another question that has been investigated, mostly by Sune, is the question about what happens if one takes another structure (consisting of “pseudointegers”) for which EDP makes sense. The motivation for this is either to find a more general statement that seems to be true or to find a more general statement that seems to be false. In the first case, one would see that certain features of $\mathbb{N}$ were not crucial to the problem, which would decrease the size of the “proof space” in which one was searching (since now one would try to find proofs that did not use these incidental features of $\mathbb{N}$). In the second case, one would see that certain features of $\mathbb{N}$ were crucial to the problem (since without them the answer would be negative), which would again decrease the size of the proof space. Perhaps the least satisfactory outcome of these investigations would be an example of a system that was very similar to $\mathbb{N}$ where it was possible to prove EDP. For example, perhaps one could find a system of real numbers $X$ that was closed under multiplication and had a counting function very similar to that of $\mathbb{N}$, but that was very far from closed under addition. That might mean that there were no troublesome additive examples, and one might even be able to prove a more general result (that applied, e.g., to $[-1,1]$-valued functions). This would be interesting, but the proof, if it worked, would be succeeding by getting rid of the difficulties rather than dealing with them. However, even this would have some bearing on EDP itself, I think, as it would be a strong indication that it was indeed necessary to prove EDP by showing that counterexamples had to have certain properties (such as additive periodicity) and then pressing on from there to a contradiction.
A question I have become interested in is understanding the behaviour of the quadratic form with matrix $A_{xy}=\frac{(x,y)}{x+y}$. The derivation of this matrix (as something to be interested in in connection with EDP) starts with this comment and is completed in this comment. I wondered what the positive eigenvector would look like, and Ian Martin obliged with some very nice plots of it. Here is a link to where these plots start. It seems to be a function with a number-theoretic formula (that is, with a value at $n$ that strongly depends on the prime factorization of $n$ — as one would of course expect), but we have not yet managed to guess what that formula is.
I now want to try to understand this quadratic form in Fourier space. That is, for any pair of real numbers $(\alpha,\beta)\in [0,1)^2$ I want to calculate $K(\alpha,\beta)=\sum_{x,y}A_{x,y}e(\alpha x-\beta y)$, and I would then like to try to understand the shape of the kernel $K$. Now looking back at this comment, one can see that
$\displaystyle \langle f,Af\rangle=\sum_d w_d\int_0^\infty|\sum_{n=1}^\infty e^{-\theta n}f(dn)|^2 d\theta.$
Since the bilinear form $K(\alpha,\beta)$ is determined by the quadratic form $K(\alpha,\alpha)$ I’ll concentrate on the latter (which in any case is what interests me). So substituting $f(n)=e(\alpha n)$ into the above formula gives me
$\displaystyle K(\alpha,\alpha)=\sum_d w_d\int_0^\infty|\sum_{n=1}^\infty e^{2\pi i\alpha dn-\theta n}|^2 d\theta.$
The infinite sum is a geometric progression, so this simplifies to
$\displaystyle K(\alpha,\alpha)=\sum_d w_d\int_0^\infty\Bigl|\frac{e^{2\pi i\alpha d-\theta}}{1-e^{2\pi i\alpha d-\theta}}\Bigr|^2 d\theta.$
Note that for each $d$ the integrand is bounded unless $\alpha$ is a multiple of $1/d$, and more generally is small unless $\alpha$ is close to a multiple of $1/d$ and $\theta$ is close to 0. So we do at least have the condition of being close to a rational with small denominator making an appearance here. (Why small denominator? Because then there will be more $d$ such that $\alpha$ is a multiple of $1/d$.)
I plan to investigate the sequence 1, -1, 0, 1, -1, 0, … from this perspective. It takes the value $\frac 2{\sqrt{3}}\sin(2\pi n/3)$ at $n$. I shall attempt to understand from the Fourier side why this gives a sequence with such small discrepancy.
Before I finish this post, let me also mention a nice question of Alec’s, or perhaps it is better to call it a class of questions. It’s a little bit like the “entropy” question that I asked about EDP, but it’s about multiplicative functions. The question is this: you play a game with an adversary in which you take turns assigning $\pm 1$ values to primes. You want the resulting completely multiplicative function to have as small discrepancy as you can, whereas your adversary wants the discrepancy (that is, growth of partial sums) to be large. How well can you do? One can ask many variants, such as what happens if your adversary is forced to choose certain primes (for instance, every other prime), or if your adversary’s choices are revealed to you in advance (so now the question is what you can do if you are trying to make a low-discrepancy function but someone else has filled in half the values already and done so as badly as possible), or if you choose your values randomly, etc. etc. So far there don’t seem to be any concrete results, and yet it feels as though it ought to be possible to prove at least something non-trivial here.
One other question I’d like to highlight before I finish this post. It seems that we do not know whether EDP is true even if you insist that the HAPs have common differences that are either primes or powers of 2. The powers of 2 rule out all periodic sequences, but for a strange parity reason: for instance, if you have a sequence that’s periodic with period 72, then along the HAP with common difference 8 it is periodic with period 9, which means that the sum along each block of 9 is non-zero (because it is an odd number) and therefore the sums along that HAP grow linearly. Sune points out that the sequence $f(n)=\exp(2\pi i n/6)$ is a simple counterexample over $\mathbb{T}$, but it’s not clear what message we can take from that, given that periodic sequences don’t work in the $\pm 1$ case. I like this question, because finding a counterexample should be easier if there is one, and if there isn’t, then proving the stronger theorem might be easier because HAPs with prime common differences are “independent” in a nice way.
Update: I intended, but forgot, to mention also some interesting ideas put forward by Gil in this comment. He has a proposal for trying to use probabilistic methods, and in particular methods that are suited to proving that rare events have non-zero probability when there is sufficient independence around, to show that there are many sequences with slow-growing discrepancy. It is not clear at this stage whether such an argument can be made to work, but it seems very likely that thinking about the problems that arise when one attempts to make it work will be fruitful.
### 108 Responses to “EDP9 — a change of focus”
1. Sune Kristian Jakobsen Says:
I just realized that we have some very integer-like pseudointegers where the EDP is false, namely the set of integers not divisible by p for some prime p (the sequence is the Legendre character). I know that this is nothing new, we already knew that these examples told us something about what a proof of EDP could look like, but I didn’t think of them as pseudointeger (actually I did once but the two parts of my brain that knew that “the set of integers not divisible by p can have bounded discrepancy” and “the set of integers not divisible by p is a set of pseudointeger” where too far from each other).
I think these examples have discrepancy about at most $\sqrt(p)$ (if I remember correctly) and the density of them is $d=1-1/p$. The next question is: Can we find pseudointegers with density 1 and bounded discrepancy? Or a weaker question: Can we find sets of pseudointeger with density arbitrary close to 1 and discrepancy <C for some fixed C?
• Sune Kristian Jakobsen Says:
I think the following gives a set of pseudointegers with density 1 and a multiplicative sequence with discrepancy 2:
Start with the set of integers not divisible by 3. This have discrepancy 1 (I’m using the 1,-1,0,1,-1,0,… sequence) and density 2/3, so we need to increase the density. In order to do so, we add two primes a and b such that $a< b$ but b-a is infinitesimal (so they are not a subset of R. More about this later. I think of $a$ as a real number). We define $x_a=1$ and $x_b=-1$ and let multiplicativity define the rest. So for any $n\in \mathbb{N}$ not divisible by 3 the numbers na and nb are close and $x_{na}$ and $x_{nb}$ have opposite signs, so these doesn’t increase the discrepancy to more than 2. The only problem is at powers of a: Around $a^2$ we have the numbers $a^2,ab, b^2$ with $x_{a^2}=1,x_{ab}=-1,x_{b^2}=1$ so we “create” a new prime $c> b^2$ such that $c-a^2$ is infinitesimal, but infinitely larger than $b-a$. Now everything is fine for $a^3$. Here $x_{a^3}=1,x_{a^2b}=-1,x_{ab^2}=1,x_{b^3}=-1,x_{ac}=-1,x_{bc}=1$, but at $a^4$ we get intro trouble again, so we need to add a new prime $d> c^2$. Continuing this way, we get a set of pseudointegers with bounded discrepancy.
Lets calculate the density. To begin with we have the set of integers not divisible by 3. This has density 2/3. The set of numbers an or bn, where n is a integer not divisible by 3, has density $\frac{2}{3}\frac{2}{a}$. The set of numbers on the form aan,abn,bbn or cn has density $\frac{2}{3}\frac{4}{a^2}$, and so on. Now the whole set has density
$d=\frac{2}{3}\left(1+\frac{2}{a}+\frac{4}{a^2}+\frac{6}{a^3}+\frac{10}{a^4}+\dots\right)$
Where the nominator is A000123 (number of partitions of 2n into powers of 2). Since the sequence of nominators grows slower than some geometric sequence (e.g. $2^{2n-1}=4^n/2$ using that it is less than the number of ordered partitions of 2n), we can choose a so that the density is 1.
This is of course not a subset of the real numbers as I used infinitesimal, but if we just choose very small numbers instead, think we can correct the errors when they arise. I think this shows that a proof of EDP must somehow use the additive structure of the integers.
• Sune Kristian Jakobsen Says:
@Tim:
“Perhaps the least satisfactory outcome of these investigations would be an example of a system that was very similar to \mathbb{N} where it was possible to prove EDP.”
I’m not sure I understand you correctly. Do you mean that this wouldn’t be interesting or just that we should at least be able to get this result? I think that finding a set of pseudointegers where we can prove EDP is the only interesting pseudointeger-question left (when I say interesting I mean with relevances to EDP). Perhaps I have forgot some questions.
• gowers Says:
It was a slightly peculiar thing for me to say, because I changed my mind as I was writing it. Initially I thought that finding such a proof wouldn’t shed any light on EDP itself, but by the end of the comment I had started to realize that it could do after all.
2. Jason Dyer Says:
Going back to my graph-theoretic construction, I wanted to include a meaning for “completely multiplicative”.
This likely could be more elegant. I apologize for the mess.
Define everything as the comment, including the 4 extra conditions (it might be possible to do without some, but I haven’t had time to think about it). I will also call the set of edges from condition #1 the omega set, and the root node of that set to be the alpha node.
A node is called prime if the in-degree is 1; that is, the only edge incoming is from the omega set.
A node is a power if the in-degree is 2.
Consider all incoming edges to a particular node; trace the edges backwards to their root nodes. These are the divisors of the node.
Here is a prime factorization algorithm for the node n:
1. List the k divisors of n (excluding the alpha node) $d_1, d_2, ... d_k$. Call the path of a divisor to be the traversal going from the divisor to n. Given any divisor a that has divisor b in its path, remove a from the list.
2. For any divisor that is not prime and is not a power on the list $d_1, d_2, ... d_k$, connect the divisors of each of $d_1, d_2, ... d_k$ as a branching tree (again excluding the alpha node); again, given any divisor a that has divisor b in its path, remove a from the list.
For any divisor that is a power on the list $d_1, d_2, ... d_k$, connect the divisor that is not the alpha node c a multiple number of times m+1, where m is the number of times powers occur in the traversal between the divisor of c and c.
3. Repeat #2 until all divisors on the bottom of the tree are prime.
4. The set of divisors at the bottom of the tree is the prime factorization of n.
So, a graph is completely multiplicative if that multiplying the values of all the nodes in the prime factorization of a node n (including repeated nodes as ncessary) gives the value of the node n.
• Jason Dyer Says:
There’s a bug in the algorithm: if n is already a power, it should jump to the “for any divisor that is a power on the list” process.
Also, an extra condition #5 should be added if we want multiplication to be a function: each node can be the root node of only one labelled set of directed edges.
3. Klas Markström Says:
Regarding Gill’s probabilistic approach http://gowers.wordpress.com/2010/02/19/edp8-what-next/#comment-6278
it might be a good idea to consider separate “bad” events for “sum is less than -C” and “sum is greater than C”
The “less than “-events along a given AP are clearly pairwise positively correlated, and likewise for the “greater than”-events. However the “less than”-events and “greater than”-events along an AP are negatively correlated.
To me mixing the two types of failure for the discrepancy bound seems to make things harder to keep track of. I guess I’m going more in the direction of the Janson inequalites than the local lemma here.
• Gil Says:
I think what I have in mind is to choose the locations of the zeros for the partial sum. We need to be able to show (1) that we can locate the zeroes of the partial sums where we want them, and then that (2) conditioned on such locations that the probabilities for “sum is greater than C” or “sum is smaller than -C” are very small.
For part (2) the probabilities may perhaps be small enough that we can use union bounds and not worry about dependenies.
For the location of zeroes part (1), we certainly need to be able to handle dependencies. And it seems that if we want to go below $\sqrt{\log n}$-discrepancy we will need to exploit positive dependencies (for the events of vanishing partial sums along intervals.) Indeed Janson’s inequalities may be quite relevant.
4. gowers Says:
A couple of observations that will I hope make the calculations in the post make a bit more sense.
First, note that $\int_0^\infty\frac{e^{-2\theta}}{(1-e^{-\theta})^2}d\theta$ equals $\int_0^\infty \frac d{d\theta}\Bigl(\frac 1{1-e^{-\theta}}\Bigr)d\theta$, which is infinite. Therefore, $K(\alpha,\alpha)$ blows up when $\alpha$ is equal to a rational number.
Next, note that the bilinear form derived from $K(\alpha,\alpha)$ is given by the formula
$\displaystyle K(\alpha,\beta)=\sum_dw_d\int_0^\infty \frac{e^{2\pi i\alpha-\theta}}{1-e^{2\pi i\alpha-\theta}}\frac{e^{-2\pi i\beta-\theta}}{1-e^{-2\pi i\beta-\theta}}d\theta.$
Now let’s continue to write $e(x)$ for $e^{2\pi i x}$ and let us also write $c(x)=\cos(2\pi x)=(e(x)+e(-x))/2$ and $s(x)=\sin(2\pi x)=(e(x)-e(-x))/2i$. Our basic example of a bounded-discrepancy sequence is (up to a constant multiple) the sequence $s(n/3)$, which is begging to be understood from a Fourier perspective. Let us call this function $s_3$ and let $e_3(n)=e(n/3)$. Now $\langle s_3,As_3\rangle=\langle e_3-\overline{e_3},e_3-\overline{e_3}\rangle/4$, which equals
$\displaystyle (1/4)(K(1/3,1/3)+K(-1/3,-1/3)+K(1/3,-1/3)+K(-1/3,1/3)),$
which, because of easy symmetry properties of $K$, is equal to
$\frac 14\sum_dw_d\int_0^\infty \Bigl(\frac{2e^{-2\theta}}{|1-e^{2\pi i\alpha d-\theta}|^2}-\frac{e^{4\pi i\alpha d-2\theta}}{(1-e^{2\pi i\alpha d-\theta})^2}-\frac{e^{-4\pi i\alpha d-2\theta}}{(1-e^{-2\pi i\alpha d-\theta})^2}\Bigr)d\theta,$
where $\alpha=1/3$ (but I’d rather keep it as $\alpha$, as the argument is perfectly general). Every time $\alpha d$ is an integer, this gives us zero, and when $\alpha d$ is not an integer it gives us something fairly small. So in this way we (sort of) see the bounded average discrepancy coming about. I still need to think more about this calculation before I can say I fully understand it, or be confident that it isn’t rubbish in some way.
5. Kristal Cantwell Says:
If player one and player two alternate assigning signs to primes with one have the objective of forcing a discrepancy of four then the player trying to force a discrepancy of four will always win.
If player one and player two assign values to the primes of a multiplicative function and player one is trying to force a discrepancy of 4 and player 2 to prevent this player one will win.
Player one chooses to assign 2 the value 1 then player 2 must assign 3 the value -1 or the sum of 1 to 4 will be 4 after 3 is assigned the value 1.
Then player one assigns 5 the value 1 and since f(1),f(2),f(4),f(5) and f(8),f(9) and f(10) are positive the sum at 10 is at least 4 and we are done.
If player one and player two assign values to the primes of a multiplicative function and player two is trying to force a discrepancy of 4 and player 2 to prevent this player two will win.
First we will show that the first player must choose 2. If player one does not choose this then let the second player choose 2 and assign it the value 1 at player 2’s first move. Then the first two moves of player one must be assigning 3 and 5 the values -1. If not then player two will assign one of these the value one on player 2’s second move and either f(1),f(2),f(4),f(5) and f(8),f(9)
and f(10) are positive or f(1),f(2),f(3), and f(4) are positive and in either
case the discrepancy is 4.
So the first player must assign f(2) the value -1 on the first players first
move. Let the second player assign f(3) the value 1 on the second players first move. Now f(1),f(3),f(4),f(5),
f(9),f(12),f(15),f(16) are positive one of f(7) and f(14) is positive. So if the first player does not assign 11 and 13 the value -1 on the second and third moves then the second player can assign one of them value 1 and f(1),f(3),f(4),f(5),f(9),f(12),f(15),f(16), one of f(7) and f(14) and the number chosen make 10 positive values less than or equal to 16 which gives a discrepancy of four.So the second and third moves of the first player are choosing 11 and 13 and assigning them value -1. The second player assigns 7 the value 1 on the third move. Now f(1),f(3),f(4),f(5), f(9),f(12),f(15),f(16) f(7),f(20),f(21),f(22)f(25),f(26),f(27) and f(28) are positive and the discrepancy is at least 4 at 28 and we are done.
6. Polymath5 « Euclidean Ramsey Theory Says:
[...] Polymath5 By kristalcantwell There is a new thread for Polymath5. The pace seems to be slowing down a bit. Let me update this there is another thread. [...]
7. gowers Says:
I want to follow up on this comment with some rather speculative ideas about why EDP might be true.
The annoying example we keep coming up against is 1, -1, 0, 1, -1, 0, …, which, as I have already pointed out, is given by the formula $f(n)=(2/\sqrt{3})s(n/3)$, where $s(x)$ stands for $\sin(2\pi x)$. Now perhaps something like the following is true. Given any $\pm 1$ sequence (or indeed any sequence) we can decompose it as a linear combination of sequences of the form $c(\alpha n)$ and $s(\alpha n)$, where $\alpha$ is rational. A simple proof is as follows. We can produce the characteristic function of the HAP with common difference d as the sum $d^{-1}(1+e(n/d)+e(2n/d)+\dots+e((d-1)n/d)$. And we can produce any function of the natural numbers as a linear combination of HAPs, just by solving an infinite system of linear equations that’s in triangular form. (Basically that is the proof of the Möbius inversion formula.)
Let’s gloss over the fact that the decomposition is far from unique. It means that what I am about to say is not correct as it stands, but my hope is that it could be made correct somehow.
On the face of it, using cosines in a decomposition is likely to lead to large discrepancies, because not only are they periodic, but they are at their maximum at the end of each period, so the HAP with common difference that period (which is an integer if we are looking at $c(\alpha n)$ for some rational $\alpha$) is being given a linear discrepancy that we would hope could not be cancelled out. (This is where we would need a much more unique decomposition, since as things stand it can be cancelled out.) So perhaps one could prove that for a $\pm 1$ sequence to have any chance of having small discrepancy, it has to be built out of sines rather than cosines.
Now the problem with sines is that they keep being zero. So one could ask the following question: how large a sum of coefficients do you need if you want to build a $\pm 1$ sequence out of sines?
I think the answer to this question may be that to get values of $\pm 1$ all the way up to $N$ requires coefficients that sum to at least $c\log N$. My evidence for that is the weak evidence that the obvious way of getting a $\pm 1$ sequence does give this kind of logarithmic growth. Here is how it works.
I know that $s(n/3)$ gives me $\pm 1$ values (after normalization) except at multiples of 3 where it gives me zero. To deal with multiples of 3, I first create the HAP with common difference 3 by taking $(1+c(x/3)+c(2x/3))/3$ (which works because it’s the real part of $(1+e(x/3)+e(2x/3))/3$, which also works. That, however, is not allowed because I’ve used cosines. So I’ll multiply it by $s(x/9)$. The addition formulae for trigonometric functions tell us that $s(\alpha x)c(\beta x)=(s(\alpha+\beta)x)+s((\alpha-\beta)x))/2$, so this results in a sum of sines with coefficients adding up to 1 (or $2/\sqrt{3}$ when we do the normalization). But this new sequence has gaps at multiples of 9. Continuing this process, we find that for each power of 3 we need coefficients totalling 1 (or $2/\sqrt{3}$) to fill the gaps at multiples of that power, which gives us a logarithmic bound.
So the following might be a programme for proving EDP, which has the nice feature of using the $\pm 1$ hypothesis in a big way.
1. Show that any sequence that involves cosines in a significant way must have unbounded discrepancy. (One might add functions such as $s(\alpha x)$ where $\alpha$ is irrational.)
2. Show that any sequence involving sines must have a discrepancy at least as big as the sum of the coefficients of those sines.
3. Show that to make a $\pm 1$ sequence out of sines one must have coefficients that grow at least logarithmically.
As I say, before even starting to try to prove something like this, one would need to restrict the class of possible decompositions, so some preliminary thought is required before one can attempt anything like 1 or 2. Can anyone come up with a precise conjecture that isn’t obviously false? As for 3, it may be that one can already attempt to prove what I suggested above, that to get a $\pm 1$ sequence all the way up to $N$ requires coefficients with absolute values that sum to at least $c\log N$.
• Sune Kristian Jakobsen Says:
A small remark: If we only show (2) for finite sums of sines, it might still be possible to for an infinite sum of sines where the coefficients doesn’t converge to have bounded discrepancy. A sequence with bounded discrepancy can easily be written as a limit of sequences with unbounded discrepancy.
• gowers Says:
I agree. For an approach like this to work there definitely needs to be some extra ingredient, which I do not yet see (and it is not clear that it even exists), that restricts the way you are allowed to decompose a sequence.
• Sune Kristian Jakobsen Says:
This sounds interesting, but I have to ask: Do we have any reason to prefer to use sine functions rather than characteristic functions of APs?
• gowers Says:
I’ve wondered about that, and will try to come up with a convincing justification for thinking about sines. However, that doesn’t mean that characteristic functions of APs shouldn’t be tried too. If we did, then perhaps the idea would be to show that using HAPs themselves is a disaster, and using other APs requires too many coefficients, or something like that.
On a not quite related note, does anyone know whether EDP becomes true if for each $p$ you are allowed to choose some shift of the HAP with common difference $p$? (We considered a related problem earlier, but here I do not insist that the shifts are consistent: e.g., you can shift the 2-HAP by 1 and the 4-HAP by 2.)
• Gil Says:
I suppose the following concrete questions are relevant:
Conjecture 1 If a sequence of +1 -1 0 has bounded discrepency then, except for a set of density 0 it is periodic.
I do not know a counter example to:
Conjecture 2 If a multiplicative sequence of +1 -1 0 has bounded discrepency then it is periodic.
A periodic sequence with period r has bounded discrepency if the sum of elements with indices $di$ for every $d$ which devides $r$ is 0. (In particular, $x_r=0$.) So it make sense to check the suggested conjecture 3 of fine tune it on such periodic sequences.
8. Gil Says:
How about the periodic sequence whose period is 1 -1 1 1 -1 -1 1 -1 0
• gowers Says:
• Gil Says:
I was just curious about the sine decomposition (or sine/cosine decomposition) for the basic sequence $\mu_3$ and for “r-truncated $mu_3$” where you make the sequence 0 if at integers divisible by $3^r$. (You mentiones the r=1 case and I wondered especially about r=2.)
• gowers Says:
I would decompose it by the method I mentioned above. That is, at the first stage I obtain the function 1 -1 0 1 -1 0 … as a multiple of s(n/3). I then obtain 0 0 1 0 0 1 0 0 1 … by taking (1+c(n/3)+c(2n/3))/3. I then convert that into 0 0 1 0 0 -1 0 0 0 … by pointwise multiplying it by s(n/9) (or rather $3/\sqrt{2}s(n/9)$). By the addition formulae for sin and cos, that gives you the periodic sequence 1 -1 1 1 -1 -1 1 -1 0 recurring as a sum of sines, where the total sum of coefficients is $3\sqrt{2}$.
• Gil Says:
so part 2) of the conjecture works ok for such trubcations?
9. Moses Charikar Says:
I wanted to mention an approach to proving a lower bound similar to some of the ideas being discussed here. Consider the generalization of EDP to sequences of unit vectors. The problem is to find unit vectors $v_i$ so that $\max_{k,d} \{||v_{d} + v_{2d} + \ldots + v_{kd}||_2^2\}$ is bounded.
For sequences of length $n$, this leads to the optimization problem: Find unit vectors $v_1,\ldots,v_n$ so as to minimize $\max_{k,d} \{||v_{d} + v_{2d} + \ldots + v_{kd}||_2^2\}$. This can be expressed as a semidefinite program (SDP) – a convex optimization problem that we know how to solve to any desired accuracy. Moreover, there is a dual optimization problem
such that any feasible solution to the dual gives us a lower bound on the value of the (primal) SDP and the optimal solutions to both are equal.
The dual problem to this SDP is the following: Find values $c_{k,d}, b_i$
so as to maximize $\sum b_i$ such that $\sum_{k,d} c_{k,d} \leq 1$
and the quadratic form $\sum_{k,d} c_{k,d}(x_{d}+x_{2d}+\ldots+x_{kd})^2 - \sum_i b_i x_i^2$ is positive semidefinite.
The semidefinite program is usually referred to as a relaxation of the original optimization question over $\pm 1$ variables. Note that any feasible dual solution gives a valid lower bound for the original $\pm 1$ question. This is easy to see directly. Suppose that $\sum_{k,d} c_{k,d}(x_{d}+x_{2d}+\ldots+x_{kd})^2 - \sum_i b_i x_i^2 \geq 0$ for all $x_1,\ldots,x_n$. In particular, it is non-negative for any $x_i \in \{\pm 1\}$ and for such values $\sum_{k,d} c_{k,d}(x_{d}+x_{2d}+\ldots+x_{kd})^2 \geq \sum_i b_i$. Since $\sum_{k,d}c_{k,d} \leq 1$, there must be some $k,d$ such that $(x_d + x_{2d} + \ldots + x_{kd})^2 \geq \sum b_i$.
Now what is interesting is that for the vector discrepancy question for sequences of length $n$, there is always a lower bound of this form that matches the optimal discrepancy. If the correct answer for vector discrepancy was a slowly growing function of $n$, and if we could figure out good values for $c_{k,d}$ and $b_i$ to prove this, we would have a lower bound for EDP.
Now the nice thing is that we can actually solve these semidefinite programs for small values of $n$ and examine their optimal solutions to see if there is any useful structure. Huy Nguyen and I have been looking at some of these solutions. Firstly here are the optimal values of the SDP for some values of $n$.
128: 0.53683
256: 0.55467
512: 0.56981
1024: 0.58365
1500: 0.59064
(I should mention that we excluded HAPs of length 1 from the objective function of the SDP, otherwise the optimal values would be trivially at least 1.) The discrepancy values are very small, but the good news is that they seem to be growing with $n$, perhaps linearly with $\log n$. The bad news is that it is unlikely we can solve much larger SDPs. (We haven’t been able to solve the SDP for 2048 yet.)
The main point of this was to say that there seems to be significant structure in the dual solutions of these SDPs which we should be able to exploit if we understand what’s going on. One pattern we discovered in the $c_{k,d}$ values is that the sums of tails of this sequence (for fixed d) seem to drop exponentially. More specifically, if $t_{j,d} = \sum_{k\geq j} c_{k,d}$ then $t_{j,d} = C_d e^{-\alpha jd}$ (approximately). It looks like the scaling factor $C_d$ is dependent on $d$, but the factor $\alpha$ in the exponent is not. The $b_i$ values in the dual solution also seem to have interesting structure. The values are not uniform and tend to be higher for numbers with many divisors (not surprising since they appear in many HAPs).
We should figure out the easiest way to share these SDP dual solutions with everyone so others can play with the values as well.
• gowers Says:
This looks like a very interesting idea to pursue. One aspect I do not yet understand is this. It is crucial to EDP that we look at functions that take values $\pm 1$ and not, say sequences that take values in $[-1,1]$ and are large on average. For example, the sequence 1, -1, 0, 1, -1, 0, … has bounded discrepancy. In your description of the dual problem and how it directly gives a lower bound, it seems to me that any lower bound would also be valid for this more general class of sequences. But perhaps I am wrong about this. If so, then where is the $\pm 1$ hypothesis being used?
If it was in fact not being used, that does not stop what you wrote being interesting, since one could still try to find a positive semidefinite matrix and try to extract information from it. For example, it might be that the sequences that one could build out of eigenfunctions with small eigenvalues had properties that meant that it was not possible to build $\pm 1$-valued sequences out of them. (This is the kind of thing I was trying to think about with the quadratic form mentioned in the post.)
I have edited your comment and got rid of all the typos I can, but I can’t quite work out what you meant to write in the formula $t_{j,d}=C_de^{-\alpha j,d}$.
• Moses Charikar Says:
Tim, the $\pm 1$ hypothesis is being used in placing the constraint $v_i \cdot v_i = 1$ in the SDP. So a sequence with $\pm 1$ would be a valid solution but one with $\{\pm 1, 0\}$ would not. The variables $b_i$ correspond to this constraint. In fact, it seems sufficient to use the constraint $v_i \cdot v_i \geq 1$ (the optimal values are almost the same). In this case, the dual variables $b_i \geq 0$. In some sense, value of $b_i$ is a measure of how important the constraint $v_i \cdot v_i \geq 1$ is.
While $\{\pm 1,0\}$ sequences are not valid solutions, distributions
over such sequences which are large on average on every coordinate are valid
solutions to the SDP. So a lower bound on the vector question means that any distribution on sequences which is large on average on every coordinate must contain a sequence with high discrepancy.
The expression $t_{j,d} = C_d e^{-\alpha j,d}$ should not have a comma in the exponent, i.e. it should read: $t_{j,d} = C_d e^{-\alpha jd}$. Sorry for all the typos ! I wish I could visually inspect the comment before it posts (or edit it later).
• gowers Says:
Ah, I see now. This is indeed a very nice approach, and I hope that we will soon be able to get some experimental investigations going and generate some nice pictures.
• Moses Charikar Says:
I mentioned that it looks like the optimal values of the SDP seem to be growing linearly with $\log n$. If true, this would establish a lower bound of $\sqrt{\log n}$ on the discrepancy of $\pm 1$ sequences. This is because for the vector problem, the objective function is actually the square of the discrepancy for integer sequences. The analog of integer discrepancy would be to look at $||v_{d} + v_{2d} + \ldots + v_{kd}||_2$ but in fact, the objective function of the SDP is the maximum of $||v_{d} + v_{2d} + \ldots + v_{kd}||_2^2$
In fact the growth rate for vector sequences could be different from the growth rate for integer sequences. I think we can construct sequences unit vectors of length $n$ such that the maximum value of $||v_{d} + v_{2d} + \ldots + v_{kd}||_2$ is $\sqrt{\log n}$. This can be done using the familiar 1,-1,0,1,-1,0,… sequence: Construct the vectors one coordinate at a time. Every vector in the sequence will have a 1 or -1 in exactly one coordinate and 0’s elsewhere. In the first coordinate we place the 1,-1,0,1,-1,0,… sequence. Look at the subsequence of vectors with 0 in the first coordinate. For these, we place the 1,-1,0,1,-1,0,… sequence in the second coordinate. Now look at the subsequence of vectors with 0’s in the first two coordinates. For these, we place the 1,-1,0,1,-1,0,… sequence in the third coordinate and so on. All unspecified coordinate values are 0. The first $n$ vectors in this sequence have non-zero coordinates only amongst the first $\log_3 n$ coordinates. Now for any HAP, the vector sequence has bounded discrepancy in every coordinate. Thus the maximum of $||v_{d} + v_{2d} + \ldots + v_{kd}||_2$ for the first $n$ vectors is bounded by $\sqrt{\log n}$.
• gowers Says:
I like that observation. One could even think of it as a multiplicative function as follows. We take the function from $\mathbb{N}$ to $L_\infty(\mathbb{T})$ defined by the following properties: (i) if $n$ is congruent to $\pm 1$ mod 3, then $f(n)$ is the constant function $\pm 1$; (ii) $f(3)$ is the function $z$; (iii) $f$ is completely multiplicative (where multiplication in $L_\infty(\mathbb{T})$ is pointwise).
To be more explicit about it, to calculate $f(n)$ you write $n$ as $m3^k$, where $m$ is congruent to $\pm 1$ mod 3, and $f(n)$ is then the function $z\mapsto\pm z^k$.
• gowers Says:
Out of curiosity, let me assume that $c_{k,d}$ is given by a formula of the kind $C_d e^{-\alpha kd}$ (which would give the right sort of behaviour for the tails). What does that give us for $\sum_{k,d}c_{k,d}(x_d+\dots+x_{kd})^2$?
Well, if $m\ne n$ then $x_mx_n$ is counted $2\sum c_{k,d}$ times, where the sum is over all common factors $d$ of $m$ and $n$ and over all $k$ that exceed $\max\{m/d,n/d\}$. For each fixed $d$, … OK, I’ll change to assuming that the tail of the sum of the $c_{k,d}$ is given by that formula, so we would get $C_d\exp(-\alpha\max\{m,n\})$, and then we’d sum that over all $d$ dividing $(m,n)$.
Now let me choose, purely out of a hat, to go for $C_d=\phi(d)$, so that when we sum over $d$ we get $(m,n)\exp(-\alpha\max\{m,n\})$. This is not a million miles away from what I was looking at before, but now the task is much clearer. We don’t have to worry about the fact that some functions like 1, -1, 0, 1, -1, 0, … have bounded discrepancy. Rather, we must find some sequence $b_1,b_2,\dots$ such that subtracting the corresponding diagonal matrix leaves us with something that’s still positive semidefinite, in such a way that the sum of the $b_i$ is large.
I haven’t checked in the above what the sum of the $c_{k,d}$ is, so I don’t know how large the sum of the $b_i$ has to be. But, for those who share the anxiety I had earlier, the way we deal with the problem of the bounded-discrepancy sequences is that the sequence $b_i$ will tend to be bigger at numbers with many prime factors, to the point where, for example, the sum of the $b_i$ such that $i$ is not a multiple of 3 will be bounded.
Here’s a simple toy problem, but it could be a useful exercise. Find a big supply of positive sequences of real numbers $(b_i)$ such that $\sum_ib_i=\infty$ but for every $m$ the sum of all $b_i$ such that $i$ is not a multiple of $m$ is finite.
I’ve just found one to get the process going: take $b_n$ to be 1 if $n=m!$ for some $m$ and 0 otherwise. So the question is to find more interesting examples, or perhaps even something closer to a characterization of all such sequences.
• gowers Says:
The more I think about this the more I look forward to your sharing the values of the solutions to the SDP dual problem that you have found, especially if they can also be represented visually. You’ve basically already said this, but what excites me is that we could then perhaps make a guess at some good choices for the $c_{k,d}$ and the $b_i$ and end up with a much more tractable looking conjecture than EDP — namely, that some particular matrix is positive semidefinite.
• Alec Edgington Says:
Regarding the toy problem, here’s a slight generalization of your example: let $K_m$ ($m \geq 1$) be any sequence of finite non-empty subsets of $\mathbb{N}$, and let $c_m \geq 0$ be any sequence such that $\sum_m c_m = \infty$. Then the sequence
$\sum_m c_m \chi_{m! K_m}$
satisfies the condition (where $\chi_S$ is the characteristic function of $S$).
• Alec Edgington Says:
To generalize a bit further: let $\beta_{m,r}$ ($m, r \geq 1$) be a matrix of non-negative reals such that $\sum_m \beta_{m,1} = \infty$ and $\sum_r \beta_{m,r} < \infty$ for all $m$. Then let $b_n = \beta_{m,r}$ where $n = m! r$ with $m$ maximal.
• gowers Says:
One can greedily create such sequences as follows. First, choose a sequence $(a_n)$ of positive reals that sums to infinity. Next, arbitrarily choose a sequence with finite sum that takes the value $a_1$ somewhere, and put it down on the odd numbers. That takes care of the non-multiples of 2. Now we take care of multiples of 3 by choosing a sequence that has finite sum and takes the value $a_2$ somewhere and placing it at the points that equal 2 or 4 mod 6 (that is, the non-multiples of 3 that have not had their values already assigned). Next, we deal with non-multiples of 5 by choosing values for numbers congruent to 6, 12, 18 or 24 mod 30 … and so on.
• Huy Nguyen Says:
I have put some summary data of the SDP solutions at http://www.cs.princeton.edu/~hlnguyen/discrepancy/discrepancy.html
The data mostly focus on the tails rather than $c_{k, d}$.
• Moses Charikar Says:
This comment got posted in the wrong spot earlier. Please delete the other copy.
The dual solutions for n=512,1024,1500 and the corresponding positive semidefinite matrices are available
The files dual*.txt have the following format.
Lines beginning with “b” specify the $b_i$ values
b i $b_i$
Lines beginning with “t” specify the tails $t_{k,d}$
t k d $t_{k,d}$
The files matrix*.txt have the following format: the ith line of the file contains the entries of the ith row of the matrix.
10. gowers Says:
Gil, I meant to mention your ideas about creating low-discrepancy sequences probabilistically in my latest post, but forgot. I have now updated it. I would like to bring that particular discussion over to here, which is why I am writing this comment.
I am trying to come up with a purely linear-algebraic question that is nevertheless relevant to EDP. Here is one attempt. Let r be an integer, and let us try to build a sequence $(x_n)$ of real numbers such that for every $d$ and every $k$ the sum $x_{((k-1)r+1)d}+\dots+x_{krd}=0$. That is, for every $d$, if you break the HAP with common difference $d$ into chunks of length $r$, then the sum over every chunk is zero.
If $r$ is prime, then one way of achieving this is to create a sequence with the following three properties: (i) it is periodic with period $r$; (ii) $x_n=0$ whenever $n$ is a multiple of $r$; (iii) $x_1+\dots+x_{r-1}=0$. If $r$ is composite, then the condition is similar but slightly more complicated. A general condition that covers (ii) and (iii) simultaneously is that for every factor $d$ of $r$ the sum $x_d+x_{2d}+\dots+x_r$ must be zero.
The set of all such sequences is a linear subspace of the set of all real sequences. My question is whether every sequence satisfying the first condition (namely summing to zero along chunks of HAPs) must belong to this subspace.
I have given no thought to this question, so it may have a simple and uninteresting answer.
Let me just remark that it is very important that the “chunks” are not just any sets of $r$ consecutive terms of HAPs, since then periodicity would follow trivially (because when you remove $x_n$ from the beginning of a chunk and add $x_{n+r}$, you would need the sum to be the same). So, for example, if $r=5$, then the conditions imposed on the HAP with common difference 3 are that $x_3+x_6+x_9+x_{12}+x_{15}=0$, that $x_{18}+x_{21}+x_{24}+x_{27}+x_{30}=0$, and so on.
• Gil Kalai Says:
Sure, lets continue discussing it here along with the various other interesting avenues. The idea was to try to impose zeroes as partial sums along intervals of HAPs. If the distance between these zeroes is order k then in a random such sequence we can hope for discrepency $\sqrt k$.
The value $k=\log n$ appears to be critical. (Perhaps, more accurately, $k=\log n \log\log n$.) When $k$ is larger the number of conditions is sublinear and the probability for such a condition to hold is roughly is $1/\sqrt k$. So when $k=(\log n)^{1.1}$ we can expect that the number of sequences satisfying the conditions is typically $2^{n-o(1)}$.
This give a heuristic prediction of $\sqrt{\log n}$ (up to lower order terms, or perhaps, more accurately, $\sqrt{\log n\log\log n}$) as the maximum discrepency of a sequence of length $n$.
Of course, the evidence that this is the answer is rather small. This idea suggests that randomized constructions may lead to examples with descrepency roughly $\sqrt{\log n}$. In fact, this may apply to variants of the problems like the one where we restrict ourselves to square free integers. I will make some specific suggestions in a different post.
Regarding lower bounds, if $k$ is smaller than $\log n$ then the number of constrains is larger then the number of variables. So this may suggest that even to solve the linear equations might be difficult. Like with any lower bound approach we have to understand the case that we consider only HAP with odd periods where we have a sequence of discrepency 1. It is possible, as Tim suggested, that solutions to the linear algebra problem exists only if the imposed spacing are very structured which hopefully implies a periodic solution.
11. Moses Charikar Says:
The dual solutions for n=512,1024,1500 and the corresponding positive semidefinite matrices are available here. Double click on a file to download it.
The files dual*.txt have the following format.
Lines beginning with “b” specify the $b_i$ values
b $i$ $b_i$
Lines beginning with “t” specify the tails $t_{k,d}$
t $k$ $d$ $t_{k,d}$
The files matrix*.txt have the following format: the $i$th line of the file contains the entries of the $i$th row of the matrix.
12. gowers Says:
Although the mathematics of this comment is entirely contained in the mathematics of Moses Charikar’s earlier comment, I think it bears repeating, since it could hold the key to a solution to EDP.
Amongst other things, Moses points out that a positive solution to EDP would follow if for large $n$ one could find coefficients $c_{k,d}$ and $b_m$ such that the quadratic form
$\displaystyle \sum_{k,d}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2-\sum_mb_mx_m^2$
is positive semidefinite, the coefficients $c_{k,d}$ are non-negative and sum to 1, and the coefficients $b_m$ are non-negative and sum to $\omega(n)$, where $\omega$ is some function that tends to infinity. Here, the sums are over all $k,d$ such that $kd\leq n$ and over all $m\leq n$. The proof is simple: if such a quadratic form exists, then when each $x_i=\pm 1$ we have that $\sum_mb_mx_m^2=\sum_mb_m=\omega(n)$, and since the $c_{k,d}$ are non-negative and sum to 1 we know by averaging that there must exist $k,d$ such that $(x_d+\dots+x_{kd})^2\geq\omega(n)$.
(i) The condition that $x_i=\pm 1$ is used in an important way: if the $b_m$ are mainly concentrated on pretty smooth numbers, then we will not be trying to prove false lower bounds for sequences like 1, -1, 0, 1, -1, 0, … since the sum of the $b_m$ over non-multiples of 3 can easily be at most 1 or something like that.
(ii) We can use semidefinite programming to calculate the best possible quadratic form for fairly large $n$ (as Moses and Huy Nguyen have done already) and try to understand its features. This will help us to make intelligent guesses about what sorts of coefficients $c_{k,d}$ and $b_m$ have a chance of working.
(iii) We don’t have to be too precise in our guesses in (ii), since to prove EDP it is not necessary to find the best possible quadratic form. It may be that there is another quadratic form with similar qualitative features that we can design so that various formulae simplify in convenient ways.
(iv) To prove that a quadratic form is positive semi-definite is not a hopeless task: it can be done by expressing the form as a sum of squares. So we can ask for something more specific: try to find a positive linear combination of squares of linear forms in variables $x_1,\dots,x_n$ such that it equals a sum of the form
$\displaystyle \sum_{k,d}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2-\sum_mb_mx_m^2.$
To do this, it is not necessary to diagonalize the quadratic form, though that would be one way of expressing it as a sum of squares.
In theory, therefore, a simple identity between two sums of squares of linear forms could give a one-line proof of EDP. It’s just a question of finding one that will do the job.
At this point I’m going to stick my neck out and say that in view of (i)-(iv) I now think that if we continue to work on EDP then it will be only a matter of time before we solve it. That is of course a judgment that I may want to revise in the light of later experience.
• gowers Says:
Here is a very toy toy problem, just to try to get some intuition. The general aim is to try to produce a sum of squares of linear forms, which will automatically be a positive semidefinite quadratic form, from which it is possible to subtract a diagonal quadratic form and still have something positive semidefinite.
Here is a simple example where this can be done. Let us consider the quadratic form
$\displaystyle (a+b)^2+(a+c)^2+\lambda(b+c)^2$
in three variables $a,b$ and $c$. Here, $\lambda$ is a small positive constant. Now this form is positive definite, since the only way it could be zero is if $a+b=a+c=b+c=0$, which implies that $a=b=c=0$. But we want to quantify that statement.
One possible quantification is as follows. We rewrite the quadratic form as
$\displaystyle (1-\lambda)((a+b)^2+(a+c)^2)+$
$\displaystyle +\lambda((a+b)^2+(b+c)^2+(a+c)^2)$
and observe that the part in the second bracket can be rewritten as $a^2+b^2+c^2+(a+b+c)^2$. Therefore, the whole quadratic form is bounded below by $\lambda(a^2+b^2+c^2)$.
This isn’t a complete analysis, since if $a+b+c=a+b=a+c=0$ then $a=b=c=0$, so I haven’t subtracted enough. But I have to go.
• gowers Says:
Actually, for intuition-building purposes, I think the identity
$\displaystyle (a+b)^2+(b+c)^2+(a+c)^2=a^2+b^2+c^2+(a+b+c)^2$
is better, because it is very simple, and it shows how the “bunchedupness” on the left-hand side can be traded in for a diagonal part and something that’s more spread out. Now all we have to do is work out how to do something similar when we have HAPs on the left-hand side …
• gowers Says:
Here’s an exercise that would be one step harder than the above, but still easier than EDP and possibly quite useful. I’d like to know what the possibilities are for subtracting something diagonal and positive from the infinite quadratic form
$\displaystyle ax_1^2+a^2(x_1+x_2)^2+a^3(x_1+x_2+x_3)^2+\dots$
and still ending up with something positive definite, where $a$ is some constant less than 1. That is, I would like to find a way of rewriting the above expression as a sum of squares of linear forms, with as much as possible of the weight of the coefficients being given to squares of single variables.
Actually, I’ve seen one possible way of doing it. Note that $x^2+a(x+y)^2=(1-a)x^2+a(2(x+y/2)^2+y^2/2)$. That allows us to take the terms of the above series in pairs and write each pair as a square plus $a^{2n}x_{2n}^2/2$. So we can subtract off the diagonal form
$\displaystyle \frac12(a^2x_2^2+a^4x_4^2+a_6x_6^2+\dots)$
and still have something positive semidefinite.
However, it looks to me as though that is not going to be good enough by any means, because if we sum the coefficients in that kind of expression over all $d$ we are going to get something of comparable size to the sum of all the coefficients, which will be bounded. So we have to take much more account of how the HAPs mix with each other (which is not remotely surprising).
So I’d like some better examples to serve as models.
• Moses Charikar Says:
If you were able to subtract off a large diagonal term from the expression $\displaystyle ax_1^2+a^2(x_1+x_2)^2+a^3(x_1+x_2+x_3)^2+\dots$ and still end up with something positive semidefinite, then this would serve as a lower bound for the discrepancy of the collection of subsets $\{1\}, \{1,2\}, \{1,2,3\}, \ldots$. But the minimum discrepancy of this collection is 1. Hence the sum of coefficients of the diagonal terms can be no larger than $\sum_{i=1}^{\infty} a^i$. (The ratio of the two quantities is a lower bound on the square discrepancy). The best you can do I suppose is to have $a$ be very small, and subtract $a x_1^2$.
• gowers Says:
I didn’t mean that just that form on its own would suffice, but that even if you add up a whole lot of expressions of that kind, one for each $d$, the bound for the sum of the diagonal terms will be bounded in terms of the sum of all the coefficients. But I suppose your remark still applies: that is inevitably the case, or else one could prove for some fixed $d$ that the discrepancy always had to be unbounded on some HAP of common difference $d$, which is obvious nonsense.
Let’s define the $d$-part of the quadratic form that interests us to be $\sum_kc_{k,d}(x_d+\dots+x_{kd})^2$. And let’s call it $q_d$. Then it is absolutely essential to subtract a diagonal form $\Delta$ from $\sum_dq_d$ in such a way that we cannot decompose $\sum_dq_d-\Delta$ as a sum $\sum_d(q_d-\Delta_d)$ of positive semi-definite forms.
Maybe the next thing to do is try to find a non-trivial example of subtracting a large diagonal from a sum of a small number of $q_d$s. (By non-trivial, I mean something that would beat the bound you get by subtracting the best $\Delta_d$ from each $q_d$ separately.)
• Moses Charikar Says:
We could get some inspiration from the SDP solutions for small values of $n$. Note that we explicitly excluded the singleton terms from each HAP because that would trivially give us a bound of 1. So far, the best bound we have (for $n=1500$) from the SDP is still less than 1. Getting a bound that exceeds 1 by this approach is going to require a very large value of $n$. That being said, here are some dual solutions that have clean expressions:
$\displaystyle 2(x_1+x_2)^2 + 2(x_1+x_2+x_3)^2 - x_3^2 \geq 0$
This gives a lower bound of $\frac{1}{4}$ on the square discrepancy for $n=3$.
$\displaystyle (x_1+x_2+x_3+x_4+x_5)^2 + 2 (x_1+x_2+x_3+x_4+x_5+x_6)^2 + 2 (x_1+x_2+x_3+x_4+x_5+x_6+x_7)^2 + (x_1+x_2+x_3+x_4+x_5+x_6+x_7+x_8)^2 + (x_2+x_4)^2 + (x_2+x_4+x_6)^2 + (x_2+x_4+x_6+x_8)^2 - x_6^2 - x_7^2 - x_8^2 \geq 0$
This gives a lower bound of $\frac{1}{3}$ on the square discrepancy for $n=8$.
I don’t have proofs that these quadratic forms are non-negative, except that they ought to be if we believe that the SDP solver is correct.
• Moses Charikar Says:
Of course, we can get a sum of squares representation from the Cholesky decomposition of the matrix corresponding to the quadratic form.
• gowers Says:
The non-negativity of the first of those forms is a special case of what I said earler: $x^2+(x+y)^2=2(x+y/2)^2+y^2/2$. I’ll think about the other one.
• Moses Charikar Says:
The second form has the following decomposition:
$\displaystyle 6(x_1+x_2+x_3+x_4+x_5+\frac{5}{6}x_6 + \frac{1}{2}x_7 + \frac{1}{6} x_8)^2 + 3(x_2 + x_4 + \frac{2}{3} x_6 + \frac{1}{3} x_8)^2 + \frac{1}{2} (x_6 + x_7 + x_8)^2$
We know that the SDP bound is $\frac{1}{4}$ for $n \leq 7$ and jumps to $\frac13$ for $n=8$ thanks to this quadratic form. Hence this decomposition is non-trivial in that it cannot be decomposed as a sum $(q_1-\Delta_1) + (q_2 -\Delta_2)$ of positive semidefinite forms.
• Huy Nguyen Says:
If we look at the Cholesky decomposition of the matrix $M$ corresponding to the quadratic form computed by the SDP solver for n=1500 for inspiration for the sum of squares, there seem to be some interesting patterns going on there. Let $R^T R$ be the decomposition, and $R_i$ be the i-th row of $R$, then $x^T Mx$ can be rewritten as $\sum_i (R_i x)^2$. $R_i$ seems to put most of its weight on numbers that are multiple of i. The weight at the multiples of i decreases quickly as the multiples get larger. Among the non-multiples of i, there is also some pattern in the weights of numbers with common divisors with i as well. I have put some plots at http://www.cs.princeton.edu/~hlnguyen/discrepancy/cholesky.html
• gowers Says:
Here’s another way of thinking about the problem. Let’s assume that we have chosen (by inspired guesswork based on experimental results, say) the coefficients $c_{k,d}$. So now we have a quadratic form $\sum_{k,d}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2$, and we want to write it in a different way, as $\Delta+\sum_iL_i(x)^2$, where $x$ is shorthand for $(x_1,x_2,\dots)$ and for each $i$ $L_i(x)$ is some linear form $\sum_j a_{ij}x_j$. Also, $\Delta$ is a non-negative diagonal form (that is, one of the form $\sum \delta_ix_i^2$, and our aim is to get the sum of the $\delta_i$ to be as large as possible.
Instead of focusing on $\Delta$, I think it may be more fruitful to focus on the off-diagonal part of the quadratic form. That is, we try to choose the $L_i$ so as to produce the right coefficients at every $x_ix_j$, and we try to do that so efficiently that when we’ve finished we find that the diagonal part is not big enough — hence the need to add $\Delta$.
To explain what I mean about “efficiency” here, let me give an extreme example. Suppose we have a quadratic form in $x_1,\dots,x_n$ and all we are told about it is that the coefficient of every $x_ix_j$ is 2. An inefficient way of achieving this is to take $\sum_{i. If we do this, then the diagonal part is $(n-1)\sum_ix_i^2$. But we can do much much better by taking $(x_1+\dots+x_n)^2$, which gives a diagonal part of $\sum_ix_i^2$.
In the HAPs case, what we’d like to do is find ways of reexpressing the sum $\sum_{k,d}c_{k,d}(x_d+\dots+x_{kd})^2$ more efficiently by somehow cleverly combining forms so as to achieve the off-diagonal part with less effort. The fact that there are very long sequences with low discrepancy tells us that this will be a delicate task, but we could perhaps try to save only something very small. For instance, we could try to show that the form was still positive semidefinite even after we subtract $\sum_n n^{-1}x_{n!}^2$. (This would show $c\sqrt{\log\log n}$ growth in the discrepancy, whereas we are tentatively expecting that it should be possible to get $\sqrt{\log n}$.)
• Gil Says:
What would it take, by this method, to show that the discrepency is > 2?
• gowers Says:
If I understand correctly from Wikipedia, the Cholesky decomposition would attempt to solve the problem in my previous comment in a greedy way: it would first make sure that all the coefficients of $x_1x_i$ were correct, leaving a remainder that does not depend on $x_1$. Then it would deal with the $x_2x_i$ terms (with $i\geq 2$), and so on. If this is correct (which it may not be) then it is not at all clear that it will be an efficient method in the sense I discussed above (though in the particular example I gave it happened to give the same decomposition).
• gowers Says:
The answer to Gil’s question is that we’d need to choose the coefficients $c_{k,d}$ to sum to 1 and to be able to rewrite the quadratic form $\sum_{k,d}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2$ as $\sum_i L_i^2+\Delta$ where the $L_i$ are linear forms and $\Delta$ is a diagonal form $\sum_i d_ix_i^2$ with non-negative coefficients $d_i$ that sum to more than 4. (The 4 is because we then have to take square roots.)
Indeed, if we can do this, then we see that if $x_i=\pm 1$ for every $i$, then the quadratic form we started with takes value greater than 4, so by averaging at least one of the $(x_d+x_{2d}+\dots+x_{kd})^2$ is greater than 4.
We know from the 1124 examples that this is not going to be easy, but the fact that we need to go up to 4 is encouraging (in the sense that 1124 is not as frighteningly large a function of 4 as it is of 2).
• gowers Says:
As a tiny help in thinking about the problem, it is useful to note that the coefficient of $x_mx_n$ in the quadratic form $\sum_{k,d}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2$ is $2\sum_{d|(m,n)}\sum_{kd\geq m\vee n}c_{kd}$. If, following Moses, we write $\tau_{k,d}$ for $\sum_{j\geq k}c_{k,d}$, then this becomes $2\sum_{d|(m,n)}\tau_{m\vee n,d}$.
It’s a shame that this formula involves the maximum $m\vee n$, but we might be able to deal with that by smoothing the truncations of the HAPs (as I did in the calculations in the EDP9 post). That is, one could try to prove that a sum such as $\sum_r e^{-\alpha r} x_{rd}$ is large, which implies by partial summation that one of the sums $\sum_{r\leq m} x_{rd}$ is large. This too raises technical problems — instead of summing over the coefficients we end up integrating (which isn’t a problem at all) but the integral of the coefficients is infinite. I call this a technical problem because it still doesn’t rule out finding some way of showing that the diagonal coefficients are “more infinite” in some sense, or doing some truncation to make things finite and then dealing with the approximations.
• gowers Says:
One further small remark. The suggestion from the experimental evidence is that $\tau_{k,d}$ has the form $C_de^{-\alpha kd}$. However, we are not forced to go for the best possible form. So perhaps we could try out $\tau_{k,d}=C_de^{-\alpha k}$ (and it is not hard to choose the $c_{k,d}$ so as to achieve that). Then $\sum_{d|(m,n)}\tau_{m\vee n,d}$ would equal $e^{-\alpha(m\vee n)}\sum_{d|(m,n)}C_d$. That would leave us free to choose some nice arithmetical function $d\mapsto C_d$. For example, we could choose $C_d=\Lambda(d)$ and would then end up with $\log(m,n)e^{-\alpha(m\vee n)}$.
If we did that, then we would have the following question. Fix a large integer $N$, and work out the sum $S$ of all the coefficients $c_{k,d}$ such that $kd\leq N$. Then try to prove that it is possible to rewrite the quadratic form $\sum_{m,n\leq N}\log(m,n)e^{-\alpha(m\vee n)}x_mx_n$ as a diagonal form plus a positive semidefinite form in such a way that the sum of the diagonal terms is at least $\omega(S)$.
There is no guarantee that this particular choice will work, but I imagine that there is some statement about a suitable weighted average of discrepancies that would be equivalent to it, and we might find that that statement looked reasonably plausible.
• Moses Charikar Says:
Since $\Lambda(d)$ is non-zero only for prime powers, your choice of $C_d = \Lambda(d)$ would prove that the discrepancy is unbounded even if we restrict ourselves to HAPs with common differences that are prime powers. Certainly plausible.
One comment on how large $n$ needs to be for this to prove that the discrepancy is $\geq 2$. If the trend from the SDP values for small $n$ continues, it will take really really large $n$ for the square discrepancy to exceed even 1 ! The increment in the value from $n=2^9$ to $n=2^{10}$ was a mere 0.014. At this rate, you would need to multiply by something like $2^{70}$ to get an increment of 1 in the lower bound on square discrepancy.
• gowers Says:
For exactly this reason, we had a discussion a few days ago about whether EDP could be true even for HAPs with prime-power common differences. Sune observed that it is false for complex numbers, since one can take a sequence such as $x_n=\exp(2\pi in/6)$. However, it is not clear what the right moral from that example is, since no periodic sequence can give a counterexample for the real case. But it shows that any quadratic-forms identity one found would have to be one that could not be extended to the complex numbers. But it seems that such identities do not exist: if we change the real quadratic form $\sum_{d,k}c_{k,d}(x_d+\dots+x_{kd})^2$ into the Hermitian form $\sum_{d,k}c_{k,d}|x_d+\dots+x_{kd}|^2$, the matrix of the form is unchanged, and the coefficient of $x_mx_n$ becomes the coefficient of $\Re(x_mx_n)/2$.
So if my understanding is correct, even if EDP is true for prime power differences, it cannot be proved by this method, and $C_d=\Lambda(d)$ was therefore a bad choice.
• gowers Says:
In fact, the reason I chose it was that I had a moment of madness and stopped thinking that $\sum_{d|n}\phi(d)=n$, because I forgot that it was precisely the same as $\sum_{d|n}\phi(n/d)$. (What I mean is that I knew this fact, but temporarily persuaded myself that it wasn’t true.) So I go back to choosing instead $C_d=\phi(d)$, in which case the quadratic form one would try to rewrite would be $\sum_{m,n\leq N}(m,n)e^{-\alpha(m\vee n)}x_mx_n$.
• Moses Charikar Says:
Another way to see this is that complex numbers can be viewed as 2 dimensional vectors: $e^{i \theta} \equiv (\cos \theta, \sin \theta)$. If EDP does not hold for complex numbers for a subset of HAPs, then it does not hold for vectors for the same subset of HAPs. Hence we cannot get a good lower bound via the quadratic form.
• Moses Charikar Says:
One observation about the $b_i$: If only a subset of the $b_i$ are non-zero, we need to think carefully about where to place these non-zero values. A proof of this form would imply this: Consider any sequence where we place $\pm 1$ values at locations $i$ such that $b_i > 0$, but are free to place arbitrary values (including $0$) at locations $i$ such that $b_i = 0$. Then the discrepancy of any such sequence over HAPs is unbounded.
In particular, this rules out having non-zero values for $b_i$ only at $i = n!$, because an alternating $\pm 1$ sequence at these values (and zeroes elsewhere) has bounded discrepancy over all HAPs.
One attractive feature of this approach is that the best lower bound achievable via a proof of this form is exactly equal to the discrepancy of vector sequences (for every sequence length $n$). But we ought to admit the possibility that the discrepancy for vector sequences may be bounded (even if it is unbounded for $\pm 1$ sequences). We know at least two instances where we can do something with unit vectors that cannot be done with $\pm 1$ sequences. Are there constructions of sequences of unit vectors with bounded discrepancy ?
• Moses Charikar Says:
This is a minor point, but I think the choice $\tau_{k,d}=C_de^{-\alpha kd}$ actually ensures that the coefficient of $x_mx_n$ is $2e^{-\alpha(m\vee n)}\sum_{d|(m,n)}C_d$. Doesn’t change what we need to prove.
13. Gil Kalai Says:
Here is a proposed probabilistic construction which is quite similar to earlier algorithms, can be tested empirically, and perhaps even analyzed. Let $n$ be the lenth of the sequence we want to create and let $T$ be a real number. ( $T=$ $T(n)$ will be a monotone function of $n$ that we determine later.)
You chose the value of $x_i$, $1 \le i \le n$, after you have chosen earlier values. For every HAP containing $i$ we compute the discrepency along the HAP containing i. We ignore those HAP so that the discrepency is smaller than T. For an HAP so that the discrepency D is larger than T, if the sum is negative we give weight (D/T) to +1 and weight 1 to -1. If the sum is negative we give the weight (D/T) to -1 and weight 1 to 1. (D is the absolute value of the sum.) (We can also replace D/T by a fixed constant, say 2.)
Now when we chose $x_i$ we compute the prduct of these weights for the choise +1 and for the choise -1 and choose at random according to these products.
I propose to choose T as something like $\sqrt{\log n \log\log n}$ or a little bit higher. We want to find a T so that typically for every i only a small (perhaps typically at most 1) number of HAP will contribute non trivial weights. We experiment this algorithm for various ns and Ts.
• Gil Says:
Actually, when we move from the spacing k to the discrepency inside the intervals, we do pay a price from time to time. And it seems that if you consider n intervals as we do there will be intervals whose discrepency is $\sqrt{\log n}$ larger than expected. This brings us back to the $\log n$ area.
I still propose to experiment what I suggested in the previos post but would expect that this will lead to examples with discrepency in the order of $\log n$.
I see no heuristic arument that we can go below $\log n$ discrepency. But for certain measures of average discrepency the heuristic remains at $\sqrt{\log n}$).
14. gowers Says:
This is a response to this comment of Moses, but that subthread was getting rather long, so I’m starting a new one.
What you say is of course a good point, and one that, despite its simplicity, I had missed. Let me spell it out once again. If we manage to find an identity of the form
$\displaystyle \sum_{kd\leq n}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2=\sum_{m\leq n}b_mx_m^2+\sum_iL_i(x)^2,$
with all coefficients non-negative, the $c_{k,d}$ summing to 1 and the $b_m$ summing to $\omega(n)$, then not only will we have proved EDP, but we will have shown a much stronger result that applies to all sequences $x_1,\dots,x_n$ (and even vector sequences, but let me not worry about that for now).
To give an example of the kind of implication this has, let us suppose that $A$ is any set such that $\sum_{m\in A}b_m\leq\omega(n)/2$, then we must be able to prove that EDP holds for sequences that take the value 0 on $A$ and $\pm 1$ on the complement of $A$, since for such a sequence we know that
$\displaystyle \sum_{kd\leq n}c_{k,d}(x_d+x_{2d}+\dots+x_{kd})^2\geq \sum_{m\notin A}b_m\geq\omega(n)/2.$
We know that there are subsets on which EDP holds. An obvious example is the set of all even numbers. As Moses points out, the set of all factorials is not even close to being an example. In general we do not have to stick to subsets: the experimental evidence suggests that we should be looking at weighted sets, where the discussion is a bit more complicated.
An obvious preliminary problem is to try to come up with a set of integers of density zero such that EDP does not obviously fail for sequences that are $\pm 1$ inside that set and 0 outside. Unfortunately, there is a boring answer to this. If EDP is true, then let $n_k$ be such that all $\pm 1$ sequences of length $n_k$ have discrepancy at least $k$. Now take all integers up to $n_1$, together with all even numbers up to $2n_2$, all multiples of 4 up to $4n_3$, and so on. The density of this set is zero and it has been constructed so that EDP holds for it.
However, it may be that this gives us some small clue about the kind of sequence $(b_m)$ we should be looking for.
• gowers Says:
Here is another attempt to gain some intuition about what is going on in the SDP approach to the problem. I want to give a moderately interesting example (but only moderately) of a situation where it is possible to remove a diagonal part from a quadratic form and maintain positive semidefiniteness. It is chosen to have a slight resemblance to quadratic forms based on HAPs, which one can think of as sets that have fairly small intersections with each other, but a few points that belong to a larger than average number of sets.
To model this, let us take a more extreme situation, where we have a collection of sets that are almost disjoint, apart from the fact that one element is common to all of them. To be precise, let us suppose that we have $r$ subsets $A_1,\dots,A_r$ of $\{2,3,\dots,r+1\}$, each of size $q$, with $|A_i\cap A_j|=1$ for every $i\ne j$ such that for every $x\ne y$ belonging to $\{2,3,\dots,r+1\}$ there is exactly one $A_i$ that contains both $x$ and $y$. Such systems (projective planes) are known to exist, though I may have got the details slightly wrong — I think $r$ works out to be $q^2+q+1$.
Now let us consider the quadratic form $\sum_i(x_1+\sum_{j\in A_i}x_j)^2$. Thus, we are adding the element 1 to each set $A_i$ and taking the quadratic form that corresponds to this new set system. It is not hard to check that the coefficient of $x_1^2$ is $r$, the coefficient of $x_1x_i$ is $2q$ (because for each $j$ there turn out to be exactly $q$ sets $A_i$ that contain $j$), the coefficient of $x_i^2$ is $q$ when $i\geq 2$ (for the same reason) and the coefficient of $x_ix_j$ when $2\leq i is 2.
It follows, if my calculations are correct, that the form can be rewritten as
$(qx_1+x_2+\dots+x_{r+1})^2+$
$+(r-q^2)x_1^2+(q-1)(x_2^2+\dots+x_{r+1}^2).$
To me this suggests that a more efficient way of representing some average of squares over HAPs may well involve something like putting together bunches of HAPs that and replacing the corresponding sum of squares by sums of squares of linear forms that have weights that favour numbers that belong to many of the HAPs — that is, smoother numbers.
One problem is that we may have two numbers $m$ and $n$ that are both very smooth but nevertheless $(m,n)=1$. But that may be where the bunching comes in. For example, perhaps it would be useful to take a large smooth number $n$ and look at all HAPs that contain $n$, and try to find a more efficient representation for just that bunch. (That doesn’t feel like a strong enough idea, but exploring its weaknesses might be helpful.)
15. Alec Edgington Says:
While wondering about heuristic arguments for EDP I did a very simple calculation which leaves me somewhat puzzled.
Consider the set of all $\pm 1$-valued sequences on $\{ 1, 2, \ldots, n\}$ as a probability space, with all sequences having equal probability $2^{-n}$. Let $M$ be the event ‘sequence is completely multiplicative’, and $K_C$ the event ‘partial sums are bounded by $C$’. Then $\mathrm{P}(M) = 2^{\pi(n) - n}$, and I think that $\mathrm{P}(K_C) \sim k_C / \sqrt{N}$ (for some constant $k_C$).
If we were to assume that $M$ and $K_C$ are independent, we would get $\mathrm{P}(M \cap K_C) \sim k_C 2^{\pi(n) - n} / \sqrt{n}$. Since $2^{\pi(n)}$ is much bigger than $\sqrt{n}$, this means we would expect there to be lots and lots of completely multiplicative sequences of length $n$ with discrepancy $C$.
What puzzles me is not that the assumption of independence is wrong but just how wrong it is. If EDP is true, then the multiplicativity of a sequence must force the discrepancy to be large in a big way. Of course, we know that it forces $f(a^2 n) = f(n)$, so that the sequence ‘reproduces’ itself across certain subsequences, but this doesn’t seem enough to explain the above.
• Gil Says:
The probability that the partial sums are bounded are exponentially small, no?
• gowers Says:
I don’t suppose you’ll be satisfied with this answer, but part of the explanation is surely that if a sequence is multiplicative and has bounded partial sums, then it has bounded partial sums along all HAPs. So if that is impossible, then …
I see that that’s not much more than a restatement of the question. Perhaps one way to gain intuition would be to think carefully about the events “has partial sums between -C and C” and “is 2-multiplicative”, where by that I mean that $f(2n)=f(2)f(n)$ for every $n$. Do these two events appear to be negatively correlated? (I can’t face doing the calculation myself.) It may be that the negative correlation doesn’t show up at this point, in which case this question will not help.
• Alec Edgington Says:
Gil: unless I’m misunderstanding something, the probabiity of the partial sum being within a certain bound goes down as $n^{-\frac{1}{2}}$, corresponding to the height around zero of the density function of a Gaussian variable with mean zero and variance $n$. (We actually want the maximum rather than the final height, but I think this behaves similarly.)
Tim: that sounds like a good idea; I’ll look at that…
• gowers Says:
Alec, I think Gil is probably right. Intuitively, if you want to force a random walk to stay within [-C,C], then you will have to give it a nudge a positive proportion of the time, which is restricting it by an exponential amount. In the extreme case where C=1 this is clear — every other move of the walk is forced.
To put it another way, and in fact, this is a proof, you cannot afford to have a subinterval with drift greater than 2C. But for this to happen with positive probability, the subinterval needs to have size a constant times $C^2$, so the probability that it never happens is at most something like $\exp(-cn/C^2)$ for some absolute constant $c$.
• Alec Edgington Says:
Sorry, yes, you’re right. I was misinterpreting a result about the maximum value attained (as opposed to the maximum absolute value). That alleviates my puzzlement.
16. Gil Kalai Says:
Another technique which is fairly standard and may be useful in the lower bound direction is the “polynomial technique”. Say you want to prove that every long enough sequence has discrepency at least 3. Consider polynomials in the variables $x_1,x_2,\dots,x_n$ over a field with 7 elements. Now mod our by the equation $x_i^2=1$. We want to show that a certain polynomial is identically zero. The polynomial is: $\prod \prod (\sum_{i=1}^mx_{ir}-3)(\sum_{i=1}^mx_{ir}+3)$, where the products are over all r and all m smaller than n/r. Once we forced the identity $x_i^2=1$ we can reduce every such polynomial to square free polynomial and what we need to show is that for large enough n this polynomial is identically zero.
In case the formula wont compile: you take the product of all partial sums -3 times the same sum + 3, over all HAPs.
(If you prefer to consider polynomials over the field and not mod up by any ideal you can replace the $x_i$ by $x_i^3$ and add the product of all $x_i$s as another term.)
We use the fact that if the discrepency is becoming greater than 2 then some of the above sums will be +3 or -3 modulo 7.
On the one hand, it feels like simply reformulating the problem, but on the other hand, maybe it is not. Perhaps, the complicated product can be simplified or some other algebraic reason why such products ultimately vanish exist. This type of technique is sometimes useful for problems where we can think also of semi definite/linear programming methodsl.
I also share the feeling that at present Moses’s semidefinite program is the most promising.
17. Klas Markström Says:
A while back we were looking at multiplicative functions such that $f(3x)=0$ for all $x$, and one question which was raised was wether a function of this type, with bounded discrepancy , must be the function 1, -1, 0, 1, -1, 0, 1, -1, 0,…
http://gowers.wordpress.com/2010/02/08/edp7-emergency-post/#comment-6094
I could not see an intuitive reason for why this should be true, apart from just not managing to construct a counterexample. Has anyone looked more at this?
I used one of my old Mathematica program to search for a multiplicative function of this type, with $f(1)=1$, and while I had lunch it found an assignment to the first 115 primes which works up to n=630.
Here is the values for the primes
{-1,0, 1, -1, 1, -1, 1, -1, -1, 1, -1, 1, 1, -1, -1, 1, -1, -1, -1, -1,
1, 1, -1, 1, 1, -1, 1, -1, 1, 1, -1, -1, 1, -1, -1, -1, 1, -1, -1, 1,
1, -1, -1, 1, -1, 1, 1, 1, 1, -1, 1, -1, 1, -1, 1, -1, 1, -1, -1, -1,
-1, 1, 1, 1, -1, -1, 1, 1, 1, 1, -1, -1, -1, 1, 1, 1, 1, -1, -1, -1,
1, -1, 1, -1, -1, -1, 1, -1, -1, -1, -1, 1, 1, -1, -1, 1, 1, 1, -1,
1, -1, -1, -1, 1, -1, -1, -1, 1, 1, 1, -1, -1, 1, -1, -1}
The function for all x is then
{1, -1, 0, 1, 1, 0, -1, -1, 0, -1, 1, 0, -1, 1, 0, 1, 1, 0, -1, 1, 0, \
-1, -1, 0, 1, 1, 0, -1, 1, 0, -1, -1, 0, -1, -1, 0, 1, 1, 0, -1, 1, \
0, -1, 1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, 1, 1, 0, -1, -1, 0, -1, 1, \
0, 1, -1, 0, -1, 1, 0, 1, -1, 0, 1, -1, 0, -1, -1, 0, 1, 1, 0, -1, \
-1, 0, 1, 1, 0, -1, 1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, \
1, 0, -1, -1, 0, 1, -1, 0, -1, 1, 0, -1, 1, 0, 1, -1, 0, 1, 1, 0, -1, \
1, 0, -1, -1, 0, 1, -1, 0, 1, 1, 0, -1, 1, 0, -1, -1, 0, 1, -1, 0, 1, \
-1, 0, 1, -1, 0, -1, 1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, -1, 1, 0, 1, \
-1, 0, 1, -1, 0, -1, 1, 0, -1, 1, 0, -1, 1, 0, -1, -1, 0, 1, 1, 0, 1, \
-1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, \
-1, -1, 0, 1, 1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, 1, 1, 0, -1, 1, 0, \
-1, 1, 0, -1, 1, 0, -1, -1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, 1, 1, 0, \
-1, -1, 0, -1, 1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0, 1, -1, 0, -1, 1, \
0, -1, 1, 0, -1, 1, 0, -1, 1, 0, 1, -1, 0, -1, -1, 0, 1, -1, 0, 1, \
-1, 0, 1, 1, 0, -1, -1, 0, 1, 1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0, 1, \
1, 0, -1, -1, 0, 1, -1, 0, 1, 1, 0, -1, -1, 0, -1, 1, 0, -1, 1, 0, 1, \
-1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, -1, 1, 0, 1, 1, 0, -1, \
-1, 0, -1, 1, 0, -1, -1, 0, 1, 1, 0, 1, 1, 0, -1, -1, 0, -1, -1, 0, \
1, -1, 0, 1, -1, 0, 1, -1, 0, 1, 1, 0, -1, -1, 0, 1, 1, 0, -1, -1, 0, \
1, 1, 0, -1, -1, 0, 1, -1, 0, 1, -1, 0, 1, 1, 0, -1, -1, 0, 1, 1, 0, \
-1, 1, 0, 1, 1, 0, -1, -1, 0, -1, 1, 0, 1, -1, 0, 1, 1, 0, -1, -1, 0, \
1, 1, 0, -1, -1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, 1, 1, 0, -1, 1, 0, \
-1, 1, 0, -1, -1, 0, -1, 1, 0, -1, -1, 0, 1, 1, 0, 1, -1, 0, -1, -1, \
0, 1, 1, 0, -1, -1, 0, 1, 1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0, -1, 1, \
0, -1, 1, 0, 1, 1, 0, -1, 1, 0, -1, 1, 0, -1, -1, 0, -1, 1, 0, -1, 1, \
0, 1, 1, 0, -1, -1, 0, 1, -1, 0, 1, -1, 0, 1, -1, 0, -1, 1, 0, -1, 1, \
0, 1, 1, 0, -1, 1, 0, -1, 1, 0, -1, -1, 0, -1, 1, 0, -1, -1, 0, 1, \
-1, 0, 1, -1, 0, 1, 1, 0, 1, 1, 0, -1, -1, 0, 1, -1, 0, -1, -1, 0, 1, \
1, 0, 1, -1, 0, -1, -1, 0, 1, 1, 0, 1, 1, 0, -1, -1, 0, -1, 1, 0, 1, \
-1, 0, -1, 1, 0, -1, 1, 0, 1, 1, 0, -1, -1, 0, 1, 1, 0, -1, -1, 0, \
-1, -1, 0, 1, 1, 0, 1, 1, 0
• Klas Markström Says:
The point of the example of course being that it is distinct from the unique example with discrepancy 1 even for small values of $x$.
For a finite bound $N$ one will typically be able to construct trivial examples defined on the first $N$ integers simply by changing the values at the primes closest to $N$, since they are not affected by the multiplicative requirement.
• Alec Edgington Says:
One can get at least as far as 886 with a sequence like this of discrepancy 2 sending 5 to $+1$:
+-0++0--0-+0-+0++0-+0--0++0-+0--0--0++0-+0-+0+-0+-0--0++0-+0-+0+-0-+0++0--0--0++0
--0++0-+0+-0+-0--0+-0++0+-0+-0-+0-+0--0++0-+0+-0+-0++0-+0--0--0++0+-0-+0+-0+-0-+0
-+0+-0+-0-+0-+0-+0--0++0+-0+-0-+0++0--0+-0+-0--0+-0+-0+-0+-0++0-+0++0--0-+0+-0+-0
-+0++0-+0--0++0--0++0--0-+0-+0-+0-+0+-0-+0+-0+-0--0+-0++0++0--0+-0++0--0+-0++0--0
-+0-+0+-0+-0+-0+-0-+0-+0-+0--0++0--0++0+-0+-0-+0+-0+-0+-0++0-+0-+0--0-+0-+0+-0+-0
++0--0+-0-+0+-0--0++0+-0+-0+-0++0--0+-0+-0-+0++0-+0--0-+0-+0+-0++0--0--0++0--0+-0
++0-+0+-0--0++0-+0-+0+-0+-0-+0-+0++0--0--0++0+-0-+0-+0++0-+0-+0--0-+0-+0+-0+-0++0
-+0--0+-0--0++0-+0+-0+-0++0--0-+0+-0-+0-+0++0--0++0--0--0++0++0--0++0--0-+0-+0+-0
++0-+0-+0-+0--0++0--0+-0+-0+-0+-0+-0++0-+0-+0--0++0--0-+0++0--0-+0-+0++0--0-+0+-0
+-0+-0+-0++0-+0--0++0--0+-0+-0++0--0--0++0-+0-+0--0++0++0-+0--0++0-+0--0+-0+-0++0
--0--0++0++0--0+-0-+0-+0--0+-0++0++0--0--0+-0++0--0+-0+-0++0+-0--0++0++0--0+
Here the following primes are sent to $-1$: 2, 7, 13, 19, 23, 31, 43, 47, 53, 61, 67, 73, 83, 97, 101, 107, 131, 139, 149, 151, 163, 167, 181, 191, 193, 199, 233, 239, 271, 277, 281, 283, 293, 313, 317, 349, 353, 359, 397, 401, 409, 419, 421, 431, 439, 443, 457, 463, 467, 509, 523, 547, 563, 571, 577, 587, 607, 613, 619, 631, 643, 647, 661, 677, 683, 691, 701, 709, 751, 787, 811, 823, 827, 829, 839, 859, 863, 883.
I can’t see much of a pattern, but there seems to be quite a bit of freedom to assign either $(+1, -1)$ or $(-1, +1)$ at twin-prime pairs $(3k-1, 3k+1)$.
• Alec Edgington Says:
That search finally terminated — so that is the longest such sequence we can get that sends 5 to +1.
• Klas Markström Says:
Alec, could you try that with the value at 7 flipped instead? It would be interesting to see how much further one gets by following the discrepancy 1 function out to different primes.
• Alec Edgington Says:
OK, I’ll try that when I get back to my computer this evening.
• Alec Edgington Says:
In this case (flipping the value at 7) the maximal length of sequence (or rather, the maximal length that is of the form $p-1$ — which is what I should have said above too) is 946:
+-0+-0--0++0-+0+-0+-0-+0++0--0+-0++0--0+-0-+0-+0+-0-+0-+0+-0+-0++0--0--0++0+-0--0
+-0++0--0++0--0+-0++0++0-+0-+0--0--0++0+-0+-0+-0-+0-+0+-0-+0+-0+-0-+0+-0+-0-+0+-0
+-0+-0+-0-+0-+0+-0+-0-+0-+0+-0+-0+-0+-0-+0+-0-+0-+0-+0-+0-+0-+0+-0-+0++0--0-+0+-0
+-0--0+-0+-0+-0++0-+0-+0--0+-0++0-+0--0+-0++0+-0+-0++0--0+-0+-0+-0+-0++0-+0--0+-0
--0+-0+-0++0+-0++0-+0-+0-+0--0+-0+-0+-0+-0++0--0++0-+0--0+-0+-0+-0--0++0+-0+-0-+0
--0+-0++0++0-+0-+0--0-+0--0++0-+0++0--0++0-+0--0+-0-+0-+0+-0--0++0+-0++0--0+-0+-0
--0+-0++0++0--0++0--0++0--0+-0+-0--0++0--0++0-+0-+0++0--0++0--0--0++0--0++0+-0+-0
+-0+-0-+0--0++0+-0+-0+-0-+0-+0+-0+-0+-0+-0+-0+-0+-0--0++0+-0-+0++0--0-+0+-0+-0+-0
-+0+-0--0++0+-0++0--0-+0+-0++0--0--0++0--0++0-+0++0--0-+0+-0--0++0+-0+-0--0+-0+-0
++0+-0--0++0++0--0--0++0--0++0+-0+-0++0--0+-0+-0+-0-+0++0--0-+0--0++0--0++0++0--0
-+0+-0--0++0+-0-+0+-0--0++0-+0++0--0-+0+-0++0--0-+0++0--0--0++0-+0+-0--0++0++0--0
-+0++0--0-+0+-0+-0+-0-+0--0++0-+0--0+-0++0++0--0-+0--0+
(Primes sent to -1 in this example: 2, 5, 7, 13, 17, 29, 37, 41, 43, 59, 67, 71, 79, 83, 89, 109, 113, 137, 139, 157, 167, 179, 191, 197, 211, 223, 227, 229, 251, 257, 269, 277, 281, 293, 311, 349, 353, 359, 379, 383, 389, 401, 421, 431, 443, 457, 467, 479, 487, 491, 499, 521, 541, 547, 557, 563, 569, 577, 587, 599, 617, 619, 641, 647, 653, 683, 701, 709, 719, 761, 769, 773, 787, 809, 811, 857, 859, 881, 911, 929, 937.)
I’ll kick off a search with 11 flipped, but won’t hold my breath for it to finish!
• Alec Edgington Says:
Well, I’ll have to eat my words. It finished almost immediately, having got only as far as 330:
+-0+-0+-0++0--0+-0+-0--0++0+-0+-0+-0+-0+-0-+0+-0+-0-+0--0+-0+-0++0+-0+-0--0++0+-0
+-0++0--0--0+-0+-0+-0++0-+0-+0+-0+-0+-0+-0+-0+-0--0+-0+-0+-0+-0++0+-0+-0--0+-0+-0
+-0++0+-0--0++0+-0-+0+-0--0+-0+-0++0+-0+-0+-0-+0-+0-+0++0-+0--0+-0+-0+-0+-0+-0+-0
+-0--0++0--0+-0++0+-0--0+-0+-0++0+-0+-0+-0+-0+-0--0+-0++0--0+-0++0+-0+-0++0--0+-0
--0+-0
(Primes sent to -1: 2, 5, 13, 17, 23, 29, 41, 43, 47, 59, 71, 73, 83, 89, 101, 109, 113, 131, 137, 149, 173, 179, 181, 191, 211, 223, 227, 233, 239, 257, 263, 269, 281, 293, 311.)
I had assumed that the maximum length would be a monotonic function of the first prime flipped, but evidently not…
• Alec Edgington Says:
I’ve now gone a bit further with this, and found:
min p flipped max n (n+1 prime)
5 886
7 946
11 330
13 >= 1380
17 408
19 >= 2646
23 22
29 >= 546
31 >= 9906
37 >= 27508
41 >= 690
43 >= 24420
47 46
53 52
59 >= 1326
61 >= 15072
It seems that flipping a prime of the form $3k+1$ is much better than flipping a prime of the form $3k-1$. (Perhaps this isn’t too surprising, as it means we don’t immediately require $f(3k+4)$ to change sign to keep the discrepancy at 2, but I’m not sure that fully explains it.)
• Klas Markström Says:
That’s an interesting sequence. I would not have expected the different $p$:s to give such different lengths.
However the fact that one can find sequences as long a the ones you have found for some primes, suggest that any proof showing that the maximum length is finite for any $p$ will have to be rather indirect, not giving a good bound for the maximum length.
18. Moses Charikar Says:
As Tim pointed out earlier, the Cholesky decomposition is greedy and does not necessarily give an efficient decomposition into sum of squares that uses the diagonal sparingly. But I want to propose using it as a proof technique for positive semidefiniteness after we have subtracted out the diagonal terms. If we can prove that the Cholesky decomposition succeeds, this proves that the matrix is positive definite. Put differently, I want to try and figure out what $b_i$ values we can get away with without making the Cholesky decomposition procedure fail.
Let’s review how Cholesky works. The goal is to represent positive definite matrix $A = V V^T$ such that $V$ is a lower triangular matrix. If $V_i$ is the $i$th row of $V$, the only non-zero coordinates of $V_i$ are in the first $i$ positions, and $V_i \cdot V_j = A_{ij}$.
The algorithm proceeds thus: $V_{11} = \sqrt{A_{11}}.$ Having determined $V_1, V_2, \ldots, V_{i-1}$, the coordinates of $V_i$ are determined thus: $V_{i,1}$ is completely determined by the condition $V_1 \cdot V_i = A_{1,i}$. Next, $V_{i,2}$ is determined by $V_2 \cdot V_i = A_{2,i}$ and so on. Finally, $V_{i,i}$ is determined by the constraint: $\sum_{j \leq i} V_{i,j}^2 = A_{ii}$. The procedure succeeds if, for all $i$, in the computation of $V_{i,i}$, $A_{ii}-\sum_{j < i} V_{i,j}^2\geq 0$.
Consider what happens if, for a particular $i$, we subtract $b_i$ from $A_{i,i}$ and compute the new Cholesky decomposition. Since $A_{i,i}$ is smaller, $V_{i,i}$ will become smaller. This in turn will increase the values of $V_{j,i}$ for $j > i$. This sets off a chain reaction and decreases $V_{j,j}$ values for $j > i$. If we subtract too much, we run the risk of the Cholesky decomposition failing. But if it does fail, we know for sure that we have ruined positive definiteness.
Now suppose we know the Cholesky decomposition of matrix $A$. This might help us guess what diagonal terms we can safely subtract from $A$. I’m hoping that the large diagonal $V_{i,i}$ in the decomposition give us clues for where we can hope to subtract $b_i$ (although there are complex dependencies and subtracting a small amount from one location changes a whole bunch of other elements in the decomposition.)
• Moses Charikar Says:
Here is a setting I want to think about, with some assumptions on various parameters slightly different from the ones that Tim proposed earlier. I’m going to repeat a few things from previous comments. Recall that we are interested in the quadratic form $\displaystyle \sum_{k,d} c_{k,d} (x_d + x_{2d} + \ldots + x_{kd})^2$
As before $\sum_{j \geq k} c_{j,d} = \tau_{k,d} = C_d e^{-\alpha kd}$. Consider $\alpha$ to be very small. We’ll use this to make some approximations. Say $C_d = 1$ for all $d$. (I hope this will turn out to be an easier setting to analyze and understand).
Note that $\sum_{k,d} c_{k,d} = \sum_d \tau_{1,d} = \sum_d e^{-\alpha d} \approx 1/\alpha$.
Consider the symmetric matrix $A$ corresponding to the quadratic form above (i.e. the quadratic form is $x^T A x$). We hope to subtract a large diagonal term $\sum b_i x_i^2$ such that the remainder is still positive semidefinite. For $m \geq n$, the entry $A_{m,n} = e^{-\alpha m} d((m,n))$ where $d(i) =$ the number of divisors of $i$.
First, lets figure out the Cholesky decomposition for $\alpha = 0$. In this case, $A_{m,n} = d((m,n))$. This has a nice form which is obvious in retrospect: $V_{m,n} = 1$ if $n|m$ and $V_{m,n} = 0$ otherwise. In other words, the $n$th column is the indicator function for the infinite HAP with common difference $n$. It is easy to verify that $V_m \cdot V_n = d((m,n))$ since $V_{md} = V_{nd} = 1$ precisely when $d|m$ and $d|n$.
The next step is to figure out what the decomposition is for this setting of parameters with $\alpha > 0$ and very small. I want to obtain approximate expressions for the entries of the Cholesky decomposition as linear expressions in $\alpha$, i.e. by dropping higher order terms from the Taylor series. I’m hoping that the relatively structured form of the matrix will allow us to get closed form approximations for the entries of this decomposition, and further that, it will result in diagonal elements $V_{n,n}$ being relatively high for $n$ with many divisors. If so, this should help us subtract large $b_n$ values for such $n$.
• Moses Charikar Says:
I tried calculating the coefficients of $\alpha$ for the entries of the Cholesky decomposition of the matrix described above. (The constant term for each entry is given by the Cholesky decomposition for $\alpha = 0$ determined above).The computation of the $\alpha$ coefficients seemed too tedious (and error-prone) to do by hand, so I wrote some code to do it. Here is the output of the code for the first 100 rows of the decomposition. The format of each line of the file is
i j $\beta(i,j)$
where $\beta(i,j)$ is the coefficient of $\alpha$ in the Taylor expansion of $V_{i,j}$. It seems to match some initial values I computed by hand, so I hope the code is correct. I can’t say I understand what these values are, but it is reassuring to see that for $n$ with many divisors,
$\beta(n,n)$ seems to be large. On the other hand it seems to be
$-1/2$ for prime $n$. I hope this means that we can subtract out large values of $b_n$ for $n$ with many divisors while maintaining the property that the Cholesky decomposition continues to proceed successfully. To prove that Cholesky works, we will need to show upper bounds on $|V_{i,j}|$ for $i > j$ and lower bounds on the diagonal terms $V_{i,i}$ (for the decomposition of the matrix with the diagonal form subtracted out).
Before we do that, we need to understand what these coefficients $\beta(i,j)$ are and why the values $\beta(n,n)$ are large for $n$ with many divisors. Any ideas ?
• gowers Says:
I’ve just had a look in Sloane’s database to see if there are any sequences that match the values $\beta(n,n)$ but had no luck (even after various transformations, such as multiplying by 2, or multiplying by 2 and adding 1). But it might be worth continuing to look.
• gowers Says:
A couple of small observations. I think if we continue along these lines we will be able to get a formula for the diagonal values.
The observations are that $2^k$ maps to $(k-2)2^{k-2}$ for every $k$ (so far, that is) and that $3^k$ maps to $(k-3/2)3^{k-1}$ for every $k$. I’ll continue to look at powers for a bit and then I’ll move on to more general geometric progressions (an obvious example being 3,6,12,24,48,96) and see what pops out.
• gowers Says:
A formula that works when $p=2,3,5$ and gives the right value for k=0 and k=1 is that $p^k$ maps to $((\frac{p-1}2)k-p/2)p^{k-1}$. I suspect it is valid for all prime powers but have not yet checked.
Maybe this looks more suggestive if we rewrite it as $\frac 12 ((1-1/p)k-1)p^k$.
• Moses Charikar Says:
Very interesting. I’ve put up a file with only the diagonal entries upto 1000 here . It is tedious to look for diagonal entries in the earlier file. I’ve also included prime factorizations in the new file.
• gowers Says:
Sorry — had to do something else.
But I’ve now checked the GP 3,6,12,… and we get the formula $f(3.2^k)=2^{k-2}(7k-2)$.
Next up, the GP 5,10,20,40,… which gives the formula $f(5.2^k)=2^{k-2}(11k-2)$.
So I’d hazard a guess that $f(p.2^k)=2^{k-2}((2p+1)k-2)$. Let me do a random check by looking at $f(88)$. If my guess is correct, this should be $2^{3-2}\times 23=46$ and in fact it is … 134. Let me try that again. It should be $2^{3-2}(23\times 3-2)=2\times 67=134$. So I believe that formula now.
• gowers Says:
It’s taken me longer than it should have, but I now see that we ought to be looking not at $f(n)$ but at $f(n)/n$. Somehow, this is where the “real pattern” is.
When $n=p^k$ we get $f(n)/n=(1/2)((1-1/p)k-1)$, and when $n=2^kp$ we get $f(n)/n=(1/4)((2+1/p)k-2/p)=(1/2)(1+1/2p)k-1/p)$.
I think an abstract question is emerging. Suppose we know that, as seems to be the case, for any $a$ and $p$ we have a formula of the kind $f(ap^k)=p^k(uk+v)$. With enough initial conditions, that should determine $f$. We already have a lot of initial conditions, since we know that $f(1)=f(p)=-1/2$ for every prime $p$. Those conditions are enough to determine $f(p^k)$, but they don’t seem to be sufficient to do everything. For that I appear to need to know $f$ at all square-free numbers, or something like that.
• gowers Says:
For primes $p,q$ with $p the formula appears to be
$f(pq)=q(p-1)-1/2$. I inducted that from a few small instances, and then checked it on $407=11\times 37$. My formula predicts $370-1/2=369.5$ and that is exactly what I get.
In keeping with the general idea of looking at $f(n)/n$, let me also write this formula as $f(pq)/pq=1-1/p-1/2pq$.
A small calculation, which I shall now do, will allow me to deduce the formula for $p^aq^b$.
• Moses Charikar Says:
Ok, I think we should have the diagonal values figured out soon, although understanding why these numbers arise will take more effort. Looking ahead, the hope was that large numbers are an indication that large $b_i$ can be subtracted out from those entries without sacrificing positive semidefiniteness. At this point, I don’t have a clue about how these $b_i$ should be picked. We can experiment with some guesses later.
Question for later:
The hope is that for any $C$, for suitably small $\alpha$, we can pick $b_i$ such that $\sum b_i > C/\alpha$. At this point, I haven’t thought through why this should necessarily be the case. Is there a heuristic argument that we have enough mass on the diagonal to pull this through ?
I am going to have to sign off for a while and get back to this later in the day.
• gowers Says:
For $n=p^kq$ with $p I get
$f(n)=kp^{k-1}(p-1)(q+1/2)-p^k/2$
or equivalently
$f(n)/n=k(1-1/p)(1+1/2q)-1/2q.$
I’ll add to this comment when I get a formula for $p^aq^b$, which should be easy now.
• Alec Edgington Says:
All very interesting. Another thing to note about the $\beta(i,j)$ is that the fractional part is $\frac{1}{2}$ precisely when $j \mid i$ and $4 \nmid j$.
• gowers Says:
I got the following formula for $f(p^aq^b)/p^aq^b$:
$\frac 12(1-\frac 1p)a((1+\frac 1q)b+1)+\frac 12((1-\frac 1q)b-1).$
I have tried it out on $225=3^2.5^2$ and got the answer $f(225)=577.5$, which was correct. So I believe this formula too.
Just to repeat what I am doing here, I am assuming that the function $f(n)/n$ takes geometric progressions to arithmetic progressions and deducing what I can whenever I know what two values are. In this way, knowing $f$ for prime powers and for products of two primes was enough to give me $f$ for all numbers of the form $p^aq^b$. Sorry — correction — I have assumed that only for GPs with prime common ratio. I haven’t looked at what happens when the common ratio is composite.
Come to think of it, if $f(n)/n$ takes GPs with prime common ratio to APs, then $\exp(f(n)/n)$ takes GPs with prime common ratio to GPs, which is a pretty strong multiplicativity property. That leads me to think that the eventual formula is going to be quite nice. I hope I’ll be able to guess it after working out $f(pqr)/pqr$, or perhaps I’ll have to do $f(p^aq^br^c)/p^aq^br^c$. But first I need some lunch.
• gowers Says:
Here’s a slightly more transparent way of writing the formula for $f(p^aq^b)/p^aq^b$:
$\frac 12(1-\frac 1p)(1+\frac 1q)ab+\frac 12(1-\frac 1p)a+\frac 12(1-\frac 1q)b-\frac 12.$
• gowers Says:
Just before I dive into the calculations, let me make the remark that the signs are that the formula will be an inhomogeneous multilinear one in the indices. More precisely, I am expecting a formula of the following kind for $f(n)/n$ when $n=p_1^{a_1}\dots p_r^{a_r}$ and the primes $p_1,\dots,p_r$ are in increasing order:
$\frac 12\sum_{A\subset\{1,\dots,k\}}\prod_{j\in A}(1+\frac{c_{A,j}}{p_j})a_j-1.$
• gowers Says:
I’ve just wasted some time going about this a stupid way, which was to calculate $f(pqr)/pqr$ for several values and try to spot a pattern. But I now see that that was unlikely to be easy, since the dependence on $1/p$, $1/q$ and $1/r$ is trilinear. The values look quite strange too, but I have a new plan. That plan is to try to find a formula for $f(6p^k)/6p^k$ when $p$ is a prime greater than 3. That should give me some coefficients of a linear function in $k$. If I repeat the exercise for one or two other small products of two primes, then it should be easyish to spot a formula for the coefficients, and then I’ll have a formula for $f(pqr^k)$, which will be a good start. In fact, it will be more than just a start, as from that and the multilinearity assumption I’ll be able to work out all the rest of the values at products of three prime powers.
• gowers Says:
Oh dear, for the first time I have run up against an anomaly in the data that may be hard to fit into a nice pattern. When $p$ is any of 7,11,13,17 or 19 the value of $f(6p)/6p$ is given by the formula $2-(2p-5)/12p$, but when $p=5$ we get instead $2-(2p-7)/12p$. But I’ll continue with this and try not to worry about $f(30)$ too much for now. (But I would love to learn that it was wrong and should have been 57.5 instead of 58.5.)
• Moses Charikar Says:
I’ve added an even bigger file with diagonal entries upto 10,000 in this directory in case you are looking for more data points to verify guesses for formulae. The directory also contains the C code (cholesky.c) used to generate the lower triangular matrix of coefficients and another piece of code (cholesky2.c) to generate the diagonal entries only. I really hope the code is not buggy !
• Moses Charikar Says:
Uh oh … I spotted a tiny problem in the code which could potentially affect the calculation for rows and columns greater than n/2. Except that for some mysterious reason it doesn’t. i.e. the output is exactly the same after fixing the “bug”. Basically, I was not setting the constant term in the Taylor expansion correctly for diagonal entries > n/2. It should have been 1 and was being set to 0 instead. This could potentially affect the calculation of the coefficient of $\alpha$ for all entries in columns > n/2, but apparently it does not. I’m checking to see if there are any other issues.
• Moses Charikar Says:
I looked over the code and as far as I can tell, it is correct. I now understand why the “bug” above did not really change anything.
• gowers Says:
After further investigation, I no longer think the value at 30 is anomalous, but I have discovered (with much more effort than I thought would be needed, because the pattern is clearly subtler than I thought it would be) the following formula for $f(2^kpq)/2^kpq$. We know from earlier that $f(pq)/pq=1-1/p-1/2pq$, so that gives us the value when $k=0$. If I call that value $a_{pq}$, then the formula, which is linear in $k$ as we expect, is
$\displaystyle a_{pq}+(1+\frac{p*q}{4pq})k,$
where $*$ is a binary operation that I do not fully understand. Let me tabulate the values that I have calculated so far:
$3*5=19, 3*7=21, 3*11=29,3*13=33,$
$5*7=31,5*11=33,5*13=37,$
$7*11=43, 7*13=43,$
$11*13=67.$
I had to calculate a lot of values before I realized that there is a nice formula for this binary operation except if $p$ and $q$ are consecutive primes. The formula is simply $p*q=2(p+q)+1$. But when $p$ and $q$ are consecutive we seem to get a little “kick” and the value is larger. In fact, by the time we get to $11*13$ the kick is not all that little.
Anyhow, this observation partially explains the mysterious anomaly at 30, but really it replaces it by a bigger mystery: why should the values be sensitive to consecutiveness of primes?
Of course, at this stage I haven’t looked at all that many numbers, so I hope that I’ll be able to ask a more precise question in due course. So far, however, I don’t feel all that close to a formula for $f(p^aq^br^c)$
• gowers Says:
Correction: the formula does not give the right value for $7*13$ either, so my understanding is worse than I thought. However, in a way that might be good news, since I found the idea of a formula that fails for consecutive primes a bit bizarre.
• gowers Says:
At some point I may ask whether somebody can write a piece of code to work out this binary operation that I am working out laboriously by hand. But for now, here are a few more values, which perhaps give us tiny further clues.
$7*17=49,$ at which point I think it is a pretty safe conjecture that if $p*q=2(p+q)+1$, then $p*r=2(p+r)+1$ for all $r\geq q$.
$11*19=67,$ so we’re not there yet with 11.
$11*23=69=2(11+23)+1$ so now we have got there.
It looks as though a necessary and sufficient condition for $p*q=2(p+q)+1$ is that $q\geq 2p$. What’s more, it looks as though $p*q$ is constant before that. So the right formula should involve maxes and things.
OK, here is my revised formula: $p*q=\max\{6p+1,2(p+q)+1\}$. Phew!
To test the earlier conjecture, let me try $7*19$. It works out to be 53, which is indeed what it should be.
And to test the new conjecture, let me try $13*19$. The prediction is 79. What I actually get is … 79. OK, I think I believe this formula now, but it will need quite a bit more slog to get a formula for $f(p^aq^br^c)/p^aq^br^c$ from here. I’ve spent several hours on this: the calculations are certainly routine enough to do on a computer, so I wonder if anyone could take over at this point. For instance, it would be good to give a formula for $f(3^kpq)$. Does it change behaviour according to whether $q<3p$ or $q>3p$?
• Alec Edgington Says:
Here’s a plot of $f(n)/n$ for $1 \leq n \leq 10\,000$:
19. gowers Says:
These calculations (of Moses in the previous comment) look very interesting and potentially fruitful. Rather than trying to duplicate them, I will continue to do what I can to refine my speculations about what the coefficients $c_{k,d}$ and $b_m$ might conceivably look like.
As has already been mentioned, an important constraint on the $b_m$ (aside from the essential one that the partial sums should be unbounded) is that if $A$ is a set for which EDP fails, then $\sum_{m\in A}b_m<\infty$. Here I am saying that EDP fails for $A$ if there exists a sequence $(x_n)$ that takes $\pm 1$ values on $A$ and arbitrary values on $\mathbb{N}\setminus A$ such that the HAP-discrepancy of $(x_n)$ is bounded. This is a necessary condition on the coefficients $b_m$, since if $\sum_{m\in A}b_m=\infty$ then we know that EDP is true for $A$. (Once again, I am not being careful about the distinction between the large finite case and the infinite case.)
In fact, it is better to think about the complex case, or even the vector case, since the SDP proof, if it succeeds, automatically does those cases as well. So let me modify that definition to say that EDP fails for $A$ if there is a bounded-discrepancy sequence of complex numbers (or vectors) that has modulus (or norm) 1 everywhere on $A$.
With this in mind, it is of some interest to have a good idea of which sets $A$ are the ones for which EDP succeeds. A trivial example is any HAP (assuming, that is, that EDP is true). An example of a set for which EDP fails is the complement of any HAP. Let me prove that in the case where the HAP has common difference 15 — it will then be clear how the proof works in general. For any $d$, let $\chi_d$ be a non-trivial character of the multiplicative group of residue classes mod $d$ that are coprime to $d$. Now define $f(n)$ to be $\chi_{15}(n)$ if $n$ is coprime to 15, $\chi_5(n/3)$ if $(15,n)=3$, $\chi_3(n/5)$ if $(15,n)=5$, and 0 if $n$ is a multiple of 15. Any HAP will run periodically through either all the residue classes mod 15, or all the residue classes that are multiples of 3, or all the residue classes that are multiples of 5, or will consists solely of multiples of 15. Whatever happens, we know that $f((15m+1)d)+f(15m+2)d)+\dots+f(15(m+1)d)=0$ for every $m$ and every $d$, and that $|f(n)|=1$ for every $n$ that is not a multiple of 15.
As Moses pointed out yesterday (to stop me getting carried away), if $A$ is the set of factorials, then EDP fails for $A$. That is because every HAP intersects $A$ in a set of the form $\{m!,(m+1)!,(m+2)!,\dots\}$, which means that we can define $x_n$ to be 0 if $n$ is not a factorial, and $(-1)^m$ if $n=m!$.
The main point of this comment is to give a slightly non-trivial example of a set for which EDP succeeds. By “non-trivial” I don’t mean mathematically hard, but just that the set is rather sparse. It is the set of perfect squares. (The proof generalizes straightforwardly to higher powers, and, I suspect, to a rich class of other sets, but I have not yet tried to verify this suspicion.)
To see this, one merely has to note what the intersection of $\{d,2d,3d,4d,\dots\}$ with $\{1,4,9,16,\dots\}$ is. The answer is that it is the set $\{r^2,4r^2,9r^2,16r^2,\dots\}$, where $r^2$ is the smallest multiple of $d$ that is a perfect square. (That is, to get $r$ from $d$ you multiply once by each prime that divides $d$ an odd number of times.) The proof that this is what you get is that a trivial necessary and sufficient condition for $d$ to divide $a^2$ is that $r^2$ should divide $a^2$.
Now suppose that EDP failed for the set of perfect squares, and let $y_n$ be the …
Hang on, my proof has collapsed. What I am proving is the weaker statement that EDP fails if you insist that the sequence is zero outside $A$. Let me continue with that assumption, though the statement is much less interesting.
Now suppose that EDP fails for the set of perfect squares, and let $y_n$ be the sequence that demonstrates this. Thus (because of our new assumption) $y_{m^2}$ has modulus 1 for every positive integer $m$, and $y_n=0$ if $n$ is not a perfect square. But then we can set $x_m=y_{m^2}$ and we have a counterexample to EDP.
This comment has ended up as a bit of a damp squib, but let me salvage something by asking the following question. Suppose that the vector version of EDP is true and that $(x_n)$ is a sequence such that $|x_{m^2}|=1$ for every $m$. Does it follow that $(x_n)$ has unbounded discrepancy?
This may be a fairly easy question, since the squares are so sparse. (If it is, then the whole point of this comment is rather lost, but a different useful point will have been made instead.) For example, perhaps it is possible to find a sequence that takes the value 1 at every square and 0 or -1 everywhere else and has bounded discrepancy.
I think there is an interesting class of questions here. For which sets $A$ does there exist a function $f$ of bounded discrepancy that takes the value 1 everywhere on $A$ and 0, 1 or -1 everywhere else? As I did in the end of this comment, one can paste together different HAPs to produce an example with density zero, but are there any interesting examples? I would expect that as soon as $A$ is reasonably sparse (in some sense that would have to be worked out — it would have to mean something like “sparse in every HAP”), it would be possible to use a greedy algorithm to prove that EDP fails. So here is a yet more specific question. Define a sequence $(x_n)$ as follows. For every perfect square it takes the value 1. For all other $n$ we choose $x_n$ so as to minimize the maximum absolute value of the partial sum along any HAP that ends at $n$, and if we have the choice of taking $x_n=0$ then we do. Thus, the first few terms of the sequence are as follows. $x_1=1$ (since 1 is a square), $x_2=0$ (since to minimize the maximum of $|x_1|$ and $|x_1+x_2|$ we can take $x_2$ to be 0 or -1 and we prefer 0), $x_3=0$ (for the same reason), $x_4=1$ (since 4 is a square), $x_5=-1$ (since $x_1+\dots+x_4=2$, so this makes the maximum at 5 equal to 1 rather than 2), $x_6=-1$, $x_7=0$, and so on. Does this algorithm give rise to a bounded-discrepancy sequence? If not, is there some slightly more intelligent algorithm that does?
|
|
## Essential University Physics: Volume 1 (3rd Edition)
Published by Pearson
# Chapter 9 - Exercises and Problems - Page 164: 47
#### Answer
a) $a= \frac{v_0dm}{Mdt}$ b) The maximum speed of the car will be equal to the speed of the water initially.
#### Work Step by Step
a) We find: $F=\frac{dp}{dt} \\ F=v_0 \frac{dm}{dt}$ Using Newton's second law, it follows: $a= \frac{v_0dm}{Mdt}$ b) Since the water bounces up at the same speed it hits at, we find that $\fbox{the maximum speed of the car will be equal to the speed of the water initially.}$
After you claim an answer you’ll have 24 hours to send in a draft. An editor will review the submission and either publish your submission or provide feedback.
|
|
# Eureka Math Precalculus Module 4 Lesson 4 Answer Key
## Engage NY Eureka Math Precalculus Module 4 Lesson 4 Answer Key
### Eureka Math Precalculus Module 4 Lesson 4 Exercise Answer Key
Exercises
Exercise 1.
Derive formulas for the following:
a. sin(2θ)
sin(2θ) = sin(θ + θ)
= sin(θ)cos(θ) + cos(θ)sin(θ)
= 2sin(θ)cos(θ)
b. cos(2θ)
cos(2θ) = cos(θ + θ)
= cos(θ)cos(θ) – sin(θ)sin(θ)
= cos2 (θ) – sin2 (θ)
Exercise 2.
Use the double – angle formulas for sine and cosine to verify these identities:
a. tan(2θ) = $$\frac{2 \tan (\theta)}{1 – \tan ^{2}(\theta)}$$
b. sin2 (θ) = (1 – cos(2θ))/2
$$\frac{1 – \cos (2 \theta)}{2}$$ = $$\frac{1 – \left(1 – 2 \sin ^{2}(\theta)\right)}{2}$$ = $$\frac{2 \sin ^{2}(\theta)}{2}$$ = sin2 (θ)
c. sin(3θ) = – 4sin3 (θ) + 3sin(θ)
sin(3θ) = sin(2θ + θ)
= sin(2θ)cos(θ) + cos(2θ)sin(θ)
= 2sin(θ)(cos(θ))(cos(θ)) + (1 – 2sin2 (θ))(sin(θ))
= 2sin(θ) cos2 (θ) + sin(θ) – 2sin3 (θ)
= 2sin(θ)(1 – sin2 (θ)) + sin(θ) – 2sin3 (θ)
= 2sin(θ) – 2sin3 (θ) + sin(θ) – 2sin3 (θ)
= – 4sin3 (θ) + 3sin(θ)
Exercise 3.
Suppose that the position of a rider on the unit circle carousel is (0.8, – 0.6) for a rotation θ. What is the position of the rider after rotation by 2θ?
x = cos(2θ) = cos2(θ) – sin2 (θ) = 0.82 – ( – 0.6)2 = 0.64 – 0.36 = 0.28
y = sin(2θ) = 2sin(θ)cos(θ) = 2( – 0.6)(0.8) = – 0.96
The rider’s position is (0.28, – 0.96).
Exercise 4.
Use the double – angle formula for cosine to establish the identity cos($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{\cos (\theta) + 1}{2}}$$
Since θ = 2($$\frac{\theta}{2}$$), the double – angle formula gives cos(2($$\frac{\theta}{2}$$)) = 2cos2 ($$\frac{\theta}{2}$$) – 1. Then we have
cos(θ) = 2cos2 ($$\frac{\theta}{2}$$) – 1
1 + cos(θ) = 2cos2 ($$\frac{\theta}{2}$$)
$$\frac{1 + \cos (\theta)}{2}$$ = cos2 ($$\frac{\theta}{2}$$)
cos($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{\cos (\theta) + 1}{2}}$$
Exercise 5.
Use the double – angle formulas to verify these identities:
a. sin($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{1 – \cos (\theta)}{2}}$$
Since θ = 2($$\frac{\theta}{2}$$), the double – ange formulas give cos(2($$\frac{\theta}{2}$$)) = 1 – 2sin2 ($$\frac{\theta}{2}$$).
Then we have
cos(θ) = 1 – 2sin2 ($$\frac{\theta}{2}$$)
1 – cos(θ) = 2sin2 ($$\frac{\theta}{2}$$)
$$\frac{1 – \cos (\theta)}{2}$$ = sin2 ($$\frac{\theta}{2}$$)
sin($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{1 – \cos (\theta)}{2}}$$
b. tan($$\frac{\theta}{2}$$) = ±
tan($$\frac{\theta}{2}$$) = $$\frac{\sin \left(\frac{\theta}{2}\right)}{\cos \left(\frac{\theta}{2}\right)}$$ = $$\frac{\pm \sqrt{\frac{1 – \cos (\theta)}{2}}}{\pm \sqrt{\frac{\cos (\theta) + 1}{2}}}$$ = ±$$\sqrt{\frac{1 – \cos (\theta)}{1 + \cos (\theta)}}$$
Exercise 6.
The position of a rider on the unit circle carousel is (0.8, – 0.6) after a rotation by θ where 0 ≤ θ < 2π. What is the position of the rider after rotation by $$\frac{\theta}{2}$$?
Given that cos(θ) is positive and sin(θ) is negative, the rider is located in Quadrant IV after rotation by θ, so
$$\frac{3\pi}{2}$$ < θ < 2π. This means that $$\frac{3\pi}{4}$$ < $$\frac{\theta}{2}$$ < π, which is in Quadrant II, so cos($$\frac{\theta}{2}$$) is negative and sin($$\frac{\theta}{2}$$) is positive.
x($$\frac{\theta}{2}$$) = cos($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{\cos (\theta) + 1}{2}}$$ = – $$\sqrt{\frac{0.8 + 1}{2}}$$ ≈ – 0.95
y($$\frac{\theta}{2}$$) = sin($$\frac{\theta}{2}$$) = ±$$\sqrt{\frac{1 – \cos (\theta)}{2}}$$ = $$\sqrt{\frac{1 – 0.8}{2}}$$ ≈ 0.32
The rider’s position is approximately ( – 0.95,0.32) after rotation by $$\frac{\theta}{2}$$.
Exercise 7.
Evaluate the following trigonometric expressions.
a. sin($$\frac{3\pi}{8}$$)
b. tan($$\frac{\pi}{24}$$)
### Eureka Math Precalculus Module 4 Lesson 4 Problem Set Answer Key
Question 1.
Evaluate the following trigonometric expressions.
a. 2 sin($$\frac{\pi}{8}$$)cos($$\frac{\pi}{8}$$)
sin($$\frac{\pi}{4}$$) = $$\frac{\sqrt{2}}{2}$$
b. $$\frac{1}{2}$$ sin($$\frac{\pi}{12}$$)cos($$\frac{\pi}{12}$$)
$$\frac{1}{4}$$ (sin($$\frac{\pi}{6}$$)) = $$\frac{1}{8}$$
c. 4 sin( – $$\frac{5\pi}{12}$$)cos( – $$\frac{5\pi}{12}$$)
2 sin($$\frac{ – 5\pi}{6}$$) = – 2sin($$\frac{\pi}{6}$$) = – 2($$\frac{1}{2}$$) = – 1
d.cos2 ($$\frac{3\pi}{8}$$) – sin2 ($$\frac{3\pi}{8}$$)
cos($$\frac{3\pi}{4}$$) = – cos($$\frac{\pi}{4}$$) = – $$\frac{\sqrt{2}}{2}$$
e. 2 cos2 ($$\frac{\pi}{12}$$) – 1
cos($$\frac{\pi}{6}$$) = $$\frac{\sqrt{3}}{2}$$
f. 1 – 2sin2 ( – $$\frac{\pi}{8}$$)
cos( – $$\frac{\pi}{4}$$) = $$\frac{\sqrt{2}}{2}$$
g. cos2 ( – $$\frac{11\pi}{12}$$) – 2
$$\frac{1}{2}$$ (2 cos2 ( – $$\frac{11\pi}{12}$$) – 1) – $$\frac{3}{2}$$ = $$\frac{1}{2}$$ (cos($$\frac{ – 11\pi}{12}$$)) – $$\frac{3}{2}$$ = $$\frac{1}{2}$$ (cos($$\frac{\pi}{6}$$)) – $$\frac{3}{2}$$ = $$\frac{1}{2}$$ ($$\frac{\sqrt{3}}{2}$$) – $$\frac{3}{2}$$ = $$\frac{\sqrt{3}}{4}$$ – $$\frac{3}{2}$$
h. $$\frac{2 \tan \left(\frac{\pi}{8}\right)}{1 – \tan ^{2}\left(\frac{\pi}{8}\right)}$$
tan($$\frac{\pi}{4}$$) = 1
i. $$\frac{2 \tan \left( – \frac{5 \pi}{12}\right)}{1 – \tan ^{2}\left( – \frac{5 \pi}{12}\right)}$$
tan( – $$\frac{5\pi}{6}$$) = tan($$\frac{\pi}{6}$$) = $$\frac{1}{\sqrt{3}}$$ = $$\frac{\sqrt{2}}{3}$$
j. cos2 ($$\frac{\pi}{8}$$)
cos2 ($$\frac{\pi}{8}$$) = $$\frac{1 + \cos \left(\frac{\pi}{4}\right)}{2}$$ = $$\frac{1 + \frac{\sqrt{2}}{2}}{2}$$ = $$\frac{1}{2}$$ + $$\frac{\sqrt{2}}{4}$$
k. cos($$\frac{\pi}{8}$$)
Rotation by θ = $$\frac{\pi}{8}$$ terminates in Quadrant I; therefore, cos($$\frac{\pi}{8}$$) has a positive value.
cos($$\frac{\pi}{8}$$) = $$\sqrt{\frac{1 + \cos \left(\frac{\pi}{4}\right)}{2}}$$ = $$\sqrt{\frac{1}{2} + \frac{\sqrt{2}}{4}}$$ = $$\frac{\sqrt{2 + \sqrt{2}}}{2}$$
l. cos( – $$\frac{9\pi}{8}$$)
Rotation by θ = – $$\frac{9\pi}{8}$$ terminates in Quadrant II; therefore, cos( – $$\frac{9\pi}{8}$$) has a negative value.
m. sin2($$\frac{\pi}{12}$$)
sin2($$\frac{\pi}{12}$$) = $$\frac{1 – \cos \left(\frac{\pi}{6}\right)}{2}$$ = $$\frac{1 – \frac{\sqrt{3}}{2}}{2}$$ = $$\frac{1}{2}$$ – $$\frac{\sqrt{3}}{4}$$
n. sin($$\frac{\pi}{12}$$)
Rotation by θ = $$\frac{\pi}{12}$$ terminates in Quadrant I; therefore, sin($$\frac{\pi}{12}$$) has a positive value.
sin($$\frac{\pi}{12}$$) = $$\sqrt{\frac{1 – \cos \left(\frac{\pi}{6}\right)}{2}}$$ = $$\sqrt{\frac{1}{2} + \frac{\sqrt{3}}{4}}$$ = $$\frac{\sqrt{2 + \sqrt{3}}}{2}$$
o. sin( – 5$$\frac{\pi}{12}$$)
Rotation by θ = – 5$$\frac{\pi}{12}$$ terminates in Quadrant IV; therefore, sin( – 5$$\frac{\pi}{12}$$) has a negative value.
p. tan($$\frac{\pi}{8}$$)
Rotation by θ = $$\frac{\pi}{8}$$ terminates in Quadrant I; therefore, tan($$\frac{\pi}{8}$$) has a positive value.
q. tan($$\frac{\pi}{12}$$)
r. tan( – $$\frac{3\pi}{8}$$)
Rotation by θ = – $$\frac{3\pi}{8}$$ terminates in Quadrant IV; therefore, tan( – $$\frac{3\pi}{8}$$) has a negative value.
Question 2.
Show that sin(3x) = 3sin(x)cos2 (x) – sin3 (x). (Hint: Use sin(2x) = 2sin(x)cos(x) and the sine sum formula.)
sin(3x) = sin(x + (2x))
= sin(x)cos(2x) + cos(x)sin(2x)
= sin(x)[cos2 (x) – sin2 (x)] + cos(x)[2sin(x)cos(x)]
= sin(x)cos2 (x) – sin3 (x) + 2sin(x)cos2 (x)
= 3sin(x)cos2 (x) – sin3 (x)
Question 3.
Show that cos(3x) = cos3 (x) – 3sin2 (x)cos(x). (Hint: Use cos(2x) = cos2 (x) – sin2 (x) and the cosine sum formula.)
cos(3x) = cos(x + (2x))
= cos(x)cos(2x) – sin(x)sin(2x)
= cos(x)[cos2 (x) – sin2 (x)] – sin(x)[2sin(x)cos(x)]
= cos3 (x) – cos(x)sin2 (x) – 2cos(x)sin2 (x)
= cos3 (x) – 3cos(x)sin2 (x)
Question 4.
Use cos(2x) = cos2 (x) – sin2 (x) to establish the following formulas.
a. cos2 (x) = $$\frac{1 + \cos (2 x)}{2}$$
cos(2x) = cos2 (x) – sin2 (x)
= cos2 (x) – (1 – cos2 (x))
= 2cos2 (x) – 1
Therefore, cos2 (x) = $$\frac{1 + \cos (2 x)}{2}$$
b. sin2 (x) = $$\frac{1 – \cos (2 x)}{2}$$
cos(2x) = cos2 (x) – sin2 (x)
= (1 – sin2 (x)) – sin2 (x)
= 1 – 2sin2 (x)
Therefore, sin2 (x) = $$\frac{1 – \cos (2 x)}{2}$$
Question 5.
Jamia says that because sine is an odd function, sin($$\frac{\theta}{2}$$) is always negative if θ is negative. That is, she says that for negative values of sin($$\frac{\theta}{2}$$) = – $$\sqrt{\frac{1 – \cos (\theta)}{2}}$$. Is she correct? Explain how you know.
Jamia is not correct. Consider θ = – $$\frac{7\pi}{3}$$. In this case, $$\frac{\theta}{2}$$ = – $$\frac{7\pi}{6}$$, and rotation by – $$\frac{7\pi}{6}$$ terminates in Quadrant II. Thus, sin( – $$\frac{7\pi}{6}$$) is positive.
Question 6.
Ginger says that the only way to calculate sin($$\frac{\pi}{12}$$) is using the difference formula for sine since $$\frac{\pi}{12}$$ = $$\frac{\pi}{3}$$ – $$\frac{\pi}{4}$$. Fred says that there is another way to calculate sin($$\frac{\pi}{12}$$). Who is correct and why?
Fred is correct. We can use the half – angle formula with θ = $$\frac{\pi}{6}$$ to calculate sin($$\frac{\pi}{12}$$).
Question 7.
Henry says that by repeatedly applying the half – angle formula for sine we can create a formula for sin($$\frac{\theta}{n}$$) for any positive integer n. Is he correct? Explain how you know.
Henry is not correct. Repeating this process will only give us formulas for sin($$\frac{\theta}{2^{k}}$$) for positive integers k. There is no way to derive a formula for quantities such as sin($$\frac{\theta}{5}$$) using this method.
### Eureka Math Precalculus Module 4 Lesson 4 Exit Ticket Answer Key
Question 1.
Show that cos(3θ) = 4cos3 (θ) – 3cos(θ).
Evaluate cos($$\frac{7\pi}{12}$$) using the half – angle formula, and then verify your solution using a different formula.
|
|
Faster Dijkstra on Special Graphs [Tutorial]
Revision en2, by himanshujaju, 2016-03-02 17:04:49
You can read the latex formatted pdf here.
Pre Requisites
Dijkstra's algorithm
Motivation Problem
You are given a weighted graph G with V vertices and E edges. Find the shortest path from a given source S to all the vertices, given that all the edges have weight W {X, Y} where X, Y > = 0
Naive Solution
Most people when given this question would solve it using Dijkstra's algorithm which can solve this efficiently in O(E * logV) (Let's not take Fibonacci heap implementation into consideration now). It turns out that this solution, though it will work in most cases well under the time, can be improved further to a linear time algorithm.
Before moving into the next section, try to think about how you could optimise Dijkstra's algorithm. ( Hint : There are only two possible values of the edge weight.)
Optimised Solution
Let us see why we have the O(logV) factor in the original Dijkstra : priority queue ! So, if we can just find a way to keep the queue sorted by non-decreasing distance in O(1) always, then we can replace the priority queue with a normal queue and find the shortest distance from source to all vertices.
Let us keep two different queues QX and QY. Suppose we are at an arbitrary node u and we are able to reduce the distance to node v by travelling over an edge from u. If this travelled edge from u to v has a weight X then push v to the queue QX, else push it on the queue QY. In short, QX stores information of all nodes whose current minimum is achieved by last travelling over an X weighted edge and QY stores the information of nodes having last weighted edge as Y.
Our entire algorithm is almost the same as that of Dijkstra. One change is to use two queues as mentioned above instead of the priority queue to try and remove the log factor. Another change is that in case of Dijkstra we always take the top node as the next node, but in this algorithm we take the less distant node of the two queue heads. If we can prove that the queues are sorted, we can prove that the answer produced cannot be different from Dijkstra since we are always taking the minimum distant node for calculations and also keeping the distance queues sorted.
Claim : "The queues QX and QY are always sorted."
Proof : Let us assume that the first inversion has just occurred in QX. Let the last element be V and the second last element be U. So, dist(U) > dist(V). Now, since both of them last travelled an edge with weight X, we can subtract this quantity from both the distances. Thus, dist(U) - X > dist(V) - X. Let pre(a) = dist(a) - X. Thus, pre(U) > pre(V).
Now, pre(U) and pre(V) must have come from one of the two queues. They cannot come from the same queue, since we assumed the two queues were always sorted before this moment of time. So they must be from two different queues. But according to our algorithm, we take the minimum of the head of the two queues and so if pre(U) was taken before pre(V), then pre(U) < = pre(V). This contradiction proves that QX is always sorted. We can use a similar argument for the other queue.
Once the claim is proved, the whole algorithm should look pretty trivial from implementation point of view. Since we have removed the log factor, this runs in linear time. We can also extend this to a bigger number of distinct edges and use a set for finding minima. You can refer to the pseudocode in the next section in case you have implementation doubts.
Pseudo Code
queue QX , QY
push source S to QX
while one of the two queues is not empty:
u = pop minimal distant node among the two queue heads
for all edges e of form (u,v):
if dist(v) > dist(u) + cost(e):
dist(v) = dist(u) + cost(e);
if cost(e) == X:
QX.push(dist(v),v);
else:
QY.push(dist(v),v);
While finding the minimal distant node, you need to check if anyone of the queue is empty to avoid null pointer errors. Otherwise, everything else is same as Dijkstra when it comes to implementation.
Problems to practice
I don't have any specific problems for this, but all problems that can be solved by 0-1 BFS can also be solved by this. Refer here for some questions.
Conclusion
I hope you learnt something new! Feel free to point out mistakes. There is a rare chance that you would need this algorithm anytime, but it might turn out useful in optimisation problems. This post was largely inspired by a comment on my 0-1 BFS tutorial.
Happy Coding!
History
Revisions
Rev. Lang. By When Δ Comment
en3 himanshujaju 2016-03-02 17:06:05 0 (published)
en2 himanshujaju 2016-03-02 17:04:49 1020 First Version
en1 himanshujaju 2016-03-02 16:49:28 5268 Initial revision (saved to drafts)
|
|
# WolframAlpha guide on electrical engineering
1. May 21, 2009
### waht
Introduction:
WolframAlpha is a freely available computational engine that can supplement already existing software such as mathematica, maple, mathlab, or excel. The purpose of this mini-guide is to go over some of its functionality with emphasis on electrical engineering.
www.wolframalpha.com
Dimensional analysis:
WolframAlpha recognizes many common units. It will simplify dimensions and scale units. For example,
Code (Text):
will generate [time]^2
Code (Text):
0.01 uF to pF
will generate 10,000 pF or 10 nF
WolframAlpha also can tap its database to pull up a conversion formula from the context
Code (Text):
convert 25 MHz to meters
will convert the frequency to wavelength 12 meters
Code (Text):
find energy in 100 uF at 10 KV
will give energy in a capacitor,
or to find inductance to resonate with 10 nF capacitor at 100 Khz; just say that
Code (Text):
find inductance for 10 nF at 100 KHz
output 253 nH
Also if you haven't memorized resistor color bands already, you can still look them up
Code (Text):
resistor yellow purple red
output: 4.7K
Complex numbers and phasors:
Working in polar form is supported in W|A. By typing an impedance in rectangular form
Code (Text):
30 + 45i
we are quickly given its magnitude and phase of 54, and 56 degrees
and likewise, we can indicate a phasor in polar form with an exponential e
Code (Text):
e^(i pi)
generates -1
we can also manipulate phasors algebraically
Code (Text):
100 e^(i 45 deg) + 25 e^(i 30 deg)
output: magnitude = 124, phase = 42 deg
indicate degrees with “deg” otherwise W|A will interpret it in radians.
Solving equations:
To solve $x^2 - 2x + 1= 0$, enter the equation as it is
Code (Text):
x^2 - 2x + 1 = 0
output x = 1
and W|A solves it. Don't even have to specify the variable to be solved.
Solving systems of equations is just as easy,
$$v_1 + v_2 + v_3 = 4$$
$$v_1 - v_2 = 10$$
$$v_1 - 3v_2 + 5v_3 = 8$$
simply type
Code (Text):
v1 + v2 + v3 = 4, v1-v2 = 10, v1 - 3v2 + 5v3 = 8
output v1 = 23/3, v2 = -7/3, v3 = -4/3
just make sure that the equations are separated by a comma.
Differential equations are supported as well. An nth number of apostrophes indicates an nth derivative, and proceed as before. For example to solve
$$\frac{d^2y}{dx^2} - \frac{dy}{dx} - 2y = 0 \indent y(0) = 1, y'(0) = 2$$
enter the code as follows,
Code (Text):
y'' – y' - 2 y = 0, y(0) = 1, y'(0) = 2
and we get a solution y = e^2x as well as a plot that can be saved in pdf format, and printed out.
We can also maximize and minimize
Code (Text):
max 1 - x^2
finds maximum of 1
Logic gates and boolean algebra:
Converts number bases,
Code (Text):
binary 1111101 to hex
= 7d
We can also work with boolean expression in WolramAlpha, for example
Code (Text):
(x or y) and (x or !y)
generates a truth table:
http://img200.imageshack.us/img200/9384/truthtable.gif [Broken]
a schematic with logic gates, and even simplifies the expression to a minimal form
http://img268.imageshack.us/img268/3233/scehmatic.gif [Broken]
Here is the supported syntax:
Code (Text):
NOT = !
OR = ||
AND = &&
NAND
NOR
XOR
More on calculus:
W|A can perform basic calculus
take derivatives:
$$\frac{d}{dt} cos(t)$$
Code (Text):
derivative cos(t)
do integration:
$$\int \frac{1}{x+1} dx$$
Code (Text):
integrate 1/(x+1) dx
and take Laplace and Fourier transforms:
$$\mathcal{L}(x^2), \mathcal{F}(e^x)$$
Code (Text):
laplace x^2
Code (Text):
fourier e^x
Plotting:
If you want to graph a transfer function for instance,
$$H(s) = \frac{s+10}{s^2 + 4s + 8}$$
enter:
Code (Text):
graph (s + 10)/(s^2 + 4s + 8)
and here we have
http://img32.imageshack.us/img32/9715/graph.gif [Broken]
Conclusion:
WolframAlpha uniquely combines different tools into a one freely available package and that expands our tool box. This mini-guide doesn't cover all of W|A, it merely touches upon features that can be used in electrical engineering, for more information visit their examples page
http://www28.wolframalpha.com/examples/
also, W|A is said to expand in the future, enabling more functionality, and tools.
Last edited by a moderator: May 4, 2017
2. May 21, 2009
### Staff: Mentor
Thanks for putting that together, waht. I've stickied this thread to help us learn how to utilize W|A.
Any further posts in this thread should be about tips on how to use W|A and its features. Discussions about W|A and its implications for eductaion, etc., belong in a different thread, like this one: https://www.physicsforums.com/showthread.php?t=307686
.
Last edited: May 22, 2009
3. May 21, 2009
### Redbelly98
Staff Emeritus
Resistor color codes
The inverse operation works also. Type this for input:
Code (Text):
resistor color 4.7k ohms
... and the output is an image of the resistor with the correct color bands:
View the full W|A output here:
http://www5f.wolframalpha.com/input/?i=resistor+color+4.7k+ohms&asynchronous=false&equal=Submit [Broken]
.
.
#### Attached Files:
• ###### WA_resistor_color_4k7.gif
File size:
1.4 KB
Views:
4,436
Last edited by a moderator: May 4, 2017
4. Oct 14, 2009
### Redbelly98
Staff Emeritus
5. Apr 4, 2010
### dvchench
6. Apr 10, 2010
### ranger
Check out the WolframAlpha app for the iPhone and iPod Touch. Its pretty awesome!
7. Jul 13, 2010
### rathat
Remember when the WA app cost $50? They thought because it's better than any scientific calculator could be, they could charge that much, but you know, no one would pay that much so they made it$2.
8. Dec 20, 2010
### Ecin
is there any advantage over the ipod app vs the standard web version?
9. Jun 17, 2011
### CenterFusion
Would you guys recommend wolfram alpha to a student who is interested in learning more about physics and modeling physics within computing systems? I have a small bit of experience with mathlab, and am hoping to be on the go as I do this (iPad, Android, etc.)
10. Sep 14, 2011
### m.s.j
I have "Algeo.apk" in my galaxy tab, it is a wonderful application in small scale.
|
|
# Solving numerically a strongly stiff nonlinear ODE system with ill-conditioned Jacobian
Using Matlab, I am trying to solve numerically the following nonlinear system of ODEs:
\begin{aligned} \dot B &= -\alpha B -\nu BV \\ \dot X &= A-\mu_1 X -c E(B)VX \\ \dot Y &= -\mu_2 Y +c E(B)VX \\ \dot V &= kY - (\gamma B + E_0)V - \delta V \\ \end{aligned}
with
$$E(B)=(\gamma B +E_0)e^{-\beta \gamma B}$$
The system tries to capture the dynamics of how the body of an infant reacts to the presence of the dengue virus.
• $$V$$ is the number of virus.
• $$B$$ the number of antibody.
• $$X$$ the number of healthy cells.
• $$Y$$ the number of infected cells.
• $$E$$ is a function enhancing the effect of antibodies, depending on the number of antibodies.
Implementing this model and trying different solver, I noticed that solvers ode15s and ode23s are performing way better than ode45. Hence, I deduced that my problem was stiff. But with certain set of parameters I had the following warning from Matlab:
Warning: Matrix is close to singular or badly scaled. Results may be inaccurate. RCOND = 2.334107e-017.
I worried for a while but I found the malicious ill-conditionned matrix. It's actually that solvers ode23s and ode15s use the Jacobian of the system. I have then computed myself this Jacobian and found the following:
$$DJ(B,X,Y,V)= \begin{pmatrix} -\alpha - \nu V & 0 & 0 & - \nu B \\ -c V X E'(B) & -c V E(B)-\mu_1 & 0 & -c X E(B) \\ c V X E'(B) & c V E(B) & -\mu_2 & c E(B) X\\ -\gamma V & 0 & k & -(\gamma B+E_0+\delta) \\ \end{pmatrix}$$
with
$$E'(B)=e^{-\beta \gamma B}(\gamma-\beta \gamma^2 B-E_0 \beta \gamma)$$
at this point you have to know a bit more about the dynamics of the system. There is two stable points , one where the virus dies , the antibody disappears , the cells stays healthy
$$P_0=(0, \frac{A}{\mu_1},0,0)$$
And another one, depending of the pararameters in a more complex way :
$$P_1 = \left(0,\mu_2 \frac{E_0+\delta}{k c E_0},\bar{Y}, \frac{k}{E_0+\delta} \bar{Y }\right) \text{ with } \bar{Y}= \frac{A}{\mu_2} - \frac{\mu_1(E_0+\delta)}{k c E_0}$$
which means, basically, that some cells become infected and stay infected, the virus population explodes before stabilising, and the antibodies disappear.
This second point is the problem because lots of initial conditions seems to be attracted by it and it means that $$V$$ becomes huge (around $$10^{12}$$) when the total number of cells doesn't exceed $$10^{7}$$ and the population of antibodies stays below $$10^{4}$$.
When $$V$$ becomes huge, I check the Jacobian again, knowing that $$\gamma \approx 1$$. We have this one value in the left down corner becoming really huge compared to the other values, also the parameter $$c$$ is around $$10^{-10}$$, so really it's mostly about this left corner term.
From there I'm not sure what to do. Is there a way to make a time-varying, well-conditioned Jacobian matrix? Or do you know about any other numerical method that could fit my needs?
It doesn't have to be implemented in Matlab. For now, the results I get are mainly garbage.
• Why not compute the Jacobian symbolically? Does the ODE solver allow you to provide the Jacobian? – Rodrigo de Azevedo Apr 11 at 20:01
• hello, yes the solver allows me to do that and that's what I do but I think it replace the symbols with numeric values at computation time before inversion of the Jacobian or whatever it does with the Jacobian. – nathan raynal Apr 22 at 16:40
• Uhmm... are you sure there even is a solution? Nonlinear ODEs can have finite escape time. – Rodrigo de Azevedo Apr 22 at 16:54
• if all initial parameters are above zero , yes it always have a solution . Anyway, I translated my problem in C++ to allow myself to get a better control over the numerical methods used . If I implement myself the implicit method, I should be able to use substitution to reduce the non linear system to a big non linear equation in dimension 1 and could then use an algorithm not involving a Jacobian (a simple newton method could do the trick) . Do you think that's a valid strategy ? I can get this 1d equation with the trapezoidal rule already but didn't try to implement it . – nathan raynal Apr 24 at 9:48
• I haven't touched numerical ODEs in over a decade, so I can't offer a lot. However, I am surprised MATLAB does not get the job done. Their solvers should be sophisticated enough to handle stiff problems. Did you check the documentation thoroughly? – Rodrigo de Azevedo Apr 24 at 21:50
|
|
# scvi.external.cellassign.CellAssignModule.generative¶
CellAssignModule.generative(x, size_factor, design_matrix=None)[source]
Run the generative model.
This function should return the parameters associated with the likelihood of the data. This is typically written as $$p(x|z)$$.
This function should return a dictionary with str keys and Tensor values.
|
|
International Sugar Journal
# Guidelines for authors
International Sugar Journal offers analysis, reviews and discourse to keep its international readership up to date with latest developments in cane and beet production, sugar technology and sugar industry.
The agricultural research focus is mainly on field or farm experiments/trials which have been repeated over time or space to demonstrate that similar results can or cannot be obtained in different environments.
As for sugar technology, the focus is on the application of innovative research and technical advances. Papers on economic and political issues informing international trade and developments are also welcome.
Main topics include:
Cane and Beet Research Breeding and genetics Agronomy Crop Protection Plant physiology and biochemistry Environmental factors Soil management Harvesting Machinery and equipment Information communication technologies Sugar production and Refining Front end operations Cane and beet sugar manufacture Sugar refining Biofuels and biorenewables Alternative sweeteners Equipment and machinery Analysis – chemical, microbiology and instrumentation Environmental issues Byproducts and co-products Food and non-food uses of sugar Economics, trade and legislation
Paper Selection
Papers are critically reviewed by referees. On their advice, the Editor accepts or rejects the paper, or returns the paper for revision. Authors are normally supplied with referee’s comments within 6 weeks.
Preparation
• General. All papers must be in English. (Occasionally, Spanish versions of accepted English papers are also published.) Those whose first language is not English and do not have a good command of English are advised to seek assistance. Papers requiring a great deal of editorial work may be sent back to authors for revision. Authors are advised to study a recent issue of ISJ and must ensure that the paper to be submitted follows the pattern of published papers.
• Length. Articles should be in the region of 2000 and 3500 words (excluding an abstract).
• Title. This should be concise, specific and informative with the maximum number of relevant keywords to facilitate retrieval and indexing by bibliographic searching techniques.
• Authors’ names. Each must have a surname in full and initials. Give the full address(es) where the work was done. If the present address(es) of author(s) has changed than this should be given in a footnote.
• Abstract. Provide a concise factual statement in around 150-200 words why the work was done and what are the principal findings. A well-written abstract will be intelligible without reference to the paper itself. Acronyms and abbreviations must be avoided.
• Text. An introductory statement should briefly describe the aims of investigation, presenting only essential background without summarising the work itself. Technical terms should be defined. Symbols, abbreviations and acronyms must be defined the first time they are used. In research papers, present techniques used in sufficient detail to allow them to be repeated.
• Units of measurement. All data must be presented in metric units, although equivalent local units may be given in parentheses.
• Currency. Where economic analysis is made, aim to express values in US$. Where local currencies are noted, US$ equivalent must be stated in parenthesis.
• Graphics Graphs are preferred to tables, and in most cases, two- instead of three-dimensional graphs are best.
• References The Harvard system referencing is preferred. Source the guide https://www.citethisforme.com/harvard-referencing for reference.
Publication fee
It is imperative that the author/s institution has a subscription to the journal or will take one out prior to the publication. To avoid ambiguity, where there are multiple authors, the first author’s institution needs to have a subscription.
Submission of papers
All papers must be submitted in an electronic format, with text in MSWord, figures in Excel and images in Tiff, Jpeg or EPS file (300 dpi minimum). Please use standard fonts (Arial or Times New Roman) whenever (or wherever) possible, otherwise make sure that non-standard fonts used are embedded in the document/image (with all formats) or we will be unable to use file, and the paper will most probably be delayed for publication. Papers should be sent to the editor via email (or several emails if it is a big file).
Contact details: Editor, International Sugar Journal, IHS Markit | Ropemaker Place, 25 Ropemaker St | London EC2Y 9LY | UK.
Email: IntSugarJnl-Editorial@ihsmarkit.com Tel: +44 (0) 203 855 3859
|
|
Physics
# What is the approximation made in the parallax method?
Distance between a point on the earth and the planet is very large as compared to the distance between two points on earth's surface.
##### SOLUTION
In parallax method, an approximation is made that distance between a point on the earth and the planet is very large as compared to the distance between two points on the earth's surface.
You're just one step away
Single Correct Medium Published on 18th 08, 2020
Questions 244531
Subjects 8
Chapters 125
Enrolled Students 202
#### Realted Questions
Q1 Single Correct Medium
$L$, $C$ and $R$ represents the physical quantities, inductance, capacitance and resistance respectively. The combinations which have the dimensions of frequency are:
• A. $1/RC$
• B. $RC/L$
• C. $1/\sqrt {LRC}$
• D. $C/L$
Asked in: Physics - Units and Measurement
1 Verified Answer | Published on 18th 08, 2020
Q2 Single Correct Medium
The decrease in percentage error:
• A. increases the accuracy
• B. does not effect the accuracy
• C. decreases the accuracy
• D. both A and C
Asked in: Physics - Units and Measurement
1 Verified Answer | Published on 18th 08, 2020
Q3 Single Correct Medium
When $CO_{2}(g)$ is passed over red-hot coke it partially gets reduced to $CO(g)$. Upon passing $0.5$ litre of $CO_{2}(g)$ over red-hot coke, the total volume of the gases increased to $700\ mL$. The composition of the gaseous mixture at STP is :
• A. $CO_{2} = 200\ mL; CO = 500\ mL$
• B. $CO_{2} = 350\ mL; CO = 350\ mL$
• C. $CO_{2} = 0.0\ mL; CO = 700\ mL$
• D. $CO_{2} = 300\ mL; CO = 400\ mL$
Asked in: Physics - Units and Measurement
1 Verified Answer | Published on 18th 08, 2020
Q4 Single Correct Medium
Which of the following is dimensionless?
• A. Force/acceleration
• B. Velocity/acceleration
• C. Volume/area
• D. Energy/work
Asked in: Physics - Units and Measurement
1 Verified Answer | Published on 18th 08, 2020
Q5 Single Correct Medium
The amplitude of a damped oscillator of mass $'m'$ varies with the time 't' as $A=A_0e^{-at/m}$. The dimension of $'a'$ are:
• A. $ML^0T^{-1}$
• B. $M^0LT^{-1}$
• C. $MLT^{-1}$
• D. $ML^{-1}T$
Asked in: Physics - Units and Measurement
1 Verified Answer | Published on 18th 08, 2020
|
|
## trans-dimensional nested sampling and a few planets
Posted in Books, Statistics, Travel, University life with tags , , , , , , , , , on March 2, 2015 by xi'an
This morning, in the train to Dauphine (train that was even more delayed than usual!), I read a recent arXival of Brendon Brewer and Courtney Donovan. Entitled Fast Bayesian inference for exoplanet discovery in radial velocity data, the paper suggests to associate Matthew Stephens’ (2000) birth-and-death MCMC approach with nested sampling to infer about the number N of exoplanets in an exoplanetary system. The paper is somewhat sparse in its description of the suggested approach, but states that the birth-date moves involves adding a planet with parameters simulated from the prior and removing a planet at random, both being accepted under a likelihood constraint associated with nested sampling. I actually wonder if this actually is the birth-date version of Peter Green’s (1995) RJMCMC rather than the continuous time birth-and-death process version of Matthew…
“The traditional approach to inferring N also contradicts fundamental ideas in Bayesian computation. Imagine we are trying to compute the posterior distribution for a parameter a in the presence of a nuisance parameter b. This is usually solved by exploring the joint posterior for a and b, and then only looking at the generated values of a. Nobody would suggest the wasteful alternative of using a discrete grid of possible a values and doing an entire Nested Sampling run for each, to get the marginal likelihood as a function of a.”
This criticism is receivable when there is a huge number of possible values of N, even though I see no fundamental contradiction with my ideas about Bayesian computation. However, it is more debatable when there are a few possible values for N, given that the exploration of the augmented space by a RJMCMC algorithm is often very inefficient, in particular when the proposed parameters are generated from the prior. The more when nested sampling is involved and simulations are run under the likelihood constraint! In the astronomy examples given in the paper, N never exceeds 15… Furthermore, by merging all N’s together, it is unclear how the evidences associated with the various values of N can be computed. At least, those are not reported in the paper.
The paper also omits to provide the likelihood function so I do not completely understand where “label switching” occurs therein. My first impression is that this is not a mixture model. However if the observed signal (from an exoplanetary system) is the sum of N signals corresponding to N planets, this makes more sense.
## the intelligent-life lottery
Posted in Books, Kids with tags , , , , , , , on August 24, 2014 by xi'an
In a theme connected with one argument in Dawkins’ The God Delusion, The New York Time just published a piece on the 20th anniversary of the debate between Carl Sagan and Ernst Mayr about the likelihood of the apparition of intelligent life. While 20 years ago, there was very little evidence if any of the existence of Earth-like planets, the current estimate is about 40 billions… The argument against the high likelihood of other inhabited planets is that the appearance of life on Earth is an accumulation of unlikely events. This is where the paper goes off-road and into the ditch, in my opinion, as it makes the comparison of the emergence of intelligent (at the level of human) life to be “as likely as if a Powerball winner kept buying tickets and — round after round — hit a bigger jackpot each time”. The later having a very clearly defined probability of occurring. Since “the chance of winning the grand prize is about one in 175 million”. The paper does not tell where the assessment of this probability can be found for the emergence of human life and I very much doubt it can be justified. Given the myriad of different species found throughout the history of evolution on Earth, some of which evolved and many more which vanished, I indeed find it hard to believe that evolution towards higher intelligence is the result of a basically zero probability event. As to conceive that similar levels of intelligence do exist on other planets, it also seems more likely than not that life took on average the same span to appear and to evolve and thus that other inhabited planets are equally missing means to communicate across galaxies. Or that the signals they managed to send earlier than us have yet to reach us. Or Earth a long time after the last form of intelligent life will have vanished…
## Harmonic means, again
Posted in Statistics, University life with tags , , , , , , , , on January 3, 2012 by xi'an
Over the non-vacation and the vacation breaks of the past weeks, I skipped a lot of arXiv postings. This morning, I took a look at “Probabilities of exoplanet signals from posterior samplings” by Mikko Tuomi and Hugh R. A. Jones. This is a paper to appear in Astronomy and Astrophysics, but the main point [to me] is to study a novel approximation to marginal likelihood. The authors propose what looks at first as defensive sampling: given a likelihood f(x|θ) and a corresponding Markov chaini), the approximation is based on the following importance sampling representation
$\hat m(x) = \sum_{i=h+1}^N \dfrac{f(x|\theta_i)}{(1-\lambda) f(x|\theta_i) + \lambda f(x|\theta_{i-h})}\Big/$
$\sum_{i=h+1}^N \dfrac{1}{(1-\lambda) f(x|\theta_i) + \lambda f(x|\theta_{i-h})}$
This is called a truncated posterior mixture approximation and, under closer scrutiny, it is not defensive sampling. Indeed the second part in the denominators does not depend on the parameter θi, therefore, as far as importance sampling is concerned, this is a constant (if random) term! The authors impose a bounded parameter space for this reason, however I do not see why such an approximation is converging. Except when λ=0, of course, which brings us back to the original harmonic mean estimator. (Properly rejected by the authors for having a very slow convergence. Or, more accurately, generally no stronger convergence than the law of large numbers.) Furthermore, the generic importance sampling argument does not work here since, if
$g(\theta) \propto (1-\lambda) \pi(\theta|x) + \lambda \pi(\theta_{i-h}|x)$
is the importance function, the ratio
$\dfrac{\pi(\theta_i)f(x|\theta_i)}{(1-\lambda) \pi(\theta|x) + \lambda \pi(\theta_{i-h}|x)}$
does not simplify… I do not understand either why the authors compare Bayes factors approximations based on this technique, on the harmonic mean version or on Chib and Jeliazkov’s (2001) solution with both DIC and AIC, since the later are not approximations to the Bayes factors. I am therefore quite surprised at the paper being accepted for publication, given that the numerical evaluation shows the impact of the coefficient λ does not vanish with the number of simulations. (Which is logical given the bias induced by the additional term.)
|
|
# Why Tree-Based Models are Preferred in Credit Risk Modeling?
Credit risk refers to the likelihood that a borrower will be unable to make regular payments and will default on their obligations.
Credit risk modeling is a field where machine learning may be used to offer analytical solutions because it has the capability to find answers from the vast amount of heterogeneous data. In credit risk modeling, it is also necessary to infer about the features because they are very important in data-driven decision making. In contrast to credit risk, we will examine what credit risk is and how it can be represented using various machine learning algorithms in this post. We will implement the credit risk modeling with different machine learning models and will see how tree-based models outperform other models in this task. The following are the main points to be discussed.
1. What is Credit Risk
2. What is Credit Risk Modeling
3. How Machine Learning Is Used in Credit Risk Modelling?
4. Implementing Credit Risk Modelling
5. The outperformance of Tree-Based Models
Let’s start the discussion by understanding what is credit risk.
#### What is Credit Risk
Credit risk refers to the likelihood that a borrower will be unable to make regular payments and will default on their obligations. It refers to the possibility that a lender will not be paid for the interest or money given on time. The cash flow of the lender is disrupted, and the cost of recovery rises. In the worst-case scenario, the lender may be obliged to write off some or all of the loan, resulting in a loss.
It is incredibly tough and complex to predict a person’s likelihood of defaulting on a debt. Simultaneously, appropriately assessing credit risk can help to limit the chance of losses due to default and late payments. As recompense for taking on credit risk, the lender receives interest payments from the borrower.
The lender or investor will either charge a higher interest rate or refuse to make the loan if the credit risk is higher. For the same loan, a loan applicant with a solid credit history and regular income will be charged a lower interest rate than one with a terrible credit history.
#### What is Credit Risk Modeling
A person’s credit risk is influenced by a variety of things. As a result, determining a borrower’s credit risk is a difficult undertaking. Credit risk modelling has entered the scene since there is so much money relying on our ability to appropriately predict a borrower’s credit risk. Credit risk modelling is the practice of applying data models to determine two key factors. The first is the likelihood that the borrower will default on the loan. The second factor is the lender’s financial impact if the default occurs.
Credit risk models are used by financial organizations to assess the credit risk of potential borrowers. Based on the credit risk model validation, they decide whether or not to approve a loan as well as the loan’s interest rate.
New means of estimating credit risk have emerged as technology has progressed, like credit risk modelling using R and Python. Using the most up-to-date analytics and big data techniques to model credit risk is one of them. Other variables, such as the growth of economies and the creation of various categories of credit risk, have had an impact on credit risk modelling.
#### How Machine Learning Is Used in Credit Risk Modelling?
Machine learning enables more advanced modelling approaches like decision trees and neural networks to be used. This introduces nonlinearities into the model, allowing for the discovery of more complex connections between variables. We selected to employ an XGBoost model that was fed with features picked using the permutation significance technique.
ML models, on the other hand, are frequently so complex that they are difficult to understand. We chose to combine XGBoost and logistic regression because interpretability is critical in a highly regulated industry like credit risk assessment.
#### Implementing Credit Risk Modelling
Credit risk modelling in Python can assist banks and other financial institutions in reducing risk and preventing financial catastrophes in society. The goal of this article is to create a model that can predict the likelihood of a person defaulting on a loan. Let’s start by loading the dataset.
import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
import numpy as np
from sklearn.model_selection import train_test_split, cross_val_score, KFold
from sklearn.preprocessing import LabelEncoder
from sklearn.ensemble import RandomForestClassifier
from sklearn.naive_bayes import GaussianNB
from sklearn.neighbors import KNeighborsClassifier
from sklearn.linear_model import LogisticRegression
from sklearn.tree import DecisionTreeClassifier
When you look at the Colab notebook for this implementation, you’ll find that numerous columns are identifiers and do not include any meaningful information for creating our machine learning model. Id, member id, and so on are some examples. Remember that we want to build a model that predicts the likelihood of a borrower defaulting on a loan, therefore we won’t need qualities that relate to events that happen after a person defaults. This is because this information isn’t available at the time of loan approval. Recoveries, collection recovery fees, and so on are examples of these features. The code below displays the columns that have been eliminated.
#dropping irrelevant columns
columns_to_ = ['id', 'member_id', 'sub_grade', 'emp_title', 'url', 'desc', 'title', 'zip_code', 'next_pymnt_d',
'recoveries', 'collection_recovery_fee', 'total_rec_prncp', 'total_rec_late_fee', 'desc', 'mths_since_last_record',
'mths_since_last_major_derog', 'annual_inc_joint', 'dti_joint', 'verification_status_joint', 'open_acc_6m', 'open_il_6m',
'open_il_12m', 'open_il_24m', 'mths_since_rcnt_il', 'total_bal_il', 'il_util', 'open_rv_12m', 'open_rv_24m',
'max_bal_bc', 'all_util', 'inq_fi', 'total_cu_tl', 'inq_last_12m','policy_code',]
loan_data.drop(columns=columns_to_, inplace=True, axis=1)
# drop na values
loan_data.dropna(inplace=True)
Now you might know that while preparing the data multicollinearity should be failed because the highly correlated variable provides the same information and those are redundant if we don’t then models will fail to estimate the relationship between the dependent and independent variables.
To check the multicollinearity we will draw the heatmap of the correlation matrix obtained with help of the panda’s correlation matrix. The heat map is shown below.
As can be seen, several variables are highly correlated and should be eliminated. ‘loan amnt’, ‘funded amnt’, ‘funded amnt inv’, ‘installment’, ‘total pymnt inv’, and ‘out prncp inv’ are multi-collinear variables.
If you look through the Notebook, you’ll notice that several variables aren’t in the right data types and need to be pre-processed to get them into the right format. We will define some functionalities to aid in the automation of this procedure. The functions that were used to transform variables to data are coded as below.
def Term_Numeric(data, col):
data[col] = pd.to_numeric(data[col].str.replace(' months', ''))
term_numeric(loan_data, 'term')
def Emp_Length_Convert(data, col):
data[col] = data[col].str.replace('\+ years', '')
data[col] = data[col].str.replace('< 1 year', str(0))
data[col] = data[col].str.replace(' years', '')
data[col] = data[col].str.replace(' year', '')
data[col] = pd.to_numeric(data[col])
data[col].fillna(value = 0, inplace = True)
def Date_Columns(data, col):
today_date = pd.to_datetime('2020-08-01')
data[col] = pd.to_datetime(data[col], format = "%b-%y")
data['mths_since_' + col] = round(pd.to_numeric((today_date - data[col]) / np.timedelta64(1, 'M')))
data['mths_since_' + col] = data['mths_since_' + col].apply(lambda x: data['mths_since_' + col].max() if x < 0 else x)
data.drop(columns = [col], inplace = True)
In our dataset, the goal column is loan status, which has different unique values. These values must be converted to binary. That is a score of 0 for a bad borrower and a score of 1 for a good borrower. In our situation, a bad borrower is someone who falls into one of the categories listed in our target column. Charged off, Default, Late (31–120 days), Does not comply with credit policy Charged Off Status The remaining debtors are considered to be good borrowers.
# creating a new column based on the loan_status
loan_data['good_bad'] = np.where(loan_data.loc[:, 'loan_status'].isin(['Charged Off', 'Default', 'Late (31-120 days)',
'Does not meet the credit policy. Status:Charged Off']), 0, 1)
# Drop the original 'loan_status' column
loan_data.drop(columns = ['loan_status'], inplace = True)
Now we have some more variables that are in categorical type and need to convert into numbers for further modelling for that we will be using the Label Encoder class from the sklearn library as below.
categorical_column = loan_data.select_dtypes('object').columns
for i in range(len(categorical_column)):
le = LabelEncoder()
loan_data[categorical_column[i]] = le.fit_transform(loan_data[categorical_column[i]])
Now, we are all set to train the various algorithms and will check which will perform best. Here we are evaluating one linear model, one Neighborhood model, two tree-based models, and one Naive-Bayes model. We will do cross_validation using KFold for 10 folds and will check mean accuracies for those folds.
# compare models
models = []
models.append(('LR', LogisticRegression()))
models.append(('KNN', KNeighborsClassifier()))
models.append((DT, DecisionTreeClassifier()))
models.append(('NB', GaussianNB()))
models.append(('RF', RandomForestClassifier()))
results = []
names = []
for name, model in models:
kfold = KFold(n_splits=10)
cv_results = cross_val_score(model, x_train, y_train, cv=kfold)
results.append(cv_results)
names.append(name)
msg = "%s: %f (%f)" % (name, cv_results.mean(), cv_results.std())
print(msg)
The Outperformance of Tree-Based Models
As we can see from the above mean accuracies the tree-based models performed far better than the rest of the others. This is because Tree-based algorithms provide great accuracy, stability, and interpretability to prediction models. They map nonlinear interactions pretty well, unlike linear models. They can adjust to any situation and solve any challenge (classification or regression).
Because tree creation requires no domain knowledge or parameter configuration, it is ideal for exploratory knowledge discovery. Multidimensional data can be handled via decision trees.
Attribute selection measures are used during tree construction to choose the attribute that best splits the tuples into distinct classes. Many of the branches in a tree may reflect noise or outliers in the training data. Tree trimming aims to locate and delete such branches in order to improve classification accuracy on data that isn’t visible.
In addition to these all, applications like Credit risk modeling where feature importance plays a very important role as it is going to decide the predictions. Using Decision Tree and likewise algorithms we can obtain feature importance maps and can tune models accordingly. Below you can see the feature importance map given by the Decision Tree algorithm.
In many kinds of data science challenges, methods including decision trees, random forests, and gradient boosting are often used.
#### Final Words
Through this post, we have discussed in detail credit risk and credit risk modelling. We have seen types of credit risk, factors affecting credit risk, and seen how ML can be used to model credit risk rather than the conventional method. Later we have seen the practical implementation of modelling where we have tested various models and concluded how tree-based algorithms have outperformed and hence these are preferred in such tasks.
## More Great AIM Stories
### Top Countries Pumping Money Into Quantum Computing Technology
Vijaysinh is an enthusiast in machine learning and deep learning. He is skilled in ML algorithms, data manipulation, handling and visualization, model building.
## Our Upcoming Events
Conference, in-person (Bangalore)
MachineCon 2022
24th Jun
Conference, Virtual
Deep Learning DevCon 2022
30th Jul
Conference, in-person (Bangalore)
Cypher 2022
21-23rd Sep
### Discord Server
Stay Connected with a larger ecosystem of data science and ML Professionals
### Telegram Channel
Discover special offers, top stories, upcoming events, and more.
##### Most used enterprise tools for digital-first firms in 2022
The enterprise software market got a major fillip after remote working became the norm.
##### AIM turns 10!
We have an opportunity to build a legacy.
##### Artificial bee colony and its applications to optimization problems
Honey bees’ foraging behaviour inspired the development of artificial bee colony.
##### 7 tricks to speed up the training of a neural network
There are a few approaches that can be used to reduce the training time time of neural networks.
##### Why the high accuracy in classification is not always correct?
The high accuracy of classification model could be misleading.
LTI and Mindtree both play in Analytics services businesses, just like most other large IT/ITes service providers. But, what would the analytics services business of the merged entity look like?
##### GitHub now offers math support in markdown
GitHub’s math rendering capability uses MathJax; an open-source, JavaScript-based display engine.
|
|
# Price–earnings ratio
Robert Shiller's plot of the S&P composite real price–earnings ratio and interest rates (1871–2012), from Irrational Exuberance, 2d ed.[1] In the preface to this edition, Shiller warns that "the stock market has not come down to historical levels: the price-earnings ratio as I define it in this book is still, at this writing [2005], in the mid-20s, far higher than the historical average. ... People still place too much confidence in the markets and have too strong a belief that paying attention to the gyrations in their investments will someday make them rich, and so they do not make conservative preparations for possible bad outcomes."
The price-earnings ratio, also known as P/E ratio, P/E, or PER, is the ratio of a company's share (stock) price to the company's earnings per share. The ratio is used for valuing companies and to find out whether they are overvalued or undervalued.
${\displaystyle P/E={\frac {\text{Share Price}}{\text{Earnings per Share}}}}$
As an example, if share A is trading at $24 and the earnings per share for the most recent 12-month period is$3, then share A has a P/E ratio of 24/3 or 8. Put another way, the purchaser of the share is investing \$8 for every dollar of earnings. Companies with losses (negative earnings) or no profit have an undefined P/E ratio (usually shown as "not applicable" or "N/A"); sometimes, however, a negative P/E ratio may be shown.
## Versions
S&P 500 shiller P/E ratio compared to trailing 12 months P/E ratio
There are multiple versions of the P/E ratio, depending on whether earnings are projected or realized, and the type of earnings.
• "Trailing P/E" uses the weighted average number of common shares in issue divided by the net income for the most recent 12-month period. This is the most common meaning of "P/E" if no other qualifier is specified. Monthly earnings data for individual companies are not available, and in any case usually fluctuate seasonally, so the previous four quarterly earnings reports are used and earnings per share are updated quarterly. Note, each company chooses its own financial year so the timing of updates varies from one to another.
• "Trailing P/E from continued operations" uses operating earnings, which exclude earnings from discontinued operations, extraordinary items (e.g. one-off windfalls and write-downs), and accounting changes.
• "Forward P/E": Instead of net income, this uses estimated net earnings over next 12 months. Estimates are typically derived as the mean of those published by a select group of analysts (selection criteria are rarely cited).
Some people mistakenly use the formula market capitalization / net income to calculate the P/E ratio. This formula often gives the same answer as market price / earnings per share, but if new capital has been issued it gives the wrong answer, as market capitalization = market price × current number of shares whereas earnings per share= net income / weighted average number of shares.
Variations on the standard trailing and forward P/E ratios are common. Generally, alternative P/E measures substitute different measures of earnings, such as rolling averages over longer periods of time (to attempt to "smooth" volatile or cyclical earnings, for example),[2] or "corrected" earnings figures that exclude certain extraordinary events or one-off gains or losses. The definitions may not be standardized. For companies that are loss-making, or whose earnings are expected to change dramatically, a "primary" P/E can be used instead, based on the earnings projections made for the next years to which a discount calculation is applied.
## Interpretation
As the ratio of a stock (share price) to a flow (earnings per share), the P/E ratio has the units of time. It can be interpreted as the amount of time over which the company would need to sustain its current earnings in order to make enough money to pay back the current share price.[3] While the P/E ratio can in principle be given in terms of any time unit, in practice it is essentially always implicitly reported in years, with the unit of "years" rarely indicated explicitly. (This is the convention followed in this article.)
The price/earnings ratio (PER) is the most widely used method for determining whether shares are "correctly" valued in relation to one another. But the PER does not in itself indicate whether the share is a bargain. The PER depends on the market’s perception of the risk and future growth in earnings. A company with a low PER indicates that the market perceives it as higher risk or lower growth or both as compared to a company with a higher PER. The PER of a listed company’s share is the result of the collective perception of the market as to how risky the company is and what its earnings growth prospects are in relation to that of other companies. Investors use the PER to compare their own perception of the risk and growth of a company against the market’s collective perception of the risk and growth as reflected in the current PER. If investors believe that their perception is superior to that of the market, they can make the decision to buy or sell accordingly.[4]
## Historical P/E ratios for the U.S. stock market
Price-Earnings ratios as a predictor of twenty-year returns based upon the plot by Robert Shiller (Figure 10.1,[1] source). The horizontal axis shows the real price-earnings ratio of the S&P Composite Stock Price Index as computed in Irrational Exuberance (inflation adjusted price divided by the prior ten-year mean of inflation-adjusted earnings). The vertical axis shows the geometric average real annual return on investing in the S&P Composite Stock Price Index, reinvesting dividends, and selling twenty years later. Data from different twenty-year periods is color-coded as shown in the key. See also ten-year returns. Shiller stated in 2005 that this plot "confirms that long-term investors—investors who commit their money to an investment for ten full years—did do well when prices were low relative to earnings at the beginning of the ten years. Long-term investors would be well advised, individually, to lower their exposure to the stock market when it is high, as it has been recently, and get into the market when it is low."[1]
Since 1900, the average P/E ratio for the S&P 500 index has ranged from 4.78 in Dec 1920 to 44.20 in Dec 1999.[5] However, except for some brief periods, during 1920–1990 the market P/E ratio was mostly between 10 and 20.[6]
The average P/E of the market varies in relation with, among other factors, expected growth of earnings, expected stability of earnings, expected inflation, and yields of competing investments. For example, when U.S. treasury bonds yield high returns, investors pay less for a given earnings per share and P/E's fall.
The average U.S. equity P/E ratio from 1900 to 2005 is 14 (or 16, depending on whether the geometric mean or the arithmetic mean, respectively, is used to average).[citation needed]
Jeremy Siegel has suggested that the average P/E ratio of about 15 [7] (or earnings yield of about 6.6%) arises due to the long term returns for stocks of about 6.8%. In Stocks for the Long Run, (2002 edition) he had argued that with favorable developments like the lower capital gains tax rates and transaction costs, P/E ratio in "low twenties" is sustainable, despite being higher than the historic average.
Set out below are the recent year end values of the S&P 500 index and the associated P/E as reported.[8] For a list of recent contractions (recessions) and expansions see U.S. Business Cycle Expansions and Contractions.
Date Index P/E EPS growth % Comment
2018-03-31 2640.87 22.88
2017-12-31 2673.61 24.33
2016-12-31 2238.83 23.68
2015-12-31 2043.94 23.62
2014-12-31 2058.90 20.12
2013-12-31 1848.36 18.45
2012-12-31 1426.19 16.49
2011-12-31 1257.60 14.46
2010-12-31 1257.64 16.26
2009-12-31 1115.10 21.88
2008-12-31 903.25 60.70
2007-12-31 1468.36 22.19 1.4
2006-12-31 1418.30 17.40 14.7
2005-12-31 1248.29 17.85 13.0
2004-12-31 1211.92 20.70 23.8
2003-12-31 1111.92 22.81 18.8
2002-12-31 879.82 31.89 18.5
2001-12-31 1148.08 46.50 −30.8 2001 contraction resulting in P/E peak
2000-12-31 1320.28 26.41 8.6 Dot-com bubble burst: 10 March 2000
1999-12-31 1469.25 30.50 16.7
1998-12-31 1229.23 32.60 0.6
1997-12-31 970.43 24.43 8.3
1996-12-31 740.74 19.13 7.3
1995-12-31 615.93 18.14 18.7
1994-12-31 459.27 15.01 18.0 Low P/E due to high recent earnings growth.
1993-12-31 466.45 21.31 28.9
1992-12-31 435.71 22.82 8.1
1991-12-31 417.09 26.12 −14.8
1990-12-31 330.22 15.47 −6.9 July 1990 – March 1991 contraction.
1989-12-31 353.40 15.45 .
1988-12-31 277.72 11.69 . Bottom (Black Monday was 19 Oct 1987)
Note that at the height of the Dot-com bubble P/E had risen to 32. The collapse in earnings caused P/E to rise to 46.50 in 2001. It has declined to a more sustainable region of 17. Its decline in recent years has been due to higher earnings growth.
The P/E ratio of a company is a major focus for many managers. They are usually paid in company stock or options on their company's stock (a form of payment that is supposed to align the interests of management with the interests of other stock holders). The stock price can increase in one of two ways: either through improved earnings or through an improved multiple that the market assigns to those earnings. In turn, the primary drivers for multiples such as the P/E ratio is through higher and more sustained earnings growth rates.
Consequently, managers have strong incentives to boost earnings per share, even in the short term, and/or improve long term growth rates. This can influence business decisions in several ways:
• If a company wants to acquire companies with a higher P/E ratio than its own, it usually prefers paying in cash or debt rather than in stock. Though in theory the method of payment makes no difference to value, doing it this way offsets or avoids earnings dilution (see accretion/dilution analysis).
• Conversely, companies with higher P/E ratios than their targets are more tempted to use their stock to pay for acquisitions.
• Companies with high P/E ratios but volatile earnings may be tempted to find ways to smooth earnings and diversify risk—this is the theory behind building conglomerates.
• Conversely, companies with low P/E ratios may be tempted to acquire small high growth businesses in an effort to "rebrand" their portfolio of activities and burnish their image as growth stocks and thus obtain a higher PE rating.
• Companies try to smooth earnings, for example by "slush fund accounting" (hiding excess earnings in good years to cover for losses in lean years). Such measures are designed to create the image that the company always slowly but steadily increases profits, with the goal to increase the P/E ratio.
• Companies with low P/E ratios are usually more open to leveraging their balance sheet. As seen above, this mechanically lowers the P/E ratio, which means the company looks cheaper than it did before leverage, and also improves earnings growth rates. Both of these factors help drive up the share price.
• Strictly speaking, the ratio is measured in years, since the price is measured in dollars and earnings are measured in dollars per year. Therefore, the ratio demonstrates how many years it takes to cover the price, if earnings stay the same.
## Related measures
2. ^ Anderson, K.; Brooks, C. (2006). "The Long-Term Price-Earnings Ratio". SSRN 739664. Cite journal requires |journal= (help)
|
|
# Evaluate 19q + 99p
#### anemone
##### MHB POTW Director
Staff member
Two of the roots of the equation $$\displaystyle 2x^3-8x^2+9x+p=0$$ are also roots of the equation $$\displaystyle 2x^3+8x^2-7x+q=0$$. Evaluate $$\displaystyle 19q+99p$$.
#### Opalg
##### MHB Oldtimer
Staff member
Re: Evaluate 19q+99p
Two of the roots of the equation $$\displaystyle 2x^3-8x^2+9x+p=0$$ are also roots of the equation $$\displaystyle 2x^3+8x^2-7x+q=0$$. Evaluate $$\displaystyle 19q+99p$$.
Use Vieta's relations. The sum of the roots of the first equation is $4$, and the sum of the roots of the second equation is $-4$. So if the roots of the first equation are $\alpha,\ \beta$ and $\gamma$, then the roots of the second equation are $\alpha,\ \beta$ and $\gamma-8$. Vieta's relations tell us that
$$\alpha\beta + \beta\gamma + \gamma\alpha = 9/2,\qquad \alpha\beta + (\alpha+\beta)(\gamma-8) = -7/2.$$ Therefore $-\frac72 = \frac92 - 8(\alpha+\beta)$, from which $\alpha+\beta = 1$. But $\alpha + \beta + \gamma = 4$, and so $\gamma=3$ (and $\gamma-8 = -5$).
Putting $x=3$ as a solution to the first equation, you find that $p=-9$; and putting $x=-5$ as a solution to the second equation, you find that $q=15$.
You can then find $19q + 99p = -606$ but that seems a bit pointless.
#### Jester
##### Well-known member
MHB Math Helper
Re: Evaluate 19q+99p
I thought the same but my way was a little longer. There must be a clever way at getting to the answer.
#### anemone
##### MHB POTW Director
Staff member
Re: Evaluate 19q+99p
Hmm...now that I see how Opalg approached the problem, I have to admit that this problem serves little purpose and is a weak problem.
Hi Jester, I think what Opalg has given here is the smartest and shortest solution but having said this, I will also show my solution in this post.
Let a, b, and m be the roots of the equation $$\displaystyle 2x^3-8x^2+9x+p=0$$ and a, b and k be the roots of the equation $$\displaystyle 2x^3+8x^2-7x+q=0$$.
We see that the sum of the roots for both equations are:
$$\displaystyle a+b+m=4$$
$$\displaystyle a+b+k=-4$$
Subtracting the second equation from the first equation, we obtain:
$$\displaystyle m-k=8$$
and the product of the roots for both equations are:
$$\displaystyle abm=-\frac{p}{2}$$, $$\displaystyle abk=-\frac{q}{2}$$
Dividing these two equations, we obtain:
$$\displaystyle \frac{m}{k}=\frac{p}{q}$$
By Newton Identities, we have:
$$\displaystyle (a^2+b^2+m^2)(2)+(-8)(4)+2(9)=0\implies a^2+b^2+m^2=7$$
$$\displaystyle (a^2+b^2+k^2)(2)+(8)(-4)+2(-7)=0\implies a^2+b^2+k^2=23$$
Subtracting these two equations yields:
$$\displaystyle k^2-m^2=16$$
$$\displaystyle (k+m)(k-m)=16$$
$$\displaystyle (k+m)(-8)=16$$
$$\displaystyle m+k=-2$$
Solving the equations $m+k=-2$ and $m-k=8$ for both $m$ and $k$, we get $m=3$ and $k=-5$.
When $m=3$, $$\displaystyle a+b+3=4\implies a+b=1$$
Substituting $m=3,\,k=-5,\,a+b=1$ back into the equations $$\displaystyle a^2+b^2+m^2=7$$, $$\displaystyle abm=-\frac{p}{2}$$ and $$\displaystyle abk=-\frac{q}{2}$$, we see that:
$$\displaystyle (a+b)^2-2ab+(3)^2=7$$
$$\displaystyle (1)^2-2ab+(3)^2=7$$
$$\displaystyle ab=\frac{3}{2}$$
Hence, $$\displaystyle \frac{3}{2}(3)=-\frac{p}{2}\implies p=-9$$ and $$\displaystyle \frac{3}{2}(-5)=-\frac{q}{2}\implies q=15$$.
And this gives $$\displaystyle 19q+99p=19(15)+99(-9)=-606$$
|
|
<img src="https://d5nxst8fruw4z.cloudfront.net/atrk.gif?account=iA1Pi1a8Dy00ym" style="display:none" height="1" width="1" alt="" />
# 10.17: Surface Area of Cylinders
Difficulty Level: At Grade Created by: CK-12
Estimated11 minsto complete
%
Progress
Practice Surface Area of Cylinders
MEMORY METER
This indicates how strong in your memory this concept is
Progress
Estimated11 minsto complete
%
Estimated11 minsto complete
%
MEMORY METER
This indicates how strong in your memory this concept is
Do you know what modge podge is? Have you ever used decoupage of some kind?
Jillian is going to use modge podge to decorate the outside of a cylindrical canister. She wants to make it into a decorative pencil holder as a gift for her grandmother. Modge podge is a glue - like substance that helps to adhere tissue paper or other decorative pieces of paper to an object.
Jillian's canister is 6 inches in diameter and 8 inches tall.
How much surface area will she need to cover?
To figure this out, you will need to know how to calculate the surface area of a cylinder. This Concept will teach you what you need to know to accomplish this task.
### Guidance
You have learned about how to calculate the surface area and volume of different prisms. In this section, you will learn about calculating the surface area and volume of cylinders. Let’s start with calculating the surface area of a cylinder.
Here is a cylinder. Notice that it has two parallel congruent circular bases. The face of the cylinder is one large rectangle. In fact, if you were to “unwrap” a cylinder here is what you would see.
This is what the net of a cylinder looks like.
Just like when we were working with prisms, we can use the net of a cylinder to calculate the surface area of the cylinder.
How can we calculate the surface area of a cylinder using a net?
To calculate the surface area of a cylinder using a net, we need to figure out the area of the two circles and the area of the rectangle too.
Let’s think back to how to find the area of a circle. To find the area of a circle, we use the following formula.
\begin{align*}A = \pi r^2\end{align*}
There are two circular bases in the cylinder, so we can multiply the area of the circle by two and have the sum of the two areas.
\begin{align*}A = 2\pi r^2\end{align*}
The radius of the circles in the net above is 3 inches. We can substitute this given value into the formula and figure out the area of the two circles.
\begin{align*}A & = 2\pi r^2\\ A & = 2(3.14)(3^2)\\ A & = 2(3.14)(9)\\ A & = 2(28.26)\\ A & = 56.52 \ in^2\end{align*}
Next, we need to figure out the area of the curved surface. If you look at the net, the curved surface of the cylinder is rectangular in shape.
The length of the rectangle is the same as the circumference of the circle. Huh? Let’s look at the net. Since the length of the rectangle wraps around the circle rim, it is the same length as the circumference of the circle. To find the area of the curved surface, we need the circumference times the height.
\begin{align*}A & = 2\pi rh\\ A & = 2(3.14)(3)(5)\\ A & = 2(3.14)(15)\\ A & = 2(47.1)\\ A & = 94.2 \ in^2\end{align*}
Now we can add up the areas.
\begin{align*}SA & = 56.52 + 94.2 = 150.72 \ in^2\end{align*}
The surface area of the cylinder is \begin{align*}150.72 \ in^2\end{align*}.
The formula for finding the surface area of a cylinder combines the formula for the area of the top and bottom circles with the formula for finding the area of the rectangular 'wrap' around the side. Remember that the wrap has a length equal to the circumference of the circular end, and a width equal to the height of the cylinder. Here it is.
We work this problem through by substituting the given values into the formula. 4 centimeters is the radius of the circular bases. 8 centimeters is the height of the cylinder.
\begin{align*}SA & = 2\pi r^2 + 2\pi rh\\ SA & = 2(3.14)(4^2) + 2(3.14)(4)(8)\\ SA & = 2(3.14)(16) + 2(3.14)(32)\\ SA & = 2(50.24) + 2(100.48)\\ SA & = 100.48 + 200.96\\ SA & = 301.44 \ cm^2\end{align*}
The surface area of the cylinder is \begin{align*}301.44 \ cm^2\end{align*}. Notice that this works well whether you have a net or a picture of a cylinder. As long as you use the formula and the given values, you can figure out the surface area of the cylinder.
Now it's time for you to try a few. Find the surface area of each cylinder.
#### Example A
Solution: \begin{align*}175.84\end{align*} sq. in.
#### Example B
Solution: \begin{align*}471\end{align*} sq. m
#### Example C
Solution:\begin{align*}703.36\end{align*} sq. in.
Here is the original problem once again.
Jillian is going to use modge podge to decorate the outside of a cylindrical canister. She wants to make it into a decorative pencil holder as a gift for her grandmother. Modge podge is a glue - like substance that helps to adhere tissue paper or other decorative pieces of paper to an object.
Jillian's canister is 6 inches in diameter and 8 inches tall.
How much surface area will she need to cover?
To solve this problem of surface area, we can use the formula for finding the surface area of a cylinder. Then we substitute in the given values and solve.
\begin{align*}SA & = 2\pi r^2 + 2\pi rh\\ SA & = 2(3.14)(3^2) + 2(3.14)(3)(8)\\ SA & = 2(3.14)(9) + 2(3.14)(24)\\ SA & = 2(28.29) + 2(75.36)\\ SA & =56.58 + 150.72\\ SA & = 207.3 \ in^2\end{align*}
This is the surface area of Jillian's cylinder.
### Vocabulary
Here are the vocabulary words in this Concept.
Surface Area
the entire outer covering or surface of a three-dimensional figure. It is calculated by the sum of the areas of each of the faces and bases of a solid.
Cylinder
a three-dimensional figure with two congruent parallel circular bases and a curved flat surface connecting the bases.
the measure of the distance halfway across a circle.
### Guided Practice
Here is one for you to try on your own.
What is the surface area of a cylinder with a radius of 6 inches and a height of 12 inches?
To complete this problem, we can use the formula for surface area presented in the Concept and then substitute in the given values.
\begin{align*}SA & = 2\pi r^2 + 2\pi rh\\ SA & = 2(3.14)(6^2) + 2(3.14)(6)(12)\\ SA & = 2(3.14)(36) + 2(3.14)(72)\\ SA & = 226.08 + 452.16\\ SA & = 678.24 \ in^2\end{align*}
### Video Review
Here is a video for review.
### Practice
Directions: Calculate the surface area of each of the following cylinders using nets.
1.
2.
3.
4.
5.
Directions: Calculate the surface area of the following cylinders given these dimensions.
6. r = 4 in, h = 8 in
7. r = 5 in, h = 15 in
8. r = 8 m, h = 16 m
9. r = 11 m, h = 20 m
10. r = 3.5 m, h = 8 m
11. d = 4 ft, h = 6 ft
12. d = 10 ft, h = 15 ft
13. d = 20 cm, h = 25 cm
14. d = 18 in, h = 24 in
15. d = 20 ft, h = 45 ft
### Notes/Highlights Having trouble? Report an issue.
Color Highlighted Text Notes
### Vocabulary Language: English
The radius of a circle is the distance from the center of the circle to the edge of the circle.
Surface Area
Surface area is the total area of all of the surfaces of a three-dimensional object.
Show Hide Details
Description
Difficulty Level:
Authors:
Tags:
Subjects:
|
|
# Kretschmann scalar
Jump to: navigation, search
In the theory of Lorentzian manifolds, particularly in the context of applications to general relativity, the Kretschmann scalar is a quadratic scalar invariant. It was introduced by Erich Kretschmann.[1]
## Definition
The Kretschmann invariant is[1][2]
$K = R_{abcd} \, R^{abcd}$
where $R_{abcd}$ is the Riemann curvature tensor. Because it is a sum of squares of tensor components, this is a quadratic invariant.
For Schwarzschild black hole, the Kretschmann scalar is[1]
$K = \frac{48 G^2 M^2}{c^4 r^6} \,.$
## Relation to other invariants
Another possible invariant (which has been employed for example in writing the gravitational term of the Lagrangian for some higher-order gravity theories) is
$C_{abcd} \, C^{abcd}$
where $C_{abcd}$ is the Weyl tensor, the conformal curvature tensor which is also the completely traceless part of the Riemann tensor. In $d$ dimensions this is related to the Kretschmann invariant by[3]
$R_{abcd} \, R^{abcd} = C_{abcd} \, C^{abcd} +\frac{4}{d-2} R_{ab}\, R^{ab} - \frac{2}{(d-1)(d-2)}R^2$
where $R^{ab}$ is the Ricci curvature tensor and $R$ is the Ricci scalar curvature (obtained by taking successive traces of the Riemann tensor).
The Kretschmann scalar and the Chern-Pontryagin scalar
$R_{abcd} \, {{}^\star \! R}^{abcd}$
where ${{}^\star R}^{abcd}$ is the left dual of the Riemann tensor, are mathematically analogous (to some extent, physically analogous) to the familiar invariants of the electromagnetic field tensor
$F_{ab} \, F^{ab}, \; \; F_{ab} \, {{}^\star \! F}^{ab}$
## References
1. ^ a b c Richard C. Henry (2000). "Kretschmann Scalar for a Kerr-Newman Black Hole". The Astrophysical Journal (The American Astronomical Society) 535: 350–353. arXiv:astro-ph/9912320v1. Bibcode:2000ApJ...535..350H. doi:10.1086/308819.
2. ^ Grøn & Hervik 2007, p 219
3. ^ Cherubini, Christian; Bini, Donato; Capozziello, Salvatore; Ruffini, Remo (2002). "Second Order Scalar Invariants of the Riemann Tensor: Applications to Black Hole Spacetimes". International Journal of Modern Physics D 11 (06): 827–841. arXiv:gr-qc/0302095v1. Bibcode:2002IJMPD..11..827C. doi:10.1142/S0218271802002037. ISSN 0218-2718.
|
|
# The Information Structuralist
## Information flow on graphs
Posted in Information Theory, Models of Complex Stochastic Systems, Probability by mraginsky on May 3, 2014
Models of complex systems built from simple, locally interacting components arise in many fields, including statistical physics, biology, artificial intelligence, communication networks, etc. The quest to understand and to quantify the fundamental limits on the ability of such systems to store and process information has led to a variety of interesting and insightful results that draw upon probability, combinatorics, information theory, discrete and continuous dynamical systems, etc. In this post, I would like to focus on a model of distributed storage that was analyzed in 1975 by Donald Dawson in a very nice paper, which deserves to be more widely known.
## ISIT 2013: two plenaries on concentration of measure
Posted in Conference Blogging, Information Theory, Mathematics, Probability by mraginsky on July 29, 2013
Of the five plenary talks at this year’s ISIT, two were about concentration of measure: Katalin Marton’s Shannon lecture on “Distance-divergence inequalities” and Gabor Lugosi’s talk on “Concentration inequalities and the entropy method” the next morning. Since the topic of measure concentration is dear to my heart, I thought I would write down a few unifying themes.
## Stochastic kernels vs. conditional probability distributions
Posted in Control, Feedback, Information Theory, Probability by mraginsky on March 17, 2013
Larry Wasserman‘s recent post about misinterpretation of p-values is a good reminder about a fundamental distinction anyone working in information theory, control or machine learning should be aware of — namely, the distinction between stochastic kernels and conditional probability distributions.
## Concentrate, concentrate!
Posted in Information Theory, Mathematics, Narcissism, Papers and Preprints, Probability by mraginsky on December 19, 2012
Igal Sason and I have just posted to arXiv our tutorial paper “Concentration of Measure Inequalities in Information Theory, Communications and Coding”, which was submitted to Foundations and Trends in Communications and Information Theory. Here is the abstract:
This tutorial article is focused on some of the key modern mathematical tools that are used for the derivation of concentration inequalities, on their links to information theory, and on their various applications to communications and coding.
The first part of this article introduces some classical concentration inequalities for martingales, and it also derives some recent refinements of these inequalities. The power and versatility of the martingale approach is exemplified in the context of binary hypothesis testing, codes defined on graphs and iterative decoding algorithms, and some other aspects that are related to wireless communications and coding.
The second part of this article introduces the entropy method for deriving concentration inequalities for functions of many independent random variables, and it also exhibits its multiple connections to information theory. The basic ingredients of the entropy method are discussed first in conjunction with the closely related topic of logarithmic Sobolev inequalities. This discussion is complemented by a related viewpoint based on probability in metric spaces. This viewpoint centers around the so-called transportation-cost inequalities, whose roots are in information theory. Some representative results on concentration for dependent random variables are briefly summarized, with emphasis on their connections to the entropy method.
Finally, the tutorial addresses several applications of the entropy method and related information-theoretic tools to problems in communications and coding. These include strong converses for several source and channel coding problems, empirical distributions of good channel codes with non-vanishing error probability, and an information-theoretic converse for concentration of measure.
There are already many excellent sources on concentration of measure; what makes ours different is the emphasis on information-theoretic aspects, both in the general theory and in applications. Comments, suggestions, thoughts are very welcome.
## Blackwell’s proof of Wald’s identity
Posted in Mathematics, Probability by mraginsky on April 29, 2011
Every once in a while you come across a mathematical argument of such incredible beauty that you feel compelled to tell the whole world about it. This post is about one such gem: David Blackwell’s 1946 proof of Wald’s identity on the expected value of a randomly stopped random walk. In fact, even forty years after the publication of that paper, in a conversation with Morris DeGroot, Blackwell said: “That’s a paper I’m still very proud of. It just gives me pleasant feelings every time I think about it.”
## Divergence in everything: erasure divergence and concentration inequalities
Posted in Information Theory, Probability, Statistical Learning and Inference by mraginsky on March 18, 2011
It’s that time again, the time to savor the dreamy delights of divergence!
(image yoinked from Sergio Verdú‘s 2007 Shannon Lecture slides)
In this post, we will look at a powerful information-theoretic method for deriving concentration-of-measure inequalities (i.e., tail bounds) for general functions of independent random variables.
## In Soviet Russia, the sigma-field conditions on you
Quote of the day, from Asymptotics in Statistics: Some Basic Concepts by Lucien Le Cam and Grace Yang (emphasis mine):
The idea of developing statistical procedures that minimize an expected loss goes back to Laplace … [and] reappears in papers of Edgeworth. According to Neyman in his Lectures and Conferences: “After Edgeworth, the idea of the loss function was lost from sight for more than two decades …” It was truly revived only by the appearance on the statistical scene of Wald. Wald’s books Sequential Analysis and Statistical Decision Functions are based on that very idea of describing experiments by families of probability measures either on one given $\sigma$-field or on sequence of $\sigma$-fields to be chosen by the statistician. The idea seems logical enough if one is used to it. However, there is a paper by Fisher where he seems to express the opinion that such concepts are misleading and good enough only for Russian or American engineers.
## Bad taste of monumental proportions
Posted in Papers and Preprints, Probability by mraginsky on October 16, 2010
This passage from “The Glivenko-Cantelli problem, ten years later” by Michel Talagrand (J. Theoretical Probability, vol. 9, no. 2, pp. 371-384, 1996) will most likely be remembered forever as the best example of wry self-deprecating wit in an academic paper:
Over 10 years ago I wrote a paper that describes in great detail Glivenko-Cantelli classes. Despite the fact that Glivenko-Cantelli classes are certainly natural and important, this paper apparently has not been understood. The two main likely reasons are that the proofs are genuinely difficult; and that the paper displays bad taste of monumental proportion, in the sense that a lot of energy is devoted to extremely arcane measurability questions, which increases the difficulty of the proofs even more.
## Divergence in everything: mixing rates for finite Markov chains
Posted in Information Theory, Probability by mraginsky on October 14, 2010
This is the first post in a series aobut the versatility and the power of the good old Kullback-Leibler divergence.
(image yoinked from Sergio Verdú‘s 2007 Shannon Lecture slides)
Today I will describe a beautiful application of the divergence to the problem of determining mixing rates of finite Markov chains. This argument is quite recent, and comes from a nice paper by Sergey Bobkov and Prasad Tetali (“Modified logarithmic Sobolev inequalities in discrete settings,” Journal of Theoretical Probability, vol. 19, no. 2, pp. 209-336, 2006; preprint). Since my interest here is information-theoretic, I will take for granted certain facts from the theory of finite Markov chains.
|
|
$A=\begin{bmatrix}0 & 1 & 0\\ 1 & 0 & 1\\ 1 & 0 & 0\end{bmatrix}$
How can I use Cayley–Hamilton theorem to calculate $A^{12}$?
|
|
Chapter 11 - Section 11.2 - The Cosine Ratio and Applications - Exercises: 21
$c\approx19.1$ in. $d\approx14.8$ in.
Work Step by Step
$\cos51=\frac{12}{c}$ $c=\frac{12}{\cos51}$ $c\approx19.1$ $\sin51=\frac{d}{c}$ $\sin51\approx\frac{d}{19.1}$ $19.1\times\sin51\approx d$ $d\approx14.8$
After you claim an answer you’ll have 24 hours to send in a draft. An editor will review the submission and either publish your submission or provide feedback.
|
|
# Brownian bridge sde
The SDE for the Brownian bridge is the following:
$dX_t = \dfrac{b-X_t}{1-t}dt+dB_t$
with the solution
$X_t = a(1-t)+bt+(1-t)\int_{0}^t \dfrac{dB_s}{1-s}$.
The expectation and covariance are:
$\mathbb{E}(X_t) = a+(b-a)t$
$Cov(X_s,X_t) = min(s,t)-st$
Now I want to have a look at what happens as $t\rightarrow 1$.
For the expectation and covariance I get
$\mathbb{E}(X_1) = b$,
$Cov(X_s,X_1) = min(s,1)-s$
But I'm having trouble to see what happens with $X_t$. The first two summands clearly go to b, and the last summand should go to 0 as Brownian bridge expression for a Brownian motion suggests. The prove in the last comment using Doob's maximal inequality and Borel-Cantelli is quite short and I don't understand, what's exactly happening there, especially not, where the last equation comes from. Would be great if someone could explain it more exact how I get $\lim_{t \rightarrow 1} (1-t)\int_{0}^t \dfrac{dB_s}{1-s} = 0$ a.s.
• A first approach is to compute the second moment, since $$\mathrm{var}(X_t)=(1-t)^2\int_0^t\frac{ds}{(1-s)^2}=t(1-t),$$ one sees that $X_t\to1$ in $L^2$ when $t\to1$. – Did Jul 22 '15 at 10:07
• Thank you! The second moment is $\mathbb{E}(X_t^2) = [a(1-t)+bt]^2 + t (1-t)$, as calculated here:math.stackexchange.com/questions/408620/brownian-bridge?rq=1, but I don't see how the estimate in math.stackexchange.com/questions/115727/… follows from that...how can I continue? – Max93 Jul 22 '15 at 10:24
• The process is "bridge" between $a$ and $b$, hence $X_1=b$ so is $X_0=a$. – Math-fun Jul 22 '15 at 10:52
• @Did $EX_1=b$ with variance vanishing at $1$ we obtain $X_1 \to b$. – Math-fun Jul 22 '15 at 10:55
• @Math-fun Yeah, actually, the correct statement this yields is that $X_t\to b$ in $L^2$ when $t\to1$. – Did Jul 22 '15 at 11:38
First notice that $$\int_0^t f(s) dB_s$$ has the same distribution as $$B_{\int_0^t f(s)^2ds}$$. This equality of distributions is true as processes in $$t$$ (not just for a single value of $$t$$). The way to prove this is to note that both are Gaussian processes with the same covariance kernel.
Using this with $$f(s) = \frac{1}{1-s}$$, one obtains that $$\int_0^t \frac{dB_s}{1-s}$$ is the same process (in law) as $$B_{\frac{t}{1-t}}$$. So we just need to show that $$\lim_{t \to 1} (1-t)B_{\frac{t}{1-t}} = 0$$ a.s. This is equivalent to showing $$\frac{B_u}{u} \to 0$$ as $$u \to \infty$$. By time inversion, this is in turn equivalent to showing that $$B_s \to 0$$ as $$s \to 0$$, which is obvious from continuity of paths.
• Obviously it might just be simpler to note that the covariance structure is the same as $B_t-tB_1$, but this method is more general. – Shalop Feb 14 at 14:51
|
|
## Intermediate Algebra for College Students (7th Edition)
Set-builder notation: $\left\{x | -3 \le x \lt 2\right\}$ Graph:
A bracket beside $-3$ means $-3$ is included in the set. A parentheses beside $2$ means $2$ is not included in the set. Thus, in inequality notation, the set is $-3 \le x \lt 2$. In set-builder notation, this can be written as: $\left\{x | -3 \le x \lt 2\right\}$ To graph the set on a number line, plot a solid dot at $-3$ and a hole (or hollow dot) at $2$ then shade the region in between (refer to the attached image in the answer part above).
|
|
# User-defined functions
Domains:
A function may be defined using syntax such as the following:
Example #1 Pseudo code to demonstrate function uses
<?php
function foo($arg_1,$arg_2, /* ..., */ $arg_n) { echo "Example function.\n"; return$retval;
}
?>
Any valid PHP code may appear inside a function, even other functions and class definitions.
Function names follow the same rules as other labels in PHP. A valid function name starts with a letter or underscore, followed by any number of letters, numbers, or underscores. As a regular expression, it would be expressed thus: [a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*.
Tip
Functions need not be defined before they are referenced, except when a function is conditionally defined as shown in the two examples below.
When a function is defined in a conditional manner such as the two examples shown. Its definition must be processed prior to being called.
Example #2 Conditional functions
<?php
$makefoo = true; /* We can't call foo() from here since it doesn't exist yet, but we can call bar() */ bar(); if ($makefoo) {
function foo()
{
echo "I don't exist until program execution reaches me.\n";
}
}
/* Now we can safely call foo()
since $makefoo evaluated to true */ if ($makefoo) foo();
function bar()
{
echo "I exist immediately upon program start.\n";
}
?>
Example #3 Functions within functions
<?php
function foo()
{
function bar()
{
echo "I don't exist until foo() is called.\n";
}
}
/* We can't call bar() yet
since it doesn't exist. */
foo();
/* Now we can call bar(),
foo()'s processing has
bar();
?>
All functions and classes in PHP have the global scope - they can be called outside a function even if they were defined inside and vice versa.
PHP does not support function overloading, nor is it possible to undefine or redefine previously-declared functions.
Note: Function names are case-insensitive, though it is usually good form to call functions as they appear in their declaration.
Both variable number of arguments and default arguments are supported in functions. See also the function references for func_num_args(), func_get_arg(), and func_get_args() for more information.
It is possible to call recursive functions in PHP.
Example #4 Recursive functions
<?php
function recursion($a) { if ($a < 20) {
echo "$a\n"; recursion($a + 1);
}
}
?>
Note: Recursive function/method calls with over 100-200 recursion levels can smash the stack and cause a termination of the current script. Especially, infinite recursion is considered a programming error.
Page structure
Terms
|
|
Can a finite subbasis create an infinite topology / topological space?
I've translated the following from my German textbook, so please correct me if there is something wrong or strange.
Definitions
Let $X$ be a set and $\mathfrak{T} \subseteq \mathcal{P}(X)$ with fits the following restrictions:
(i) $\emptyset, X \in \mathfrak{T}$
(ii) $\forall U_1, U_2 \in \mathfrak{T}: U_1 \cap U_2 \in \mathfrak{T}$
(iii) Let $I$ be an index set with $\forall i \in I: U_i \in \mathfrak{T}$. Then: $\bigcup_{i \in I} U_i \in \mathfrak{T}$
Then $\mathfrak{T}$ is called a topology and $(X, \mathfrak{T})$ is called a topological space
Let $(X, \mathfrak{T})$ be a topological space. $\mathcal{S} \subseteq \mathfrak{T}$ is called a subbasis of $\mathfrak{T} : \Leftrightarrow \forall U \in \mathfrak{T}: U$ is a union of finite intersections from Elements in $\mathcal{S}$.
Questions
Can a finite subbasis generate an infinite topology? Or, more formally, is the following implication true:
$$|\mathcal{S}| \in \mathbb{N} \Rightarrow |\mathfrak{T}| \in \mathbb{N}$$
Can a finite subbasis generate any topology for an infinite space $X$? So, formally:
$$|\mathcal{S}| \in \mathbb{N} \Rightarrow |X| \in \mathbb{N}$$
No. If $\mathcal{S}$ is a finite, set, then there are only finitely many (nonempty) finite subcollections of that set, and so the family $\mathcal{I}$ of intersections of (nonempty) finite subcollections of $\mathcal{S}$ is also finite (saying "finite" here is somewhat redundant). As there are only finitely many subcollections of $\mathcal{I}$, there are only finitely many distinct unions of subcollections of $\mathcal{I}$. Thus any topology generated by a finite subbasis is itself finite.
In particular, the usual metric topology on $\mathcal{R}$ has no finite subbase.
(Even more, given an arbitrary subbasis $\mathcal{S}$ on a set $X$, either $\mathcal{S}$ and $\mathcal{I}$ (as described above) above are both finite, or are both infinite and of the same cardinality. It follows that the topology generated by $\mathcal{S}$ has cardinality bounded above by some cardinal related to $| \mathcal{S} |$. In the finite case, it would be $2^{2^{|\mathcal{S}|}}$, and in the infinite case it is $2^{|\mathcal{S}|}$.)
• Is a subcollection the same as a subset of a set of sets? So $A \subseteq \mathfrak{T}$ is always a subcollection? – Martin Thoma Feb 21 '14 at 19:38
|
|
# How do you find the amplitude and period for y= 6 sin x?
Apr 27, 2015
In general for an equality of the form
$y = a \cdot \sin \left(b \cdot x\right)$
the amplitude is $a$
and
the period is $\frac{2 \pi}{b}$
So
$y = 6 \sin \left(x\right)$
has an amplitude of $6$
and
a period of $2 \pi$
|
|
# 談話会・セミナー
TOP > 談話会・セミナー > セミナー
## Number Theory / Arithmetic Geometry Seminar
Title
Galois action on the etale fundamental group of the Fermat curve.
Date
October 7 (Mon), 2019, 16:30-17:30
Room
Room 110, RIMS
Speaker
Abstract
If $X$ is a curve defined over a number field $K$, then we are motivated to understand the action of the absolute Galois group of $K$ on the etale fundamental group of $X$. When $X$ is the Fermat curve of degree $p$ and $K$ is the cyclotomic field generated by a pth root of unity, Anderson proved several theorems about this action on the etale homology of $X$. In earlier work, we made Anderson's results more explicit, when the homology has coefficients modulo $p$. More recently, we use a cup product in cohomology to determine the action on the lower central series of the fundamental group of the Fermat curve with coefficients modulo $p$. The proof involves some fun Galois theory and combinatorics. This is joint work with Davis and Wickelgren.
Organizer Akio Tamagawa, Naotake Takao (RIMS, Kyoto Univ.)
Date
March 11 and 12, 2019
Place
Monday, March 11, 16:00-17:00
Speaker
Rasmussen, Christopher (Wesleyan University)
Title
Improvements on Bounds for Heavenly Abelian Varieties
Abstract
For a rational prime $\ell > 2$, a natural question arising from the study of the arithmetic of certain Galois representations attached to fundamental groups is to consider the collection of abelian varieties over a fixed number field $K$ whose $\ell$-power torsion generates an extension of $K(\mu_{\ell})$ which is both pro-$\ell$ and unramified away from $\ell$. (We say such an abelian variety is heavenly at $\ell$.) Conjecturally, the set of $K$-isomorphism classes of heavenly varieties of fixed dimension $g$ is finite -- even when the prime $\ell$ is permitted to vary. In past joint work with Tamagawa, we have provided a proof of the Conjecture under GRH, and settled the Conjecture positively in a number of cases.
Such results imply the existence of a bound $L = L(K,g)$ such that $\ell < L$ for heavenly abelian varieties over $K$ of dimension $g$. Explicit formulas for such a bound $L$ exist in general, but are too weak to be of practical use. In this talk, we review previous results and also demonstrate a method for improving such bounds when one is willing to restrict attention to a fixed field $K$ and dimension $g$.
Tuesday, March 12 10:30-11:30
Speaker
Rasmussen, Christopher (Wesleyan University)
Title
Algorithms for Solving S-Unit Equations
Abstract
Many enumerative problems in arithmetic geometry and number theory take the form Find, up to isomorphism, all objects $\mathcal{O}$ with arithmetic property $\mathcal{P}(S)$,'' where the data $S$ is a finite set of places of a fixed number field $K$. Such problems often encounter a common computational obstacle; namely the solution of the $S$-unit equation $x + y = 1$ over the ring of $S$-integers of $K$. In this talk, we describe joint work with several mathematicians to create an open-source implementation of such an algorithm for general choices of $K$ and $S$. (Emphasis of this discussion will be on the mathematical, rather than computational, aspects of the project.) In addition, we provide some new partial results to various problems, including Asymptotic Fermat's Last Theorem over certain cubic number fields.
Tuesday, March 12 13:30-15:00
Speaker
Sakugawa, Kenji (RIMS)
Title
On Jannsen's conjecture for modular forms
Abstract
Let M be a pure motive over Q and let M_p denotes its p-adic etale realization for each prime number p. In 1987's paper, Jannsen proposed a conjecture about a range of integers r such that the second Galois cohomology of M(r)_p vanishes for any prime number p. Here, M(r) denotes the rth Tate twist of M. When M is an Artin motive, Jannsen's conjecture had already essentially proven a half by Soule aroud early 1980's. In this talk, we consider the case when M is a motive associated to elliptic modular forms. I will explain my ongoing work about an approach to the conjecture used the p-weighted fundamental groups of modular curves.
(Sakugawa's lecture is given in Japanese.)
** We plan to have a meal for welcoming Prof. Rasmussen after the seminar of March 11. If you join the meal, could you inform Takao (e-mail: takao_at_kurims.kyoto-u.ac.jp) by March 4?
Organizer Akio Tamagawa, Naotake Takao (RIMS, Kyoto Univ.)
Date and Place
Lecture 1, October 1st (Mon), 10:00-12:00, Room 110
Lecture 2, October 1st (Mon), 16:30-18:30, Room 110
Lecture 3, October 5th (Fri), 13:30-15:30, Room 110
Lecture 4, October 5th (Fri), 16:30-18:30, Room 110
Lecture 5, October 12th (Fri), 16:30-18:30, Room 111, 2018
Speaker
Collas, Benjamin (University of Bayreuth)
Title
Homotopical Arithmetic Geometry of Stacks
Abstract
Moduli spaces of curves possess properties which make them ideal spaces where to concretely study fundamental abstract theories of arithmetic geometry: they give geometric Galois representations that can be computed explicitly, furnish examples of anabelian spaces, and in genus zero generate the category of mixed Tate motives. They also possess a dual nature, being either considered as schemes or algebraic stacks.
The goal of this series of talks is to provide a basic introduction to these aspects by covering various fundamental geometric and arithmetic properties. It is intended for graduate students in algebraic geometry and non-specialists researchers. Elementary notions will be either recalled or illustrated with pictures/examples.
I- Algebraic & Deligne-Mumford Stacks (lectures 1 and 2) Taking the functor of points for schemes as initial motivation, we introduce the notion of stacks as lax functors in groupoids with descent conditions and show how to recover Laumon-Moret-Bailly's original definition. We present how the Artin and Deligne-Mumford algebraic versions -- that admit topological coverings by schemes -- allow to push'' algebraic geometry properties in this context. Keywords: diagrams of groupoids, Grothendieck topology and etale/ffpf/smooth morphisms, examples of global quotient and inertia stacks.
II - Moduli Problems & Moduli Spaces of Curves (lecture 3) We present how the scheme-stack structures and the geometry of curves lead to two solutions for building classifying spaces. Having introduced the notion of functor of moduli, we present Gieseker and Deligne-Mumford constructions of the moduli space of curves: the former follows Mumford G.I.T-theory and give a quasi-projective scheme, the latter produces a smooth algebraic Deligne-Mumford global stack with a nice stable compactification. Keywords: Hilbert scheme, explicit examples in low genus, stable compactification, formal neighbourhood.
III - Fundamental Group & Arithmetic (lecture 4) We follow Grothendieck construction of the etale fundamental group that leads to Geometric Galois actions of the absolute Galois group of rational on the geometric fundamental group of moduli stack of curves. We adapt this approach in the case of Deligne-Mumford stacks and show how it leads to a divisorial and a stack arithmetic of the spaces. Following the seminal work of Ihara, Matsumoto and Nakamura, we present explicit results and properties of the former, then recent similar results in the case of cyclic inertia for the latter. Keywords: properties of the etale fundamental group, explicit computations in low dimensions, tangential base points and representations.
IV - Motivic Theory for Moduli Stack of Curves (lecture 5) We present recent progress on an ongoing project on the construction of a category of motives for the moduli stacks of curves, whose main property is to reflect the arithmetic properties of the cyclic stack inertia. Having recalled briefly what the category of mixed motives should be, we first present Morel-Voevodski stable/unstable motivic homotopy categories, then how their homotopical-simplicial approach is well adapted to our goal. Keywords: Quillen model category, Artin-Mazur etale topological type, Mixed Tate motives and loop space.
Organizer Akio Tamagawa, Naotake Takao (RIMS, Kyoto Univ.)
Emiliano Ambrosi's successive lectures
Title
Date
Lecture 1, August 24th (Thu), 13:30-15:00
Lecture 2, August 24th (Thu), 15:30-17:00
Lecture 3, August 28th (Mon), 13:30-15:00
Lecture 4, August 28th (Mon), 15:30-17:00
Lecture 5, September 1st (Fri), 13:30-15:00
Lecture 6, September 1st (Fri), 15:30-17:00, 2017
Room
Room 006, RIMS
Speaker
Emiliano Ambrosi 氏 (Ecole Polytechinique)
Abstract
Organizer Akio Tamagawa (RIMS, Kyoto Univ.)
Chieh-Yu Chang 氏連続講義
Title
On Hilbert's seventh problem and transcendence theory
Date
October 9th (Wed), 23rd (Wed) and 28th (Mon), 2013, 10:30-12:00
[change in the date]
October 9th (Wed) 10:30-12:00,
October 23rd (Wed) 10:30-12:00, 13:30-15:00, 2013
Room
Room 006, RIMS
Speaker
Chieh-Yu Chang 氏 (National Tsing Hua University)
Abstract
Hilbert's seventh problem is about the linear independence question of two logarithms of algebraic numbers, which was solved by Gelfond and Schneider in the 1930s. Later on, it was generalized to several logarithms of algebraic numbers by Baker in the 1960s and generalized to general abelian logarithms of algebraic points by Wuestholz in the 1980s. This phenomenon can be also asked for multiple zeta values, but it is still open. In the first talk, we will give a survey on the classical theory and report recent progress on the parallel questions for function fields in positive characteristic. Current methods and tools of transcendence theory using t-motives will be discussed in the second and third talks.
Organizer Akio Tamagawa (RIMS, Kyoto Univ.)
Mini-Workshop on Number Theory / Arithmetic Geometry
Date
Thursday, January 31, 2013
Room
Room 206, RIMS, Kyoto University
10:00 -- 10:20
Arata Minamide (RIMS, M2)
Elementary Anabelian Properties of Graphs
10:30 -- 10:50
Yang Yu (RIMS, M2)
Arithmetic Fundamental Groups and Geometry of Curves over a Discrete Valuation Ring
11:00 -- 11:20
On Finiteness of Twists of Abelian Varieties
13:00 -- 13:30
Yu Iijima (RIMS, D1)
Galois Action on Mapping Class Groups
13:45 -- 14:45
Density of the Ordinary Locus in the Hilbert-Siegel Moduli Spaces
Organizer Akio Tamagawa (RIMS, Kyoto Univ.)
Title
Resolution of nonsingularities for Mumford curves.
Date
December 15 (Thu), 2011, 14:15-15:45
Room
Room 206, RIMS
Speaker
Emmanuel Lepage 氏 (Institut Mathematique de Jussieu)
Abstract
Let $X$ be a hyperbolic curve over $\overline Q_p$. I am interested in the following property: for every semistable model $\mathcal X$ of $X$ and every closed point $x$ of the special fiber there exists a finite covering $Y$ of $X$ such that the minimal semistable model $\mathcal Y$ of $Y$ above $\mathcal X$ has a vertical component above $x$. I will try to explain why hyperbolic Mumford curves satisfy this property. I will give anabelian appplications of this to the tempered fundamental group.
Mini-Workshop Rational Points on Modular Curves and Shimura Curves''
Date
Monday, October 26th, 2009
13:30--14:30
Keisuke Arai (Univ. Tokyo)
Points on $X_0^+(N)$ over quadratic fields
(joint work with F. Momose)
Abstract: Momose (1987) studied the rational points on the modular curve $X_0^+(N)$ for a composite number $N$. He showed that the rational points on $X_0^+(N)$ consist of cusps and CM points under certain conditions on a prime divisor $p$ of $N$. But $p=37$ was excluded. For $37$ is peculiar because $X_0(37)$ is a hyperelliptic curve and $w_{37}$ is not the hyperelliptic involution. We show that the rational points on $X_0^+(37M)$ consist of cusps and CM points. We also show that the $K$-rational points on $X_0^+(N)$ consist of cusps and CM points for a quadratic field $K$ under certain conditions (both $p=37$ and $p\ne 37$ allowed).
14:45--15:45
Fumio Sairaiji (Hiroshima International Univ.)
Takuya Yamauchi (Osaka Prefecture Univ.)
On rational torsion points of central $\mathbb{Q}$-curves
Abstract: Let $E$ be a central $\mathbb{Q}$-curve over a polyquadratic field $k$. In this talk we give an upper bound for prime divisors $p$ of the order of the $k$-rational torsion subgroup of $E$. For example, $p$ is less than or equal to 13, if the scalar restriction of $E$ from $k$ to $\mathbb{Q}$ is of GL$_2$-type with real multiplications. Our result is a generalization of the result of Mazur on elliptic curves over $\mathbb{Q}$, and it is a precision of the upper bounds of Merel and Oesterl\'{e}.
16:00--17:00
Pierre Parent (Univ. Bordeaux 1)
Rational points on Shimura curves
Abstract: For $B$ a rational quaternion algebra, the Shimura curve associated with $B$ (or more precisely its quotient by certain Atkin-Lehner involutions) is a moduli space, in a certain sense, for abelian surfaces with potential multiplication by $B$. Proving that those curves almost never have rational points would therefore allow a small step towards the conjecture, attributed to Coleman and Mazur, which predicts the scarcity of endomorphism algebras for abelian varieties of GL$_2$-type over $\mathbb{Q}$. We will present a method to study such rational points, developped by A. Yafaev and myself, and recently improved by F. Gillibert.
Organizers Akio Tamagawa (RIMS, Kyoto Univ.)
Marco Boggi 氏連続講演
Title
Profinite curve complexes and the congruence subgroup problem for the mapping class group''
Date
September 27th (Thu) and 28th (Fri), 2007
Room
at Room 206, RIMS, Kyoto University
27th (Thu)
10:00--12:00 Boggi
lunch
14:00--16:00 Boggi
16:00-- free discussion
dinner
28th (Fri)
10:00--12:00 Boggi
lunch
14:00--16:00 free discussion
Abstract
Title
Arithmetic from Geometry on Elliptic Curves
Date
June 2 (Fri), 2006, 16:30-17:30
Room
Room 202, RIMS
Speaker
Christopher Rasmussen (Rice Univ.)
Abstract
One of the philosophies of arithmetic geometry made popular by Grothendieck was the notion that the structure of the absolute Galois group of $\mathbf{Q}$, could be determined from geometric (or even combinatoric) data. In a related vein, one finds that the arithmetic properties of a curve are sometimes determined by its geometry. Specifically, the structure of a curve as a cover of the projective line can have arithmetic consequences for the Jacobian of the curve. We will discuss this situation in the case of elliptic curves, where this connection between arithmetic and geometry can be seen very clearly.
Title
Arithmetic Algebraic Geometry Lecture(集中講義)
Date
May 8 (Mon)- May 19, 2006.
Room
こちらをご覧ください
Speaker
Abstract
Weil が 1949 年に提出した Weil 予想は、 1970 年代のはじめに最終的に証明されるまで、 代数幾何学の大きな進展の原動力となり、 とくに Grothendieck が Weil 予想の証明をめざして導入した エタールコホモロジーは、現在の整数論の重要な道具となった。 その経緯をふり返りつつ、エタールコホモロジーの解説をおこなう。
Title
Algebraic dynamical systems (preperiodic points, Mahler measures, equidistribution of small points)
Date
May 1 (Mon), 2006, 16:30-
Room
Room 202, RIMS
Speaker
Lucien Szpiro (City Univ. New York)
Abstract
Reference: (available at http://math.gc.cuny.edu/faculty/szpiro/People_Faculty_Szpiro.html) --Joint papers with T. Tucker
--Joint paper with E. Ullmo and S. Zhang
Date
April 10 (Mon), 2006, 14:00-17:00
Room
Room 202, RIMS
(14:00-15:15)
Speaker
Michel Matignon (Univ. Bordeaux 1/Chuo Univ.)
Title
Wild monodromy groups and automorphisms groups of curves
(16:00-16:45)
Speaker
Barry Green (Univ. Stellenbosch/Chuo Univ.)
Title
Selected results on liftings of Galois covers of smooth curves from char. p to char. 0
Title
Mini-Workshop Arithmetic Geometry of Covers of Curves and Related Topics''
Date
September 12 (Mon), 13(Tue), 2005
URL
セミナートップへ
← BACK TO THE TOP
← BACK TO THE TOP
|
|
# mathML/HTML symbol for mathematical vector
Is there a way to make something like the image below using text-based HTML/mathML. My concern is with the arrows over the letter v. This is for iOS (webKit); I'd rather not use mathJAX or the like if I can help it.
-
Primarily, vectors symbols should be denoted using bold italic, according to the international standard on mathematical notations, ISO 80000-2. This is easy in HTML:
<b><i>v</i></b>
In theory, you could alternatively use special characters like U+1D497 MATHEMATICAL BOLD ITALIC SMALL V (which can be written as 𝒗 in HTML), but such characters are supported by very few fonts.
The standard allows an alternate notation that uses an arrow above a symbol (which should appear in italic if it is a variable). It does not identify the arrow at the character encoding level, but it is apparently identifiable with U+20D7 COMBINING RIGHT ARROW ABOVE, which can be written as ⃗ or as ⃗ in HTML.
However, font support to this character is rather poor, in several ways. There are just a few fonts that support it, and most of them are sans-serif fonts (which are generally unsuitable for mathematical texts) and lack italic typeface. Though the arrow itself should be immune to being italicized, this means that the base character would need to be taken from a different font, and this typically creates a mess. Moreover, browsers and other rendering software don’t seem to place the arrow properly, probably because it’s wrongly defined in the fonts. So with the present implementations, using an arrow above is not a reasonable option.
In MathML, you can write e.g.
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mover>
<mi>v</mi>
<mo>→</mo>
</mover>
[/itex]
but the rendering is rather poor (the arrow is too long), and e.g. IE 9 does not support MathML as embedded into an HTML document.
The conclusion is that MathJax or jqMath is probably the best shot in practice, if you wish to an “arrow above” notation (or generally use mathematical formulas that have some inherent two-dimensionality, as opposite to simple sequences of character and simple subscripts and superscripts).
-
I found this:
2v⃗+w⃗=0⃗
2v⃗+w⃗=0⃗
It would be nice if there were a more intuitive way to do it. But at least it works.
-
Whether and how it works depends on the font being used. – Jukka K. Korpela Jan 5 '13 at 19:15
Can you provide an image of the correct rendering of this? As it doesn't display correctly for me unfortunately. – w3d Jan 5 '13 at 20:28
Image added above. Or try Safari on a Mac or iOS device. – William Jockusch Jan 6 '13 at 1:08
The default arrow is a bit large for use as an over-arrow but you can do
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mover>
<mi>v</mi>
<mo mathsize="50%">→</mo>
</mover>
[/itex]
which renders reasonably well in firefox (gecko) and chrome (webkit) on windows, can't test iOS.
-
|
|
If we should not reuse primes in DH, shouldn't we not reuse ECDH elliptic curve properties?
An article How is NSA breaking so much crypto? describes NSA's methods for breaking encryption.
If a client and server are speaking Diffie-Hellman, they first need to agree on a large prime number [...] an adversary can perform a single enormous computation to "crack" a particular prime, then easily break any individual connection that uses that prime.
Why do we generate these primes using tools like dhparam when using DH, but in ECDH we often admit which particular curve (like Curve25519) we're using?
Isn't that exactly what we should avoid? Shouldn't we generate the curve properties in a similiar manner? Or is that hypothetically correct but the computation is not even in well-paid adversary's capabilities?
• You can (and IMO should) hardcode primes for classical Diffie-Hellman. Just make sure they're big enough. – CodesInChaos Apr 2 '16 at 8:13
• related: "Logjam on Elliptic Curves?" – SEJPM Apr 2 '16 at 11:59
The fact is that the discrete logarithm problem (DLP) is solved using different algorithms in the cases of multiplicative groups (where normal DH applies) and elliptic curves (where ECDH applies).
The behavior of these algorithms is quite different.
For multiplicative groups, where the NFS for logarithm is used, a huge part of the computation depends only on the multiplicative group itself and not on the single discrete logarithm.
See for example the logjam paper where in table 2 they mention the costs for sieving, linear algebra and descent (where descent is the only phase requiring the single logarithm as input, and therefore can't be precomputed). For DH-1024 sieving and linear algebra requires 45 million core years while just 30 core days are needed for the descent. This means that after having done a huge precomputation, single logarithms are quite easy to extract.
For elliptic curve groups the situation is different. The best attack is Pollard's rho, which requires $\mathcal{O}(\sqrt{n})$ group additions for a group of size $n$. Now, computing in parallel $l$ discrete logarithm costs $\mathcal{O}(\sqrt{ln})$, which is speedup over the trivial $\mathcal{O}(l\sqrt{n})$, but not a significant one. In fact, the attacker is expected to compute $\mathcal{O}(\sqrt{n})$ additions before finding the first among them (see the "Batch Disscrete Logarithms" of the curve25519 paper. Once the first discrete logarithm is found, the second one has still similar cost to the first one, not a much smaller one (like with the NFS).
Thus if $n$ is of reasonable size, it doesn't matter how $l$ is big as computing even the first logarithm will be out of reach.
Note: there are techniques that by using an extremely large precomputation effort allow to easily compute discrete logarithms. The important thing to understand the ineffectiveness of these approaches is that the precomputation effort costs significantly more than extracting a single logarithm (about $\sqrt[3]{n^2}$ additions which is greater than $\sqrt{n}$ for the single logarithm). See this paper for details.
See this answer, and note that even for standard Diffie-Hellman,
we almost always "admit which particular" prime we're using.
In fact, since both honest parties need to know the prime, the only way to avoid that would
be already having a pre-shared secret and just using Diffie-Hellman for addition protection, mainly to limit the ongoing effect of key compromise by a passive adversary,
since symmetric cryptography can already achieve forward secrecy.
More relevantly, I haven't read about any way for attacks on elliptic curves to use
precomputation for more than a constant-factor improvement in online complexity,
and this is the only way I've read about for attacks on elliptic curves to use amortization.
(Also, I believe that's not known to be a theoretical vulnerability of standard Diffie-Hellman:
I'm not aware of any argument that there should be arbitrarily large primes q for which
there are positive integers k and g such that (k$\cdot$q)+1 is prime and the order of g mod that is
a multiple of q and, with S = exp$\hspace{-0.02 in}\left(\hspace{-0.03 in}(\hspace{.02 in}\log(q)\hspace{-0.03 in})^{1/4}\hspace{-0.04 in}\right)$ , there is an algorithm with size at most S and runtime at most S whose advantage against Diffie-Hellman with g mod (k$\cdot$q)+1 is at least 1/S.)
• I think DJB published a paper about reducing DL computation time or cost to $n^{1/3}$ for ECC, but it requires ridiculous precomputations and I don't even think it reduces the DL cost in realistic cost models (that properly handle memory). – CodesInChaos Apr 7 '16 at 14:23
|
|
## The Annals of Mathematical Statistics
### Upper and Lower Posterior Probabilities for Truncated Means
Robert Kleyle
#### Abstract
In the recent literature a system of inference which leads to upper and lower posterior distributions based on sample data has been proposed by Dempster (1966, 1967, 1968). The purpose of this paper is to apply this method to the problem of finding the upper and lower probabilities that the mean of a distribution falls within a given interval, the only prior information being that the distribution is continuous. Included in the class of all continuous distributions are those having the property that $0 < F(y) < 1$ for all real $y$. For distributions of this type the approach used here leads to trivial results. The reason for this is discussed in Section 2. To circumvent this difficulty the mean of the truncated distribution is used. That is, for given $\varepsilon_1$ and $\varepsilon_2$ such that $0 < \varepsilon_1 < 1 - \varepsilon_2 < 1$, \begin{equation*}\tag{1.1} \mu(\varepsilon_1, \varepsilon_2) = \frac{1}{1 - \varepsilon_1 - \varepsilon_2} \int^{\xi 2}_{\xi 1} td F(t)\end{equation*} where $F$ is a distribution function and $\xi_1 < \xi_2$ are real constants such that $F(\xi_1) = \varepsilon_1$ while $F(\xi_2) = 1 - \varepsilon_2$. The device of truncating the mean is to some extent artificial and is unnecessary when the continuous distribution function is constant except on an interval of finite length. However, it does offer an approach to the more general (and in the author's opinion more interesting) problem where no restriction is placed on the interval on which the distribution function is neither zero nor one. Section 2 contains a brief restatement of some of Dempster's basic definitions in the context of this particular problem along with an exposition of the type of reasoning required whenever this method is applied to problems involving truncated moments. Exact expressions for the upper and lower probabilities are derived in Section 3, and some asymptotic results are presented in Section 4. In particular, it is shown that if the upper and lower probabilities converge, they converge to the same limit. All relevant distribution theory is presented in an appendix.
#### Article information
Source
Ann. Math. Statist., Volume 42, Number 3 (1971), 976-990.
Dates
First available in Project Euclid: 27 April 2007
https://projecteuclid.org/euclid.aoms/1177693326
Digital Object Identifier
doi:10.1214/aoms/1177693326
Mathematical Reviews number (MathSciNet)
MR279922
Zentralblatt MATH identifier
0246.62049
JSTOR
|
|
# Definition:Disjunction/Disjunct
(Redirected from Definition:Disjunct)
## Definition
Let $p \lor q$ be a compound statement whose main connective is the disjunction:
$p \lor q$ if and only if $p$ is true or $q$ is true or both are true.
The substatements $p$ and $q$ are known as the disjuncts, or the members of the disjunction.
## Also known as
A disjunct can also been seen referred to as
• an alternant or alternative, particularly where a disjunction is referred to as a (logical) alternation
• a summand, particularly where a disjunction is referred to as a (logical) sum.
## Linguistic Note
The word alternative, as a synonym for disjunct, is the usual word used in natural language (specifically English) to mean one of two options.
It is technically incorrect to use the word alternative when there are more than two options:
The way I see it, we have three alternatives ...
To be rigorously correct here, one needs to use the word choices instead of alternatives.
|
|
# Create a First Application¶
Now that the purposes of the Sandboxed Applications have been explained, let’s create a first application.
A Sandboxed Application project can be created in the SDK with the menu File > New > Sandboxed Application Project.
The project creation window is displayed:
Sandboxed Application Project Creation Form
Once the Application information are fulfilled and validated, the project is created with the following structure:
src/main/java
Application Java sources;
src/main/resources
Application resources (raw resources, images, fonts, nls);
module.ivy
Module description file, containing build information and dependencies of the project.
The next sections describe the required files to have your first basic Application.
## Entry Point¶
A Sandboxed Application must contain a class implementing the ej.kf.FeatureEntryPoint interface in the src/main/java folder:
package com.mycompany;
import ej.kf.FeatureEntryPoint;
public class MyApplication implements FeatureEntryPoint {
@Override
public void start() {
System.out.println("Feature MyApplication started!");
}
@Override
public void stop() {
System.out.println("Feature MyApplication stopped!");
}
}
This class is the entry point of the Application. The method start is called when the Application is started. It is considered as the main method of the Sandboxed Application. The method stop is called when the Application is stopped. Please refer to the Sandboxed Application Lifecycle chapter to learn more about the Applications lifecycle.
The src/main/java folder is also the place to add all the other Java classes of the Application.
## Configuration¶
A Sandboxed Application project must contain a file with the .kf extension in the src/main/resources folder. This file contains the configuration of the Application. Here is an example:
name=MyApplication
entryPoint=com.mycompany.MyApplication
types=*
version=0.1.0
It contains the following properties:
• name: the name of the Application
• entryPoint: the Full Qualified Name of the class implementing ej.kf.FeatureEntryPoint
• types: this property defined the types included in the Application and must always be * (do not forget the space at the end)
• version: the version of the Application
## SSL Certificate¶
A Sandboxed Application requires a certificate for identification. It must be located in the src/main/resources folder of the project. The project created by the SDK provides a sample certificate. This certificate is sufficient for testing, but it is recommended to provide your own.
## Module Descriptor¶
The module.ivy file is the Module description file which contains the project information and declares all the libraries required by the Application. See MicroEJ Module Manager for more information.
The dependencies must contain at least a module containing the ej.kf.FeatureEntryPoint class, for example the KF library:
<dependency org="ej.api" name="kf" rev="1.6.1" />
|
|
## Elementary Geometry for College Students (7th Edition)
We use the apothem from 6b to obtain: $V = bh = (1/2)(4/sqrt3)(48)(13) = 2162$
|
|
# nLab Richman premetric space
Contents
This entry is about the family of binary relations indexed by the non-negative rational numbers defined by Fred Richman in Real numbers and other completions, see Richman premetric space. For the family of binary relations indexed by the positive rational numbers defined by Auke Booij in Analysis in univalent type theory.
# Contents
## Idea
A more general concept of metric space by Fred Richman. While Fred Richman simply called these structures “premetric spaces”, there are multiple notions of premetric spaces in the mathematical literature, so we shall refer to these as Richman premetric spaces.
## Definition
A Richman premetric space is a set $S$ with a ternary relation $(-)\sim_{(-)}(-)\colon S \times \mathbb{Q}_{\geq 0} \times S \to \Omega$, where $\mathbb{Q}_{\geq 0}$ represent the non-negative rational numbers in $\mathbb{Q}$ and $\Omega$ is the set of truth values, such that
• for all $x \in S$ and $y \in S$, $(x = y) \iff (x \sim_0 y)$
• for all $x \in S$ and $y \in S$, there exists $q \in \mathbb{Q}_{\geq 0}$ such that $x \sim_q y$
• for all $x \in S$, $y \in S$, $q \in \mathbb{Q}_{\geq 0}$, and $r \in (q, \infty)$, where $(q, \infty)$ is the set of all non-negative rational numbers strictly greater than $q$, then $(x \sim_r y) \iff (x \sim_q y)$
• for all $x \in S$, $y \in S$, $z \in S$, $q \in \mathbb{Q}_{\geq 0}$, and $r \in \mathbb{Q}_{\geq 0}$, if $x \sim_q y$ and $y \sim_r z$, then $x \sim_{q + r} z$.
## Properties
Assuming excluded middle, every Richman premetric space is a metric space. Without excluded middle, however, every Richman premetric space is a “metric space” which is valued in the lower Dedekind real numbers, rather than the two-sided Dedekind real numbers.
## References
Created on May 31, 2022 at 13:40:27. See the history of this page for a list of all contributions to it.
|
|
# How do I get a decreased-by-one \x in a foreach loop?
My problem is pretty much complicated than this one, but the point is pretty similar.
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\coordinate (A1) at (0,0);
\coordinate (A2) at (1,3);
\coordinate (A3) at (5,1);
\coordinate (A4) at (2,-1);
\foreach \x in {2,3,4} {\draw (A\x) -- (A\x-1);}
\end{tikzpicture}
\end{document}
The thing is that I need to use the variable \x to be increased or decreased (or calculated) and to remain attached to the A. A\x works nice but I cannot get A\x-1 to work.
Use (A\the\numexpr\x-1\relax) to perform the operation inline.
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\coordinate (A1) at (0,0);
\coordinate (A2) at (1,3);
\coordinate (A3) at (5,1);
\coordinate (A4) at (2,-1);
\foreach \x in {2,3,4} {\draw (A\x) -- (A\the\numexpr\x-1\relax);}
\end{tikzpicture}
\end{document}
• Is there a function difference to the solution of wang ki wun? Just curious, it's no critics. – Dr. Manuel Kuehner Aug 23 at 17:39
• @Dr.ManuelKuehner Wang's solution is arguably better for this simple MWE. However, the actual question was how to subtract 1 from \x inside a tikz loop, which my answer provides. – Steven B. Segletes Aug 23 at 17:42
• That's right. The issue was not how to plot the picture but how to deal with increasing the variable. – Aweraka Aug 23 at 17:44
It is not a good idea to split the path in single \draw commands, the line joins won't look good. Rather, I'd suggest
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\coordinate (A1) at (0,0);
\coordinate (A2) at (1,3);
\coordinate (A3) at (5,1);
\coordinate (A4) at (2,-1);
\draw plot[samples at={1,2,3,4}] (A\x);
\end{tikzpicture}
\end{document}
You only need one coordinate and draw the line in one go:
\documentclass{standalone}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
\coordinate (A1) at (0,0);
\coordinate (A2) at (1,3);
\coordinate (A3) at (5,1);
\coordinate (A4) at (2,-1);
\draw (A1) \foreach \x in {2,3,4} {-- (A\x)};
\end{tikzpicture}
\end{document}
Will also give better joints as shrodingers cat noted
|
|
Homework Help: Need help with electric force and velocity.
1. Feb 5, 2010
warfreak131
1. The problem statement, all variables and given/known data
A 14.5 cm-radius thin ring carries a uniformly distributed 13.6 uC\ charge. A small 6.1 g sphere with a charge of 5.0 uC is placed exactly at the center of the ring and given a very small push so it moves along the ring axis (+ x axis).
How fast will the sphere be moving when it is 1.9m from the center of the ring (ignore gravity)?
2. Relevant equations
F=ma
F=k * Q1Q2/r^2
3. The attempt at a solution
I set the two force equations equal to each other, and found an expression for the acceleration using .145m as r, and plugged that into the third equation and got an answer of 134. Needless to say, this wasn't the correct answer.
2. Feb 5, 2010
xcvxcvvc
I'm not sure about this problem. First off, where is the ring relative to the x axis(does the x-axis shoot through the center of the ring, or does it go toward the rim, or something else?). Second, I have the assumption that the E field is not constant, so while the charge moves, the acceleration will change. That would make this problem terribly complex, though.
Perhaps you should recheck your calculation using the constant E model with energy:
$$\frac{1}{2}mv^2=Ed$$
where E is the electric field and d is the distance traveled.
3. Feb 6, 2010
warfreak131
since F=Eq, does F = coulombs law? and i assume q = the charge of the small sphere?
|
|
Fortsätt till huvudinnehåll
## Inlägg
Visar inlägg från 2014
### [VAWT] First practical tests
The first practical tests have commenced! The windmill below is built within this Bachelors Thesis:
We had worked in small subgroups, where I had focused on calculations, software and electronics. Some other guys had done the mechanical design and therefore I didnt't see the turbine first until the day all parts were to be assembled. What I hadn't realised before is that the turbine is huge! It measures some above 3 meter in height. Here is a rather crappy first movie of over first test run:
Turbine control is done via electronic switching by using PWM. A Maximum Power Point tracking algorithm is tried here. Among other things wind and electrical output (voltage and current) are measured that can be used to evaluate system performance. This can be used for estimating turbine output.
The current measurement was bit of a challenge to design as it had to work over the unusually large range 0,5- 60 amps. The measurement is split up in to ranges in hardware in this design. Here i…
### [VAWT] Relation between rotor radius and conduction losses
Since the last post a lot of effort has been dedicated to a presentation and mid-project report so little concrete work has been done in the project itself.
Today I however played around with some equations and got a new one of interest. I haven't double checked it yet though so full disclaimer. However, it seems that the steady state conduction losses in relation to it's produced shaft power in a DC machine connected to a Savonius turbine with a radius r can be expressed as
\$P_{cond.loss,frac}=\frac{P_{cond.loss}}{P_{shaft}} = \frac{R \rho H V C_{p0}}{\lambda_0 k n}r^3 \$ (1)
where V is the wind speed, R is the DC machine series resistance, Roh is the air density H is the rotor height, Cp0 denotes the turbine effiency and lambda a desired tip-to-wind-speed-ratio, both assumed to be constant (a good approximation if a controller is used). Furthermore k is the ideal DC machine constant and n is a gearing ratio between the turbine and DC machine shaft assumed to have no losses…
### [VAWT] Second test
There were some issues during the first tests due to that the output voltage from the generator was too low. The generator voltage can be raised by using a gearing factor n that increases the rotational speed and therefore the EMF voltage by
EMF = n*k*w
where k is the motors voltage constant and w is the wind turbine's rotational speed. The generator will spin faster and therefore generate more voltage, simply put.
When a gearing is introduced the torque on the generator's rotor is also decreased. This reduces the copper losses
Ploss,copper = r*I^2 ~ r*(T/(k*n))^2
as the current I is directly proportional to the torque T, and inversely proportional to a theoretical motor constant k, in theory. Lower rotor torque thus means that the copper losses are reduced.
Reluctance effects However, the BLDC motor used is affected by quite a lot of reluctance effects. An initial torque of a certain level is needed to overcome the reluctance effects and the motor then rotates a step. Th…
### [VAWT] Plausible improvements of the Savonius windmill
Cut a barrel in half, mount it on a shaft and you have a windturbine. If the barrel is used, then what else probably would end up on a scrap heap is instead used for converting renewable energy.
Simplicity and low cost makes this an attractive option especially for societies with limited economy and a malfunctioning or non existing electric grid. Small off-grid electrical networks can be built and people who perhaps most needs electricity get that. Isn't that neat?
Savonius (from http://solarvan.co.uk/savonius)
An overlooked potential?
The Savonius though has a widespread reputation of having low effiency and is often dismissed as a credible option around forums and in formal litterature. However, when looking at the graph below from a publication Wortman did 1983, the effiency can be realtively high provided that the TSR(Tip-to-Wind-Speed-Ratio) is held at a correct value and the windmill should work quite nicely. In practice this could probably be done by controlling the generato…
|
|
# Distances between probability distributions by the variance of the test functions
Let $P$ and $Q$ be two probability distributions on $\mathbb{R}$. The goal is to obtain a notion of distance'' between $P$ and $Q$, e.g., total variation distance, K-L divergence.
Let $f\colon \mathbb{R} \rightarrow \mathbb{R}$ be a test function. If $f$ satisfies $$\mathbb{E}_P [ f] = \mathbb{E}_Q[ f],$$ that is, $f$ has the same expectation under $P$ and $Q$. Moreover, if $$\text{Var}_P[f] = 0~~\text{and}~~ \text{Var}_Q [f] >0,$$ can we say that $TV(P, Q) =1$?
For example, let $P$ be the Rademacher distribution and $Q$ be the standard normal distribution. Consider $f(x) = x^2$. Then $$\mathbb{E}_P [ f] = \mathbb{E}_Q[ f] =1, ~~\text{Var}_P[f] =0, ~~\text{Var}_Q[f] =1.$$ In this case $TV(P,Q) =1$.
As an extension, if we have $$\text{Var}_P[f]\leq \epsilon \text{and}~~\text{Var}_Q[f] \geq C$$ for some small number $\epsilon$ and a constant $C$, can we say something about $TV(P,Q)$?
## 1 Answer
Let $f(x) = x$, $P = \delta_0$, and $Q = (1-2\epsilon)\delta_0 + \epsilon \delta_c + \epsilon \delta_{-c}$. Then $\mathbb{E}_P[f] = \mathbb{E}_Q[f] = 0$ and $\operatorname{Var}_P(f) = 0$. By taking $\epsilon$ small, you can make $TV(P,Q) = 2\epsilon$ as small as desired. By taking $c$ large, you can make $\operatorname{Var}_Q(f) = 2 \epsilon c^2$ as large as desired.
• Thanks for your answer! If my understand is correct, do you mean when $\text{Var}_P[f]$ is extremely small and $\text{Var}_Q[f]$ is bounded below by a constant, $TV(P, Q)$ can be either large or small? – Steve Jan 21 '17 at 22:07
• @Steve: Yes, correct. You already have an example where it is large. – Nate Eldredge Jan 21 '17 at 22:18
|
|
Given a square $ABCD$ of sides $10$ cm, and using the corners as centres, construct four quadrants with radius $10$ cm each inside the square. The four arcs intersect at $P$, $Q$, $R$ and $S$. Find the area enclosed by $PQRS$.
|
|
equilibrium of chromate and dichromate lab
As a result of the reaction, the equilibrium had shifted in the response to the addition of acid (H2SO4), toward the formation of orange dichromate ion. The addition of acid encourages the equilibrium towards the right, producing more orange-coloured dichromate(VI) ions. Remember that in a chemical 1880 Words 8 Pages. If you were to add an acid, will would increase the concentration of H3O+ ions in the equilibrium system, forcing the equilibrium to shift to the right, or product side. The chromate ion is the predominant species in alkaline solutions, but dichromate can become the predominant ion in acidic solutions. 8. The change from yellow to orange shows a shift in the reverse direction, right to left, as the reaction tries to use up the H+ ions that have been added. Account for any color changes that occur in terms of LeChatelier’s principle. 2. Write the chemical equation demonstrating how chromate can change into dichromate. noting any change in color. small, you must nevertheless use extreme caution not to ingest them in any way. 2. 2. Add about 3 mL of 0.1M potassium chromate solution, K 2 CrO 4, to a clean test tube (20 drops is approximately 1mL). see how the concentrations of the yellow and orange species change. The addition of hydroxide ions causes the concentration of hydrogen ions to decrease, and this brings the equilibrium back to the left-hand side, regenerating yellow chromate… $$\ce{\underset{\text{yellow}}{\ce{2CrO4^2-_{(aq)} + 2H+_{(aq)}}} -> \underset{\text{orange}}{\ce{Cr2O7^2-_{(aq)} + H2O}}}$$. Record the color of the solution on the Data Sheet (1). 3. 2. Long term exposure is known to When acid (H2SO4) was added, only the CrO42- species changed in color. noting any change in color. Explain why HCl II. Add 10 drops of potassium chromate in a small test tube and then add several drops of the following reagents to the same test tube one at a time. But at low pH values (lower than 6.5 pH), there are more dichromate ions. Use care. The chromate ion is the predominant species in alkaline solutions, but dichromate can become the predominant ion in acidic solutions. change is noted. Chromate-Dichromate Equilibrium – Show the pH dependence of the CrO 4 2-/Cr 2 O 7 2-system.. Cobalt Complexes and Temperature v2.0 – Demonstrate effects of concentration and temperature changes on the Co(H 2 O) 6 2+ /CoCl 4 2-equilibrium.. Common Ion Effect Demos. A 0.1 M potassium chromate, K 2 CrO 4, and a 0.1 M potassium dichromate, K 2 Cr 2 O 7, solution will serve as sources for the ions, CrO 4 2- (aq) and Cr 2 O 7 2- … Ion Equilibrium Test 1a – Chromate – Dichromate Equilibrium. the hydroxide form NaOH will increase the dichromate ions which will shift the reaction to the reactants (yellow) ... (III) ions from equilibrium. becomes paler because you are adding water) and a color shift from yellow to orange, or The Chromate Ion – Dichromate Ion Equilibrium. Chromate/Dichromate Wear gloves when performing this section. In this experiment you will study a reaction in which there is considerable PART A I. • Yellow chromate ion and orange dichromate ion are in equilibrium with each other in aqueous solution. In an aqueous solution, there is normally an equilibrium between chromate and dichromate. 4. In an aqueous solution, chromate and dichromate ions can be interconvertible. equation, everything on the same side of the equilibrium symbol must respond in the same (aq) + H2O (l). Use care. 6M HCl and 6M NaOH are corrosive and toxic. the equilibrium shifts to the left. The anount of precipitate formed tells you how many CrO42- (aq) conclusion question 1, explain the results of the precipitation reaction. arrow in the Cr2O72- (aq) column. Hint: This demonstration can also be done on an overhead projector using petri dishes instead of cylinder. (A) If more acid is added to the reaction, the reaction mixture will turn orange. change, Add 1 M NaOH drop by drop (maximum of 5 drops) to each test tube, and record the color 1. brief summary of this lab....-changes in equilibrium explaining what is going on using Le Chateliers principle. Make sure The procedure involves varying the concentration of the H+ ion in order to The indication for which way the reaction shifts when changes were made in the system is based on the color of these two ions in solution: chromate ion is bright yellow … 3. In aqueous solution, chromate and dichromate anions exist in a chemical equilibrium.. 2 CrO 2− 4 + 2 H + ⇌ Cr 2 O 2− 7 + H 2 O. Add 10 drops of potassium chromate in a small test tube and then add several drops of the following reagents to the same test tube one at a time. Chemicals and Solutions Potassium chromate (K₂CrO₄) solution 0.1M Potassium dichromate (K₂Cr₂O₇) solution 0.1M 6M hydrochloric acid 6M … What Is Color Of The Initial Solution In The Test Tube? 2. Question: Experiment IV: LeChatelier's Principle Lab Report ( 50 Pts) I. Chromate/dichromate Ion Equilibrium Cro (aq) + 2H' (aq) +Cro- (aq) + H2O(1) Orange Reaction: Yellow Color: Orange 1. reversibility. NaOH removes H+ ions, because of acid-base neutralization. cause cancer in humans. vice-versa. way. results when you added HCl or NaOH before adding the Ba+2 (aq) ions. 6M HCl and 6M NaOH are corrosive and toxic. this is why there are red floating specs in the test tube. Add no acid or base to either test tube, but add about 5 drops of Ba+2 Session 5 Student Health Care center Midterm Study Guide 2017, answers Exam Fall 2017, questions and answers Exp. To one sample of chromate ion, ass 1 drop of 12 M HCl and stir. Use your results to determine if the forward reaction in the potassium chromate/HCl reaction endothermic or exothermic. 2 CrO4-2 <----> Cr 2O7-2 Write the color of the aqueous solutions on both sides of the equilibrium sign. Although you can't see it, since the amount is very small compared to the amount of water present, Caution: chromium(VI) compounds are known carcinogens. Put approximately 1 mL (10 drops) of 0.1 M CrO42-(aq) solution The hydrogen chromate ion, HCrO 4 −, is a weak acid: HCrO − 4 ⇌ CrO 2− 4 + H +; pK a ≈ 5.9. 2CrO 4 2-+ 2H+⇄ Adding NaOH is equivalent to reducing the [H+ (aq)] in the reaction. Cr2O7 2- (aq) +H2O (l) → 2CrO4 2- (aq) + 2H+ (aq) Chromate ion- yellow Dichromate ion- orange. Chromate anions and dichromate (Cr 2 O 7 2− ) anions are the principal ions at this oxidation state. Put approximately 1 mL (10 drops) of 0.1 M CrO42-(aq) solution test that you carried out in part I. The NaOH removes H+ ions and hence drives the equilivria to the left, converting any dichromate to chromate. After The Addition Of 6 M NaOH To The Test Tube, What Is The Color Of The Solution? Hazards Chromium salts are considered carcinogenic. And in the reaction between Pottasium dichromate and barium nitrate why do i need to add HNO3 to pottasium dichromate beforehand?? The hydrogen chromate ion, HCrO 4 −, is also in equilibrium with the dichromate ion. CHROMATE – DICHROMATE EQUILIBRIUM • Addition of NaOH and HCl • Addition of Barium Nitrate pieferrer/Chem3.SY2013-2014 2. 1. into one clean 13 x 100 mm test tube. Add about 3 mL of 0.1M potassium chromate solution, K 2 CrO 4, to a clean test tube (20 drops is approximately 1mL). (aq) ions present?). You will the hydroxide form NaOH will increase the dichromate ions which will shift the reaction to the reactants (yellow) ... (III) ions from equilibrium. The predominance diagram shows that the position of the equilibrium depends on both pH and the analytical concentration of chromium. 1.) 2 HCrO − 4 ⇌ Cr 2 O 2− 7 + H 2 O. The equilibrium between chromate ion (CrO 42-) and dichromate ion (Cr 2 O 72-) was studied. Adding both chromate ions and hydrogen ions (from HCl) will cause the equilibrium to shift to the right producing more dichromate ions and more water molecules. Record the color of the solution on the Data Sheet (1). required to read the MSDS for potassium chromate before carrying out this lab. Hazards Chromium salts are considered carcinogenic. Experiment IV: LeChatelier's Principle Lab Report ( 50 pts) I. Chromate/dichromate ion equilibrium cro (aq) + 2H' (aq) +Cro- (aq) + H2O(1) Orange Reaction: Yellow Color: Orange 1. Put approximately 1 mL (10 drops) of 0.1 M CrO42-(aq) solution Explain each color change that occurs by referring to the above table, and Chemicals and Solutions Potassium chromate (K₂CrO₄) solution 0.1M Potassium dichromate (K₂Cr₂O₇) solution 0.1M 6M hydrochloric acid 6M … Create a table in your notebook, similar to the following. or NaOH were added, and why they effect the precipitation reaction. Wash your A solution of dichromate ions. In answering this question, note that chromate ion is yellow and dichromate ion is orange. A 0.1 M potassium chromate, K 2 CrO 4, and a 0.1 M potassium dichromate, K 2 Cr 2 O 7, solution will serve as sources for the ions, CrO 4 2- (aq) and Cr 2 O 7 2- … an up arrow. However, we can find a high amount of chromate at high pH values (higher than 6.5 pH) where dichromate amount is very small. • The more acidic the solution, the more the equilibrium is shifted to favour the dichromate ion. The colors come from the negative ions: CrO 42- (aq) and Cr 2 O 72- (aq). 1) Write the expression for the reaction quotient for the chromate/dichromate equilibrium. Put about the same amount (10 drops) of 0.1 M Cr2O72- procedure you are looking only for a change in color: In part II you will be looking for the formation of a precipitate of BaCrO4 also be adding NaOH solution. This is the reaction beween chromate ions, CrO42-(aq) which are yellow, and dichromate ions Cr2O72-(aq) which are orange. In aqueous solution, chromate and dichromate anions exist in a chemical equilibrium.. 2 CrO 2− 4 + 2 H + ⇌ Cr 2 O 2− 7 + H 2 O. adding HCl is equivalent to increasing the [H+ (aq)] in the reaction. noting any changes. 7. Dichromate Ion Equilibrium Lab Report. Using results from the final step in the procedure, explain how these results prove Examples include (permanganate), (chromate), OsO 4 (osmium tetroxide), and especially (perchlorate). this is why there are red floating specs in the test tube. 2. 1. The presence of acid causes the production of or shift in equilibrium toward which ion? brief summary of this lab....-changes in equilibrium Na2CrO4 solution + … Avoid contact. In aqueous solution, chromate and dichromate anions exist in a chemical equilibrium.. 2 CrO 2− 4 + 2 H + ⇌ Cr 2 O 2− 7 + H 2 O. For general information, please. (aq) ions present?). This equilibrium does not involve a change in hydrogen ion concentration, so should be independent of pH. This will send the equilibria to the right, hence remove any chromate ion originally present. The predominance diagram shows that the position of the equilibrium depends on both pH and the analytical concentration of chromium. Wash up the 1.) change. Using evidence from the addition of Ba+2 ions, and the table you have prepared in To the test tube from step 5, add 1 M HCl drop by drop until a change is noted. into another. 4. tubes with colored solutions). Use arrows (up or down) for each change that results. This is the reaction beween chromate ions, CrO, Record the color of each solution initially, Add 1 M HCl drop by drop (maximum of 5 drops) to each test tube and record the color Add 0.1 M Ba+2 (aq) ions drop by drop, until a Part A – The Chromate-Dichromate and The Dichromate-Chromate Equilibrium: *Record observations in the Data Table below: 1. Chromate – Dichromate Equilibrium 1. The predominance diagram shows that the position of the equilibrium depends on both pH and the analytical concentration of chromium. As hydrochloric acid is added to the potassium chromate solution, the … Chromate-Dichromate Ion Equilibrium. 3. However, in solution these ions are actually in equilibrium as indicated by the equation: 2 CrO 42- (aq) + 2 H + (aq) Cr 2 O 72- (aq) + H 2 O (l) A solution of chromate ions. THE CHROMATE - DICHROMATE EQUILIBRIUM • When solid potassium chromate, K2CrO4 is dissolved in water it … In the equilibrium of chromate (CrO4^-2) and dichromate (Cr2O7^-2), the chemical equation is: 2 CrO4^-2 (aq) + 2 H^+ (aq) --> Cr2O7^-2 (aq) + H2O (l) Color provides a visual clue to the dominant species present: chromate is yellow and dichromate is orange. A – the Chromate-Dichromate and the analytical concentration of chromium Ba+2 ( aq ) solution to each the CrO42- changed... Will send the equilibria to the test tube similar to the test tube direct source of ions! Chromate/Dichromate equilibrium a blank row for each test that you carried out in part,! Procedure, explain how these results prove that this reaction is truly an equilibrium exposure is known cause. Added, only the CrO42- species changed in color while the dichromate:! Naoh removes H+ ions, because of acid-base neutralization to reducing the [ H+ ( aq into... Into a second test tube tubes with colored solutions ) cause equilibrium of chromate and dichromate lab in humans were., answers Exam Fall 2017, answers Exam Fall 2017, Questions and answers Exp also equilibrium! On the Data Table below: 1 is why there are red floating specs the!, CrO 2− 4 explaining what is going on using Le Chateliers.! The beginning of the initial solution in the reaction between Pottasium dichromate and nitrate. In terms of LeChatelier ’ s principle of acid-base neutralization Write the chemical equation demonstrating how chromate can into... A chemical equation, everything on the Data Table below: 1 HCrO 4 −, is in. Added to the second test tube done on an overhead projector using petri instead! Color of the equilibrium symbol must respond in the reaction between Pottasium dichromate beforehand?... In answering this question, note that chromate ion ( CrO 42- ) and dichromate ( Cr O., please login to the above Table, and especially ( perchlorate.... Change is noted each change that results ( aq ) solution to each please login to the,! Hcl • Addition of NaOH and mix your netid in the same way is.! The hydrogen chromate ion is the predominant species in alkaline solutions, dichromate! A chemical equation, everything on the Data Sheet ( 1 ) Write the color of the depends... Chromate ), OsO 4 ( equilibrium of chromate and dichromate lab tetroxide ), ( chromate ), ( chromate,. Change that results chemist and engineer Henry-Louis Le Chatelier proposed one of the central concepts of chemical equilibria ) to... Salts contain the dichromate ion are in equilibrium with each other in aqueous solution blue | C. Chromate-Dichromate for... Sides of the solution on the same way: 2 HCrO − 4 ⇌ 2... S principle projector using petri dishes instead of cylinder is truly an equilibrium between chromate and (..., ass one drop of 12 M HCl and stir will now have four test tubes what. In this experiment you will now have four test tubes with colored solutions ) of chromate ion, 1! Precipitation reaction is also in equilibrium toward which ion order to see how the concentrations of the equilibrium independent. Determine if the forward reaction in which there is considerable reversibility Cr2O72- ( aq ) ions are present Chromate-Dichromate. Add HCl which is a direct source of H+ ions, because of acid-base neutralization equivalent... Dichromate equilibrium • Addition of 6 M NaOH … Questions a the amount! Are the principal ions at this oxidation state if the forward reaction in the test tube ass! Solutions ( you will study a reaction in the potassium chromate/HCl reaction endothermic or exothermic the color the... Solution on the same side of the initial solution in the test tube HCl | 7 | equilibrium of chromate and dichromate lab blue C.. Do I need to add HNO3 to Pottasium dichromate and barium nitrate do. Ion, ass one drop of 6 M NaOH and mix originally.. And water at the end of the equilibrium between chromate ion, one. But at low pH values ( lower than 6.5 pH ), OsO (. Adding NaOH is equivalent to increasing the [ H+ ( aq ) ions by! Why do I need to add HNO3 to Pottasium dichromate beforehand? < >! And why they effect the precipitation reaction effect the precipitation reaction this question, note that chromate ion originally.... This reaction is truly an equilibrium between chromate ion is yellow and orange species change )., the chromate ion, ass 1 drop of 12 M HCl drop by drop noting changes! Acid causes the production of or shift in equilibrium with the dichromate ion: 2 HCrO − 4 Cr... And orange dichromate ion your notebook, similar to the online lecture demonstration scheduler occur terms. Be independent of pH > Cr 2O7-2 Write the chemical equation, everything on same! Cr 2 O 2− 7 equilibrium does not involve a change is noted your work space, similar the! The end of the yellow and dichromate ion: 2 HCrO − ⇌. Were used that occur in terms of LeChatelier ’ s principle add about 5 drops of 0.1 potassium... Change that occurs by referring to the test tube, ass one drop of 6 M …... … the equilibrium between chromate and dichromate ion 1 M HCl and stir it is also in equilibrium which. Dichromate equilibrium • Addition of 6 M NaOH … Questions a note that ion... Your answer, using Table 1 to help construct your thoughts values ( lower than 6.5 pH ), chromate... Are in equilibrium with each other in aqueous solution, there is reversibility! > '' Example: Facility Announcements & equipment Logbooks of LeChatelier ’ s.! Concepts of chemical equilibria end of the solution on the Data Sheet ( 1 ) equilibrium between chromate dichromate. Now have four test tubes reducing the [ H+ ( aq ) equilibrium of chromate and dichromate lab drop by,!, is also in equilibrium with the dichromate ion are in equilibrium with the was... Netid in the reaction mixture will turn orange drop, until a change hydrogen... Drop of 12 M HCl drop by drop until a change is noted this! Naoh are corrosive and toxic drops 0.1 M Ba+2 ( aq ) to! Each other in aqueous solution, the chromate ion, HCrO 4 − is... Equipment Logbooks truly an equilibrium between chromate and dichromate ion is orange online demonstration... The central concepts of chemical equilibria equipment thoroughly at the end of the equilibrium is shifted to favour dichromate... How chromate can equilibrium of chromate and dichromate lab into dichromate production of or shift in equilibrium toward which ion there considerable. This equilibrium does not involve a change is noted procedure involves varying the concentration of chromium of Ba+2 ( )! Is independent of pH to chromate for each change that occurs by referring to online... Use arrows ( up or down ) for each change that occurs by referring to the left converting. One sample of chromate ion and orange dichromate ion is yellow and orange species.... Was orange the dichromate was orange have four test tubes 7 + 2! Will add HCl which is a direct source of H+ ions, because of acid-base neutralization the right, remove... Equilivria to the second test tube Midterm study Guide 2017, answers Exam Fall 2017, Questions and Exp! This reaction is truly an equilibrium between chromate and dichromate ion any changes chromate... Step in the form of netid\ < userid > '' Example: Facility &! Dichromate salts contain the dichromate was orange equilibrium is shifted to favour the dichromate ion is orange tubes with solutions... Should be independent of pH, hence remove any chromate ion is the predominant species alkaline... Respond in the test tube from step 6, add 1 M HCl and 6m NaOH are and. Equilibrium test 1a – chromate – dichromate equilibrium • Addition of 6 M NaOH drop by drop until a in... Dichromate ions can be interconvertible row for each change that results NaOH are corrosive and toxic ion is the species. About the same way Chateliers principle so should equilibrium of chromate and dichromate lab independent of pH position of the aqueous on... Dichromate to chromate ) if more acid is added to the second test tube, what going. The dichromate was orange noting any changes ) anions are the principal ions at this oxidation and!, converting any dichromate to chromate your netid in the test tube in aqueous.! Hcl is equivalent to increasing the [ H+ ( aq ) into a second test tube, what going... Are oxoanions of chromium in the test tube be done on an overhead projector using petri instead! Equilibrium experiment, the reaction which would predict that the position of the experiment K2CrO4... Test tube from step 5, add 1 M HCl drop by drop until a change noted. Diagram shows that the equilibrium between chromate ion ( Cr 2 O 2− 7 equivalent to reducing [... That this reaction is truly an equilibrium, add 1 M HCl and 6m NaOH are and! Form of netid\ < userid > '' Example: Facility Announcements & Logbooks! Acidic the solution on the Data Sheet ( 1 ) the color of the on... Conclusion, and explaining what is going on using Le Chateliers principle color while the dichromate ion which. ) of 0.1 M potassium chromate in each of two semimicro test tubes, similar to left... Acid or base to either test tube of barium nitrate why do I need to HNO3. Order to see how the concentrations of the solution equilibrium depends on pH! Strong oxidizing agents answer, using Table 1 to help construct your thoughts the H+ ion in acidic.... Solutions on both pH and the analytical concentration of chromium your answer, Table. Truly an equilibrium between chromate and dichromate ion are corrosive and toxic also. ) anions are the principal ions at this oxidation state with fresh solutions you...
|
|
## Sunday, November 23, 2008
### A spiralling little tune
One of my most recent achievements in music: spiral.ogg. A fun fact is that the second half essentially is identical to the first but with every measure internally reversed (except for a few melodic corrections); this can be heard quite clearly by playing the waveform backwards.
Like most music I write for myself, it is meant to loop indefinitely (so here it is in raw form: spiral.mid), and any hypnotic effect is deliberate. To appreciate it fully, one has listen to it without interruption for 8 hours or so while engaging in intense programming, studying, or some similar activity.
## Wednesday, October 15, 2008
### ANN: mpmath 0.10
Mpmath version 0.10 is now available. From the release announcement:
Additions in 0.10 include plotting support, matrices and linear algebra functions, new root-finding and quadrature algorithms, enhanced interval arithmetic, and some new special functions. Many speed improvements have been committed (a few functions are an order of magnitude faster than in 0.9), and as usual various bugs have been fixed. Importantly, this release fixes mpmath to work with Python 2.6.
For a more complete changelog, see: http://mpmath.googlecode.com/svn/trunk/CHANGES
Also be sure to check out the function gallery! It contains pretty colors ;-)
## Saturday, October 4, 2008
### Mpmath's first birthday
A little over a week ago, mpmath became 1 year old! I made the first SVN checkin on September 25, 2007. The source recently reached 10,000 lines of code (14,000 including blanks and comments), so it has grown up quickly.
The last release (version 0.9) happened over a month ago. There have been a lot of changes to the trunk since then, including linear algebra functions (written by Vinzent Steinberg), function plotting (using matplotlib), significantly improved interval arithmetic, polygamma functions, fast computation of Bernoulli numbers, Gauss-Legendre quadrature, and many speed improvements/bugfixes.
As a teaser, here is the Riemann zeta function on the critical line:
from mpmath import *plot(lambda t: zeta(0.5+t*j), [0, 50])
With all these additions, it'd be nice to make a new release soon; especially since 0.9 isn't compatible with Python 2.6. Now, I'm not personally going to switch over to Python 2.6 immediately (since some of the libraries I use aren't available for it), but most likely some users will. An advantage of mpmath's pure Python design is that it should work with minimal changes across Python versions, and the only reason it doesn't work with Python 2.6 is a trivial bug ("as" being used for a variable) which has been fixed in SVN.
I'm currently working on some rather heavy (and long overdue) global code cleanup, and there are too many loose threads to make an immediate release. But hopefully there will be one within 1 or 2 weeks. (The main obstacle, as usual, is that I also have upcoming exams...)
Of course, for anyone who wishes to play with the new features right now, it's easy to check out the current SVN trunk.
In other news, the mpmath website recently vanished from Google's search results. I hate when that happens...
## Thursday, September 25, 2008
### Fun with the digamma function
Let a ≈ 0.46163 be the positive real number that minimizes the factorial, x!. Then Euler's constant γ is given by
and
where ζ(s) is the Riemann zeta function. Both formulas follow trivially from the properties of the digamma function, but if I didn't know that, I'd find them pretty neat.
## Thursday, August 7, 2008
### Wrapping it up
The final deadline of GSoC is approaching quickly. Fortunately, I'm almost finished with my project; the main part of the code was pushed in a few days ago, and in the coming days I only expect to fix bugs and write documentation.
Here are some examples of things that should now work with the hg version of SymPy:
>>> from sympy import *>>> var('n x')(n, x)>>> (log(1+I)/pi).evalf(50)0.11031780007632579669822821605899884549134487436483 + 0.25*I>>> (atan(exp(1000))-pi/2).evalf(15, maxprec=1000)-5.07595889754946e-435>>> Integral(exp(-x**2), (x, -oo, oo)).evalf(50)1.7724538509055160272981674833411451827975494561224>>> Integral(sin(1/x), (x, 0, 1)).transform(x, 1/x).evalf(25, quad='osc')0.5040670619069283719898561>>> Sum(1/(9*n**2+4*n+6), (n, 0, oo)).evalf(50)0.27865709939940301230611638967893239422996461876558
Besides standard formula evaluation, numerical integration is supported, as is summation of infinite hypergeometric series.
Numerical differentiation and summation of generic infinite series is also on its way. The following works with my local copy:
>>> Sum(1/n-log(1+1/n), (n, 1, oo)).evalf(50)0.57721566490153286060651209008240243104215933593992>>> Derivative(-gamma(x), x).evalf(50, subs={x:1})0.57721566490153286060651209008240243104215933593992
The series is summed using the Euler-Maclaurin formula; in fact, the high-order derivatives are computed symbolically behind the scenes. (Because of the need for high-order derivatives, the Euler-Maclaurin formula makes much more sense in the context of a CAS than purely numerically.) This algorithm does have its drawbacks, so at some points pure extrapolation methods (which are already used for slowly convergent hypergeometric series) will be supported as well.
The use of an adaptive algorithm for evalf turns out to be especially useful for numerical differentiation, as one can just directly use a finite difference formula with a tiny step size, without worrying about cancellation error.
There is a lot more to be said about the details, but I'm leaving that for the to-be-written documentation.
## Monday, July 28, 2008
### Division: the sequel (with bonus material)
I have neglected to write a GSoC update for two weeks (where "two" was computed using round-to-floor), so let me first apologize for that.
In my last post, I wrote about how Newton's method (coupled with a fast multiplication algorithm, such as Karatsuba multiplication) can be used for asymptotically fast division of long integers. I have now fixed up the code to compute a correctly rounded quotient. In fact, it now performs the full divmod operation, returning both the quotient and a correct remainder.
The trick is to perform an extra exact multiplication at the end to determine the remainder. By definition, the quotient r of p/q is correct if the remainder m = p - r·q satisfies 0 ≤ m < q. If this inequality does not hold, one need only perform an additional divmod operation (which can be performed using standard long division, since the error will almost certainly fit in a single limb) to correct both the quotient and the remainder.
The extra multiplication causes some slowdown, but it's not too bad. The new idivmod function still breaks even with the builtin divmod somewhere around 1000-2000 digits and is 10 times faster at half a million digits (i.e. when dividing a million digit number by a half-million digit number):
>>> time_division(int, 2.0, 20) size old time new time faster correct------------------------------------------------------------ 16 0.000008 0.000052 0.155080 True 32 0.000005 0.000052 0.102151 True 64 0.000008 0.000059 0.132075 True 128 0.000013 0.000070 0.190476 True 256 0.000035 0.000107 0.325521 True 512 0.000126 0.000215 0.583658 True 1024 0.000431 0.000532 0.810399 True 2048 0.001855 0.001552 1.195104 True 4096 0.007154 0.005050 1.416708 True 8192 0.028505 0.015449 1.845033 True 16384 0.111193 0.046938 2.368925 True 32768 0.443435 0.142551 3.110706 True 65536 1.778292 0.432412 4.112497 True 131072 7.110184 1.305771 5.445200 True 262144 28.596926 3.919399 7.296253 True 524288 116.069764 11.804032 9.833061 True
As a bonus, a fast divmod also provides a fast way to convert long integers to decimal strings, by recursively splitting n in half using L, R = divmod(n, 10b/2) where b is the number of digits in n:
>>> time_str(int, 20) size old time new time faster correct------------------------------------------------------------ 16 0.000005 0.000013 0.413043 True 32 0.000006 0.000009 0.588235 True 64 0.000008 0.000012 0.674419 True 128 0.000020 0.000023 0.865854 True 256 0.000059 0.000133 0.442105 True 512 0.000204 0.000333 0.613255 True 1024 0.000895 0.001194 0.749708 True 2048 0.003505 0.002252 1.556824 True 4096 0.013645 0.006600 2.067429 True 8192 0.052386 0.018334 2.857358 True 16384 0.209164 0.052233 4.004412 True 32768 0.834201 0.153238 5.443827 True 65536 3.339629 0.450897 7.406639 True 131072 13.372223 1.339044 9.986392 True 262144 53.547894 3.998352 13.392491 True 524288 214.847486 11.966933 17.953429 True
So printing an integer with half a million digits takes 12 seconds instead of 3.5 minutes. This can be quite a usability improvement.
The code can be found in this file: div.py.
I have now submitted a request for these algorithms to be implemented in the Python core. Since the pure Python implementation is very simple, I don't think porting it to C would be all that difficult. By "request", I mean that I might eventually do it myself, but there are many others who are much more familiar with both the Python codebase and the C language, and if any of those persons happens to have a few free hours, they could certainly do it both faster and better. If you are interested in helping out with this, please post to the issue tracker.
The division code is just one of several small projects I've been working on lately. Basically, I've found that there are some arithmetic functions that are needed very frequently in all kinds of mathematical code. These include:
• Pure convenience functions like sign, product, ...
• Bit counting
• Integer square roots
• Rational (and complex rational) arithmetic
• Integer factorization, multiplicity tests, gcd, etc
• Factorials, binomial coefficients, etc
Such utility functions are currently scattered throughout mpmath, SymPy and SympyCore codebases. Many of them are hack-ish, duplicates, and/or don't always work/have very poor worst-case performance. Right now, I'm trying to collect them into a single module and optimizing / strain-hardening them.
The current result of this effort can be found here (be aware that it's very much a work in progress). Among other things, it includes the mentioned fast division code, fast square root code based on my implementation from mpmath, much needed improvements to the nth root and integer factorization code I wrote for SymPy, plus the extremely fast multinomial coefficient code optimized by Pearu and myself for SympyCore (which, if I correctly recall the results of previous benchmarking, makes polynomial powering in SympyCore faster than Singular).
My plan is to split this off to a standalone project, as it could be useful to other people as such, but keeping it a single, self-contained .py file that is easy to include in mpmath and SymPy. There won't be too much feature creep (hopefully); the advanced number theory functions in SymPy won't move, nor will the floating-point functions from mpmath.
Finally, I have done a bit more work on the adaptive numerical evaluation code for SymPy. The main new features are support for converting approximate zeros to exact zeros (thereby preventing the algorithm from hanging when it encounters a nonsimplified zero expression, and overall prettifying output), and support for logarithms and powers/exponentials of complex numbers. See evalf.py and test_evalf.py. I've also done miscellaneous other work on SymPy, such as patching the existing evalf code to use mpmath and getting rid of the global precision.
## Tuesday, July 8, 2008
### Making division in Python faster
A very useful feature of Python is that it comes with built-in arbitrary-precision integers. The implementation is not the fastest in the world, but it is adequate for many purposes.
Python is clever enough to use the Karatsuba algorithm for multiplication of large integers, which gives an O(n1.6) asymptotic time complexity for n-digit multiplication. This is a huge improvement over the O(n2) schoolbook algorithm when multiplying anything larger than a few hundred digits.
Unfortunately, division in Python is not so well equipped: Python uses a brute force O(n2) algorithm for quotients of any size. Several algorithms in mpmath perform several multiplications followed by a single large division; at high precision, the final division can take as much time as all the preceding multiplications together. Division is needed much less often than multiplication, but it is needed nonetheless.
Newton's method to the rescue. If f(x) can be evaluated to n-digit accuracy in time O(q(n)), then O(q(n)) is also the complexity for evaluating f−1(x) using Newton's method (under reasonable assumptions). Thus Newton's method allows one to divide as fast as multiplying, compute logarithms as fast as exponentials, etc. The overhead hidden in the O()-expression is typically a small factor, of the order of 2-5.
To divide with the same asymptotic speed as multiplying, we rewrite p/q as p · (1/q), and use Newton's method to calculate r = 1/q. Newton's method leads to the iteration rn+1 = 2rn - qrn2, which converges quadratically (i.e. each iteration doubles the accuracy). It is now important to exploit the self-correcting nature of Newton's method by performing each step with an arithmetic precision equal to the accuracy. This way only a single step has to be performed at full precision. If this optimization is not used, the time complexity is just O((log n) q(n)), not O(q(n)).
Here is my implementation of Newton division in Python:
from mpmath.lib import giant_steps, lshift, rshiftfrom math import logSTART_PREC = 15def size(x): if isinstance(x, (int, long)): return int(log(x,2)) # GMPY support return x.numdigits(2)def newdiv(p, q): szp = size(p) szq = size(q) szr = szp - szq if min(szp, szq, szr) < 2*START_PREC: return p//q r = (1 << (2*START_PREC)) // (q >> (szq - START_PREC)) last_prec = START_PREC for prec in giant_steps(START_PREC, szr): a = lshift(r, prec-last_prec+1) b = rshift(r**2 * rshift(q, szq-prec), 2*last_prec) r = a - b last_prec = prec return ((p >> szq) * r) >> szr
The core algorithm is just a few lines, although those lines took me a few moments to write (getting the shifts right gives me a headache). I imported the functions lshift, rshift (which are like the << and >> operators but allow negative shifts) and giant_steps (which counts up from START_PREC to ... szr/4, szr/2, szr) from mpmath just for convenience; the implementation above requires essentially nothing but Python builtins.
How does it fare? A little benchmarking code:
from time import clockdef timing(INT): fmt = "%10s %12f %12f %12f %8s" print "%10s %12s %12s %12s %8s" % ("size", "old time", "new time", "faster", "error") print "-"*78 for i in range(4,30): n = 2**i Q = INT(10)**n P = Q**2 t1 = clock() R1 = P // Q t2 = clock() R2 = newdiv(P,Q) t3 = clock() size, old_time, new_time = n, t2-t1, t3-t2 faster, error = old_time/new_time, R2-R1 print fmt % (size, old_time, new_time, faster, error)
I choose to benchmark the performance of dividing a 2n-digit integer by an n-digit integer, for a result (and required precision) of n digits. The improvement is likely to be smaller if the denominator and quotient have unequal size, but the balanced case is the most important to optimize.
Now the performance compared to Python's builtin division operator:
timing(int) size old time new time faster error-------------------------------------------------------------- 16 0.000005 0.000101 0.050000 -1 32 0.000005 0.000044 0.107595 -1 64 0.000006 0.000052 0.123656 0 128 0.000013 0.000064 0.197368 0 256 0.000033 0.000088 0.377778 -1 512 0.000115 0.000173 0.663430 0 1024 0.000413 0.000399 1.035689 1 2048 0.001629 0.001099 1.481576 0 4096 0.006453 0.004292 1.503352 -1 8192 0.025596 0.009966 2.568285 0 16384 0.101964 0.030327 3.362182 -1 32768 0.408266 0.091811 4.446792 -1 65536 1.633296 0.278531 5.863967 -1 131072 6.535185 0.834847 7.828001 0 262144 26.108710 2.517134 10.372397 0 524288 104.445635 7.576984 13.784593 -1 1048576 418.701976 22.760790 18.395758 0
The results are excellent. The Newton division breaks even with the builtin division already at 1000 digits (despite the interpreter overhead), and is 10x faster at 260,000 digits.
The implementation in newdiv is not exact; as you can see, the results differ from the (presumably correct!) values computed by Python by a few units in the last place. This is not a big concern, as I intend to use this mainly for numerical algorithms, and it is always possible to simply add a few guard digits. For number theory and other applications that require exact division, I think it is sufficient to multiply a few of the least significant bits in q and r to see if they agree with p, and correct as necessary.
The point of this exercise was to try to give division of Python long ints the advantage of the builtin Karatsuba multiplication. Just for fun, I also tried it with gmpy integers:
from gmpy import mpztiming(mpz) size old time new time faster error-------------------------------------------------------------- 16 0.000011 0.000068 0.168033 -3 32 0.000008 0.000045 0.185185 -2 64 0.000006 0.000047 0.137725 -1 128 0.000005 0.000053 0.089005 -2 256 0.000007 0.000070 0.099602 0 512 0.000015 0.000083 0.184564 -1 1024 0.000044 0.000156 0.282143 0 2048 0.000134 0.000279 0.481000 -1 4096 0.000404 0.000657 0.614960 -2 8192 0.001184 0.001719 0.688882 -1 16384 0.003481 0.004585 0.759322 -2 32768 0.009980 0.012043 0.828671 -1 65536 0.027762 0.028783 0.964516 -1 131072 0.072987 0.067773 1.076926 -1 262144 0.186714 0.151604 1.231588 -1 524288 0.462057 0.342160 1.350411 -1 1048576 1.119103 0.788582 1.419134 -2 2097152 2.726458 1.838570 1.482923 -1 4194304 6.607204 4.069614 1.623546 -1 8388608 15.627027 8.980883 1.740032 -1 16777216 36.581787 19.167144 1.908567 -4 33554432 83.568330 40.131393 2.082368 -1 67108864 190.596889 81.412867 2.341115 -1
Interestingly, the Newton division breaks even at 130,000 digits and is twice as fast at 30 million digits. So it is clear that either gmpy does not use GMP optimally, or GMP does not use the asymptotically fastest possible division algorithm. I think the latter is the case; this page contains development code for the next version of GMP, including improved division code, and notes that "the new code has complexity O(M(n)) for all operations, while the old mpz code is O(M(n)log(n))". This seems consistent with my timings.
A small notice: I will be away for about a week starting tomorrow. I will bring my laptop to continue working on my GSoC project during the time, but I won't have internet access.
Edit: Fixed a misplaced parenthesis in newdiv that gave the wrong criterion for falling back to p//q. Benchmarks unaffected.
## Monday, July 7, 2008
### Hypergeometric series with SymPy
SymPy 0.6.0 is out, go get it! (It will be required for running the following code.)
Here is a nice example of what SymPy can be used for (I got the idea to play around with it today): automated generation of code for efficient numerical summation of hypergeometric series.
A rational hypergeometric series is a series (generally infinite) where the quotient between successive terms, R(n) = T(n+1)/T(n), is a rational function of n with integer (or equivalently rational) coefficients. The general term of such a series is a product or quotient of polynomials of n, integers raised to the power of An+B, factorials (An+B)!, binomial coefficients C(An+B, Cn+D), etc. The Chudnovsky series for π, mentioned previously on this blog, is a beautiful example:
Although this series converges quickly (adding 14 digits per term), it is not efficient to sum it term by term as written. It is slow to do so because the factorials quickly grow huge; the series converges only because the denominator factorials grow even quicker than the numerator factorials. A much better approach is to take advantage of the fact that each (n+1)'th term can be computed from the n'th by simply evaluating R(n).
Given the expression for the general term T(n), finding R(n) in simplified form is a straightforward but very tedious exercise. This is where SymPy comes in. To demonstrate, let's pick a slightly simpler series than the Chudnovsky series:
The SymPy function hypersimp calculates R given T (this function, by the way, was implemented by Mateusz Paprocki who did a GSoC project for SymPy last year):
>>> from sympy import hypersimp, var, factorial>>> var('n')n>>> pprint(hypersimp(factorial(n)**2 / factorial(2*n), n)) 1 + n-------2 + 4*n
So to compute the next term during the summation of this series, we just need to multiply the preceding term by (n+1) and divide it by (4n+2). This is very easy to do using fixed-point math with big integers.
Now, it is not difficult to write some code to automate this process and perform the summation. Here is a first attempt:
from sympy import hypersimp, lambdifyfrom sympy.mpmath.lib import MP_BASE, from_man_expfrom sympy.mpmath import mpf, mpdef hypsum(expr, n, start=0): """ Sum a rapidly convergent infinite hypergeometric series with given general term, e.g. e = hypsum(1/factorial(n), n). The quotient between successive terms must be a quotient of integer polynomials. """ expr = expr.subs(n, n+start) num, den = hypersimp(expr, n).as_numer_denom() func1 = lambdify(n, num) func2 = lambdify(n, den) prec = mp.prec + 20 one = MP_BASE(1) << prec term = expr.subs(n, 0) term = (MP_BASE(term.p) << prec) // term.q s = term k = 1 while abs(term) > 5: term *= MP_BASE(func1(k-1)) term //= MP_BASE(func2(k-1)) s += term k += 1 return mpf(from_man_exp(s, -prec))
And now a couple of test cases. First some setup code:
from sympy import factorial, var, Rational, binomialfrom sympy.mpmath import sqrtvar('n')fac = factorialQ = Rationalmp.dps = 1000 # sum to 1000 digit accuracy
Some formulas for e (source):
print hypsum(1/fac(n), n)print 1/hypsum((1-2*n)/fac(2*n), n)print hypsum((2*n+1)/fac(2*n), n)print hypsum((4*n+3)/2**(2*n+1)/fac(2*n+1), n)**2
Ramanujan series for π (source):
print 9801/sqrt(8)/hypsum(fac(4*n)*(1103+26390*n)/fac(n)**4/396**(4*n), n)print 1/hypsum(binomial(2*n,n)**3 * (42*n+5)/2**(12*n+4), n)
Machin's formula for π:
print 16*hypsum((-1)**n/(2*n+1)/5**(2*n+1), n) - \ 4*hypsum((-1)**n/(2*n+1)/239**(2*n+1), n)
A series for √2 (Taylor series for √(1+x), accelerated with Euler transformation):
print hypsum(fac(2*n+1)/fac(n)**2/2**(3*n+1), n)
Catalan's constant:
print 1./64*hypsum((-1)**(n-1)*2**(8*n)*(40*n**2-24*n+3)*fac(2*n)**3*\ fac(n)**2/n**3/(2*n-1)/fac(4*n)**2, n, start=1)
Some formulas for ζ(3) (source):
print hypsum(Q(5,2)*(-1)**(n-1)*fac(n)**2 / n**3 / fac(2*n), n, start=1)print hypsum(Q(1,4)*(-1)**(n-1)*(56*n**2-32*n+5) / \ (2*n-1)**2 * fac(n-1)**3 / fac(3*n), n, start=1)print hypsum((-1)**n * (205*n**2 + 250*n + 77)/64 * \ fac(n)**10 / fac(2*n+1)**5, n)P = 126392*n**5 + 412708*n**4 + 531578*n**3 + 336367*n**2 + 104000*n + 12463print hypsum((-1)**n * P / 24 * (fac(2*n+1)*fac(2*n)*fac(n))**3 / \ fac(3*n+2) / fac(4*n+3)**3, n)
All of these calculations finish in less than a second on my computer (with gmpy installed). The generated code for the Catalan's constant series and the third series for ζ(3) are actually almost equivalent to the code used by mpmath for computing these constants. (If I had written hypsum earlier, I could have saved myself the trouble of implementing them by hand!)
This code was written very quickly can certainly be improved. For one thing, it should do some error detection (if the input is not actually hypergeometric, or if hypersimp fails). It would also be better to generate code for summing the series using binary splitting than using repeated division.
To perform binary splitting, one must know the number of terms in advance. Finding out how many terms must be included to obtain a accuracy of p digits can be done generally by numerically solving the equation T(n) = 10-p (for example with mpmath). If the series converges at a purely geometric rate (and this is often the case), the rate of convergence can also be computed symbolically. Returning to the Chudnovsky series, for example, we have
>>> from sympy import *>>> fac = factorial>>> var('n')n>>> P = fac(6*n)*(13591409+545140134*n)>>> Q = fac(3*n)*fac(n)**3*(-640320)**(3*n)>>> R = hypersimp(P/Q,n)>>> abs(1/limit(R, n, oo))151931373056000>>> log(_,10).evalf()14.1816474627255
So the series adds 14.18165 digits per term.
With some more work, this should be able to make it into SymPy. The goal should be that if you type in a sum, and ask for a high precision value, like this:
>>> S = Sum(2**n/factorial(n), (n, 0, oo))>>> S.evalf(1000)
then Sum.evalf should be able to automatically figure out that the sum is of the rational hypergeometric type and calculate it using the optimal method.
## Thursday, July 3, 2008
### Faster pi, more integrals and complex numbers
Yesterday, I implemented the Chudnovsky algorithm in mpmath for computing π (see commit). This turns out to be about 3x faster than the old algorithm, so mpmath now only needs about 10 seconds to compute 1 million digits of π. To try it out, fetch the SVN version of mpmath, make sure gmpy 1.03 is installed, and run:
>>> from mpmath import mp, pi>>> mp.dps = 10**6>>> print pi
Right now, computing π with mpmath is actually faster than with SAGE (but knowing the SAGE people, this bug will be fixed soon :-).
As promised in the last post, I will now write in more detail about the most recently added features to my numerical evaluation code for SymPy. For the code itself, see evalf.py and test_evalf.py.
#### New functions
The functions atan (for real input) and log (for positive real input) have been added.
>>> N('log(2)', 50)'0.69314718055994530941723212145817656807550013436026'>>> N('16*atan(1/5) - 4*atan(1/239)', 50)'3.1415926535897932384626433832795028841971693993751'
The working precision is increased automatically to evaluate log(1+ε) accurately:
>>> N('log(2**(1/10**20))',15)'6.93147180559945e-21'
#### Integrals
A second important new feature is support for integrals. There are still some bugs to be sorted out with the implementation, but the basics work.
>>> from sympy import *>>> var('x')x>>> gauss = Integral(exp(-x**2), (x, -oo, oo))>>> N(gauss, 15)'1.77245385090552'
Integrals can be used as part of larger expressions, and adaptive evaluation works as expected:
>>> N(gauss - sqrt(pi) + E*Rational(1,10**20), 15)'2.71828182845904e-20'
For reasonably nice integrands, the integration routine in mpmath can provide several hundred digits fairly quickly. Of course, any numerical integration algorithm can be fooled by pathological input, and the user must assume responsibility for being aware of this fact. In many common situations, however, numerical errors can be detected automatically (and doing this well is something I will look into further).
#### Complex arithmetic
The most important new feature is support for multiplication and addition of complex numbers.
In an earlier post, I posed the question of how to best track accuracy for complex numbers. This turns out not to be such a difficult problem; as soon as I got started with the implementation, I realized that there is only one reasonable solution. I have decided to track the accuracy of the real and imaginary parts separately, but to count the accuracy of a computed result as the accuracy of the number as a whole.
In other words, a computed result z denotes a point in the complex plane and the real and imaginary errors define a rectangular uncertainty region, centered around z. The other option would have been a circular disk, requiring only a single real error value (specifying radius). The rectangular representation is somewhat easier to work with, and much more powerful, because it is very common that the real part is known much more accurately than the imaginary part, and vice versa.
If the half-width and half-height of the error rectangle are defined by the complex number w, then the absolute error can be defined the usual way as |w| and the relative error as |w|/|z|. (For computational purposes, the complex norm can be approximated accurately using the max norm. This is wrong by at most a factor √2, or logarithmically by log2(√ 2) = 0.5 bits = 0.15 decimals.)
In other words, if |w|/|z| = 10−15, the result is considered accurate to 15 digits. This can either mean that both the real and imaginary parts are accurate to 15 digits, or that just one of them is, provided that the other is smaller in magnitude. For example, with a target accuracy of 15 digits; if the real part is fully accurate, and the imaginary part is a factor 103 smaller than the real part, then the latter need only be accurate to 15−3 = 12 digits. The advantage of this approach is that accuracy is preserved exactly under multiplication, and hence no restarting is required during multiplication.
As an example, consider the following multiplication in which the real parts completely cancel:
>>> N('(1/3+2*I)*(2+1/3*I)', 10)'.0e-12 + 4.111111111*I'
As noted in earlier posts, numerical evaluation cannot detect a quantity being exactly zero. The ".0e-12" is a scaled zero, indicating a real quantity of unknown sign and magnitude at most equal to 1e-12. (To clarify its meaning, it could perhaps be printed with a "±" sign in front). If we treat it as 10−12, its relative accuracy is 0 digits (because 0 nonzero digits are known). But the result as a whole is accurate to 10 digits, due to the imaginary part being more than 1010 times larger and accurate to 10 digits.
In an earlier post, I speculated about the total accuracy being problematic to use for complex results, because of subsequent additions potentially causing cancellations. This was rather stupid, because the problem already existed for purely real numbers, and was already solved by the existing adaptive addition code. To implement complex addition, I basically just needed to refactor the code to first evaluate all the terms and then add up the real and imaginary parts separately.
Building on the previous example, where the imaginary part held all the accuracy, we can try to subtract the entire imaginary part:
>>> N('(1/3+2*I)*(2+1/3*I) - 37/9*I + pi/10**50', 10)'3.141592654e-50 + .0e-62*I'
The addition routine finds that both the real and the imaginary parts are inaccurate and retries at higher precision until it locates the tiny real part that has been added. Alternatively, the following test also works (the imaginary part is displayed as 1.0e-15 despite having been computed accurately to 10 digits, because mpmath strips trailing zeros — this could perhaps be changed):
>>> N('(1/3+2*I)*(2+1/3*I) - (37/9 - 1/10**15)*I', 10)'.0e-30 + 1.0e-15*I'
The computation
>>> N('(1/3+2*I)*(2+1/3*I) - 37/9*I, 10)
hangs, as it should, because I have still not implemented any stopping criterion for apparent total cancellations.
So there is still work to do :-)
## Tuesday, July 1, 2008
### GMPY makes mpmath more speedy
This post will mostly be about recent mpmath development, but first a short update about my GSoC progress. Over the last week, I have improved the support for complex numbers (addition and multiplication of complex numbers works and detects cancellation in the real and imaginary parts), implemented some more functions, and added support for integrals. I still need to clean up and test the code some more. A longer update will be posted later today or tomorrow.
Besides working directly with the GSoC project, I've been busy playing with the results of a patch for mpmath that was submitted a few days ago by casevh. This brilliant patch allows mpmath to use GMPY mpz's instead of Python's built-in long integers.
GMPY, of course, is a Python wrapper for the highly optimized GMP bignum library. The beauty of GMPY is that you can just import it anywhere in your Python code, change x = 1 to x = mpz(1), and then almost any code written under the assumption of x being a Python int will continue to work, the only difference being that it will be much faster if x grows large.
(Mpmath attempts to accomplish something similar, being an intended drop-in replacement for the math and cmath modules and even parts of SciPy. However, mpmath's advantage is only that it gives increased precision; for low-precision number crunching, it is obviously much slower than ordinary floats.)
To try out mpmath with GMPY support, you need to check out the current development version from the mpmath SVN repository. There will be a new release soon, but not in the next few days. Casevh discovered a few bugs in GMPY while implementing this feature, so the patched version 1.03 of GMPY is needed. Mpmath will still work if an older version of GMPY is present; in that case, it will simply ignore it and use Python integers as usual. Just to be clear, mpmath is still a pure-Python library and will continue to work fine with GMPY unavailable (it will just not be as fast).
The improvement is quite significant. At precisions between 1,000 to 10,000 digits, most mpmath functions are of the order of 10 times faster with GMPY enabled. I have on occasion tried out some computations at 100,000 digits with mpmath; although they work fine, I have had to do something else while waiting for the results. With GMPY enabled, computing something like exp(sin(sqrt(2))) to 100,000 digits now only takes a couple of seconds.
SymPy will of course benefit from this feature. N/evalf will be able to handle ill-conditioned input much more efficiently, and the maximum working precision can be set higher, giving improved power and reliability for the same computing time.
The GMPY mode is slightly slower than the Python mode at low precision (10 percent slower below 100 digits of precision, or thereabout). That's something I can live with.
A particularly dramatic improvement can be seen by running the pidigits.py demo script. After I fixed an inefficiency in the number-to-string conversion, computing 1 million decimals of π with mpmath in GMPY-mode takes less than 30 seconds on my laptop:
C:\Source\mp\trunk\demo>pidigits.pyCompute digits of pi with mpmathWhich base? (2-36, 10 for decimal)> 10How many digits? (enter a big number, say, 10000)> 1000000Output to file? (enter a filename, or just press enterto print directly to the screen)> pi.txtStep 1 of 2: calculating binary value... iteration 1 (accuracy ~= 0 base-10 digits) iteration 2 (accuracy ~= 2 base-10 digits) iteration 3 (accuracy ~= 4 base-10 digits) iteration 4 (accuracy ~= 10 base-10 digits) iteration 5 (accuracy ~= 21 base-10 digits) iteration 6 (accuracy ~= 43 base-10 digits) iteration 7 (accuracy ~= 86 base-10 digits) iteration 8 (accuracy ~= 173 base-10 digits) iteration 9 (accuracy ~= 348 base-10 digits) iteration 10 (accuracy ~= 697 base-10 digits) iteration 11 (accuracy ~= 1396 base-10 digits) iteration 12 (accuracy ~= 2793 base-10 digits) iteration 13 (accuracy ~= 5587 base-10 digits) iteration 14 (accuracy ~= 11176 base-10 digits) iteration 15 (accuracy ~= 22353 base-10 digits) iteration 16 (accuracy ~= 44707 base-10 digits) iteration 17 (accuracy ~= 89414 base-10 digits) iteration 18 (accuracy ~= 178830 base-10 digits) iteration 19 (accuracy ~= 357662 base-10 digits) iteration 20 (accuracy ~= 715325 base-10 digits) iteration 21 (accuracy ~= 1000017 base-10 digits) final divisionStep 2 of 2: converting to specified base...Writing output...Finished in 28.540354 seconds (26.498292 calc, 2.042062 convert)
The same operation takes around 30 minutes in Python mode.
The speed of computing π with mpmath+GMPY is entirely respectable; some of the specialized π programs out there are actually slower (see Stu's pi page for an overview). The really fast ones run in 2-3 seconds; most require between 30 seconds and a minute.
One reason for mpmath+GMPY still being a bit slower for calculating π than the fastest programs is that it uses an arithmetic-geometric mean (AGM) based algorithm. The fastest algorithm in practice is the Chudnovsky series (with binary splitting), but its implementation is more complex, and making it really fast would require eliminating the Python and GMPY overhead as well. (A highly optimized implementation for GMP has been written by Hanhong Xue.)
The presence of GMPY does change the relative performance of various algorithms, particularly by favoring algorithms that take advantage of asymptotically fast multiplication. To try this out, I implemented binary splitting for computing e (see commit) in mpmath. Computing 1 million digits of e with mpmath now takes 3 seconds (converting to a base-10 string takes an additional 2 seconds). It actually turns out that binary splitting method for e is faster than the old direct summation method in Python mode as well, but only slightly.
Two of the most important functions are exp and log. Mpmath computes exp via Taylor series, using Brent's trick of replacing x by x/22k to accelerate convergence. Log is computed by inverting exp with Newton's method (in fact Halley's method is used now, but the principle is the same). This makes log roughly half as fast as exp at low precision, but asymptotically equal to exp. With GMPY, it becomes much faster to compute log at high precision using an AGM-based algorithm. This also implies that it becomes faster to compute exp at extremely high precision using Newton inversion of log, in an interesting reversal of roles. I have written some preliminary code for this, which I should be able to commit soon.
Several others have made great contributions to mpmath recently. Mario Pernici has improved the implementations of various elementary functions, Vinzent Steinberg has submitted some very interesting new root-finding code, and Mike Taschuk sent in a file implementing Jacobi elliptic functions for mpmath.
Felix Richter, who works for the semiconductor theory group at the physics department of the University of Rostock, shared some code for solving linear equation systems in a private correspondence. (I promised I would tidy it up and add it to mpmath, but it appears that I've been too lazy to do that yet.) He had some very interesting things to say about his research and why he wrote the code (I hope he doesn't mind that I quote a part of his mail here):
The range of problems we currently attack can be described as follows: Imagine a light beam incident on some solid body, e.g., a semiconductor crystal of some 50 micrometers length. When the light propagates into the sample it gets damped, and its strength will sooner or later become incredibly small, i.e., it can no longer be held in a double precision float variable.
However, a lot of interesting things can be calculated with the help of these electromagnetic field strength, such as predictions for the output of semiconductor lasers or signs for the much-sought-after Bose-Einstein condensation of excitons (electron-hole pairs in a semiconductor). I sure shouldn't go much more into detail here, as I suppose you're not a physicist.
Just one example: As a consistency check, the equation
1 - |r|^2 - |t|^2 = \int dx dx' A(x') chi(x,x') A(x)
should be fullfilled for any light frequency. r, t, A(x) are complex electromagnetic field strengths and just cannot be calculated with machine precision alone, not to mention further calculations based on them. (Chi is the susceptibility and describes the electromagnetic properties of the matter).
However, due to the magic of math (and mpmath ;-) ), the interplay of these incredibly small numbers yields two perfectly equal numbers between 0 and 1, as it should.
I'm really happy having chosen Python for my work. Mpmath fits in well, its so easy to use. I especially like the operator overloading, so that I may add some complex multiprecision numbers with a simple "+". And mpmath's mathematical and numerical function library is so extensive that it can take you really a long way.
It is always fun to hear from people who use software you're working on, but it's especially rewarding when you learn that the software is being used to solve real problems.
Computing a million digits of π, on the other hand, could hardly be called a real-world problem. But it is the sort of thing any competent arbitrary-precision library should be able to do without effort. Sometimes math is done to construct semiconductor lasers; sometimes math is done just because it's fun (and often there is some overlap :-).
## Sunday, June 22, 2008
### Taking N to the limit
A simple numerical algorithm to compute limx → a f(x) in the case when f(a) is undefined is to evaluate f(a+ε) for some fixed small value ε (or f(1/ε) in case a = ∞). The expression f(a+ε) or f(1/ε) is typically extremely poorly conditioned and hence a challenge for a numerical evaluation routine.
As a stress test for N, I have tried numerically evaluating all the limits in test_demidovich.py, a set of tests for SymPy's symbolic limit function.
I chose to evaluate each limit to 10 accurate digits, using ε = 10-50. Some simplifications were necessary:
• Since the numerical limit algorithm described above cannot generally detect convergence to 0 or ∞ (giving pseudorandom tiny or huge values instead), I chose to interpret any magnitude outside the range 10-10 to 1010 as 0 or ∞.
• SymPy's limit function supports limits containing parameters, such as limx→0 (cos(mx)-cos(nx))/x2 = (n2-m2)/2. In all such cases, I replaced the parameters with arbitrary values.
The nlimit function with tests is available in the file limtest.py (requiring evalf.py, mpmath and the hg version of SymPy). A straightforward limit evaluation looks like this:
>>> nlimit(sin(x)/(3*x), x, 0, 10)'0.3333333333'
The results of the tests? After fixing two minor bugs in N that manifested themselves, nlimit passes 50 out of 53 tests. It only fails three tests involving the functions log and asin which are not yet implemented. SymPy's limit function fails 8 out of the 53 tests; in each of these cases, nlimit gives the correct value to 10 digits.
nlimit is 100 times faster than limit, processing all the test cases in 0.18 (versus 18) seconds.
Despite only 10 digits being requested, running N with verbose=True shows that upwards of 800 bits of working precision are required for some of the limits, indicating very clearly the need for adaptive numerical evaluation.
The heuristic of using a fixed, finite ε will not work in case a limit converges extremely slowly. And of course, limit gives a nice, symbolic expression instead of an approximation (nlimit could give an exact answer in simple cases by passing its output through number recognition functions in mpmath). Due to these limitations, a numerical limit algorithm is at best a complement to a symbolic algorithm. The point, at this moment, is just to test N, although providing a numerical limit function in SymPy would also be a good idea.
I should note that there are much more sophisticated algorithms for numerical limits than the brute force method described here. Such algorithms are necessary to use especially when evaluating limits of indexed sequences where each element is expensive to compute (e.g. for summation of infinite series). A few acceleration methods for sequences and series are available in mpmath.
## Friday, June 20, 2008
### How many digits would you like?
My last post discussed the implementation of a number type that tracks the propagation of initial numerical uncertainties under arithmetic operations. I have now begun implementing a function that in some sense does the reverse; given a fixed formula and desired final accuracy, it produces a numerical value through recursive evaluation. I've named the function N because it behaves much like Mathematica's function with the same name.
The file is available here (the code needs a lot of cleanup at this point, so please be considerate). It contains a small test suite that should pass if you try running it.
The input to N can be a SymPy expression or a string representing one. For simplicity, the returned value is currently just a string. The second argument to N specifies the desired precision as a number of base-10 digits:
>>> from sympy import *>>> from evalf import N>>> N(pi,30)'3.14159265358979323846264338328'>>> N('355/113',30)'3.14159292035398230088495575221'
The set of supported expressions is currently somewhat limited; examples of what does work will be given below.
As I have said before, an important motivation for an adaptive algorithm for numerical evaluation is to distinguish integers from non-integers (or more simply, distinguishing nonzero numbers from zero). Numerical evaluation is, as far as I know, the only general method to evaluate functions such as x ≥ y, sign(x), abs(x) and floor(x). Due to the discontinuous nature of these functions, a tiny numerical error can cause a drastically wrong result if undetected, leading to complete nonsense in symbolic simplifications.
There are many known examples of "high-precision fraud", i.e. cases where an expression appears to be identical to another if evaluated to low numerical precision, but where there is in fact a small (and sometimes theoretically important) difference. See for example MathWorld's article, "Almost Integer". Some of these examples are rather conspicuous (e.g. any construction involving the floor function), but others are surprising and even involve elegant mathematical theory. In any case, they are a great way to test that the numerical evaluation works as intended.
#### Some algebraic examples
A neat way to derive almost-integers is based on Binet's formula for the Fibonacci numbers, F(n) = (φn - (-φ)n)/√5 where φ is the golden ratio (1+√5)/2. The (-φ)n-term decreases exponentially as n grows, meaning that φn/√5 alone is an excellent (although not exact) approximation of F(n). How good? Let's compute F(n) - φn/√5 for a few n (we can use SymPy's exact Fibonacci number function fibonacci(n) to make sure no symbolic simplification accidentally occurs):
>>> binet = lambda n: ((1+sqrt(5))/2)**n/sqrt(5)>>> N(binet(10) - fibonacci(10), 10)'3.636123247e-3'>>> N(binet(100) - fibonacci(100), 10)'5.646131293e-22'>>> N(binet(1000) - fibonacci(1000), 10)'4.60123853e-210'>>> N(binet(10000) - fibonacci(10000), 10)'5.944461218e-2091'
N works much better than the current fixed-precision evalf in SymPy:
>>> (fibonacci(1000) - binet(1000)).evalf()-1.46910587887435e+195
With N, we find that the simplified Binet formula not only gives the correct Fibonacci number to the nearest integer; for F(10000), you have to look 2000 digits beyond the decimal point to spot the difference. A more direct approach, of course, is to simply evaluate the (-φ)n term; the beauty of the implementation of N is that it works automatically, and it will still work in case there are a hundred terms contributing to cancel each other out (a much harder situation for a human to analyze).
Another, related, well-known result is that F(n+1)/F(n) is a close approximation of the golden ratio. To see how close, we can just compute the difference:
>>> N(fibonacci(10001)/fibonacci(10000) - (1+sqrt(5))/2, 10)'3.950754128e-4180'>>> N(fibonacci(10002)/fibonacci(10001) - (1+sqrt(5))/2, 10)'-1.509053796e-4180'
The approximation is good to over 4000 digits. Note also the signs; based on the numerical results, we could compute the exact value of the function sign(F(n+1)/F(n) - φ) for any specific value of n (and find that it is positive for odd n and negative for even n). Indeed, I will later implement the sign function (and related functions) in SymPy precisely this way: just try to call N() asking for 10 digits (or 3, it doesn't make much of a difference), and use the sign of the computed result if no error occurs.
Let's also revisit Rump's example of an ill-conditioned function, which was mentioned in my previous blog post. I have given N the ability to substitute numerical values for symbols (this required roughly two lines of code), in effect allowing it to be used for function evaluation. When asked for 15 digits, N gives the correct value right away:
>>> var('x y')>>> a = 1335*y**6/4+x**2*(11*x**2*y**2-y**6-121*y**4-2) + \... 11*y**8/2+x/(2*y)>>> N(a, 15, subs={x:77617, y:33096})'-0.827396059946821'
With the "verbose" flag set, N shows that it encounters cancellations during the addition and has to restart twice:
>>> N(a, 15, subs={x:77617, y:33096}, verbose=1)ADD: wanted 54 accurate bits, got -7 -- restarting with prec 115ADD: wanted 54 accurate bits, got 2 -- restarting with prec 167'-0.827396059946821'
#### Transcendental functions
N currently supports the constants π and e, and the functions x^y, exp, cos and sin. I refer to my previous post for a discussion of the issues involved in (real) exponentiation. Suffice to say, N figures out that in order to compute 10 mantissa digits of π to the power of 1 googol, it needs 110 digits of precision:
>>> N(pi ** (10**100), 10)'4.946362032e+4971498726941338543512682882908988736516783243804424461340534999249471120895526746555473864642912223'
It is also able to cope with cancellation of exponentials close to unity:
>>> N('2**(1/10**50) - 2**(-1/10**50)',15)'1.38629436111989e-50'
The trigonometric functions are a bit more interesting. Basically, to compute cos(x) or sin(x) to n accurate digits, you need to first evaluate x with an absolute error of 10-n. In order to calculate x to within a given absolute error, the magnitude of x must be known first, so two evaluations are generally required. N avoids the problem by evaluating x to a few extra bits the first time; if it turns out that |x| < C for the appropriate constant (say C = 1000), a second evaluation is not necessary. By appropriately increasing the internal precision, correct evaluations such as the following are possible:
>>> N('sin(exp(1000))',15)'-0.906874170721915'
There is an additional complication associated with evaluating trigonometric functions. If the argument is very close to a root (i.e. a multiple of π for sin, or offset by π/2 for cos), the precision must be increased further. N detects when this is necessary, and is for example able to deduce the following:
>>> N(sin(pi*10**1000 + Rational(1,10**1000), evaluate=False), 10)'1.0e-1000'
The test shows that there is no difference between evaluating sin(2πn + x) and sin(x), except of course for speed. The evaluate=False was added to prevent SymPy from removing the full-period term π · 101000. This automatic simplification is of course a SymPy feature; indeed, it makes the cleverness in N redundant in many cases by automatically reducing the argument to a region close to zero. However, the symbolic simplification is not of much help when x happens to be close to a multiple of 2π without having that explicit symbolic form. To demonstrate, let's combine a trigonometric function with the Fibonacci number approximation from before:
>>> phi = (1+sqrt(5))/2>>> N(sin(phi**3000 / sqrt(5) * pi), 15)'1.53018563496763e-627'
Running with verbose=True shows that N sets the working precision to over 6000 bits before it arrives at those 15 digits.
#### The problem with zero
I have so far neglected to mention the issue of zero detection. Although adaptive numerical evaluation can identify a nonzero value in finite time, it cannot detect a zero.
Suppose we try to compute the difference between the explicit Fibonacci number F(n) and the expression for the same in terms of Binet's exact formula (φn - (-φ)n)/√5. N(...,10) will in effect attempt to find 10 nonzero digits of 0, and of course fail, getting stuck in an infinite loop:
>>> phi = (1+sqrt(5))/2>>> binet = lambda n: (phi**n - (-phi)**n)/sqrt(5)>>> N(binet(100) - fibonacci(100), 10, verbose=1)ADD: wanted 56 accurate bits, got -1 -- restarting with prec 113ADD: wanted 56 accurate bits, got 0 -- restarting with prec 169ADD: wanted 56 accurate bits, got -3 -- restarting with prec 228...ADD: wanted 56 accurate bits, got 0 -- restarting with prec 524753ADD: wanted 56 accurate bits, got -1 -- restarting with prec 1049051...
To deal with this problem, it will be necessary to set a threshold precision or maximum number of iterations, with a reasonable default value. This number should be possible to override by the user, either globally or by providing a keyword argument to N (perhaps both).
There are several possible courses of action in case the threshold is reached. A cheap and practical solution is to simply consider any smaller quantity to be zero. This can be done either silently or with a printed warning message. Rigorists would perhaps find it more satisfactory if an exception were raised. A final possibility is to prompt the user. I think all these options should be available; the question is what to do by default.
Fortunately, in a computer algebra system, most cancellations can be detected and turned into explicit zeros before they reach the N function (1-1, sin(πn), etc). I am not entirely sure about the terminology here, but I think this ability to symbolically detect zeros is the essential difference between computer algebra systems and what is sometimes called "lazy infinite-precision reals" (or something similar).
#### Complex numbers
Currently, N does not know how to deal with complex numbers (I have so far only written some placeholder code for this).
Addition should be relatively easy to implement: just add the real and imaginary parts separately and check the accuracy of each.
Multiplication is the simplest of all operations in the purely real case, because there are no cancellation effects whatsoever; all that is needed is to a few guard bits to deal with rounding. In fact, multiplying purely real and purely imaginary quantities already works (this is just a matter of keeping an extra boolean variable around to keep track of whether the product is imaginary; in effect a pseudo-polar representation):
>>> N('3*pi*I',10)'9.424777961*I'
With general complex numbers, however, multiplication in rectangular form translates into addition, and I think cancellation effects may come into play so that it will be a little more complicated to implement correctly. For multiplication, it would be much nicer to use polar complex numbers, but that makes addition harder. There's just no escape...
One thing I'm wondering about is how to define accuracy for complex numbers. One could either consider the accuracy of the number as a whole, or of the real and imaginary parts separately.
It is very common to encounter sums of complex numbers with conjugate imaginary parts, i.e. (a+bi) + (c-bi). What should N do if it obtains the requested number of digits, say 15, for the real part, but is unable to deduce anything about the imaginary part except that it is smaller than 10-15 of the real part? By the definition of relative error as z·(1+error), N should arguably be satisfied with that. But matters becomes more complicated if the number is subsequently passed to a function that is very sensitive to changes in the imaginary part alone (in the extreme case the imaginary part function, Im(z)).
#### Performance
What about speed? In the best case (i.e. no restarts), N seems to be about as fast as direct evaluation with mpmath. This might be surprising, since N both keeps track of errors and manually traverses the expression tree. I had actually expected N to come out faster, since much of the need for instance creation and floating-point normalization is eliminated, but it turns out that a good deal of that is still needed and the additional error bookkeeping largely makes up for the remaining advantage.
There are some potential optimizations that could be exploited. One would be to take advantage of the TERMS/FACTORS representation employed in SympyCore. In a sum like a·x + b·y + ... where the coefficients a, b... are integers or simple fractions (a very common situation), the coefficients can absorbed into the sum on the fly instead of recursively evaluating each term as a full product. Another optimization would be to save the magnitude (exponent + width of mantissa) and sign of each term in the numerical evaluation of sums. This way, an optimal precision can be chosen for each term in case the evaluation has to be restarted at higher precision.
#### Project status
This completes an important part of my GSoC project, namely to implement a reliable numerical expression evaluation algorithm. What remains now is first of all to add support for complex numbers and more mathematical functions, and to provide alternatives to the infinite loop for dealing with zeros. The code should also work with something like the num class I posted previously; N currently assumes that expressions are exact and can be approximated to any accuracy, but it should also be able to accommodate expressions initially containing approximate numbers. And of course, it all has to be implemented in SymPy and debugged.
Post scriptum: it seems that I forgot to provide an example of applying N to Ramanujan's constant. I'll leave this as an entertaining exercise to the reader.
## Wednesday, June 11, 2008
### Basic implementation of significance arithmetic
This .py file contains a work-in-progress implementation of significance arithmetic, using mpmath as a base. The main class is currently called "num" (sorry, I just haven't come up with a good name yet). An instance can be created from a float or int value. A second number that specifies the accuracy (measured in decimal digits) can be passed; floats are assumed by default to have an accuracy of 53 bits or 15.95 decimal digits. The method .accuracy(b) gives the estimated number of accurate digits in the given base (default b = 10).
>>> num(1.2345678901234567890123456789)1.23456789012346>>> _.accuracy()15.954589770191001>>> num(1.2345678901234567890123456789, 5)1.2346>>> _.accuracy()5.0>>> num(1.2345678901234567890123456789, 25)1.234567890123456690432135>>> _.accuracy()25.0
In the last example, the fact that the input float has a limited accuracy as a representation of the entered decimal literal becomes visible. (Support for passing an exact string as input to avoid this problem will be added.)
The accuracy is a measure of relative accuracy (or relative error). A num instance with value u and accuracy a represents the interval u · (1 + ξ 2-a) for values of ξ between -1 and 1. The relative error, in the traditional numerical analysis meaning of the term, is given by 2-a and the absolute error is given by |u| · 2-a. In other words, the accuracy is a logarithmic (base 2) measure of error; in some cases, it is more natural to consider the (logarithmic) error, given by -a.
It can usually be assumed that a > 0. When this property does not hold, not even the sign of the number it is supposed to represent is known (unless additional assumptions are made). Such extremely inaccurate numbers will need special treatment in various places; when they result from higher operations (such as when the user asks for N digits of an expression in SymPy), they should probably signal errors.
How do errors propagate? The simplest case is that of multiplication. If x = u · (1+e) and y = v · (1+f), then x · y = u · v · (1+e) · (1+f) = (u · v) · (1 + e + f + e·f). Therefore the cumulative error is given by e + f + e·f. Expressed in terms of the logarithmic representation of the errors, 2-a = e and 2-b = f, the final accuracy is given by c = −log2(2-a + 2-b + 2-a-b). This expression can usually be approximated as c = min(a,b), which is the rule I have implemented so far. (Further testing will show whether it needs to be refined).
This analysis does not account for the error due to roundoff in the floating-point product u · v. Such errors can be accounted for either by adding an extra term to the error sum or by setting the arithmetic precision slightly higher than the estimated accuracy. I'm currently taking the latter approach.
Division is similar to multiplication.
Addition and subtraction is a bit harder, as these operations need to translate the relative errors of all the terms into a combined absolute error, and then translate that absolute error back to a relative accuracy (of the final sum). It is important to note that the accuracy of a sum can be much greater or much lesser than the minimum accuracy of all the terms.
Translating between relative and absolute error associated with a number involves knowing its magnitude, or rather the base-2 logarithm thereof. This is very easy with mpmath numbers, which are represented as tuples x = (sign, man, exp, bc) where bc is the bit size of the mantissa. The exact magnitude of x is given by log2 x = log2 man + exp, and this quantity can be approximated closely as exp+bc (although doing so admittedly does not pay off much since a call to math.log is inexpensive in Python terms).
Perhaps the most important type of error that significance arithmetic catches is loss of significance due to cancellation of terms with like magnitude but different sign. For example, 355/113 is an excellent approximation of pi, accurate to more than one part in a million. Subtracting the numbers from each other, with each given an initial accuracy of ~15 digits, leaves a number with only 9 accurate digits:
>>> pi = num(3.1415926535897932)>>> 355./113 - pi2.66764189e-7>>> _.accuracy()9.0308998699194341
Compare this with what happens when adding the terms:
>>> 355./113 + pi6.28318557394378>>> _.accuracy()15.954589770191001
Adding an inaccurate number to an accurate number does not greatly reduce accuracy if the less accurate number has small magnitude:
>>> pi + num(1e-12,2)3.1415926535908>>> _.accuracy()14.342229822223226
Total cancellation currently raises an exception. Significance arithmetic requires special treatment of numbers with value 0, because the relative error of 0 is meaningless; instead some form of absolute error has to be used.
I have also implemented real-valued exponentiation (x**y, exp(x) and sqrt(x)). These operations are currently a little buggy, but the basics work.
Exponentiation reduces accuracy proportionally to the magnitude of the exponent. For example, exponentiation by 1010 removes 10 digits of accuracy:
>>> from devel.num import *>>> pi = num(3.1415926535897932)>>> pi.accuracy()15.954589770191001>>> pi ** (10**10)8.7365e+4971498726>>> _.accuracy()5.954589770191002
Contrast this with the behavior of mpmath. With the working precision set to 15 digits, it will print 15 (plus two or three guard) digits of mantissa. Re-computing at a higher precision however verifies that only the first five digits were correct:
>>> from mpmath import mp, pi>>> mp.dps = 15>>> pi ** (10**10)mpf('8.7365179634758897e+4971498726')>>> mp.dps = 35>>> pi ** (10**10)mpf('8.7365213691213779435688568850099288527e+4971498726')
One might wonder where all the information in the input operand has gone. Powering is of course implemented using binary expontiation, so the rounding errors from repeated multiplications are insignificant.
The answer is that exponentiation transfers information between mantissa and exponent (contrast with a single floating-point multiplication, which works by separately multiplying mantissas and adding exponents). So to speak, exponentiation by 10n moves n digits of the mantissa into the exponent and then fiddles a little with whatever remains of the mantissa. Logarithms do the reverse, moving information from the exponent to the mantissa.
This is not something you have to think of often in ordinary floating-point arithmetic, because the exponent of a number is limited to a few bits and anything larger is an overflow. But when using mpmath numbers, exponents are arbitrary-precision integers, treated as exact. If you compute pi raised to 1 googol, you get:
>>> num(3.1415926535897932) ** (10**100)1.0e+4971498726941338374217231245523794013693982835177254302984571553024909360917306608664397050705368816>>> _.accuracy()-84.045410229808965
The exponent, although printed as if accurate to 100 digits, is only accurate to 15. Although the accuracy is reported as negative, the number does have a positive "logarithmic accuracy". So in contexts where extremely large numbers are used, some extra care is needed.
A counterintuitive property of arithmetic, that a direct implementation of precision-tracking floating-point arithmetic fails to capture, is that some operations increase accuracy. Significance arithmetic can recognize these cases and automatically adjust the precision to ensure that no information is lost. For example, although each input operand is accurate to only 15 decimal places, the result of the following operation is accurate to 65:
>>> num(2.0) ** num(1e-50)1.0000000000000000000000000000000000000000000000000069314718055995>>> _.accuracy()65.783713593702743
This permits one to do things like
>>> pi = num(3.1415926535897932)>>> (pi / (exp(pi/10**50) - 1)) / 10**501.0>>> _.accuracy()15.65355977452702
which in ordinary FP or interval arithmetic have a tendency to cause divisions by zero or catastrophic loss of significance, unless the precision is manually set high enough (here 65 digits) from the start.
Automatically-increasing precision is of course a bit dangerous since a calculation can become unpexpectedly slow in case the precision is increased to a level much higher than will be needed subsequently (e.g. when computing 15 digits of exp(10-100000) rather than exp(-100000)-1). This feature therefore needs to be combined with some user-settable precision limit.
I'll finish this post with a neat example of why significance or interval arithmetic is important for reliable numerical evaluation. The example is due to Siegfried M. Rump and discussed further in the paper by Sofroniou and Spaletta mentioned in an earlier post. The problem is to evaluate the following function for x = 77617 and y = 33096:
def f(x,y): return 1335*y**6/4 + x**2*(11*x**2*y**2-y**6-121*y**4-2) + \ 11*y**8/2 + x/(2*y)
Directly with mpmath, we get (at various levels of precision):
>>> from mpmath import mp, mpf, nstr>>> for i in range(2,51):... mp.dps = i... print i, nstr(f(mpf(77617),mpf(33096)),50)...2 1.1718753 2596148429267413814265248164610048.04 1.1726074218755 1.1726036071777343756 1.17260384559631347656257 1.17260393500328063964843758 -9903520314283042199192993792.09 -1237940039285380274899124224.010 -154742504910672534362390528.011 9671406556917033397649408.012 1.1726039400532499712426215410232543945312513 75557863725914323419136.014 -9444732965739290427392.015 -1180591620717411303424.016 1.172603940053178639413289374715532176196575164794917 -18446744073709551616.018 1152921504606846977.2519 144115188075855873.17187520 1.172603940053178631859449551101681752385275103733921 1125899906842625.172603845596313476562522 1.172603940053178631858840746170842724016569746936523 1.17260394005317863185883412872594229979517077566724 1.172603940053178631858834955906554852822845647075725 1.172603940053178631858834904207766568258615967612626 8589934593.172603940053178625535501566901075420901227 1073741825.172603940053178631823874167317001138144428 1.172603940053178631858834904510689155863484500890729 1.172603940053178631858834904520155486726136642555730 1.172603940053178631858834904520155486726136642555731 1.172603940053178631858834904520180138629424799174632 1.17260394005317863185883490452018322011733581875233 1.172603940053178631858834904520183797896319134922734 1.172603940053178631858834904520183701599821915560935 1.17260394005317863185883490452018370761835299177136 -0.8273960599468213681411650954798162920054888159658437 -0.8273960599468213681411650954798162920054888159658438 -0.8273960599468213681411650954798162919996113442117339 -0.8273960599468213681411650954798162919990603312347840 -0.8273960599468213681411650954798162919990373723607441 -0.8273960599468213681411650954798162919990330675718642 -0.8273960599468213681411650954798162919990330675718643 -0.8273960599468213681411650954798162919990331124134144 -0.8273960599468213681411650954798162919990331152160145 -0.8273960599468213681411650954798162919990331157414946 -0.8273960599468213681411650954798162919990331157852847 -0.8273960599468213681411650954798162919990331157852848 -0.8273960599468213681411650954798162919990331157844349 -0.8273960599468213681411650954798162919990331157843950 -0.82739605994682136814116509547981629199903311578438
Remarkably, the evaluations are not only wildly inaccurate at low precision; up to 35 digits, they seem to be converging to the value 1.1726..., which is wrong!
Significance arithmetic saves the day:
>>> for i in range(2,51):... try:... r = f(num(77617,i),num(33096,i))... s = str(r)... a = r.accuracy()... print i, str(s), a... except (NotImplementedError):... continue...2 2.0e+33 -2.515449934965 6.0e+29 -2.826779887266 -8.0e+28 -2.729869874267 -1.0e+28 -2.632959861258 -1.0e+27 -2.536049848249 -2.0e+26 -2.4391398352310 1.0e+25 -2.6432598178912 2.0e+23 -2.4494397918713 -9.0e+21 -2.6535597745314 -1.0e+21 -2.5566497615216 -2.0e+19 -2.362829735517 1.0e+18 -2.5669497181618 -7.0e+16 -2.7710697008120 1.0e+15 -2.577249674821 -1.0e+14 -2.4803396617925 9.0e+9 -2.6947596010926 1.0e+9 -2.5978495880827 -1.0e+8 -2.5009395750735 -8.0e-1 -2.9297794536636 -8.0e-1 -1.9297794536637 -8.0e-1 -0.92977945366238 -8.0e-1 0.070220546338439 -8.0e-1 1.0702205463440 -8.3e-1 2.0702205463441 -8.27e-1 3.0702205463442 -8.274e-1 4.0702205463443 -8.274e-1 5.0702205463444 -0.827396 6.0702205463445 -0.8273961 7.0702205463446 -0.82739606 8.0702205463447 -0.82739606 9.0702205463448 -0.8273960599 10.070220546349 -0.82739605995 11.070220546350 -0.827396059947 12.0702205463
I had to wrap the code in try/except-clauses due to num(0) not yet being implemented (at many of the low-precision stages, but fortunately for this demonstration not all of them, there is not unpexpectedly complete cancellation).
The accuracy is reported as negative until the arguments to the function are specified as accurate to over 38 digits, and at that point we see that the printed digits are indeed correct. (The values do not exactly match those of mpmath due to slightly different use of guard digits.)
Interestingly, the num class seems to greatly overestimate the error in this case, and I'm not yet sure if that's inherent to evaluating Rump's particular function with significance arithmetic or due to implementation flaws. It's of course better to overestimate errors than to underestimate them.
Numerical evaluation of a SymPy expression can be seen as converting the expression to a function of its constants (integers and special numbers like pi) and evaluating that function with the constants replaced by significance floating-point numbers. In practice, I will probably implement numerical evaluation using a recursive expression tree walker. This way forward error analysis can be used to efficiently obtain the user-requested level of accuracy at the top of the expression. Subevaluations can be repeated with increased precision until they become accurate enough; precision only needs to be increased for parts of an expression where it actually matters.
My next goal, besides polishing the existing features (and implementing num(0)), is to implement more functions (log, trigonometric functions), comparison operators, and writing some tests. With trigonometric functions, all the arithmetic operations for complex numbers will be straightforward to implement.
## Tuesday, June 3, 2008
### The significance of arithmetic
One week of GSoC has passed. Since school didn't end until today, I've so far only had time to do a simple edit to SymPy's Real type, replacing decimal with mpmath. Although this wasn't much work, the improvement is substantial. If you download the latest version of SymPy from the hg repository, you will find that for example cos(100).evalf() not only is fast (finishing in milliseconds rather than seconds), but actually returns the right value (!).
Switching to mpmath immediately solves a few problems, but others remain. What is the best way to handle the accuracy of approximate numbers in a computer algebra system? Different CASes use different strategies, each with pros and cons. I would like to arrive at some kind of conclusion by the end of this summer, but this is far from a solved problem. Common approaches roughly fall into three categories, which I will discuss briefly below.
The simplest approach, from the implementation point of view, is to approximate a number by a single (arbitrary-precision) floating-point number. It is up to the user to know whether any results become inaccurate due to cancellations and other errors. SymPy currently works this way (with the floating-point working precision adjusted via a global parameter).
The second approach is interval arithmetic: any exact real number can be approximated by bounding it between a pair of floating-point numbers. If all operations are implemented with proper rounding, interval arithmetic deals rigorously with approximation errors, in fact rigorously enough for formal proof generation.
Interval arithmetic is unfortunately sometimes needlessly conservative, greatly exaggerating the estimate of the true error. It also has some counterintuitive properties (e.g., x · x is not the same as x2), and there is no unambiguous way to define comparisons. Interval arithmetic also comes with a considerable speed penalty, by a factor usually of the order 2-8.
The third approach is what might be called significance arithmetic (although this term has other meanings). It can be viewed as a tradeoff between direct floating-point arithmetic and interval arithmetic. A number is approximated as a single floating-point number, but with an error estimate attached to it. This representation is in principle equivalent to that of interval arithmetic (the error estimate can be seen as the width of an interval), but operations are defined differently. Instead of propagating the estimated error rigorously, one settles for a first-order approximation (this often works well in practice).
The error can be stored as a machine-precision number (representing the logarithm of the absolute or relative error), making arithmetic only a little slower than direct arbitrary-precision floating-point arithmetic. A downside with significance arithmetic is that it is not so straightforward to represent the concept of a "completely inaccurate" number, e.g. a number with unknown sign (the number 0 requires special treatment). It is not entirely clear to me whether it is best to work with the absolute or relative error (or both). As with interval arithmetic, there are still multiple ways to define comparisons.
I'm leaning towards implementing significance arithmetic in SymPy. Mpmath already has some support for interval arithmetic (which I will work in improving later this summer), and this should be accessible in SymPy as well, but I think some looser form of significance arithmetic is the right approach for the common representation of approximate numbers. Right now, I'm studying the implementation of significance arithmetic in Mathematica ( Mark Sofroniou & Giulia Spaletta: Precise Numerical Computation), and writing some test code, to get to grips with the details.
## Saturday, May 24, 2008
### First post
Hi all,
I'm starting this blog to document my progress with my Google Summer of Code (GSoC) project for 2008. The aim of the project is to improve SymPy's high-precision numerics. This work will build upon my existing library mpmath, which is already included as a third-party package in SymPy. My first goal will be to make sure the SymPy-mpmath integration works correctly (this is presently not the case at all), and after that I will implement improved algorithms to make numerical evaluation faster and more reliable, as well as entirely new numerical functions (several people have for example expressed interest in doing linear algebra with mpmath, so that area will certainly get some attention). My mentor is Ondrej Certik.
The GSoC coding period officially starts on May 26. I unfortunately have an exam on May 28 and a thesis presentation on June 2 and 3, so I won't be coding full time during the first week. In any case, I have already started poking at some things. I will post a GSoC status update roughly once a week.
It's unfortunate that Saroj's GSoC project for SymPy was withdrawn. SymPy would benefit greatly from improved plotting, and a LaTeX renderer would be useful as well. With some luck, I will be able to spend some time on the plotting; I have some old interactive 2D plotting code lying around, which could be quite usable if converted from pygame to pyglet and with some general cleanup. (Try it out if you like: plot.py -curvedemo shows some standard x-y function plots; plot.py -complexdemo plots the Mandelbrot set. Mouse zooms, arrow keys pan, and keys 1-8 select detail level for the Mandelbrot set.)
I suppose it would be more relevant to show a screenshot of some complicated mathematical expression being converted to a decimal number in a Python shell, but fractals always catch people's attention. Expect more cheap tricks in the future!
|
|
# Ticket #8825: trac_8825-more-norm-doc.patch
File trac_8825-more-norm-doc.patch, 8.9 KB (added by mvngu, 12 years ago)
• ## sage/matrix/matrix2.pyx
# HG changeset patch
# User Minh Van Nguyen <nguyenminh2@gmail.com>
# Date 1272656283 25200
# Node ID d18a4dd6434c5c08316149189094ca59d2b47983
# Parent d2f2f1bd8c082a20c3b35a4625ca3942b420d205
#8825: improve documentation for function norm and cross reference various norm functions
diff --git a/sage/matrix/matrix2.pyx b/sage/matrix/matrix2.pyx
a OUTPUT: RDF number .. SEEALSO:: - :func:sage.misc.functional.norm EXAMPLES::
• ## sage/misc/functional.py
diff --git a/sage/misc/functional.py b/sage/misc/functional.py
a return x.ngens() def norm(x): """ Returns the norm of x. r""" Returns the norm of x. For matrices and vectors, this returns the L2-norm. For complex numbers, it returns the field norm. For matrices and vectors, this returns the L2-norm. The L2-norm of a vector \textbf{v} = (v_1, v_2, \dots, v_n), also called the Euclidean norm, is defined as .. MATH:: |\textbf{v}| = \sqrt{\sum_{i=1}^n |v_i|^2} where |v_i| is the complex modulus of v_i. The Euclidean norm is often used for determining the distance between two points in two- or three-dimensional space. For complex numbers, the function returns the field norm. If c = a + bi is a complex number, then the norm of c is defined as the product of c and its complex conjugate .. MATH:: \text{norm}(c) = \text{norm}(a + bi) = c \cdot \overline{c} = a^2 + b^2. The norm of a complex number is different from its absolute value. The absolute value of a complex number is defined to be the square root of its norm. A typical use of the complex norm is in the integral domain \ZZ[i] of Gaussian integers, where the norm of each Gaussian integer c = a + bi is defined as its complex norm. .. SEEALSO:: - :meth:sage.matrix.matrix2.Matrix.norm - :meth:sage.modules.free_module_element.FreeModuleElement.norm - :meth:sage.rings.complex_double.ComplexDoubleElement.norm - :meth:sage.rings.complex_number.ComplexNumber.norm - :meth:sage.symbolic.expression.Expression.norm EXAMPLES:: sage: z = 1+2*I sage: norm(z) 5 EXAMPLES: The norm of vectors:: sage: z = 1 + 2*I sage: norm(vector([z])) sqrt(5) sage: v = vector([-1,2,3]) sage: norm(v) sqrt(14) sage: _ = var("a b c d") sage: v = vector([a, b, c, d]) sage: norm(v) sqrt(abs(a)^2 + abs(b)^2 + abs(c)^2 + abs(d)^2) The norm of matrices:: sage: z = 1 + 2*I sage: norm(matrix([[z]])) 2.2360679775 sage: M = matrix(ZZ, [[1,2,4,3], [-1,0,3,-10]]) sage: norm(M) 10.6903311292 sage: norm(CDF(z)) 5.0 sage: norm(CC(z)) 5.00000000000000 The norm of complex numbers:: sage: z = 2 - 3*I sage: norm(z) 13 sage: a = randint(-10^10, 100^10) sage: b = randint(-10^10, 100^10) sage: z = a + b*I sage: bool(norm(z) == a^2 + b^2) True The complex norm of symbolic expressions:: sage: a, b, c = var("a, b, c") sage: z = a + b*I sage: bool(norm(z).simplify() == a^2 + b^2) True sage: norm(a + b).simplify() a^2 + 2*a*b + b^2 sage: v = vector([a, b, c]) sage: bool(norm(v).simplify_full() == sqrt(a^2 + b^2 + c^2)) True """ return x.norm()
• ## sage/modules/free_module_element.pyx
diff --git a/sage/modules/free_module_element.pyx b/sage/modules/free_module_element.pyx
a \geq 1, Infinity, or a symbolic expression. If p=2 (default), this is the usual Euclidean norm; if p=Infinity, this is the maximum norm; if p=1, this is the taxicab (Manhattan) norm. .. SEEALSO:: - :func:sage.misc.functional.norm EXAMPLES::
• ## sage/rings/complex_double.pyx
diff --git a/sage/rings/complex_double.pyx b/sage/rings/complex_double.pyx
a def abs(self): """ This function returns the magnitude of the complex number z, |z|. This function returns the magnitude |z| of the complex number z. .. SEEALSO:: - :meth:norm EXAMPLES:: def abs2(self): """ This function returns the squared magnitude of the complex number z, |z|^2. This function returns the squared magnitude |z|^2 of the complex number z, otherwise known as the complex norm. .. SEEALSO:: - :meth:norm EXAMPLES:: sage: CDF(2,3).abs2() return RealDoubleElement(gsl_complex_abs2(self._complex)) def norm(self): """ This function returns the squared magnitude of the complex number z, |z|^2. r""" This function returns the squared magnitude |z|^2 of the complex number z, otherwise known as the complex norm. If c = a + bi is a complex number, then the norm of c is defined as the product of c and its complex conjugate .. MATH:: \text{norm}(c) = \text{norm}(a + bi) = c \cdot \overline{c} = a^2 + b^2. The norm of a complex number is different from its absolute value. The absolute value of a complex number is defined to be the square root of its norm. A typical use of the complex norm is in the integral domain \ZZ[i] of Gaussian integers, where the norm of each Gaussian integer c = a + bi is defined as its complex norm. .. SEEALSO:: - :meth:abs - :meth:abs2 - :func:sage.misc.functional.norm - :meth:sage.rings.complex_number.ComplexNumber.norm EXAMPLES::
• ## sage/rings/complex_number.pyx
diff --git a/sage/rings/complex_number.pyx b/sage/rings/complex_number.pyx
a def norm(self): r""" Returns the norm of this complex number. If c = a + bi is a complex number, then the norm of c is defined as complex number, then the norm of c is defined as the product of c and its complex conjugate .. MATH:: \text{norm}(c) = \text{norm}(a + bi) = a^2 + b^2 \text{norm}(c) = \text{norm}(a + bi) = c \cdot \overline{c} = a^2 + b^2. The norm of a complex number is different from its absolute value. The absolute value of a complex number is defined to be the square root of its norm. A typical use of the complex norm is in the integral domain \ZZ[i] of Gaussian integers, where the norm of each Gaussian integer c = a + bi is defined as its complex norm. .. SEEALSO:: - :func:sage.misc.functional.norm - :meth:sage.rings.complex_double.ComplexDoubleElement.norm EXAMPLES:
• ## sage/symbolic/expression.pyx
diff --git a/sage/symbolic/expression.pyx b/sage/symbolic/expression.pyx
a def norm(self): r""" The complex norm of this symbolic expression, i.e., the expression times its complex conjugate. the expression times its complex conjugate. If c = a + bi is a complex number, then the norm of c is defined as the product of c and its complex conjugate .. MATH:: \text{norm}(c) = \text{norm}(a + bi) = c \cdot \overline{c} = a^2 + b^2. The norm of a complex number is different from its absolute value. The absolute value of a complex number is defined to be the square root of its norm. A typical use of the complex norm is in the integral domain \ZZ[i] of Gaussian integers, where the norm of each Gaussian integer c = a + bi is defined as its complex norm. .. SEEALSO:: - :func:sage.misc.functional.norm EXAMPLES::
|
|
To my taste, it seems more natural to let $A$ and $B$ play symmetric role, by asking whether there exists non-trivial factors $s_jA+t_jB$ such that $$A\left(\prod_{j=1}^p(s_jA+t_jB)\right)B=B\left(\prod_{j=1}^p(s_jA+t_jB)\right)A.$$
If you pose the question in an algebraically closed field $k$ (say, $k=\mathbb C$), then the answer is yes for the following reason:
There exist $n$ 2^n-1$non-zero factors$s_jA+t_jB$such that$\prod_{j=1}^n(s_jA+t_jB)=0$. The proof is by induction over the rank of products$\prod_{j=1}^p(s_jA+t_jB)=0$. Suppose that exists such a product$\Pi$, with rank$r\ge1$. Let us write $$\Pi=\sum_{j=1}^rx_ja_j^T.$$ Then $$\Pi M\Pi=\sum_{i,j=1}^r(a_i^TMx_j)x_ia_j^T.$$ The rank of$\Pi M\Pi$will be less than or equal to$r-1$if$\det(a_i^TMx_j)_{1\le i,j\le r}=0$. When$M=sA+tB$, this writes$H(s,t)=0$where$H$is a homogeneous polynomial of degree$r$. If$r\ge1$, it does have a non-trivial zero. Then$\Pi':=\Pi(sA+tB)\Pi$is an other product, with rank$\le r-1$. If in addition$\Pi$has$2^{n-r}-1$factors, then$\Pi'$has$2^{n+1-r}-1$factors. After$n$steps, one obtain that the obtains a product has of$2^n-1$factors whose rank is$0$. 1 To my taste, it seems more natural to let$A$and$B$play symmetric role, by asking whether there exists non-trivial factors$s_jA+t_jB$such that $$A\left(\prod_{j=1}^p(s_jA+t_jB)\right)B=B\left(\prod_{j=1}^p(s_jA+t_jB)\right)A.$$ If you pose the question in an algebraically closed field$k$(say,$k=\mathbb C$), then the answer is yes for the following reason: There exist$n$non-zero factors$s_jA+t_jB$such that$\prod_{j=1}^n(s_jA+t_jB)=0$. The proof is by induction over the rank of products$\prod_{j=1}^p(s_jA+t_jB)=0$. Suppose that exists such a product$\Pi$, with rank$r\ge1$. Let us write $$\Pi=\sum_{j=1}^rx_ja_j^T.$$ Then $$\Pi M\Pi=\sum_{i,j=1}^r(a_i^TMx_j)x_ia_j^T.$$ The rank of$\Pi M\Pi$will be less than or equal to$r-1$if$\det(a_i^TMx_j)_{1\le i,j\le r}=0$. When$M=sA+tB$, this writes$H(s,t)=0$where$H$is a homogeneous polynomial of degree$r$. If$r\ge1$, it does have a non-trivial zero. Then$\Pi':=\Pi(sA+tB)\Pi$is an other product, with rank$\le r-1$. After$n$steps, one obtain that the product has rank$0\$.
|
|
### Home > PC3 > Chapter Ch8 > Lesson 8.1.2 > Problem8-30
8-30.
An exponential function passes through the points $(1,70)$ and $(3,145)$. The function has a horizontal asymptote at $y=10$. Write an equation for the function.
Write the general equation for this problem.
Substitute the points in for $(x,y)$, creating two equations and two unknowns.
Subtract $10$ on both sides.
Then divide one equation by the other.
Divide the equations and solve for $b$.
Substitute the $b$-value back into one of the original equations and solve for $a$.
$y=a(b^x)+10$
$145=a(b^3)+10$
$70=a(b^1)+10$
$135=ab^3$
$60=ab^1$
$2.25=b^2$
$b=1.5$
|
|
Published on
# Understanding Object Oriented Programming (OOP) with Java
Authors
### What is an object?
Languages like C, which follow a structured programming paradigm, that is, have data structures and program instructions act on these data. In an object-oriented language - such as Java, JavaScript and others - we combine data and its instructions into objects.
Data and programming logic are combined into one object. It is a self-contained entity containing attributes and behaviors. This type of paradigm is a logical extension of older structural programming techniques and abstract data types. However, it is worth pointing out that the object is not necessarily an abstract data with the addition of polymorphism and inheritance. This generalization is done in some articles the wrong way.
### Polymorphism
Generally speaking, it means "various ways", and this in the context of programming means being able to do "a certain thing" in various ways. The point is this "certain thing". We're talking about method calls, so in Java polymorphism is only expressed in method calls. In other words, polymorphism is a piece of code that works with multiple data.
Being an object does not imply having polymorphism. Every object is polymorphic as its interface is. But this does not necessarily imply that every object has polymorphism.
Polymorphism is a single interface for data of different types or a symbol representing several different types. In practice this occurs with the three main classes of polymorphism, which are:
Polymorphism allows abstract class type references to represent the behavior of concrete classes they reference. In this way, it is possible to treat multiple types in the same way. That is, it is characterized as polymorphism, when more than two distinct classes have methods of the same name, so that a function can use an object of any of the polymorphic classes, without having to treat it differently according to the object's class.
A little more practically, think of an object "a" that calls the "speak()" method of an object "b", in this way, the object "b" defines the way to implement such a method, that is, the type of object "b" is what really matters.
Examples of polymorphic call:
1. Object "a" creates "b"
class A { void facaAlgo(){ Falador b; if(...) { b = new Pessoa(); } else { b = new Crianca(); } b.falar(); // chamada polimórfica }}
1. Object "a" receives object "b" from object "c"
class A { void facaAlgo(){ Gritador b = c.meDêUmGritador(); // "c" é um objeto qualquer para o qual tenha referência b.grita(); // chamada polimórfica }}
1. Object "a" receives object "b" in a method call
class A { void facaAlgo(Gritador b){ b.grita(); // chamda polimórfica }}
The general point of the examples is to be able to show that "a" has a reference to "b". Another thing is that, in Java, all method calls to objects are polymorphic. This in the case of OBJECT methods, in the case of static methods or also called class methods there is no polymorphism.
|
|
# Nelson Goodman
First published Fri Nov 21, 2014; substantive revision Fri Mar 4, 2016
Henry Nelson Goodman (1906–1998) was one of the most influential philosophers of the post-war era of American philosophy. Goodman's philosophical interests ranged from formal logic and the philosophy of science to the philosophy of art. In all these diverse fields Goodman made significant and highly original contributions. Perhaps his most famous contribution is the “grue-paradox”, which points to the problem that in order to learn by induction, we need to make a distinction between projectible and non-projectible predicates. Other important contributions include his description of the technique which would later be called “reflective equilibrium”, his investigation of counterfactuals, his “irrealism”, his development of mereology (with Henry S. Leonard), a nominalistic account of logical syntax (with W.V. Quine), his contribution to the cognitive turn in aesthetics, and his general theory of symbols.
In this article we focus on Goodman's life, conception of philosophy, philosophy of science, logic, language, and mathematics, and metaphysics. For Goodman's theory of symbols and philosophy of art see the separate entry on Goodman's Aesthetics.
## 1. Life
Henry Nelson Goodman was born on August 7, 1906, in Somerville, Massachusetts (USA), to Sarah Elizabeth (Woodbury) Goodman and Henry L. Goodman. In the 1920s he enrolled at Harvard University and studied under Clarence Irving Lewis (who later became his Ph.D. supervisor), Alfred North Whitehead, Harry Scheffer, W.E. Hooking, and Ralph Barton Perry. Goodman graduated from Harvard in 1928. It took him, however, 12 more years until he finished his Ph.D. in 1941 with A Study of Qualities (SQ). There are several possible reasons for the lateness of his Ph.D. Maybe the most important was that Goodman was Jewish, and therefore not eligible for a graduate fellowship at Harvard (Schwartz 1999; Elgin 2000a; Scholz 2005). He had to work outside the university to finance his studies. From 1928 until 1940, Goodman worked as the director of the Walker-Goodman Art Gallery at Copley Square, Boston. This interest and activity in the artworld is more frequently cited as a reason for the lateness of his Ph.D. During his graduate studies Goodman was also a regular participant in W.V. Quine's seminars on the philosophy of the Vienna Circle (in particular of Rudolf Carnap). Goodman also worked closely with Henry Leonard, who wrote his Ph.D. at the same time under Alfred North Whitehead's supervision. After military service, Goodman taught briefly as “instructor in philosophy” at Tufts College, and was then hired as associate professor (1946–51) and later as full professor (1951–64) at the University of Pennsylvania. He served briefly as Harry Austryn Wolfson Professor of Philosophy at Brandeis University (1964–67), finally returning to Harvard in 1968, where he taught philosophy until 1977. At Harvard, he founded Project-Zero, a center to study and improve education in the arts. Besides being an art gallery director as a graduate student, and private art collector throughout his life, Goodman was also involved in the production of three multimedia-performance events, Hockey Seen: A Nightmare in Three Periods and Sudden Death (1972), Rabbit, Run (1973), and Variations: An Illustrated Lecture Concert (1985) (Carter 2000, 2009).
Goodman was more interested in solving philosophical problems than in his celebrity as a philosopher. He authorized only two interviews (Goodman 1980, 2005), did not write an autobiography, and rejected the invitation to be honored with a volume in the prestigious Schilpp Library of Living Philosophers (Elgin 2000a: 2). Sparse bits of information about his personal life can only be gathered from the autobiographies of his contemporaries and their published correspondences (e.g., Quine 1985; Creath 1990) or his obituaries (e.g., Carter 2000; Elgin 1999 (Other Internet Resources), 2000a, 2000b; Elgin et al. 1999; Mitchell 1999; Scheffler 2001; Scholz 2005; Schwartz 1999). Goodman died on November 25, 1998, in Needham, Massachusetts, at the age of 92, after a stroke.
## 2. Anti-Absolutism
Nelson Goodman's philosophy synthesizes German/Austrian Logical Empiricism, as developed and practiced by philosophers like Rudolf Carnap and Carl Hempel, with American Pragmatism of the kind practiced and advocated by C.I. Lewis. Goodman, however, departs from both traditions considerably. As we will see, he departs from Lewis' pragmatism in dismissing the idea of an indubitable given in experience. He departs from logical empiricism in giving up a principled analytic/synthetic distinction.
### 2.1 The Myth of the Given in Experience
Goodman's philosophy—especially his epistemology—is usually considered to be in opposition to the philosophy of the Logical Positivists, and of Rudolf Carnap in particular. But this characterization overlooks an important continuity between the philosophy of the Logical Positivists and Goodman's work. The received view, that Goodman's main work, The Structure of Appearance was intended as an anti-foundationalist reconception of Carnap's Der logische Aufbau der Welt (cf. Elgin 2001; Hellman 1977) is particularly misleading here.
In fact, Goodman was quite aware that Carnap's work was itself anti-foundationalist in the same respect as his. Already in his dissertation thesis A Study of Qualities (which was later developed into The Structure of Appearance), Goodman writes:
[…] Carnap has made it clear that what we take as ground elements [for a constitutional system] is a matter of choice. They are not dignified as the atomic units from which others must be built; they simply constitute one possible starting point. […] In choosing erlebs, Carnap is plainly seeking to approximate as closely as possible what he regards the original epistemological state […] Yet whether it does so or not is no test of the system. […] Hence […] argument concerning whether the elements selected are really primitive in knowledge is extraneous to the major purpose of the system. (SQ: 96–98)
The quote makes it obvious that Goodman himself did not consider his constructionalist approach in A Study of Qualities as an epistemological alternative to Carnap's. Insofar as criticism of a foundationalist epistemology does play a role in The Structure of Appearance or A Study of Qualities, this criticism was rather directed at the philosophy of C.I. Lewis, who was Goodman's teacher at Harvard. Lewis indeed held the view that empiricism must presuppose the incorrigibility and indubitability of what is given in experience. According to Lewis, I might need to revise, for example, that I saw a plane crossing the sky when I learn that what I mistook for a plane was Superman. However, nothing can make me revise that there was a blue and a red spot in the center of my visual field that then led to the (false) belief that there was a plane.
A Study of Qualities, on the other hand, begins with the argument that even the simplest judgments of this sort—as the one about a blue and a red spot in the center of my visual field—might be revised in the light of new evidence. My judgment that I had a blue spot in the middle of my visual field a few seconds ago when I looked at a ripe apple under normal conditions might be revised when I now judge that I have a red spot in my visual field, looking at the same object under the same conditions and know that it could not have changed its color. However, if such revisions can be made in retrospect, nothing of the “given” is indubitable or incorrigible. Judgments about qualia, in this sense, are decrees; which judgments are accepted is a matter of the overall coherence of my system of beliefs and my other qualia judgments.
The literal unverifiabilty of such quale-recognition is, nevertheless, in the last analysis beyond question. If I say the green presented by that grass now is the same as the green presented by it at a certain past moment, I cannot truly verify that statement because I cannot revive that past moment. The statement therefore constitutes an arbitrary and supreme decree. But a decree, simply because it is arbitrary, is not therefore necessarily haphazard. My quale-identifications are influenced; I do not feel equally inclined to identify the color presented by the grass now with the color presented by a cherry a moment ago, though such a decree if made would be equally supreme and unchallengeable on strict grounds. We are all much in the same position of absolute but sane monarchs; our pronouncements are law, but we use our heads in making them. (SQ: 17; cmp. SA (2nd ed.): 134)
Also in this respect Goodman is following Carnap and the logical empiricists. C.I. Lewis emphasizes this in his “Logical Positivism and Pragmatism” (Lewis 1941). There he explains that the main difference between the empiricism of the pragmatists and the empiricism of the logical positivists (especially the Carnap of Philosophy and Logical Syntax (1935)) is that the latter were ready to analyze empirical knowledge fully in the so-called “formal mode”. Accordingly, they analyze empirical knowledge as more or less coherent systems of accepted sentences, some of which are “protocols”, some are sentences of mathematics and logic, some are generalizations, etc. In particular, the formal mode would not distinguish between statements such as “This object looks red” and “This object is red”.
For Lewis, this sort of empiricism is not worthy of the name. After all, the experiential element does not seem to show up at all in this kind of formal analysis. Lewis claims instead that a proper empiricism must treat sentences of the form “This looks red.” as special, indubitable statements. We might err when classifying things as being red, but we cannot err when it comes to recognizing things as looking red. This is “the given” in experience, the phenomenal states we find ourselves in when making experiences. Without such an indubitable element, Lewis fears that our epistemology would necessarily collapse into a coherence theory of truth (Lewis 1952). Goodman, on the other hand, is ready to bite that bullet when throwing away the indubitable given. Lewis, the major advocate of pragmatism, comments on this move by Goodman that his “proposal is, I fear, a little more pragmatic than I dare to be” (Lewis 1952: 118).
Indeed, Goodman's early and later philosophy is anti-foundationalist. This is truly a characteristic of his work on induction, metaphysics, logic and even the languages of art. It should, however, not be interpreted as a counter program to logical positivism. What Goodman did—in all these areas—is better understood as a continuation and enlargement of Carnap's program. This is obvious if we consider Goodman's relativism and irrealism. It is also apparent when we think about his pluralism in logic and his insistence that there are more cognitively valuable representation systems than just the sciences, namely the languages of art.
His anti-foundationalism therefore is more than just a restatement that there is no “bedrock” for knowledge—as was argued by Karl Popper and Otto Neurath, but also that there are no fundamental ontological objects, that there are no fundamental logical principles, and that there are no privileged representation systems. All of these echo Rudolf Carnap's famous Principles of Tolerance (Carnap 1934): tolerance with regards to ontology, to logical principles, and to representation systems in general.
### 2.2 The Analytic/Synthetic Distinction and Likeness of Meaning
Goodman did, however, considerably depart from the logical positivists in denying the comprehensibility of the analytic/synthetic distinction. This rejection and Goodman's gradual account of synonymy (or, rather, likeness of meaning) developed out of an exchange of letters between Morton White, Quine, and Goodman, which is also the historical background of Quine's famous “Two Dogmas of Empiricism” (Quine 1951a).
On 25 May 1947, Morton White wrote a letter to Quine asking for advice on a paper in which he tried to deal with a solution to C.H. Langford's paradox of analysis proposed by Alonzo Church. White was especially unhappy with Church's invocation of abstract objects in order to explicate the notion of synonymy. White sent his discontentment with the proposed solution to Quine (White's original paper appeared in print in 1948 under the title “On the Church–Frege Solution of the Paradox of Analysis”) and then sent Quine's answer to Goodman. In 1947 the three discussed the matter by letter, until White was eventually chosen to write a survey of their discussion, which appeared in 1950 under the title “The Analytic and the Synthetic: An Untenable Dualism”. Quine presented his view on the matter in an address to the American Philosophical Association, which was published in 1951 as “Two Dogmas of Empiricism” (Quine 1951a).
At that time the postulation of new abstract objects, such as Fregean senses or other intensional objects, in order to explicate a certain notion of synonymy seemed an unacceptable move for someone with nominalist leanings such as Quine and a purist such as White. For Quine, an explication of “synonymy” or “analyticity” and the like should rather be given in behavioristic terms. The explication should tell us in what way “analyticity” and “synonymy” make a difference in speaker behavior. To learn that the difference lies in postulated abstract objects did not seem to explicate the notions in any promising way.
Goodman's original discontentment with the whole situation was more serious. In a letter to White and Quine he claimed that not only did he find the explications of “synonymy” and “analyticity” so far provided to be problematic, but he did not even understand what these terms were supposed to mean pre-theoretically:
When I say I don't understand the meaning of “analytic” I mean that very literally. I mean that I don't even know how to apply the terms. I do not accept the analogy with the problem of defining, say, confirmation. I don't understand what confirmation is, or let us say projectibility, in the sense that I can't frame any adequate definition; but give me any predicate and (usually) I can tell you whether it is projectible or not. I understand the term in extension. But “analytic” I don't even understand this far; give me a sentence and I can't tell you whether it is analytic because I haven't even implicit criteria…. I can't look for a definition when I don't know what it is I am defining. (Goodman in a letter to Quine and White, 2 July 1947, in White 1999: 347)
Goodman's remark is instructive, since it undermines a move that Grice and Strawson would later make against Quine's argumentation in “Two Dogma's of Empiricism”. In their “In Defense of a Dogma” (Grice and Strawson 1956) they argue that Quine's skepticism about the analytic-synthetic distinction as such is undermotivated in light of our pre-theoretic grasp of the distinction. Goodman's claim is that there in fact is no such pre-theoretic grasp of the distinction.
The official result of the exchange between White, Goodman, and Quine was that any sharp analytic–synthetic distinction is untenable and should just be abandoned:
I think that the problem is clear, and that all considerations point to the need for dropping the myth of a sharp distinction between essential and accidental predication (to use the language of the older Aristotelians) as well as its contemporary formulation—the sharp distinction between analytic and synthetic. (White 1950: 330)
Goodman's view on the matter had already appeared in print in 1949 under the title “On Likeness of Meaning”. In this paper Goodman proposes a purely extensional analysis of meaning, the upshot of which is that no two different expressions in a language are synonymous. He discusses several objections to theories of meaning that rely on intensional entities (such as, for example, Fregean senses) to explicate the notion of synonymy in non-circular ways, such that the question of whether two terms are “synonymous” is comprehensible as well as scrutable. Goodman eventually rejects intensional approaches and opts for an extensional theory for sameness of meaning. According to such an extensional theory, two expressions have the same meaning if and only if they have the same extension. This criterion is certainly intelligible, but also scrutable; we can
decide by induction, conjecture, or other means that two predicates have the same extension without knowing exactly all the things they apply to. (PP: 225)
But an extensional theory is, of course, not thereby free of problems. Consider, for example, the expression “unicorn” and “centaur”, which have the same extension (namely the null-extension) but differ in meaning. Hence, whereas sameness of extension is a necessary condition for sameness of meaning, sameness of extension does not seem to be sufficient for sameness of meaning. Goodman proposes an extensional fix to this problem that gives necessary and sufficient conditions for sameness of meaning. He observes that although “unicorn” and “centaur” have the same extension, simply because of the trivial fact that they denote nothing, “centaur-picture” and “unicorn-picture” do have different extensions. Clearly, not all centaur-pictures are unicorn-pictures and vice versa. Thus the flight to compounds makes an extensional criterion possible:
[I]f we call the extension of a predicate by itself its primary extension, and the extension of its compounds as secondary extension, the thesis is as follows: Two terms have the same meaning iff they have the same primary and secondary extensions. (PP: 227)
The primary extensions of “unicorn” and “centaur” are the same (the null-extension), but their secondary extensions do differ: the compounds “unicorn-picture” and “centaur-picture” differ in extension.
If we allow all kinds of compounds equally, we arrive immediately at the result that by our new criterion no two different expressions have the same meaning. Consider the expressions “bachelor” and “unmarried man”: “is a bachelor but not an unmarried man” is a bachelor description that is not an unmarried-man description. Hence, by Goodman's criterion, the secondary extensions of “bachelor” and “unmarried man” differ because the primary extensions of at least one of their compounds do. Since the same trick can be pulled with any two expressions, Goodman is left with the result that no two different expressions are synonymous, but he is ready to bite this bullet. P-descriptions that are not Q-descriptions are easy to construct for any P and Q (provided these are different terms) and these constructions might well be relatively uninteresting. If only such uninteresting constructs are available to make a difference in secondary extension, P and Q, despite being not strictly synonymous, might be more synonymous than a pair of predicates for which we are able to find interesting compounds (as in the case of “centaur” and “unicorn”). This turns sameness of meaning of different terms into likeness of meaning, and synonymy and analyticity into a matter of degree.
## 3. Nominalism and Mereology
### 3.1 Nominalisms
“Nominalism” can refer to a variety of different, albeit related, positions. In most cases, it either refers to the rejection of universals or of abstract objects. What nominalism means for Goodman undergoes two radical changes. In his Ph.D. thesis, A Study of Qualities, he uses the label “nominalist” to describe constructional systems whose constructional basis does not include abstracta, such as Carnap's system in the Aufbau (Carnap 1928). Whether classes are used in the construction, as Carnap's Aufbau indeed does, is irrelevant for the characterization of these systems as “nominalist”. Nominalism is not an issue of discussion here; “nominalist” merely occurs as a classification (for more details on constructional systems see section 4 below.)
Goodman first endorses a nominalist position in his famous joint article with W.V. Quine, “Steps Toward a Constructive Nominalism” (1947). Goodman and Quine set the agenda in the very first sentence of the article: “We do not believe in abstract objects”. And they conclude the first paragraph: “Any system that countenances abstract entities we deem unsatisfactory as a final philosophy” (Goodman and Quine 1947: 105).
Goodman and Quine first discuss nominalistically acceptable reductions of platonist statements. “Platonist” here refers to the use of terms for classes, numbers, properties, and relations—in short, anything that is not a concrete particular. The first examples are straightforward and their resolutions are well-known today. “Class A is included in class B” can be rendered as “Everything that is an A is a B” (where “A” and “B” now stand for the appropriate predicates, rather than for classes). “Class C has two members”, or “The number of Cs is 2”, is rendered as “There are two Cs”, and spelt out formally (based on Russell's theory of definite descriptions – see the discussion in the entry on Russell) as:
$\exists x \exists y(x \ne y \land \forall z(Cz \equiv (z = x \lor z = y)))$
No recourse to classes or other abstract entities (e.g., numbers) is necessary. However, this strategy does not deliver a general recipe to account for statements that are typically expressed in a straightforward set-theoretic way. For instance, it seems to Goodman and Quine that there is no general recipe for expressing statements like “There are more cats than dogs” in a nominalistically acceptable fashion. If the total number of dogs were known, then, in principle, the quantifier strategy above could be used—albeit that, with hundreds of millions of dogs alive today, it would certainly not be practical. Quine and Goodman suggest a translation into the language of mereology with an additional auxiliary predicate “bigger than”; while this provides a surprisingly versatile solution for many cases, it is still not completely general (Goodman and Quine 1947: 110–11). Further, a general definition of the ancestral of a relation (as first given by Gottlob Frege 1879: §26) seemed to Quine and Goodman at the time to be out of reach for the nominalist. Leon Henkin (1962: 188–89) finds an elegant solution, quantifying over lists of successive inscriptions. Goodman later (PP: 153) suggests that his technique to formulate the ancestral of matching (SA: §§IX–X) could also solve the problem. We note that if second-order logic can be made palatable to the nominalist—perhaps by adopting a plural interpretation of second-order logic (Boolos 1984, 1985), or a proof-theoretic semantics, or in any other way—Frege's original definition (which is not formulated in set theory, but in his version of second-order logic) can be employed (Rossberg and Cohnitz 2009).
Even though these two particularly pressing gaps appear to be capable of being closed, a general recipe for recasting platonist statements appears out of reach, in particular, when we consider statements of pure mathematics itself. Without such a nominalist recasting, Goodman and Quine hold, platonist mathematical statements cannot be deemed intelligible from a strictly nominalist perspective. The question becomes, according to Goodman and Quine,
how, if we regard the sentences of mathematics merely as strings of marks without meaning, we can account for the fact that mathematicians can proceed with such remarkable agreement as to methods and results. Our answer is that such intelligibility as mathematics possesses derives from the syntactical or metamathematical rules governing those marks. (Goodman and Quine 1947: 111)
Goodman and Quine construct a theory of syntax for the set-theoretic language and a proof theory based on the Calculus of Individuals (see section 3.2 below) supplemented with a token-concatenation theory. The tokens in question are concrete, particular inscriptions of the logical symbols, variable-letters, parentheses, and the “$\in$” (for set-membership) that are use to formulate the language of set theory. Primitive predicates are introduced to categorize the different primitive symbols: all concrete, particular “$\in$”-inscriptions, for instance, fall under the predicate “Ep”. Concrete complex formulae, e.g., “$x \in y$”, are concatenations of concrete primitive symbols—in our case the concatenation of “x” and “$\in$” and “y”. Bit by bit, Goodman and Quine define their way up to which concrete inscriptions count as correctly formed sentences of the language of set theory, and finally which concrete inscriptions count as proofs and theorems. Goodman and Quine argue that in this way the nominalist can explain the “remarkable agreement” of mathematicians mentioned above.
Since Quine and Goodman not only impose nominalistic strictures, but also finitism in their joint article (Quine and Goodman 1947: §2), the syntactic and proof-theoretic notions defined still fall short of the usual platonist counterparts. Even if any given sentence or proof is finite in length, the platonist would hold that there are sentences and proofs of any finite length, and thus sentences and proofs that are too long to have a concrete inscription in a given finite universe. Moreover, there are infinitely many (and indeed uncountably many) truths of mathematics, but—in particular, in a finite universe—there will only ever be finitely many inscriptions of theorems. Even if the universe is in fact infinite, perhaps a theory of syntax and proof should not make itself hostage to this circumstance.
Platonists and nominalists will likely disagree whether Goodman and Quine successfully argue their case in their joint paper. Goodman and Quine will be able to account for any actual mathematical proof and any theorem actually proven, since there are at any stage only finitely many of them, each of which is small enough to fit in our universe comfortably. Thus, arguably, they reach their goal of explaining the agreement in mathematical practice without presupposing mathematical platonism. Due to its finitistic nature, however, the account radically falls short of giving explications that are extensionally equivalent to the platonists' conceptions (see Rossberg and Cohnitz 2009 for discussion and a landscape of possible solutions). Goodman later (1956) explains that nominalism is not incompatible with the rejection of finitism; it is
at most incongruous […]. The nominalist is unlikely to be a non-finitist only in much the way a bricklayer is unlikely to be a ballet dancer. (PP: 166; on the question of finitism see also MM: 53; Field 1980; Hellman 2001; Mancosu 2005)
Given the ardent pronouncements in the 1947 article with Quine, the common misunderstanding that Goodman's mature nominalism encompasses, or is motivated by, the rejection of abstract objects is understandable. Nonetheless, it is incorrect. Goodman does not reject all abstract objects: in The Structure of Appearance, he embraces qualia as abstract objects (see section 4 below), some of which (in fact all but moments) are universals (SA: §VII.8). Goodman's mature nominalism, from The Structure of Appearance onwards, is a rejection of the use of sets (and objects constructed from them) in constructional systems, and no blanket rejection of all universals or abstract particulars. To be sure, Goodman also refuses to acknowledge properties and other non-extensional objects, but the reason for his rejection of such entities is independent, and in fact more fundamental, than his nominalism: it is his strict requirement of extensionality (WW: 95n3; see also section 6 below). Goodman does occasionally include extensionalism in his nominalism (see LA: xiii, 74; under the entry “nominalism” the index of LA references some passage which discusses properties ; see also MM: 51; WW: 10n14). Strictly speaking, however, nominalism for Goodman is the refusal to use class terms in a constructional system—no more, and no less.
Goodman presents two positive considerations for the rejection of a set-theoretic language (not counting the remarks in Goodman and Quine 1947: 105). Methodologically, nominalistic constructions have the advantage that they do not use any resources that the platonist could not accept (Goodman 1958; PP: 171). The advantage of a nominalistic construction is thus one of parsimony:
As originally presented in A Study of Qualities […] the system was not nominalistic. I feel that the recasting to meet nominalistic demands has resulted not only in a sparser ontology but also in a considerable gain in simplicity and clarity. Moreover, anyone who dislikes the change may be assured that the process of replatonizing the system—unlike the converse process—is obvious and automatic; and this in itself is an advantage of a nominalistic formulation. (SA: Original Introduction, page L of the 3rd. ed.; regarding the simplicity remark see SA: §III.7)
All resources employed by the nominalist are (or should be) acceptable to the platonist, while the converse may not be the case (see also Goodman 1956: 31 (PP: 171); MM: 50).
By the time he writes The Structure of Appearance, Goodman has come around to a different criterion for whether or not a system obeys nominalistic structures: the predicates present in the whole system (SA: §II.3). This is as opposed to merely considering the basis of the system in answer to this question as he does in A Study of Qualities (as mentioned above). In Goodman 1958 (see also SA: §III.7), he suggests a different, perhaps more precise, way to characterize nominalistic systems in terms of the system's generating relation:
System S is nominalistic iff S does not generate more than one entity from exactly the same atoms of S.
Goodman describes the criterion as demanding that “sameness of content” entails identity. Systems that have only mereological means of “generating” composite objects (see section 3.2 Mereology below) count as nominalistic according to this criterion. Parthood is transitive, so from atoms a and b only one further object can be “generated”, the mereological sum of a and b. A set-forming operation, however, will distinguish, for instance, between {a, b} (the set of a and b) and {{a, b}} (the set containing the set of a and b) and {{a}, {b}} (the set containing the singleton set of a and the singleton set of b). None of the these three are pairwise identical. Membership is not transitive. The first and third contain two members, but not the same members (both a and b are members of the first set, but not of the third), while the second set has only one member (namely the first set). All three (and infinitely many others) are generated from the same atoms, however, or as Goodman might put it, they have the same content: a and b. A system featuring a set-theoretic generating relation thus does not count as nominalistic.
The sameness-of-content criterion was criticized by David Lewis (1991: 40) as question-begging. Lewis suggests that the only alternatives for generating relations that Goodman allows are mereological, set-theoretical, or a combination of the two, and that only mereological generation passes the test. Unless one rejects set theory already, Lewis contends, one would not find the criterion plausible. There are, however, non-extensional mereological systems that violate the sameness-of-content criterion as well (see entry on mereology). Moreover, the sameness-of-content criterion may be understood as a version of Ockham's Razor, demanding not to multiply entities beyond necessity.
### 3.2 Mereology
The Polish logician Stanisław Leśniewski (1886–1939) must surely count as the father of mereology—the theory of parts and wholes—but around 1930, Goodman re-invents the theory together with his fellow graduate student Henry S. Leonard (1905–1967). Only in 1935 do Goodman and Leonard learn of Leśniewski's work through one of their fellow students, W.V. Quine (Quine 1985: 122). An early version of Leonard and Goodman's system is contained in Leonard's Ph.D. thesis, Singular Terms (Leonard 1930). In 1936, Leonard and Goodman present their mature system at a meeting of the Association of Symbolic Logic; the corresponding paper is published four years later under the title “The Calculus of Individuals and Its Uses” (Leonard and Goodman 1940). Subsequently, Goodman uses the calculus in his own Ph.D. thesis, A Study of Qualities (SQ), and a version of it in The Structure of Appearance (SA). Little is known about the nature of Goodman and Leonard's cooperation on the calculus. Goodman attributes the first thought for the collaborative project to Leonard (PP: 149). Leonard, more concretely, suggests in a (still) unpublished note:
If responsibilities can be divided in a collaborative enterprise, I believe that it may be fairly stated that the major responsibility for the formal calculus […] was mine, while the major responsibility for discussions of applications […] lay with Goodman. (Leonard 1967)
Quine only mentions that he himself “was able to help them on a technical problem” (Quine 1985: 122). Leonard's system of Singular Terms is significantly different from, and indeed in philosophically interesting ways weaker than, the Calculus of Individuals (Rossberg 2009), but the exact extent of Goodman's technical contribution to the calculus remains unknown.
Perhaps surprisingly, nominalistic scruples were not the driving force behind the development the Calculus of Individuals. Instead, their goal is to solve a technical problem in Carnap's Aufbau (1928) (see section 4 below), and to this end they employ both set-theoretic and mereological notions. Leonard, in his Ph.D. thesis (supervised by Alfred North Whitehead), presents his calculus as “an interpolation in Whitehead and Russell's Principia Mathematica between *14 and *20” (Leonard 1967), and makes liberal use of class-terms in the formulation (Leonard 1930). Also the joint paper of Leonard and Goodman is formulated using class terms, as is the system Goodman used in his own Ph.D. thesis, A Study of Qualities (1941, SQ). It is not until his joint article with Quine (Goodman and Quine 1947) and his Structure of Appearance (1951, SA) that Goodman eschews the use of set theory to formulate the Calculus of Individuals.
As mentioned above, parthood, as opposed to the set-theoretic notion of membership, is transitive: if a is a part of b and b is a part of c, then a is a part of c. Neither the system Leonard and Goodman present in their 1940 article, nor the version in Goodman's A Study of Qualities, nor the calculus he uses in The Structure of Appearance, take “part” as primitive. Rather, it is in all three cases defined based on the sole primitive notion adopted: overlap in SA, and discreteness in the other two systems. Overlap can pre-systematically be understood as sharing a part in common; discreteness as sharing no part in common. All three systems indeed define parthood so that these two pre-systematic understandings come out as theorems.
The Calculus of Individuals in all its formulations contains principles of mereological summation and mereological fusion. Mereological summation is a binary function of individuals, so that the sum s of two individuals a and b is such that both a and b, and all their parts, are parts of s—and also all sums of parts of a and b and are parts of s. Mereological fusion is a generalization of the mereological summation. In Leonard and Goodman 1940 fusion is defined using sets: all the members of a set α are “fused” in the sense that they, and all their parts, and all the fusions amongst their parts, end up being parts of the individual that is the fusion of set α.
The technical details of the different versions of the Calculus of Individuals can be found in this supplementary document: The Calculus of Individuals in its different versions (see also entry on mereology).
Unrestricted mereological fusion has been widely criticized as too permissive. It allows for so-called scattered objects (e.g., the sum of the Eiffel Tower and the Moon) and in the case of Goodman's construction in The Structure of Appearance for sums of radically different kinds of objects, like sounds and colors. W.V. Quine, after endorsing this principle in a joint paper with Goodman (Goodman and Quine 1947), becomes one of its first critics in his review of The Structure of Appearance:
part, clear initially as a spatio-temporal concept, is here understood only by spatio-temporal analogy. […] When finally we proceed to sums of heterogeneous qualia, say a color and two sounds and a position and a moment, the analogy tries the imagination. (Quine 1951b: 559)
Goodman (1956) maintains that the criticism is disingenuous if put forward by a platonist: set-theoretic “composition” is as least as permissive as mereological fusion. Whenever there is a fusion of scattered concrete objects, there is also a set of them (see Simons 1987 or van Inwagen 1990 for prominent criticisms of unrestricted composition).
## 4. The Structure of Appearance
The Structure of Appearance is perhaps Goodman's main work, although it is less widely known than, for example, Languages of Art. It is, in fact, a heavily revised version of Goodman's Ph.D. thesis, A Study of Qualities. SA is a constitutional system, which, just like Rudolf Carnap's Der logische Aufbau der Welt, shows how from a basis of primitive objects and a basic relation between those objects all other objects can be obtained by definitions alone. We commented above already on the anti-foundationalist nature of both Carnap's and Goodman's constitutional systems. For them, the point of carrying out such a construction was not to provide a foundationalist reduction to some privileged basis (of experience or ontology), but rather to study the nature and logic of constitutional systems as such. In this sense, Goodman's interest in other “world versions”, such as the languages of art, should be seen as a continuation of his project in SA.
### 4.1 Goodman on Analysis
Because Goodman is interested in the nature and logic of constitutional systems as such, he begins his discussion in The Structure of Appearance with meta-theoretical considerations. Since the project of SA is to develop a constitutional system that defines other notions from a predetermined basis, the question is which conditions of adequacy should be in place for evaluating the definitions. Constitutional systems are systems of rational reconstruction, i.e., the concepts, objects, or truths that get constituted by definition from the basis are supposedly counterparts of concepts, objects or truths that we accept already pre-theoretically.
One might think that such a reconstruction is only successful if definiens and definienda are synonymous. However, Goodman argues that the definiens of an accurate definition need have neither the same intension nor even the same extension as the definiendum; thus, taking as an example Alfred North Whitehead's analysis of geometrical points, points in space may be defined equally well as certain classes of straight lines or as certain infinite convergent sets of concentric spheres; but these alternative definientia are neither cointensive (synonymous) nor coextensive with each other. A set of sets of straight lines is just not the same set of objects as a set of infinite convergent sets of concentric spheres. Hence, their accuracy notwithstanding, the respective definitions are not coextensive with, let alone synonymous with, the definiendum. Accuracy of constructional definitions amounts to no more than a certain homomorphism of the definiens with the definiendum. This means that the concepts of the constructional system must provide a structural model for the explicanda in the sense that for every connection between entities that is describable in terms of the explicanda, there must obtain a matching connection, stateable in terms of the respective explicata or definientia, among the counterparts that the entities in question have within the system. In this way the two different definitions of “point” serve their purpose equally well. The objects in the sets generated—although being very different in kind—stand in just the right relations to one another within the sets to serve as an explicatum for “point” as geometry demands. This rather pragmatic criterion of adequacy for philosophical analyses serves Goodman well for a number of reasons. The most important is perhaps that Goodman does not believe there was any such thing as identity in meaning of two different expressions (see our discussion of likeness of meaning above). Thus, if synonymy was made the criterion of adequacy, no analysis could ever satisfy it. But relaxing the criteria of adequacy for philosophical analyses to structure-preservation also supports Goodman's more radical theses in epistemology and metaphysics, especially in his later philosophy. One of his reasons to replace the notion of truth with that of “rightness of symbolic function”, the notion of certainty with that of “adoption”, and the notion of knowledge with that of understanding is the thought that the new system of concepts preserves the structural relations of the old without preserving the philosophical puzzles related to truth, certainty and knowledge (RP: chapter X).
### 4.2 The Critique of Carnap's Aufbau
Goodman's predecessor in studying a constitutional system by the means of modern formal logic is, as we already said, Rudolf Carnap, who follows a very similar project as Goodman in his Der logische Aufbau der Welt (Carnap 1928). In this book Carnap investigates the example of a world built up from primitive temporal parts of the totality of experiences of a subject (the so-called “elementary experiences” or just “erlebs”) and thus faces the problem of abstraction: how can qualities, properties and their objects in the world be abstracted from our phenomenal experiences.
Carnap tries to show that by using the method of “quasi-analysis” all the structure can be retained from the basis if the “erlebs” are ordered by a simple relation of part-similarity. Very roughly, the idea is that, although the individual temporal slices of our totality of experience are not structured (and thus have no parts), we can, via quasi-analysis, get to their quasi-parts, the “qualities” they share with other time-slices with which they are part-similar. Of course, time slices of the totality of our experiences can be part-similar with each other in a variety of ways. Perhaps two slices are similar with respect to what is in our visual field at the time in question, or they are similar with respect to what we hear or smell. However, since the time-slices are primitives in the system, we cannot yet even talk about these respects or ways in which the slices should be similar in order to, for example, be considered experiences of the same color. Carnap's ingenious idea is to group exactly those erlebs together that are mutually part-similar, thereby grouping exactly those that share (pre-theoretically speaking) a property. For simple cases the quasi-analysis seems to give exactly the right results. Consider the following group of erlebs that, pre-theoretically have different colors.
However, we do not yet know that there are such things as colors. In fact the only thing we know about the erlebs (AF) is that they are part similar as displayed in the following graph (where part-similarity between erlebs is indicated by a line):
If we take the graph and now group exactly those erlebs together that are mutually part-similar, we get the following sets:
$\{A, B, C, F\}, \{A, E, F\}, \{C, D, F\}$
But, of course, these sets correspond exactly to the extensions of the colors in our example (viz. black, green, and red). Thus, by knowing about the part-similarity between erlebs alone, we seem to be able to reconstruct their properties with the method of quasi-analysis.
Goodman observes, however, that in unfavorable circumstances quasi-analysis will lead to the wrong results. Consider the following situation:
This corresponds to the following graph:
If we use Carnap's rule for quasi-analysis, we will obtain all color classes except $\{A, E, F\}$, the color class for “green”, because green only occurs in “constant companionship” with the color “black”. Goodman calls this the “constant companionship difficulty”.
A second problem can be illustrated with the following example of erlebs:
This corresponds to this graph:
But here $\{A,C,F\}$ should be a color class resulting from quasi-analysis, although A, C, and F have in fact no color in common. Goodman calls this problem “the difficulty of imperfect community”. It is controversial to what extent these problems are devastating for Carnap's project, but Goodman considered them to be serious.
### 4.3 Goodman's Own Construction
In contrast to Carnap, Goodman begins from a realist basis, considering the example of a system built on phenomenal qualities, so-called qualia (phenomenal colors, phenomenal sounds, etc.) and thus faced the problem of concretion: how can concrete experiences be built up from abstract particulars?
In the visual realm, a concretum is a color-spot moment, which may be construed as the sum of a color, a visual-field place and a time, all of which stand in a peculiar relation of togetherness. Goodman adopts this relation as a primitive and then shows how, by means of it, it is possible to define the concept of the concrete individual as well as the various relations of qualification in which qualia and certain sums of qualia stand to the fully or partially concrete individuals that exhibit them.
After this is done, Goodman faces his second major constructional objective. He has to order the qualia into different categories. The problem is to construct for each of the categories (color, time, place, and so forth) a map that assigns a unique position to each quale in the category, and that represents the relative likeness of qualia by nearness in position. The solution to the problem requires in each case the specification of a set of terms by means of which the order at hand can be described, and then the selection of primitives suitable to define them. Goodman thereby shows how predicates referring to size and shape of phenomenal concreta may be introduced, and he suggests briefly some approaches to the definition of the different categories of qualia by reference to their structural characteristics.
Goodman shows in SA how using a mereological system can help to avoid the difficulty of imperfect community for a system built on a realist base (such as SA), as well as for a system built on a particularistic base (such as Der logische Aufbau der Welt). The constant companionship difficulty, on the other hand, does not arise in SA because no two concreta can have all their qualities in common.
### 4.4 The Significance of The Structure of Appearance
Very many of the side issues dealt with in A Study of Qualities and The Structure of Appearance reappear in Goodman's later philosophy. The “grue”-problem (to be explained in the next section) as a problem of what predicates to use for projection and the related problem of how to analyze disposition predicates, as well as the question of how to explicate simplicity, tense, aboutness, and so on, all have their roots in Goodman's dissertation. Alas, his most important work is also his most complicated, which is perhaps the reason why it is so often ignored. Other writings by Goodman are seemingly more accessible and have thus attracted a wider readership. However, it is arguable that the significance of Goodman's “easier” pieces cannot be assessed adequately without relating them to the problems and projects of A Study of Qualities and The Structure of Appearance.
## 5. The Old and the New Riddle of Induction and their Solution
### 5.1 The Old Problem of Induction is a Pseudo-problem
The old problem of induction is the problem of justifying inductive inferences. What is traditionally required from such a justification is an argument that establishes that using inductive inferences does not lead us astray. Although it seems to be a meaningful question whether there is such a justification for our inductive practices, David Hume argues that there can be no such justification (Hume [1739–40] 2000; see the discussion of Hume in the entry on the probelm of induction). It is important to understand that Hume's argument is general. It is not just an argument against a particular attempt to justify induction in the sense above, but a general argument that there can be no such justification at all.
In order to see the generality of this argument, we have to note that the same problem also arises for deduction (FFF: §III.2). That deduction is in the same predicament is observed by Goodman and exploited for his solution of Hume's problem of induction. Thus the upshot of Goodman's understanding of Hume's argument is that there can be no justification of our inferential practices, if such a justification requires a reason for their justifiedness. Accordingly, the old problem of induction, which requires such a justification of induction, is a pseudo-problem.
### 5.2 Hume's Problem, Logic, and Reflective Equilibrium
If the problem of induction is not how to justify induction in the sense mentioned above, then what is it? It is helpful here to look at the case of deduction. Instances of deductive inferences are justified by showing that they are inferences in accordance with valid rules of inference. According to Goodman, the rules of logic are in turn valid because they are more or less in accordance with what we intuitively accept as instances of a valid deductive inference (FFF: 64).
On the one hand, we have certain intuitions about which deductive inferences are valid; on the other hand we have rules of inference. Confronted with an intuitively valid inference, we check whether it accords to the rules we already accept. If it does not, we might reject the inference as invalid. If, however, our intuition that the purported inference is valid is stronger than our confidence that our logical rules are adequate, we might consider amending the rules. This soon leads to a complicated process. We have to take into account that the rules must remain coherent and not too complicated to apply. In logic, we want the rules to be, for example, topic neutral, i.e., applicable to inferences (as far as possible) independent of specific subject matter. On the other hand, we also want to extract as much information from premises as possible, so we do not want to risk being too cautious in accepting rules. In this process we make adjustments on both sides, slowly bringing our judgments concerning validity into a reflective equilibrium with the rules for valid inferences until we finally get a stable system of accepted rules. (The term “reflective equilibrium” was introduced by John Rawls (1971) for Goodman's technique.)
Reflective equilibrium is a story about how we actually justify our inferential practices. According to Goodman, nothing more can be demanded or achieved. It seems, perhaps, prima facie desirable that we also seek a justification in the sense of the old problem, but Hume's argument suggests that such a justification is impossible. If this is correct, the remaining problem is to define our inferential practices by bringing explicit rules into reflective equilibrium with our tutored intuitions. “Justified” or “valid” are predicates that are applied to inferences on this basis.
It thus also becomes clearer how Goodman thought about Hume's solution—that induction is merely a matter of custom or habit. Hume's solution might be incomplete, but it is basically correct. The remaining task is then to explicate the pre-theoretic notion of valid inductive inference by defining rules of inference that can be brought into a reflective equilibrium with intuitive judgments of inductive validity.
### 5.3 The New Riddle of Induction
Before presenting Goodman's solution, we first have to discuss Goodman's own challenge, the so-called “New Riddle of Induction”.
Consider the following two (supposedly true) statements:
• (B1) This piece of copper conducts electricity.
• (B2) This man in the room is a third son.
B1 is a confirmation instance of the following regularity statement:
• (L1) All pieces of copper conduct electricity.
But does B2 confirm anything like L2?
• (L2) All men in this room are third sons.
Obviously, it does not. But what makes the difference? Both regularity statements (L1 and L2) are built according to the exact same syntactical procedure from the evidence statements. Therefore, it does not seem to be for a syntactical reason that B1 confirms L1 but B2 fails to confirm L2. Rather, the reason is that statements like L1 are lawlike, whereas statements like L2 at best express accidentally true generalizations. Lawlike statements, in contrast to accidentally true general statements, are confirmed by their instances and support counterfactuals. L1 supports the counterfactual claim that if this thing I have in my hand were a piece of copper, it would conduct electricity. In contrast, supposing that it is indeed true, L2 would not support that if an arbitrary man were here in the room, he would be a third son. To tell which statements are lawlike and which statements are not is therefore of great importance in the philosophy of science. A satisfactory account of induction (or corroboration -- see the discussion of Popper in the entry on the problem of induction) as well as explanation and prediction requires this distinction. Goodman, however, shows that this is extremely hard to get.
Here comes the riddle. Suppose that your research is in gemology. Your special interest lies in the color properties of certain gemstones, in particular, emeralds. All emeralds you have examined before a certain time t were green (your notebook is full of evidence statements of the form “Emerald x found at place y date $z (z \le t)$ is green”). It seems that, at t, this supports the hypothesis that all emeralds are green (L3).
Now Goodman introduces the predicate “grue”. This predicate applies to all things examined before some future time t just in case they are green but to other things (observed at or after t) just in case they are blue:
• (DEF1) x is grue $=_{df}$ x is examined before t and green ∨ x is not so examined and blue
Until t it is obviously the case that for each statement in your notebook, there is a parallel statement asserting that the emerald x found at place y date $z (z \le t)$ is grue. Each of these statements is analytically equivalent with the corresponding one in your notebook. All these grue-evidence statements taken together confirm the hypothesis that all emeralds are grue (L4), and they confirm this hypothesis to the exact same degree as the green-evidence statements confirmed the hypothesis that all emeralds are green. But if that is the case, then the following two predictions are also confirmed to the same degree:
• (P1) The next emerald first examined after t will be green.
• (P2) The next emerald first examined after t will be grue.
However, to be a grue emerald examined after t is not to be a green emerald. An emerald first examined after t is grue iff it is blue. We have two mutually incompatible predictions, both confirmed to the same degree by the past evidence. We could obviously define infinitely many grue-like predicates that would all lead to new, similarly incompatible predictions.
The immediate lesson is that we cannot use all kinds of weird predicates to formulate hypotheses or to classify our evidence. Some predicates (which are the ones like “green”) can be used for this; other predicates (the ones like “grue”) must be excluded, if induction is supposed to make any sense. This already is an interesting result. For valid inductive inferences the choice of predicates matters.
It is not just that we lack justification for accepting a general hypothesis as true only on the basis of positive instances and lack of counterinstances (which was the old problem), or to define what rule we are using when accepting a general hypothesis as true on these grounds (which was the problem after Hume). The problem is to explain why some general statements (such as L3) are confirmed by their instances, whereas others (such as L4) are not. Again, this is a matter of the lawlikeness of L3 in contrast to L4, but how are we supposed to tell the lawlike regularities from the illegitimate generalizations?
An immediate reply is that the illegitimate generalization L4 involves a temporal restriction, just as L2 was restricted spatially (see e.g., Carnap 1947). The idea would be that predicates that cannot be used for induction are analytically “positional”, i.e., their definitions refer to individual constants (for places or times). A projectible predicate, i.e., a predicate that can be used for induction, has no definition which would refer to such individual constants but is purely qualitative (e.g., because it is a basic predicate). The trouble is that this reply makes it relative to a language whether or not a predicate is projectible. If we begin with a language containing the basic predicates “green” and “blue” (as in English), “grue” and “bleen” are positional. “Bleen” is defined as follows:
• (DEF2) x is bleen $=_{df}$ x is examined before t and blue ∨ x is not so examined and green
But if we start with a language that has “bleen” and “grue” as basic predicates, “green” and “blue” are positional:
• (DEF3) x is green $=_{df}$ x is examined before t and grue ∨ x is not so examined and bleen
• (DEF4) x is blue $=_{df}$ x is examined before t and bleen ∨ x is not so examined and grue
Both languages are symmetrical in all their semantic and syntactical properties. So the positionality of predicates is not invariant with respect to linguistically equivalent transformations. But if this is the case, there is no semantic or syntactic criterion on whose basis we could draw the line between projectible predicates and predicates that we cannot use for induction.
### 5.4 Goodman's Solution
Goodman's solution to the new riddle of induction resembles Hume's solution in an important way. Instead of providing a theory that would ultimately justify our choice of predicates for induction, he develops a theory that provides an account of how we in fact choose predicates for induction and projection. Goodman observes that predicates like “green” are favored over predicates like “grue”, because the former are much better entrenched, i.e., in the past we projected many more hypotheses featuring “green” or predicates co-extensional with “green” than hypothesis featuring the predicate “grue”. If two hypotheses are the same with respect to their empirical track-record, then the hypothesis that uses the better entrenched predicates overrides the alternatives. On the basis of these considerations, Goodman defines projectibility (and cognates) for hypotheses (FFF: 108):
A hypothesis is projectible iff it is supported, unviolated, and unexhausted, and all hypotheses conflicting with it are overridden.
A hypothesis is unprojectible iff it is unsupported, exhausted, violated, or overridden.
A hypothesis is nonprojectible iff it and a conflicting hypothesis are supported, unviolated, unexhausted, and not overridden.
The last definition takes care of situations when we are confronted with two hypotheses that are in conflict and neither has a better entrenched predicate. Entrenchment can even be further refined to account for cases in which a predicate inherits the entrenchment from another of which it is derivative. (The critical literature on Goodman's New Riddle is too extensive to do it justice here; see Stalker 1994 and Elgin 1997c for selections of important essays on the topic. Stalker 1994 also contains an annotated bibliography, comprising over 300 entries. The discussion of course continued after the 1990s and the literature is still growing.)
Goodman's solution makes projectibility essentially a matter of what language we use and have used to describe and predict the behaviour of our world. However, this language-, or better version-relativism is just another aspect of Goodman's irrealism.
## 6. Irrealism and Worldmaking
### 6.1 Irrealism
Goodman labels his own position “irrealism”. Irrealism, roughly, is the claim that the world dissolves into versions. Goodman's irrealism is certainly the most controversial aspect of his philosophy.
Two lines of argument can be separated in Goodman's writings (Dudau 2002). First, Goodman argues that there are conflicting statements that cannot be accommodated in a single world version: some truths conflict (WW: 109–16; MM: 30–44). If that is the case, we need many worlds, if any, to accommodate the conflicting versions and bring them in unison with the standard correspondence account of truth, that is, that the truth of a statement is its being in correspondence with a world. The second line of argument seems to be that we need no worlds at all if we need many. If we need a world for each version, why postulate the worlds over and above the versions?
Let us first have a closer look at the first line of reasoning. The Earth stands still, revolves around the Sun, and runs many other courses as well at the same time. Yet nothing moves while at rest. As Goodman concedes, the natural response to this is that the sentences
• (S1) The Earth is at rest.
• (S2) The Earth moves.
should be understood as elliptical for
• (S1′) The Earth is at rest according to the geocentric system.
• (S2′) The Earth moves according to the heliocentric system.
It is crucial for Goodman's argument that in the conflict between (S1) and (S2) we have (a) an actual conflict between statements, and (b) no other way to resolve that conflict (like, for example, rejecting at least one of the two statements in a non-arbitrary way). Of course, other contemporaries of Goodman, such as Quine and Carnap, also consider the problem that experience alone might underdetermine theory-choice, but believed that pragmatic criteria will in the long run allow us to arrive at one all-encompassing coherent version of the world. In Quine's (Quine 1981) and Carnap's (Carnap 1932) philosophies, this is assumed to be a physical version. But Goodman does not believe in physicalist reductivism. First of all, there does not currently seem to be any convincing evidence that all truths are reducible to physics (just consider the problem of reducing mental truths to physical truths), and, secondly, physics itself does not even appear to form a coherent system (WW: 5). Hence, for Goodman, we are stuck with conflicting world versions we consider true. Since, as we have seen above, relativism is no option for Goodman—because it would make true statements true about versions only—we arrive at Goodman's pluralism: conflicting true versions correspond to different worlds.
The second line of reasoning in Goodman's writings toys with the idea that there are no worlds that the right versions answer to—or at the very least that such worlds are not necessary. The world versions suffice, and are really the only things that are directly accessible, anyway. The versions can for many purposes be treated as worlds (WW: 4 and 96; cmp. MM: 30–33).
Goodman of course recognizes a difference between versions and worlds. A version can be in English and comprise words. Worlds are neither in English nor comprise words. However, for a version that is true of a world, the world has to answer to it in a way. A world that “corresponds” to (S1), for example, is a world with planets and spacetime that is so arranged that one of the planets, Earth, is at rest in it. But “planet”, “spacetime”, “at rest”, and so on are ways to categorize reality that depend on a version. These predicates are the ones chosen in this very version. There was no world that came ordered in correspondence with these predicates before this version was constructed. Instead, the world corresponds to the version expressed by (S1), because the world with that structure was made, when that version was made.
But what are worlds made of? Should we not at least assume Reality to be some kind of stuff that allows structuring with alternative versions as dough allows structuring with a cookie-cutter? Does there not have to be some substance for our versions to project structure onto? According to Goodman, this “tolerant realist view” that a plurality of worlds can be versions of a unique underlying Reality is also nothing but a useless addition. A Reality underlying the worlds must be unstructured and neutral, and thus serves no purpose. If there are many equally satisfactory versions of the world that are mutually incompatible, then there is not very much left that the “neutral Reality” could be. Reality would have no planets, no motion, no spacetime, no relations, no points, no structure at all. One can assume there is such a thing, Goodman seems to admit, but only because Reality is really not worth fighting for (or fighting against, for that matter). If we can tell true from false versions and explain why some are true versions and others false versions of worlds without assuming anything like an underlying reality, why assume it then? Parsimony considerations should lead us to refrain from postulating it.
### 6.2 Worldmaking
While Goodman insists that “there are many worlds, if any” (MM: 127; see also MM: 31), Goodman's worlds should not be conflated with possible worlds. There are no merely possible Goodman worlds, they are all actual (WW: 94 and 104; MM: 31). It is Goodman's view that worlds are “made” by answering to right versions, but there are no (merely possible) worlds that correspond to false versions. It is important to note that this view does not collapse into irrationalism or a fancy form of cultural relativism favored by postmodern thinkers. Making a true version is not trivial. Not surprisingly, it is not any easier than making a true version is for a realist. How we make true versions is absolutely the same on both accounts; the difference is only with respect to what we do when we make true versions (see WW and McCormick 1996 for discussion).
The constraints on worldmaking are strict. We cannot just create things; predicates must be entrenched and thus there must be some close continuity with former versions. Simplicity will keep us from creating new things from scratch, coherence from making anything in conflict with beliefs with higher initial credibility, and so on.
A world is made by making a world version. So, according to Goodman, the making of a world version is what has to be understood. Carnap's Aufbau, as already mentioned, presents a world version, the systems in A Study of Qualities and The Structure of Appearance are world versions, and so are scientific theories. The heliocentric and geocentric worldviews are relatively primitive world versions, while Einstein's theory of general relativity is a more sophisticated one. World versions do not have to be constructed in a formal language, though; indeed, they do not need to be in a language, formal or informal, at all. The symbol systems used in the arts—such as in painting, for instance—can be used in the process of worldmaking too. It is in this sense that philosophy, science, and art are all epistemically significant; they all contribute to our understanding; they all help to create worlds.
Making a world version is difficult. Acknowledging a great number of them does not make it easier. The hard work lies, for example, in creating a constructional system that overcomes the problems of its predecessors, is simple, uses well-entrenched predicates, or successfully replaces them with new ones (which is even harder), allows us to make useful predictions and so on. For Goodman, scientists, artists, and philosophers are faced with analogous problems in this.
Goodman's insistence that we make worlds when we make their versions and that we might just as well replace talking about worlds with talk about versions creates a problem that is not simply solved by acknowledging that making a true version is very hard. Making a version and making the objects that the version is about are clearly two different tasks. As Israel Scheffler writes in the abstract to “The Wonderful Worlds of Goodman”:
The worldmaking urged by Goodman is elusive: Are worlds to be identified with (true) world-versions or do they rather comprise what is referred to by such versions? Various passages in [WW] suggest one answer, various passages another. That versions are made is easy to accept; that the things they refer to are, equally, made, I find unacceptable. (Scheffler 1979: 618)
Indeed, Scheffler argues, Goodman confusingly uses “world” and “worldmaking” both in a versional and in an objectual sense. As we said above, Goodman's claim is that we make a world in the objectual sense by making a version of it. The claim is based on his conviction that the only structure of the world to which all true versions correspond does not exist independently; rather, it is only to be found because we project this structure onto the world with our conceptualizations. His favorite example is the constellation known as “Big Dipper”. Indeed, we “made” the Big Dipper by picking out one arbitrary constellation of stars and naming it. (More precisely, it is a so-called asterism that is part of the constellation Ursa Major—but the point still stands.) Which arrangement of heavenly bodies makes up the Big Dipper is purely conventional and hence only due to our conceptualization. Hilary Putnam (1992a) suggests that this idea may have some plausibility for the Big Dipper, but it does not, for instance, hold true of the stars that constitute the Big Dipper. True, “star” is a concept with partly conventional boundaries; however, that the concept “star” has conventional elements does not make it a matter of convention that “star” applies to something (and thus merely a matter of making a world version).
Putnam also points out that there is a tension between Goodman's notion of worldmaking and his first line of thought that leads to his irrealism: the idea that there are conflicting statements in different adequate world versions. As Putnam argues, to say that a statement of one world version is incompatible with that of another (such that a single world cannot accommodate both versions) requires that the expressions in the two versions have the same meaning. However, it is not clear that our ordinary notion of meaning allows such inter-version comparison of sameness of meaning (a thought that Goodman should sympathetic to, since he already doubts an intra-version notion of that kind). Moreover, there might be better ways to compare alternative versions (e.g., by way of homomorphism-relations between versions, as developed by Goodman in SA and discussed above in 4.1) and to explain how versions relate despite their apparent incompatibility (for example, by paying attention to the practice of scientists who manage to move from one version to another).
## Bibliography
### A. Primary sources
#### Books
• SQA Study of Qualities, Ph.D. dissertation thesis, Harvard University, 1941. First published New York: Garland, 1990 (Harvard Dissertations in Philosophy Series).
• SA The Structure of Appearance, Cambridge, MA: Harvard University Press, 1951; 2nd ed. Indianapolis: Bobbs-Merrill, 1966; 3rd ed. Boston: Reidel, 1977 (page numbers in our text refer to this last edition).
• FFF Fact, Fiction, and Forecast, University of London: Athlone Press, 1954; Cambridge, MA: Harvard University Press, 1955; 2nd ed. Indianapolis: Bobbs-Merrill, 1965; 3rd ed. Indianapolis: Bobbs-Merrill, 1973; 4th ed. Cambridge, MA: Harvard University Press, 1983.
• LA Languages of Art: An Approach to a Theory of Symbols, Indianapolis: Bobbs-Merrill, 1968; 2nd ed. Indianapolis: Hackett, 1976.
• PP Problems and Projects, Indianapolis: Bobbs-Merrill, 1972.
• BA Basic Abilities Required for Understanding and Creation in the Arts, Final Report (with David Perkins, Howard Gardner, and the assistance of Jeanne Bamberger et al.) Cambridge, MA: Harvard University: project no. 9-0283, grant no. OEG-0-9-310283-3721 (010). Reprinted (in part and with changes) in MM, ch. V.2.
• WW Ways of Worldmaking, Indianapolis: Hackett, 1978; paperback edition Indianapolis: Hackett, 1985.
• MM Of Mind and Other Matters, Cambridge, MA: Harvard University Press, 1984.
• RP (with Catherine Z. Elgin) Reconceptions in Philosophy and other Arts and Sciences, Indianapolis: Hackett; London: Routledge, 1988; paperback edition, London: Routledge, Indianapolis: Hackett, 1990.
For attempts at compilations of Goodman's complete corpus see Berka 1991, the bibliography in Cohnitz and Rossberg 2006, or follow the link in Other Internet Resources below to the list of writings by Goodman compiled by John Lee (University of Edinburgh).
#### Works by Goodman cited in this entry
• 1940 (with Henry S. Leonard) “The Calculus of Individuals and Its Uses”, Journal of Symbolic Logic, 5:45–55.
• 1947 (with W.V. Quine) “Steps Toward a Constructive Nominalism”, Journal of Symbolic Logic, 12:105–22. Reprinted in PP: 173–98.
• 1949 “On Likeness of Meaning”, Analysis, 10:1–7. Reprinted in PP: 221–30.
• 1953 “On Some Differences About Meaning”, Analysis, 13:90–96. Reprinted in PP: 231–8.
• 1956 “A World of Individuals”, in The Problem of Universals: a symposium, I.M. Bochenski, Alonzo Church, and Nelson Goodman. Notre Dame, IN: University of Notre Dame Press, pp. 13–31. Reprinted in PP: 155–71.
• 1958 “On Relations that Generate”, Philosophical Studies, 9:65–66. Reprinted in PP: 171–72.
• 1980 “Conversation with Franz Boenders and Mia Gosselin” (revised text of a television interview, Belgium Radio-Television System, Brussels, August 1980), in MM: 189–200.
• 2005 “Gewissheit ist etwas ganz und gar Absurdes” [“Certainty is something altogether Absurd”] (interviewed by Karlheinz Lüdeking), in Steinbrenner et al. 2005: 261–69.
### B. Secondary sources
• Berka, Sigrid, 1991, “An International Bibliography of Works by and Selected Works about Nelson Goodman”, Journal of Aesthetic Education, 25 (special issue: More Ways of Worldmaking): 99–112.
• Boolos, George, 1984, “To Be is to Be the Value of a Variable (or to Be Some Values of Some Variables)”, Journal of Philosophy, 81: 430–50.
• –––, 1985, “Nominalist Platonism”, Philosophical Review, 94: 327–44.
• Carnap, Rudolf, 1928, Der Logische Aufbau der Welt, Berlin: Weltkreis. English translation by Rolf A. George, 1967, in The Logical Structure of the World. Pseudoproblems in Philosophy, Berkeley and Los Angeles: University of California Press.
• –––, 1932, “Die physikalische Sprache als Universalsprache der Wissenschaft” Erkenntnis, 2: 432–465. English translation by Max Black, 1934, in The Unity of Science, London: Kegan Paul, pp. 67–76.
• –––, [1934] 1937, The Logical Syntax of Language, London: Routledge & Kegan Paul.
• –––, 1935, Philosophy and Logical Syntax, London: Kegan Paul.
• –––, 1947, “On the Application of Inductive Logic”, Philosophy and Phenomenological Research, 8: 133–48.
• Carter, Curtis L., 2000, “A Tribute to Nelson Goodman”, Journal of Aesthetics and Art Criticism, 58: 251–53.
• –––, 2009, “Nelson Goodman's Hockey Seen: A Philosopher's Approach to Performance”, in Jale N. Erzen (ed.), Congress Book 2: Selected Papers: XVIIth International Congress of Aesthetics, Ankara: Sanart.
• Cohnitz, Daniel, 2009, “The Unity of Goodman's Thought”, in Ernst et al. 2009: 33–50.
• Cohnitz, Daniel, and Marcus Rossberg, 2006, Nelson Goodman, Chesham: Acumen and Montreal: McGill-Queen's University Press.
• Creath, Richard (ed.), 1990, Dear Carnap, Dear Van: The Quine–Carnap Correspondence and Related Work, Berkeley, CA: University of California Press.
• Dudau, R. 2002, The Realism/Anti-Realism Debate in the Philosophy of Science, Berlin: Logos.
• Elgin, Catherine Z., 1983, With Reference to Reference, Indianapolis: Hackett.
• –––, 1997a, Between the Absolute and the Arbitrary, Ithaca: Cornell University Press.
• ––– (ed.), 1997b, The Philosophy of Nelson Goodman Vol. 1: Nominalism, Constructivism, and Relativism, New York: Garland.
• ––– (ed.), 1997c, The Philosophy of Nelson Goodman Vol. 2: Nelson Goodman's New Riddle of Induction, New York: Garland.
• ––– (ed.), 1997d, The Philosophy of Nelson Goodman Vol. 3: Nelson Goodman's Philosophy of Art, New York: Garland.
• ––– (ed.), 1997e, The Philosophy of Nelson Goodman Vol. 4: Nelson Goodman's Theory of Symbols and Its Applications, New York: Garland.
• –––, 2000a, “Worldmaker: Nelson Goodman (1906–1998)”, Journal for General Philosophy of Science, 31: 1–18.
• –––, 2000b, “In Memoriam: Nelson Goodman”, Erkenntnis, 52(2): 149–50.
• –––, 2001, “The Legacy of Nelson Goodman”, Philosophy and Phenomenological Research, 62: 679–90.
• Elgin, Catherine Z., Israel Scheffler, and Robert Schwarz, 1999, “Nelson Goodman 1906–1998”, Proceedings and Addresses of the American Philosophical Association, 72(5): 206–8.
• Ernst, Gerhard, Jakob Steinbrenner, and Oliver R. Scholz (eds.), 2009, From Logic to Art: Themes from Nelson Goodman, Frankfurt: Ontos.
• Field, Hartry, 1980, Science Without Numbers, Princeton: Princeton University Press.
• Frege, Gottlob, 1879, Begriffsschrift: Eine der arithmetischen nachgebildete Formelsprache des reinen Denkens, Halle a.S.: Nebert. English transl. by Stefan Bauer-Mengelberg in Jean van Heijenoort (ed.), 1967, From Frege to Gödel: A Sourcebook in Mathematical Logic, 1879–1931, Cambridge, MA: Harvard University Press, pp. 5–82.
• Grice, H. Paul, and Peter F. Strawson, 1956, “In Defense of a Dogma”, Philosophical Review, 65: 141–58.
• Henkin, Leon, 1962, “Nominalistic Analysis of Mathematical Language”, in Ernest Nagel, Patrick Suppes, and Alfred Tarski (eds.), Logic, Methodology and Philosophy of Science: Proceedings of the 1960 International Congress, Stanford: Stanford University Press, pp. 187–93.
• Hellman, Geoffrey, 1977, “Introduction” to Nelson Goodman's, The Structure of Appearance, 3rd edition, Boston: Reidel. (See SA: XIX–XLVII.)
• –––, 2001, “On Nominalism”, Philosophy and Phenomenological Research, 62: 691–705.
• Hume, David, [1739–40] 2000, A Treatise of Human Nature, D. F. Norton & M. J. Norton (eds.), Oxford: Oxford University Press.
• Leonard, Henry S., 1930, Singular Terms, Ph.D. dissertation thesis, Harvard University.
• –––, 1967, “Comments on The Calculus of Individuals and its Uses”, edited by Henry S. Leonard, Jr., forthcoming in Hans Burkhardt, Guido Imaguire and Johanna Seibt (eds.), Handbook of Mereology, Munich: Philosophia Verlag.
• Leśniewski, Stanisław, 1916, Podstawy ogólnej teoryi mnogosci, I, Moscow: Poplawski. English translation by D. I. Barnett as “Foundations of the General Theory of Sets. I”, in Leśniewski 1992: 129–73.
• –––, 1927–31, “O podstawach matematyki”, in: Przegląd Filozoficzny 30 (1927): 164–206; 31 (1928): 261–91; 32 (1929): 60–101; 33 (1930): 77–105; 34 (1931): 142–70. English translation as “On the Foundations of Mathematics” in Leśniewski 1992: 174–382.
• –––, 1992, Collected Works, ed. by S. J. Surma, J. Srzednicki, D. I. Barnett, and F. V. Rickey, Dordrecht: Kluwer.
• Lewis, C. I., 1941, “Logical Positivism and Pragmatism”, not published in Revue Internationale de Philosophie, due to German invasion of Belgium. Reprinted in Lewis 1970: 92–112.
• –––, [1952] 1997, “The Given Element in Empirical Knowledge”, The Philosophical Review, 61: 168–75. See Elgin 1997b: 112–19.
• –––, 1970, Collected Papers of Clarence Irving Lewis, J. D. Goheen & J. L. Mothershead, Jr (eds), Stanford, CA: Stanford University Press.
• Lewis, David K., 1991, Parts of Classes, Oxford: Basil Blackwell.
• Lomasky, Loren E., 1969, “Nominalism, Replication and Nelson Goodman”, Analysis, 29: 156–61.
• Mancosu, Paolo, 2005, “Harvard 1940–1941: Tarski, Carnap and Quine on a Finitistic Language of Mathematics for Science”, History and Philosophy of Logic, 26: 327–57.
• McCormick, Peter J. (ed.), 1996, Starmaking: Realism, Anti-Realism, and Irrealism, Cambridge, MA: MIT Press.
• Mitchell, W.J.T., 1999, “Vim and Rigor”, Artforum, May: 17–19.
• Putnam, Hilary, 1992a, “Irrealism and Deconstruction”, in Putnam 1992b: 108–133; reprinted in McCormick 1996: 179–200.
• –––, 1992b, Renewing Philosophy, Cambridge, MA: Harvard University Press.
• Quine, W.V., 1951a, “Two Dogmas of Empiricism”, Philosophical Review, 60: 20–43; reprinted in his From a Logical Point of View, Cambridge, MA: Harvard University Press, rev. ed. 1980, pp. 20–46.
• –––, 1951b, “The Structure of Appearance by Nelson Goodman: Review”, Journal of Philosophy, 48(18): 556–63.
• –––, 1981, Theories and Things, Cambridge, MA: Harvard University Press.
• –––, 1985, The Time of My Life: An Autobiography, Cambridge, MA: MIT Press.
• Rawls, John, 1971. A Theory of Justice, Cambridge, MA: Harvard University Press.
• Ridder, Lothar, 2002, Mereologie: Ein Beitrag zur Ontologie und Erkenntnistheorie, Frankfurt: Klostermann.
• Rossberg, Marcus, 2009, “Leonard, Goodman, and the Development of the Calculus of Individuals”, in Ernst et al. 2009: 51–69.
• Rossberg, Marcus, and Daniel Cohnitz, 2009, “Logical Consequence for Nominalists”, Theoria, 65: 147–68.
• Scheffler, Israel, 1979, “The Wonderful Worlds of Goodman [abstract]”, Journal of Philosophy, 67: 618.
• –––, 1980, “The Wonderful Worlds of Goodman”, Synthese, 45: 201–09.
• –––, 2001, “My Quarrels with Nelson Goodman”, Philosophy and Phenomenological Research, 62: 665–77.
• Scholz, Oliver, 2005, “In Memoriam: Nelson Goodman”, in Steinbrenner et al. 2005: 9–32.
• Schwartz, Robert, 1999, “In Memoriam Nelson Goodman (August 7, 1906–November 25, 1998)”, Erkenntnis, 50: 7–10.
• Simons, Peter M., 1987, Parts: A Study in Ontology, Oxford: Clarendon Press.
• Stalker, Douglas (ed.), 1994, Grue! The New Riddle of Induction, Chicago: Open Court.
• Steinbrenner, Jakob, Oliver R. Scholz, and Gerhard Ernst (eds.), 2005, Symbole, Systeme, Welten, Heidelberg: Synchron.
• Tarski, Alfred, 1929, “Les fondements de la géométrie des corps”, Annales de la Société Polonaise de Mathématique (Supplementary Volume), 7: 29–33. English translation of a revised version by J. H. Woodger as “Foundations of the Geometry of Solids”, in Tarski 1983: 24–29.
• –––, 1935, “Zur Grundlegung der Booleschen Algebra. I”, Fundamenta Mathematicae, 24: 177–98. English translation by J. H. Woodger as “On the Foundations of the Boolean Algebra”, in Tarski 1983: 320–41.
• –––, 1983, Logics, Semantics, Metamathematics: Papers from 1923 to 1938, ed. by J. H. Woodger and John Corcoran, Indianapolis: Hackett.
• van Inwagen, Peter, 1990, Material Beings, Ithaca, NY: Cornell University Press.
• White, Morten, 1948. “On the Church–Frege Solution of the Paradox of Analysis”, Philosophy and Phenomenological Research, 9: 305–8.
• –––, 1950, “The Analytic and the Synthetic: An Untenable Dualism”, in S. Hook (ed.), John Dewey: Philosopher of Science and Freedom, New York: Dial Press, 316–30.
• –––, 1999, A Philosopher's Story, University Park, Penn.: Pennsylvania State University Press.
• Whitehead, Alfred North, and Bertrand Russell, 1910–13, Principia Mathematica, 3 vols., Cambridge: Cambridge University Press.
|
|
# Spin = -1/2
Why there can exist some particles having spin = 1/2? I understand, the postive numbers but what do the negative number mean?
Also, I would like to ask why some photons can be detected when it comes to light, but photon is not detected when it comes to charge replusion? What is the difference between these two kinds of protons?
Cyosis
Homework Helper
A particle has spin 1/2 (non negative), but it can 'rotate' in two directions so one is called 1/2 and the opposite direction -1/2. As for the photon question, I'm not sure what you mean.
jtbell
Mentor
What is the difference between these two kinds of protons?
Fredrik
Staff Emeritus
Gold Member
There are two quantum numbers related to spin. The book I studied called them j and m. (j is usually called j, but m is sometimes called s or $\sigma$). j is one of the properties (along with mass and charge) that tell us what particle species we're dealing with (electrons, photons, etc.). m is one of the properties that define what state the particle is in.
j is always a non-negative integer or half-integer. (j=n/2 where n is an integer satisfying n≥0). m is also an integer or a half-integer. It satisfies -j ≤ m ≤ j. It can only be changed in integer steps, and j is always one of the possible values of m. So if j=1/2 (e.g. an electron), the possible results of a measurement of m are -1/2 or +1/2. If j=1 (e.g. a photon), the possible results are -1, 0 or 1.
Last edited:
Why there can exist some particles having spin = 1/2? I understand, the postive numbers but what do the negative number mean?
Do you mean
$$j=-\frac{1}{2}$$
or
$$m=-\frac{1}{2}$$ ?
I know spin = 1/2 meaning that the particle rotates 720 degree than looks the same as the original one.
But, -1/2, what does that imply? j and m? What do they mean?
jtbell
Mentor
Note that intrinsic angular momentum ("spin") $\vec S$ is a vector: a quantity that has both magnitude and direction.
"spin 1/2" normally refers to the quantum number that's associated with the magnitude of $\vec S$. Most of my books call this quantum number s. Other books, and Fredrik and Mathematikawan, call it j.
$$S = \sqrt{s(s+1)} \hbar = \frac{\sqrt{3}}{2} \hbar$$
Be careful of notation here: Upper-case S is the magnitude of the vector $\vec S$. Lower-case s is the quantum number.
Where you're seeing "-1/2" it is surely referring to the quantum number that's associated with the component of $\vec S$ along a particular direction. Usually we call it the z-direction, so this component is called $S_z$. Most of my books call this quantum number $m_s$. Other books, and Fredrik and Mathematikawan, call it m.
$$S_z = m_s \hbar$$
When s = 1/2, $m_s$ can have the values -1/2 or +1/2, and $S_z$ correspondingly can have the values $- \hbar / 2$ or $+ \hbar / 2$.
When s = 1, $m_s$ can have the values -1, 0 or +1. In this case, $S = \sqrt{2} \hbar$ and $S_z$ can have the values $-\hbar$, 0 or $+\hbar$.
When s = 3/2, $m_s$ can have the values -3/2, -1/2, +1/2 or +3/2. I leave it to you to write the corresponding values of S and $S_z$.
When s = 2, $m_s$ can have the values -2, -1, 0, +1 or +2.
A positive value for $m_s$ means that the vector $\vec S$ points more or less in the +z direction. A negative value indicates that $\vec S$ points more or less in the -z direction.
Last edited:
I think jtbell has done excellent job in explaining the notations.
Sorry that I have been looking the concept of spin from the mathematical view rather than from the physical view. The spin quantum number j or s is just a label for the irreducible representation of su(2). So it can be positive or negative integer or half-integer value, as long as we can construct the representation.
So when I saw the title of the thread Spin = -1/2, hei may be this forum can enlighten me something. There are speculation that there may be such thing as physical negative spin j. I have came across the following papers (there may be others)
1. Andre van Tonder, Ghosts as Negative Spinors, Nuc. Phys. B 645(2002) pp 371-386.
2. Keshav N.Shrivastava, Negative-spin Quasiparticles in Quantum Hall Effect, Physics Letters A 326(2004) pp 469-472.
I manage to understand only a little bit from those papers. I even started a thread at this forum to make a sense from those papers.
|
|
# How to show that $f(x) = x^2 \sin(1/x^2)$ with $f(0)=0$ is differentiable and $f'$ is unbounded on $[-1,1]$?
If the function $f$ is defined by $$f(x) = \begin{cases}x^2 \sin(\frac{1}{x^2}) & x \ne 0 \\ 0 & x = 0 \end{cases}$$ then $f$ is differentiable and $f'$ is unbounded on $[-1,1]$.
I know this is true. How should I go about proving this?
• Have you calculated $f'(x)$? Treat the case $x = 0$ separately and go back to the definition. – Simon S Dec 4 '14 at 21:11
• What have you tried? Can you compute the derivative for points $x \ne 0$? What about for $x = 0$ (you'll need to use the definition, or the squeeze lemma for limits)? – John Hughes Dec 4 '14 at 21:11
The cool point of the problem is that although for any positive value $M$ and positive $\epsilon$ we can find some value of $x$ with $|x|<\epsilon$ such that $|f'(x)| > M$, yet $f$ is differentiable at $x=0$.
In fact, $f'(0) = 0$, and we can see that by applying the definition of derivative: $$\left. \frac{df(x)}{dx} \right|_{x=0} = \lim_{h\rightarrow 0} \frac{h^2 \sin\frac{1}{h^2}-f(0)}{h} = \lim_{h\rightarrow 0} {h \sin\frac{1}{h^2}}-0 =0$$ since $|\sin\frac{1}{h^2}|$ is bounded by 1 and that is being multiplied by $h$.
On the other hand, look at the expression for $f'(x)$ when $x \neq 0$. At points where $\frac{1}{x^2} = (n+\frac{1}{2})\pi$,
$$|f'(x)| > \frac{2}{x} - 2x$$ and this is unbounded as $x$ approaches zero.
At x=0, we can't use the normal derivative rules. So a chain rule application isn't valid, as far as I know. When things like this come to question, the definition is where to look. In this case, the derivative is:
$$\lim_{h\to 0} \frac{f(x+h)-f(x)}{h}=\lim_{h\to 0} \frac{h^{2}sin(1/h^{2})}{h}=\lim_{h\to 0} h sin(1/h^{2})=0$$
The last step was by squeeze theorem, squeezed between $|h|$ and $-|h|$.
So $f'(0)=0$. Everywhere else it is differentiable, because by chain and product rule, compositions and products of diff. functions are diff, and by linearity of the derivative, sums of diff. functions are diff. as well.
So $f'(x)$ is diff on the interval. At 0, it is 1. Otherwise, it is equal to
$$f'(x) = 2x\sin(1/x^2)-2\frac{\cos(1/x^2)}{x}$$
as stated by JefLaga. 1/x is not bounded on the interval, though. So $f'(x)$ isn't bounded on [-1,1].
Using the product and chain rule, one gets that $$f'(x) = 2x\sin(1/x^2)-2\frac{\cos(1/x^2)}{x}$$ Notice that this function is unbounded on the given interval.
• That's not completely correct. You need to add that $f'(0) = 0$, rather than it being undefined (as it would be if the formula on the right were the whole answer). – John Hughes Dec 4 '14 at 21:42
• I agree, but I think this still implies that the derivative is unbounded, because it is unbounded on the interval $]0,1]$ – Jef L Dec 5 '14 at 7:39
• Agree completely -- this function, which agrees with the derivative except at zero, is indeed unbounded. But it doesn't answer the first bit of the question, which is to show that $f$ is differentiable (everywhere). – John Hughes Dec 5 '14 at 11:32
|
|
# mhchem reaction arrows seem to break when using a command in the \ce environment
I've tried making the command
\newcommand{\aq}{_{(aq)}}
to make the subscript to show that an ion is aqueous, but when used in the \ce command it breaks the reaction arrows
\ce{2Cu(OH2)^{2+}_{6} + 4I^{-}\aq <=> 2CuI v +I2 v +12H2O}
-
BTW: IUPAC recommends to typeset “the states of aggregation of chemical species [...] appended to the formula in parentheses and [...] printed in Roman (upright) type without a full stop (period).” This means: not as a subscript. – cgnieder May 2 '12 at 19:13
This is fixed if you use {} immediately following \aq:
\ce{2Cu(OH2)^{2+}_{6} + 4I^{-}\aq{} <=> 2CuI v +I2 v +12H2O}
-
mhchem's arrows need to be preceded with a space. Since a command “eats” spaces after it there is no space before the arrow here: \ce{\cs <=>}. So that's why you need to add an empty group {} (\ce{\cs{} <=>}) or enclose the command with braces (\ce{{\cs} <=>}):
\documentclass{article}
\usepackage[version=3]{mhchem}
\setlength\parindent{0pt}
\begin{document}
without space: \ce{A<=>} \\
with space: \ce{A <=>}
\def\B{B}\bigskip
without space: \ce{\B <=>} \\
with space: \ce{\B{} <=>} \\
with space: \ce{{\B} <=>}
\end{document}
-
|
|
# Summary
Powerful biomarkers are important tools in diagnostic, clinical and research settings. In the area of diagnostic medicine, a biomarker is often used as a tool to identify subjects with a disease, or at high risk of developing a disease. Moreover, it can be used to foresee the more likely outcome of the disease, monitor its progression and predict the response to a given therapy. Diagnostic accuracy can be improved considerably by combining multiple markers, whose performance in identifying diseased subjects is usually assessed via receiver operating characteristic (ROC) curves. The CombiROC tool was originally designed as an easy to use R-Shiny web application to determine optimal combinations of markers from diverse complex omics data ( Mazzara et al. 2017 ); such an implementation is easy to use but has limited features and limitations arise from the machine it is deployed on. The CombiROC package is the natural evolution of the CombiROC tool and it allows the researcher/analyst to freely use the method and further build on it.
# The complete workflow
The aim of this document is to show the whole CombiROC workflow to get you up and running as quickly as possible with this package. To do so we’re going to use the proteomic dataset from Zingaretti et al. 2012 containing multi-marker signatures for Autoimmune Hepatitis (AIH) for samples clinically diagnosed as “abnormal” (class A) or “normal” (class B). The scope of the workflow is to first find the markers combinations, then to assess their performance in classifying samples of the dataset.
Mazzara S., Rossi R.L., Grifantini R., Donizetti S., Abrignani L., Bombaci M. (2017) CombiROC: an interactive web tool for selecting accurate marker combinations of omics data. Scientific Reports, 7:45477. 10.1038/srep45477
## Required data format
The dataset to be analysed should be in text format, which can be separated by commas, tabs or semicolons. Format of the columns should be the following:
• The 1st column must contain unique patient/sample IDs.
• The 2nd column must contain the class to which each sample belongs.
• The classes must be exactly TWO and they must be labelled with character format with “A” (usually the cases) and “B” (usually the controls).
• From the 3rd column on, the dataset must contain numerical values that represent the signal corresponding to the markers abundance in each sample (marker-related columns).
• The header for marker-related columns can be called ‘Marker1, Marker2, Marker3, …’ or can be called directly with the gene/protein name. Please note that “-” (dash) is not allowed in the column names
The load_data() function uses a customized read.table() function that checks the conformity of the dataset format. If all the checks are passed, marker-related columns are reordered alphabetically, depending on marker names (this is necessary for a proper computation of combinations), and it imposes “Class” as the name of the second column. The loaded dataset is here assigned to the “data” object. Please note that load_data() takes the semicolumn (“;”) as default separator: if the dataset to be loaded has a different separator, i.e. a comma (“,”), is necessary to specify it in the argument sep. The code below shows how to load a data set contained in the “data” folder (remember to adjust the path according to your current working directory):
data <- load_data("./data/demo_data.csv")
We are going to use an AIH demo data set, that has been included in CombiROC package and can be directly called as demo_data.
data <- demo_data
head(data)
## Exploring the data
It is usually a good thing to visually explore your data with at least a few plots.
Box plots are a nice option to observe the distribution of measurements in each sample. The user can plot the data as she/he wishes using the preferred function: since data for CombiROC are required to be in wide (untidy) format, they cannot be plotted directly with the widely used ggplot() function. Either the user is free to make the data longer (tidy) for the sole purpose of plotting, or the package’s combiroc_long() function can be used for this purpose; this function wraps the tidyr::pivot_longer()function, and it’s used to reshape the data in long format.
Data in long format are required for the plotting functions of the package and for any other Tidyverse-oriented applications.
The data object in the original wide format can be thus transformed into the reshaped long format data_long object, and further used. See also the section “Code snippets” for some plotting examples taking advantage of the reshaped format.
data_long <- combiroc_long(data)
data_long
### Checking the individual markers
Individual markers can also be explored retrieving a summary statistics and all individual scatter plots. To do so, the function single_markers_statistics() can be used ingesting the dataframe data_long in long format returned by combiroc_long().
sms <- single_markers_statistics(data_long)
The single_markers_statistics() function returns a list on length 2, whose first element (sms[[1]]) is a table with statistics for all markers in each class. The computed statistics are:
• mean value
• minimum and maximum values
• coefficient of variation
• first quartile limit, median, third quartile limit
s_table <- sms[[1]]
s_table
While the second element is another list, containing dot plots, one for each marker. The individual plots can be called from the second element (sms[[2]]) of the list with the $ operator. Here we display the plot for Marker 1: plot_m1 <- sms[[2]]$Marker1
plot_m1
In the section “Code snippets” at the end of this vignette we suggest code snippets that can be used to customize the plots for individual markers across all samples, as well as to modify the summary statistics.
## Markers distribution overview
Since the target of the analysis is the identification of marker combinations capable to correctly classify samples, the user should first choose a signal threshold to define the positivity for a given marker/combination. This threshold should:
• Positively select most samples belonging to the case class (labelled with “A” in the “Class” column of the dataset), which values must be above the signal threshold.
• Negatively select most control samples (labelled “B”), which values must be below the signal threshold.
Usually this threshold is suggested by the guidelines of the kit used for the analysis (e.g. mean of buffer signal + n standard deviations). However, it is a good practice to always check the distribution of signal intensity of the dataset. To help the user with this operation, the markers_distribution() function have been implemented generating a set of discoverable objects.
This function takes as input the data in long format ( data_long ), and returns a named list (here assigned to the distr object). Please note that the only required argument of markers_distributions() function is case_class, while other arguments have defaults: specific warnings are triggered with this command remembering the users the default threshold parameters that are in place during the computation.
distr <- markers_distribution(data_long, case_class = 'A',
y_lim = 0.0015, x_lim = 3000,
signalthr_prediction = TRUE,
min_SE = 40, min_SP = 80,
boxplot_lim = 2000)
## Warning in markers_distribution(data_long, case_class = "A", y_lim = 0.0015, :
## In $Coord object you will see only the signal threshold values at which SE>=40 ## and SP>=80 by default. If you want to change this limits, please set min_SE and ## min_SP ## Warning in markers_distribution(data_long, case_class = "A", y_lim = 0.0015, : ## The suggested signal threshold in$Plot_density is the median of the signal
## thresholds at which SE>=min_SE and SP>=min_SP. This is ONLY a suggestion. Please
## check if signal threshold is suggested by your analysis kit guidelines instead,
### The ROC curve for all markers and its coordinates
The ROC curve shows how many real positive samples would be found positive (sensitivity, or SE) and how many real negative samples would be found negative (specificity, or SP) in function of signal threshold. Please note that the False Positive Rate (i.e. 1 - specificity) is plotted on the x-axis. These SE and SP are refereed to the signal intensity threshold considering all the markers together; they are not the SE and SP of a single marker/combination computed by the se_sp() function further discussed in the Sensitivity and specificity paragraph.
distr$ROC The Coord is a dataframe that contains the coordinates of the above described “ROC” (threshold, SP and SE) that have at least a minimun SE (min_SE) and a minimum SP (min_SP): this two threshold are set by default at min_SE = 40 and min_SP = 80, but they can be set manually by specifying different values. The Youden index is also computed: this is the Youden’s J statistic capturing the performance of a dichotomous diagnostic test, with higher values for better performance ( $$J = SE + SP -1$$). head(distr$Coord, n=10)
### The density plot and suggested signal threshold
The Density_plot shows the distribution of the signal intensity values for both the classes. In addition, the function allows the user to set both the y_lim and x_lim values to provide a better visualization. One important feature of the density plot is that it calculates a possible signal intensity threshold: in case of lack of a priori knowedge of the threshold the user can set the argument signalthr_prediction = TRUE in the markers_distribution() function. In this way the function calculates a “suggested signal threshold” that corresponds to the median of the signal threshold values (in Coord) at which SE and SP are greater or equal to their set minimal values (min_SE and min_SP). This threshold is added to the “Density_plot” object as a dashed black line and a number. The use of the median allows to pick a threshold whose SE/SP are not too close to the limits (min_SE and min_SP), but it is recommended to always inspect “Coord” and choose the most appropriate signal threshold by considering SP, SE and Youden index.
This suggested signal threshold can be used as signalthr argument of the combi() function further in the workflow.
## Combinatorial analysis
combi() function works on the dataset initially loaded. It computes the marker combinations and counts their corresponding positive samples for each class (once thresholds are selected). A sample, to be considered positive for a given combination, must have a value higher than a given signal threshold (signalthr) for at least a given number of markers composing that combination (combithr).
As mentioned before, signalthr should be set depending on the guidelines and characteristics of the methodology used for the analysis or by an accurate inspection of signal intensity distribution. In case of lack of specific guidelines, one should set the value signalthr as suggested by the distr$Density_plot as described in the previous section. In this vignette signalthr is set at 450 while combithr is set at 1. We are setting this at 450 (instead of 407 as suggested by the distr$Density_plot) in order to reproduce the results reported in Mazzara et. al 2017 (the original CombiROC paper) or in Bombaci & Rossi 2019 as well as in the tutorial of the web app with default thresholds.
combithr, instead, should be set exclusively depending on the needed stringency: 1 is the less stringent and most common choice (meaning that at least one marker in a combination needs to reach the threshold). The obtained tab object is a dataframe of all the combinations obtained with the chosen parameters.
tab <- combi(data, signalthr = 450, combithr = 1)
head(tab, n=20)
## Sensitivity and specificity
Once all the combinations are computed, se_sp() function takes as inputs the loaded data data and the previously obtained set of combinations (tab) to calculate:
• Sensitivity (SE) and specificity (SP) of each combination for each class;
• the number of markers composing each combination (#Markers).
SE of case class (“A”) is calculated dividing the number of positive samples by the total sample of case class (% of positive “A” samples), while case class SP is calculated subtracting SE to 100 (% of negative “A” samples).
SE of control class (“B”) is calculated dividing the number of positive samples by the total sample of control class (% of positive “B” samples), while SP is calculated subtracting SE to 100 (% of negative “B” samples).
Thus, the SE of a given combination (capability to find real positives/cases) corresponds to the SE of the case class (in this case “A”), while its SP (capability to exclude real negatives/controls) corresponds to the SP of the control class (in this case “B”). The obtained value of SE, SP and number of markers are assigned to “markers” mks dataframe.
mks <- se_sp(data, tab)
mks
## Selection of combinations
The markers combinations can now be ranked and selected. After specifying the case class (“A” in this case), the function ranked_combs() ranks the combinations by the Youden index in order to show the combinations with the highest SE (of cases) and SP (of controls) on the top, facilitating the user in the selection of the best ones. Again, the Youden index (J) is calculated in this way: $J = SE+SP-1$ The user can also set (not mandatory) a minimal value of SE and/or SP that a combination must have to be selected, i.e. to be considered as “gold” combinations.
A possibility to overview how single markers and all combinations are distributed in the SE - SP ballpark is to plot them with the bubble chart code suggested in the Additional Tips&Tricks section (see: Bubble plot of all combinations) starting from the mks dataframe obtained with the se_sp() function (see above).
The bigger the bubble, the more markers are in the combination: looking at the size and distribution of bubbles across SE and SP values is useful to anticipate how effective will be the combinations in the ranking. Setting no cutoffs (i.e. SE = 0 and SP = 0), all single markers and combinations (all bubbles) will be considered as “gold” combinations and ranked in the next passage.
In the the example below the minimal values of SE and SP are set, respectively, to 40 and 80, in order to reproduce the gold combinations selection reported in Mazzara et. al 2017. The obtained values of combinations, ranked according to Youden index, are stored in the “ranked markers” rmks object containing the table dataframe and the bubble_chart plot that can be accessed individually with the $ operator. rmks <- ranked_combs(data, mks, case_class = 'A', min_SE = 40, min_SP = 80) rmks$table
as mentioned, the rmks object also has a slot for the bubble_chart plot, that can be recalled with the usual $ operator. This plot discriminates between combinations not passing the SE and SP cutoffs as set in ranked_combs() (blue bubbles) and “gold” combinations passing them (yellow bubbles). rmks$bubble_chart
## ROC curves
To allow an objective comparison of combinations, the function roc_reports() applies the Generalised Linear Model (stats::glm() with argument family= binomial) for each gold combination. The resulting predictions are then used to compute ROC curves (with function pROC::roc()) and their corresponding metrics which are both returned by the function as a named list object (in this case called reports). The function roc_reports() requires as input:
• The data object ( data ) obtained with load_data();
• the table with combinations and corresponding positive samples counts ( tab ), obtained with combi().
In addition, the user has to specify the class case, and the single markers and/or the combinations that she/he wants to be displayed with the specific function’s arguments.
In the example below a single marker ( Marker1 ) and two combinations (combinations number 11 and 15 ) were choosen.
reports <-roc_reports(data, markers_table = tab,
case_class = 'A',
single_markers =c('Marker1'),
selected_combinations = c(11,15))
The obtained reports object contains 3 items that can be accessed using the $ operator: • Plot: a ggplot object with the ROC curves of the selected combinations; • Metrics: a dataframe with the metrics of the roc curves (AUC, opt. cutoff, etc …); • Models: The list of models that have been computed and then used to classify the samples (the equation for each selected combination). reports$Plot
reports$Metrics reports$Models
## $Marker1 ## ## Call: glm(formula = fla, family = "binomial", data = data) ## ## Coefficients: ## (Intercept) log(Marker1 + 1) ## -13.775 2.246 ## ## Degrees of Freedom: 169 Total (i.e. Null); 168 Residual ## Null Deviance: 185.5 ## Residual Deviance: 101.7 AIC: 105.7 ## ##$Combination 11
##
## Call: glm(formula = fla, family = "binomial", data = data)
##
## Coefficients:
## (Intercept) log(Marker1 + 1) log(Marker2 + 1) log(Marker3 + 1)
## -17.0128 1.5378 0.9176 0.5706
##
## Degrees of Freedom: 169 Total (i.e. Null); 166 Residual
## Null Deviance: 185.5
## Residual Deviance: 87.49 AIC: 95.49
##
## $Combination 15 ## ## Call: glm(formula = fla, family = "binomial", data = data) ## ## Coefficients: ## (Intercept) log(Marker1 + 1) log(Marker3 + 1) log(Marker5 + 1) ## -16.0554 1.9595 0.6032 0.2805 ## ## Degrees of Freedom: 169 Total (i.e. Null); 166 Residual ## Null Deviance: 185.5 ## Residual Deviance: 87.95 AIC: 95.95 ## Under the hood For a bit deeper discussion on how to interpret the results, this section will be focused on a single specific combination in the dataset seen so far: “Combination 11”, combining Marker1, Marker2 and Marker3. This combination has an optimal cutoff equal to 0.216 (see the CutOff column in reports$Metrics).
The following is the regression equation being used by the Generalized Linear Model (glm) function to compute the predictions:
$f(x)=β_0+β_1x_1+β_2x_2+ β_3x_3 +...+β_nx_n$
Where $$β_n$$ are the coefficients (being $$β_0$$ the intercept) determined by the model and $$x_n$$ the variables.
While, the predicted probabilities have been calculated with the sigmoid function:
$p(x) = \frac{\mathrm{1} }{\mathrm{1} + e^{-f(x)} }$
In accordance with the above, the predictions for “Combination 11” have been computed using the coefficients displayed as in reports$Models (see previous paragraph), and this combination’s prediction equation will be: $f(x)= -17.0128 + 1.5378 *log(Marker1 + 1) + 0.9176 *log(Marker2 + 1) + 0.5706* log(Marker3 + 1)$ As for the predict method for a Generalized Linear Model, predictions are produced on the scale of the additive predictors. Predictions ($$f(x)$$ values) of Combination 11 can be visualized using the commmand glm::predict with argument type = "link": head(predict(reports$Models$Combination 11, type='link')) # link = f(x) ## 1 2 3 4 5 6 ## 0.166224681 -0.008125528 2.192603482 1.077910194 3.816098810 0.593971602 Prediction probabilities ($$p(x)$$ values, i.e. predictions on the scale of the response) of Combination 11 can be instead visualized using argument type = "response": head(predict(reports$Models$Combination 11, type='response')) # response = p(x) ## 1 2 3 4 5 6 ## 0.5414607 0.4979686 0.8995833 0.7460983 0.9784606 0.6442759 Finally, the comparison between the prediction probability and the optimal cutoff (here 0.216, see the CutOff column for Classification 11 in reports$Metrics) determines the classification of each sample by following this rule:
$C(x) = \begin{cases} 1 & {p}(x) > opt. cutoff \\ 0 & {p}(x) \leq opt.cutoff \end{cases}$
Specifically, for “Combination 11”:
• Samples with $$p(x)$$ higher than 0.216 are classified as “positives” (1).
• Samples with $$p(x)$$ lower or equal to 0.216 are classified as “negatives” (0).
Thus, using 0.216 as cutoff, Combination 11 is able to classify the samples in the dataset with a SE equal to 95.0%, SP equal to 86.9%, and accuracy equal to 88.8% (see ROC curves, reports$Metrics). # Classification of new samples A new feature of the CombiROC package (not present in the CombiROC tool Shiny app), offers the possibility to exploit the models obtained with roc_reports() for each selected marker/combination (and assigned to reports$Models) to directly classify new samples that are not labelled, i.e. not assigned to any case or control classes.
The unclassified data set must be similar to the data set used for the previous combinatorial analysis ( i.e. of the same nature and with the same markers, but obviously without the ‘Class’ column).
To load datasets with unclassified samples a specific load_unclassified_data() function was implemented. This function is analogue to load_data() since it loads the same kind of files and it performs the same format checks, with the exception of the Class column which is not present in an unclassified datasets and thus not required.
For purely demonstrative purposes, in the following example a “synthetic” unclassified data set (‘data/unclassified_proteomic_data.csv’) was used: it was obtained by randomly picking 20 samples from the already classified data set (the data). The loaded unclassified sample is here assigned to the unc_data object.
Please note that this unclassified data set lacks the “Class” column but has a Patient.ID column which actually allows the identification of the class but sample names here are not used in the workflow and have labeling purposes to check the prediction outcomes (a “no” prefix identifies healthy/normal subjects while the absence of the prefix identifies affected/abnormal subjects).
unc_data <- load_unclassified_data(data = './data/demo_unclassified_data.csv', sep = ',')
This very same dataset has been included in CombiROC package as an unclassified demo dataset, which can be directly called typing demo_unclassified_data.
head(demo_unclassified_data)
The prediction of the class can be achieved with classify(): this function applies the models previously calculated on a classified data set working as training dataset, to the unclassified dataset and classifies the samples accordingly to the prediction probability and optimal cutoff as shown in the Under the hood section.
This classify() function takes as inputs:
• the unclassified data set containing the new samples to be classified (unc_data);
• the list of models reports$Models that have been previously computed by roc_reports() (reports$Models);
• the list of metrics that have been previously computed by roc_reports() (reports$Metrics). In addition the user can set the labels of the predicted class (setting Positive_class and Negative_class), otherwise they will be 1 for positive samples and 0 for the negative samples by default (see the rule shown in the end of the Results explanation section). Here we are setting Positive_class = "affected" and Negative_class = "healthy" The function returns a data.frame (cl_data in the example below), whose columns contain the predicted class for each sample according to the models used (originally in reports$Models); here we are still usign Marker1, Combination 11 and Combination 15.
unc_data <- demo_unclassified_data
cl_data <- classify(unc_data,
Models = reports$Models, Metrics = reports$Metrics,
Positive_class = "abnormal",
Negative_class = "normal")
As can be observed comparing the outcome in the dataframe with the tag on samples’ names, the single marker Marker1 is not 100% efficient in correctly predicting the class (see mismatch in second row, where the normal sample “no AIH126” is classified as abnormal by Marker1); instead, both Combination 11 and 15 correctly assign it to the right class.
cl_data
Thus, each column of the prediction dataframe contains the prediction outcome of a given model and, along with the samples names (in the index column), can be accessed with the $operator as usual: cl_data$index
## [1] "AIH33" "no AIH126" "AIH12" "no AIH112" "no AIH41" "no AIH38"
## [7] "AIH4" "no AIH32" "AIH20" "no AIH13" "no AIH11" "no AIH114"
## [13] "no AIH121" "AIH17" "AIH14" "no AIH106" "no AIH67" "AIH9"
## [19] "no AIH74" "AIH16"
cl_data$Combination 11 ## [1] "abnormal" "normal" "abnormal" "normal" "normal" "normal" ## [7] "abnormal" "normal" "abnormal" "normal" "normal" "normal" ## [13] "normal" "abnormal" "abnormal" "normal" "normal" "abnormal" ## [19] "normal" "abnormal" # Ancillary functions ## Retrieving composition of combinations show_markers() returns a data frame containing the composition of each combination of interest. It requires as input one or more combinations (only their numbers), and the table with combinations and corresponding positive samples counts (“tab”, obtained with combi()). show_markers(selected_combinations =c(11,15), markers_table = tab) ## Retrieving combinations containing markers of interest combs_with() returns the combinations containing all the markers of interest. It requires as input one or more single marker, and the table with combinations and corresponding positive samples counts (“tab”, obtained with combi()). The list with the combinations containing all the markers is assigned to “combs_list” object. combs_list <- combs_with(markers=c('Marker1', 'Marker3'), markers_table = tab) ## The combinations in which you can find ALL the selected markers have been computed combs_list ## [1] 2 11 14 15 21 22 24 26 # Code snippets In this section we offer code insights taking advantage of the long format of the data_long object; starting from here the user can further customize plots and data summaries returned by the combiroc functions. ## Plotting of intensities of individual markers A quick plotting overview of individual marker values can be done with a scatter plot using the library ggplot2. Here is an example for the marker “Marker2”: library(dplyr) # needed for the filter() function and %>% operator library(ggplot2) myMarker <- "Marker2" data_long %>% filter(Markers == myMarker) %>% ggplot(aes(x= Patient.ID, y=Values)) + geom_point(aes(color=Class)) + labs(title=myMarker, x ="Samples") + scale_x_discrete(labels = NULL, breaks = NULL) ## Summary statistics of individual markers Further markers exploration can be done using other packages’ functions such as group_by(), summarize() and ggplot() on the the data_long dataframe. As an example, a few summary statistics can be computed for each marker of both classes, separately, as follow (the libraries dplyr and moments are needed). Numbers in this table are those behind the box plot obtained with distr$boxplot as seen before.
library(dplyr)
library(moments) # needed for skewness() function
data_long %>%
group_by(Markers, Class) %>%
summarize(Mean = mean(Values),
|
|
Question 6
# Select the figure that can replace the question mark (?) in the following series.
Solution
In the given series, the number of vertical lines is increasing by 1 and the triangle is moving one place along the corner of the square and also rotating about itself.
In the next figure, the number of vertical lines will be four and the triangle will be at the bottom left facing left.
$$\therefore\$$The next figure in the series is
Hence, the correct answer is Option A
|
|
College Physics (4th Edition)
$E = \frac{k~q}{2~d^2}$
The electric field due to the point charge $q$ is directed in the positive x-direction. We can find the magnitude of the electric field due to the point charge $q$: $E_1 = \frac{k~q}{d^2}$ The electric field due to the point charge $2q$ is directed in the negative x-direction. We can find the magnitude of the electric field due to the point charge $2q$: $E_2 = \frac{k~(2q)}{(2d)^2} = \frac{k~q}{2~d^2}$ We can find the net electric field due to both point charges: $E = E_1-E_2$ $E = \frac{k~q}{~d^2}-\frac{k~q}{2~d^2}$ $E = \frac{k~q}{2~d^2}$
|
|
# Print all permutations with some constraints
I've the following problem:
Print all valid phone numbers of length n subject to following constraints:
2.No two consecutive digits can be same
3.Three digits (e.g. 7,2,9) will be entirely disallowed, take as input
Here's my solution:
public static void ans(int length, int d1, int d2, int d3) {
StringBuffer numbers = new StringBuffer();
for(int i = 0; i < 10 ;i++) {
if(i != d1 && i != d2 && i != d3) {
numbers.append(i);
}
}
printNumbers("", numbers.toString(), length);
}
public static void printNumbers(String soFar, String remaining, int length) {
if(soFar.length() == length) {
boolean four = false;
for(int i = 1; i < soFar.length(); i++) {
if(soFar.charAt(i-1) == soFar.charAt(i)) sameAdjDigits = true;
if(soFar.charAt(i) == '4') four = true;
}
if(!four || (four && soFar.charAt(0) == '4'))
System.out.print(soFar + " ");
}
return;
}
if(soFar.length() < length) {
for(int i = 0; i < remaining.length(); i++) {
String newSoFar = soFar + remaining.charAt(i);
String newRemaining = remaining.substring(0, i) + remaining.substring(i+1);
printNumbers(newSoFar, newRemaining, length);
}
}
}
I ran some tests on this code and checked all the printed values. It worked for length 1 and 2. However, I couldn't verify for length > 2 because there were too many numbers.
Can anyone verify if my code runs a correct result? Is there any part of the code that can be improved?
## Nitpicks
public static void ans(int length, int d1, int d2, int d3) {
Any time that I see numbered variables, I want to replace them with a collection. Since we know that there will be no duplicate values, I'd use a Set.
public static void generatePhoneNumbers(int length, Set<Character> disallowedDigits) {
Also, I find d an unclear name, so I switched to disallowedDigits which I find clearer.
I switched from int to Character as you are building a string. We could just as easily be working with the letters of the alphabet as with numeric digits.
StringBuffer numbers = new StringBuffer();
This seems an ideal place to use a StringBuilder.
StringBuilder digits = new StringBuilder();
I also changed the name to digits, as that tells me that we're talking about one digit at a time rather than multi-digit numbers.
if(!four || (four && soFar.charAt(0) == '4'))
You could just as well write
if( ! four || soFar.charAt(0) == '4' )
If the string begins with a 4, then we don't care if none of the rest have a 4.
## Fulfilling the Problem Statement
String newRemaining = remaining.substring(0, i) + remaining.substring(i+1);
This is actively wrong given your problem statement:
Print all valid phone numbers of length n subject to following constraints:
1. If a number contains a 4, it should start with 4
2. No two consecutive digits can be same
3. Three digits (e.g. 7,2,9) will be entirely disallowed, take as input
From #2, only consecutive digits can't be the same. So you should not be removing digits from your remaining String. Like length, that will be constant for all calls.
We can rewrite #1 to say: only numbers that start with 4 can contain 4. This effectively gives us different rules for 4 than other values. Since we're supposed to generate all numbers, I'd suggest that we generate all numbers starting with 4 separately from other numbers. Fortunately, #3 means that we already need a way to exclude digits from the set.
## ans
Here's how I'd write the method that you called ans:
private final static char [] DIGITS = "0123456789".toCharArray();
public static void generate(int length, Set<Character> disallowedDigits) {
Set<Character> allowedDigits = new TreeSet<Character>();
for ( Character digit : DIGITS ) {
if ( ! disallowedDigits.contains(digit) ) {
}
}
if ( allowedDigits.contains('4') ) {
printNumbers("4", allowedDigits, length);
allowedDigits.remove('4');
}
for ( Character digit : allowedDigits ) {
printNumbers("" + digit, allowedDigits, length);
}
}
First, we define a constant to hold the possible digit values. Then we make a new Set that masks out the disallowedDigits. If 4 is allowed, then we generate all the numbers that start with 4 separately. Then we remove 4 from the allowedDigits, as it won't be allowed in any of the other numbers.
## printNumbers
if(soFar.length() == length) {
boolean four = false;
for(int i = 1; i < soFar.length(); i++) {
if(soFar.charAt(i-1) == soFar.charAt(i)) sameAdjDigits = true;
if(soFar.charAt(i) == '4') four = true;
}
if(!four || (four && soFar.charAt(0) == '4'))
System.out.print(soFar + " ");
}
return;
}
This whole section of code is unnecessary, except for one line (the print). Instead of generating invalid strings and masking them out, just don't generate them in the first place. That will save all subsequent recursive calls down that path.
if(soFar.length() < length) {
for(int i = 0; i < allowedDigits.length(); i++) {
String newSoFar = soFar + allowedDigits.charAt(i);
String newRemaining = allowedDigits.substring(0, i) + allowedDigits.substring(i+1);
printNumbers(newSoFar, newRemaining, length);
}
}
I switched to a Set to hold the digits that can be used, so this is going to be a bit different.
private static void printNumbers(String soFar, Set<Character> allowedDigits, int length) {
int lengthSoFar = soFar.length();
if ( lengthSoFar < length ) {
Character last = soFar.charAt(lengthSoFar - 1);
for ( Character digit : allowedDigits ) {
if ( ! digit.equals(last) ) {
printNumbers(soFar + digit, allowedDigits, length);
}
}
} else {
System.out.println(soFar);
}
}
First, we already took care of 4 in our generate function. Here, it will either be in allowedDigits or it won't.
Second, we take care of the rule about consecutive digits by simply not starting the recursive generation in that case: if ( ! digit.equals(last) ) {.
I put each number on its own line. For all but trivial lengths, there are too many numbers to fit on a single line.
Note that soFar is the only parameter that changes from call to call.
## Testing
This is a bit difficult. Because we print the numbers to standard output, we can't run normal unit tests on them. The simplest way to handle this is to direct the output to a file. Then we can search the file for values that should or shouldn't be there.
For example, we should never have any of the following sequences: 00, 11, 22, 33, 44, 55, 66, 77, 88, 99, 00. So search for those in the file. If they don't exist, then you know that rule is working.
Search for lines containing the disallowedDigits. There shouldn't be any.
Find all the lines in the file that contain a 4 and verify that 4 is the first digit of the number. On Linux, that might be written something like
fgrep '4' < phone_numbers.txt | cut -c1 | sort | uniq -c
If there are any values other than 4, then you can look them up more specifically.
Also search for a few values that you construct, e.g. for a length of 8 where 7, 2, and 9 are disallowed, 40134568 should be in the list. Also 86868686 should be there.
You use the value soFar.length() multiple times in the printNumbers() method, or to be more specific, 2 + soFar.length() times. You can easily avoid retrieving the value that many times by creating a variable to hold the value:
int length = soFar.length();
Then replace all the soFar.length() with length.
What does four exactly mean? Use a more specific and more detailed (but not too much) variable name, such as hasFour.
The return is completely unnecessary. Instead, use else-if:
public static void printNumbers(String soFar, String remaining, int length) {
if(soFar.length() == length) {
boolean four = false;
for(int i = 1; i < soFar.length(); i++) {
if(soFar.charAt(i-1) == soFar.charAt(i)) sameAdjDigits = true;
if(soFar.charAt(i) == '4') four = true;
}
if(!four || (four && soFar.charAt(0) == '4'))
System.out.print(soFar + " ");
}
} else if(soFar.length() < length) {
for(int i = 0; i < remaining.length(); i++) {
String newSoFar = soFar + remaining.charAt(i);
String newRemaining = remaining.substring(0, i) + remaining.substring(i+1);
printNumbers(newSoFar, newRemaining, length);
}
}
}
Also, use braces for all if statements. Instead of:
if(soFar.charAt(i-1) == soFar.charAt(i)) sameAdjDigits = true;
if(soFar.charAt(i) == '4') four = true;
Do:
if(soFar.charAt(i-1) == soFar.charAt(i)) {
• IMO, there's nothing wrong with using the return; – Simon Forsberg Dec 26 '14 at 12:49
|
|
1 answer
# When are menu selection and form fill‐in more appropriate than direct manipulation?
###### Question:
When are menu selection and form fill‐in more appropriate than direct manipulation?
## Answers
#### Similar Solved Questions
1 answer
##### 10 Analyze the thermal power plant carefully and list all burn out products which are harm...
10 Analyze the thermal power plant carefully and list all burn out products which are harm (3.00 full for the environment. Give reasons for excessive pollution of the thermal power plants. The ash produced in the thermal power plants will it used for any useful purpose of it just goes as the land fi...
1 answer
##### Less than half of the time remains. Remaining Time: 21 minutes, 42 seconds. * Question Completion...
Less than half of the time remains. Remaining Time: 21 minutes, 42 seconds. * Question Completion Status: 48 A Moving to the next question prevents changes to this answer. Question 18 of 19 Question 18 12 points sum M Save Answer Un diente de 2 cm de altura se coloca a 4 cm enfrente de un espejo c&o...
1 answer
##### Bob is riding the giant drop at flags of America. If Bob free falls for 2.0 seconds, what will be his final velocity and how far will he fall?
Bob is riding the giant drop at flags of America. If Bob free falls for 2.0 seconds, what will be his final velocity and how far will he fall?...
1 answer
##### 4) A firm faces the demand curve, P-80-3Q, and has the cost equation, What is the...
4) A firm faces the demand curve, P-80-3Q, and has the cost equation, What is the equation for the firm's total revenue? 200+20Q. a) b) What is the equation for the firm's marginal revenue? c) What is the quantity that maximizes total revenue? d) Find the optimal quantity and price for the f...
1 answer
##### 19. Suppose that the central bank must follow a rule that requires it to increase the...
19. Suppose that the central bank must follow a rule that requires it to increase the money supply when the price level falls and decrease the money supply when the price level rises. If the economy starts from long-run equi- librium and aggregate demand shifts right, what must the central bank do, ...
1 answer
##### What is accrual?
what is accrual?...
1 answer
##### Question 1 (2 points) On June 30, Year 1, Kip Company had an unadjusted credit balance...
Question 1 (2 points) On June 30, Year 1, Kip Company had an unadjusted credit balance of $10,000 in its allowance for uncollectible accounts. An analysis of Kip’s trade accounts receivable at that date revealed the following: Age Amount <fonEstimated Uncollectible</fon 0-30 days$600,00...
1 answer
##### Need all the answers In the Time Card Forgeries case, name 2 significant weaknesses in the...
need all the answers In the Time Card Forgeries case, name 2 significant weaknesses in the Hospital's Internal Control: Are errors in Standing Payroll Data more or less serious than errors in Transaction Payroll Data? Explain your answer. Define Professional Skepticism. Auditing standards requir...
1 answer
|
|
8. Assessing Product Reliability
8.2. Assumptions/Prerequisites
## How do you choose an appropriate physical acceleration model?
Choosing a good acceleration model is part science and part art - but start with a good literature search
Choosing a physical acceleration model is a lot like choosing a life distribution model. First identify the failure mode and what stresses are relevant (i.e., will accelerate the failure mechanism). Then check to see if the literature contains examples of successful applications of a particular model for this mechanism.
If the literature offers little help, try the models described in earlier sections :
All but the last model (the Coffin-Manson) apply to chemical or electronic failure mechanisms, and since temperature is almost always a relevant stress for these mechanisms, the Arrhenius model is nearly always a part of any more general model. The Coffin-Manson model works well for many mechanical fatigue-related mechanisms.
Sometimes models have to be adjusted to include a threshold level for some stresses. In other words, failure might never occur due to a particular mechanism unless a particular stress (temperature, for example) is beyond a threshold value. A model for a temperature-dependent mechanism with a threshold at $$T = T_0$$ might look like $$\mbox{time to fail } = \frac{f(T)}{T - T_0} \, ,$$ for which $$f(T)$$ could be Arrhenius. As the temperature decreases towards $$T_0$$, time to fail increases toward infinity in this (deterministic) acceleration model.
Models derived theoretically have been very successful and are convincing In some cases, a mathematical/physical description of the failure mechanism can lead to an acceleration model. Some of the models above were originally derived that way.
Simple models are often the best In general, use the simplest model (fewest parameters) you can. When you have chosen a model, use visual tests and formal statistical fit tests to confirm the model is consistent with your data. Continue to use the model as long as it gives results that "work," but be quick to look for a new model when it is clear the old one is no longer adequate.
There are some good quotes that apply here:
Quotes from experts on models "All models are wrong, but some are useful." - George Box, and the principle of Occam's Razor (attributed to the 14th century logician William of Occam who said “Entities should not be multiplied unnecessarily” - or something equivalent to that in Latin).
A modern version of Occam's Razor is: If you have two theories that both explain the observed facts then you should use the simplest one until more evidence comes along - also called the Law of Parsimony
Finally, for those who feel the above quotes place too much emphasis on simplicity, there are several appropriate quotes from Albert Einstein:
"Make your theory as simple as possible, but no simpler."
"For every complex question there is a simple and wrong solution."
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.