Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsC
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le
message de news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." <nicolas.bruot@adresse.bidon.com> a écrit dans le
message de news: eVhKjuK$DHA.808@TK2MSFTNGP12.phx.gbl...
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsC
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le
message de news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le message de
news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." <nicolas.bruot@adresse.bidon.com> a écrit dans le message de
news: eVhKjuK$DHA.808@TK2MSFTNGP12.phx.gbl...
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsC
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le message de
news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
:O)))))
"garnote" a écrit dans le message de
news:ppt%b.79152$Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le message
de
news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autresformes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
:O)))))
"garnote" <rien@absent.net> a écrit dans le message de
news:ppt%b.79152$2g.56014@charlie.risq.qc.ca...
Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." <nicolas.bruot@adresse.bidon.com> a écrit dans le message
de
news: eVhKjuK$DHA.808@TK2MSFTNGP12.phx.gbl...
Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autres
formes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsC
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
Pffff....
même pas peur .....
t'aurais pu te fouler un peu plus ....
bouge même pô !!!!!
:O)))))
"garnote" a écrit dans le message de
news:ppt%b.79152$Salut Nicolas,
Et comme mon graphqiue ne contient qu'une série,
il faudrait ajouter :
k = WorksheetFunction.Min(k, 32000)
Est-ce encore 32 000, le nombre de points
maximal d'une série (2002-2003) ?
et renommer la macro «Famille de virus».
:-)
Serge
"Nicolas B." a écrit dans le message
de
news: eVhKjuK$Inoffensif comme virus, mais excellent !
:-)
On peut même changer les coefficients des fonctions pour obtenir
d'autresformes.
A+
--
Nicolas B.
Adresse @adresse.bidon.com invalide,
E-mail : www.cerbermail.com/?gAAILfkPsCBonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
-----Original Message-----
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
.
-----Original Message-----
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
.
-----Original Message-----
Bonsoir,
Je viens de programmer mon premier virus :-)))
Sub Virus()
Application.ScreenUpdating = False
Sheets.Add
Dim table(1 To 50000, 1 To 2)
For c1 = -1.5 To 1.5 Step 0.015
For c2 = -1.5 To 1.5 Step 0.015
x = c1: y = c2:
For i = 1 To 10
x1 = x ^ 3 - 3 * x * y ^ 2 + 0.5
y1 = 3 * x ^ 2 * y - y ^ 3
If Abs(x1) > 10 Or Abs(y1) > 10 Or _
x1 ^ 2 + y1 ^ 2 > 100 Then GoTo 10
x = x1
y = y1
Next i
10:
If Abs(x1) < 10 Or Abs(y1) < 10 Then
k = k + 1
table(k, 1) = c1
table(k, 2) = c2
End If
Next c2
Next c1
Range(Cells(1, 1), Cells(k, 2)).Value = table
Set ici = Range(Cells(1, 1), Cells(k, 2))
Charts.Add
With ActiveChart
.ChartType = xlXYScatter
.SetSourceData Source:=ici, _
PlotBy:=xlColumns
.Location Where:=xlLocationAsNewSheet
.HasLegend = False
.PlotArea.ClearFormats
.PlotArea.Interior.ColorIndex = 3
.Axes(xlValue).MajorGridlines.Delete
.Axes(xlValue).Delete
.Axes(xlCategory).Delete
End With
With ActiveChart.SeriesCollection(1)
.MarkerBackgroundColorIndex = 4
.MarkerStyle = xlCircle
.Smooth = False
.MarkerSize = 8
.Shadow = False
End With
ActiveChart.Deselect
End Sub
Serge
.