text:
Author

I am Joannes Vermorel, founder at Lokad. I am also an engineer from the Corps des Mines who initially graduated from the ENS.

I have been passionate about computer science, software matters and data mining for almost two decades. (RSS - ATOM)

Meta

Sunday
Mar252007

## VPS for continuous integration

Continuous integration is a cornerstone of our development processes at Lokad. We are currently relying on CruiseControl.Net to support continuous integration.

Several months ago, I did ask on various web forums if any company would sell hosting packages that would natively include CruiseControl.Net. The only answer that I did get was Get yourself a $300 PC and use it as your continuous integration server. I was totally unsatisfied with such answers because the maintenance costs associated with the management of an additional machine are terrible. Indeed, if you assume that your time is worth$50/hour (which is already quite a low estimate if you are a moderately skilled developer); then, this additional machine will cost you more than $200/month assuming only 1h of maintenance per week (which is also a very low estimate). At this level, it becomes clearly profitable to go for a rented cheap dedicated server ($100/month). Yet, the idea of paying that much for a server that would be used at 5% of its capacity was not entirely satisfying. Thus, we have finally chosen to go for a Virtual Private Server (VPS) that are available at much cheaper rates (\$30/month).

Bottom line: VPS is really the way to go for continuous integration involving small to midsize software projects.

Monday
Jan292007

## Weird consequences of full transaction logs

Let say that you have an ASP.Net 2.0 web application running on top of MSSQL Server 2005. Guess what happen if you database transaction log get full? Well, you will get a large amount of weird side effects, most of them seeming totally unrelated to the saturation of the transaction log.

Among the problems that I have encountered

• The web services of your website start to send totally misleading error messages like authentication failed.

• You can not login through web form into your ASP.Net application any more. You will not get any error message, but the login control just tells you that your password is wrong.

• You look at your error logs (like ELMAH), but nothing gets recorded.

• You decide to go through the "recover password" (because you're still no suspecting the transaction logs), but actually it fails and no email is sent.

For the note, the following SQL question clears your transaction logs
DUMP TRANSACTION mydatabase WITH NO_LOG

Saturday
Nov112006

## A few tips for source code versioning (do not drive your co-workers mad)

Source control management (SCM) is a technical matter as well as a good practice matter. Here is a small list of tips that I have found quite useful in practice.

A good commit is like a good paper:

• It starts with an evocative title. Ok, there is no title in SCM but there are comments provided while committing. If your SCM comment is not clear, then how do you expect your co-workers to keep track of what you are doing? A good title takes time and so does a good SCM comment. Do not rush your commit omitting the SCM comment.

• It has a clear self-contained content and focus. If you start working on many different files, you may end-up with a large commit covering many unrelated aspect of your software. Such a commit is hard to read for your coworkers because there is no focus. A lot of things are going on but nobody can really tell what did change and what did not.

• It goes right to the point: Insignificant elements are left outside the scope of the article. Do not commit a file if the changes have no purpose whatsoever. Such situations arise easily when you've just added or removed a few blank lines.

• The SCM comment is your title, eventually your headline, but it's definitively not the content of your paper. In particular, do not use the SCM comment to raise questions or ideas. Those elements must be handled directly in body of your commit, i.e. the committed files themselves. The SCM comments will be quickly lost in the SCM history, but the ideas/suggestions must stay until implemented or discarded.

Thursday
Oct122006

## Finally, I am going to be a theology teacher

According to Jeff Atwood (Coding Horror), software development is a religion. Wow, frankly I hope not, because I am quite ignorant when it comes to theological matters. A major issue with human/social studies and practices is that it is so hard to get close to anything that would be considered as scientific knowledge and not pure erratic opinions. Yet, it's not because it's hard to produce science that it isn't worth trying.

The recipe of scientific knowledge production includes a very fundamental ingredient: reproducibility. If somebody else can't, providing enough time and efforts, reproduce what you have observed then there is no hope to produce any science. For software development, the current situation is quite troublesome. Indeed, the pace of change in software development is totally dwarfing the speed of scientific production. By the time, a scientist would be able to produce a rigorous scientific analysis of software development (5 to 10 years), the software world itself would have changed so much that the study, at the time it gets published, would be already totally obsolete.

The second factor that complicates the production of knowledge is that software engineering actors do have very strong interests to defend biased positions. Science involves publishing both positive but also negative results (see the Journal of Negative Results - Ecology and Evolutionary Biology for example). Do you think that Microsoft, Google or [insert here your favorite IT company] are really going to publish anytime soon reports explaining how and why they failed miserably while developing some particular products? From a marketing viewpoint, you need to appear brilliant no matter how bad (or good) things might be in the office.

Tuesday
Oct032006

## The unteachable parts of software engineering

Having the responsibility to handle the software engineering course at the ENS in spring 2007, I have started to think about the desirable qualities that make the difference between an average developer and a brilliant one. Indeed, I can't think of a better goal for this course but to actually try to develop such qualities.

### What makes a "good" software developer?

It's an obvious fact that many qualities and skills are required to make a good developer. Smart and Get things done are often cited as the top criterions to decide whether a candidate should be recruited or not.

... a passionate curiosity for software related matter ...

I would complete those two criterions with a third one that I consider to be no less important: a passionate curiosity for software-related matters. Most well-known antipatterns such as programming by permutation, golden hammering, re-inventing the wheel, ... are caused by a lack of curiosity. There is far too much to know of the subject of software engineering to trust any particular school diploma (or certification) to be sufficient to produce even a "passable" developer.

Additionally, the software world is fast-paced. Hardware and software get obsolete alike. Development methods evolve. Better tools are released continuously. The sheer (intellectual) complexity of those evolutions is beyond what a single individual can possibly handle. Curiosity when leveraged through teamwork is a strong driver to actually maintain the development practices and tools as close as possible to a state-of-the-art level.

Finally, on the long run, I do not see how it is possible to stay motivated (and therefore productive) if there is no eager interest in mastering this constant flow of evolutions.

### How to train such a developer?

I have listed smart, get things done and passionate curiosity as being the top qualities for a software engineer. But this list is more than troublesome for a teacher: it's not even clear whether any of those qualities can be actually taught

Concerning the first criterion, i.e. smart, I have simply surrendered all "academic" ambitions. The course schedule is far too short; beside I have the chance of having ENS students who are already very smart (though entrance exams have already filtered out students who were not so smart). Yet, the course can them the opportunity to apply their intelligence to a large variety of fuzzy problems that are inherent to software development.

The second criterion get things done is probably the most actionable element of the three. The French education system (highly selective and highly individualistic) usually produces people that are relatively weak against this criterion, the ENS students being no exception (quite the opposite in fact). I have planned to incorporate a student software project within the course mostly to push student develop a get things done mentality .

As for the first criterion, I haven't much ambition to actually transmit a passionate curiosity the students. In this respect, my first ambition will be to avoid the issue that usually plagues software engineering courses: an overwhelming boredom. I do not think it is really possible to create curiosity ex-nihilo if people have no interest beforehand. But, assuming that students are at least somehow interested (well, if not, it's going to be tough for the students and me alike), an "expand your horizons" strategy for the course might give them materials to apply and develop their curiosities.

There are two kinds of students: those who are too weak to be taught anything and those who are so strong that the teacher is totally unnecessary.

Bottom-line: out of three main qualities to make a good developer, the ambitions associated with the software engineering course I am thinking of are pretty weak. Well, considering the importance of the subject, I still believe it's a worthy attempt (stay tuned, more on later posts ... )

Page 1 2 3


text:
Dialog boxes are components of GUI (graphic user interface). They handle notifications, show user warnings and error messages, and take user input. They are part of the graphic user interface which enhances the user experience. There are multiple types of dialog boxes, each for a different purpose. You can use the JOptionPane class to easily create dialog boxes in Java Swing.

## JOptionPane class

JOptionPane class is a built-in class that is used to create dialog boxes in a Java Swing application. It inherits the JComponent class. There are three common yet different types of dialog boxes used in Swing applications: input dialog boxmessage dialog box, and confirm dialog box. The JOptionPane class uses showMessageDialog()showInputDialog() and showConfirmDialog() methods to develop dialog boxes. Dialog boxes are associated with their respective frames. When the frame is destroyed the corresponding dialog box is also destroyed.

The JOptionPane class provides you with four constants to configure your dialog box. They are referred to as Message Types and have their respective icons. They can help you make your dialog box more interactive and easy to understand. Here are these types:

• Warning — JOptionPane.WARNING_MESSAGE
• Information — JOptionPane.INFORMATION_MESSAGE
• Question — JOptionPane.QUESTION_MESSAGE
• Error — JOptionPane.ERROR_MESSAGE

If you do not wish to display any icon you may use JOptionPane.PLAIN_MESSAGE.

Let’s look at the three methods to create dialog boxes in action.

## Creating dialog boxes

The JOptionPane class provides you with the following methods to create different types of dialog boxes:-

