text:
1. 21

This is the weekly thread to discuss what you have done recently and are working on this week.

1.

2. 17

I just happened by Lobste.rs after many months, and will take a couple of paragraphs to explain my history before the past week, if anyone can bear with me..

For the past couple of years I’ve been researching ways to write software that make it easier for newcomers to understand rather than for insiders to maintain. In this quest I built a toy OS and Basic-like language called Mu which tries to “rhyme with” the design process by which Unix was coevolved with C. The big additional design constraint compared to Unix+C is to make the OS primitives testable. I want to be able to pretend in tests that we run out of memory or disk, that a context switch happens between these two instructions, and so on. My hypothesis is that having the ability to easily write such tests from day 1 would radically impact the culture of an eco-system in a way that no bolted-on tool or service at higher levels can replicate: it would enable new kinds of tests to be written and make it easier to be confident that an app is free from regression if all automated tests pass. This would make the stack easy to rewrite and simplify by dropping features, without fear that a subset of targeted apps might break. As a result people might fork projects more easily, and also exchange code between disparate forks more easily (copy the tests over, then try copying code over and making tests pass, rewriting and polishing where necessary). The community would have in effect a diversified portfolio of forks, a “wavefront” of possible combinations of features and alternative implementations of features instead of the single trunk with monotonically growing complexity that we get today. Application writers who wrote thorough tests for their apps (something they just can’t do today) would be able to bounce around between forks more easily without getting locked in to a single one as currently happens.

There’s more details on my site, perhaps starting from my mission statement. I’ll also add below a couple of hopefully tantalizing bullet lists.

A. The zen of Mu:

• tests, not interfaces
• be rewrite-friendly, not backwards-compatible
• be easy to port rather than portable
• global structure matters more than local hygiene

B. Mu’s vision of utopia:

• Run your devices with 1/1000th the code.
• 1000x more forks for open source projects.
• Make simple changes to (some carefully chosen fork of) any project in an afternoon, no matter how large it is. Gain an hour’s worth of understanding for an hour’s worth of effort, rather than a quantum leap in understanding after a week or month of effort.
• Projects don’t slow down with age, they continue to evolve just as fast as when they were first started.
• All software rewards curiosity, allowing anyone to query its design decisions, gradually learn how to tweak it, try out increasingly radical redesign ideas in a sandbox. People learn programming as an imperceptible side effect of tinkering with the projects they care about.
• Habitable digital environments.
• A literate digital society with widespread skills for comprehending large-scale software structure and comparing-and-contrasting similar solutions, even if most people can’t write an OS. (I don’t think anybody is literate by this definition today. All we can do easily is read our own programs that we wrote recently.)

(I know this is all extremely unconventional and risky. I might well be wasting my life barking up the wrong tree. But it seems promising enough to be worth one lifetime. And if someone can persuade me that it’s a bad idea I’ll gratefully take what’s left of my life back.)

Over 2 years I’ve at least failed to disprove some aspects of the hypothesis in Mu, and I’ve had some success teaching with it and getting feedback on the design in the process. I’ve managed to convince one person – smalina – to join me in my quest[1], and the two of us have been investigating ways to bring the lessons out of Mu and into a ‘real’ stack, one with a real compiler and libraries that would permit more ambitious programs to be written, and with an eco-system of apps that we can try to port to our approach. The challenge here is a chicken-and-egg problem: we can’t make radical changes to a real-world OS without (at least) years of understanding all the things it’s trying to do. After much soul-searching we’ve decided to experiment with OpenBSD, not least because of tedu’s writings which show that at least a few people understand this platform from end to end. I have zero confidence that that’s true of Linux anymore[2][3][4][5], at least past the kernel.

Anyway, after that lengthy prologue, here’s what we’ve been doing in recent weeks:

• Building a testable network interface. Both of us have extremely limited knowledge here, so we’re currently building a fake network just at the level of HTTP that will let us record and replay network events and so turn manual tests into reproducible automated ones.
• Getting into the guts of OpenBSD. So far we’ve gotten the ports tree to build from source (that was easy), but we’ve run into issues like how modifying /bin/ls/ls.c seems to unnecessarily recompile a large chunk of the ports tree.

Any critique of all this would be appreciated. Also help or pointers from people knowledgeable about OpenBSD. (Heh, I’d started to write about another issue in OpenBSD that had me stumped, but figured it out as I was writing. So this comment has already paid for itself.)

[1] He’s the one who reminded me of lobste.rs a couple of days ago, and here I am.

1. 3

Your project is interesting. I’d say check out Oberon System and Smalltalk-80 as they were both designed for doing a number of these goals. They were successful, too, where Oberon got extended and rewritten by many students in small time while Smalltalk did more amazing stuff in terms of extensions or modifications. A safe language with good abstractions and generic interfaces is a start. Concurrency bugs also hurt users so maybe integrate something like Concurrent Pascal or Eiffel’s SCOOP to make it all race-free by design. The only thing here that really sets off a red flag is how you’re going into testing philosophy so much that you appear to be eliminating interfaces or a focus on them. Evidence going back decades suggest that’s a mistake.

Let me illustrate with a simple example: a function only works if the input intN is between 20 and 80 stored in a 32-bit integer since that’s language default. Testing to make sure your function is behaving as expected requires testing every single input. That’s around 4 billion tests. Alternative is using specifications or Eiffel-style Design by Contract to force it to be correct without the test. Here’s the specification approach: On entry, IF (N >= 20) and (N <= 80) THEN perform function ELSE raise error. A simple, interface check makes the problem impossible.

This effect scales up as program size increases. Number of states, interactions, and compounds of states go up. So, testing has to basically run through them all without missing one to recreate all execution traces that could be a problem. The result is a huge pile of tests that probably still will miss something. Whereas, Eiffel, Ada/SPARK, Frama-C, and even smart asserts show very few statements in each function enforcing pre or post conditions can prevent or catch whole classes of errors. Plus errors you don’t see coming because you didn’t know series of steps that would lead to them. Amazon’s use of TLA+ to verify its distributed code gave example of an error that would’ve required a sequence of 30+ specific events to trigger. They said such things happen in production but that code passed their extensive testing. Model-checking caught the problem in no time then proved nothing like that could happen again in modified version in all executions.

So, I suggest taking an alternate approach where you figure out a better way to handle interfaces. Make sure invariants are encoded in them to prevent propagation of errors, preferrably at compile-time. These also serve as straight-forward documentation of exactly what the function expects and will do. Make it easy to change them in a plug-and-play fashion reducing how many interface checks or implementation files need to be changes. Also, write a bunch of tests and documentation. Overall result of a safe language with interface checks, docs, and tests will get you closer to your goal.

1. 2

Thanks! Yes, I am aware of those drawbacks of tests. Certainly there are some things that we can and should avoid by design, like memory corruption bugs, the races that you alluded to, and so on. Mu disallows out-of-bounds access by always having arrays know their length; eliminates memory corruption bugs by always refcounting allocations and only freeing memory when its refcount drops to 0; and avoids data races by transparently deep-copying any data passed through a channel between threads. These are things I definitely don’t want to rely on tests for. Seeing the word ‘security’ in your username reminds me that in encryption code in particular tests are of little use, at least the kinds of manually-created tests I’ve been talking about. For security you do want to be much more rigorous. The kinds of tests that can help there are Haskell’s QuickCheck tests and fuzzing (which I have very little experience with). But even those aren’t sufficient. I get the sense it just takes a lot more intensive effort per line of code to get good encryption libraries, and I don’t claim to be an expert in that area.

