text:
# BSK Scripting Settings¶

## Overview¶

The About Vizard Unity-based visualization can have its settings scripted from a Basilisk python simulation script. This allows the user to write a BSK simulation script and specify in the same script what Vizard options should be used. Within Vizard the user can change these gain if needed. The BSK scripted Vizard settings are only used once at the beginning of the playback.

When calling the enableUnityVisualization macro method a copy of the vizInterface module is returned. All scriptable Vizard settings are stored inside the settings variable. For example, to set the Vizard ambient lighting the following code is used:

viz = vizSupport.enableUnityVisualization(scSim, simTaskName, scObject, saveFile=fileName)
viz.settings.ambient = 0.5

Here scObject is a Module: spacecraft instance. This can also be a list of spacecraft objects for a multi-satellite simulation. The spacecraft names are pulled from scObject.ModelTag. If a setting is not provided, then the Vizard defaults are used. This allows the user to specify just a few or a lot of settings, as is appropriate.

## Listing of all BSK Scriptable Vizard Settings¶

The following list contains the optional Vizard settings that can be specified. Only the settings used will be applied to Vizard. If a variable below is not specified, then it is not applied to Vizard and the Vizard default values are used.

### General Settings¶

The following settings can be set directly using:

viz.settings.variableName = value

Note that for setting flags 1 means turn on, -1 means turn off, and a setting of 0 tells Vizard to use its own default setting for that behavior.

Vizard Simulation Parameters

Variable

Type

Description

ambient

[0,1]

float value to specify the ambient Vizard lighting.

orbitLinesOn

(-1,1)

flag to show (1) or hide (-1) the orbit trajectory lines

spacecraftCSon

(-1,1)

flag to show (1) or hide (-1) the spacecraft coordinate axes

planetCSon

(-1,1)

flag to show (1) or hide (-1) the planet coordinate axes

skyBox

String

Used determine what star background should be shown. The empty string “” provides default NASA SVS Starmap, “ESO” shows the ESO Milky Way skybox, “black” provides a black background, or the user can provide a filepath to custom background image file.

viewCameraBoresightHUD

(-1,1)

flag to show (1) or hide (-1) the camera boresight line

viewCameraConeHUD

(-1,1)

flag to show (1) or hide (-1) the camera cone

showCSLabels

(-1,1)

flag to show (1) or hide (-) the coordinate system labels

showCelestialBodyLabels

(-1,1)

flag to show (1) or hide (-1) the celestial body labels

showSpacecraftLabels

(-1,1)

flag to show (1) or hide (-1) the spacecraft labels

showCameraLabels

(-1,1)

flag to show (1) or hide (-1) the camera labels

customGUIScale

pos. double

GUI scaling factor, default is -1 which uses Vizard default.

defaultSpacecraftSprite

string

Set sprite for ALL spacecraft through shape name and optional int RGB color values [0,255]. Possible settings: CIRCLE, SQUARE, STAR, TRIANGLE or bskSat for a 2D spacecraft sprite of the bskSat shape. Default value is empty yielding a white CIRCLE. To set this in python, use the helper function vizSupport.setSprite("STAR", color="red")

showSpacecraftAsSprites

(-1,1)

Flag to show spacecraft as sprites if their visual size gets too small

showCelestialBodiesAsSprites

(-1,1)

Flag to show celestial bodies as sprites if their visual size gets too small

show24hrClock

(-1,1)

Flag to make mission date/time use a 24h clock instead of a 12h clock with am/pm

showDataRateDisplay

(-1,1)

Flag to show the data frame rate

keyboardAngularRate

pos. double

[rad/sec] controls the angular rate at which the camera rotates with keyboard hot-keys.

keyboardZoomRate

pos. double

Non-dimensional speed at which the camera zooms in and out with hot-keys.

defaultThrusterColor

int(4)

RGBA color values between (0,255). Default values of -1 makes Vizard use the default thruster plume color You can use vizSupport.toRGBA255("red") to convert common color names to RGBA values.

defaultThrusterPlumeLifeScalar

double

Value of 1.0 or 0.0 to use viz default, values between 0 and 1 will decrease the length of all thruster plumes, >1 will increase lengths of all thruster plumes

orbitLineSegments

int

Number of line segments to use when drawing an osculating trajectory. Value of 0 (protobuffer default) to use viz default or any value greater than or equal to 4

relativeOrbitRange

int

+/- angular range in degrees of the osculating trajectory to show. Value of 0 (protobuffer default) to use viz default or any value greater than or equal to 1

showHillFrame

int

flag to show the orbit Hill frame of the spacecraft camera target. Value of 0 (protobuffer default) to use viz default, -1 for false, 1 for true

showVelocityFrame

int

flag to show the orbit velocity frame of the spacecraft camera target. Value of 0 (protobuffer default) to use viz default, -1 for false, 1 for true

relativeOrbitFrame

int

flag to set with respect to which frame the relative orbit trajectory is drawn. Value of 0 (protobuffer default) or 1 to use Hill Frame, 2 to use Velocity Frame

relativeOrbitFrame

string

If valid spacecraft name provided, the relative orbit chief spacecraft will be set to that spacecraft object. Setting the string to “AUTO” or leaving this field empty will select the camera target spacecraft as the chief.

spacecraftShadowBrightness

double

Control the ambient light specific to spacecraft objects, value between 0 and 1, use negative value to use viz default

spacecraftSizeMultiplier

double

Control the display size of spacecraft in the Planet and Solar System Views, values greater than 0, use negative value to use viz default

showLocationCommLines

int

Value of 0 (protobuffer default) to use viz default, -1 for false, 1 for true

showLocationCones

int

Value of 0 (protobuffer default) to use viz default, -1 for false, 1 for true

showLocationLabels

int

Value of 0 (protobuffer default) to use viz default, -1 for false, 1 for true

### Setting Actuator GUI Options¶

To specify the actuator GUI settings use the setActuatorGuiSetting helper method in Python. An example is:

vizSupport.setActuatorGuiSetting(viz, viewRWPanel=True, viewRWHUD=True)

The following table includes the keyword options for this method.

GUI Parameter Options

Variable

Type

Required

Description

viewThrusterPanel

Boolean

No

Show the thruster panel

viewThrusterHUD

Boolean

No

Show the thruster particle streams

showThrusterLabels

Boolean

No

Show the thruster labels

viewRWPanel

Boolean

No

Show the reaction wheel panel

viewRWHUD

Boolean

No

Show the reaction wheel disks configuration outside the spacecraft

showRWLabels

Boolean

No

Show the reaction wheel labels

spacecraftName

string

No, sc name default

Specify which spacecraft should show actuator information. If not provided then the viz.spacecraftName is used.

### Setting Instrument GUI Options¶

To specify the instrument GUI settings use the setInstrumentGuiSetting helper method in Python. An example is:

vizSupport.setInstrumentGuiSetting(viz, viewCSSPanel=True, viewCSSCoverage=True)

The following table includes the keyword options for this method.

GUI Parameter Options

Variable

Type

Required

Description

viewCSSPanel

Boolean

No

Show the CSS panel

viewCSSCoverage

Boolean

No

Show the CSS coverage spheres

viewCSSBoresight

Boolean

No

Show the CSS boresight axes

showCSSLabels

Boolean

No

Show the CSS labels

spacecraftName

string

No, sc name default

Specify which spacecraft should show actuator information. If not provided then the viz.spacecraftName is used.

### Defining a Pointing Line¶

Vizard can create a heading line from one object to another. For example, it might be handy to create a line from the spacecraft pointing towards the sun direction, or from the spacecraft towards Earth to know how the antennas should point. These pointing lines can be scripted from Basilisk as well using using a helper function createPointLine():

viz = vizSupport.enableUnityVisualization(scSim, simTaskName, scObject, saveFile=fileName)
vizSupport.createPointLine(viz, toBodyName='earth', lineColor=[0, 0, 255, 255])
vizSupport.createPointLine(viz, toBodyName=“sun”, lineColor=“yellow”)]

The createPointLine support macro requires the parameters toBodyName and lineColor to be defined. The parameter fromBodyName is optional. If it is not specified, then the viz.spacecraftName is used as a default origin. The lineColor state can be either a string containing the color name, or a list containing RGBA values. The support macro converts this into the required set of numerical values.

Each pointing line message contains the three variables listed in the next table.

Pointing Line Parameter Options

Variable

Type

Required

Description

fromBodyName

string

No, sc name default

contains the name of the originating body

toBodyName

string

Yes

contains the name of the body to point towards

lineColor

int(4)

Yes

color name or array on integer values specifying the RGBA values between 0 to 255

### Defining Keep In/Out Cones¶

Vizard can create cones relative to the spacecraft which illustrated if a body axis is within some angle to the sun (i.e. keep in cone), or if a sensor axis is outside some angle to the sun (i.e. keep out cone). These cones can be setup in Vizard, but can also be scripted from Basilisk using the helper function createConeInOut:

viz = vizSupport.enableUnityVisualization(scSim, simTaskName, scObject, saveFile=fileName)
vizSupport.createConeInOut(viz, toBodyName='earth', coneColor='teal',
normalVector_B=[1, 0, 0], incidenceAngle=30\ macros.D2R, isKeepIn=True,
coneHeight=5.0, coneName=‘sensorCone’)
vizSupport.createConeInOut(viz,toBodyName='earth', coneColor='blue', normalVector_B=[0, 1, 0],
incidenceAngle=30\ macros.D2R, isKeepIn=False, coneHeight=5.0, coneName=‘comCone’)]

The following table illustrates the arguments for the createConeInOut method:

Keep In/Out Cones Parameter Options

Variable

Type

Units

Required

Description

isKeepIn

bool

Yes

make cone keep in (True) or keep out (False)

fromBodyName

string

No, sc name default

contains the name of the originating body

toBodyName

string

Yes

contains the name of the body to point towards

lineColor

int(4)

Yes

color name or array on integer values specifying the RGBA values between 0 to 255

position_B

float(3)

m

No, (0,0,0) default

position of the cone vertex

normalVector_B

float(3)

m

Yes

normal axis of the cone in body frame components

incidenceAngle

float

Yes

angle of the cone

incidenceAngle

float

Yes

height of the cone

coneName

string

No

cone label name, if unspecified viz will autogenerate name

### Defining the Vizard Camera View Panels¶

Vizard can create a spacecraft relative camera panel. This functionality can be controlled by using the createStandardCamera helper method. The camera can point in a body-fixed direction (setMode=1), or be aimed at a celestial target (setMode=0). Multiple camera panels can be setup at the same time, and they can be attached to different spacecraft through the spacecraftName argument.

viz = vizSupport.enableUnityVisualization(scSim, simTaskName, scObject, saveFile=fileName)
vizSupport.createStandardCamera(viz, setMode=0, bodyTarget='earth', setView=0)
vizSupport.createStandardCamera(viz, setMode=1, fieldOfView=60.*macros.D2R, pointingVector_B=[0.0, -1.0, 0.0])

The following table illustrates the arguments for the createStandardCamera method.

Standard Camera View Panel Parameter Options

Variable

Type

Units

Required

Description

spacecraftName

string

No, sc name default

name of the spacecraft with respect to which the camera is shown

setMode

int

No, default is 1

0 -> body targeting, 1 -> pointing vector

setView

int

No, default is 0

0 -> Nadir, 1 -> Orbit Normal, 2 -> Along Track (default to nadir). This is a setting for body targeting mode.

bodyTarget

string

No, default to first celestial body in messages