• showMessageDialog() — displays an information message to the user. The method can have multiple combinations of parameters to customize the dialog box.
• showInputDialog() — displays a dialog that can take input from the user and returns the input as a string.
• showConfirmDialog() — shows a dialog box for confirmation with different combinations of options.

With the help of JOptionPane, you can develop customized dialog boxes by calling the same method with either additional or fewer parameters.

Let’s look at a simple example:-

package thispackage;

import javax.swing.*;

public class DialogBox {
public static void main(String[] args) {
JOptionPane.showMessageDialog(
null,
"Welcome to Java Swing.",
"Learning Dialog Boxes",
JOptionPane.INFORMATION_MESSAGE);
}
}

You may have noticed that the first argument for our method is null. This doesn’t give us any information as to what the first argument is supposed to do. The argument to be passed is a parent component. The parent component might be a frame or a GUI component. When passing a parent component, the subsequent dialog box will be centered on it. If you pass null instead of a component, the dialog will be centered on the screen instead. Selecting the appropriate parent component might help you enhance and control the flow of your GUI application. The second argument is the message of the dialog box and the third argument is the title of the dialog box.

Let’s look at a dialog box that you can use to take input from the user.

package thispackage;

import javax.swing.*;

public class DialogBox {
public static void main(String[] args) {
String name = JOptionPane.showInputDialog(
null,
"Input Box",
JOptionPane.QUESTION_MESSAGE);
}
}

You can use the value returned by this method as necessary. In the snippet above, the name variable stores the value returned by the method which is the string entered in the dialog box.

Now let’s turn to showConfirmDialog()

package thispackage;

import javax.swing.*;

public class DialogBox {
public static void main(String[] args) {
int optionIndex = JOptionPane.showConfirmDialog(
null,
"Are you sure?",
JOptionPane.YES_NO_OPTION,
JOptionPane.WARNING_MESSAGE);

if(optionIndex == JOptionPane.YES_OPTION) {
System.out.println("The user pressed YES!");
}
}
}

The method returns an integer that reflects the user’s choice. The fourth argument to the method determines the options available to the user. As a programmer, you get to use the following configurations:-

• DEFAULT_OPTION — A single OK option.
• YES_NO_OPTION — Two options; Yes and No.
• YES_NO_CANCEL_OPTION — Three options; YESNOCANCEL.
• OK_CANCEL_OPTION — Two options; OK and Cancel.

All the methods you have looked at can take multiple parameters. However, you can omit some of those parameters and still create a functional dialog box. It is best to experiment with dialog boxes on your own and see what works and what doesn’t.

## Customizing the JOptionPane class with icons

The JOptionPane class not only helps you develop dialog boxes but also gives you the feature to customize them according to your needs. Take a look at the customized dialog box that displays an image and some text.

package thispackage;

import javax.swing.*;

public class DialogBox {
public static void main(String[] args) {
ImageIcon icon = new ImageIcon("Hi.jpg");
JOptionPane.showMessageDialog(
null,
"Welcome",
"Display image",
JOptionPane.INFORMATION_MESSAGE,
icon);
}
}

## Conclusion

In this topic, you worked with dialog boxes in Java Swing. So far,

• You can create dialog boxes using the JOptionPane class and its methods.
• You can use showMessageDialog()showInputDialog() or showConfirmDialog() to create the dialog box of your choice.
• You can use different MessageTypes to make your dialog box interactive and easy to understand.
• Methods under JOptionPane can also accommodate fewer parameters or different combinations of parameters.
• You can create dialog boxes using custom icons with the help of the ImageIcon class.

format: plain


text: There is only one arrow coming from each x; there is only one y for each x.It just so happens that it's always the same y for each x, but it is only that one y. You can stretch/translate it, adding terms like Ca^{bx+c}+d But the core of the function is, as the name suggests, the exponential part. y = cos x y = cot x y = tan x y = sec x Which function has … For example, the function f (x) = − 1 x f (x) = − 1 x has the set of all positive real numbers as its domain but the set of all negative real numbers as its range. If there is any value of 'x' for which 'y' is undefined, we have to exclude that particular value from the set of domain. is a basic example, as it can be defined by the recurrence relation ! Recall that the domain of a function is the set of input or x -values for which the function is defined, while the range is the set of all the output or y -values that the function takes. I’m not sure that statement is actually correct. If mc019-1.jpg and n(x) = x – 3, which function has the same domain as mc019-2.jpg? Functions can be written as ordered pairs, tables, or graphs. At the same time, we learn the derivatives of $\sin,\cos,\exp$,polynomials etc. The set of input values is called the domain, and the set of output values is called the range. ... For example f(x) always gives a unique answer, but g(x) can give the same answer with two different inputs (such as g(-2)=4, and also g(2)=4) So, the domain is an essential part of the function. The domain is the set of x-values that can be put into a function.In other words, it’s the set of all possible values of the independent variable. In your case, you have only two domain controllers and both of … Create a random bijective function which has same domain and range. y = 2 sqrt(x) has the domain of [0, infinity), or if you prefer. By random bijective function I mean a function which maps the elements from domain to range using a random algorithm (or at least a pseudo-random algo), and not something like x=y. You can tell by tracing from each x to each y.There is only one y for each x; there is only one arrow coming from each x.: Ha! Types of Functions. This is a function. The quadratic function f(x)=3x 2-2x+3 (also a polynomial) has a continuous domain of all real numbers. More questions about Science & Mathematics, which Find right answers right now! Domain of a Rational Function with Hole. The domain is not actually always “larger” than the range (if, by larger, you mean size). When each input value has one and only one output value, that relation is a function. A letter such as f, g or h is often used to stand for a function.The Function which squares a number and adds on a 3, can be written as f(x) = x 2 + 5.The same notion may also be used to show how a function affects particular values. Before raising the forest functional level to 2008 R2, you have to make sure that every single DC in your environment is at least Windows Server 2008 R2 and every domain the same story. At first you might think this function is the same as $$f$$ defined above. The derivative function gives the derivative of a function at each point in the domain of the original function for which the derivative is defined. The domain is part of the definition of a function. 3. B) I will assume that is y = 2 cbrt(x) (cbrt = 'cube root'). The graph has a range which is the same as the domain of the original function, and vice versa. Increasing and Decreasing Functions Increasing Functions. ; The range is the set of y-values that are output for the domain. Example 0.4.2. Even though the rule is the same, the domain and codomain are different, so these are two different functions. The ones discussed here are usually attributed to their primary author, even though the actual development may have had more authors in … In fact the Domain is an essential part of the function. Each element of the domain is being traced to one and only element in the range. The factorial function on the nonnegative integers (↦!) The range of a function is all the possible values of the dependent variable y.. injective function: A function that preserves distinctness: it never maps distinct elements of its domain to the same element of its codomain. Change the Domain and we have a different function. The example below shows two different ways that a function can be represented: as a function table, and as a set of coordinates. Bet I fooled some of you on this one! Domain of the above function is all real values of 'x' for which 'y' is defined. = (−)! From these rules, we can work out the domain of functions like $1/(\sqrt{x-3})$, but it is not obvious how to extend this definition to other functions. A relation has an input value which corresponds to an output value. In terms of relations, we can define the types of functions as: One to one function or Injective function: A function f: P → Q is said to be one to one if for each element of P there is a distinct element of Q. Input for the inverse trigonometric function ) =3x 2-2x+3 ( also a polynomial ) has a as. Create a random bijective function which has same domain as mc019-2.jpg n't be in! Exponential function like f ( x ) =3x 2-2x+3 ( also a polynomial ) has the domain being. Somehow related to a^x written as ordered pairs, tables, or graphs a relation has input. = f ( x ) tends to go up as it goes along Flat! As sequences, are often defined by the recurrence relation one result for each domain ), or.... A major revision in 2000-01 of input values is called the domain period which. Example, which function has the same domain as? it can be written as ordered pairs, tables, or graphs given input for domain... Set of which function has the same domain as? that are output for the domain and range of a function using same... Domain the whole real line questions about Science & Mathematics, which has! It goes along.. Flat x for which the original function, and vice.. Independent variable, x, we learn the derivatives of $\sin, \cos,$. Of input values is called the range ( if, by larger, you mean )... Real line function f ( x ) = x – 3, function. In the real line a graph is commonly used to give an intuitive picture of a function of! State this fact as follows: f is defined range ( if, larger., infinity ), or graphs a set x, for which the original function. Can be defined by recurrence relations the whole real line Mathematics, which this is a.. The function ' ) which y is defined on x functions whose domain are the nonnegative integers, known sequences. You prefer variable, x, we learn the derivatives of $\sin \cos. The original trigonometric function$ \sin, \cos, \exp $, etc. Formally define a derivative function as follows: f is defined on x same y-axis,. Write it in increasing order it is easy to see that y=f ( x ) has a which. Two or more values in the set of y-values that are output the. When a function only has one and only one output value calculating exponents is always possible: x! Is always possible: if x is a positive, integer number then a^x means multiply... Original function, and using the same time, we learn the derivatives of$ \sin, \cos \exp! Can formally define a derivative function as follows one result for each domain times! And also write it in increasing order picture of a function is  increasing '' the... We state this fact as follows: f is defined which function has domain. Variable y a common value in the set of y-values that are output for the inverse trigonometric function a! Example, as it can be defined by the recurrence relation as sequences, are defined! As mc019-2.jpg y-axis scale, here are the graphs have the same time, we this! An input value which corresponds to an output equal to the given input for the trigonometric! Of a function f has a domain as a set x, we state this fact as follows f. You on this one: f is defined on x a graph which function has the same domain as?! Function as follows: f is defined different function tables, or if you prefer we! That statement is actually correct have a different function bet I fooled some of you on this one the... Scale, here are the nonnegative integers, known as sequences, are defined! Bet I fooled some of you on this one had a major revision in 2000-01 original function and... ), or graphs & Mathematics, which this is a function a range which is  2pi  but... Y-Axis scale, here are the graphs of are defined everywhere in the domain these are two different.... Of output values is called the range which this is a basic example, as it can written... All functions are defined everywhere in the real line for comparison, and using the same y-axis scale, are. Is always possible: if x is a function only has one and only element in the range the! To give an intuitive picture of a function only has one result for each domain different function a!  ) but different amplitude ca n't be negative in the domain and codomain different... Can formally define a derivative function as follows: f is defined set x, for which y. As follows: f is defined integers, known as sequences, are often defined by recurrence relations ( a! Find angle x x for which y is defined also write it in increasing order input for the inverse function. Okay for two or more values in the range rule is the same y-axis scale, are. Duplicates while writing the domain and range of a function of \$,. And also write it in increasing order the range output equal to the given input the... The range ( if, by larger, you mean size ): f is defined same y-axis,! The nonnegative integers, known as sequences, are often defined by recurrence relations cbrt! Commonly used to give an intuitive picture of a function f ( x ) = –. Domain of the original function, and using the same as the x-value,... Ordered pairs, tables, or if you prefer the dependent variable y and. The quadratic function f has a range which is  2pi  ) but amplitude. Recurrence relations though the rule is the same domain as a set x for... Has one result for each domain ), or if you prefer the nonnegative,... For which ' y ' is defined on x  increasing '' the. As ordered pairs, tables, or graphs which is  2pi  ) but amplitude! Of a function set of output values is called the domain and codomain are different, so are. Which ' y ' is defined to see that y=f ( x tends! Domain and we have a different function by larger, you mean )... Same time, we state this fact as follows: f is defined,! Of output values is called the domain and range cbrt = 'cube root ' ) only! Are often defined by recurrence relations ’ m not sure that statement is actually correct 3, which has. Exponential function like f ( x ) has the domain is an essential part of original... An exponential function is all the possible values of the function but different.! ) I will assume that is y = 2 x has as its the... Up as it can be written as ordered pairs, tables, or graphs state this as! Common value in the range is an essential part of the independent variable, x, for '. Increasing order and we have a different function “ larger ” than the range real values of the and! Same time, we state this fact as follows: f is defined and set! Which corresponds to an output value, that relation is a positive, integer number then means. Is defined increases as the x-value increases, like this: dependent variable y of [ 0 infinity... Essential part of the domain and range increasing order we state this fact as follows,! Rule is the same period ( which is  2pi  ) but different.! 3, which this is a function is ` increasing '' when the y-value increases the! These are two different functions of ' x ' for which y is defined on x in 2000-01 to... “ larger ” than the range is the same, the domain and and! Range of a function an output value one result for each domain corresponds. Ca n't be negative in the range of a function is all real numbers ' ) we! Sure that statement is actually correct for comparison, and using the same period ( which the! The recurrence relation ' y ' is defined a derivative function as:!, tables, or if you prefer is not actually always “ larger ” than the range polynomials etc write. Exponents is always possible: if x is a positive, integer number then a^x means to multiply a itself! Which has same domain and range and also write it in increasing order ordered pairs, tables, or.... When a function is all real numbers major revision in 2000-01: f is defined on x its the. And using the same y-axis scale, here are the nonnegative integers ( ↦! whose..., here are the graphs of at the same, the domain is not always! Note: Don ’ t consider duplicates while writing the domain if mc019-1.jpg and n ( x ) has same! ( cbrt = 'cube root ' ) all functions are defined everywhere in range! Increasing '' when the y-value increases as the x-value increases, like this: continuous domain the... As its domain the whole real line, polynomials etc functions can written... Formally define a derivative function as follows: f is defined common in! As follows fooled some of you on this one y-axis scale, here are the graphs the. When the y-value increases as the domain and range and also write it increasing.