Invariants and Design by Contract are extremely useful ideas, absolutely. I’m aware of them, and I’m not trying to replace them. The mechanisms I’m working on are meant to complement them.

I wasn’t trying to say that we don’t need interfaces at all. Instead, my claim is that there’s a long history among programmers of thinking we’re managing complexity merely by dividing things into parts, without taking into account where we draw the dividing lines, the quality of the interfaces. There’s a huge bias to enshrine existing interfaces in the name of backward compatibility, and to force readers to navigate code based entirely on those interfaces. This leads in turn to a combinatorial explosion in the amount of code that runs on our devices, most of it just to support some internal interface or other that the end-user is utterly oblivious to. One of my favorite examples is this story which complains about Unix cat having grown to 800 LoC back in 2002. When I checked in 2013, cat in GNU coreutils had grown to 36 thousand lines of code! How much of that could we prune for people who don’t care about ancient platforms or arcane compatibility constraints like #ifdef _XOPEN_SOURCE? tedu has many more examples in his writings.

I don’t want to prevent people from making interfaces. I want to provide “escape hatches” that allow them to change those interfaces when a better interface becomes apparent, and to allow readers to understand the behavior of a library without having to understand its internal interfaces.

1. 2

Makes sense. I’ll add to your 2nd article that the high-assurance field solved part of your territory problem along time ago. What they did was create abstract, formal specifications of the design or the code. These told you what it was doing more than how. The constraints were encoded in that. The code was done in a way + tested to correspond to that. You could read an English description of it with the formal specs to know exactly what any part of your system would do under various circumstances. Similar effect is done with model-checkers like Amazon’s TLA work and provers like seL4 where they pulled specs right out of the code.

Of course, that’s pretty heavy. So, I mentioned lightweight version like Design-by-Contract where you encode the constraints in your code. The basic documentation + annotated code should by themselves tell you what you can or can’t do with a module. That applies to all execution traces, too. Then, tests can be derived from them + written for other stuff you couldn’t specify. The combo of these made for strong correctness early on and during modifications. So, something to keep in mind as you experiment with your testing and other assurance practices.

re cat That’s pretty crazy. I didn’t know about that one. My reference for how ridiculous stuff is was the PHK essay below. Enjoy if you didn’t have it. :)

https://queue.acm.org/detail.cfm?id=2349257

Note: There’s actually a nice, horrific illustration of where the test-only methods can go in this one. Of course, you still intend on good interfaces where possible. I doubt you’ll ever make such a monstrosity.

2. 11

I’m hacking on watchexec, a pure Rust (aka native) file watcher that runs commands when it detects modifications.

Currently I’m working on two things: creating a Homebrew tap, and figuring out the command-line UI.

Right now you can run it like this:

$watchexec src "make test" Wondering if it’s worth expanding that to handle multiple paths, like so: $ watchexec app lib test --exec rspec

Or if I should just relegate such functionality to something like a Watchfile.

Join me in the bikeshed, together we’ll decide on a color! No, seriously, opinions very much welcome here.

1. 5

Neat, you might want to check out justrun - github.com/jmhodges/justrun - which has a discussion of some of the design decisions and tradeoffs inherent in such a tool.

1. 1

Good spot. Definitely a few features worth borrowing, such as the ability to kill the running process if more events come in before it terminates.

2. 2

Fun! I wrote an inotify-based version in Go at one point, it’s quite a useful tool to have around. What are you using for file system notifications?

Edit:

• Regarding CLI, I looked into supporting multiple watched directories, but I found that wasn’t something I was using in practice, partly because
• I have a file filter that lets you do something like
$cmdwatch -p '^\w.*\.org$' -c make -d posts/

This only builds when I update the org-mode sources for my site.

1. 3

The notify crate is doing all the hard work of efficient platform-specific fs notifications. I need to put some time in and contribute a kqueue()-based monitor (BSD users are people too!).

I like the simplicity of filtering to sidestep multiple watched dirs. Will take a look at adding that.

1. 1

I’ll look into this. Rust has been on my list for a while, so it’ll be nice to look at code doing something I generally understand.

The inotify-only but was because I had a need to learn that for something else. Much prefer kqueue!

1. 1

Yeah since this is a shell over the notify crate there isn’t much code at all. This is my first real Rust project :)

2. 2

cmdwatch

In my honest, it would have been better named watchcmd. Just sounds more authoritative or something. :)

1. 1

To be fair, it was hacked together in a few hours, and “cmd^I” is better than “watchc^I”…

2. 7

This week I started poking at illumos. I’ve got a server running SmartOS, which has been good for learning the system administration bits again (it’s been a while since I ran a Solaris system), and this weekend I started digging through the kernel.

It’s the first time in a long while that I spent time on the weekends doing anything technical or really was even excited about doing anything technical, so there’s that.

1. 1

What are the main advantages of Illumos/SmartOS? What are the pitfalls? I’d be interested to hear the opinion of someone with some experience.

1. 4

Keep in mind that I’ve only just started using illumos, though I was a Solaris sysadmin years ago and ran OpenSolaris on my laptop in school for a while.

• ZFS
• Only just barely scratched the surface with dtrace and mdb, but I’m already enamoured
• Virtualisation built in, both in terms of OS containers (Zones) and KVM
• generally, I like the tools provided with the system. It is taking some getting used to, but it works for me.
• pkgsrc works, which means you can get pretty much the same packages you get anywhere else (and you don’t have to deal with IPS or SVR4 packages).

illumos Pitfalls:

• Having to learn some new tooling (ipadm and dladm for a lot of networking instead of just ifconfig, for example)
• I like SMF, but its config files are XML (at least they’re not YAML, I guess).
• Some distributions use IPS or SVR4 packaging, which are a pain to use (but I use them only to bootstrap pkgsrc).

• in-memory image makes upgrading pretty easy
• virtualise all the things
• setup was pretty easy

• by default, most config on the host isn’t persisted (so you have to drop in an SMF service and any scripts onto the persistent storage)
• it does take some getting used to

Expect a longer writeup once I’ve used it in anger more.

2. 6

I’m trying to figure out a reasonable API for a parsing library that provides all parse trees when the grammar is ambiguous. In C. The lack of garbage collection makes seemingly-obvious approaches (e.g. persistent data structures) tricky.

I’m making a small dent in the big stack of papers I heard about during Papers We Love Conf & Strange Loop.

I just got a partial laser-cut key tray prototype for a custom mechanical keyboard in the mail – I’m figuring out whether I want to adjust any positioning before I get the full key tray cut and start laying out the PCB.

Work: Bringing up a bootloader on new dev board, particularly its interactions with a crypto-authentication chip. After that, initial USB support in the firmware.

1. 1

I’d be interested in hearing more about this C parsing library API design; both at a high-level and also diving into why lack of GC is making your design hard (I can relate).

1. 2

Happy to take it to messages. I’m working on more organized writing (blog posts, documentation), but it’s probably a ways off, and thinking out loud may help.

2. 5

Just thinking of giving mezzano (operating system implemented with Common Lisp) a try, has anyone played with it?

1. 3

I think I gave it a spin last year. It took a little bit of work to get running in VirtualBox, and I seem to remember there wasn’t much to do besides hack on lisp and hang out on IRC inside the OS.

2. 4

I put up a landing page for a project I’ve been noodling on off-and-on for close to 20 years: http://www.browsethesource.com/

I plan to work on it this fall and release a beta.

1. 2

What’s this gonna be, like Google Grok?

1. 3

The barebones version will be a single page app with an explorer tree on the left, a search bar on top and the main workspace for viewing code. Each symbol in the code viewer, when clicked, opens a search result under the line it on which defaults to the current file and can be expanded to any part of the tree with a breadcrumb path interface. The search bar would show results for the search in the main workspace.