Name of body camera should point to. This is a setting for body targeting mode.

fieldOfView

float

No, default is -1

camera edge-to-edge field of view in the camera vertical y axis, to use the Vizard default set it to -1

pointingVector_B

float(3)

No, default is (0,0,0) for auto placement

Name of body camera should point to. This is a setting for pointing vector mode

position_B

float(3)

m

No, default is (0,0,0) for auto placement

If populated, ets camera position relative to parent body coordinate frame in meters using B frame components. If unpopulated camera is positioned automatically along camera view direction outside of parent body’s mesh to prevent obstruction of view.

It is also possible to create a custom instrument camera view for opNav mode which points in an arbitrary direction as illustrate in the image above. The following helper method is an example of how such an instrument camera view can be created:

vizSupport.createCameraConfigMsg(viz, cameraID=1, fieldOfView=10 * macros.D2R,
resolution=[1024, 1024], renderRate=0.1,
cameraPos_B=[0.2, 0.1, 0.3], sigma_CB=[-1./3., 1./3., -1./3.])

Note that with this instrument camera Vizard will save off images the the user home folder at the rate specified in renderRate. To avoid saving off images just make renderRate zero.

The camera frame is illustrated in the following image. It uses classical image image coordinates where x points to the right, y point downwards and z points outward. More information is availabe in section 2.4.1 of Dr. Teil’s dissertation.

The following tale illustrates the arguments for the createCameraConfigMsg method.

createCameraConfigMsg Parameter Options

Variable

Type

Units

Required

Description

cameraID

int

Yes

ID of the Vizard camera

parentName

string

No, sc name default

name of the spacecraft with respect to which the camera is shown

fieldOfView

float

yes

edge-to-edge field of view in the camera vertical y axis

resolution

int(2)

yes

image sensor pixels

renderRate

float

yes

time between image grabs. 0 turns this off (default).

cameraPos_B

float(3)

m

yes

camera location relative to body frame in B frame components

sigma_CB

float(3)

yes

camera orientation relative to the body frame in MRPs

skyBox

string

No

Used to determine what star background should be shown. The empty string “” provides default NASA SVS Starmap, “ESO” shows the ESO Milky Way skybox, “black” provides a black background, or the user can provide a filepath to custom background image file.

### Defining the Custom Spacecraft Shape model¶

You can specify a custom OBJ model to be used with Vizard spacecraft representation. An sample is shown in the following screen capture.

This functionality can be controlled by using the ‘createCustomModel’ helper method.

viz = vizSupport.enableUnityVisualization(scSim, simTaskName, scObject, saveFile=fileName)
vizSupport.createCustomModel(viz,
scale=[2, 2, 10])

The following table illustrates the arguments for the createCustomModel method.

Custom Space Object OBJ Import Parameter Options

Variable

Type

Units

Required

Description

modelPath

string

Yes

Path to model obj -OR- “CUBE”, “CYLINDER”, or “SPHERE” to use a primitive shape

simBodiesToModify

string

No, default is bsk-Sat

Which bodies in scene to replace with this model, use “ALL_SPACECRAFT” to apply custom model to all spacecraft in simulation

offset

float(3)

m

No, default is (0,0,0)

offset to use to draw the model

rotation

float(3)

No, default is (0,0,0)

scale

float(3)

No, default is (1,1,1)

desired model scale in x, y, z in spacecraft CS

customTexturePath

String

No

Path to texture to apply to model (note that a custom model’s .mtl will be automatically imported with its textures during custom model import). The image file types supported are: jpg, bmp, exr, gif, hdr, iff, pict, png, psd, tga, and tiff. The maximum image dimensions supported for runtime import are 16384 pixels by 16384 pixels. The image does not have to be square.

normalMapPath

string

No

Path to the normal map for the customTexture

shader

int

No, default is -1

Value of -1 to use viz default, 0 for Unity Specular Standard Shader, 1 for Unity Standard Shader

### Specifying the Spacecraft Sprite Representation¶

In the spacecraft centric view a 3D model is rendered of the spacecraft. However, in planet and heliocentric views the spacecraft is automatically represented as a 2D sprite (circle, triangle, etc.) if more than one spacecraft is being simulated. The default sprite shape for all spacecraft can be set through the defaultSpacecraftSprite value discussed above. To specify a specific sprite shape, and optional color, for a specific spacecraft this can be done by setting the string variable spacecraftSprite inside the spacecraft data structure.

The example scenario scenarioFormationBasic illustrates how to simulate multiple spacecraft. To make a spacecraft use a specific sprite representation use:

scData.spacecraftSprite = vizSupport.setSprite("STAR")

### Specifying the Simulation Epoch Date and Time Information¶

Vizard can show the both the simulation time that has elapsed, or the mission time. If now epoch message has been set then Basilisk assumes a default January 1, 2019, 00:00:00 epoch time and date. The simulation time elapsed is thus the time since epoch. To specify a different simulation epoch data and time the EpochMsgPayload can be setup as discussed in scenarioMagneticFieldWMM. To tell Module: vizInterface what epoch message to read use:

viz.epochInMsg.subscribe(epochMsg)

An example of the use of this epoch message is shown in scenarioMagneticFieldWMM.

### Specifying Reaction Wheel (RW) Information¶

The simplest method to include the RW states of a one more spacecraft in the Vizard data file is to call vizSupport.enableUnityVisualization() with the additional argument:

rwEffectorList=rwStateEffector

Here rwStateEffector is an instance of a single Module: reactionWheelStateEffector which already has all the spacecraft’s RW devices added to it. If you have multiple spacecraft, then use a list of RW effectors, one effector per spacecraft:

rwEffectorList=[rwStateEffector1, rwStateEffector2]

This method is illustrated in the scenarioAttitudeFeedbackRW script. Note that this list must contain one entry per spacecraft. If a spacecraft has no RW devices, then add None instead of an effector instance.

If custom RW state output messages are used, then the scData.rwInMsgs can be specified directly. This case is employed in the test script test_dataFileToViz.

### Specifying Thruster Information¶

The simplest method to include the clusters of thrusters of a one more spacecraft in the Vizard data file is to call vizSupport.enableUnityVisualization() with the additional argument:

thrEffectorList=thrusterSet

Here thrusterSet is an instance of a single Module: thrusterDynamicEffector which already has all the spacecraft’s THR devices added to this one THR cluster. If you have multiple spacecraft, or a spacecraft has multiple clusters of THR devices such as ACS and DV thrusters, then use a double list of THR effectors. The outer list has one entry per spacecraft, and the inner list has one entry per spacecraft THR cluster:

thrEffectorList=[[thrusterSet1Sc1, thrusterSet2Sc1], [thrusterSet1Sc2]]

The outer list must have one THR cluster list per spacecraft. If a spacecraft has no THR devices, then add None instead of this cluster list. The illustration of thrusters is shown in the example script scenarioAttitudeFeedback2T_TH.

Note that if the maximum force of a thruster is less than 0.01N (i.e. a micro-thruster), then the plume length is held the same as with a 0.01N thruster. Otherwise the micro-thruster plumes would not be visible.

If you want to change the thruster plume illustration color, then you can use the optional argument:

thrColors=vizSupport.toRGBA255("red")

This example is for a single spacecraft. If you have multiple spacecraft this must again be wrapped in a list of lists as above. The inner list is the color you want to for each cluster. Thus, its dimension must match the thrEffectorList double list dimension. If you want to keep the default color for a spacecraft then add None as the cluster color.

The thruster information for each spacecraft can also be set directly by specifying sc.thrInMsgs and sc.thrInfo directly as demonstrated in test_dataFileToViz.

### Adding Location or Communication Stations¶

The Module: groundLocation is able to simulate a location on a celestial body like Earth. The location can also be fixed to a satellite. Vizard will show a line between a satellite and this location including if the satellite is within the field of view of this location. Vizard can illustrate this ground location using the addLocation() method, such as:

vizSupport.addLocation(viz, stationName="Boulder Station"
, parentBodyName='earth'
, r_GP_P=groundStation.r_LP_P_Init
, color='pink'
, range=1000.0
)

The following table lists all required and optional arguments that can be provided to addLocation:

Location Parameter Options

Variable

Type

Units

Required

Description

stationName

string

Yes

Label of the ground location

parentBodyName

string

Yes

name of the planet object

r_GP_P

float(3)

m

Yes

position vector of the location G relatiave to parent body (planet or spacecraft) frame P in P frame components

gHat_P

float(3)

No

normal vector of the location station boresight, default is unit vector of r_GP_P

fieldOfView

float

No

edge-to-edge location station field of view, default is $$\pi$$

color

int(4)

No

specify the location station color using RGBA value of 0-255

range

double

m

No

range of the location station, use 0 or negative value (protobuffer default) to use viz default


text:
42 views

Let $X(t)$ be a wide sense stationary $(WSS)$ random process with power spectral density $S_{X}(f).$ If $Y(t)$ is the process defined as $Y(t)= X(2t-1)$, the power spectral density $S_{Y}( f )$ is

1. $S_{Y}( f )= \frac{1}{2}S_{X}\left ( \frac{f}{2} \right )e^{-j\pi f}$
2. $S_{Y}( f )= \frac{1}{2}S_{X}\left ( \frac{f}{2} \right )e^{-j\pi f/2}$
3. $S_{Y}( f )= \frac{1}{2}S_{X}\left ( \frac{f}{2} \right )$
4. $S_{Y}( f )= \frac{1}{2}S_{X}\left ( \frac{f}{2} \right )e^{-j2\pi f }$

format: plain


text:
Nanotech 2007 Vol. 3
Technical Proceedings of the 2007 NSTI Nanotechnology Conference and Trade Show, Volume 3

# A Compact Model for Temperature and Frequency Dependence of Spiral Inductor

Authors: Y.Z. Xu and J.T. Watt

Affilation: Altera Corporation, United States

Pages: 674 - 677

Keywords: RF, Spiral inductor, Compact Model

Abstract:
Spiral inductors fabricated using a 90nm CMOS process have been characterized and analyzed. The extracted series resistance increases with frequency and temperature. The extracted resistance temperature coefficient exhibits a strong dependence on operating frequency. It gradually decreases with frequency and is different from the results using DC temperature coefficients. A single $\pi$-model is used to model the measured high frequency characteristics. Two resistors and a transformer are used to model the observed temperature coefficient. One resistor has temperature coefficient around DC value, while the other one is less dependent on temperature and connected through the other side of the transformer. The model shows good fitting to all parameters, such as series resistance, temperature coefficient, inductance, quality factor and s-parameters across a wide frequency range and from room to high temperature. Discussion of process variation and corner models is also given.

ISBN: 1-4200-6184-4
Pages: 732
Hardcopy: \$139.95


text:
# Tom Lehrer's Mathematical Songs

Tom Lehrer (born in Manhattan, New York in 1928) is an American singer, songwriter and entertainer. He trained as a mathematician, receiving his AB from Harvard in 1946 and being awarded a Master's degree in the following year. He then undertook mathematics research at Harvard but, at the same time, began to develop his musical career and also took some time out to work at the Los Alamos Scientific Laboratory. He had parallel careers as a musician and song-writer, and as an academic teaching mathematics as part of liberal arts courses first at the Massachusetts Institute of Technology and then, from 1972, at the University of California at Santa Cruz. He taught courses such as "The Nature of Mathematics" and "Infinity".

As a songwriter, Lehrer wrote satirical songs on many topics but, of course, some of his songs were on mathematics. Here are four of his Mathematical Songs.
1. There's A Delta For Every Epsilon (Calypso).

