Group Abstract Group Abstract

Message Boards Message Boards

9
|
5.7K Views
|
98 Replies
|
57 Total Likes
View groups...
Share
Share this post:
GROUPS:

[WSG77] Daily Study Group: Differential Equations (begins April 13)

Posted 4 months ago

Please join us in a study group devoted to differential equations that begins Monday, April 13. This study group will meet daily, Monday to Friday, over the next two weeks. We will share the excellent lesson videos from the Wolfram U course "Introduction to Differential Equations." The study group sessions will include time for exercises, discussion and Q&A. This study group will help you achieve the course completion certificate for the "Introduction to Differential Equations" course after you complete the course quizzes.

REGISTER HERE

enter image description here

POSTED BY: Luke Titus
98 Replies

There is something odd about Lesson 27 (Review of Matrices) as it appears in the course framework. In the section "Matrix Functions", the code snippet

A={{x^2, x},{3 + x}, Exp[x]}};
A // MatrixForm

is followed by (apparently output) matrix

{{{r^2, s^2}, {r, s}}, {{r + 3, s + 3}, {Exp[r], Exp[s]}}}  (* Completely different matrix *)

When I open the downloaded lesson in Mathematica, I see the input as shown, but the output is the matrix corresponding to the input with the variable x, not the more complicated matrix with r and s as I see in the course framework..

Thank you. That definitely shouldn't be like that. I think x was holding a definition from a previous example that wasn't cleared. We'll get that fixed. Thank you so much for catching these errors.

POSTED BY: Luke Titus
POSTED BY: Luke Titus

In Problem Session 7, the discussion of Problem 2 says "Because of the lack of a damping term, the solution takes an unending oscillatory path:"

In fact, the equation for this problem (y''[t] + 2*y'[t] + y[t] == (a few step functions) ) DOES have a damping term and the plotted solution tapers off quickly.

POSTED BY: Luke Titus

In Examples 3, 4, and 5 of Lesson 26 (Convolution Theorem), the analysis stops at the same point, showing that the solution has the form

Integrate[ someFunction[ t-r ]*phi[r], {r,0,t}]

where phi[r] represents the UnitStep function. Since the Wolfram Language apparently does not understand the meaning of phi, it does not resolve the integral . HOWEVER, it would help the student if you would point out in all these cases that the UnitStep function (phi) simply equals 1 in the region of integration {r, 0, t}, and therefore the integral reduces to Integrate[ someFunction [t-r], {r,0,t} ]. I'm sure it would also be useful to remind the student that L[UnitStep] is 1/s .

POSTED BY: Luke Titus

In Lesson 24, Exercise 4 also contains a sign error. The forcing function described at the top is

UnitStep[t-2*Pi] * Sin[t] - UnitStep[t-4*Pi] * Sin[t]

With its negative sign, the second term cancels out the first term after t==4Pi. The forcing function is then just a single cycle, and the solution settles down to a constant amplitude. However, the forcing function in the solution is UnitStep[t-2Pi] * Sin[t] + UnitStep[t-4*Pi] * Sin[t]

With its plus sign, the second term reinforces the sinusoidal oscillation driving the solution, which then diverges.

Hello Richard,

Thank you for this feedback. I'll create a ticket per your report for Luke to review.

Christine Owens

POSTED BY: Christine Owens
Posted 3 months ago

In the Exercises for Lesson 24 (Discontinuous Forcing Functions), Exercise 1 solves a different equation than posed at the top of the problem. At the top, the equation is

2*y''[t] + y'[t] +2*y[t] == UnitStep[t-2]   (* Note the sign of the y'[t] term. *)

The equation you actually solve for is

''[t] -y'[t] + 2*y[t] == UnitStep[t-2]      (* Note the sign of the y'[t] term. *)
POSTED BY: Updating Name

The difference the sign of y'[t] makes is fascinating. With a minus sign, the solution diverges (swings wider and wider away from zero). With a plus sign, it converges to a value of 1/2.

Hello Richard,

I'll open a ticket including your report and notebook for Luke to review. I'll follow up with you via email.

Thank you,

Christine Owens
Wolfram U Project Manager
Wolfram U

POSTED BY: Christine Owens
Posted 3 months ago