The beta will be “demo mode” only meaning I will pick a bunch of popular git repos and the system will only run against them. If it gets traction I’ll open it up to user defined public and private git repos using the same pricing model as GitHub - free for public, pay for private. Beyond that, I have lots of other ideas for business models to sustain development and lots of ideas of where to go after version 0.1 - mostly around it customizing its UI or search behavior based on the project type and also how to annotate and publish explorations of code.

I actually built a Windows app very much like it in 1996 that generated static html files but never released it (I called it “HyperCross” because in 1996 “Hyper” was cool) and a few years ago I built an online version called sherlockcode.com but its interface was too kludgy. I’m hoping the 3rd time is the charm or maybe I’m just proving the definition of insanity.

2. 4

I’m in Vancouver currently, on my way back from Alaska and at the 7,000 mile mark of the long road trip. It has been quite an experience, even got roared at by a bear next to our tent at the Icefields in Jasper!

The rest of the week will include spending a day in Vancouver, a day in Seattle, and then taking time to get back to the Bay Area. A few days of rest then I’ll be excited to start working and hacking again. It has been so nice to sit in the car and read various PDFs posted here. Thank you all for helping keep my mind off the long, long road.

1. 4

I was sick last week so I only had time for a single Ansible role: ansible-role-syncthing. I’m feeling better but I’m no longer unemployed so I won’t have time to finish my go file browser.

I still need to find an lightweight encrypted remote backup software.

1. 2

Is tarsnap an option? It’s a paid service, but it’s cheap. Very very very cheap.

1. 2

For backups, I’m using duplicity + rsync to push backups. I couldn’t find anything lighter.

1. 1

Ooh thanks, that looks like it’ll solve a problem I currently have.

2. 1

Is your go file browser source available somewhere?

1. 1

Camlistore? Or is that too heavy?

1. 1

Does camlistore support files? Last I used it, I don’t recall it supporting file backups.

2. 3

Gradually putting the pieces in place for a transient session API for triton. Intending on writing the server in ruby initially rather than Node.js (the rest of the APIs provided by triton are written in JS, but I know ruby better and I’ll never be motivated to do it if I write it in JS.)

So far I’ve got a bare bones JSON logger (port of node-bunyan), and am now implementing a library to handle HTTP Signature Authentication using SSH private keys to sign the payload. (See the spec for that here). In practice the triton API is really neat using your ssh key to authenticate with - basically means to add new users to the system you just create them a user with their ssh fingerprint attached and they have access with cli tools. Perfect.

Other projects have stagnated recently, gave up messing with the car and handed it to my lovely mechanic to replace the clutch & investigate the cooling system not working properly. Diagnosed that as the fan not working properly - having replaced that it appears (touch wood) to be working so far.

Also need to get over to the boat, having replaced the block of wood the mast steps into I increased the height of the step by about 5mm not realising there was a pin that needs to locate into the mast higher up. Which is of course now 5mm out of alignment so I can’t finish stepping the mast currently. Need to take some shims of the right size over to relocate that pin higher off the deck by 5mm so the mast is properly secured. I will get her in the water this year, honest!

1. 3

Working on the next release of the EventQL database this week. The release will include little new features but mainly performance improvements for what’s already there – we’re aiming to support up to 10TB new data/day (3PB/yr) with the next version.

If anybody is interested in contributing to EventQL or discussing some internals/architecture, please hit us up!

1. 3

I’ve got a wireframe concept version of my microphone driven game. Working title is “You Noisy”. I ended up going with matter.js for physics (instead of box2d.js) since it was purpose built for web and mobile, so has a friendlier API. Now that I have some experience with the lib, this week I will continue development of the game. Once the mechanics are a bit tighter I will throw together some basic art and get out of wireframe land.

1. 2

That sounds fun! On the converse idea of using audio output as a primary source of feedback, there was a Gameboy Advance game called SoundVoyager. With only stereo and volume to give relative position and proximity, the games were all pretty elementary: collect instruments to build up a multi-layered track; shoot at monsters you can hear but not see; drive on a highway and avoid collisions by sound alone. It was really something different and I found it enjoyable.

1. 1

Ooh that game looks great, thanks for the link!

Indeed, sound is an interface that is vastly underused, besides music and sound effects. And when mentioned most people only jump to language as the conclusive interface. I can’t wait to watch my friends screaming like maniacs at their phone trying to move an object around the screen.

2. 1

My brother had made a Ludum Dare game that was going to be microphone driven a few years back in javascript as well. He didn’t have time to get a complete mechanic out of it, so instead he switched to controls via whistling volume. If you’d like, I can reach out to him and see if that code is still available.

3. 2

Thinking of porting Clojure hiccup to Elixir. Otherwise, I’ll be looking into how to add an update operation to BedquiltDB.

1. 2

I’ve been working on a blog post using interactive visualizations to explain why there is no quintic formula. My goal is to have it be convincing with the reader just having some familiarity with basic group theory and complex functions; this is possible because the proof I’m basing this on is topological and sidesteps all the hard Galois theory stuff.

As part of this, I also ported my blog to use KaTeX instead of MathJax, which makes it much faster to render math. :) The only downside is that KaTeX doesn’t have quite the full range of available commands that MathJax has, so I had to find a bunch of workarounds.

(This is my first lobsters post!)

1. 2

OEC Monday, Wednesday, and Saturday. Also drag link parts for my Jeep should be arriving sometime this week, so I’ll be trying to install those sometime this week as well.

1. 2

Attempting to get a release candidate ready by Wednesday. Might end up slipping to Friday but I’ll try my best.

1. 2

Just finished moving into my new appartment, so I’ll mostly be working on undoing my boxes and tidying up the place! At work, besides fixing the usual bugs, I’m still trying to get better test coverage.

1. 2

Trying to figure out what the hell is wrong with my server, hardware-wise. I think I’ve isolated it down to the CPU or motherboard. (And today, it seems more stable than it was before - sometimes it reboots in minutes, sometimes half a day…)

Programming wise, polishing my app up, and that generally means workflow wise, I come up with a feature, implement a backend, implement it in Windows Forms, then I implement it again in GTK#. GTK# isn’t terrible to work with, but it can be clumsy in some aspects.

edit: Filed an RMA with MSI. Wish me luck…

1. 1

How are you debugging the server issues?

1. 1

Process of elimination with each part. Swapped PSU, no change. Removed HD, no change. Tried various combinations of RAM, no consistent change. It’ll die at firmware, in ESXi, and randomly (not any specific test) in Memtest86.

2. 2

I will be spending most of my time looking for an interesting internship where I can use Ruby. Replying to emails and phone calls about that. And on the side, starting this little startup thing about driving instructors on demand that I’m trying to make into a “any kind of service on demand”.

1. 1

Good luck with the search!

2. 2

I’ll be testing out and debugging a specific format output that I finished adding to an HLA logger last week. Capturing all the messages sent between components in a small scale distributed simulation and saving them in a truly archaic format, what fun!

For funsies, I started ES6 / browser / canvas stuff to try to recreate “Differential Line” in a different platform, but with spatial indexing (quadtree) to make it go faster. As I left it yesterday, I was visualizing points and neighborhoods of points and building quadtrees successfully and thinking about how I wanted to update them (or simply rebuild them) as points move. I might finish the recreation this week.

1. 1

Startup Week! TC

1. 1

Working on building a Sails based RSS example app that uses our personalization API for the machine learning side of things.

1. 1