The words and music are by Tom Lehrer. The song appears in the American Mathematical Monthly 81 (1974), 612.

There's a delta for every epsilon,
It's a fact that you can always count upon.
There's a delta for every epsilon
And now and again,
There's also an $N$.

But one condition I must give:
The epsilon must be positive
A lonely life all the others live,
In no theorem (A delta for them.)

How sad, how cruel, how tragic,
Tives that I might mention.)
The matter merits our attention.
If an epsilon is a hero,
Just because it is greater than zero,
It must be mighty discouragin'
To lie to the left of the origin.

This rank discrimination is not for us,
We must fight for an enlightened calculus,
Where epsilons all, both minus and plus,
Have deltas
To call their own.
2. The Derivative Song.

Words by Tom Lehrer to the tune "There'll be Some Changes Made".The song appears in the American Mathematical Monthly 81 (1974), 490.

You take a function of $x$ and you call it $y$,
Take any $x$-nought that you care to try,
You make a little change and call it delta $x$,
The corresponding change in $y$ is what you find nex',
And then you take the quotient and now carefully
Send delta $x$ to zero, and I think you'll see
That what the limit gives us, if our work all checks,
Is what we call $dy/dx$,
It's just $dy/dx$.
3. The Professor's Song.

Words by Tom Lehrer to the tune "If You Give Me Your Attention" from Princess Ida by Gilbert and Sullivan. The song appears in the American Mathematical Monthly 81 (1974), 745.

If you give me your attention, I will tell you what I am.
I'm a brilliant math'matician - also something of a ham.
I have tried for numerous degrees, in fact I've one of each;
Of course that makes me eminently qualified to teach.
I understand the subject matter thoroughly, it's true,
And I can't see why it isn't all as obvious to you.
Each lecture is a masterpiece, meticulously planned,
Yet everybody tells me that I'm hard to understand,
And I can't think why.

My diagrams are models of true art, you must agree,
And my handwriting is famous for its legibility.
Take a word like "minimum" (to choose a random word),
For anyone to say he cannot read that, is absurd.
The anecdotes I tell get more amusing every year,
Though frankly, what they go to prove is sometimes less than clear,
And all my explanations are quite lucid, I am sure,
Yet everybody tells me that my lectures are obscure,
And I can't think why.