Question for Luke on the definition of autonomous equations. In my notes I have that you presented an example y'(t) = 5 + y(t). However this is still depending on "t", so it is not purely just depending on the dependent variable there. If you are defining an autonomous equation as y' = f(y) versus y' = f(x), that will change whether an autonomous equation is necessarily exact or not.

POSTED BY: Jason Gross

Hello Jason,

I'll inquire about this with Luke.

Thank you,

Christine Owens
Wolfram U Project Manager
Wolfram U

POSTED BY: Christine Owens
POSTED BY: Michael Rogers
Posted 3 months ago
POSTED BY: Jason Gross

@Jason Gross, Just to be clear, I'm saying both of these are autonomous:

  • y'(t) = 5 + y(t)
  • y' = f(y)

And this one is not autonomous because the independent variable x appears in f(x) and f is not y:

  • y' = f(x)

The first one, y'(t) = 5 + y(t), is the same as y' = 5 + y, which has no t. The fact that the solution y(t) and its derivative depend on t is not a factor in the definition of autonomous.

[Update: Edited to fix sign errors.]
As for exact, I'm not sure what definition was used, but I'm sure it's equivalent to the following. Put the autonomous differential equation in differential form: $${dy \over dx} = {M(x,y) \over N(x,y)} \Longrightarrow M(x,y)\;dx + N(x,y)\; dy = 0\;.$$ Then the equation is exact if ${\partial M \over \partial y} = {\partial N \over \partial x}$. For the autonomous $y'=f(y)$, we have $${dy \over dx} = f(y) \Longrightarrow -dx + {1 \over f(y)}\; dy = 0\;.$$ So $M$ is the constant $-1$ and $N$ is $1/f(y)$. Thus ${\partial M \over \partial y}$ and ${\partial N \over \partial x}$ are both zero. So the autonomous equation *in this form is exact. In fact, all separable equations can be made exact with the right integrating factor, and an autonomous equation is separable: $${dy \over dx} = f(y) \Longrightarrow {dy \over f(y)} = dx \;. $$ On the other hand, we also have $${dy \over dx} = f(y) \Longrightarrow -f(y)\;dx + {1}\; dy = 0\;.$$ In this form $M=-f(y)$ and $N=1$. Thus ${\partial M \over \partial y}=-f'(y)$ and ${\partial N \over \partial x}=0$. In this form, the equation is not exact unless $f'(y)=0$, that is, unless $f$ is constant. It does, however, have an integrating factor ( $1/f(y)$, for instance).

POSTED BY: Michael Rogers
Posted 3 months ago
POSTED BY: Jason Gross
POSTED BY: Michael Rogers
Posted 3 months ago
POSTED BY: Jason Gross
Posted 3 months ago

There's a typo in the setup of Problem 7 in Problem Session 6. The initial conditions in the text intro are

y(0) = 1
y'(0) = 1

However, the Mathematica code for the transform is

leqn=LaplaceTransform[y''[t]+4y'[t]+4y[t]\[Equal]Sin[t], t,s]/.{y[0]->0,y'[0]->1} 

Note that y(0) is given different values in the two places (one in the text, zero in the code).

POSTED BY: Updating Name

Hello,

Thank you for bringing this to our attention. Can you please confirm your name? I'll follow up with you via email once this has been reviewed and updated.

Best,
Christine Owens
Wolfram U Project Manager
Wolfram U

POSTED BY: Christine Owens

Thank you. My name is Richard Daehler-Wilking.

Richard Daehler-Wilking daehlerr@bellsouth.net

POSTED BY: Christine Owens
POSTED BY: Christine Owens
POSTED BY: Luke Titus

Cool! Thank you. SUGGESTION: Add this to the discussion of Example 4 in Lesson 19. It seems to be a nice example of an apparent singularity that isn't "essential"; that is, it goes away when you look at it right.

Thank you Richard. I've noted this for Luke to review.

POSTED BY: Christine Owens

Sorry to submit so many questions -- but not really. They come up because the course is so rewarding and has so much potential. Thanks for the challenge!