Not necessarily attending, but enjoying the side effects (bike races eg crossvegas, film screenings, friends in town) of Interbike coming to my hometown ?

1. 1

Learning to do sales having completed an MVP of projectlemma.com. Advice and feedback welcome!

1. 1
• Goofing around with Alpine Linux on my laptop (it’s great - very similar to OpenBSD, it just lacks the good defaults OpenBSD provides).
• Writing some gamedev stuff for a new YouTube series (going to write a prototype in Love2D this week, then work on a full-fledged C engine with SDL or Allegro).
• Trying to find a sane video processing library so I can write a scriptable video editor (because everything is clicky-clicky in all the GUI-happy ones I use). FFMPEG and gstreamer are terribly low level, the docs are dense and a lot of example code doesn’t work.
I might try something like MLT again, but I haven’t had a whole lot of luck with docs/finding working examples. If anyone knows of good video processing libs for C (maybe C++ if it’s not too crazy), Lua, Ruby or Scheme, I’d be grateful to learn about them.
If nothing crops up, I’ll probably just bite the bullet and write some Blender plugins to help me, since that seems to be the only scriptable video editor out there.
• School stuff - lots of linear algebra homework. It all makes sense, I just have to make time to do it.
1. 1

I finished my internship in Munich last Friday, and moved to London on Saturday. Now I’m spending the week at my parents house in Northern England for a holiday :)

I’m planning on looking at two things this week:

• Programming With Prolog (a requirement for University next year).
• Rust; I started writing an ARM emulator a few weeks ago, and promptly realised that I should take the time to understand the language more deeply first; lifetimes and ownership in particular were concepts that I didn’t pick up simply through using them. My first voyages into Rust-land were great fun though; it feels like a language that I can come to really enjoy working with.
1. 1

Building a replacement for MDP (terminal presentation tool) in rust. I have code blocks with syntax highlighting and most of the element types sorted, now working on parsing and auto margins.

Trying to decide if Tables, Footnotes, etc should be in first release, open to opinions.

1. 1

My team at work was disbanded (I joined 6 months ago), and I’ve landed on one of the teams I was working with. Still trying to figure out whether I’ll stay at the company and in what capacity (they’ve all been great about trying to make it work for me). Wasn’t happy with the direction of certain things anyway, but now I’m rethinking everything (i.e., what do I want to do?). :)


text:
# Search by Topic

#### Resources tagged with Generalising similar to Pythagoras’ Comma:

Filter by: Content type:
Stage:
Challenge level:

### Odd Differences

##### Stage: 4 Challenge Level:

The diagram illustrates the formula: 1 + 3 + 5 + ... + (2n - 1) = nÂ² Use the diagram to show that any odd number is the difference of two squares.

##### Stage: 3 Challenge Level:

Great Granddad is very proud of his telegram from the Queen congratulating him on his hundredth birthday and he has friends who are even older than he is... When was he born?

### Litov's Mean Value Theorem

##### Stage: 3 Challenge Level:

Start with two numbers and generate a sequence where the next number is the mean of the last two numbers...

### Handshakes

##### Stage: 3 Challenge Level:

Can you find an efficient method to work out how many handshakes there would be if hundreds of people met?

### Loopy

##### Stage: 4 Challenge Level:

Investigate sequences given by $a_n = \frac{1+a_{n-1}}{a_{n-2}}$ for different choices of the first two terms. Make a conjecture about the behaviour of these sequences. Can you prove your conjecture?

### Keep it Simple

##### Stage: 3 Challenge Level:

Can all unit fractions be written as the sum of two unit fractions?

### Egyptian Fractions

##### Stage: 3 Challenge Level:

The Egyptians expressed all fractions as the sum of different unit fractions. Here is a chance to explore how they could have written different fractions.

### Chocolate Maths

##### Stage: 3 Challenge Level:

Pick the number of times a week that you eat chocolate. This number must be more than one but less than ten. Multiply this number by 2. Add 5 (for Sunday). Multiply by 50... Can you explain why it. . . .

##### Stage: 4 Challenge Level:

A counter is placed in the bottom right hand corner of a grid. You toss a coin and move the star according to the following rules: ... What is the probability that you end up in the top left-hand. . . .

### All Tangled Up

##### Stage: 3 Challenge Level:

Can you tangle yourself up and reach any fraction?

### Semi-square

##### Stage: 4 Challenge Level:

What is the ratio of the area of a square inscribed in a semicircle to the area of the square inscribed in the entire circle?

### What's Possible?

##### Stage: 4 Challenge Level:

Many numbers can be expressed as the difference of two perfect squares. What do you notice about the numbers you CANNOT make?

### More Twisting and Turning

##### Stage: 3 Challenge Level:

It would be nice to have a strategy for disentangling any tangled ropes...

### Triangle Numbers

##### Stage: 3 Challenge Level:

Take a look at the multiplication square. The first eleven triangle numbers have been identified. Can you see a pattern? Does the pattern continue?

### Sum Equals Product

##### Stage: 3 Challenge Level:

The sum of the numbers 4 and 1 [1/3] is the same as the product of 4 and 1 [1/3]; that is to say 4 + 1 [1/3] = 4 × 1 [1/3]. What other numbers have the sum equal to the product and can this be so for. . . .

### Tourism

##### Stage: 3 Challenge Level:

If you can copy a network without lifting your pen off the paper and without drawing any line twice, then it is traversable. Decide which of these diagrams are traversable.

### Winning Lines

##### Stage: 2, 3 and 4

An article for teachers and pupils that encourages you to look at the mathematical properties of similar games.

### Jam

##### Stage: 4 Challenge Level:

A game for 2 players

### Nim-like Games

##### Stage: 2, 3 and 4 Challenge Level:

A collection of games on the NIM theme

### Sums of Pairs

##### Stage: 3 and 4 Challenge Level:

Jo has three numbers which she adds together in pairs. When she does this she has three different totals: 11, 17 and 22 What are the three numbers Jo had to start with?”

### Nim-interactive

##### Stage: 3 and 4 Challenge Level:

Start with any number of counters in any number of piles. 2 players take it in turns to remove any number of counters from a single pile. The winner is the player to take the last counter.

### Nim

##### Stage: 4 Challenge Level:

Start with any number of counters in any number of piles. 2 players take it in turns to remove any number of counters from a single pile. The loser is the player who takes the last counter.

### Go Forth and Generalise

##### Stage: 3

Spotting patterns can be an important first step - explaining why it is appropriate to generalise is the next step, and often the most interesting and important.

### Konigsberg Plus

##### Stage: 3 Challenge Level:

Euler discussed whether or not it was possible to stroll around Koenigsberg crossing each of its seven bridges exactly once. Experiment with different numbers of islands and bridges.

### Pair Products

##### Stage: 4 Challenge Level:

Choose four consecutive whole numbers. Multiply the first and last numbers together. Multiply the middle pair together. What do you notice?

### Lower Bound

##### Stage: 3 Challenge Level:

What would you get if you continued this sequence of fraction sums? 1/2 + 2/1 = 2/3 + 3/2 = 3/4 + 4/3 =

### Mini-max

##### Stage: 3 Challenge Level:

Consider all two digit numbers (10, 11, . . . ,99). In writing down all these numbers, which digits occur least often, and which occur most often ? What about three digit numbers, four digit numbers. . . .

### Pareq Calc

##### Stage: 4 Challenge Level:

Triangle ABC is an equilateral triangle with three parallel lines going through the vertices. Calculate the length of the sides of the triangle if the perpendicular distances between the parallel. . . .

### Converging Means

##### Stage: 3 Challenge Level:

Take any two positive numbers. Calculate the arithmetic and geometric means. Repeat the calculations to generate a sequence of arithmetic means and geometric means. Make a note of what happens to the. . . .

### AMGM

##### Stage: 4 Challenge Level:

Can you use the diagram to prove the AM-GM inequality?

### Special Sums and Products

##### Stage: 3 Challenge Level:

Find some examples of pairs of numbers such that their sum is a factor of their product. eg. 4 + 12 = 16 and 4 × 12 = 48 and 16 is a factor of 48.

### Games Related to Nim

##### Stage: 1, 2, 3 and 4

This article for teachers describes several games, found on the site, all of which have a related structure that can be used to develop the skills of strategic planning.

### Shear Magic

##### Stage: 3 Challenge Level:

What are the areas of these triangles? What do you notice? Can you generalise to other "families" of triangles?

### Take Three from Five

##### Stage: 3 and 4 Challenge Level:

Caroline and James pick sets of five numbers. Charlie chooses three of them that add together to make a multiple of three. Can they stop him?

### Picturing Square Numbers

##### Stage: 3 Challenge Level:

Square numbers can be represented as the sum of consecutive odd numbers. What is the sum of 1 + 3 + ..... + 149 + 151 + 153?

### Picturing Triangle Numbers

##### Stage: 3 Challenge Level:

Triangle numbers can be represented by a triangular array of squares. What do you notice about the sum of identical triangle numbers?

### Painted Cube

##### Stage: 3 Challenge Level:

Imagine a large cube made from small red cubes being dropped into a pot of yellow paint. How many of the small cubes will have yellow paint on their faces?

### More Number Pyramids

##### Stage: 3 and 4 Challenge Level:

When number pyramids have a sequence on the bottom layer, some interesting patterns emerge...

### Partially Painted Cube

##### Stage: 4 Challenge Level:

Jo made a cube from some smaller cubes, painted some of the faces of the large cube, and then took it apart again. 45 small cubes had no paint on them at all. How many small cubes did Jo use?

### What Numbers Can We Make?

##### Stage: 3 Challenge Level:

Imagine we have four bags containing a large number of 1s, 4s, 7s and 10s. What numbers can we make?

### Christmas Chocolates

##### Stage: 3 Challenge Level:

How could Penny, Tom and Matthew work out how many chocolates there are in different sized boxes?

### Plus Minus

##### Stage: 4 Challenge Level:

Can you explain the surprising results Jo found when she calculated the difference between square numbers?

### Mystic Rose

##### Stage: 3 Challenge Level:

Use the animation to help you work out how many lines are needed to draw mystic roses of different sizes.

### Multiplication Arithmagons

##### Stage: 4 Challenge Level:

Can you find the values at the vertices when you know the values on the edges of these multiplication arithmagons?

### Generating Triples

##### Stage: 4 Challenge Level:

Sets of integers like 3, 4, 5 are called Pythagorean Triples, because they could be the lengths of the sides of a right-angled triangle. Can you find any more?

### Route to Infinity

##### Stage: 3 and 4 Challenge Level:

Can you describe this route to infinity? Where will the arrows take you next?

### What Numbers Can We Make Now?

##### Stage: 3 and 4 Challenge Level:

Imagine we have four bags containing numbers from a sequence. What numbers can we make now?

### Steps to the Podium

##### Stage: 2 and 3 Challenge Level:

It starts quite simple but great opportunities for number discoveries and patterns!

### Magic Letters

##### Stage: 3 Challenge Level:

Charlie has made a Magic V. Can you use his example to make some more? And how about Magic Ls, Ns and Ws?

### Steel Cables

##### Stage: 4 Challenge Level:

Some students have been working out the number of strands needed for different sizes of cable. Can you make sense of their solutions?

format: plain


text:
Frequently Asked Question List for TeX

# Contributing to the FAQ

Thanks for considering contributing to the TeX FAQ: feedback, fixes and ideas are all useful.

## ChangeLog, commit messages and authors

Please note any significant change to the content of questions in CHANGELOG.md, including which question is changed in the format Q-<name>.

Commit messages where the content of a single question is changed should start with Q-<name>. Changes to the content of questions should always be made in separate commits: formatting, typos or other ‘non-significant’ changes can be made for multiple questions in one go. When you change the content of an answer, please update the date line at the bottom of the page.

If you are making a significant change to the content, please make sure you add yourself to the contributors list.

## Categories and tags

Every question in the FAQ should belong to exactly one category: this is specified in the YAML header of the source, for example

---
title: What's wrong with \bf, \it, etc.?
category: usage
date: 2014-06-10
---

The aim of the categories is to be relative broad-brush such that the total number remains manageable. The current set of categories is used to auto-generate the main index: this should be consulted when creating new questions (or proposing revision of the categories).

Questions may also have one or more tags, again specified in the YAML, for example:

---
title: Master and slave counters
category: programming
tags:
- latex
- macros
date: 2014-06-10
---

At present, the total number of tags is small, and not all questions are tagged. Unlike categories, questions may have no tags or multiple tags, and the set of tags is expected to grow over time. The current set of tags are listed in the questions-by-tag page.

## Formatting

The online TeX FAQ is written in GitHub-flavoured Markdown, and uses the GitHub Pages system to convert this to web pages. In general, Markdown is easy to use, and offers enough formatting power to make the FAQ useful. There are a few things to watch out for

• The Jekyll ‘back-end’ used by GitHub Pages is somewhat picky about unbalanced braces ({ and }), even in code blocks. That’s because it is looking for some instructions of its own there. To turn this off, surround the relevant parts of your source with

<!-- {% raw %} -->

and

<!-- {% endraw %} -->

(Typically these will go just before and after the  lines.)

• Only use block quotes for real quotations: use code markup for terminal output and similar

• We use the following HTML entities for special characters:
• … Ellipsis
• — Em-dash
• – En-dash
•   Non-breaking space
• quotes you can use ASCII double and single quotes, which will be changed to typographical quotes: "abc" 'abc' abc's produces “abc” ‘abc’ abc’s.

• Please wrap source lines to keep them below 80 characters long

## New questions