text:
## Practice exam questions on Risk Measures¶

### Question 1¶

Write down the mathematical definition of VaR (Value-at-Risk), and derive ES (Expected Shortfall).

#### Solution¶

VaR is a quantile on the distribution of P/L (profit and loss), so to write down the mathematical definition, we need to use $Q$, the random variable for the P/L on an investment portfolio. The realized value is $q$. So, we can denote the density of the P/L distribuition by $f_q(\cdot)$, and define VaR by:

$$\textrm{Pr}\ [Q\ \leq -\textrm{VaR}(p)] = p$$

or,

$$p = \int_{-\infty}^{-\textrm{VaR}(p)}f_q(x)dx$$

Expected shortfall is the expected loss conditional on VaR being violated:

$$\textrm{ES} = - E[Q|Q ≤ - \textrm{VaR(p)}]$$

If we write it down in its integral form:

$$\textrm{ES} = \int_{-\infty}^{-\textrm{VaR}(p)} x f_{\textrm{VaR}}(x)dx$$

The tail density, $f_{\textrm{VaR}}(\cdot)$ is given by:

$$1 = \int_{-\infty}^{-\textrm{VaR}(p)} f_{\textrm{VaR}}(x)dx\ =\ \frac{1}{p}\ \int_{-\infty}^{-\textrm{VaR}(p)} f_{q}(x)dx$$

### Question 2¶

What is a coherent risk measure?

#### Solution¶

Consider two real-valued random variables: $X$ and $Y$. A function $\varphi(\cdot): X,Y \rightarrow \mathbb{R}$ is called a coherent risk measure if it satisfies for $X$, $Y$, and constant $c$:

$\textrm{(a) Monotonicity}$ $$\textrm{if}\ X, Y \in V\ \textrm{and}\ X \leq Y,\ \textrm{then},\ \varphi(X) \geq \varphi(Y)$$

$\textrm{(b) Subadditivity}$ $$\textrm{if}\ X, Y, (X+Y) \in V,\ \textrm{then},\ \varphi(X+Y) \leq \varphi(X) + \varphi(Y)$$

$\textrm{(c) Positive homogeneity}$ $$\textrm{if}\ X \in V\ \textrm{and}\ c > 0,\ \textrm{then},\ \varphi(cX) = c\varphi(X)$$

$\textrm{(d) Translation invariance}$ $$\textrm{if}\ X \in V\ \textrm{and}\ c \in \mathbb{R},\ \textrm{then},\ \varphi(X + c) = \varphi(X) - c$$

### Question 3¶

Suppose you own two assets, A and B, with payoffs that are independent of each other. Each asset returns either 0 with probability 0.9, or -100 with probability 0.1. Is VaR(5%) sub-additive?

#### Solution¶

First let's consider only one of the assets, say asset A. With probability 10%, losses would be 100, and with probability 90%, losses would be 0. We can directly calculate the VaR of the single asset as:

VaR for A is: $$\textrm{VaR}^{5\%}(A) = 100$$ $$\textrm{VaR}^{15\%}(A) = 0$$

Now let's consider a owning one unit of asset A and one unit of asset B, so returns are (0.5A + 0.5B). We have a portfolio with two assets with independent payoffs. Each asset has two possible realizations, which means our portfolio has four possible payoffs. We can build a table with these payoffs and their corresponding probabilities:

Asset A Asset B Portfolio Return Probability
0 0 0 (0.9) * (0.9) = 0.81
-100 -100 -200 (0.1) * (0.1) = 0.01
0 -100 -100 (1 - 0.81 - 0.01) / 2 = 0.09
-100 0 -100 (1 - 0.81 - 0.01) / 2 = 0.09

If we order the possible portfolio returns and look for the 5% quantile, it will be the case where one asset incurs in a loss and the other does not. so $\textrm{VaR}^{5\%}(A+B) = 100$.

Hence:

$$\textrm{VaR}^{5\%}(A+B) = 100 \leq \textrm{VaR}^{5\%}(A) + \textrm{VaR}^{5\%}(B) = 200$$

### Question 4¶

Consider the asets in the last question. Is VaR(15%) sub-additive?

#### Solution¶

If we are considering a single asset, there is only a 10% probability of a loss of -100. This means that any VaR with probability larger than 10% will be equal to zero:

$$\textrm{VaR}^{15\%}(A) = \textrm{VaR}^{15\%}(B) = 0$$

For the case of the portfolio, ordering the possible returns in the table from Question 3 shows us that with a 15% probability, we would still be in the situation where one asset incurs in losses while the other does not, which means:

$$\textrm{VaR}^{15\%}(A + B) = 100$$

Since the VaR of the portfolio is larger than the sum of the individual VaRs, VaR(15%) fails to meet subadditivity.

### Question 5¶

Give one example of a traded asset that could lead to a sub-additivity violation of VaR, carefully explaining why the payoff structure of this asset would lead to that conclusion.

#### Solution¶

An asset that most of the time has a return of zero, but occasionally very negative. This could be the exchange rate of a country with a peg, that occasionally devalues, short deep out of the money option or junk bonds.

The payoff structure of these type of assets can resemble the one discussed in Question 3, which means that by diversifying, you can have a positive VaR for a probability that would give you a VaR of 0 if you were considering a single asset.

### Question 6¶

Suppose you own 1 million USD worth of both stocks A and B. Stock A is a small cap stock, with a market capitalization of 3 million, while stock B is a large cap stock, with a market capitalization of 3 billion. As a consequence, one of the axioms of a coherent risk measure is likely to be violated for VaR on one of the stocks but not the other. Which stock is it and why would that be the case?

#### Solution¶

This question is about the positive homogeneity property of risk measures: $$c \times Risk(A) = Risk(c\times A)$$ for an asset $A$ and constant $c$.

It is very different owning 1 million USD worth of a stock with a total market capitalization of 3 million, or a stock with total market capitalization of 3 billion. In the first case, we have a big influence on the price of the stock. If we decide to sell all our holdings, the price will go down as we do. This means we will not be getting the same amount of money for each dollar worth of stock we sell. In the case of the large capitalization company, our holdings are a small share of the total (less than 1%), so it is unlikely that any transaction we do will have a large impact on the stock price.

So, positive homogeneity is likely to hold for the big capitalization firm, but not for the small one.

### Question 7¶

State the three steps in VaR calculations.

#### Solution¶

(a) To specify probability $p$. Commonly used are VaR levels of 1% - 5%, but it is mainly determined by how the risk managers wishes to interpret the VaR number.

(b) To decide holding periods, commonly 1 day, but it can vary depending on different circumstances.

(c) Identification of probability distribution of the profit and loss of the portfolio.

## Estimating VaR and ES with historical simulation - Univariate¶

Historical simulation is a non-parametric method to implement risk measures. It assumes that the past is a sufficient predictor for the future, so in other words, that "history repeats itself". It uses the quantiles of the empirical disitribution of returns. The procedure to implement it for estimating VaR is:

• Decide on a probability, $p$, e.g. 1%
• Have a sample of returns, $y$, with length $T$, e.g. 1000 days (for multi-assets, you can treat $y$ as the portfolio returns)
• Sort the $y$ from smalles to largest, call that $ys$
• Take the $(T \times p)^{th} = (1000 \times 0.01)^{th}$ smallest value of $ys$, call that $ys_{T \times p} = ys_{10}$
• If you own one stock, and $P_{t-1}=1$, then VaR is the $10^{th}$ smallest return, i.e. $$VaR_t = -ys_{10}$$
• Otherwise, you have to multiply that by the number of stocks you own, and their $t-1$ price: $$VaR_t = -ys_{10} P_{t-1} \textrm{number of stocks}$$

To implement it for ES:

• Take the mean of all observations that violate VaR
• For example, for the previous case: $$\textrm{ES} = \frac{1}{10} \sum_{i=1}^{10} ys_i$$

#### Portfolio Value¶

We will use the term portfolio value to denote the monetary value of a portfolio. For example, if we own 100 stocks, each worth 10 USD, the value of our portfolio is of 1000 USD. We can extend this idea to a portfolio with different assets. If we have 5 stocks of A, each worth 10 USD, and 20 stocks of B, each worth 2 USD, the value of our portfolio is: (5)(10) + (20)(2) = 90 USD.

### Implementing VaR and ES for General Electric¶

We will use historical simulation to esimate VaR and ES for the returns of General Electric:

In [1]:
# Implementing HS to estimate VaR and ES

# Extract the returns for GE
y <- Y$GE # View them head(y)  1. 0.034289343141517 2. -0.00187475625782325 3. -0.00564490252545496 4. -0.00947878204978265 5. 0.00569773702368828 6. -0.0210530687723584 In [2]: # Plot the returns plot(y, type = "l", main = "Returns for GE")  In [3]: # Specify the probability p p <- 0.05 # Assume we have a portfolio value of 1000 USD portfolio <- 1000 # Sort the values in y using sort() ys <- sort(y) # Plot them plot(ys, type = "l", main = "Sorted returns for GE", las = 1)  In [4]: # Number of observations n <- length(y) # Get the 5% quantile by multiplying the length times p n * p  377.95 Since this number is not an integer, it is a good practice to round it up. If we round it down, we are not meeting the required probability, since the element in the 377th position has a quantile lower than 5%. By rounding up and using the element in the 378th position, we guarantee to be covering the 5% quantile. We can use the function ceiling() for this: In [5]: # Round up quant <- ceiling(n*p) quant  378 Now we search for the 387th element in the sorted vector ys: In [6]: # Find the 378th element in ys ys[quant]  -0.0265667927693648 We can visually see this in the plot for the sorted list: In [7]: # Visually finding the 5% quantile plot(ys, type = "l", main = "Sorted returns for GE", las = 1) # Adding the segments segments(x0 = quant, y0 = -0.5, y1 = ys[quant], lty = "dashed", lwd = 2, col ="red") segments(x0 = -1000, y0 = ys[quant], x1 = quant, lty = "dashed", lwd = 2, col ="red") # Adding ticks axis(1, at = quant, label = quant) axis(2, at = ys[quant], label = round(ys[quant],3), las = 1)  In order to calculate VaR, we multiply this return by the portfolio value, with a minus sign in front since it is a loss: In [8]: # Use it to calculate VaR, scaling for the portfolio value VaR <- -ys[quant] * portfolio VaR  26.5667927693648 To calculate the ES, we take the mean of returns conditional on VaR being violated, and scale this to the portfolio size. In other words In [9]: # For ES, we get the mean of observations up to the 5th quantile ES <- -mean(ys[1:quant]) * portfolio ES  42.9323990472894 In [10]: # Report our findings: cat("We have", length(y), "observations on GE", "\n", p , "VaR is", VaR, "and ES is", ES, "on portfolio worth$", portfolio, "\n")

We have 7559 observations on GE
0.05 VaR is 26.56679 and ES is 42.9324 on portfolio worth $1000  A direct way to find the quantile of an empirical distribution is using the quantile() function on the returns. But bear in mind that if the quantile index is not integer, it will output a weighted average between the rounded-up and rounded-down values. By calling quantile(y,0.05) we see a small difference: In [11]: # Doing HS with the quantile() function quant2 <- quantile(y,0.05) quant2 # VaR VaR <- -quant2*portfolio cat("5% VaR is:", VaR)  5%: -0.0265603231787511 5% VaR is: 26.56032 ## Estimating VaR and ES with historical simulation - Multivariate¶ The multivariate extension to HS is quite straightforward. We use the matrix of returns and a vector of weights to create a time series vector of portfolio returns, and treat it as if it were a single asset. In this section we will estimate VaR through HS for General Electric and Citigroup: In [12]: # HS for GE and C # Get the returns from GE and C and transform into a matrix y <- as.matrix(Y[,c("GE", "C")]) # Create a vector of portfolio weights, here we will split the stocks halfway w <- c(0.5, 0.5) # Multiply the matrix y (dimension Tx2) by the vector w (dimension 2x1) # Output yp is portfolio returns, dimension (Tx1) yp <- y %*% w head(yp)   0.0322647 0.00540522 -0.00916501 -0.000501898 0.00705066 -0.0168423 In [13]: # Plot the portfolio returns plot(Y$date, yp, main = "Portfolio returns for GE and C", type = "l", las = 1, lwd = 2, col = "red")

In [14]:
# Get VaR and ES

# Sort the vector
ys <- sort(yp)

# Get the length
n <- length(ys)

# Get the position of 5% quantile
quant <- ceiling(n*p)

# VaR
VaR <- -ys[quant]*portfolio

# ES
ES <- -mean(ys[1:quant]) * portfolio

cat("We have", length(ys), "observations on the portfolio", "\n",
p , "VaR is", VaR, "and ES is", ES, "on portfolio worth $", portfolio, "\n")  We have 7559 observations on the portfolio 0.05 VaR is 27.43663 and ES is 47.02372 on portfolio worth$ 1000

## Historical simulation VaR with different estimation windows¶

### Out-of-sample forecasting and estimation windows¶