In Lesson 19 (Series Solutions near a Singular Point), Example 2, I'm able to duplicate everything up until the solution to the recursion relations (notebook attached). When I try to use RSolve[ ], I get expressions involving Pochhammer[...], which I've never heard of before. Wolfram documentation for Pochhammer indicates it should reduce to ratios of factorials if it is given integer arguments, but the solutions I come up with all involve a fraction.

QUESTION: When RSolve[ ] gives us Pochhammer, is there anything we can do to simplify it? Or is there something in particular we should look for to fix it?

Attachments:

FunctionExpand[] and FullSimplify[] will convert Pochhammer[] to Gamma[]. Since Gamma[1+n] equals n !, FullSimplify[] will go further if the complexity function tells FullSimplify[] that the factorial expression is less complex than the gamma expression and the argument is an integer. Note that "less complex" is a numerical measurement and not the same a "more familiar to the user."

FullSimplify[
 -(((-1)^n 2^(1 - n) C[1])/(Pochhammer[3/2, -1 + n] Pochhammer[2, -1 + n])), 
 n \[Element] Integers && n >= 0]
(*  -(((-2)^n C[1])/(2 n)!)  *)

For the following, one needs a complexity function that favors factorials to get a factorial:

FullSimplify[
 -(((-1)^n 2^(1 - n) C[1])/(Pochhammer[2, -1 + n] Pochhammer[5/2, -1 + n])), 
 n \[Element] Integers && n >= 0]  
(*  -((3 (-2)^n C[1])/Gamma[2 + 2 n])  *)

