How Do I Correctly Plot an Electric Field Around a Base Station Using MATLAB? (2024)

  • Forums
  • Homework Help
  • Engineering and Comp Sci Homework Help
  • Thread starterjadelsky
  • Start date
  • Tags
    Contour plotMatlabPlot

In summary, the task at hand is to plot an electric field in the range of 200m around a base station with an EIRP of 57.5dBm, a gain of 1, and an N value of 4. The equation for calculating the electric field is E=[2*sqrt(30*N*P*G)]/r, with P=10exp[(EIRP-30)/10]. The attempt at a solution involved using the meshgrid function in MATLAB to plot the field, but the result was not satisfactory. The poster is open to suggestions for alternative methods and also needs help incorporating the gain value into the equation to achieve a non-symmetrical result.

  • #1

jadelsky

13
0

Homework Statement

I need to plot an electric field in some range around base station, for example in range of 200m.

EIRP=57,5dBm
G=1 for the first example
N=4

Homework Equations

E=[2*sqrt(30*N*P*G)]/r
P=10exp[(EIRP-30)/10]
EIRP=57,5dBm
G=1 for the first example
N=4

The Attempt at a Solution

[X,Y] = meshgrid(-200:.50:200,-200:.50:200);
E=520./sqrt(X.^2+Y.^2);
contour(X,Y,E);

so when i calculate the numerator it's around 520 so i just placed it directly, and in the denominator part i placed sqrt(X.^2+Y.^2) so it's the result for any distance from the station in this range from 0 to 200...the result i get is not good, i used contour plot, I'm really not that familiar with plotting in MATLAB so this is the first option i thought will work (maybe there are better options?)...in the attached file i made a snapshot of my result and the result of some other example...my result should look something like that...

I would appreciate any help very much...Thanks!

Attachments

  • #2

jadelsky

13
0

and also i should include G (gain) in the equation so it all don't come out symetric but i got no idea how should i do it...

1. What is a contour plot in Matlab?

A contour plot in Matlab is a graphical representation of a 3-dimensional surface in two dimensions. It is created by plotting points on a grid and connecting them with lines that represent points with the same value on the surface. This allows for visualization of changes in the surface over a range of values.

2. How do I create a contour plot in Matlab?

To create a contour plot in Matlab, you can use the "contour" or "contourf" function. The "contour" function creates a contour plot with lines, while the "contourf" function creates a filled contour plot. Both functions require the input of the x-coordinates, y-coordinates, and z-values of the points on the surface. You can also add labels, titles, and a colorbar to your contour plot for better visualization.

3. How do I customize my contour plot in Matlab?

You can customize your contour plot in Matlab by changing the number of levels, the color scheme, the line style, and the axis limits. You can also add grid lines, change the font and size of labels and titles, and add annotations or text to your plot. Additionally, you can use the "colormap" function to create a custom color scheme for your contour plot.

4. Can I add multiple contour plots in one figure in Matlab?

Yes, you can add multiple contour plots in one figure in Matlab by using the "hold on" function. This allows you to plot multiple contour plots on the same axes, making it easier to compare and analyze different surfaces or data sets. You can also use the "subplot" function to create a grid of smaller contour plots within one figure.

5. How can I export my contour plot from Matlab?

To export your contour plot from Matlab, you can use the "print" function. This allows you to save your plot as an image file (such as PNG, JPEG, or TIFF) or as a vector graphics file (such as EPS or PDF). You can also copy and paste your contour plot directly into other programs, such as Microsoft Word or PowerPoint, by using the "Edit" menu in the figure window.

Similar threads

Comp SciOrbit of Earth: Plotting Trajectory

  • Engineering and Comp Sci Homework Help
    Replies
    6
    Views
    864

    Creating Plots using Matlab For Interpolation

    • Calculus and Beyond Homework Help
      Replies
      10
      Views
      991

      MATLABHow to plot an orbit around the Earth in MATLAB

      • MATLAB, Maple, Mathematica, LaTeX
        Replies
        2
        Views
        2K

        MATLABHow to plot flow data from an orifice in MATLAB without overlapping the plots?

        • MATLAB, Maple, Mathematica, LaTeX
          Replies
          2
          Views
          1K

          MathematicaPlotting a parameter Plane of a spring pendulum in Mathematica

          • MATLAB, Maple, Mathematica, LaTeX
            Replies
            1
            Views
            1K

            How to plot out a triangular wave in matlab

            • Engineering and Comp Sci Homework Help
              Replies
              1
              Views
              2K

              Matlab: arrays, matrices, and rotating plots

              • Engineering and Comp Sci Homework Help
                Replies
                13
                Views
                2K

                How Can MATLAB Help in Plotting the Electric Field of a Charged Wire?

                • Engineering and Comp Sci Homework Help
                  Replies
                  1
                  Views
                  6K

                  How to display variables on MATLAB plots

                  • Engineering and Comp Sci Homework Help
                    Replies
                    1
                    Views
                    2K

                    Matlab, how to know time step size in the plot or how can i get the ou

                    • Engineering and Comp Sci Homework Help
                      Replies
                      1
                      Views
                      3K
                      • Forums
                      • Homework Help
                      • Engineering and Comp Sci Homework Help
                      How Do I Correctly Plot an Electric Field Around a Base Station Using MATLAB? (2024)

                      References

                      Top Articles
                      Latest Posts
                      Article information

                      Author: Nathanial Hackett

                      Last Updated:

                      Views: 5988

                      Rating: 4.1 / 5 (52 voted)

                      Reviews: 83% of readers found this page helpful

                      Author information

                      Name: Nathanial Hackett

                      Birthday: 1997-10-09

                      Address: Apt. 935 264 Abshire Canyon, South Nerissachester, NM 01800

                      Phone: +9752624861224

                      Job: Forward Technology Assistant

                      Hobby: Listening to music, Shopping, Vacation, Baton twirling, Flower arranging, Blacksmithing, Do it yourself

                      Introduction: My name is Nathanial Hackett, I am a lovely, curious, smiling, lively, thoughtful, courageous, lively person who loves writing and wants to share my knowledge and understanding with you.