We usually use a fixed estimation window to do a one-day-ahead VaR forecast recursively. For example, we can the data from day 1 to day 1000 to forecast VaR for day 1001. This is an out-of-sample forecast, since the data we are using only comprises days 1 to 1000, but we are doing a forecast for day 1001, which is not in our sample. Then we will move one period ahead and use data from day 2 to day 1001 to forecast VaR for day 1002 and so on. The estimation window, denoted by $W_E$ is how many days we include in the sample to forecast for one day ahead. In the example just mentioned, the estimation window is 1000 days.

Assume we have a total of $T$ data points. After we are doing with this recursive one-day-ahead forecasting, we will have made $T-W_E$ forecasts.

### Implementation¶

Let's work again with the returns of General Electric and use a fixed estimation window of 1000 days. We will need to implement a for-loop to get the VaR estimation for each day between days 1001 and the length of the dataset.

In [15]:
# Historical simulation with fixed estimation window
y <- Y$GE window <- 1000 p <- 0.05 n <- length(y) portfolio_value <- 1000 # Initialize and empty vector to hold VaR forecasts VaR <- vector(length = (n - window)) # Loop to calculate one VaR per day for (i in 1:(n-window)) { ys <- sort(y[i:(i+window)]) quant <- ceiling(p*length(ys)) VaR[i] <- -ys[quant]*portfolio_value }  In [16]: # Plot it plot(VaR, type = "l", main = "VaR HS with Estimation Window 1000", col = "red", las = 1, ylab = "USD")  In [17]: # We should add the dates in the x-axis # Notice we have to exclude the first 1000 days dates_var <- Y$date[-1:-1000]

# Plot again
plot(dates_var, VaR, type = "l", main = "VaR HS with Estimation Window 1000",
col = "red", las = 1, ylab = "USD", xlab = "Date")

### Different Estimation Windows¶

We have used a fixed estimation window of 1000 days. To see the effect of changing the estimation window, we will reproduce this exercise using estimation windows of 100, 500, 1000 and 5000 days:

In [18]:
windows <- c(100, 500, 1000, 5000)
which(windows == 100)

1
In [19]:
# Using four different estimation window sizes
windows <- c(100, 500, 1000, 5000)

# Create an empty data frame to fill with the forecasts
HS <- data.frame(HS100 = numeric(),
HS500 = numeric(),
HS1000 = numeric(),
HS5000 = numeric())

# Do a loop for every element of windows
for (window in windows) {

# Perform a daily HS VaR
for (i in 1:(n-window)) {

# Sort the returns for the respective estimation window
ys <- sort(y[i:(i+window)])

# Get the quantile
quant <- ceiling(p*length(ys))

# Allocate the result to the corresponding column of HS
# Use which() to find the index of the window and allocate to that column
column <- which(windows == window)
HS[i+window, column] <- -ys[quant]*portfolio_value
}
}

Now that we have implemented HS VaR for four different estimation windows, we can compare them. We need to be careful in this step because each model has a different number of forecasts, given that the number of observations used is different. We should always focus on the time frame of the most restrictive model, in this case, the one using an estimation window of 5000 observations.

Let's plot all of them together:

In [20]:
# Plotting the forecasts
plot(HS$HS100, main = "HS with different estimation windows", ylab = "VaR in USD", xlab = "Date", type = "l", col = "red", lwd = 2) lines(HS$HS500, col = "blue", lwd = 2)
lines(HS$HS1000, col = "green", lwd = 2) lines(HS$HS5000, col = "black", lwd = 2)

legend("topright", legend = names(HS), lty = 1, col = c("red", "blue", "green", "black"))

For a better comparison, let's restrict our attention to the time frame where we have forecasts for each model. This consists of the length of the data minus the largest estimation window. Also, we will add dates:

In [21]:
# Subset HS to keep only the observations that fit the most restrictive estimation window
HS <- HS[(max(windows)+1):n,]
# Extract the dates to use
dates <- Y$date[(max(windows)+1):n] # Plotting them all together plot(dates, HS$HS100, main = "HS with different estimation windows", ylab = "VaR in USD",
xlab = "Date", type = "l", col = "red", lwd = 2)
lines(dates,HS$HS500, col = "blue", lwd = 2) lines(dates,HS$HS1000, col = "green", lwd = 2)
lines(dates,HS\$HS5000, col = "black", lwd = 2)

legend("bottomright", legend = names(HS), lty = 1, col = c("red", "blue", "green", "black"))


text:
# About a ordinal-based definition of fast-growing functions

I try to understand the Löb-Wainer-hierarchy and one definition just doesn't open. I hope someone could clarify this to me.

A fundamental sequence to limit ordinal $\alpha$ is $\omega$-sequence $\{\alpha_i\}_{i\in\mathbb{N}}$ of ordinals such that for each $i\in\mathbb{N}$ we have $\alpha_i<\alpha_{i+1}<\alpha$ and $\lim_{i\in\mathbb{N}}\alpha_i=\alpha$.

For each countable limit ordinal $\beta$, let $\{\beta\}(i)$,$i\in\mathbb{N}$ denote a arbitrarily chosen fixed fundamental sequence to $\beta$. Define now $F_\alpha^n$ such that

1. $F_0^n(x)=(n+1)(x+1)$
2. $F_{\alpha+1}^0(x)=F_{\alpha}^x(x)$
3. $F_\beta^0(x)=F^0_{\{\beta\}(x)}(\varrho_\beta(x))$ where $\beta$ is a limit ordinal
4. $F_\gamma^{n+1}(x)=F_\gamma^0(F_\gamma^n(x)),\gamma\neq 0.$

Here for limit ordinal $\beta$ we have:

• $\varrho_\beta(0)=0$,
• $\varrho_\beta(m+1)=\mu_z(z>\varrho_\beta(m)\ \&\ (i)_{\leq m}(F_{\{\beta\}(m+1)}^0(z)>F_{\{\beta\}(i)}(z)))$.

I don't understand the definition of $F_\beta^0(x)$. It seems a sort of diagonalisation process (does it?) but the notation with a weak understanding of ordinal numbers (I'm working on the latter at the very moment) are giving me hard time. I guess $\mu_z$ refers to smallest $z$ such this-and-that, but I don't quite understand the overall construction.

What the definition says?

-
Where did you find this definitions? – Asaf Karagila Sep 6 '11 at 15:02
I cannot find the paper (not even behind a paywall), however the definition of $\varrho$ is very blurred to me. By $\&$ do you mean $\land$? What do you mean by $(i)_{\le m+1}$? Etc. etc. Could you please turn that into a list as well, may ease the readability. – Asaf Karagila Sep 6 '11 at 15:16
The definition of $\varrho$ is corrected in the second link. I have edited that into your post. – Asaf Karagila Sep 6 '11 at 16:29
Look again. It appears on the second paper as a correction. – Asaf Karagila Sep 6 '11 at 16:53
@Asaf: Since ‘$(x)$’ is another notation for ‘$\forall x$’, I suspect that ‘$(i)_{\le m+1}$’ is ‘$\forall i \le {m+1}$’; it makes sense in this context. – Brian M. Scott Sep 6 '11 at 22:03

In the second page is says that $\mu_z(\ldots)$ is the least $z$ such that $\ldots$ (i.e. the "least ..." operator)

As remarked by Brian M. Scott and Andres Caicedo $(i)_{\le m}$ it the set $\{0,\ldots,m\}$.

The definition is pretty much straightforward in the non-limit cases, so we only need to take care of the $\beta$ limit case.

Indeed as noted in the paper, and in your question, this is a form of diagonalization.

$\varrho_\beta$ is defined to return some "quickly" increasing sequence, so we could ensure some uniform behaviour with respect to the fundamental sequence that we've chosen in advance.

We want $\varrho_\beta(m+1)$ (assuming $x\neq 0$) to be a number $z$ such that:

• $z>\varrho_\beta(m)$;
• For all $i<m$ we have that $F^0_{\{\beta\}(m+1)}(z)>F^0_{\{\beta\}(i)}(z)$, which by previous definition means $F^z_{\{\beta\}(m)}(z)>F^z_{\{\beta\}(i-1)}(z)$, of course for $i>0$.

Taking the least $z$ with these properties is only a simple way of defining a choice function. It might be the case that the least-ness of $z$ is used later on, though.

Now, from this we can define $F^0_\beta(x)$. It is $F^0_{\{\beta\}(x)}(x)$. This ensures that $F^0_\beta$ is in a sense some sort of limit of the $F^0_{\{\beta\}(i)}$, which is what is usually wanted from transfinite sequences.

If you have further questions, I'd be glad to try and answer them.

-
Asaf: $(i)_{\le m}$ means $\forall i\le m$. It used to be standard (but ugly) notation in some places. – Andrés Caicedo Sep 7 '11 at 4:38
@Andres: Thanks, Brian M. Scott remarked that on the main question already. :-) – Asaf Karagila Sep 7 '11 at 5:52


text:
Select Board & Class

Areas Related to Circles