FullSimplify[
 -(((-1)^n 2^(1 - n) C[1])/(Pochhammer[2, -1 + n] Pochhammer[5/2, -1 + n])), 
 n \[Element] Integers && n >= 0, 
 ComplexityFunction -> 
     (LeafCount[#] - 3 Count[#, _Factorial, Infinity] &)]
(*  -((3 (-2)^n C[1])/(1 + 2 n)!)  *)
POSTED BY: Michael Rogers
POSTED BY: Michael Rogers

Thank you very much for all of your comments, Richard. I really do appreciate it. We've put a lot of work into this course and we want to make it the best course we can. Your comments have helped us a lot with identifying some of the errors or improvements that we've overlooked.

POSTED BY: Luke Titus
Posted 4 months ago

Just a practical question here - the quizzes are not timed are they? Thanks.

POSTED BY: Jason Gross
POSTED BY: Christine Owens

In Lesson 19 (Series Solutions near a Singular Point), Example 1 glosses over a subtle, difficult, and perhaps important point. For the equation 4xy''[x] + 2*y'[x] + y[x] == 0, one recursion relation is derived leading to the sequence of coefficients {a[0], -a[0]/2!, +a[0]/4!, -a[0]/6!, ...} and another relation is derived leading to {a[0], -a[0]/3!, +a[0]/5!, -a[0]/7!, ...}. Both these sequences appear in my old CRC handbook table of trigonometric series. The first is for Cos[x] and the second is for Sin[x]. But Lesson 19 goes on to say that the sequences we've just derived are for Cos[Sqrt[x]] and for Sin[Sqrt[x]] . Where did the Sqrt[..] come from?

The answer is implicit when you show the result of Series[Cost[Sqrt[x]], {x, 0, 3}]. There, we discover that the powers of x in the Cos series are {1, x, x^2, x^3, ...}, while the powers in my trust old CRC handbook are {1, x^2, x^4, x^6, ...} (each term the square of CRC's list). For Sin, CRC shows {x, x^3, x^5, x^7, ...} instead of {x^(1/2), x^(3/2), x^(5/2), x^(7/2), ...} as shown by Mathematica for Sin[Sqrt[x]].

QUESTION: How are we to know the powers of x that go with each term in the series expansion? I could probably answer this question 55 years ago in Calc 210, but it eludes me now.

Hello Richard,

Thank you for this feedback. I'll create a ticket per your report for Luke to review.

Christine Owens Wolfram U Project Manager Wolfram U

POSTED BY: Christine Owens
POSTED BY: Luke Titus

The voiceover for Lesson 18 (Euler Equations) includes an important sentence that is NOT in the written notes: "The equation can be simplified by assuming the solution is some power of x." [At time stamp 2:09 or so.] The written notes then say "Euler observed that by utilizing the power rule (x^r}' == r*x^(r-1), the differential equation could be transformed into a simpler form ..."

SUGGESTION: Include the voiceover assumption that y[x]==x^r in the written notes. It's implicit in the Wolfram Language transformation ( /.y->Function[x,x^r] ) but has no justification if one is just reading the notes.

Hello Richard,

Thank you for this feedback. I'll create a ticket per your report for Luke to review.

Christine Owens Wolfram U Project Manager Wolfram U

POSTED BY: Christine Owens

In Lesson 17 about series solutions near an ordinary point, the first graph shows a sequence of plots converging to a limit. The last graph shows a similar collection of plots, and points out their convergence in the interval (-1, 1). I was confused at first because I expected a note about divergence.

SUGGESTION: For the last graph, also point out that as the order increases the plots move AWAY from the full solution (dotted line) rather than toward it as they did in the first graph. This illustrates divergence outside the region of convergence.

That's a good point. Thanks for the suggestion, Richard. We'll update the notebooks to reflect that.

POSTED BY: Luke Titus

Problems 11 through 14 of Problem Set 4 entail physical equations with actual physical units. The use of physical units such as {kilograms, meters, seconds} was mentioned in the class, so I tried using pounds, inches, and seconds, (converting pounds to mass by dividing by gravitational acceleration). Mathematica allowed me to enter pretty-looking equations and initial conditions, but then did not seem to know what to do with them when I tried DSolveValue. Presumably I'm doing something wrong, but the sample problems don't help here.

SUGGESTION: Demonstrate use of physical units in one or two problem set solutions.

Thanks, Richard. That's a good suggestion. We can include units in a few of those problems to show how to include units in a calculation.

POSTED BY: Luke Titus
Posted 4 months ago
POSTED BY: Updating Name

Thank you very much. It does look like it should be Exp[x] rather than Exp[2]. We'll get that fixed.

POSTED BY: Luke Titus
Posted 4 months ago
POSTED BY: Rich Albert

Hi Rich. Please send your solution to wolfram-u@wolfram.com They will forward your solution along to me and I will get back to you over email.

POSTED BY: Luke Titus

COMMENT on END-OF-COURSE SURVEY: You ask us to indicate all the Daily Study Groups we'd be interested in, but the radio buttons only allow a single choice. SUGGESTION: Change the reply function to checkboxes.

Oops! Thanks for sharing this error in the survey question. We will fix it.

POSTED BY: Jamie Peterson

Hello Richard,

I've created a ticket per your inquiry for review.

Christine Owens
Wolfram U Project Manager
Wolfram U

POSTED BY: Christine Owens

Thanks for pointing that out, Richard. We'll get that fixed.

POSTED BY: Luke Titus
Posted 4 months ago

I believe I figured out my original problem: The solution to Problem 5 refers to the Method of Undetermined Coefficients even when it is applying Variation of Parameters. Please check: Above the equation

u1=-Integrate[y2[x]Sin[x]/Wronskian[{y1[x],y2[x]},x],x]+C[1] 

do you mean to say "Method of Variation of Parameters" instead of "Method of Undetermined Coefficients"?

POSTED BY: Updating Name

Hello Richard,

I've added your follow-up to our original ticket per your report above for "problem 5, problem session 4".

Thank you,

Christine

POSTED BY: Christine Owens

To form an augmented matrix from matrix A and vector b, it's important to realize that the augmented matrix uses b as a COLUMN vector. If b is a single-level list, that amounts to a row vector (in spite of what some Mathematica documentation says), so we must transpose it. Transpose[ ] works with matrices (multi-level lists) but not with row vectors (single-level lists). Assume A is {{1,2,3},{4,5,6}} and b is {x,y}. To transpose b we must first enclose it in curly braces to form a two-level list. We then direct the Join[ ...] function to act at level 2 of the lists, instead of level 1.

Augmented matrix:: Join[A,Transpose[ { b } ], 2]

Output: {{1, 2, 3, x}, {4, 5, 6, y}}

Thank you, Richard. It looks like that is doing the right thing.

POSTED BY: Luke Titus

In both Lesson 24 (Discontinuous Forcing Functions) and Lesson 25 (Impulse Functions), plots are shown of the complementary solution (forcing function is zero) and the particular solution (forcing function/impulse function applied). It would be interesting to see a plot of the DIFFERENCE between results with/without forcing function.

In Lesson 24, there's not much to see. However, the difference plot of (sln2 - sln3) in Lesson 25 makes it easier to see the effects of the applied impulse functions, particular the first negative hit at t==2Pi. It's harder to see the effect of the positive hit at t==3Pi because it simply adds to the already-positive motion of the curve. SUGGESTION: Create a Manipulate box to allow the student to tinker with the timing and magnitude of the second hit. That should provide a nice feeling for coherent and destructive effects.

Hello Richard,

Thank you for your feedback. I've created a ticket per your report for Luke and our team to review. As soon as I have more information, I'll let you know.

Best,
Christine Owens
Wolfram U Project Manager
Wolfram U

POSTED BY: Christine Owens

Thank you very much for your comments, Richard. Sorry that I couldn't give a better reply during the session today, but posting these comments here helps us keep track of everything that needs to be improved in the course.

POSTED BY: Luke Titus

I think there's a significant typo in the solution to Problem 11 of Problem Set 2. The problem is to plot the first four iterations of Picard's method for this initial value problem:

y'[t] == (t^2 + y[t]^2 )^2      and      y[0] == 0

The published solution starts out with

y1 = Integrate[0 + s^2, {s, 0, t}]

This omits the outer exponent of the original equation. Shouldn't it be

y1 = Integrate[ ( 0 + s^2) ^2, {s, 0, t}]

Yes, you are absolutely right. It should be Integrate[ ( 0 + s^2) ^2, {s, 0, t}]. Thank you for pointing this out. We'll get it fixed.

POSTED BY: Luke Titus

In the Basic Example of Lesson 13 (Method of Undetermined Coefficients) , DSolveValue returns a solution in terms of Cos[x] and Sin[x]. QUESTION: Is it possible to specify which basis functions DSolveValue uses? That is, can we ask DSolveValue to return an answer in terms of

Exp[x] and Exp[-x]?

That can't be controlled from within DSolveValue, but you can use the TrigToExp function to do that conversion. For example:

In[1]:= TrigToExp[DSolveValue[y''[x] + y[x] == x, y[x], x]]
Out[1]= x + 1/2 E^(-I x) C[1] + 1/2 E^(I x) C[1] + 1/2 I E^(-I x) C[2] - 1/2 I E^(I x) C[2]
POSTED BY: Luke Titus

I have notice between the Exercise 11-1 and Exrcise 12-1. They are changed.

enter image description hereenter image description here

POSTED BY: Jaime Jiménez

Thank you very much. It does look like the solution for those two exercises have been switched. We'll have to fix that. Thank you for pointing that out. We really appreciate it.

POSTED BY: Luke Titus

I must have missed something. Lesson 8 is on Picard's Theorem. The first two exercises for Lesson 8 are indeed connected to Picard's Theorem, but exercises 8.3 through 8.5 seem unrelated to it. For example, Exercise 8.3 is:

Transform the following initial value problem to the equivalent problem with the initial value at the origin: 2x - y[x] + y'[x](2*y[x] - x) == 0 and y[1] == 5

The solution doesn't make sense to me, and Mathematica says the solution's transformed equation does NOT correspond to the original. The original solution is entirely real; the transformed solution is complex. Perhaps I made a typo, but I triple-checked it and also used copy-and-paste.

Picard's Theorem works best when the initial condition when the dependent variable equals zero when the independent variable equals zero. Exercise 3 shows how to transform a differential equation where y[0] is not equal to zero into an equivalent problem where the initial condition at zero equals zero.

POSTED BY: Luke Titus
POSTED BY: Luke Titus
POSTED BY: Christine Owens
Posted 4 months ago

In Section 12 of the course, the symbol Lambda was used for the characteristic equation. Can you explain why that particular symbol was used there? It seems that choice was no accident, but I see no clues to why that was chosen. TY.

POSTED BY: Phil Earnhardt
POSTED BY: Luke Titus

REQUEST: Can you please post a URL for the daily study group sessions? Everything I try just takes me to the registration page. It has dial-in information that doesn't work (no Dial-In ID Number), and I can't find a link to the session that has surely started by now.

Thanks, but that link goes to the course framework with the recording of the course. I'm looking for a link to the daily lectures as they are given. Sometimes the link in the daily reminder e-mail works, but at least once or twice it did not seem to work for me.

POSTED BY: Luke Titus

No, I'm NOT looking for a link to the recording. Cassidy has been sending those out each day. What I'm looking for is a link to the presentation ABOUT TO BE PRESENTED -- in other words, the live class session. For example, I just received the reminder for today's course session. It has a link [Join Daily Study Group] and immediately below that another link headed by "Join using your custom link:"

Both links take me to to a page describing the webinar, with a graphic that sometimes contains an arrowhead that lets me into the course and sometimes does not. Yesterday it did not. Today it does not. I have dialed into the session (Dial-In Number 176487# and Passcode 8751#) and am now listening to some very nice hold music ...

Someone from the WolframU team will reach out to you shortly.

POSTED BY: Luke Titus
Posted 4 months ago

Richard, it sounds like you have an issue logging into the BigMarker servers. The link Cassidy sends out every day contains your BigMarker credentials: they're embedded in the long list of characters in that URL. Cassidy should be able to reset and re-send to you. An email to wolfram-u@wolfram.com should get the ball rolling.

As a temporary workaround, I bet you could "register" with another e-mail address and use that to access the session today. Wolfram U would prefer to fix your permanent account (since that's how they track users for certifications they earn), but that can get you running today.

Good luck. This course is hard enough for me with my BigMarker login working smoothly. :)

POSTED BY: Phil Earnhardt

I'm trying to generate nice legends like the ones in the Autonomous Equations section of Lesson 6:

C[1] = -2  C[1] = -1  C[1] = 0  C[1] = 1  C[1] = 2 

I tried Table["C[1] = "j, {j, -2, 2}] but this generated

-2 C[1] =
-C[1] = 
0
C[1] =
2 C[1] =

In other words, Mathematica did math instead of lexical substitution!
QUESTION: Is there an analog of the C language sprintf function by which we can generate formatted expressions?

Basically, you need to convert everything to a string then use <> to combine the strings you want. You can use quotes to convert the C[1] expressions to a string, but you need to use the ToString function to convert the iterator in the Table to a string. For example:

In[94]:= Table["C[1] = " <> ToString[i], {i, -2, 2}]
Out[94]= {"C[1] = -2", "C[1] = -1", "C[1] = 0", "C[1] = 1", "C[1] = 2"}
POSTED BY: Luke Titus

Something seems odd in the "Integrating Factor Method" section of Lesson 5 (Linear 1st-Order Eqns). The input

D[Exp[f[x]],x] 

generates Exp[f[x]] f'[x] on my system, as expected. However, in the lesson notebook it generates output with an exponent that seems to be a detailed list of possibilities. Pasting it into this box gives an unholy mess, but the first set of possibilities seems to be

1 if 0 <= x < 1 and
0 otherwise

and the second set of possibilities looks like

0 if x is not equal to zero or one;
Indeterminate otherwise

My guess is that the function f is carrying a definition over from a previous cell. SUGGESTION: clear the contents of f before calling D[Exp[f[x]],x]

It does seem like the symbol f has some other definition attached to it. If you clear f before evaluating the derivative, it should give the expected result. For example:

Clear[f]
D[Exp[f[x]], x]
POSTED BY: Luke Titus

In Lesson 5 (Linear 1st Order Eqns), the example for constant coefficients shows a manual reworking of the solution to bring the arbitrary constant C out of the exponential function, then uses that manually reworked expression as a replacement for y when checking the solution:

y->Function[x,(b+\[ConstantC] Exp[-a x])/a]

When I tried simply replacing y with the generated solution

[In]    soln2 = Solve[soln, y[x], Reals]

    (y'[x] + a*y[x] == b) /. y -> Function[x, Evaluate[soln2]] // Simplify

[Out]    {{y[x] -> (b + E^(-a x + C[1]))/a}}

the result would not simplify to True. It doesn't perform the indicated replacements:

[In]    (y'[x] + a*y[x] == b) /. y -> Function[x, Evaluate[soln2]] // Simplify

[Out]    
{{a (y[x] -> (b + E^(-a x + C[1]))/a) + (Derivative[1][y][x] -> -E^(-a x + C[1]))}} == b

QUESTION #1: Why won't it simplify?

QUESTION #2: Is there a way to have Mathematica do the work, rather than having to rework the solution manually?

The issue here is that the form of y[x] in the definition of soln2 isn't in the right form to make the replacement. This variable has the definition:

soln2={{y[x]->(b+E^(-a x+Subscript[\[ConstantC], 1]))/a}}

When making the substitution into the equation, you first need to extract just the functional form for the solution rather than the entire rule. For example:

In[24]:= soln2[[1, 1, 2]]
Out[24]= (b + E^(-a x + C[1]))/a

This form can be substituted into the equation to verify it is true.

In[25]:= (y'[x] + a*y[x] == b) /. y -> Function[x, Evaluate[soln2[[1, 1, 2]]]]
Out[25]= True

For your second question. There isn't an easy way to automatically redefine the constant term in the exponential as another constant. If the equation was in a simpler form, you could use a replacement rule such as:

In[26]:= a*Exp[C[1]] /. Exp[C[1]] -> C[2]
Out[26]= a C[2]

However, since the -a*x term is also in the exponential, more complicated pattern matching that wouldn't be general for all situations would be required pick out just the Exp[C[1]] term. In these cases it's normally easier to just redefine the arbitrary constants manually.

POSTED BY: Luke Titus
Posted 4 months ago

When first studying differential equations, I seem to recall we were drawing magnitudes with the vectors in the direction field. Or maybe my memory is not accurage. I mostly recall they were a pain to draw manually -- much work. :( Is there any advantage to drawing magnitudes with the vector fields, or has everyone agreed that having unit magnitude vectors is the way to go?

Does VectorPlot[] allow one to draw vector fields with something other than a unit magnitude? Have you ever encountered an application where that was useful?

POSTED BY: Phil Earnhardt

You can get different sized arrows using VectorScaling and VectorSizes. For example:

VectorPlot[{y, -x}, {x, -3, 3}, {y, -3, 3}, VectorScaling -> Automatic, VectorSizes -> {0, 1}]

The advantage of using all vectors with a unit length and specifying the magnitudes with colors is to make the plot less cluttered when vector lengths differ a lot in the plot. When using the default unit lengths for the vectors, you can get a legend that shows the length that corresponds to a particular color using PlotLegends

VectorPlot[{y, -x}, {x, -3, 3}, {y, -3, 3}, PlotLegends -> Automatic]
POSTED BY: Luke Titus
Posted 4 months ago

![enter image description here][1]

Can r be i?

POSTED BY: Tingting Zhao

Sure, but most (maybe all?) introductory diff. eq. courses restrict their attention to real-valued solutions. [This is a practical convention, since the course usually follows first-year, real-valued calculus.]

POSTED BY: Michael Rogers

You can get an imaginary r(t) function, for example, by using an initial condition on r[0] that is complex. However, we are mostly focusing on the real-valued functions in this course.

POSTED BY: Luke Titus

Regarding Lesson 3 and the associated Problem 5: At first I was baffled why the instructor did so much work to come up with a solution that he then verified using DSolveValue[...]. Why not simply use DSolveValue[...] to begin with, as was done in the recent course on Partial Differential Equations. Then I realized that this instructor is actually teaching us math, not simply Wolfram Language functions!
SUGGESTION (in terms of Problem 5 of Problem Session 1, but can be applied to the population model in Lesson 3 as well): After the text "Move dx to the right-hand side and use Integrate on the left-hand side", show the result of moving dx to the right-hand side BEFORE integrating:
(1 / {f(x) + 1)) df(x) = 1 * dx
NOW point out that we have separated variables and can integrate each side separately. (The instructor said this, but we didn't have this form of the equation to look at, so I missed his point.)

POSTED BY: Luke Titus

This is just a reminder that the Differential Equations Study Group begins tomorrow (Monday, April 13).

The Study Group will offer an excellent opportunity to get certified in Differential Equations with guidance from our popular instructor, Luke Titus.

I look forward to seeing you all!

POSTED BY: Devendra Kapadia
Reply to this discussion
Community posts can be styled and formatted using the Markdown syntax.
Reply Preview
Attachments
Remove
or Discard