Recent content by darkfall13

  1. D

    MATLAB How to Limit Colormap Range in Matlab Scatter Plot?

    I think I found it, using "caxis([minvalue maxvalue])" before colorbar seems to be what I'm looking for.
  2. D

    MATLAB How to Limit Colormap Range in Matlab Scatter Plot?

    I'm doing some plotting in Matlab where I'm using a third variable of data as a color. For example I have vectors x and y with some sort of values plotted as a scatter plot. I can color the points according to a third vector z by turning on colormap and colorbar (scatter(X,Y,S,C) and use z in...
  3. D

    MATLAB MATLAB Color Points According to Variable

    Wow as much as I thought that didn't help I didn't realize the scatter function can take a vector for color values, and it automatically creates equal transitions for the spectrum. Thank you so much!
  4. D

    MATLAB MATLAB Color Points According to Variable

    I've been thinking a bit on this and I can see I'll need some sort of variable to define the stepping through different color shades, and to define how many shades I'll be wanting. I see the regular "colorbar" command seems to be the right color scheme. But how do I apply to the individual...
  5. D

    MATLAB MATLAB Color Points According to Variable

    I have been tasked with making a plot with a couple variables of available data. I'm to make a normal 2D scatter plot of the data with respect to 2 of the variables given, easy enough. But then I'm supposed to color (from red to blue) each point according to a 3rd variable, which is a derivative...
  6. D

    Refraction through a nonuniform medium

    Ha thank you for the catch, I haven't been completely here lately. \cot \theta = \frac{-x}{2a} \theta \left( \textbf{x} \right) = \cot^{-1} \left( \frac{-x}{2a} \right) = \cot^{-1} \left( - \frac{2a \sqrt{1-\frac{y}{a} } }{2a} \right) = - \cot^{-1} \left( \sqrt{1-y/a} \right) = \theta...
  7. D

    Refraction through a nonuniform medium

    Homework Statement A plane electromagnetic wave refracts in a nonuniform medium. The ray trajectory is known, y = a \left[ 1 - \left( \frac{x}{2a} \right)^2 \right] where a=const. a) Plot y(x) b) From the slope of the curve find the angle \theta \left( y \right) which the...
  8. D

    MATLAB Solving Filename Issues in MATLAB 6.5.1

    OK thank you, I'll have to devise a new naming scheme for the files I need to create, and isvarname should come in handy thank you.
  9. D

    Energy, magnitude of E & B, pressure from a laser

    That does help immensely thank you.
  10. D

    Energy, magnitude of E & B, pressure from a laser

    Homework Statement A Ti-sapphire femtosecond laser (1fs= 10^-15s, λ≈0.8μm) has an intensity of 1022 W/cm2 when focused to a spot of 1μm radius. What is the energy of the laser pulse? What is the peak magnetic induction B in Tesla and the electric field in V/m? What is the wave pressure in...
  11. D

    MATLAB Solving Filename Issues in MATLAB 6.5.1

    I'm having a weird problem in my copy of MATLAB at work (6.5.1.199709 Release 13 SP1). Originally I was having a problem with naming a file "any.m" as it wouldn't run. So I named it anyd.m and no problem afterward and I just assumed that word was some sort of script or something already defined...
  12. D

    Induced Current Density On Disk Due to Changing Magnetic Field

    I'm silly, I think I got it started: \vec{\nabla} \times \vec{E} = - \frac{ \partial \vec{B} }{\partial t} = + B_0 \omega \sin(\omega t) \hat{z} \oint_C \vec{E} \cdot d\vec{s} = \oint_C E_\phi \hat{\phi} \cdot \rho d\phi \hat{\phi} = 2 \pi \rho E_\phi = \int_S (\vec{\nabla} \times \vec{E})...
  13. D

    Induced Current Density On Disk Due to Changing Magnetic Field

    Homework Statement A very thin conducting disc of radius a and conductivity \sigma lies in the x-y plane with the origin at its center. A spatially uniform induction is present and given by B=B_0 cos\(\omega t \)\hat{z}. Find the induced current density \vec{J} in the disc. Homework...
  14. D

    Undergrad Kirth, Kerth, Kurth (SP?) Phase?

    Hello everyone, I have no clue where this question should go as I do not have the slightest insight as to what this even is. Background, I'm doing a project over the summer with my professor studying magnetic fields of Saturn. One of the variables I'm to record is K(i,e,u)rth Phase, noted as...
  15. D

    Undergrad Can a small shock from a lighter be more dangerous than a wall socket?

    Generally high voltage comes with quite a bit of current (but also used to circumvent this: the large power lines carry high voltage with low current to try to overcome resistance over vast distances). But the part of this equation that can kill you is the current. This is also why there's the...