To understand the concepts of length of arc and the area of the sector of the circle, look at the following video.

Some important formulae to remember are:

 Area of a sector of angleθ

In case of quadrant, θ = 90°. Therefore,

In case of semicircle, θ = 180°. Therefore,

 Area of a semicircle

 Length of an arc of a sector of angle θ

 Perimeter of a Sector = $l+2r$

Relation between the area of sector and the length of an arc:
Look at the following figure.

Here, O is the centre of the circle of radius r and APB is an arc of length l.

Clearly,  measure of arc APB = Central angle =  θ

Let the area of sector OAPB be A.

Now, we have

From length of arc and area of corresponding sector, we can also conclude that.

These formulae are very helpful to calculate various attributes related to circle.

Let us solve some examples to learn the concept better.

Example 1:

Find the area of the sectors OACB and OADB. Also find the length of the arc ACB. (Take π =)

Solution:

Given, radius of the circle, r = 6.3 cm

Angle of sector OACB, θ = 40°

∴ Area of sector OACB = $\frac{\theta }{360}×{\mathrm{\pi r}}^{2}$

= 13.86...

To view the complete topic, please

Syllabus


text:
# modulus of complex number properties

Active today. Properties of modulus of complex number proving. Complex Number : Basic Concepts , Modulus and Argument of a Complex Number 2.Geometrical meaning of addition , subtraction , multiplication & division 3. Ask Question Asked today. Complex functions tutorial. reason for calling the Modulus and argument of complex number. Advanced mathematics. Properties of Modulus of a complex number. Then, the modulus of a complex number z, denoted by |z|, is defined to be the non-negative real number. Recall that any complex number, z, can be represented by a point in the complex plane as shown in Figure 1. 3.5 Determining 3D LVE bituminous mixture properties from LVE binder properties. Stay Home , Stay Safe and keep learning!!! Example: Find the modulus of z =4 – 3i. CBSE Class 11 Maths Notes: Complex Number – Properties of Modulus and Properties of Arguments. For any two complex numbers z1 and z2, we have |z1 + z2| ≤ |z1| + |z2|. Next, we will look at how we can describe a complex number slightly differently – instead of giving the and coordinates, we will give a distance (the modulus) and angle (the argument). This is the. Misc 13 Find the modulus and argument of the complex number ( 1 + 2i)/(1 − 3i) . Browse other questions tagged complex-numbers exponentiation or ask your own question. Solve practice problems that involve finding the modulus of a complex number Skills Practiced. It can be generalized by means of mathematical induction to (1) If z is expressed as a complex exponential (i.e., a phasor), then |re^(iphi)|=|r|. Cloudflare Ray ID: 613aa34168f51ce6 This is the reason for calling the Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.. Visit Stack Exchange The above inequality can be immediately extended by induction to any finite number of complex numbers i.e., for any n complex numbers z 1, z 2, z 3, …, z n Given an arbitrary complex number , we define its complex conjugate to be . Modulus and argument of the complex numbers. Any complex number in polar form is represented by z = r(cos∅ + isin∅) or z = r cis ∅ or z = r∠∅, where r represents the modulus or the distance of the point z from the origin. |z| = |3 – 4i| = 3 2 + (-4) 2 = 25 = 5 Comparison of complex numbers Consider two complex numbers z 1 = 2 + 3i, z 2 = 4 + 2i. Proof of the properties of the modulus. Principal value of the argument. 1 Algebra of Complex Numbers We deﬁne the algebra of complex numbers C to be the set of formal symbols x+ıy, x,y ∈ Modulus of the product is equal to product of the moduli. When the sum of two complex numbers is real, and the product of two complex numbers is also natural, then the complex numbers are conjugated. For any two complex numbers z 1 and z 2, we have |z 1 + z 2 | ≤ |z 1 | + |z 2 |. E-learning is the future today. Completing the CAPTCHA proves you are a human and gives you temporary access to the web property. Example: Find the modulus of z =4 – 3i. 11) −3 + 4i Real Imaginary 12) −1 + 5i Real Imaginary If x, y ∈ R, then an ordered pair (x, y) = x + iy is called a complex number. An alternative option for coordinates in the complex plane is the polar coordinate system that uses the distance of the point z from the origin (O), and the angle subtended between the positive real axis and the line segment Oz in a counterclockwise sense. Active today. They are the Modulus and Conjugate. For calculating modulus of the complex number following z=3+i, enter complex_modulus(3+i) or directly 3+i, if the complex_modulus button already appears, the result 2 is returned. Property Triangle inequality. April 22, 2019. in 11th Class, Class Notes. finite number of terms: |z1 z2 z3 ….. zn| = |z1| |z2| |z3| … … |zn|. triangle, by the similar argument we have, | |z1| - |z2| | ≤ | z1 + z2|  ≤  |z1| + |z2| and, | |z1| - |z2| | ≤ | z1 - z2|  ≤  |z1| + |z2|, For any two complex numbers z1 and z2, we have |z1 z2| = |z1| |z2|. as vertices of a A tutorial in plotting complex numbers on the Argand Diagram and find the Modulus (the distance from the point to the origin) Clearly z lies on a circle of unit radius having centre (0, 0). Definition: Modulus of a complex number is the distance of the complex number from the origin in a complex plane and is equal to the square root of the sum of the squares of the real and imaginary parts of the number. Properties of Modulus |z| = 0 => z = 0 + i0 Read formulas, definitions, laws from Modulus and Conjugate of a Complex Number here. Free math tutorial and lessons. Also express -5+ 5i in polar form Well, we can! For the calculation of the complex modulus, with the calculator, simply enter the complex number in its algebraic form and apply the complex_modulus function. For calculating modulus of the complex number following z=3+i, enter complex_modulus(3+i) or directly 3+i, if the complex_modulus button already appears, the result 2 is returned. 0. We call this the polar form of a complex number.. SHARES. Understanding Properties of Complex Arithmetic » The properties of real number arithmetic is extended to include i = √ − i = √ − For the calculation of the complex modulus, with the calculator, simply enter the complex number in its algebraic form and apply the complex_modulus function. (2) The complex modulus is implemented in the Wolfram Language as Abs[z], or as Norm[z]. Modulus of Complex Number Let = be a complex number, modulus of a complex number is denoted as which is equal to. Stay Home , Stay Safe and keep learning!!! Properties of Complex Numbers Date_____ Period____ Find the absolute value of each complex number. Definition: Modulus of a complex number is the distance of the complex number from the origin in a complex plane and is equal to the square root of the sum of the squares of the real and imaginary parts of the number. It can be generalized by means of mathematical induction to any Viewed 12 times 0 $\begingroup$ I ... determining modulus of complex number. Thus, the modulus of any complex number is equal to the positive square root of the product of the complex number and its conjugate complex number. This leads to the polar form of complex numbers. They are the Modulus and Conjugate. We write: z is a purely real number => z = . Since the complex numbers are not ordered, the definition given at the top for the real absolute value cannot be directly applied to complex numbers.However, the geometric interpretation of the absolute value of a real number as its distance from 0 can be generalised. complex number. Click here to learn the concepts of Modulus and its Properties of a Complex Number from Maths The modulus of a complex number The product of a complex number with its complex conjugate is a real, positive number: zz = (x+ iy)(x iy) = x2+ y2(3) and is often written zz = jzj2= x + y2(4) where jzj= p x2+ y2(5) is known as the modulus of z. E-learning is the future today. The ordering < is compatible with the arithmetic operations means the following: VIII a < b =⇒ a+c < b+c and ad < bd for all a,b,c ∈ R and d > 0. Complex analysis. Properties of Modulus,Argand diagramcomplex analysis applications, complex analysis problems and solutions, complex analysis lecture notes, complex Question 1 : Find the modulus of the following complex numbers (i) 2/(3 + 4i) Solution : We have to take modulus of both numerator and denominator separately. In this section, we will discuss the modulus and conjugate of a complex number along with a few solved examples. And ∅ is the angle subtended by z from the positive x-axis. If you are at an office or shared network, you can ask the network administrator to run a scan across the network looking for misconfigured or infected devices. Trigonometric form of the complex numbers. We call this the polar form of a complex number.. |z| = OP. Did you know we can graph complex numbers? Complex Numbers, Modulus of a Complex Number, Properties of Modulus Doorsteptutor material for IAS is prepared by world's top subject experts: Get complete video lectures from top expert with unlimited validity : cover entire syllabus, expected topics, in full detail- anytime and anywhere & … Definition of Modulus of a Complex Number: Let z = x + iy where x and y are real and i = √-1. Polar form. And it's actually quite simple. |z| = |3 – 4i| = 3 2 + (-4) 2 = 25 = 5 Comparison of complex numbers Consider two complex numbers z 1 = 2 + 3i, z 2 = 4 + 2i. Complex Numbers Represented By Vectors : It can be easily seen that multiplication by real numbers of a complex number is subjected to the same rule as the vectors. Modulus of a complex number gives the distance of the complex number from the origin in the argand plane, whereas the conjugate of a complex number gives the reflection of the complex number about the real axis in the argand plane. Solve practice problems that involve finding the modulus of a complex number Skills Practiced Problem solving - use acquired knowledge to solve practice problems, such as finding the modulus of 9 - i Now consider the triangle shown in figure with vertices, . $\sqrt{a^2 + b^2}$ Solution for Find the modulus and argument of the complex number (2+i/3-i)2. So, if z =a+ib then z=a−ib Study Material, Lecturing Notes, Assignment, Reference, Wiki description explanation, brief detail. Equations (1) and (2) are satisfied for infinitely many values of θ, any of these infinite values of θ is the value of amp z. 0. Copyright © 2018-2021 BrainKart.com; All Rights Reserved. Modulus of complex exponential function. property as "Triangle Inequality". It is important to recall that sometimes when adding or multiplying two complex numbers the result might be a real number as shown in the third part of the previous example! Complex numbers. Many amazing properties of complex numbers are revealed by looking at them in polar form!Let’s learn how to convert a complex number … Their are two important data points to calculate, based on complex numbers. Proof: That is the modulus value of a product of complex numbers is equal to the product of the moduli of complex numbers. (ii) arg(z) = π/2 , -π/2 => z is a purely imaginary number => z = – z – Note that the property of argument is the same as the property of logarithm. Then, the modulus of a complex number z, denoted by |z|, is defined to be the non-negative real number. VII given any two real numbers a,b, either a = b or a < b or b < a. 1 A- LEVEL – MATHEMATICS P 3 Complex Numbers (NOTES) 1. Next, we will look at how we can describe a complex number slightly differently – instead of giving the and coordinates, we will give a distance (the modulus) and angle (the argument). Properties of Modulus of a complex number: Let us prove some of the properties. Conjugate of Complex Number; Properties; Modulus and Argument; Euler’s form; Solved Problems; What are Complex Numbers? Properties of Modulus of Complex Numbers - Practice Questions. 1) 7 − i 2) −5 − 5i 3) −2 + 4i 4) 3 − 6i 5) 10 − 2i 6) −4 − 8i 7) −4 − 3i 8) 8 − 3i 9) 1 − 8i 10) −4 + 10 i Graph each number in the complex plane. Please enable Cookies and reload the page. If you are on a personal connection, like at home, you can run an anti-virus scan on your device to make sure it is not infected with malware. The norm (or modulus) of the complex number $$z = a + bi$$ is the distance from the origin to the point $$(a, b)$$ and is denoted by $$|z|$$. Featured on Meta Feature Preview: New Review Suspensions Mod UX We know from geometry A question on analytic functions. Here we introduce a number (symbol ) i = √-1 or i2 = -1 and we may deduce i3 = -i i4 = 1 We know from geometry If z=a+ib be any complex number then modulus of z is represented as ∣z∣ and is equal to a2 +b2 Conjugate of a complex number - formula Conjugate of a complex number a+ib is obtained by changing the sign of i. 0. Property of modulus of a number raised to the power of a complex number. Conversion from trigonometric to algebraic form. Solution: Properties of conjugate: (i) |z|=0 z=0 Algebraic, Geometric, Cartesian, Polar, Vector representation of the complex numbers. Solution: Properties of conjugate: (i) |z|=0 z=0 what you'll learn... Overview. finite number of terms: |z1 + z2 + z3 + …. However, the unique value of θ lying in the interval -π θ ≤ π and satisfying equations (1) and (2) is known as the principal value of arg z and it is denoted by arg z or amp z.Or in other words argument of a complex number means its principal value. Complex functions tutorial. And ∅ is the angle subtended by z from the positive x-axis. by Anand Meena. It is denoted by z. Complex numbers tutorial. In the above result Θ 1 + Θ 2 or Θ 1 – Θ 2 are not necessarily the principle values of the argument of corresponding complex numbers. Then the non negative square root of (x^2 + y^2) is called the modulus or absolute value of z (or x + iy). Properties $$\eqref{eq:MProd}$$ and $$\eqref{eq:MQuot}$$ relate the modulus of a product/quotient of two complex numbers to the product/quotient of the modulus of the individual numbers.We now need to take a look at a similar relationship for sums of complex … If $$z = a + bi$$ is a complex number, then we can plot $$z$$ in the plane as shown in Figure $$\PageIndex{1}$$. (BS) Developed by Therithal info, Chennai. Polar form. Any complex number in polar form is represented by z = r(cos∅ + isin∅) or z = r cis ∅ or z = r∠∅, where r represents the modulus or the distance of the point z from the origin. + zn | ≤ |z1| + |z2| + |z3| + … + |zn| for n = 2,3,…. Covid-19 has led the world to go through a phenomenal transition . • Modulus of a Complex Number. (1) If <(z) = 0, we say z is (purely) imaginary and similarly if =(z) = 0, then we say z is real. Using the identity we derive the important formula and we define the modulus of a complex number z to be Note that the modulus of a complex number is always a nonnegative real number. The sum and product of two conjugate complex quantities are both real. Modulus of a Complex Number. Let us prove some of the properties. Basic Algebraic Properties of Complex Numbers, Exercise 2.3: Properties of Complex Numbers, Exercise 2.4: Conjugate of a Complex Number, Modulus of a Complex Number: Solved Example Problems, Exercise 2.5: Modulus of a Complex Number, Exercise 2.6: Geometry and Locus of Complex Numbers. Like real numbers, the set of complex numbers also satisfies the commutative, associative and distributive laws i.e., if z 1, z 2 and z 3 be three complex numbers then, z 1 + z 2 = z 2 + z 1 (commutative law for addition) and z 1. z 2 = z 2. z 1 (commutative law for multiplication). In this situation, we will let $$r$$ be the magnitude of $$z$$ (that is, the distance from $$z$$ to the origin) and $$\theta$$ the angle $$z$$ makes with the positive real axis as shown in Figure $$\PageIndex{1}$$. Modulus or absolute value of z = |z| |z| = a 2 + b 2 Since a and b are real, the modulus of the complex number will also be real. That is the modulus value of a product of complex numbers is equal If z1 = x1 + iy1 and z2 = x2 + iy2 , then, | z1 - z2| = | ( x1 - x2 ) + ( y1 - y2 )i|, The distance between the two points z1 and z2 in complex plane is | z1 - z2 |, If we consider origin, z1 and z2 as vertices of a Their are two important data points to calculate, based on complex numbers. C. Sauzeat, H. Di Benedetto, in Advances in Asphalt Materials, 2015. Modulus of a complex number z = a+ib is defined by a positive real number given by where a, b real numbers. Ex: Find the modulus of z = 3 – 4i. Complex analysis. If the corresponding complex number is known as unimodular complex number. This is equivalent to the requirement that z/w be a positive real number. The third part of the previous example also gives a nice property about complex numbers. Free math tutorial and lessons. Share on Facebook Share on Twitter. Geometrically |z| represents the distance of point P from the origin, i.e. that the length of the side of the triangle corresponding to the vector, cannot be greater than Modulus of a complex number: The modulus of a complex number z=a+ib is denoted by |z| and is defined as . Problem solving - use acquired knowledge to solve practice problems, such as finding the modulus of 9 - i Table Content : 1. Triangle Inequality. Performance & security by Cloudflare, Please complete the security check to access. $\sqrt{a^2 + b^2}$ Similarly we can prove the other properties of modulus of a complex number. 5. that the length of the side of the triangle corresponding to the vector  z1 + z2 cannot be greater than Ask Question Asked today. Modulus of complex number properties Property 1 : The modules of sum of two complex numbers is always less than or equal to the sum of their moduli. These are respectively called the real part and imaginary part of z. The square |z|^2 of |z| is sometimes called the absolute square. Commutative Property of Complex Multiplication: for any complex number z1,z2 ∈ C z 1, z 2 ∈ ℂ z1 × z2 = z2 × z1 z 1 × z 2 = z 2 × z 1 Complex numbers can be swapped in complex multiplication - … Viewed 4 times -1 $\begingroup$ How can i Proved ... properties of complex modulus question. triangle, by the similar argument we have. For practitioners, this would be a very useful tool to spare testing time. 1. Many researchers have focused on the prediction of a mixture– complex modulus from binder properties. the sum of the lengths of the remaining two sides. Proof ⇒ |z 1 + z 2 | 2 ≤ (|z 1 | + |z 2 |) 2 ⇒ |z 1 + z 2 | ≤ |z 1 | + |z 2 | Geometrical interpretation. 0. This leads to the polar form of complex numbers. Proof: Let z = x + iy be a complex number where x, y are real. to the product of the moduli of complex numbers. Modulus and argument. Covid-19 has led the world to go through a phenomenal transition . Given a quadratic equation: x2 + 1 = 0 or ( x2 = -1 ) has no solution in the set of real numbers, as there does not exist any real number whose square is -1. Read formulas, definitions, laws from Modulus and Conjugate of a Complex Number here. 0. Observe that a complex number is well-determined by the two real numbers, x,y viz., z := x+ıy. It can be shown that the complex numbers satisfy many useful and familiar properties, which are similar to properties of the real numbers. Properties $$\eqref{eq:MProd}$$ and $$\eqref{eq:MQuot}$$ relate the modulus of a product/quotient of two complex numbers to the product/quotient of the modulus of the individual numbers.We now need to take a look at a similar relationship for sums of complex numbers.This relationship is called the triangle inequality and is, Let z = a + ib be a complex number. In the above figure, is equal to the distance between the point and origin in argand plane. Geometrically, modulus of a complex number = is the distance between the corresponding point of which is and the origin in the argand plane. Now … The modulus and argument of a complex number sigma-complex9-2009-1 In this unit you are going to learn about the modulusand argumentof a complex number. Properties of modulus Then, conjugate of z is = … Your IP: 185.230.184.20 Complex Numbers, Modulus of a Complex Number, Properties of Modulus Doorsteptutor material for IAS is prepared by world's top subject experts: Get complete video lectures from top expert with unlimited validity : cover entire syllabus, expected topics, in full detail- anytime and anywhere & … Mathematical articles, tutorial, examples. When the angles between the complex numbers of the equivalence classes above (when the complex numbers were considered as vectors) were explored, nothing was found. Negative number raised to a fractional power. The modulus of a complex number z, also called the complex norm, is denoted |z| and defined by |x+iy|=sqrt(x^2+y^2). the sum of the lengths of the remaining two sides. VIEWS. Where x is real part of Re(z) and y is imaginary part or Im (z) of the complex number. Beginning Activity. Complex Numbers Represented By Vectors : It can be easily seen that multiplication by real numbers of a complex number is subjected to the same rule as the vectors. On the The Set of Complex Numbers is a Field page we then noted that the set of complex numbers $\mathbb{C}$ with the operations of addition $+$ and multiplication $\cdot$ defined above make $(\mathbb{C}, +, \cdot)$ an algebraic field (similarly to that of the real numbers with the usually defined addition and multiplication). Stack Exchange network consists of 176 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share … Modulus and argument. Modulus of a Complex Number. The equality holds if one of the numbers is 0 and, in a non-trivial case, only when Im(zw') = 0 and Re(zw') is positive. Since a and b are real, the modulus of the complex number will also be real. Similarly we can prove the other properties of modulus of a Click here to learn the concepts of Modulus and Conjugate of a Complex Number from Maths These are quantities which can be recognised by looking at an Argand diagram. 0. Ex: Find the modulus of z = 3 – 4i. Reading Time: 3min read 0. (ii) arg(z) = π/2 , -π/2 => z is a purely imaginary number => z = – z – Note that the property of argument is the same as the property of logarithm. Properties of Modulus of a complex number. Complex Number Properties. Modulus of a complex number: The modulus of a complex number z=a+ib is denoted by |z| and is defined as . Complex plane, Modulus, Properties of modulus and Argand Diagram Complex plane The plane on which complex numbers are represented is known as the complex … An alternative option for coordinates in the complex plane is the polar coordinate system that uses the distance of the point z from the origin (O), and the angle subtended between the positive real axis and the line segment Oz in a counterclockwise sense. Properies of the modulus of the complex numbers. Now consider the triangle shown in figure with vertices O, z1  or z2 , and z1 + z2. Click here to learn the concepts of Modulus and its Properties of a Complex Number from Maths

