5,430 research outputs found
Finding The Lazy Programmer's Bugs
Traditionally developers and testers created huge numbers of explicit tests, enumerating interesting cases, perhaps
biased by what they believe to be the current boundary conditions of the function being tested. Or at
least, they were supposed to.
A major step forward was the development of property testing. Property testing requires the user to write a few
functional properties that are used to generate tests, and requires an external library or tool to create test data
for the tests. As such many thousands of tests can be created for a single property. For the purely functional
programming language Haskell there are several such libraries; for example QuickCheck [CH00], SmallCheck
and Lazy SmallCheck [RNL08].
Unfortunately, property testing still requires the user to write explicit tests. Fortunately, we note there are
already many implicit tests present in programs. Developers may throw assertion errors, or the compiler may
silently insert runtime exceptions for incomplete pattern matches.
We attempt to automate the testing process using these implicit tests. Our contributions are in four main
areas: (1) We have developed algorithms to automatically infer appropriate constructors and functions needed
to generate test data without requiring additional programmer work or annotations. (2) To combine the
constructors and functions into test expressions we take advantage of Haskell's lazy evaluation semantics by
applying the techniques of needed narrowing and lazy instantiation to guide generation. (3) We keep the type
of test data at its most general, in order to prevent committing too early to monomorphic types that cause
needless wasted tests. (4) We have developed novel ways of creating Haskell case expressions to inspect elements
inside returned data structures, in order to discover exceptions that may be hidden by laziness, and to make
our test data generation algorithm more expressive.
In order to validate our claims, we have implemented these techniques in Irulan, a fully automatic tool for
generating systematic black-box unit tests for Haskell library code. We have designed Irulan to generate high
coverage test suites and detect common programming errors in the process
Recommended from our members
Gender mainstreaming and EU climate change policy
This article uses feminist institutionalism to examine how gender mainstreaming has been sidelined in European Union (EU) climate change policy. It finds that, with a few exceptions largely emanating from the European Parliament's Committee on Women's Rights and Gender Equality, EU responses to climate change are gender-blind. This is despite the Treaty obligations to gender mainstream policy in all areas and despite the intersections between climate change and development policy, which is renowned for having taken gender equality and women's empowerment seriously and for instigating gender mainstreaming and specific actions as a means to achieve them. The persistent invisibility of gender can be attributed to various forms of institutional resistance
Electroweak Symmetry Breaking without a Higgs Boson at the LHC
We present two studies into strong symmetry breaking scenarios at the LHC.
The first case is a study into vector boson scattering at ATLAS. This uses the
framework of the Electroweak Chiral Lagrangian with Pade unitarisation to
generate possible signal scenarios. Signals could be observed with an
integrated luminosity of 30 fb^{-1}. Secondly a search for the technirho,
rho_{TC}, at CMS is presented, within the Technicolour ``Straw Man'' model. 5
sigma discovery is possible starting from 4 fb^{-1}.Comment: 4 pages, to appear in the proceedings of 42st Rencontres de Moriond
on QCD and Hadronic interactions, La Thuile, Aosta Valley, Italy, 17-24 Mar
200
Bipyridine-porphyrin conjugates : a thesis presented in partial fulfilment of the requirements for the degree of Masterate of Science in Chemistry at Massey University
The research carried out for this thesis comprises an investigation into the synthesis of bipyridyl-bridged porphyrin compounds and their metal complexes. Chapter One introduces the bipyridine ligand and summarises research carried out on the functionalisation of 2,2'-bipyridine (bpy). A proposal for a novel study involving the connection of porphyrin functionalities to bpy via vinylic linking groups is discussed, and the Wittig methodology proposed to achieve this is described. Chapter Two outlines the synthesis of the 4,4'-diformyl-2,2'-bipyridine ligand necessary for the Wittig reaction to form the primary target compound, a bipyridyl-bridged bisporphyrinyl ligand. Synthesis of the bipyridine dialdehyde ligand had previously been reported via a four step procedure from 4,4'-dimethyl-2,2'-bipyridine in reasonable yield, a result which was unable to be reproduced. The methodology involved an oxidation of the dimethyl bipyridine to the corresponding dicarboxylic acid, esterification to the dimethylester, reduction to form the dialcohol, followed by an oxidation to the desired dialdehyde ligand. All attempts at this procedure, using various reagents for the final oxidation step, were either unsuccessful or resulted in very low yields of product. Thus an alternative single step SeO2 oxidation of 4,4'-dimethyl-2,2'-bipyridine to form the target dialdehyde was explored. Optimisation of this procedure gave an efficient one step synthesis of 4,4'-diformyl-2,2'-bipyridine, 4. Chapter Three discusses the synthesis of the porphyrin phosphonium salt, the second precursor required for this work. Tetra-meso-substituted porphyrin moieties were used so that the phosphonium salt appendage would be connected through one of the pyrrolic carbon atoms. A meso-tetraphenylporphyrin (TPP) phosphonium salt 5, had been synthesised in these laboratories, thus the synthetic methodology previously developed was repeated to make this Wittig precursor. The synthesis of a second, more soluble meso-tetraxylylporphyrin (TXP) phosphonium salt, 13, was also developed (an eight step synthesis from mesitylene and pyrrole) and optimised so as to improve the solubility of the resulting bpy compounds. Application of the Wittig reaction using dialdehyde 4, and the TPP phosphonium salt 13, is discussed in Chapter Four. Both the monomeric 4-(trans-2"-vinyl-TPPyl)-4'-formyl-2,2'- bipyridine, 14, and the dimeric 4,4'-(trans-2"-vinyl-TPPyl)-2,2'-bipyridine, 15, bipyridineporphyrin conjugates were successfully synthesised. The bipyridine ligand is connected to the porphyrin through a vinylic linking group to one of the pyrrolic positions (2-position) of the porphyrin ring. Bisporphyrinyl ligand 15, as expected, proved to be insoluble in organic solvents. Before continuing with the more soluble TXP phosphonium salt 13, some test metallation reactions were performed using the soluble monomeric porphyrinyl bipyridine ligand 14. Zinc was inserted into the porphyrin ring to form 4-[(trans-2"-vinyl- TPPato)zinc(II)]-4'-formyl-2,2'-bipyridine, 16. Coordination of rhenium to the bipyridyl moiety of the monomeric porphyrin ligand, formed the complex l,1'-Re(CO)3 Cl[4,4'-(trans-2"-vinyl-TPPyl)-4'-formyl-2,2'-bipyridine], 17. A subsequent Wittig reaction was carried out to form the complex l,1'-Re(CO)3 Cl[4,4'-(trans-2"-vinyl-TPPyl)-2,2'-bipyridine], 18. The remainder of Chapter Four reports the methodology developed for an efficient synthesis of the target bipyridyl-bridged dimeric porphyrin ligand 4,4'-(trans-2"-vinyl-TXPyl)-2,2'-bipyridine, 20, using the tetraxylylporphyrin phosphonium salt, TXP-CH2 PPh3 Cl, 13. Ligand 20 was first synthesised in two steps. Connection of one porphyrin ring to 4,4'-diformyl-2,2'-bipyridine 4, formed the monomeric porphyrin ligand, 4-(trans-2"-vinyl-TXPyl)-4'-formyl-2,2'-bipyridine, 19. A second Wittig reaction on this ligand resulted in the target bisporphyrinyl compound. A more efficient one step Wittig reaction was then investigated, resulting in a high yielding single step preparation of bisporphyrinyl bipyridine 20. Coordination of the metal ions Mo, Re, and Ru, to the bipyridyl moiety of the target bipyridyl-bridged tetraxylylporphyrin dimer 20, are described in Chapter Five. A monoporphyrinyl molybdenum-bound bipyridine complex, 1,1'-Mo(CO)4[4-(trans-2"- vinyl-TXPyl)-4'-formyl-2,2'-bipyridine], 22, was synthesised via a Wittig reaction from the bipyridyl molybdenum complex 1,1'-Mo(CO)4[4,4'-diformyl-2,2'-bipyridine], 21. The rhenium-bound bisporphyrinyl complex, 1,1'-Re(CO)3 Cl[4,4'-(trans-2"-vinyl-TXPyl)-2,2'- bipyridine], 23 was synthesised in a single step metallation reaction of the bisporphyrinyl bipyridine 20 with rhenium pentacarbonyl chloride. A bisporphyrinyl ruthenium(II) bipyridine complex l,1'-Ru(CO)2Cl2[4,4'-(trans-2"-vinyl-TXPyl)-2,2'-bipyridine], 25, was synthesised in a one step Wittig reaction from the Ru(II)bpy complex 1,1'- Ru(CO)2Cl2[4,4',-diformyl-2,2'-bipyridine], 24. The synthesis and characterisation of a tetraporphyrinyl ruthenium(II)bisbipyridine complex is also reported. l,1'-RuCl2[bis-4,4'-(trans-2"-vinyl-TXPyl)-2,2'-bipyrldlne], 27, was synthesised via a single step metallation reaction between bisporphyrinyl bipyridine 20 and a RuCl2 (DMSO)4 complex. Chapter Six contains a brief summary of the results obtained throughout this study and future work to be done in this area
Increasing women's representation in France and India
Cet article prĂ©sente la question de la reprĂ©sentation politique des femmes en France et en Inde. Tout dâabord, il vise Ă mettre en Ă©vidence comment la reprĂ©sentation des femmes Ă©tait inscrite Ă lâagenda politique de chaque pays. Ensuite, il propose un examen critique des arguments utilisĂ©s pour justifier la demande dâune meilleure reprĂ©sentation ainsi que de ceux pour sây opposer. Enfin, il considĂšre les conclusions que lâon peut tirer de ces deux cas. DĂ©passant les cadres comparatifs traditionnels utilisĂ©s par les fĂ©ministes occidentales et en contestant lâinsistance française sur l'idĂ©e d'une France unique, cet article identifie les particularismes et les points communs de chaque cas, pour tenter dâatteindre Ă ce que Shirin Rai appelle âun dĂ©passement enracinĂ© des frontiĂšres culturelles, historiques et politiques.â (Rai, 2000: 15)
Social and creative decision making
Research on human decision making is at the present time undergoing rapid changes. From previously being much focused on models and approaches with an origin in economy, much of the present day research finds its inspiration from disciplinary approaches concerned with incorporating more of the context that the decision making takes place in. This context includes psychological aspects of the decision maker and social-cultural aspects of the situation he or she acts in. All human decision making occurs in dynamically changing contexts. One factor contributing to this is that human beings or groups in many situations act as entrepreneurs trying to improve the situation for themselves or their organization. Given that this is the case, it is of increasing interest for both researchers and practitioners interested in the social aspects of decision making to consider the relation between creativity and decision making
Control of the switching behavior of ferromagnetic nanowires using magnetostatic interactions
Magnetostatic interactions between two end-to-end Permalloy (Ni80Fe20) nanowires have been studied as a function of their separation, end shape, and width. The change in switching field increases as the wires become closer, with deviations from the switching field of an isolated wire of up to 40% observed. The sign of the change depends on the relative magnetization orientation of the two wires, with higher fields for parallel magnetization and lower fields for antiparallel magnetization. A wire end shape has a strong influence, with larger field variations being seen for flat-ended wires than wires with tapered ends. The micromagnetic modeling and experiments performed here were in good qualitative agreement. The experimental control of switching behavior of one nanowire with another was also demonstrated using magnetostatic interactions
Enhanced longitudinal magnetooptic Kerr effect contrast in nanomagnetic structures
We report on enhanced longitudinal magnetooptic Kerr effect signal contrast in thin-film nanomagnetic disks with in-plane magnetization when combined with dielectric layers that provide impedance matching to the structure and the underlying substrate. Kerr signals can increase by a factor of three, while substrate reflectance is almost completely suppressed. This leads to an increase in Kerr ellipticity relative to the background intensity and a subsequent improvement in the measured signal-to-noise ratio. Measurements using a beam focused on opaque 400-nm Ni disks yield contrast improvements of a factor of 8. Arrays of nanodisks demonstrate more complex behavior due to diffraction effects
Recommended from our members
Transforming lives? CONCORD Report EU Gender Action Plan II: from implementation to impact
- âŠ