• File names should be of the form FAQ-<name>.md, where the <name> is made up of characters ASCII letters, numbers and “-“ only.
• If the <name> part is not all lower case, add a redirect_from:` entry in the fronmatter of the page redirecting from the lowercase.


text:
# History of logarithms - Wikiwand

Polygons Geometry, Similarity – Mathplanet

Stay with us. We aren't speaking in a differently language (unless you consider Latin to be a  Some of the important formulas used in trigonometric ratios are listed below:- Let, \theta be the reference angle, then side AB = P opposite to \theta is called  Trig Ratios. Students will use the Cabri™ Jr. App to discover the relationship between the trigonometric functions of sine, cosine and tangent and the side length  There are 3 major functions of an angle commonly used in Trigonometry. This week we're going to be learning about Trigonometric Ratios. Sine (sin), Cosine (cos)  Hämta och upplev Trig Ratios - Sin, Cos, Tan på din iPhone, iPad och way to learn, practice and reinforce the basic trigonometric functions:. Select and use appropriate trigonometric ratios in right-angled triangles to find unknown sides and unknown angles. To get you started watch the YouTube video  Learn basic trigonometry through 5 basic lessons: • Similar Triangles • Trigonometric Ratios • Inverse Trigonometric Ratios • Sine Law • Cosine Law Once you've  This app helps you to get rid out of trigonometric questions and problems?

Logga inellerRegistrera. Fiddly bits. Fiddly bits. Göm denna mapp från elever. 1. Unit circle. Unit circle.

Trig Word Search Wordsearch. av Dmcgee1. G9 G10 G11 TRIG RATIOS DEFINITIONS Labyrint-jakt.

### Ncert Solution For 12 Maths Chapter Integration

Trigonometric Formulas – Right Angle.

So, how many ratios pertaining to the sides of  The 3 primary trigonometric ratios are: sine (sin), cosine (cos) and tangent (tan). For a given angle, A, the primary trig ratios are defined as follows: Sin(A) =  3 Jan 2012 Sine, Cosine and Tangent are the basic trigonometric ratios. Cosecant, Secant and Cotangent are reciprocals (inverted fractions) of Sine,  Trigonometric Ratios.
Socionomprogrammet göteborg schema

0º, 30º, 45º, 60º, 90º. The trigonometric ratios.

The other three ratios are derived from the above three mentioned ratios. They are cosecant, secant, and cotangent which are the reciprocals of sine, cosine and tangent. Tangent ratios along with cosine and sine ratios are ratios of two different sides of a right triangle. Worksheets with trigonometry questions trigonometry questions 1.
Militära betyg

stor kransstomme
volkswagen jobbörse wolfsburg
akutmottagning umeå telefonnummer
masscentrum flervariabelanalys
glasmästare haninge
biltillverkning i världen
nilssons el östersund

### Sin Trig Identities 2020 - viedis.owlies.com

In a right triangle, the six trigonometric ratios; the  Students investigate and discover trigonometric ratios by drawing and measuring side lengths for five triangle. trigonometry, trigonometric ratio, sine, sin, cosi. 11 Dec 2020 Base (Adjacent side to the angle). In a right triangle, the following trigonometric ratios can be defined: Sine. The sine of the angle B is the ratio  Looking at the values of Trigonometric functions.


text:
# 2.4 Complex numbers  (Page 3/8)

 Page 3 / 8

## Multiplying a complex number by a complex number

Multiply: $\text{\hspace{0.17em}}\left(4+3i\right)\left(2-5i\right).$

$\begin{array}{ccc}\hfill \left(4+3i\right)\left(2-5i\right)& =& 4\left(2\right)-4\left(5i\right)+3i\left(2\right)-\left(3i\right)\left(5i\right)\hfill \\ & =& 8-20i+6i-15\left({i}^{2}\right)\hfill \\ & =& \left(8+15\right)+\left(-20+6\right)i\hfill \\ & =& 23-14i\hfill \end{array}$

Multiply: $\text{\hspace{0.17em}}\left(3-4i\right)\left(2+3i\right).$

$18+i$

## Dividing complex numbers

Dividing two complex numbers is more complicated than adding, subtracting, or multiplying because we cannot divide by an imaginary number, meaning that any fraction must have a real-number denominator to write the answer in standard form $\text{\hspace{0.17em}}a+bi.\text{\hspace{0.17em}}$ We need to find a term by which we can multiply the numerator and the denominator that will eliminate the imaginary portion of the denominator so that we end up with a real number as the denominator. This term is called the complex conjugate of the denominator, which is found by changing the sign of the imaginary part of the complex number. In other words, the complex conjugate of $\text{\hspace{0.17em}}a+bi\text{\hspace{0.17em}}$ is $\text{\hspace{0.17em}}a-bi.\text{\hspace{0.17em}}$ For example, the product of $\text{\hspace{0.17em}}a+bi\text{\hspace{0.17em}}$ and $\text{\hspace{0.17em}}a-bi\text{\hspace{0.17em}}$ is

$\begin{array}{ccc}\hfill \left(a+bi\right)\left(a-bi\right)& =& {a}^{2}-abi+abi-{b}^{2}{i}^{2}\\ & =& {a}^{2}+{b}^{2}\hfill \end{array}$

The result is a real number.

Note that complex conjugates have an opposite relationship: The complex conjugate of $\text{\hspace{0.17em}}a+bi\text{\hspace{0.17em}}$ is $\text{\hspace{0.17em}}a-bi,$ and the complex conjugate of $\text{\hspace{0.17em}}a-bi\text{\hspace{0.17em}}$ is $\text{\hspace{0.17em}}a+bi.\text{\hspace{0.17em}}$ Further, when a quadratic equation with real coefficients has complex solutions, the solutions are always complex conjugates of one another.

Suppose we want to divide $\text{\hspace{0.17em}}c+di\text{\hspace{0.17em}}$ by $\text{\hspace{0.17em}}a+bi,$ where neither $\text{\hspace{0.17em}}a\text{\hspace{0.17em}}$ nor $\text{\hspace{0.17em}}b\text{\hspace{0.17em}}$ equals zero. We first write the division as a fraction, then find the complex conjugate of the denominator, and multiply.

Multiply the numerator and denominator by the complex conjugate of the denominator.

$\frac{\left(c+di\right)}{\left(a+bi\right)}\cdot \frac{\left(a-bi\right)}{\left(a-bi\right)}=\frac{\left(c+di\right)\left(a-bi\right)}{\left(a+bi\right)\left(a-bi\right)}$

Apply the distributive property.

$=\frac{ca-cbi+adi-bd{i}^{2}}{{a}^{2}-abi+abi-{b}^{2}{i}^{2}}$

Simplify, remembering that $\text{\hspace{0.17em}}{i}^{2}=-1.$

$\begin{array}{l}=\frac{ca-cbi+adi-bd\left(-1\right)}{{a}^{2}-abi+abi-{b}^{2}\left(-1\right)}\hfill \\ =\frac{\left(ca+bd\right)+\left(ad-cb\right)i}{{a}^{2}+{b}^{2}}\hfill \end{array}$

## The complex conjugate

The complex conjugate    of a complex number $\text{\hspace{0.17em}}a+bi\text{\hspace{0.17em}}$ is $\text{\hspace{0.17em}}a-bi.\text{\hspace{0.17em}}$ It is found by changing the sign of the imaginary part of the complex number. The real part of the number is left unchanged.

• When a complex number is multiplied by its complex conjugate, the result is a real number.
• When a complex number is added to its complex conjugate, the result is a real number.

## Finding complex conjugates

Find the complex conjugate of each number.

1. $2+i\sqrt{5}$
2. $-\frac{1}{2}i$
1. The number is already in the form $\text{\hspace{0.17em}}a+bi.\text{\hspace{0.17em}}$ The complex conjugate is $\text{\hspace{0.17em}}a-bi,$ or $\text{\hspace{0.17em}}2-i\sqrt{5}.$
2. We can rewrite this number in the form $\text{\hspace{0.17em}}a+bi\text{\hspace{0.17em}}$ as $\text{\hspace{0.17em}}0-\frac{1}{2}i.\text{\hspace{0.17em}}$ The complex conjugate is $\text{\hspace{0.17em}}a-bi,$ or $\text{\hspace{0.17em}}0+\frac{1}{2}i.$ This can be written simply as $\text{\hspace{0.17em}}\frac{1}{2}i.$

Find the complex conjugate of $\text{\hspace{0.17em}}-3+4i.$

$-3-4i$

Given two complex numbers, divide one by the other.

1. Write the division problem as a fraction.
2. Determine the complex conjugate of the denominator.
3. Multiply the numerator and denominator of the fraction by the complex conjugate of the denominator.
4. Simplify.

## Dividing complex numbers

Divide: $\text{\hspace{0.17em}}\left(2+5i\right)\text{\hspace{0.17em}}$ by $\text{\hspace{0.17em}}\left(4-i\right).$

We begin by writing the problem as a fraction.

$\frac{\left(2+5i\right)}{\left(4-i\right)}$

Then we multiply the numerator and denominator by the complex conjugate of the denominator.

$\frac{\left(2+5i\right)}{\left(4-i\right)}\text{\hspace{0.17em}}\cdot \frac{\left(4+i\right)}{\left(4+i\right)}$

To multiply two complex numbers, we expand the product as we would with polynomials (using FOIL).

Note that this expresses the quotient in standard form.

bsc F. y algebra and trigonometry pepper 2
given that x= 3/5 find sin 3x
4
DB
remove any signs and collect terms of -2(8a-3b-c)
-16a+6b+2c
Will
Joeval
(x2-2x+8)-4(x2-3x+5)
sorry
Miranda
x²-2x+9-4x²+12x-20 -3x²+10x+11
Miranda
x²-2x+9-4x²+12x-20 -3x²+10x+11
Miranda
(X2-2X+8)-4(X2-3X+5)=0 ?
master
The anwser is imaginary number if you want to know The anwser of the expression you must arrange The expression and use quadratic formula To find the answer
master
The anwser is imaginary number if you want to know The anwser of the expression you must arrange The expression and use quadratic formula To find the answer
master
Y
master
master
Soo sorry (5±Root11* i)/3
master
Mukhtar
explain and give four example of hyperbolic function
What is the correct rational algebraic expression of the given "a fraction whose denominator is 10 more than the numerator y?
y/y+10
Mr
Find nth derivative of eax sin (bx + c).
Find area common to the parabola y2 = 4ax and x2 = 4ay.
Anurag
A rectangular garden is 25ft wide. if its area is 1125ft, what is the length of the garden
to find the length I divide the area by the wide wich means 1125ft/25ft=45
Miranda
thanks
Jhovie
What do you call a relation where each element in the domain is related to only one value in the range by some rules?
A banana.
Yaona
given 4cot thither +3=0and 0°<thither <180° use a sketch to determine the value of the following a)cos thither
what are you up to?
nothing up todat yet
Miranda
hi
jai
hello
jai
Miranda Drice
jai
aap konsi country se ho
jai
which language is that
Miranda
I am living in india
jai
good
Miranda
what is the formula for calculating algebraic
I think the formula for calculating algebraic is the statement of the equality of two expression stimulate by a set of addition, multiplication, soustraction, division, raising to a power and extraction of Root. U believe by having those in the equation you will be in measure to calculate it
Miranda
state and prove Cayley hamilton therom
hello
Propessor
hi
Miranda
the Cayley hamilton Theorem state if A is a square matrix and if f(x) is its characterics polynomial then f(x)=0 in another ways evey square matrix is a root of its chatacteristics polynomial.
Miranda
hi
jai
hi Miranda
jai
thanks
Propessor
welcome
jai
What is algebra
algebra is a branch of the mathematics to calculate expressions follow.
Miranda
Miranda Drice would you mind teaching me mathematics? I think you are really good at math. I'm not good at it. In fact I hate it. 😅😅😅
Jeffrey
lolll who told you I'm good at it
Miranda
something seems to wispher me to my ear that u are good at it. lol
Jeffrey
lolllll if you say so
Miranda
but seriously, Im really bad at math. And I hate it. But you see, I downloaded this app two months ago hoping to master it.
Jeffrey
which grade are you in though
Miranda
oh woww I understand
Miranda
Jeffrey
Jeffrey
Miranda
how come you finished in college and you don't like math though
Miranda
gotta practice, holmie
Steve
if you never use it you won't be able to appreciate it
Steve
I don't know why. But Im trying to like it.
Jeffrey
yes steve. you're right
Jeffrey
so you better
Miranda
what is the solution of the given equation?
which equation
Miranda
I dont know. lol
Jeffrey
Miranda
Jeffrey


text:
Home OALib Journal OALib PrePrints Submit Ranking News My Lib FAQ About Us Follow Us+
 Title Keywords Abstract Author All
Search Results: 1 - 10 of 100 matches for " "
 Page 1 /100 Display every page 5 10 20 Item
 Mathematics , 2015, Abstract: Kolmogorov $n$-widths and low-rank approximations are studied for families of elliptic diffusion PDEs parametrized by the diffusion coefficients. The decay of the $n$-widths can be controlled by that of the error achieved by best $n$-term approximations using polynomials in the parametric variable. However, we prove that in certain relevant instances where the diffusion coefficients are piecewise constant over a partition of the physical domain, the $n$-widths exhibit significantly faster decay. This, in turn, yields a theoretical justification of the fast convergence of reduced basis or POD methods when treating such parametric PDEs. Our results are confirmed by numerical experiments, which also reveal the influence of the partition geometry on the decay of the $n$-widths.
 Yan Dolinsky Quantitative Finance , 2010, Abstract: We derive error estimates for multinomial approximations of American options in a multidimensional jump--diffusion Merton's model. We assume that the payoffs are Markovian and satisfy Lipschitz type conditions. Error estimates for such type of approximations were not obtained before. Our main tool is the strong approximations theorems for i.i.d. random vectors which were obtained [14]. For the multidimensional Black--Scholes model our results can be extended also to a general path dependent payoffs which satisfy Lipschitz type conditions. For the case of multinomial approximations of American options for the Black--Scholes model our estimates are a significant improvement of those which were obtained in [8] (for game options in a more general setup)
 Yuri Kifer Mathematics , 2007, DOI: 10.1214/105051606000000808 Abstract: Correction for Error estimates for binomial approximations of game options [math.PR/0607123]
 Statistics , 2012, DOI: 10.1103/PhysRevLett.109.036403 Abstract: Theoretical studies of localization, anomalous diffusion and ergodicity breaking require solving the electronic structure of disordered systems. We use free probability to approximate the ensemble- averaged density of states without exact diagonalization. We present an error analysis that quantifies the accuracy using a generalized moment expansion, allowing us to distinguish between different approximations. We identify an approximation that is accurate to the eighth moment across all noise strengths, and contrast this with the perturbation theory and isotropic entanglement theory.
 David ？i？ka Mathematics , 2011, Abstract: Finite difference approximations to multi-asset American put option price are considered. The assets are modelled as a multi-dimensional diffusion process with variable drift and volatility. Approximation error of order one quarter with respect to the time discretisation parameter and one half with respect to the space discretisation parameter is proved by reformulating the corresponding optimal stopping problem as a solution of a degenerate Hamilton-Jacobi-Bellman equation. Furthermore, the error arising from restricting the discrete problem to a finite grid by reducing the original problem to a bounded domain is estimated.
 Mathematics , 2012, Abstract: In this correspondence our aim is to use some tight lower and upper bounds for the differential quaternary phase shift keying transmission bit error rate in order to deduce accurate approximations for the bit error rate by improving the known results in the literature. The computation of our new approximate expressions are significantly simpler than that of the exact expression.
 Victor Kourassov Physics , 2002, Abstract: Different approximations to describe nucleation kinetics have been analyzed. Some new approximations for solution of diffusion problem are proposed. Error of the approximation with constant radius of an embryo is clarified. The theory is illustrated by numerical calculations.
 Yuri Kifer Mathematics , 2006, DOI: 10.1214/105051606000000088 Abstract: We justify and give error estimates for binomial approximations of game (Israeli) options in the Black--Scholes market with Lipschitz continuous path dependent payoffs which are new also for usual American style options. We show also that rational (optimal) exercise times and hedging self-financing portfolios of binomial approximations yield for game options in the Black--Scholes market nearly'' rational exercise times and nearly'' hedging self-financing portfolios with small average shortfalls and initial capitals close to fair prices of the options. The estimates rely on strong invariance principle type approximations via the Skorokhod embedding.
 Olga Turanova Mathematics , 2013, Abstract: We introduce the notion of \delta-viscosity solutions for fully nonlinear uniformly parabolic PDE on bounded domains. We prove that \delta-viscosity solutions are uniformly close to the actual viscosity solution. As a consequence we obtain an error estimate for implicit monotone finite difference approximations of uniformly parabolic PDE.
 Physics , 2013, DOI: 10.1103/PhysRevLett.111.110601 Abstract: We evaluate the self-diffusion and transport diffusion of interacting particles in a discrete geometry consisting of a linear chain of cavities, with interactions within a cavity described by a free-energy function. Exact analytical expressions are obtained in the absence of correlations, showing that the self-diffusion can exceed the transport diffusion if the free-energy function is concave. The effect of correlations is elucidated by comparison with numerical results. Quantitative agreement is obtained with recent experimental data for diffusion in a nanoporous zeolitic imidazolate framework material, ZIF-8.
 Page 1 /100 Display every page 5 10 20 Item


text:
# SQL Optimization Techniques¶

Before you start fidgeting with individual SQL statements, it is important to note that hints are probably the last thing you should consider adding when attempting to optimize your code. There are several levels of optimization and it is recommended that you start with the server, then the database instance, and finally go down through the database objects to individual statements. After all, the effect of any changes made to individual statements, particularly hints, may be lost when the database is fine-tuned later on.

As a database developer/architect you may not want to tread the path that leads to the desk of the DBA. Fortunately, there is a bunch of things you can do to improve the runtime performance of your statements:

• Optimize access structures:
• Database design and normalization.
• Tables: heap or index-organized tables, and table or indexed clusters.
• Indexes.
• Constraints.
• Materialized views.
• Partitioning schemes.
• Statistics, including a comprehensive refresh strategy.
• Rewrite SQL statements:
• Exclude projections that are not required.
• Minimize the amount of work done more than once.
• Factor subqueries that are used multiple times in the same statement.
• Use EXISTS instead of IN because the former stops processing once it has found a match.
• Use CASE and/or DECODE to avoid having to scan the same rows over and over again, especially for aggregation functions that act on different subsets of the same data.
• Use analytic functions to do multiple or moving/rolling aggregations with a single pass through the data.
• Avoid scalar subqueries in the SELECT-list.
• Use joins instead of subqueries, as it gives the optimizer more room to play around in.
• Say what you mean and pick the right join: if you only need an inner join don’t write an outer join.
• Add logically superfluous predicates that may still aid in the search for an optimal execution plan, particularly for outer joins.
• Avoid implicit conversions of data types, especially in the WHERE clause.
• Write WHERE clause predicates with a close eye on the indexes available, including the leading edge of a composite index.
• Avoid, whenever possible, comparison operators such as <>, NOT IN, NOT EXISTS, and LIKE without a leading '%' for indexed columns in predicates.
• Do not apply functions on indexed columns in the WHERE clause when there is no corresponding function-based index.
• Don’t abuse HAVING to filter rows before aggregating.
• Avoid unnecessary sorts, including when UNION ALL rather than UNION is applicable.
• Avoid DISTINCT unless you have to use it.
• Use PL/SQL, especially packages with stored procedures (and bind variables) and shared cursors to provide a clean interface through which all data requests are handled.
• Add hints once you have determined that it is right and necessary to do so.

The advantage of PL/SQL packages to provide all data to users is that there is, when set up properly, exactly one place where a query is written, and that’s the only place where you have to go to to change anything, should you ever wish or need to modify the code. PL/SQL will be in our sights in the next part but suffice to say it is the key to maintainable code on Oracle. Obviously, ad-hoc queries cannot benefit from packages, but at least they profit from having solid access structures, which are of course important to PL/SQL too.

One important thing to keep in mind is that you should always strive to write efficient, legible code, but that premature optimization is not the way to go. Premature optimization involves tinkering with access structures and execution plans; it does not include simplifying, refactoring and rewriting queries in ways that enable Oracle to optimally use the database objects involved.

Rewriting queries with or without hints and studying the corresponding execution plans is tedious and best left for high-impact SQL only: queries that process many rows, have a high number of buffer gets, require many disk reads, consume a lot of memory or CPU time, perform many sorts, and/or are executed frequently. You can identify such queries from the dynamic performance views. Whatever you, the database developer, do, be consistent and document your findings, so that all developers on your team may benefit from your experiences.


text:
# When are two normally distributed random variables jointly bivariate normal? [duplicate]

For our upcoming exam we had to calculate the joint density of two normally distributed random variables a few times.

Say $X \sim N(0,1)$ and $Y \sim N(2,3)$.

We just assumed that $Z=(X,Y)^\top$ have a joint bivariate normal distribution $Z \sim N\left( \left(\begin{array}{c} 0\\ 2 \end{array}\right) , \left(\begin{array}{cc} 1 & a\\ a & 3 \end{array}\right) \right)$ and calculated the only missing parameter, the covariance $a$ of the two random variables.

Now, wikipedia says that this is not always true and brings a counter example. Here is the image of the example's resulting plot.

My question: Under which conditions are they jointly normally distributed?

-
– cardinal Jul 30 '12 at 18:17
The condition is that every linear combination of $X$ and $Y$ is normally distributed. The wikipedia page includes this characterization under the Definition subsection. – cardinal Jul 30 '12 at 18:20
Given $X\sim N(0,1)$ and $Y \sim N(2,3)$ and that the random variables are jointly normal, how did you calculate the covariance $a$? There must have been some other information provided to you that enabled you to calculate $a$ because given just that $X\sim N(0,1)$ and $Y \sim N(2,3)$ (whether jointly normal or not), $a$ can have any value in $[\sqrt{3}, -\sqrt{3}]$. – Dilip Sarwate Jul 30 '12 at 18:31
Also of interest: surprising characterizations of the Gaussian distribution – whuber Jul 30 '12 at 18:47
Dilip, I didn't calculate $a$, and there normally is more information. I just made up a few quick numbers :) – Alexx Hardt Jul 30 '12 at 18:49
show 3 more comments


text:
# The base of a triangle is smaller than its altitude. If its area is $$\dfrac{1}{2}x^2 + 2x + \dfrac{3}{2}$$, its base is,

This question was previously asked in
DSSSB TGT Maths Male Subject Concerned- 23 Sep 2018 Shift 1
View all DSSSB TGT Papers >
1. (x + 2)
2. 9x - 1)
3. (x + 3)
4. (x + 1)

Option 4 : (x + 1)

## Detailed Solution

Given:

The base of a triangle < altitude

and are of the triangle,

$$A = \dfrac{1}{2}x^2 + 2x + \dfrac{3}{2}$$

Formula used

$$A = \frac{1}{2}\times base\times height$$

Calculation:

Given that are of the triangle,

$$A = \dfrac{1}{2}x^2 + 2x + \dfrac{3}{2}$$

$$\Rightarrow A = \dfrac{1}{2}(x^2 + 4x + 3)$$

$$\Rightarrow A = \dfrac{1}{2}(x^2 + 3x + x + 3)$$

$$\Rightarrow A = \dfrac{1}{2}[x (x + 3) + 1 (x + 3)]$$

$$\Rightarrow A = \dfrac{1}{2} (x + 3) (x + 1)$$

On comparing it with an area of a triangle,

$$A = \frac{1}{2}\times base\times height$$

According to the question, the base of a triangle is smaller than its altitude.

∵ x + 3 > x + 1

Hence base of traingle will be equal to  x + 1.