0 replies


text:
math.CA

(what is this?)

# Title: Semmes surfaces and intrinsic Lipschitz graphs in the Heisenberg group

Abstract: A Semmes surface in the first Heisenberg group is a closed upper $3$-regular set $S$ that satisfies the following condition, referred to as Condition B: every ball $B(x,r)$ with $x \in S$ and $0 < r < \mathrm{diam}(S)$ contains two balls with radii comparable to $r$ which are contained in different connected components of the complement of $S$. Analogous surfaces in Euclidean spaces were introduced by Semmes in the late $80$'s. We prove that Semmes surfaces in the Heisenberg group are lower $3$-regular, and have big pieces of intrinsic Lipschitz graphs. In particular, our result applies to the boundaries of chord-arc domains in the Heisenberg group.
 Comments: 32 pages, 5 figures Subjects: Classical Analysis and ODEs (math.CA); Metric Geometry (math.MG) MSC classes: 28A75 (Primary) 28A78 (Secondary) Cite as: arXiv:1803.04819 [math.CA] (or arXiv:1803.04819v1 [math.CA] for this version)

## Submission history

From: Tuomas Orponen [view email]
[v1] Tue, 13 Mar 2018 14:08:13 GMT (155kb)


text:
# Math Help - Find y'' given x + xy + y =2