Consider, for example, just the force of gravity:
It's inversely proportional to something - let me see -
It's $r^{3}$ - no, $r^{2}$ - no, it's just $r$, I'll bet -
The sign in front is plus - or is it minus, I forget -
Well, anyway, there is a force, of that there is no doubt.
All these formulas are trivial if you only think them out.
Yet students tell me, "I have memorised the whole year through
(Ev'rything you've told us, but the problems I can't do."
And I can't think why!

[Note. When Tom Lehrer performs this song he writes on the blackboard

for the word "minimum".]
4. Lobachevsky
For many years now, Mr Danny Kaye, who has been my particular idol since childbirth, has been doing a routine about the great Russian director Stanislavsky and the secret of success in the acting profession. And I thought it would be interesting to stea... to adapt this idea to the field of mathematics. I always like to make explicit the fact that before I went off not too long ago to fight in the trenches, I was a mathematician by profession. I don't like people to get the idea that I have to do this for a living. I mean, it isn't as though I had to do this, you know, I could be making, oh, 3000 dollars a year just teaching.

Be that as it may, some of you may have had occasion to run into mathematicians and to wonder therefore how they got that way, and here, in partial explanation perhaps, is the story of the great Russian mathematician Nicolai Ivanovich Lobachevsky.

Who made me the genius I am today,
The mathematician that others all quote,
Who's the professor that made me that way?
The greatest that ever got chalk on his coat.

One man deserves the credit,
One man deserves the blame,
And Nicolai Ivanovich Lobachevsky is his name.
Hi!
Nicolai Ivanovich Lobach-

I am never forget the day I first meet the great Lobachevsky.
In one word he told me secret of success in mathematics:
Plagiarize!

Plagiarize,
But plagiarize, plagiarize, plagiarize -
Only be sure always to call it please 'research'.

And ever since I meet this man
My life is not the same,
And Nicolai Ivanovich Lobachevsky is his name.
Hi!
Nicolai Ivanovich Lobach-

I am never forget the day I am given first original paper
to write. It was on analytic and algebraic topology of
locally Euclidean parameterization of infinitely differentiable
Riemannian manifold.
Bozhe moi!
This I know from nothing.
What-i'm going-to do.
But I think of great Lobachevsky and get idea - ahah!

I have a friend in Minsk,
Who has a friend in Pinsk,
Whose friend in Omsk
Has friend in Tomsk
With friend in Akmolinsk.
His friend in Alexandrovsk
Has friend in Petropavlovsk,
Whose friend somehow
Is solving now
The problem in Dnepropetrovsk.

And when his work is done -
Ha ha! - begins the fun.
From Dnepropetrovsk
To Petropavlovsk,
By way of Iliysk,
And Novorossiysk,
To Alexandrovsk to Akmolinsk
To Tomsk to Omsk
To Pinsk to Minsk
To me the news will run,
Yes, to me the news will run!

And then I write
By morning, night,
And afternoon,
And pretty soon
My name in Dnepropetrovsk is cursed,
When he finds out I publish first!

And who made me a big success
And brought me wealth and fame?
Nicolai Ivanovich Lobachevsky is his name.
Hi!
Nicolai Ivanovich Lobach -

I am never forget the day my first book is published.
Every chapter I stole from somewhere else.
Index I copy from old Vladivostok telephone directory.
This book was sensational!
Pravda - well, Pravda - Pravda said: "Zhil-bil korol kogda-to, pree nyom blokha zhila"* It stinks.
But Izvestia! Izvestia said: "Ya idoo kuda sam czar idyot peshkom!"**
It stinks.
Metro-Goldwyn-Moskva buys movie rights for six million rubles,
Changing title to 'The Eternal Triangle',
With Ingrid Bergman playing part of hypotenuse.

And who deserves the credit?
And who deserves the blame?
Nicolai Ivanovich Lobachevsky is his name.
Hi!

* "a king lived once upon a time, a flea lived with him", a line from Goethe's "Faust" (as translated by A. Strugovschik)

** "I am going where even the king has to go on foot" (as opposed to riding, etc.), meaning "to the bathroom"

Last Updated October 2013


text:
# chain rule examples with solutions pdf

December 25, 2020 - Less than a minute read

Use the solutions intelligently. The best way to memorize this (along with the other rules) is just by practicing until you can do it without thinking about it. This package reviews the chain rule which enables us to calculate the derivatives of functions of functions, such as sin(x3), and also of powers of functions, such as (5x2 −3x)17. The more times you apply the chain rule to different problems, the easier it becomes to recognize how to apply the rule. 1.3 The Five Rules 1.3.1 The … D(y ) = 3 y 2. y '. We are nding the derivative of the logarithm of 1 x2; the of almost always means a chain rule. 5 0 obj If , where u is a differentiable function of x and n is a rational number, then Examples: Find the derivative of each function given below. Solution: This problem requires the chain rule. 2 1 0 1 2 y 2 10 1 2 x Figure 21: The hyperbola y − x2 = 1. �ʆ�f��7w������ٴ"L��,���Jڜ �X��0�mm�%�h�tc� m�p}��J�b�f�4Q��XXЛ�p0��迒1�A��� eܟN�{P������1��\XL�O5M�ܑw��q��)D0����a�\�R(y�2s�B� ���|0�e����'��V�?��꟒���d� a躆�i�2�6�J�=���2�iW;�Mf��B=�}T�G�Y�M�. 2. We illustrate with an example: 35.1.1 Example Find Z cos(x+ 1)dx: Solution We know a rule that comes close to working here, namely, R cosxdx= sinx+C, In examples such as the above one, with practise it should be possible for you to be able to simply write down the answer without having to let t = 1 + x² etc. The symbol dy dx is an abbreviation for ”the change in y (dy) FROM a change in x (dx)”; or the ”rise over the run”. 'ɗ�m����sq'�"d����a�n�����R��� S>��X����j��e�\�i'�9��hl�֊�˟o��[1dv�{� g�?�h��#H�����G��~�1�yӅOXx�. SOLUTION 6 : Differentiate . Example. u and the chain rule gives df dx = df du du dv dv dx = cosv 3u2=3 1 3x2=3 = cos 3 p x 9(xsin 3 p x)2=3: 11. As we apply the chain rule, we will always focus on figuring out what the “outside” and “inside” functions are first. Example 1 Find the rate of change of the area of a circle per second with respect to its … Example Diﬀerentiate ln(2x3 +5x2 −3). Now apply the product rule. Solution: Using the table above and the Chain Rule. Solution (a) This part of the example proceeds as follows: p = kT V, ∴ ∂p ∂T = k V, where V is treated as a constant for this calculation. 6 f ' x = 56 2x - 7 1. f x 4 2x 7 2. f x 39x 4 3. f x 3x 2 7 x 2 4. f x 4 x 5x 7 f ' x = 4 5 5 -108 9x - This video gives the definitions of the hyperbolic functions, a rough graph of three of the hyperbolic functions: y = sinh x, y = … 2 1 0 1 2 y 2 10 1 2 x Figure 21: The hyperbola y − x2 = 1. ��#�� 13) Give a function that requires three applications of the chain rule to differentiate. The chain rule and implicit differentiation are techniques used to easily differentiate otherwise difficult equations. Hyperbolic Functions And Their Derivatives. Then . The Chain Rule for Powers The chain rule for powers tells us how to diﬀerentiate a function raised to a power. Usually what follows Make use of it. Chain Rule Worksheets with Answers admin October 1, 2019 Some of the Worksheets below are Chain Rule Worksheets with Answers, usage of the chain rule to obtain the derivatives of functions, several interesting chain rule exercises with step by step solutions and quizzes with answers, … Section 3-9 : Chain Rule. SOLUTION 20 : Assume that , where f is a differentiable function. Definition •In calculus, the chain rule is a formula for computing the derivative of the composition of two or more functions. Take d dx of both sides of the equation. Example: Chain rule for f(x,y) when y is a function of x The heading says it all: we want to know how f(x,y)changeswhenx and y change but there is really only one independent variable, say x,andy is a function of x. �x$�V �L�@na%�'�3� 0 �0S endstream endobj startxref 0 %%EOF 151 0 obj <>stream BNAT; Classes. Revision of the chain rule We revise the chain rule by means of an example. This diagram can be expanded for functions of more than one variable, as we shall see very shortly. To differentiate this we write u = (x3 + 2), so that y = u2 For problems 1 – 27 differentiate the given function. y = x3 + 2 is a function of x y = (x3 + 2)2 is a function (the square) of the function (x3 + 2) of x. (b) For this part, T is treated as a constant. About this resource. The following figure gives the Chain Rule that is used to find the derivative of composite functions. 57 0 obj <> endobj 85 0 obj <>/Filter/FlateDecode/ID[<01EE306CED8D4CF6AAF868D0BD1190D2>]/Index[57 95]/Info 56 0 R/Length 124/Prev 95892/Root 58 0 R/Size 152/Type/XRef/W[1 2 1]>>stream Title: Calculus: Differentiation using the chain rule. Now apply the product rule twice. dy dx + y 2. The chain rule provides a method for replacing a complicated integral by a simpler integral. Example 3 Find ∂z ∂x for each of the following functions. Work through some of the examples in your textbook, and compare your solution to the detailed solution o ered by the textbook. Updated: Mar 23, 2017. doc, 23 KB. Then (This is an acceptable answer. The rules of di erentiation are straightforward, but knowing when to use them and in what order takes practice. The method is called integration by substitution (\integration" is the act of nding an integral). Study the examples in your lecture notes in detail. Click HERE to return to the list of problems. The Chain Rule (Implicit Function Rule) • If y is a function of v, and v is a function of x, then y is a function of x and dx dv. Both use the rules for derivatives by applying them in slightly different ways to differentiate the complex equations without much hassle. Ask yourself, why they were o ered by the instructor. [��IX��I� ˲ H|�d��[z����p+G�K��d�:���j:%��U>����nm���H:�D�}�i��d86c��b���l��J��jO[�y�Р�"?L��{.����C�f It’s no coincidence that this is exactly the integral we computed in (8.1.1), we have simply renamed the variable u to make the calculations less confusing. We must identify the functions g and h which we compose to get log(1 x2). Chain Rule Examples (both methods) doc, 170 KB. 2.Write y0= dy dx and solve for y 0. Show Solution. Example Find d dx (e x3+2). Hint : Recall that with Chain Rule problems you need to identify the “inside” and “outside” functions and then apply the chain rule. Click HERE to return to the list of problems. Example: Find the derivative of . The Chain Rule is a formula for computing the derivative of the composition of two or more functions. du dx Chain-Log Rule Ex3a. From there, it is just about going along with the formula. dv dy dx dy = 17 Examples i) y = (ax2 + bx)½ let v = (ax2 + bx) , so y = v½ ()ax bx . (medium) Suppose the derivative of lnx exists. This rule is obtained from the chain rule by choosing u … Section 1: Basic Results 3 1. The following chain rule examples show you how to differentiate (find the derivative of) many functions that have an “ inner function ” and an “ outer function.” For an example, take the function y = √ (x 2 – 3). Solution. !w�@�����Bab��JIDу>�Y"�Ĉ2FP;=�E���Y��Ɯ��M��3f�+o��DLp�[BEGG���#�=a���G�f�l��ODK�����oDǟp&�)�8>ø�%�:�>����e �i":���&�_�J�\�|�h���xH�=���e"}�,*�����N8l��y���:ZY�S�b{�齖|�3[�Zk���U�6H��h��%�T68N���o��� A function of a … Example 1: Assume that y is a function of x . This might … Show Solution For this problem the outside function is (hopefully) clearly the exponent of 4 on the parenthesis while the inside function is the polynomial that is being raised to the power. A simple technique for diﬀerentiating directly 5 www.mathcentre.ac.uk 1 c mathcentre 2009. After having gone through the stuff given above, we hope that the students would have understood, "Chain Rule Examples With Solutions"Apart from the stuff given in "Chain Rule Examples With Solutions", if you need any other stuff in math, please use our google custom search here. In Leibniz notation, if y = f (u) and u = g (x) are both differentiable functions, then Note: In the Chain Rule, we work from the outside to the inside. The outer layer of this function is the third power'' and the inner layer is f(x) . d dx (e3x2)= deu dx where u =3x2 = deu du × du dx by the chain rule = eu × du dx = e3x2 × d dx (3x2) =6xe3x2. Use u-substitution. stream We always appreciate your feedback. Chain Rule Examples (both methods) doc, 170 KB. if x f t= ( ) and y g t= ( ), then by Chain Rule dy dx = dy dx dt dt, if 0 dx dt ≠ Chapter 6 APPLICATION OF DERIVATIVES APPLICATION OF DERIVATIVES 195 Thus, the rate of change of y with respect to x can be calculated using the rate of change of y and that of x both with respect to t. Let us consider some examples. differentiate and to use the Chain Rule or the Power Rule for Functions. Substitute into the original problem, replacing all forms of , getting . Implicit Diﬀerentiation and the Chain Rule The chain rule tells us that: d df dg (f g) = . √ √Let √ inside outside For instance, (x 2 + 1) 7 is comprised of the inner function x 2 + 1 inside the outer function (⋯) 7. If , where u is a differentiable function of x and n is a rational number, then Examples: Find the derivative of … Differentiate algebraic and trigonometric equations, rate of change, stationary points, nature, curve sketching, and equation of tangent in Higher Maths. Now we’re almost there: since u = 1−x2, x2 = 1− u and the integral is Z − 1 2 (1−u) √ udu. In applying the Chain Rule, think of the opposite function f °g as having an inside and an outside part: General Power Rule a special case of the Chain Rule. The chain rule for functions of more than one variable involves the partial derivatives with respect to all the independent variables. The random transposition Markov chain on the permutation group SN (the set of all permutations of N cards) is a Markov chain whose transition probabilities are p(x,˙x)=1= N 2 for all transpositions ˙; p(x,y)=0 otherwise. The Total Derivative Recall, from calculus I, that if f : R → R is a function then f ′(a) = lim h→0 f(a+h) −f(a) h. We can rewrite this as lim h→0 f(a+h)− f(a)− f′(a)h h = 0. Solution Again, we use our knowledge of the derivative of ex together with the chain rule. Let f(x)=6x+3 and g(x)=−2x+5. Step 1. Created: Dec 4, 2011. For instance, if f and g are functions, then the chain rule expresses the derivative of their composition. Notice that there are exactly N 2 transpositions. If and , determine an equation of the line tangent to the graph of h at x=0 . Written this way we could then say that f is diﬀerentiable at a if there is a number λ ∈ R such that lim h→0 f(a+h)− f(a)−λh h = 0. Hint : Recall that with Chain Rule problems you need to identify the “inside” and “outside” functions and then apply the chain rule. Examples using the chain rule. For example, in Leibniz notation the chain rule is dy dx = dy dt dt dx. dx dy dx Why can we treat y as a function of x in this way? BOOK FREE CLASS; COMPETITIVE EXAMS. h�bbdb^$��7 H0���D�S�|@�#���j@��Ě"� �� �H���@�s!H��P�$D��W0��] In this presentation, both the chain rule and implicit differentiation will To avoid using the chain rule, recall the trigonometry identity , and first rewrite the problem as . Some examples involving trigonometric functions 4 5. x + dx dy dx dv. The Chain Rule for Powers 4. There is also another notation which can be easier to work with when using the Chain Rule. Solution This is an application of the chain rule together with our knowledge of the derivative of ex. For this equation, a = 3;b = 1, and c = 8. Using the linear properties of the derivative, the chain rule and the double angle formula , we obtain: {y’\left( x \right) }={ {\left( {\cos 2x – 2\sin x} \right)^\prime } } , or . Example: a) Find dy dx by implicit di erentiation given that x2 + y2 = 25. That is, if f is a function and g is a function, then the chain rule expresses the derivative of the composite function f ∘ g in terms of the derivatives of f and g. Definition •If g is differentiable at x and f is differentiable at g(x), … The following examples demonstrate how to solve these equations with TI-Nspire CAS when x >0. H��TMo�0��W�h'��r�zȒl�8X����+NҸk�!"�O�|��Q�����&�ʨ���C�%�BR��Q��z;�^_ڨ! We ﬁrst explain what is meant by this term and then learn about the Chain Rule which is the technique used to perform the diﬀerentiation. If and , determine an equation of the line tangent to the graph of h at x=0 . 4 Examples 4.1 Example 1 Solve the differential equation 3x2y00+xy0 8y=0. Write the solutions by plugging the roots in the solution form. Does your textbook come with a review section for each chapter or grouping of chapters? A good way to detect the chain rule is to read the problem aloud. Tree diagrams are useful for deriving formulas for the chain rule for functions of more than one variable, where each independent variable also depends on other variables. The inner function is the one inside the parentheses: x 2 -3. A good way to detect the chain rule is to read the problem aloud. ()ax b dx dy = + + − 2 2 1 2 1 2 ii) y = (4x3 + 3x – 7 )4 let v = (4x3 + 3x – 7 ), so y = v4 4()(4 3 7 12 2 3) = x3 + x − 3 . Multi-variable Taylor Expansions 7 1. dv dy dx dy = 18 8. The outer layer of this function is the third power'' and the inner layer is f(x) . To avoid using the chain rule, recall the trigonometry identity , and first rewrite the problem as . "���;U�U���{z./iC��p����~g�~}��o��͋��~���y}���A���z᠄U�o���ix8|���7������L��?߼8|~�!� ���5���n�J_��.��w/n�x��t��c����VΫ�/Nb��h����AZ��o�ga���O�Vy|K_J���LOO�\hỿ��:bچ1���ӭ�����[=X�|����5R�����4nܶ3����4�������t+u����! A transposition is a permutation that exchanges two cards. Even though we had to evaluate f′ at g(x)=−2x+5, that didn't make a difference since f′=6 not matter what its input is. The chain rule gives us that the derivative of h is . Target: On completion of this worksheet you should be able to use the chain rule to differentiate functions of a function. {�F?р��F���㸝.�7�FS������V��zΑm���%a=;^�K��v_6���ft�8CR�,�vy>5d륜��UG�/��A�FR0ם�'�,u#K �B7~���1&��|��J�ꉤZ���GV�q��T��{����70"cU�������1j�V_U('u�k��ZT. functionofafunction. %PDF-1.4 Differentiation Using the Chain Rule. •Prove the chain rule •Learn how to use it •Do example problems . Solution 4: Here we have a composition of three functions and while there is a version of the Chain Rule that will deal with this situation, it can be easier to just use the ordinary Chain Rule twice, and that is what we will do here. Section 2: The Rules of Partial Diﬀerentiation 6 2. Derivative Rules - Constant Rule, Constant Multiple Rule, Power Rule, Sum Rule, Difference Rule, Product Rule, Quotient Rule, Chain Rule, Exponential Functions, Logarithmic Functions, Trigonometric Functions, Inverse Trigonometric Functions, Hyperbolic Functions and Inverse Hyperbolic Functions, with video lessons, examples and step-by-step solutions. The chain rule 2 4. 1. Chain Rule Formula, chain rule, chain rule of differentiation, chain rule formula, chain rule in differentiation, chain rule problems. Chain rule. … Find the derivative of y = 6e7x+22 Answer: y0= 42e7x+22 Then . For functions f and g d dx [f(g(x))] = f0(g(x)) g0(x): In the composition f(g(x)), we call f the outside function and g the inside function. Scroll down the page for more examples and solutions. dx dy dx Why can we treat y as a function of x in this way? If f(x) = g(h(x)) then f0(x) = g0(h(x))h0(x). dx dg dx While implicitly diﬀerentiating an expression like x + y2 we use the chain rule as follows: d (y 2 ) = d(y2) dy = 2yy . Example Suppose we wish to diﬀerentiate y = (5+2x)10 in order to calculate dy dx. doc, 90 KB. For this problem the outside function is (hopefully) clearly the exponent of 4 on the parenthesis while the inside function is the polynomial that is being raised to the power. In examples such as the above one, with practise it should be possible for you to be able to simply write down the answer without having to let t = 1 + x² etc. Click HERE to return to the list of problems. Chain rule examples: Exponential Functions. This section shows how to differentiate the function y = 3x + 1 2 using the chain rule. /� �؈L@'ͱ݌�z���X�0�d\�R��9����y~c Solution: Step 1 d dx x2 + y2 d dx 25 d dx x2 + d dx y2 = 0 Use: d dx y2 = d dx f(x) 2 = 2f(x) f0(x) = 2y y0 2x + 2y y0= 0 Step 2 Basic Results Diﬀerentiation is a very powerful mathematical tool. NCERT Books for Class 5; NCERT Books Class 6; NCERT Books for Class 7; NCERT Books for Class 8; NCERT Books for Class 9; NCERT Books for Class 10; NCERT Books for Class 11; NCERT … In other words, the slope. We must identify the functions g and h which we compose to get log(1 x2). If 30 men can build a wall 56 meters long in 5 days, what length of a similar wall can be built by 40 … It is convenient … In fact we have already found the derivative of g(x) = sin(x2) in Example 1, so we can reuse that result here. Differentiation Using the Chain Rule. If our function f(x) = (g◦h)(x), where g and h are simpler functions, then the Chain Rule may be stated as f′(x) = (g◦h) (x) = (g′◦h)(x)h′(x). %PDF-1.4 %���� d dx (ex3+2x)= deu dx (where u = x3 +2x) = eu × du dx (by the chain rule) = ex3+2x × d dx (x3 +2x) =(3x2 +2)×ex3+2x. <> Scroll down the page for more examples and solutions. 2. Then if such a number λ exists we deﬁne f′(a) = λ. Ok, so what’s the chain rule? Thus p = kT 1 V = kTV−1, ∴ ∂p ∂V = −kTV−2 = − kT V2. Solution: Using the above table and the Chain Rule. To avoid using the chain rule, first rewrite the problem as . Usually what follows Differentiating using the chain rule usually involves a little intuition. To avoid using the chain rule, first rewrite the problem as . There is a separate unit which covers this particular rule thoroughly, although we will revise it brieﬂy here. The Chain Rule 4 3. Solution: This problem requires the chain rule. Example Find d dx (e x3+2). To write the indicial equation, use the TI-Nspire CAS constraint operator to substitute the values of the constants in the symbolic … For example, all have just x as the argument. In applying the Chain Rule, think of the opposite function f °g as having an inside and an outside part: General Power Rule a special case of the Chain Rule. We are nding the derivative of the logarithm of 1 x2; the of almost always means a chain rule. For the matrices that are stochastic matrices, draw the associated Markov Chain and obtain the steady state probabilities (if they exist, if How to use the Chain Rule. %�쏢 dx dg dx While implicitly diﬀerentiating an expression like x + y2 we use the chain rule as follows: d (y 2 ) = d(y2) dy = 2yy . The same is true of our current expression: Z x2 −2 √ u du dx dx = Z x2 −2 √ udu. Solution. Introduction In this unit we learn how to diﬀerentiate a ‘function of a function’. The Rules of Partial Diﬀerentiation Since partial diﬀerentiation is essentially the same as ordinary diﬀer-entiation, the product, quotient and chain rules may be applied. rule d y d x = d y d u d u d x ecomes Rule) d d x f ( g ( x = f 0 ( g ( x )) g 0 ( x ) \outer" function times of function. by the Chain Rule, dy/dx = dy/dt × dt/dx so dy/dx = 3t² × 2x = 3(1 + x²)² × 2x = 6x(1 + x²)². Solution: The derivatives of f and g aref′(x)=6g′(x)=−2.According to the chain rule, h′(x)=f′(g(x))g′(x)=f′(−2x+5)(−2)=6(−2)=−12. View Notes - Introduction to Chain Rule Solutions.pdf from MAT 122 at Phoenix College. SOLUTION 6 : Differentiate . by the Chain Rule, dy/dx = dy/dt × dt/dx so dy/dx = 3t² × 2x = 3(1 + x²)² × 2x = 6x(1 + x²)². Let so that (Don't forget to use the chain rule when differentiating .) General Procedure 1. Use the chain rule to calculate h′(x), where h(x)=f(g(x)). Now apply the product rule. If you have any feedback about our math content, please mail us : v4formath@gmail.com. Moveover, in this case, if we calculate h(x),h(x)=f(g(x))=f(−2x+5)=6(−2x+5)+3=−12x+30+3=−12… (b) We need to use the product rule and the Chain Rule: d dx (x 3 y 2) = x 3. d dx (y 2) + y 2. d dx (x 3) = x 3 2y. Class 1 - 3; Class 4 - 5; Class 6 - 10; Class 11 - 12; CBSE. The chain rule is probably the trickiest among the advanced derivative rules, but it’s really not that bad if you focus clearly on what’s going on. has solution: 8 >> >< >> >: ˇ R = 53 1241 ˇ A = 326 1241 ˇ P = 367 1241 ˇ D = 495 1241 2.Consider the following matrices. After having gone through the stuff given above, we hope that the students would have understood, "Chain Rule Examples With Solutions" Apart from the stuff given in "Chain Rule Examples With Solutions", if you need any other stuff in math, please use our google custom search here. Info. The outer function is √ (x). The difficulty in using the chain rule: Implementing the chain rule is usually not difficult. SOLUTION 9 : Integrate . Let Then 2. Although the chain rule is no more com-plicated than the rest, it’s easier to misunderstand it, and it takes care to determine whether the chain rule or the product rule is needed. Solution Again, we use our knowledge of the derivative of ex together with the chain rule. The chain rule gives us that the derivative of h is . Now apply the product rule twice. You must use the Chain rule to find the derivative of any function that is comprised of one function inside of another function. (a) z … Then (This is an acceptable answer. Solution: d d x sin( x 2 os( x 2) d d x x 2 =2 x cos( x 2). The problem that many students have trouble with is trying to figure out which parts of the function are within other functions (i.e., in the above example, which part if g(x) and which part is h(x). If f(x) = g(h(x)) then f0(x) = g0(h(x))h0(x). Find it using the chain rule. For example: 1 y = x2 2 y =3 √ x =3x1/2 3 y = ax+bx2 +c (2) Each equation is illustrated in Figure 1. y y y x x Y = x2 Y = x1/2 Y = ax2 + bx Figure 1: 1.2 The Derivative Given the general function y = f(x) the derivative of y is denoted as dy dx = f0(x)(=y0) 1. Show all files. Calculate (a) D(y 3), (b) d dx (x 3 y 2), and (c) (sin(y) )' Solution: (a) We need the Power Rule for Functions since y is a function of x: D(y 3) = 3 y 2. Implicit Diﬀerentiation and the Chain Rule The chain rule tells us that: d df dg (f g) = . Example: Differentiate . This is called a tree diagram for the chain rule for functions of one variable and it provides a way to remember the formula (Figure $$\PageIndex{1}$$). 3x 2 = 2x 3 y. dy … As another example, e sin x is comprised of the inner function sin 2.5 The Chain Rule Brian E. Veitch 2.5 The Chain Rule This is our last di erentiation rule for this course. The Inverse Function Rule • Examples If x = f(y) then dy dx dx dy 1 = i) … This 105. is captured by the third of the four branch diagrams on the previous page. Then differentiate the function. Many answers: Ex y = (((2x + 1)5 + 2) 6 + 3) 7 dy dx = 7(((2x + 1)5 + 2) 6 + 3) 6 ⋅ 6((2x + 1)5 + 2) 5 ⋅ 5(2x + 1)4 ⋅ 2-2-Create your own worksheets like this … The derivative is then, \[f'\left( x \right) = 4{\left( {6{x^2} + 7x} \right)^3}\left( … NCERT Books. Learn its definition, formulas, product rule, chain rule and examples at BYJU'S. Just as before: … It states: if y = (f(x))n, then dy dx = nf0(x)(f(x))n−1 where f0(x) is the derivative of f(x) with respect to x. 1. It is often useful to create a visual representation of Equation for the chain rule. The rule is given without any proof. Since the functions were linear, this example was trivial. Example: Find d d x sin( x 2). Most of the basic derivative rules have a plain old x as the argument (or input variable) of the function. SOLUTION 20 : Assume that , where f is a differentiable function. When the argument of a function is anything other than a plain old x, such as y = sin (x 2) or ln10 x (as opposed to ln x), you’ve … h�bf��������A��b�,;>���1Y���������Z�b��k���V���Y��4bk�t�n W�h���}b�D���I5����mM꺫�g-��w�Z�l�5��G�t� ��t�c�:��bY��0�10H+$8�e�����˦0]��#��%llRG�.�,��1��/]�K�ŝ�X7@�&��X�����  %�bl endstream endobj 58 0 obj <> endobj 59 0 obj <> endobj 60 0 obj <>stream In this unit we will refer to it as the chain rule. Hyperbolic Functions - The Basics. SOLUTION 8 : Integrate . x��\Y��uN^����y�L�۪}1�-A�Al_�v S�D�u). It’s also one of the most used. Section 1: Partial Diﬀerentiation (Introduction) 5 The symbol ∂ is used whenever a function with more than one variable is being diﬀerentiated but the techniques of partial … Section 3: The Chain Rule for Powers 8 3. Final Quiz Solutions to Exercises Solutions to Quizzes. Find the derivative of $$f(x) = (3x + 1)^5$$. Example 2. For example, they can help you get started on an exercise, or they can allow you to check whether your intermediate results are correct Try to make less use of the full solutions as you work your way ... using the chain rule, and dv dx = (x+1) Method is called integration by substitution ( \integration '' is the one inside the parentheses: x 2.... Determine an equation of the logarithm of 1 x2 ; the of almost always means a chain that! Three applications of the derivative of h at x=0 that, where f is a function of x in way. You have any feedback about our math content, please mail us: v4formath @.. Is an application of the following Figure gives the chain rule is usually not difficult Figure 21: the y! Y0= dy dx Why can we treat y as a constant is comprised of one function of! A number λ exists we deﬁne f′ ( a ) Z … the difficulty in the! Thus p = kT 1 V = kTV−1, ∴ ∂p ∂V = −kTV−2 = kT! Is comprised of one function inside of another function easily differentiate otherwise equations... If and, determine an equation of the derivative of their composition our. Here to return to the list of problems 3: the chain rule is to read the problem.! Section shows how to differentiate the function y = 3x + 1 ) ^5\ ) both use the rules derivatives! As before: … the following functions is captured by the instructor are used! ( medium ) Suppose the derivative of the derivative of composite functions just x as the argument! � . An application of the line tangent to the graph of h at x=0 of lnx exists rule gives that. With TI-Nspire CAS when x > 0 for computing the derivative of ex for problems –. 2 y 2 10 1 2 y 2 10 1 2 using the rule! One function inside of another function separate unit which covers this particular rule thoroughly, although we will refer it... Notes in detail return to the detailed solution o ered by the instructor to a power some of derivative... Definition, formulas, product rule, recall the trigonometry identity, and c = 8 linear this! Section 3: the hyperbola y − x2 = 1, and rewrite... 10 ; Class 11 - 12 ; CBSE, the easier it becomes to recognize how diﬀerentiate. We revise the chain rule the detailed solution o ered by the instructor raised to a power x in unit... ) Z … the difficulty in using the table above and the layer! Is a function ’ problems, the chain rule: Implementing the chain rule by means of example. Is called integration by substitution ( \integration '' is the one inside the parentheses: x )... Example 1: Assume that, where f is a differentiable function x Figure 21: the y! At x=0 more functions work through some of the derivative of the of! Technique for diﬀerentiating directly 5 www.mathcentre.ac.uk 1 c mathcentre 2009 d dx of both sides of the chain rule examples with solutions pdf! Which we compose to get log ( 1 x2 ) find d d x sin ( x ) ),! Ered by the instructor: the hyperbola y − x2 = 1, and compare your solution to graph... Or more functions, first rewrite the problem as [ =X�|����5R�����4nܶ3����4�������t+u���� simpler.!: bچ1���ӭ����� [ =X�|����5R�����4nܶ3����4�������t+u���� solution 20: Assume that y is a permutation exchanges. Dx and solve for y 0 of di erentiation rule for functions dx dy dx Why can we treat as. The examples in your lecture notes in detail table and the chain rule usually involves little. Textbook come with a review section for each of the function y = 3x... We use our knowledge of the basic derivative rules have a plain old as! Solve for y 0 x2 ) and compare your solution to the graph of h at.! 4 examples 4.1 example 1: Assume that, where f is a separate unit which covers this rule... X2 ).��w/n�x��t��c����VΫ�/Nb��h����AZ��o�ga���O�Vy|K_J���LOO�\hỿ��: bچ1���ӭ����� [ =X�|����5R�����4nܶ3����4�������t+u����, where h ( x ), where h ( x.... Expanded for functions of a function ’ the easier it becomes to how! Before: … the following functions Z x2 −2 √ u du dx dx = x2... When to use the rules for derivatives by applying them in slightly ways! Any function that requires three applications of the four branch diagrams On the previous page revise. G and h which we compose to get log ( 1 x2 ) for each or! That requires three applications of the line tangent to the graph of h at x=0 basic derivative rules have plain! Then the chain rule when differentiating. 105. is captured by the.... Tangent to the detailed solution o ered by the instructor introduction in this unit we will it... Example 1: Assume that y is a separate unit which covers this particular rule thoroughly, although will. − kT V2 section 3: the hyperbola y − x2 = 1 df dg ( (! Of the logarithm of 1 x2 ) y0= dy dx Why can we treat y a. 23 KB this equation, a = 3 ; Class 6 - 10 Class... Ok, so what ’ s also one of the logarithm of 1 x2 ) our math content, mail! We treat y as a function raised to a power inside of function! Is a differentiable function Suppose we wish to diﬀerentiate a ‘ function of x the page for more examples solutions. The textbook '' and the chain rule of differentiation, chain rule examples ( methods... U�U��� { z./iC��p����~g�~ } ��o��͋��~���y } ���A���z᠄U�o���ix8|���7������L��? ߼8|~�! � ���5���n�J_�� .��w/n�x��t��c����VΫ�/Nb��h����AZ��o�ga���O�Vy|K_J���LOO�\hỿ��: bچ1���ӭ����� [ =X�|����5R�����4nܶ3����4�������t+u���� a... Easily differentiate otherwise difficult equations involves a little intuition differentiate otherwise difficult.! Refer to it as the argument ( or input variable ) of the function y = 3x + 2! We deﬁne f′ ( a ) = 3 y 2. y ' first rewrite the aloud... Exists we deﬁne f′ ( a ) = ( 3x + 1 2 using the chain rule for 8. Linear, this example was trivial if and, determine an equation the. Class 4 - 5 ; Class 6 - 10 ; Class 11 - 12 ; CBSE an equation of following... Problems, the easier it becomes to recognize how to differentiate functions more!? �h�� # H�����G��~�1�yӅOXx� previous page in what order takes practice for diﬀerentiating directly 5 www.mathcentre.ac.uk 1 c 2009... 6 - 10 ; Class 4 - 5 ; Class 11 - 12 CBSE! Any function that requires three applications of the examples in your textbook with. ) ^5\ ) di erentiation rule for Powers 8 3 to apply the rule! We learn how to use the chain rule gives us that: d df dg ( f ( ). What follows to avoid using the chain rule Solutions.pdf from MAT 122 at Phoenix College exists we deﬁne (... To calculate h′ ( x ) ) ���5���n�J_�� .��w/n�x��t��c����VΫ�/Nb��h����AZ��o�ga���O�Vy|K_J���LOO�\hỿ��: bچ1���ӭ����� [ =X�|����5R�����4nܶ3����4�������t+u���� computing the derivative ex..., this example was trivial tells us that: d df dg ( (..., the easier it becomes to recognize how to apply the chain rule is to read the as... Of problems to different problems, the easier it becomes to recognize to. Work with when using the chain rule: Implementing the chain rule •Learn how to a... For each chapter or grouping of chapters just as before: … the difficulty in using the chain to. Revision of the examples in your lecture notes in detail rule, first the. Example was trivial previous page, where h ( x ) = λ by (! G are functions, then the chain rule to differentiate the complex equations without much hassle h. Logarithm of 1 x2 ) all forms of, getting = kT V. ( g ( x ) ) compare your solution to the detailed o. ) Suppose the derivative of ex rewrite the problem aloud table above and the inner function is the... Expanded for functions U�U��� { z./iC��p����~g�~ } ��o��͋��~���y } ���A���z᠄U�o���ix8|���7������L��? ߼8|~�! � ���5���n�J_�� .��w/n�x��t��c����VΫ�/Nb��h����AZ��o�ga���O�Vy|K_J���LOO�\hỿ��: bچ1���ӭ����� =X�|����5R�����4nܶ3����4�������t+u����! Covers this particular rule thoroughly, although we will revise it brieﬂy HERE )... Most used ‘ function of a function that is used to easily differentiate otherwise difficult.. Examples 4.1 example 1: Assume that y is a permutation that exchanges two.... Branch diagrams On the previous page a chain rule, chain rule, chain.... 1 x2 ) 0 1 2 y 2 10 1 2 y 2 1. X sin ( x ), where h ( x ) =f ( g ( x ), where is. Derivative rules have a plain old x as the chain rule in differentiation, chain the. Solution Again, we use our knowledge of the logarithm of 1 x2 ) are nding chain rule examples with solutions pdf derivative of at. T is treated as a function of x in this way was trivial 0 1 2 x Figure:! Is f ( x ) =f ( g ( x 2 -3 g ( x =f! The line tangent to the list of problems rewrite the problem aloud function of... How to diﬀerentiate a ‘ function of x in this way of our current expression: Z x2 −2 u! In order to calculate dy dx and solve for y 0 transposition is a function that three. Rule to different problems, the easier it becomes to recognize how to the. Above and the inner layer is f ( x ), where h ( x ) = 3 b... Hyperbola y − x2 = 1, and first rewrite the problem aloud x2 = 1 1 and. Expresses the derivative of h is have any feedback about our math content, please us!


text:
# How do I contiguously store and iterate over ECS components in C++?

I'm writing an entity component system and want to store each type of component separately and contiguously in memory in a way that's easy to iterate over.

Component is a simple base class from which like classes like MoveComponent derive.

I store components inside the World class:

struct World {
...
std::vector<Component> components;
};

This would work fine if there was only one type of component, just a Component class. The problem is I don't know how to handle component subclasses. For example every MoveComponent should be stored contiguously in memory in a way that I can easily iterate over and process them.

I want to avoid this kind of copy-paste junk code for hopefully obvious reasons:

struct World {
...
std::vector<MoveComponent> move_components;
std::vector<PhysicsComponent> physics_components;
etc.
};

I'd like to instead structure it in a way that permits iterating over each component of a certain type in a World like, for example, this (inspired by Overwatch's entity component system video, see here):

for (MoveComponent *mc : ComponentIterator<MoveComponent>(world)) { ... }

I'm at a loss as to how to implement this.

• Did you check how EnTT does it? – Vaillancourt Apr 3 at 3:18
• I recommend avoiding Blizzard's presentations, they often oversell their achievements while also being shallow on technical details. For example, you are not supposed to iterate over single component; rather, system is supposed to iterate over the set of multiple components. – Shadows In Rain Apr 3 at 4:53

Entity component systems store data in one of three ways:

1. Centrally allocated arrays, accessable by all systems.
2. Contigious arrays of subsets of components that each system is interested in.
3. Contigious array of "entities" allocated in a centrally located memory buffer.

Naughty Dog uses scenario 1. An entity in this context is just a collection of numbers:

struct Entity
{
static const int FOO = 0;
static const int BAR = 1;
int components[MAX_COMPONENTS];
uint32_t id;
};

The "components" in the above code are either "-1" meaning "no component of this type, or a positive number, zero inclusive. This is an index to a centrally stored array of each set of components:

class ComponentAllocator
{
public:
FooComponent foo_components[MAX_FOO_COUNT];
BarComponent bar_components[MAX_BAR_COUNT];
};

Then any system can use some singleton/service locator pattern to get access to it, and iterate over it:

void FooBarSystem::update()
{
for (auto& entity: entities) //entities is just a collection of type Entity
{
Foo& foo = getComponentAllocator().foo_components[entity.components[FOO]];
Bar& bar = getComponentAllocator().bar_components[entity.components[BAR]];
// Do something that requires interaction between foo and bar.
// ...
}
}

In scenario 2, your entity is the storage for each set of components, and each system stores a collection of proxies to that entity.

class Entity
{
public:
std::map<std::type_index, std::shared_ptr<IComponent>> m_Components;
uint32_t id;


text:
# TAVLTree

Implemented in the FCL unit avl_tree. This is the predecessor of TAvgLvlTree.

# TAvgLvlTree

Where to get: Unit AvgLvlTree of Lazarus package LazUtils of the Lazarus sources.

The AVL trees - Average Level Trees are sorted self balancing binary trees. Similar to a list like TPFList a TAvgLvlTree can store arbitrary data (Pointer), but contrary to TFPList the tree is always sorted and balanced. Therefore searching is very fast. Features:

• You can define your own compare function or method.
• Searching an item or key takes O(log(n))
• Inserting an item takes O(log(n))
• Deleting an item takes O(log(n))
• Finding the lowest or highest item takes log(n)
• Finding the sucessor or predecessor item takes O(log(n))
• Iterating through all items in order takes O(n)
• Enumerators for running from lowest to highest and highest to lowest
• Supports duplicates
• Keeps duplicates order stable.
• It is not thread safe, but it does not use any global variables. So it can be used in threads just like TFPList.

## Creating a tree

By default the tree is sorted for the pointers. That means similar to TFPList you can add any pointers or objects:

uses AvgLvlTree; // in package lazutils

Tree:=TAvgLvlTree.Cteate;
...
// If you want to know if an item is already in the tree use Find:
if Tree.Find(AnObject1)<>nil then
writeln('AnObject is in the tree');
...
// To remove an item from the tree use:
Tree.Remove(AnObject1);

To create a tree for your custom data you only need a compare function. The following example demonstrates how to sort TMyData objects via their Filenames:

uses AvgLvlTree; // in package lazutils
type
TMyData = class
public
Filename: string;
Content: string;
end;

function CompareMyData(Data1, Data2: Pointer): integer;
begin
Result:=CompareFilenames(TMyData(d1).Filename,TMyData(d2).Filename);
end;

...
var
MyData1: TMyData;
Tree: TAvgLvlTree;
begin
Tree:=TAvgLvlTree.Create(@CompareMyData);

MyData1:=TMyData.Create;
MyData1.Filename:='SomeFile';
end;

## Enumerating all items of a tree

### Enumerate from lowest to highest

var
MyData: TMyData;
begin
for Node in Tree do begin
MyData:=TMyData(Node.Data);
writeln(MyData.Filename);
end;
end;

Notes:

• You can insert new nodes while enumerating with this enumerator.
• You must not delete the Node, nor change the Node.Data using this enumerator.

### Enumerate from highest to lowest

var
MyData: TMyData;
begin
for Node in Tree.GetEnumeratorHighToLow do begin
MyData:=TMyData(Node.Data);
writeln(MyData.Filename);
end;
end;

### Delete all nodes that fits a condition

If you need full control over the enumeration you can use Node.Sucessor and Node.Precessor. Here is an example how to delete all nodes that fits a filter:

var
Node: TAvgLvlTreeNode;
begin
Node:=Tree.FindLowest;
while Node<>nil do begin
NextNode:=Node.Successor;
if TMyData(Node.Data).Flag=true then
Tree.Delete(Node); // Note: this frees the Node, not the Node.Data. Use Tree.FreeAndDelete(Node) to free the Data.
Node:=NextNode;
end;
end;

Note:

• TMyData.Flag is just an example property. You can check whatever you want.

## Searching items

You can search an item with the same key:

var
Node: TAvgLvlTreeNode;
begin
MyData.Filename:='test';
Node:=Tree.Find(MyData); // finds a node with a Filename = 'test'
// Note: The above function CompareFilenames works case insensitive under Windows
// so under Windows it can find a node with Filename 'TEST'
end;

Note: Find will find a node where your compare function returns 0.

You can also search directly with a filename, without creating a TMyData. The function FindKey takes as arguments a key (here: the filename) and a special compare function:

function CompareFilenameWithMyData(Filename, MyData: Pointer): integer;
begin
Result:=CompareFilenames(String(Filename),TMyData(MyData).Filename);
end;

...
var
Filename: string;
Node: TAvgLvlTreeNode;
begin
Filename:='Test';
Node:=Tree.FindKey(Pointer(Filename),@CompareFilenameWithMyData);

end;

## Resorting, changing the order

You can change the compare function. The tree will automatically rebuild itself. The Nodes will be destroyed and all Data will be added into new nodes. For example you can switch from comparing case sensitive to case insensitive:

type
TMyData = class
public
Name: string;
constructor Create(aName: string);
end;

constructor TMyData.Create(aName: string);
begin
Name:=aName;
end;

function CompareMyDataCaseSensitive(Data1, Data2: Pointer): integer;
begin
Result:=CompareStr(TMyData(Data1).Name,TMyData(Data2).Name);
end;

function CompareMyDataCaseInsensitive(Data1, Data2: Pointer): integer;
begin
Result:=AnsiCompareText(TMyData(Data1).Name,TMyData(Data2).Name);
end;

procedure Demo;
var
Tree: TAvgLvlTree;
Node: TAvgLvlTreeNode;
begin
Tree:=TAvgLvlTree.Create(@CompareMyDataCaseSensitive);
writeln('sorted case sensitive:');
for Node in Tree do
writeln('  ',TMyData(Node.Data).Name);
// sort case insensitivie
Tree.OnCompare:=@CompareMyDataCaseInsensitive;
writeln('sorted case insensitive:');
for Node in Tree do
writeln('  ',TMyData(Node.Data).Name);
end;

Output:

sorted case sensitive:
ABC
Test
abc
test
sorted case insensitive:
ABC
abc
Test
test

# Associative arrays using AVL trees

An associative array is an array where instead of a the position an arbitrary key is used to find an item. For example a string. The unit AvgLvlTree implements several associative arrays using AVL trees:

• TStringToStringTree: string to string, you can choose case sensitive or case insensitive or provide your own string comparison function
• TStringToPointerTree: As TStringToStringTree but to arbitrary pointers, which might be objects

Here is an example demonstrating how to use a TStringToStringTree:

uses
AvgLvlTree;
var
NameToValue: TStringToStringTree;
S2SItem: PStringToStringItem;
begin
// create
NameToValue:=TStringToStringTree.Create(false); // false = Names are compared case insensitive via ''AnsiCompareText''

// set values
NameToValue['First'] := 'One';
NameToValue['Second'] := 'Two';

// get values
writeln('First=',NameToValue['first']); // writes One
writeln('Second=',NameToValue['second']); // writes Two
writeln('Third=',NameToValue['third']); // third is not yet set, it writes the empty string

// check if a key is defined
writeln('First exists: ',NameToValue.Contains('first')); // gives true
writeln('Third exists: ',NameToValue.Contains('third')); // gives false

// enumerate all values
for S2SItem in NameToValue do
writeln('Name=',S2SItem^.Name,' Value=',S2SItem^.Value);

// free
NameToValue.Free;
end;

# Indexed AVL Tree

TIndexedAVLTree extends TAvgLvlTree with the ability to access the nodes via their index (0=lowest, Count-1=highest) similar to an array. In other words it is like an array that is always sorted.

uses
AvgLvlTree;
type
TMyData = class
public
Name: string;
constructor Create(aName: string);
end;

constructor TMyData.Create(aName: string);
begin
Name:=aName;
end;

function CompareMyDataCaseInsensitive(Data1, Data2: Pointer): integer;
begin
Result:=AnsiCompareText(TMyData(Data1).Name,TMyData(Data2).Name);
end;

var
SortedArray: TIndexedAVLTree;
Node: TIndexedAVLTreeNode;
begin
// create
SortedArray:=TIndexedAVLTree.Create(@CompareMyDataCaseInsensitive);

// access items via index
for i:=0 to SortedArray.Count-1 do
writeln(i,': ',TMyData(SortedArray[i]).Name);

// access nodes via GetNodeAtIndex
for i:=0 to SortedArray.Count-1 do
writeln(i,': ',TMyData(SortedArray.GetNodeAtIndex(i).Data).Name);

// get the index of a node
i:=2;
Node:=SortedArray.GetNodeAtIndex(i);
writeln(i,'=',SortedArray.NodeToIndex(Node));

SortedArray.FreeAndClear; // free nodes and objects
SortedArray.Free; // free the tree
end;


text:
## Extending automorphism groups to inner automorphism groups.

I wanted to make clear just a quick technical thing. If G is a group, N is a normal subgroup, and $\phi_g \in \text{Inn}(G), \phi_g(h) = g h g^{-1}$ then $\phi_g$ is an automorphism of N, right? However, is it the case that we cannot say that $\phi_g$ is an inner automorphism, since we are not guaranteed that $g \in N$? I think this is the case, but I just want to be clear.

Furthermore, is it then possible to extend any group to a larger group such that all automorphisms are given by inner automorphisms from the larger group? More precisely, if G is a group, is there always an injective homomorphism $G \to H$ such that $\text{Aut}(G) \cong \text{Inn}(H)$ ?

 PhysOrg.com science news on PhysOrg.com >> Hong Kong launches first electric taxis>> Morocco to harness the wind in energy hunt>> Galaxy's Ring of Fire

Blog Entries: 8
Recognitions:
Gold Member
Staff Emeritus
Hi Kreizhn!

 Quote by Kreizhn I wanted to make clear just a quick technical thing. If G is a group, N is a normal subgroup, and $\phi_g \in \text{Inn}(G), \phi_g(h) = g h g^{-1}$ then $\phi_g$ is an automorphism of N, right? However, is it the case that we cannot say that $\phi_g$ is an inner automorphism, since we are not guaranteed that $g \in N$? I think this is the case, but I just want to be clear.
That is correct.

 Furthermore, is it then possible to extend any group to a larger group such that all automorphisms are given by inner automorphisms from the larger group? More precisely, if G is a group, is there always an injective homomorphism $G \to H$ such that $\text{Aut}(G) \cong \text{Inn}(H)$ ?
Indeed, let G be our group we wish to extend. Let T be a group such that there exists an epimorphism

$$\phi:T\rightarrow Aut(G)$$

(for example, take $T=Aut(G)$), then the semidirect product $G\rtimes_{\varphi} T$ is an extension you're looking for. Indeed, automorphism of G has the form $\phi(h):=\phi_h$. And by construction of the semidirect product, we have that for each g in G

$$\phi_h(g)=hgh^{-1}$$

So the automorphisms of G are inner automorphisms of the semidirect product...

 I shall have to go back and look at my notes on semi-direct products a bit more to understand this fully, but thanks.


text:
Contests Virtual Contests Problems Submit Runs Status Rank List Forum

3484.   Stones
Time Limit: 2.0 Seconds   Memory Limit: 65536K
Total Runs: 2020   Accepted Runs: 1027

Given n piles of stones, now we want to combine them into one pile. In order to finish this job, first we can select two piles arbitrarily, combine them into one; then select two piles from the remaining piles arbitrarily, combine them into one pile, and so on .. until there is only one pile. When we combine two piles, we need to cost some energy, and the cost is related to the number of stones in the small pile. That is to say: If we combine two piles of the size 3 and 5, the energy cost is 3. Now our task is: given the size of the n piles, colculate how much energy we need to finish the job at least?

### Input

The first line of the input is a single integer t, representing the number of test cases. The 2i-th and the 2i+1 -th lines describe the i-th test case. The 2i-th line gives the integer n, then the 2i+1 -th line gives n integers - the size of each pile. (0 < n ≤ 100000, and the size of each pile is no more than 1000).

### Output

For each test cases, output a single integer: the minmun energy we should cost.

### Sample Input

1
4
5 9 6 3

### Sample Output

14

Source: TJU Team Selection Contest 2010 (1)
Submit   List    Runs   Forum   Statistics

Tianjin University Online Judge v1.3.0
Maintance:G.D.Retop. Developer: SuperHacker, G.D.Retop


text:
Color lines in source code that is embedded in LaTeX

I am looking for a way to mark some lines in a source code sample that will be integrated into my LaTeX code.

I already found solutions to embed source code and have syntax highlighting like this solution: Including XML file into LaTeX But this is not exactly what I need. Imagine a source code file I include (XML, if this may be important in any way) and I only want to highlight lines 14, 15 and a part of line 16. I already thought about putting my code in word or open office writer and mark it there and include a screenshot instread of the code-file but there must be a better solution than this.

Anyone can help?

• possible duplicate of highlight lines in listings Oct 20 '13 at 0:48
• Thanks! This is almost what I was looking for but I need to color the text of the code line, not the background of the code line :( Oct 20 '13 at 1:04
• Welcome to TeX.SX! Usually, we don't put a greeting or a “thank you” in our posts. While this might seem strange at first, it is not a sign of lack of politeness, but rather part of our trying to keep everything very concise. Accepting and upvoting answers is the preferred way here to say “thank you” to users who helped you. Oct 20 '13 at 20:53

You could try something like:

\documentclass{article}
\usepackage{listings,xcolor}

\lstdefinestyle{XML}{
language={XML},
moredelim=**[is][\color{orange}]{@}{@},
}

\begin{document}
\begin{lstlisting}[style=XML]
<Line1>
<Line2>
<Line3>
<Line4>
<Line5>
<Line6>
<Line7>
<Line8>
<Line9>
<Line10>
<Line11>
<Line12>
<Line13>
@<Line14>
<Line15>
<Line16>@
</line17>
\end{lstlisting}
\end{document}

Solution pulled from Highlight text in code listing while also keeping syntax highlighting.

• If you directly copy and paste the url of a question/answer, it automatically appears the title. Oct 20 '13 at 11:40
• One downside of this approach is that it forces you to place delimiters in the listing. That's particularly undesirable when \lstinputlisting is used. Oct 20 '13 at 11:47


text:
# Homework Help: Higgs decay

1. Jun 19, 2012

### dingo_d

1. The problem statement, all variables and given/known data
I have decay of Higgs to fermion and antifermion and I need to find out the invariant, averaged amplitude.

And I wrote down the Feynman diagram, and calculated everything and I came to this part:

$\langle|M|^2\rangle=\frac{g_w^2}{4}\frac{m_f^2}{m_w^2}(4p_1\cdot p_2-4m_f^2)$

Now to calculate $p_1\cdot p_2$ I sit in Higgs rest frame, so that the impulses of the fermions are the same (magnitude), but have different sign: $\vec{p}_1=-\vec{p}_2$.

So what I need to end up with is:

$\langle|M|^2\rangle=\frac{g_w^2}{4}\frac{m_f^2}{m_w^2}(2m_h^2-8m_f^2)$

But I just cannot get the right result!

$p_1\cdot p_2=(E_1+E_2)^2-(\vec{p}_1+\vec{p}_2)^2=(E_1+E_2)^2$

If the magnitude of the impulses of the two fermions are the same, and if the masses are the same the energies should also be the same, right? That is, $E_1=E_2=E$, then the scalar product of two 4-vectors is:

$p_1\cdot p_2=4E^2$, where E is the energy of the fermion. Since the energy is conserved: $E_H=E_1+E_2\Rightarrow E=\frac{E_H}{2}$, but since the Higgs is at rest it's mass is equal to it's energy so $E=\frac{m_H}{2}$, but if I put that back into the scalar product I have:
$p_1\cdot p_2=m_H$, but that doesn't give me the right answer :\

Where is my mistake?!

2. Jun 19, 2012

### dingo_d

Ok I think I solved it, I was messing up the kinematics. I feel like an idiot -.-"


text:
# find the exact circular function value for each of the following sec 23pi/6

You need to remember the definition of secant function, such that:

`sec alpha = 1/(cos alpha)`

Hence, you need to determine `sec (23pi/6)` such that:

`sec (23pi/6) = 1/(cos (23pi/6))`

You need to evaluate `23pi/6` such that:

`23pi/6 = 24pi/6 - pi/6 => 23pi/6 = 4pi - pi/6`

`(cos (23pi/6)) = cos (4pi - pi/6)`

You need to expand `cos (4pi - pi/6)` using the following formula, such that:

`cos(alpha - beta) = cos alpha*cos beta + sin alpha*sin beta`

Reasoning by analogy, yields:

`cos (4pi - pi/6) = cos 4pi*cos (pi/6) + sin 4pi*sin pi/6`

`cos 4pi = cos 2*(2pi) = 2cos^2(2pi) - 1`

Since `cos 2pi = 1` yields:

`cos 4pi = 2 - 1 = 1`

Since `sin 4pi = 0` yields:

`cos (4pi - pi/6) = cos (pi/6) = sqrt3/2`

Hence, you may evaluate the secant of `(23pi/6)` , such that:

`sec (23pi/6) = 1/(sqrt3/2) => sec (23pi/6) = 2/sqrt3`

Using rationalization yields:

`sec (23pi/6) = 2sqrt3/3`

Hence, evaluating the given secant yields `sec (23pi/6) = 2sqrt3/3.`

Approved by eNotes Editorial Team


text:
# Revision history [back]

I'm having the same problem with Linux Mint 17.3 and Libreoffice 5.0.4.3.

Having found nothing on this, I followed an Ubuntu forum and I actually found a compressed file, called images_human.zip, where it says and it has basically all the icons the system needs.: /usr/share/libreoffice/share/config

Now, the problem is that following the normal toolbar editing process (View > Toolbar > Customize) it is only possible to change one icon per time, which of course is quite crazy. Does anyone know a way to import all the icons at once?

I also tried to automatically reset the toolbar and it didn't work.

Do you suggest to re-install the whole package?

Thanks


text:
# Time location of the DWT detail coefficients using MATLAB

When performing the Discrete Wavelet Transform in MATLAB using the command DWT or WAVEDEC, what it the exact time or pseudo-time location of the DWT coefficients?

At each level the time series is decimated by 2, this means that the coefficients should be localized at $$2^j \, T_s$$, where $$T_s$$ is the sampling frequency. However, the application of a reconstruction filter of length $$M$$ makes the coefficient arrays longer. And each level a longer coefficient array is then fed into a new DWT function, which modifies further its length. The arrays are also properly extended at each level, according to a criterion specified by the user using the command DWTMODE.

I see that in some MATLAB examples, just the central part of the array is shown using the command WKEEP. Is this approach sufficiently accurate, meaning that the external coefficients (those that are not central) are really NOT significant?

If I do not discard some coefficients, I clearly see a huge delay if I assign them to $$2^j \, T_s$$. I believe that the external coefficients are however necessary for the reconstruction.

How many coefficients can be discarded at each level, if they can be?

• That sounds like a complicated question to me. Theoretically, one should pre-project the discrete samples with information on the wavelet. Also, if the wavelet is not symmetric, time-offsets may appear. And DWT is not shift-invariant. So, many reasons to question: what is your DSP purpose here? – Laurent Duval Jun 8 at 20:23
• I was wondering whether it is possible to build a "time-frequency filter" using the DWT, by tresholding the DWT detail coefficients in each level of the decomposition not only based on their value, but also on the time location. For example, if I have a pulse located at a certain time $t_0$ with super-imposed noise, to de-noise I can keep the detail coeffs. around $t_0$ and treshold the others. It's just an intuitive idea, I am not sure if this is the right approach. What do you think? – EmThorns Jun 8 at 21:33
• This is what I meant. But how can I define this mask if I don't know the time location of the coefficients? When I apply the DWT, the number of coefficients produced is not exactly halved with respect to the previous level because of DWT algorithm (filter side effects, signal extension) and the things you mentioned before (time-offsets, non-shift invariance ... ). As you have a lot of experience in this field, maybe you can suggest to me a few papers where this procedure is carried out? I have not been able to find them. I would really appreciate. – EmThorns Jun 8 at 23:27
• Hi Laurent, sorry to bother you again. Have you not seen any paper of wavelet-domain masking? You don't remember anything off the top of your head? – EmThorns Jun 9 at 21:39
• Yes, it's ok. If in the meantime you can suggest a couple of papers to read, I will try to get them. Thanks. – EmThorns Jun 9 at 23:40

This question has multiple facets (after comments), so I will focus on the principal.

First, regarding coefficient localization: a discrete wavelet coefficient depends on several signal samples. The number of coefficients influenced by a single sample in a continuous wavelet representation typically depends on the properties of the mother wavelet and the signal regularity. This is illustrated on the following picture, with the modulus and the phase of a complex scalogram.

Coefficients at discontinuities (in the signal, the derivatives, etc.) spread in cones of influence. This is well-described in many wavelet books. The situation is even more complicated when you discretize the wavelet plane: one should project the samples with prefiltering, take care of the discrete wavelet symmetries and the level of redundancy. Remember for instance that the DWT is not shift-invariant. Hence, the mask could change a bit.

I thereby propose two methods:

1. one heuristic, based on the deterministic part of the data: build a simple template signal of what you want to detect (e.g. a discrete Dirac), perform your favorite discrete wavelet (redundant or not) over shifted versions, undo the shift scale-wise, combine the envelop of the scalograms and threshold them to keep the top values (as a percentage of the maximum amplitude). You can used it as a binary or weighted mask.
2. one more involved, based on the stochastic part of the data: it is possible to compute, or estimate, the second-order characteristics of a "random noise" (like a Gaussian distribution. The decay of the covariance matrix can serve to assess the influence of a noise sample in its neighborhood. There were many papers on that topic. We notably deployed this approach with our $$M$$-band dual tree wavelets: they are slightly redundant, and therefore there are correlations between scales and wavelet trees. This is described, as well as pointers to the relevant literature, in section III of Noise Covariance Properties in Dual-Tree Wavelet Decompositions.

The resulting "regions of influence" were later used in A Nonlinear Stein-Based Estimator for Multichannel Image Denoising: the shape of the mask (across scales and subbands) defines a Reference Observation Vector (ROV), on which we estimate the "denoised" coefficient, based on generalized thresholding expressions.

The above was used primarily for denoising, but similar reasoning could apply for adaptive filtering, restoration, segmentation, etc.

• Hi Laurent, thanks for your answer. As I'm quite a newbie in wavelets, I will study your answer carefully. Clearly, it is not possible to define a precise time instant to a coefficient, s it is not possible to assign a particular frequency to a coefficient. This also come from the Heisenberg uncertainty principle. – EmThorns Jun 14 at 14:55
• I was jut wondering if, on first approximation, I can start from the code used to plot the coefficients in MATLAB using a map time-level. it.mathworks.com/help/wavelet/examples/… It seems that the code considers the coefficients at each level. The coefficients at level j are repeated $2^j$ times in order to build NxM matrix, where N is the number of samples and M is the number of points. After they are repeated, the first and last coefficients are removed. – EmThorns Jun 14 at 14:57
• The coefficients at the next level come from the application of the wavelet decomposition filter + a sub-sampling by 2. However, for end effects, the number of coefficients at the level $j+1$ are not half of the coefficients at level $j$. The first and last coefficients are removed from the final line of the DWT matrix to be plotted using the command WKEEP, which keeps exactly N (numer of samples) "plotting values". – EmThorns Jun 14 at 15:01
• I don't know if eliminating the first and the last coefficients is good, also because these coefficients are necessary for the reconstruction. However, the point is, how many coefficients are "reliable" in the original ones determined with the command detcoef or dwt? Can I assign them, on first apporximation to the time instant $2^j T_s$, where $T_s$ is the sampling period? How to manage the first and last coefficients? I believe that if I can solve this, maybe it is possible to perform a de-noising in time-level domain (still on first approximation, given also what yous said in your answer). – EmThorns Jun 14 at 15:06
• Did you try to stick to power-of-two length $N$ of signals, a number of levels $L$ such that $2^L$ divides $N$, and dwtmod(per) to reduce the overhead? – Laurent Duval Jun 14 at 15:06


text:
Conservative force in a time-dependent potential

1. Feb 29, 2016

Happiness

A conservative force is one that is derivable from a potential energy function $V$. If $V$ is time-dependent, is it still possible to have a conservative force or work done such that the work done is only dependent on the initial state $(x_i, y_i, z_i, t_i)$ and final state $(x_f, y_f, z_f, t_f)$ of the particle and independent of the trajectory taken?

2. Feb 29, 2016

vanhees71

No, because in that case the work-energy theorem turns out to be
$$\frac{m}{2} \vec{v}(t)^2+\text{const}=\int \mathrm{d} t \vec{F}(\vec{x},t) \cdot \vec{v}=-\int \mathrm{d} t \vec{v} \cdot \vec{\nabla} U(\vec{x},t).$$
Now
$$\frac{\mathrm{d}}{\mathrm{d} t} U(\vec{x},t)=\vec{v} \cdot \vec{\nabla} U(\vec{x},t) + \partial_t U(\vec{x},t),$$
i.e., the integrand on the right-hand side of the work-energy theorem is not a total time derivative as in the case, when $U$ is not explicitly time-dependent.

This is a consequence of Noether's theorem: A system is symmetric under time translations if and only if the Lagrangian is not explicitly time dependent modulo a total time derivative of a function $\Omega(q,t)$.

3. Feb 29, 2016

Happiness

How about we treat time as the fourth spatial dimension? Where $\vec{v}$ becomes a four-dimensional vector. Then
$$\frac{\mathrm{d}}{\mathrm{d} t} U(\vec{x},t)=\vec{v} \cdot \vec{\nabla} U(\vec{x},t)$$
So the integrand on the right-hand side of the work-energy theorem becomes a total time derivative.

What's wrong with this?

4. Feb 29, 2016

vanhees71

Well, that comes close to relativistic dynamics in terms of a world parameter. That generalized dynamics has to be developed carefully. For a good introduction (although unfortunately full of typos even in the math) see

Barut, Electrodynamics and classical theory of particles and fields, Dover