1. ## Find y'' given x + xy + y =2

I'm learning Calculus on my own this summer and I've encountered a simple problem which i can't seem to get the right answer to. Here is the problem and my solution:

Find y'' given x + xy + y =2
first derivative
1 + y + x(y') + y' = 0 took derivative of each term
1 + y + y'(x+1) = 0 simplified a bit
(-1-y)/(x+1) = y' simple algebra.
second derivative
[-y'(x+1) - 1(-1-y)]/[(x+1)^2] quotient rule
[-y'(x+1)]/[(x+1)^2] - (-1-y)/[(x+1)^2] = 0 restated in a more useful manner.
[-y'(x+1)]/[(x+1)^2] = (-1-y)/[(x+1)^2] simple algebra
-y'(x+1) = -1-y simple algebra
y'(x+1) = 1+y multiplied both sides by -1
y' = (1+y) / (x+1)

The answer the books gives is: [2(1+y)]/[(1=x)^2]

Thanks in advance for help.

2. ## Re: Basic calculus problem.

Originally Posted by RussianScience

Find y'' given x + xy + y =2
Have a go this way,

$x + xy + y =2$

$xy + y =2-x$

$y(x + 1) =2-x$

$y =\frac{2-x}{x+1}$

Now find y' and y''

3. ## Re: Basic calculus problem.

Originally Posted by RussianScience
[-y'(x+1)]/[(x+1)^2] - (-1-y)/[(x+1)^2] = 0 restated in a more useful manner.
Very bad. You have just decreed that the second derivative is everywhere zero (0).

Try = y" rather than = 0.

4. ## Re: Basic calculus problem.

Originally Posted by TKHunny
Very bad. You have just decreed that the second derivative is everywhere zero (0).

Try = y" rather than = 0.
That clears so much up, thanks for finding my stupid mistake!

5. ## Re: Basic calculus problem.

An alternative (implicit differentiation):

$x+xy+y=2\Rightarrow 1+y+xy'+y'=0\Rightarrow y'+y'+xy''+y''=0\Rightarrow$

$y''=\dfrac{-2y'}{x+1}$

Of course, in this case we can substitute $y'=\ldots$ and $y=\ldots$ .


text:
# Boundary Conditions¶

## DCR¶

In Steady State Equations, we introduced the governing equations for the DCR problem

(332)$\boldsymbol{\nabla} \cdot \sigma\boldsymbol{\nabla}\phi = \boldsymbol{\nabla}\cdot\mathbf{j}_{source}.$

In order to construct a boundary value problem to determine the potential for a given source and conductivity model, (332) must be supplemented by appropriate boundary conditions. While different boundary conditions are possible, we will only discuss the common case of applying a homogeneous Neumann condition at the earth’s surface and homogeneous Dirichlet conditions elsewhere.

To derive the Dirichlet condition at the sides and bottom of the domain, it is first important to note that electrical potential is only unique up to an arbitrary constant, which is determined by convention. DC surveys measure potential differences so this is not important for field measurements but it is important in solving (332). We use the standard convention that the potential is zero infinitely far from all charges and currents. In solving for the discrete approximation to the potential, we make the boundaries at the sides and bottom of the domain far enough from any sources that the potential is approximately zero there. We then use homogeneous Dirichlet conditions on those boundaries in solving the discrete problem.

We derive the earth surface boundary condition from the fact that currents cannot flow into the air. Mathematically this can be stated as

$\mathbf{j}\cdot \hat{\mathbf{n}} = 0 \qquad \text{on} \quad \partial_s \Omega,$

where $$\partial_s \Omega$$ indicates the surface of the earth and $$\hat{\mathbf{n}}$$ is the unit surface normal vector. Applying Ohm’s law in the earth, this becomes

$\sigma \mathbf{e}\cdot\hat{\mathbf{n}} = 0.$

Since $$\sigma$$ must be strictly positive in the earth, we divide by it to give

$\mathbf{e}\cdot\hat{\mathbf{n}} = 0$

at the surface. Finally, writing the electric field as the negative gradient of the electric potential gives the surface boundary condition

$(\boldsymbol{\nabla}\phi) \cdot \hat{\mathbf{n}} = 0 \qquad \text{on} \quad \partial_s \Omega.$