text:
Wikibooks:Reading room/Archives/2021/September

New book on Abacus Traditional Methods
Hello all,

This summer I have been working on a project (Abacus Traditional Methods) in my Sandbox and it is slowly approaching completion. I plan to move it to the main namespace soon as I think that in its current state it may already be useful. But first I must decide on the final title, perhaps something like "Traditional Abacus and Bead Arithmetic".

Since I am new here, before proceeding with such step, I would like to consult a few things with you:
 * First, I would greatly appreciate if an expert could take a look at the project to make sure it conforms to WikiBooks policies and guidelines.
 * About the bookshelves,
 * the book deals with a well known chapter in the history of mathematics in East Asia, so it fits "Shelf:Mathematics history" without trouble, I think.
 * it also deals with arithmetic, but not so elementary as to include it in "Shelf:Elementary arithmetic" if it deals with cube roots, so I am reluctant to such inclusion.
 * Unfortunately I do not see any other shelf like: "Shelf:Computation history" or "Shelf:Computing instruments" or so. I guess I'm not the one who has to create shelves.
 * Do you have any suggestions on this?

 * Also, as you can see, I am not a native speaker, so the book should be completely revised to ensure its linguistic accuracy. Once I move the project to the main namespace, I plan to ask for the collaboration of fellow members of the Soroban and Abacus Group, a group that has been discussing the abacus for some 20 years. Many of its members have a lot to say about the subject of this book and some of them are native speakers. But unsure about the degree of assistance I can get from them, how can I additionally request the collaboration of other wikibookians?

Any comments will be welcome.

Thank you very much!,

Jccsvq (discuss • contribs) 04:56, 27 August 2021 (UTC)
 * I went ahead and made Shelf:History of Computation if that helps. --Mbrickn (discuss • contribs) 16:55, 27 August 2021 (UTC)
 * I just skimmed it and know almost nothing about the abacus (Until I take a more closer read of course!), but overall formatting looks good to me. As far as the note about content from your website goes, I'm unsure if that needs to be cleared through some process similar to the Volunteer Response Team or anything like that. --Mbrickn (discuss • contribs) 17:10, 27 August 2021 (UTC)
 * Thank you very much! I'm certainly going to use the new shelf.
 * Regarding your second comment, I am not sure I understand it as I am seeing "Volunteer Response Team" for the first time. If the concern is about copyright, all the content of my website is under a Creative Commons 0 or Public Domain license, as it is expressly indicated in each page and document of the web, and anyone (including me!) is granted the right to reuse it in any way without restriction, for example, to adapt it as a textbook and create a new work for WikiBooks. I see no problem in this. Jccsvq (discuss • contribs) 04:49, 28 August 2021 (UTC)
 * Oh there's no problem with using CC0 content. All that the VRT does is confirm that the content was available under that license at the time of import, but I'm not sure if Wikibooks has a similar mechanism. I'm out of my depth in this knowledge, and it's probably not required if I can't find documentation on it. Someone more experienced like would know more. --Mbrickn (discuss • contribs) 22:02, 30 August 2021 (UTC)
 * Yes we typically request an email to the VRT with appropriate evidence of ownership. However, if the material is published under a compatible license we don't ask for evidence that any source that preceded that publication was licensed correctly. QuiteUnusual (discuss • contribs) 07:55, 31 August 2021 (UTC)
 * Thank you both very much. It seems like there is no problem. Anyway, I plan to add a link to the book on my website as soon as I move it to the main namespace. This will at least prove that the owner of the material (me, anyway) knows about its use on WikiBooks and recommends visiting it. Jccsvq (discuss • contribs) 04:12, 1 September 2021 (UTC)

The 2022 Community Wishlist Survey will happen in January
Hello everyone,

We hope all of you are as well and safe as possible during these trying times! We wanted to share some news about a change to the Community Wishlist Survey 2022. We would like to hear your opinions as well.

Summary:

We will be running the Community Wishlist Survey 2022 in January 2022. We need more time to work on the 2021 wishes. We also need time to prepare some changes to the Wishlist 2022. In the meantime, you can use a dedicated sandbox to leave early ideas for the 2022 wishes.

Proposing and wish-fulfillment will happen during the same year
In the past, the Community Tech team has run the Community Wishlist Survey for the following year in November of the prior year. For example, we ran the Wishlist for 2021 in November 2020. That worked well a few years ago. At that time, we used to start working on the Wishlist soon after the results of the voting were published.

However, in 2021, there was a delay between the voting and the time when we could start working on the new wishes. Until July 2021, we were working on wishes from the Wishlist for 2020.

We hope having the Wishlist 2022 in January 2022 will be more intuitive. This will also give us time to fulfill more wishes from the 2021 Wishlist.

Encouraging wider participation from historically excluded communities
We are thinking how to make the Wishlist easier to participate in. We want to support more translations, and encourage under-resourced communities to be more active. We would like to have some time to make these changes.

A new space to talk to us about priorities and wishes not granted yet
We will have gone 365 days without a Wishlist. We encourage you to approach us. We hope to hear from you in the talk page, but we also hope to see you at our bi-monthly Talk to Us meetings! These will be hosted at two different times friendly to time zones around the globe.

We will begin our first meeting September 15th at 23:00 UTC. More details about the agenda and format coming soon!

Brainstorm and draft proposals before the proposal phase
If you have early ideas for wishes, you can use the new Community Wishlist Survey sandbox. This way, you will not forget about these before January 2022. You will be able to come back and refine your ideas. Remember, edits in the sandbox don't count as wishes!

Feedback

 * What should we do to improve the Wishlist pages?
 * How would you like to use our new sandbox?
 * What, if any, risks do you foresee in our decision to change the date of the Wishlist 2022?
 * What will help more people participate in the Wishlist 2022?

Answer on the talk page (in any language you prefer) or at our Talk to Us meetings.

SGrabarczuk (WMF) (talk) 00:23, 7 September 2021 (UTC)

Results for the 2021 Wikimedia Foundation Board of Trustees election

 * Read in other languages

Thank you to everyone who participated in the 2021 Board election. The Elections Committee has reviewed the votes of the 2021 Wikimedia Foundation Board of Trustees election, organized to select four new trustees. A record 6,873 people from across 214 projects cast their valid votes. The following four candidates received the most support:

 * 1) Rosie Stephenson-Goodknight
 * 2) Victoria Doronina
 * 3) Dariusz Jemielniak
 * 4) Lorenzo Losa

While these candidates have been ranked through the community vote, they are not yet appointed to the Board of Trustees. They still need to pass a successful background check and meet the qualifications outlined in the Bylaws. The Board has set a tentative date to appoint new trustees at the end of this month.

Read the full announcement here. Xeno (WMF) (discuss • contribs) 01:56, 9 September 2021 (UTC)

Call for Candidates for the Movement Charter Drafting Committee ending 14 September 2021
Movement Strategy announces the Call for Candidates for the Movement Charter Drafting Committee. The Call opens August 2, 2021 and closes September 14, 2021.

The Committee is expected to represent diversity in the Movement. Diversity includes gender, language, geography, and experience. This comprises participation in projects, affiliates, and the Wikimedia Foundation.

English fluency is not required to become a member. If needed, translation and interpretation support is provided. Members will receive an allowance to offset participation costs. It is US$100 every two months.

We are looking for people who have some of the following skills:

 * Know how to write collaboratively. (demonstrated experience is a plus)
 * Are ready to find compromises.
 * Focus on inclusion and diversity.
 * Have knowledge of community consultations.
 * Have intercultural communication experience.
 * Have governance or organization experience in non-profits or communities.
 * Have experience negotiating with different parties.

The Committee is expected to start with 15 people. If there are 20 or more candidates, a mixed election and selection process will happen. If there are 19 or fewer candidates, then the process of selection without election takes place.

Will you help move Wikimedia forward in this important role? Submit your candidacy here. Please contact strategy2030wikimedia.org with questions.

This message may have been sent previously - please note that the deadline for candidate submissions was extended and candidacies are still being accepted until 14 September 2021. Xeno (WMF) 17:16, 10 September 2021 (UTC)

Server switch
Read this message in another language •

The Wikimedia Foundation tests the switch between its first and secondary data centers. This will make sure that Wikipedia and the other Wikimedia wikis can stay online even after a disaster. To make sure everything is working, the Wikimedia Technology department needs to do a planned test. This test will show if they can reliably switch from one data centre to the other. It requires many teams to prepare for the test and to be available to fix any unexpected problems.

They will switch all traffic back to the primary data center on Tuesday, 14 September 2021.

Unfortunately, because of some limitations in MediaWiki, all editing must stop while the switch is made. We apologize for this disruption, and we are working to minimize it in the future.

You will be able to read, but not edit, all wikis for a short period of time.

 * You will not be able to edit for up to an hour on Tuesday, 14 September 2021. The test will start at 14:00 UTC (07:00 PDT, 10:00 EDT, 15:00 WEST/BST, 16:00 CEST, 19:30 IST, 23:00 JST, and in New Zealand at 02:00 NZST on Wednesday, 15 September).
 * If you try to edit or save during these times, you will see an error message. We hope that no edits will be lost during these minutes, but we can't guarantee it. If you see the error message, then please wait until everything is back to normal. Then you should be able to save your edit. But, we recommend that you make a copy of your changes first, just in case.

Other effects:

 * Background jobs will be slower and some may be dropped. Red links might not be updated as quickly as normal. If you create an article that is already linked somewhere else, the link will stay red longer than usual. Some long-running scripts will have to be stopped.
 * We expect the code deployments to happen as any other week. However, some case-by-case code freezes could punctually happen if the operation require them afterwards.

This project may be postponed if necessary. You can read the schedule at wikitech.wikimedia.org. Any changes will be announced in the schedule. There will be more notifications about this. A banner will be displayed on all wikis 30 minutes before this operation happens. Please share this information with your community. SGrabarczuk (WMF)  00:45, 11 September 2021 (UTC)

Talk to the Community Tech

Read this message in another language •

Hello!

As we have recently announced, we, the team working on the Community Wishlist Survey, would like to invite you to an online meeting with us. It will take place on September 15th, 23:00 UTC on Zoom, and will last an hour. Click here to join.

Agenda

 * How we prioritize the wishes to be granted
 * Why we decided to change the date from November 2021 to January 2022
 * Update on the disambiguation and the real-time preview wishes
 * Questions and answers

Format

The meeting will not be recorded or streamed. Notes without attribution will be taken and published on Meta-Wiki. The presentation (first three points in the agenda) will be given in English.

We can answer questions asked in English, French, Polish, and Spanish. If you would like to ask questions in advance, add them on the Community Wishlist Survey talk page or send to sgrabarczuk@wikimedia.org.

Natalia Rodriguez (the Community Tech manager) will be hosting this meeting.

Invitation link

 * Join online
 * Meeting ID: 898 2861 5390
 * One tap mobile
 * +16465588656,,89828615390# US (New York)
 * +16699006833,,89828615390# US (San Jose)
 * Dial by your location

See you! SGrabarczuk (WMF) 03:03, 11 September 2021 (UTC)

Links and tables
Hi, Documents for links indicate that text with an alt parameter will be displayed when a File is not available from Commons. In Oberon/ETH_Oberon/Tutorial/Mouse under heading "Select - Mouse Right key - MR" "File:OberonMouse4.png" is not available. Shouldn't the alt text be displayed?

At the bottom of the same page are two tables; aqua and yellow. How can the yellow table be located beside the aqua rather than below? Thx, ... PeterEasthope (discuss • contribs) 20:04, 17 September 2021 (UTC)
 * Explanations received in Wikipedia Teahouse. Regards, ... PeterEasthope (discuss • contribs) 16:57, 25 September 2021 (UTC)


text: Category:Book:A Guide to SpaceX's Starship

license: Creative Commons - Attribution Share-Alike - https://creativecommons.org/licenses/by-sa/4.0/


text:
Talk:Public International Law/Methodology/Interdisciplinarity

Review: May 20, 2023
Dear Silvia and Tamsin,

Thank you both so much for doing an absolutely stellar job and contributing a chapter that will be one of the many things that make our textbook stand out among others. I have added a number of comments in the text regarding, mainly, some suggestions for restructuring (especially the IL and Language / IL and Literature and the IL and Ecomonics / IL and Psychology part) and some additional suggestions for scholarship you could highlight, but these are all 'nice to have'. Please don't feel pressured to address all of them in the short period of time that's still left (sorry for not managing to do this in-depth review earlier), but I still wanted to add them in case you found them helpful.

The summary (we are still calling it 'conclusion' in the heading, even though we have been debating if we should change this for all chapters) is still missing.

Warmly, Sué Sué González Hauck (discuss • contribs) 20:14, 20 May 2023 (UTC)

Review: May 12, 2023
The chapter provides an in-depth analysis of interdisciplinary research methods, highlighting both the benefits and potential drawbacks of such approaches. The chapter is well-written and easy to understand, making it accessible to students of all levels. The chapter is exceptional. You do an excellent job of outlining the various interdisciplinary methods used in social sciences, providing both theoretical and practical examples. The use of research in each sub-area to demonstrate the application of interdisciplinary methods is a great idea, making the chapter more tangible and applicable. You also stress the importance of understanding the potential risks of interdisciplinary research methods. The further readings included in the chapter are diverse and comprehensive, providing students with a wealth of information to deepen their understanding.

At times, the chapter can be repetitive, particularly in the sections discussing the "how to" of applying interdisciplinary methods. Shortening these sections would improve the flow of the chapter.

You will find some comments in your chapter in which I elaborate on something more specifically. To view these comments, just open you chapter page and click on "Edit" in the top-right toolbox.

Note also that the following parts are still missing: required knowledge, learning objectives, summary

Some footnotes are not formatted according to OSCOLA.

Max Milas (discuss • contribs) 08:02, 12 May 2023 (UTC)

This strikes me as an ideal structure for a chapter on interdisciplinary approaches, with just one exception. I do not see a section on law and philosophy in this chapter. This is surprising because the philosophy of international law is a major contemporary field and also, arguably, the first true instance of interdisciplinary writing on the subject (Grotius etc). With that small addition, however, I am happy that this is good to go. GlexAreen-York (discuss • contribs) 12:59, 29 October 2021 (UTC)


text:
Open Pedagogy/Team work and team assignments

This will be the page where my students will upload their info.


text:
User:Dinginto

I am a love able person funny out going and some times I am a doctor who saves people's lives if you want to be like me you must carry on with what you started and carry on never be hopeless never lose hope be hopeful and be proud of your work all you have to do is to trust in God maybe one day you will get what you have been asking for in your whole entire life be happy for who you are.

title: User:Dinginto


text:
International Relations/Liberal International Theory vs. International Realism Theory

The two modern major schools of International Relations theory are /International Liberal Theory/ and /International Realism Theory/.

Liberal theory is often marked by an analysis of an ideal, or utopian, outcome. Realist theory, however, focuses on the ways and means that states interact. An excellent discussion on the differences of the natures of these two theories can be found in Edwards H. Carr's "The Twenty Years' Crisis, 1919-1939" (he uses the term 'utopianism' for 'liberalism') or in Hans Morgenthau's "Politics Among Nations."

Realists often credit Thucydides as the first realist thinker for his desire to leave an account of war as a "possession for all time," his writing style in which he was only concerned with facts from reliable sources, and for his concentration on power in "The History of the Peloponnesian War." The Melian Dialogue is often given extra attention due to the unique use of dialogue, leading many to believe that Thucydides is trying to highlight an important event. From this comes the quote "The strong do what they have the power to do and the weak accept what they must," expressing the realist theme of might-equals-right. However, for an interesting look at the worldview that shaped Thucydides' writing, see RG Collingwood's "The Idea of History."

Realism has traditionally focused on power, and in the Westphalian state system, the state is seen as having the most power. Because it is concerned with power, realism has tended to focus more on high politics than low politics. However, with most wars since the early 1990s being fought within states instead of between states, this is currently being redefined within realism.

Other formative thinkers in the realist tradition include:
 * St Augustine of Hippo (The City of God)
 * Niccolò Machiavelli (The Prince)
 * Thomas Hobbes (Leviathan)
 * Carl Schmitt (Concept of the Political)
 * Hans Morgenthau (Politics Among Nations)
 * Henry Kissinger
 * Hedley Bull (The Anarchical Society)
 * Kenneth Waltz
 * John Mearsheimer (The Tragedy of Great Power Politics)

Liberalism (also called "Idealism" pejoratively) gained popularity following the end of World War I and the triumph of Wilsonian liberalism. Liberalism in international relations theory is generally associated with internationalism, institutionalism, and socialism. Essentially, they believe human nature is good, war can be avoided, and there is a moral universalism. They do not trace a long history of their theory, like realists do. Key themes include international law, sovereignty, international organisations, and global governance.

Formative thinkers in the liberal tradition include:
 * Francisco de Vitoria & the School of Salamanca (De Indis debates)
 * Immanuel Kant (Perpetual Peace) Perpetual_Peace
 * Vladimir Lenin (Imperialism: The Highest Stage of Capitalism)
 * David Held (Democracy and the Global Order)


text: User:Lapalalalaal

title: User:Lapalalalaal


text:
Maxima/Weaknesses of math software

While Maxima is a very useful software, it suffers from the same issues faced by many other math programs.

 * The limit of a discontinuous function at the point of discontinuity
 * Branch cuts
 * Zero-recognition
 * Keeping track of domains of validity

title: Maxima/Weaknesses of math software


text:
Maxima/Methods of use

Maxima is flexible software, and can be used with a number of different methods:
 * online, without installation
 * offline = after installation
 * Graphical User Interface (GUI)
 * from console ( without GUI)
 * interactive ( also one can load program files using load or bash function)
 * bash mode

Run maxima, use program c.mac and save output to c.txt file:

maxima -b c.mac >c.txt

title: Maxima/Methods of use


text:
Maxima/Installation

Dependencies

 * gnuplot,
 * tex
 * texinfo
 * texi2html
 * texlive-latex-recommended
 * GNU autotools
 * automake 1.9
 * autoconf2.13
 * tk 8.4.
 * lisp
 * sbcl ( sudo apt-get install sbcl)
 * libgmp3-dev
 * libreadline5-dev
 * libncurses5-dev
 * sharutils
 * libxmu-dev
 * libxaw7-dev
 * wxWidgets library for wxMaxima
 * libwxgtk3.0-dev
 * libwxbase3.0-dev
 * compiler is GNU g++ for wxWidgets library
 * build-essential
 * imagemagick
 * ibus-gtk
 * ibus-gtk3

Steps

 * Download and install ready made Maxima deb packages
 * from Ubuntu repositories ( old versions )
 * from other sites
 * Compile your own maxima package
 * compile maxima from sources ( without creating deb packages )

Now the best is a git method

From Ubuntu repositories
You can make use of :
 * Synaptic ( Graphical package manager)
 * apt-get.

In second case write in command line:

sudo apt-get install maxima

This method can get old version which gets some trouble, like loadfile: failed to load /usr/share/maxima/5.37.2/share/draw/draw.lisp

Uninstall such Maxima version

sudo apt-get remove maxima

wxmaxima
From repositiories by Istvan Balhota sudo add-apt-repository ppa:blahota/wxmaxima sudo apt-get update sudo apt-get install wxmaxima

From sources
Before compilation, you should have all dependent packages

CVS
cd maxima ./bootstrap   # only if you downloaded the source code from cvs ./configure --enable-clisp  # or:   --enable-sbcl make make check sudo make install make clean

This procedure does not create a deb package.

maxima/xmaxima
If you have git and SBCL then : git clone git://git.code.sf.net/p/maxima/code maxima cd maxima ./bootstrap ./configure --with-sbcl make

Now one can run it from inside the source directory.

cd maxima ./maxima-local

The result :

Maxima branch_5_30_base_104_ged70fb2_dirty http://maxima.sourceforge.net using Lisp SBCL 1.0.45.0.debian Distributed under the GNU Public License. See the file COPYING. Dedicated to the memory of William Schelter. The function bug_report provides bug reporting information. (%i1)

Xmaxima can also be run :

cd ~/maxima ./xmaxima-local

or bash file :

wxMaxima is not present now.

Where is Maxima after standard ( as above) installation ?

locate maxima-local

example result :

~/Pobrane/maxima-5.38.1/maxima-local.in ~/Pobrane/maxima-5.38.1/xmaxima-local.in  ~/maxima/maxima-local ~/maxima/maxima-local.in ~/maxima/xmaxima-local ~/maxima/xmaxima-local.in ~/maxima/interfaces/xmaxima/Tkmaxima/maxima-local.tcl

Note that it is a different directory then after apt-get installation. One can have 2 ( or more ) versions of Maxima on the disk )

wxmaxima
git clone https://github.com/wxMaxima-developers/wxmaxima

Problems

 * Open a terminal
 * type :  sudo apt-get install gdb
 * after gdb is installed type : gdb wxmaxima
 * run and wait until it crashes
 * and type : backtrace

title: Maxima/Installation


text:
Maxima/Symbols

 * symbols %z7 and %z9 represent any arbitrary integer value.

title: Maxima/Symbols


text:
Maxima/Operators

"=" means syntactic equality. Check : is(equal(a,b))

title: Maxima/Operators


text:
Maxima/Names

"One quick way to check on name conflicts is to keep the html Maxima help manual up in a separate window, and have the Index panel available to type in a name you want to use.    The painful way to check on name conflicts is to wait for Maxima to give you a strange error message as to why what you are trying to do won’t work. If you get strange results, try changing the names of your variables and or functions. An important fact is that Maxima is case sensitive, so  you can avoid name conflicts by capitalizing the names of your user defined Maxima functions. Your Solve will not conflict with Maxima’s solve." Edwin L. Woollett

title: Maxima/Names


text:
Maxima/Variables

 * global
 * global variables category
 * local

title: Maxima/Variables


text:
Maxima/Objects

 * atom
 * number
 * name
 * string
 * list of atoms

title: Maxima/Objects


text:
Maxima/Data types

 * Numbers
 * Strings
 * Constants
 * Lists
 * Arrays
 * Structures

title: Maxima/Data types


text:
Maxima/Features

Maxima recognizes certain mathematical properties of:
 * functions and variables
 * system. There is a list of non-mathematical, system-dependent features. See status.

which called features.

declare (x, foo) /* gives the property foo to the function or variable x */

declare (foo, feature) /* declares a new feature foo. */

declare ([red, green, blue], feature) /* declares three new features, red, green, and blue. */

The predicate

featurep (x, foo)

returns true if x has the foo property, and false otherwise.

The infolist features is a list of known features. These are integer       noninteger      even odd           rational        irrational real          imaginary       complex analytic      increasing      decreasing oddfun        evenfun         posfun constant      commutative     lassociative rassociative  symmetric       antisymmetric integervalued plus any user-defined features.

features is a list of mathematical features.

Example: (%i1) declare (FOO, feature); (%o1)                        done (%i2) declare (x, FOO); (%o2)                        done (%i3) featurep (x, FOO); (%o3)                        true

Declare
declare recognizes the following properties:
 * additive : Tells Maxima to simplify a_i expressions by the substitution a_i(x + y + z + ...) --> a_i(x) + a_i(y) + a_i(z) + .... The substitution is carried out on the first argument only.
 * alphabetic : Tells Maxima to recognize all characters in a_i (which must be a string) as alphabetic characters.
 * antisymmetric, commutative, symmetric : Tells Maxima to recognize a_i as a symmetric or antisymmetric function. commutative is the same as symmetric.
 * bindtest : Tells Maxima to trigger an error when a_i is evaluated unbound.
 * constant : Tells Maxima to consider a_i a symbolic constant.
 * even, odd : Tells Maxima to recognize a_i as an even or odd integer variable.
 * evenfun, oddfun : Tells Maxima to recognize a_i as an odd or even function.
 * evflag : Makes a_i known to the ev function so that a_i is bound to true during the execution of ev when a_i appears as a flag argument of ev. See evflag.
 * evfun : Makes a_i known to ev so that the function named by a_i is applied when a_i appears as a flag argument of ev. See evfun.
 * feature : Tells Maxima to recognize a_i as the name of a feature. Other atoms may then be declared to have the a_i property.
 * increasing, decreasing : Tells Maxima to recognize a_i as an increasing or decreasing function.
 * integer, noninteger : Tells Maxima to recognize a_i as an integer or noninteger variable.
 * integervalued : Tells Maxima to recognize a_i as an integer-valued function.
 * lassociative, rassociative : Tells Maxima to recognize a_i as a right-associative or left-associative function.
 * linear : Equivalent to declaring a_i both outative and additive.
 * mainvar : Tells Maxima to consider a_i a "main variable". A main variable succeeds all other constants and variables in the canonical ordering of Maxima expressions, as determined by ordergreatp.
 * multiplicative : Tells Maxima to simplify a_i expressions by the substitution a_i(x * y * z * ...) --> a_i(x) * a_i(y) * a_i(z) * .... The substitution is carried out on the first argument only.
 * nary : Tells Maxima to recognize a_i as an n-ary function. The nary declaration is not the same as calling the nary function. The sole effect of declare(foo, nary) is to instruct the Maxima simplifier to flatten nested expressions, for example, to simplify foo(x, foo(y, z)) to foo(x, y, z).
 * nonarray : Tells Maxima to consider a_i not an array. This declaration prevents multiple evaluation of a subscripted variable name.
 * nonscalar : Tells Maxima to consider a_i a nonscalar variable. The usual application is to declare a variable as a symbolic vector or matrix.
 * noun : Tells Maxima to parse a_i as a noun. The effect of this is to replace instances of a_i with 'a_i or nounify(a_i), depending on the context.
 * outative : Tells Maxima to simplify a_i expressions by pulling constant factors out of the first argument. When a_i has one argument, a factor is considered constant if it is a literal or declared constant. When a_i has two or more arguments, a factor is considered constant if the second argument is a symbol and the factor is free of the second argument.
 * posfun : Tells Maxima to recognize a_i as a positive function.
 * rational, irrational : Tells Maxima to recognize a_i as a rational or irrational real variable.
 * real, imaginary, complex : Tells Maxima to recognize a_i as a real, pure imaginary, or complex variable.
 * scalar : Tells Maxima to consider a_i a scalar variable.

Declare tells: what to return.
 * evenp
 * oddp
 * integerp
 * and so on

Compare with:
 * mode_decalre

title: Maxima/Features


text:
Maxima/Numbers

Check
(%i1) load(to_poly); (%o1) home/a/maxima/share/to_poly_solve/to_poly.lisp (%i2) r; (%o2) r (%i3) isreal_p(r); (%o3) true    /*  When I use unspecified variables, Maxima seems to assume that they are real */ (%i4) z:x+y*%i; (%o4) %i y + x (%i5) isreal_p(z); (%o5) isreal_p(%i y) /* maxima can't check if it is real or not */ (%i6) isreal_p(x); (%o6) true (%i7) isreal_p(y); (%o7) true (%i8) complex_number_p(z); (%o8) false (%i9) declare(z, complex); (%o9) done (%i10) complex_number_p(z); (%o10)  false /* still not complex */                                                                                true

Random numbers
bfloat(random(10^fpprec) / 10^fpprec); /* random bfloat with fpprec decimal digits in the range 0 to 1 */

Binary numbers
(%i1) ibase; (%o1) 10 (%i2) obase; (%o2) 10 (%i3) ibase:2; (%o3) 2 (%i4) x=1001110; (%o4) x=78

Argument
Principial value of argument of complex number in turns carg produces results in the range (-pi, pi] . It can be mapped to [0, 2*pi) by adding 2*pi to the negative values

carg_t(z):= block( [t],  t:carg(z)/(2*%pi),  /* now in turns */  if t<0 then t:t+1, /* map from (-1/2,1/2] to [0, 1) */  return(t) )$ On can order list of complex points according to it's argument : l2_ordered: sort(l2, lambda([z1,z2], is(carg(z1) < carg(z2))))$

rational numbers

 * rat
 * ratp

Rationalize with limit denominator:

limit_denominator(x, max_denominator):= block([p0, q0, p1, q1, n, d, a, q2, k, bound1, bound2, ratprint: false], [p0, q0, p1, q1]: [0, 1, 1, 0],  [n, d]: ratexpand([ratnum(x), ratdenom(x)], 0),  if d <= max_denominator then x else  (catch(    do block( a: quotient(n, d), q2: q0+a*q1, if q2 > max_denominator then throw('done), [p0, q0, p1, q1]: [p1, q1, p0+a*p1, q2], [n, d]: [d, n-a*d])), k: quotient(max_denominator-q0, q1), bound1: (p0+k*p1)/(q0+k*q1), bound2: p1/q1, if abs(bound2 - x) <= abs(bound1 - x) then bound2 else bound1))$

Predicate functions
(%i1) is(0=0.0); (%o1) false

Compare : (%i1) a:0.0$ (%i2)is(equal(a,0)); (%o2) true

List of predicate functions ( see p at the end ) :
 * abasep
 * alphacharp
 * alphanumericp
 * atom
 * bfloatp
 * blockmatrixp
 * cequal
 * cequalignore
 * cgreaterp
 * cgreaterpignore
 * charp
 * clessp
 * clesspignore
 * complex_number_p from to_poly package
 * constantp
 * constituent
 * diagmatrixp
 * digitcharp
 * disjointp
 * elementp
 * emptyp
 * evenp
 * featurep
 * floatnump ( compare : isreal_p)
 * if
 * integerp
 * intervalp
 * is
 * isreal_p from to_poly package
 * lcharp
 * listp
 * listp
 * lowercasep
 * mapatom
 * matrixp
 * matrixp
 * maybe
 * member
 * nonnegintegerp
 * nonscalarp
 * numberp
 * oddp
 * operatorp
 * ordergreatp
 * orderlessp
 * picture_equalp
 * picturep
 * poly_depends_p
 * poly_grobner_subsetp
 * polynomialp
 * prederror
 * primep
 * ratnump
 * ratp
 * scalarp
 * sequal
 * sequalignore
 * setequalp
 * setp
 * stringp
 * subsetp
 * subvarp
 * symbolp
 * symmetricp
 * taylorp
 * unknown
 * uppercasep
 * zeroequiv
 * zeromatrixp
 * zn_primroot_p

See also :
 * declare
 * property:
 * rational, irrational, real, imaginary, complex,
 * even, odd,
 * decreasing, increasing
 * evenfun, oddfun

Number Theory
There are functions and operators useful with integer numbers

Elementary number theory
In Maxima there are some elementary functions like the factorial n! and the double factorial n!! defined as $$\frac{n!}{k!}$$ where $$k$$ is the greatest integer less than or equal to $$n/2$$

Divisibility
Some of the most important functions for integer numbers have to do with divisibility:

gcd, ifactor, mod, divisors...

all of them well documented in help. you can view it with the '?' command.

Function ifactors takes positive integer and returns a list of pairs : prime factor and its exponent. For example :

a:ifactors(8); 2,3

It means that : $$8 = 2^3\,$$

Other Functions
Continuus fractions :

(%i6) cfdisrep([1,1,1,1]); (%o6) 1+1/(1+1/(1+1/1)) (%i7) float(%), numer; (%o7) 1.666666666666667

title: Maxima/Numbers


text:
Maxima/Functions

Definition
For mathematical functions use always define instead of :=

There is only one small difference between them:

"The function definition operator. f(x_1, ..., x_n) := expr defines a function named f with arguments x_1, …, x_n and function body expr. := never evaluates the function body (unless explicitly evaluated by quote-quote '' )."

"Defines a function named f with arguments x_1, …, x_n and function body expr. define always evaluates its second argument (unless explicitly quoted). "

return
"return doesn't mean the same thing in Maxima as it does in other programming languages. It means only to return a value from a block; that's not enough for what you need here." Robert Dodier

If you wish to make a return from some expression inside the function then you must use block and return.

block ([], expr1, ..., if (a > 10) then return(a), ..., exprn)

is itself an expression, and so could take the place of the right hand side of a function definition. Here it may happen that the return happens earlier than the last expression.

Local variables
block ([x], expr1, ..., exprn)

The first [] in the block, may contain a list of variables and variable assignments, such as [a: 3, b, c: []], which would cause the three variables a,b,and c to not refer to their global values, but rather have these special values for as long as the code executes inside the block, or inside functions called from inside the block. This is called dynamic binding, since the variables last from the start of the block to the time it exits. Once you return from the block, or throw out of it, the old values (if any) of the variables will be restored. It is certainly a good idea to protect your variables in this way. Note that the assignments in the block variables, are done in parallel. This means, that if you had used c: a in the above, the value of c would have been the value of a at the time you just entered the block, but before a was bound. Thus doing something like:

block ([a: a], expr1, ... a: a+3, ..., exprn)

will protect the external value of a from being altered, but would let you access what that value was. Thus the right hand side of the assignments, is evaluated in the entering context, before any binding occurs. Using just block ([x], ...) would cause the x to have itself as value, just as if it would have if you entered a fresh Maxima session.

See also description by Darren Irvine

compile

 * "The modedeclare statement is important for compiled code
 * Compiling can greatly speed numerical code; for mostly symbolic code, the speed up is not great.
 * There are some differences between compiled and uncompiled code -- be careful." Barton Willis

mode_declare
"mode_declare tells the compiler that the compiled code needs not to be generic enough to be able to deal with all kind of objects. If your function only takes floats, but no symbolic arguments the compiled code might run much faster." Gunter Königsmann

title: Maxima/Functions


text:
Maxima/Debugging

Directories
Start Maxima and type the command:

maxima_userdir;

this will tell you the directory that is being used as your user directory.

infolists

 * is a system variable
 * Default value: []
 * is a list of the names of all of the information lists in Maxima. These are
 * labels : All bound %i, %o, and %t labels.
 * values : All bound atoms which are user variables, not Maxima options or switches, created by : or :: or functional binding.
 * functions : All user-defined functions, created by := or define.
 * arrays : All declared and undeclared arrays, created by :, ::, or :=.
 * macros : All user-defined macro functions, created by ::=.
 * myoptions : All options ever reset by the user (whether or not they are later reset to their default values).
 * rules : All user-defined pattern matching and simplification rules, created by tellsimp, tellsimpafter, defmatch, or defrule.
 * aliases : All atoms which have a user-defined alias, created by the alias, ordergreat, orderless functions or by declaring the atom as a noun with declare.
 * dependencies : All atoms which have functional dependencies, created by the depends, dependencies, or gradef functions.
 * gradefs : All functions which have user-defined derivatives, created by the gradef function.
 * props : All atoms which have any property other than those mentioned above, such as properties established by atvalue or matchdeclare, etc., as well as properties established in the declare function.
 * let_rule_packages : All user-defined let rule packages plus the special package default_let_rule_package. (default_let_rule_package is the name of the rule package used when one is not explicitly set by the user.)

reset
reset : resets many (global) system variables

Use:

reset

example output :

(%o1) [_, __, load_pathname, labels, %, linenum, ratprint, tr-unique, lispdisp, multiplicities]

trace
In Maxima : :lisp (setf *debugger-hook* nil)

manual debugging
print partial results using :
 * print
 * playback

values
values:
 * is a system variable
 * is a list ... which contains the names of currently assigned scalar values which have been set by:
 * the user interactively
 * by packages which have been loaded"
 * initial value is []

dependencies
dependencies :
 * is a system variable
 * is the list of atoms which have functional dependencies, assigned by:
 * depends
 * the function dependencies
 * gradef

status
status (feature);

example output: (%o34) [sb-bsd-sockets-addrinfo, cl, mk-defsystem, cltl2, 64-bit, 64-bit-registers, alien-callbacks, ansi-cl, ash-right-vops, c-stack-is-control-stack, common-lisp, compare-and-swap-vops, complex-float-vops, cycle-counter, elf, float-eql-vops, fp-and-pc-standard-save, gencgc, ieee-floating-point, inline-constants, integer-eql-vop, interleaved-raw-slots, largefile, linkage-table, linux, little-endian, memory-barrier-vops, multiply-high-vops, os-provides-blksize-t, os-provides-dladdr, os-provides-dlopen, os-provides-getprotoby-r, os-provides-poll, os-provides-putwc, os-provides-suseconds-t, package-local-nicknames, precise-arg-count-error, raw-instance-init-vops, sb-after-xc-core, sb-core-compression, sb-doc, sb-eval, sb-futex, sb-ldb, sb-package-locks, sb-simd-pack, sb-source-locations, sb-test, sb-thread, sb-unicode, sb-xref-for-internals, sbcl, stack-allocatable-closures, stack-allocatable-fixed-objects, stack-allocatable-lists, stack-allocatable-vectors, stack-grows-downward-not-upward, symbol-info-vops, unix, unwind-to-frame-and-call-vop, x86-64]

title: Maxima/Debugging


text:
Maxima/Data structures

"Maxima's current array/matrix semantics are a mess, I must say, with at least four different kinds of object (hasharrays, explicit lists, explicit matrices, Lisp arrays) supporting subscripting with varying semantics. "

"Maxima's concept of arrays, lists, and matrices is pretty confused, since various ideas have accreted in the many years of the project... Yes, this is a mess. Sorry about that. These are all interesting ideas, but there is no unifying framework. "

Array
Maxima has two array types :
 * Undeclared arrays ( implemented as Lisp hash tables )
 * Declared arrays ( implemented as Lisp arrays )
 * created by the array function
 * created by the make_array function.

Category: Arrays :
 * array
 * arrayapply
 * arrayinfo
 * arraymake
 * arrays - global variable
 * fillarray
 * listarray
 * make_array
 * rearray
 * remarray
 * subvar
 * use_fast_arrays

See also :
 * array functions defined by := and define.

Undeclared array
Assignment creates an undeclared array.

(%i1) c[99] : 789; (%o1)                         789 (%i2) c[99]; (%o2)                         789 (%i3) c; (%o3)                          c (%i4) arrayinfo (c); (%o4)                  [hashed, 1, [99]] (%i5) listarray (c); (%o5)                        [789]

"If the user assigns to a subscripted variable before declaring the corresponding array, an undeclared array is created. Undeclared arrays, otherwise known as hashed arrays (because hash coding is done on the subscripts), are more general than declared arrays. The user does not declare their maximum size, and they grow dynamically by hashing as more elements are assigned values. The subscripts of undeclared arrays need not even be numbers. However, unless an array is rather sparse, it is probably more efficient to declare it when possible than to leave it undeclared. " ( from Maxima CAS doc)

"created if one does :

b[x+1]:y^2

(and b is not already an array, a list, or a matrix - if it were one of these an error would be caused since x+1 would not be a valid subscript for an art-q array, a list or a matrix).

Its indices (also known as keys) may be any object. It only takes one key at a time (b[x+1,u]:y would ignore the u). Referencing is done by b[x+1] ==> y^2. Of course the key may be a list, e.g. bx+1,u:y would be valid. "( from Maxima CAS doc)

Declared array

 * declare array ( give a name and allocate memmory)
 * fill array
 * process array

array function
Function: array (name, type, dim_1, …, dim_n)

Creates an n-dimensional array. Here :
 * type can be fixnum for integers of limited size or flonum for floating-point numbers
 * n may be less than or equal to 5. The subscripts for the i'th dimension are the integers running from 0 to dim_i.

(%i5) array(A,2,2); (%o5)                                 A (%i8) arrayinfo(A); (%o8)                     [declared, 2, [2,2]]

Because subscripts of array A elements are goes from 0 to dim so array A has : ( dim_1 + 1) * (dim_2 + 1) = 3*3 = 9

elements.

The array function can be used to transform an undeclared array into a declared array.

arraymake function
Function: arraymake (A, [i_1, …, i_n])

The result is an unevaluated array reference.

(%i12) arraymake(A,[3,3,3]); (%o12)                   array_make(3, 3, 3) 3, 3, 3 (%i13) arrayinfo(A); arrayinfo: A is not an array.

Function: make_array
Function: make_array (type, dim_1, …, dim_n)

Creates and returns a Lisp array.

Type may be :
 * any
 * flonum
 * fixnum
 * hashed
 * functional.

There are n indices, and the i'th index runs from 0 to dim_i - 1.

The advantage of make_array over array is that the return value doesn't have a name, and once a pointer to it goes away, it will also go away. For example, if y: make_array (...) then y points to an object which takes up space, but after y: false, y no longer points to that object, so the object can be garbage collected.

Examples:

(%i9) A : array_make(3,3,3); (%o9)                        array_make(3, 3, 3) (%i10) arrayinfo(A); (%o10)                    [declared, 3, [3, 3, 3]]

List
Assignment to an element of a list.

(%i1) b : [1, 2, 3]; (%o1)                      [1, 2, 3] (%i2) b[3] : 456; (%o2)                         456 (%i3) b; (%o3)                     [1, 2, 456]

(%i1) mylist : a,b],[c,d; (%o1) a, b], [c, d

Interesting examples by Burkhard Bunk :

lst: [el1, el2, ...];        contruct list explicitly lst[2];                      reference to element by index starting from 1 cons(expr, alist);           prepend expr to alist endcons(expr, alist);        append expr to alist append(list1, list2, ..);    merge lists makelist(expr, i, i1, i2);   create list with control variable i makelist(expr, x, xlist);     create list with x from another list length(alist);               returns #elements map(fct, list);              evaluate a function of one argument map(fct, list1, list2);      evaluate a function of two arguments

Category: Lists :
 * ]
 * append
 * assoc
 * cons
 * copylist
 * create_list
 * delete
 * eighth
 * endcons
 * fifth
 * first
 * flatten
 * fourth
 * fullsetify
 * join
 * last
 * length
 * listarith
 * listp
 * lmax
 * lmin
 * lreduce
 * makelist
 * member
 * ninth
 * permut
 * permutations
 * pop
 * push
 * random_permutation
 * rest
 * reverse
 * rreduce
 * second
 * setify
 * seventh
 * sixth
 * some
 * sort
 * sublist
 * sublist_indices
 * tenth
 * third
 * tree_reduce
 * xreduce
 * xreduce

product
/* example by Burton Willis */ (%i28) P1(s) := rectform(product(s[i],i, 1, length(s)))$

(%i29) P2(s) := xreduce(lambda([a,b], rectform(a*b)),s)$

(%i30) s : makelist(random(1.0)+%i*random(1.0),10^4)$

(%i31) P1(s); Evaluation took 32.3080 seconds (32.3860 elapsed) using 17944.301 MB. (%o31) 0.0

(%i32) P2(s); Evaluation took 0.0620 seconds (0.0620 elapsed) using 8.343 MB. (%o32) 0.0

Matrix
"In Maxima, a matrix is implemented as a nested list (namely a list of rows of the matrix)". E.g. : (($MATRIX) ((MLIST) 1 2 3) ((MLIST) 4 5 6))

Construction of matrices from nested lists :

(%i3) M:matrix([1,2,3],[4,5,6],[0,-1,-2]); [ 1  2    3  ]                                 [             ] (%o3)                           [ 4   5    6  ] [            ]                                 [ 0  - 1  - 2 ]

Interesting examples by Burkhard Bunk :

A: matrix([a, b, c], [d, e, f], [g, h, i]);    /* (3x3) matrix */ u: matrix([x, y, z]);                          /* row vector */ v: transpose(matrix([r, s, t]));               /* column vector */

Reference to elements etc:

u[1,2];                /* second element of u */ v[2,1];                /* second element of v */ A[2,3];  or  A[2][3];  /* (2,3) element */ A[2];                        /* second row of A */ transpose(transpose(A)[2]);  /* second column of A */

Element by element operations:

A + B;     A - B; A * B;       A / B; A ^ s;       s ^ A;

Matrix operations :

A. B;                 /* matrix multiplication */ A ^^ s;                /* matrix exponentiation (including inverse) */ transpose(A); determinant(A); invert(A);

Category: Matrices :
 * addcol
 * addrow
 * adjoint
 * augcoefmatrix
 * cauchy_matrix
 * charpoly
 * coefmatrix
 * col
 * columnvector
 * covect
 * copymatrix
 * determinant
 * detout
 * diag
 * diagmatrix
 * doallmxops
 * domxexpt
 * domxmxops
 * domxnctimes
 * doscmxops
 * doscmxplus
 * echelon
 * eigen
 * ematrix
 * entermatrix
 * genmatrix
 * ident
 * invert
 * list_matrix_entries
 * lmxchar
 * matrix
 * matrix_element_add
 * matrix_element_mult
 * matrix_element_transpose
 * matrixmap
 * matrixp
 * mattrace
 * minor
 * ncharpoly
 * newdet
 * nonscalar
 * nonscalarp
 * permanent
 * rank
 * ratmx
 * row
 * scalarmatrixp
 * scalarp
 * setelmx
 * sparse
 * submatrix
 * tracematrix
 * transpose
 * triangularize
 * zeromatrix

Function: matrix
Function: matrix (row_1, …, row_n)

Returns a rectangular matrix which has the rows row_1, …, row_n. Each row is a list of expressions. All rows must be the same length.

. operator
"The dot operator, for matrix (non-commutative) multiplication. When "." is used in this way, spaces should be left on both sides of it, e.g.

A. B

This distinguishes it plainly from a decimal point in a floating point number.

The operator. represents noncommutative multiplication and scalar product. When the operands are 1-column or 1-row matrices a and b, the expression a.b is equivalent to sum (a[i]*b[i], i, 1, length(a)). If a and b are not complex, this is the scalar product, also called the inner product or dot product, of a and b. The scalar product is defined as conjugate(a).b when a and b are complex; innerproduct in the eigen package provides the complex scalar product.

When the operands are more general matrices, the product is the matrix product a and b. The number of rows of b must equal the number of columns of a, and the result has number of rows equal to the number of rows of a and number of columns equal to the number of columns of b.

To distinguish. as an arithmetic operator from the decimal point in a floating point number, it may be necessary to leave spaces on either side. For example, 5.e3 is 5000.0 but 5. e3 is 5 times e3.

There are several flags which govern the simplification of expressions involving ., namely dot0nscsimp, dot0simp, dot1simp, dotassoc, dotconstrules, dotdistrib, dotexptsimp, dotident, and dotscrules." ( from Maxima CAS doc)

Vectors
Category: Vectors :
 * Vectors
 * eigen
 * express
 * nonscalar
 * nonscalarp
 * scalarp

Category: Package vect
 * vect
 * scalefactors
 * vect_cross
 * vectorpotential
 * vectorsimp

title: Maxima/Data structures


text:
Maxima/Numerical methods

"If you are doing purely numerical computation and are concerned about speed, use a compiled numerical programming language. Maxima is intended for use if you have symbolic mathematical symbols, too, and while it works for numbers, most components of the system are on the lookout for non-numeric inputs, and this checking takes time.   It is possible to speed up certain kinds of numeric computations in Maxima by using compile and mode_declare  together. " RJF

Newton method
Functions
 * newton for equation with function of one variable
 * mnewton is an implementation of Newton's method for solving nonlinear equations in one or more variables.

newton
load : load("newton"); (%o1)                                                                                /home/a/maxima/share/numeric/newton.mac (%i2) load("newton1"); (%o2)                                                                                /home/a/maxima/share/numeric/newton1.mac

Code :

/* Maxima CAS code from /maxima/share/numeric/newton1.mac input : exp =  function of one variable, x var = variable x0 = initial value of variable eps =

The search begins with x = x_0 and proceeds until abs(expr) < eps (with expr evaluated at the current value of x).

output : xn = an approximate solution of expr = 0 by Newton's method

newton(exp,var,x0,eps):= block( [xn,s,numer],   numer:true,   s:diff(exp,var),   xn:x0,   loop,     if abs(subst(xn,var,exp))<eps          then return(xn),    xn:xn-subst(xn,var,exp)/subst(xn,var,s),   go(loop) )$

mnewton
One can use Newton method for solving systems of multiple nonlinear functions. It is implemented in mnewton function. See directory :

/Maxima..../share/contrib/mnewton.mac

which uses linsolve_by_lu defined in :

/share/linearalgebra/lu.lisp

See this image for more code. (%i1) load("mnewton")$

(%i2) mnewton([x1+3*log(x1)-x2^2, 2*x1^2-x1*x2-5*x1+1],             [x1, x2], [5, 5]); (%o2) x1 = 3.756834008012769, x2 = 2.779849592817897 (%i3) mnewton([2*a^a-5],[a],[1]); (%o3)            a = 1.70927556786144 (%i4) mnewton([2*3^u-v/u-5, u+2^v-4], [u, v], [2, 2]); (%o4) u = 1.066618389595407, v = 1.552564766841786

title: Maxima/Numerical methods


text:
Maxima/Algorithms

Stack ( LIFO)

Stack implementation using list:

/* create stack */ stack:[1]; /* push on stack */ stack:endcons(2,stack); stack:endcons(3,stack); block (  loop,   stack:delete(last(stack),stack), /* pop from stack */   disp(stack), /* display */   if is(not emptyp(stack)) then go(loop) ); stack;

title: Maxima/Algorithms


text:
Maxima/Plots

Complex Functions

 * Visualizing Complex Functions with Conformal Mapping ( themaximalist )

Topologist's sine curve
plot2d (sin(1/x), [x, 0, 1])$

Topologist's comb : load(draw); /* by Mario Rodríguez Riotorto http://riotorto.users.sourceforge.net/gnuplot/index.html  */

draw2d( title    = "Topologist\\47s comb", /* Syntax for postscript enhanced option; character 47 = '  */ xrange        = [0.0,1.2], yrange        = [0,1.2], file_name = "comb2", terminal      = svg, points_joined = impulses, /* vertical segments are drawn from points to the x-axis  */ color         = "blue", points(makelist(1/x,x,1,1000),makelist(1,y,1,1000)) )$

title: Maxima/Plots


text:
Maxima/Outputs and warnings

 * ratprint : false; /* remove "rat :replaced " */
 * using $ instead of ; at the end of the line ( not inside function where, ends the line )
 * return from the function
 * "warning: encountered undefined variable ... in translation." This is warning from compile when function uses global variable without using in in tha arguments list. You have to include the variables in the function's list

title: Maxima/Outputs and warnings


text:
Maxima/Example programs

 * Iteration of complex numbers, stack and drawing a list of points
 * Iteration of complex numbers, comparing complex numbers, finding period of cycle
 * Drawing Julia set and critical orbit. Computing period

 * drawing curves in 2D plane
 * drawing points

title: Maxima/Example programs


text:
Maxima/Help

bash

 * info maxima

Maxima commands

 * dependencies
 * infolists
 * describe

title: Maxima/Help


text: Maxima/Printable version

title: Maxima/Printable version


text: Phantasy Star Online Episode I & II/Printable version


text: History of Tennessee/Printable version

title: History of Tennessee/Printable version


text: History of Alaska/Printable version

title: History of Alaska/Printable version


text: History of Nevada/Printable version

title: History of Nevada/Printable version


text: History of Wyoming/Printable version

title: History of Wyoming/Printable version


text: Outline of U.S. History/Print version

title: Outline of U.S. History/Print version


text: History of Florida/Printable version

title: History of Florida/Printable version


text: History of Hawaii/Printable version

title: History of Hawaii/Printable version


text: History of New York State/Printable version


text: American Revolution/Printable version

title: American Revolution/Printable version


text: Canadian History/Printable version

title: Canadian History/Printable version


text: Hawaiian Monarchs/Printable version

title: Hawaiian Monarchs/Printable version


text:
Hawaiian Monarchs/Kamehameha III

Kamehameha III drasticly changed the government of Hawaii.

title: Hawaiian Monarchs/Kamehameha III


text:
Hawaiian Monarchs/Kamehameha IV

When Kamehameha IV died young, a power struggle ensured.

title: Hawaiian Monarchs/Kamehameha IV


text:
Hawaiian Monarchs/Kamehameha V

Established Kamehameha day.

title: Hawaiian Monarchs/Kamehameha V


text: Hawaiian Monarchs/William Lunalilo

title: Hawaiian Monarchs/William Lunalilo


text:
Fractals/moebius

Möbius transformation is an example of plane transformation

=definition=

A Möbius transformation   of extended complex plane $$\widehat{\Complex} = \Complex \cup \{\infty\}$$  is a rational function  f of the form

 * $$f(z) = \frac{a z + b}{c z + d}$$

of one complex variable z.

Here the coefficients a, b, c, d and the result w are complex numbers satisfying

 * ad - bc \ne 0

 * $$w = f(z) = \frac{a z + b}{c z + d}$$

=Representation or form =
 * function
 * matrix

Function

 * $$f(z) = \frac{a z + b}{c z + d}$$

 * $$f \ \colon z \to w$$

 * $$ w = f(z)$$

Matrix
In matrix form by using homogeneous coordinates:

M =

\left( \begin{matrix}\begin{array}{cc} a & b \\ c & d \end{array}\end{matrix} \right)

\,$$

w =

\left( \begin{matrix}\begin{array}{c} w \\ 1 \end{array}\end{matrix} \right)

=

\left( \begin{matrix}\begin{array}{cc} a & b \\ c & d \end{array}\end{matrix} \right)

\left( \begin{matrix}\begin{array}{c} z \\ 1 \end{array}\end{matrix} \right)

= \left( \begin{matrix}\begin{array}{c} az + b \\ cz + d \end{array}\end{matrix} \right)

\,$$

Matrix M is a square 2x2 invertible matrix

=Examples=
 * Transforms using Complex Numbers
 * Moebius transformation
 * Paper: Squares that Look Round: Transforming Spherical Images by Saul Schleimer Henry Segerman and Shadertoy : Spherical Images by soma_arc and python code Henry Segerman
 * Moebius transformation in mandelbrot-graphics library
 * Mathematics of Kleinian Group Fractals by hiddendimension
 * Generalized circles and Möbius transformations by Stéphane Laurent
 * Projective Transformation and Mobius Transformation by Tadao Ito

simple
The following simple transformations are also Möbius transformations:
 * $$ f(z) = z \quad (a=1, b=0, c = 0 ,d=1 ) $$ is an identity
 * $$ f(z) = z+b\quad (a=1,c = 0 ,d=1 ) $$ is a translation
 * $$ f(z) = az \quad (b=0,c = 0 ,d=1 )$$  is a combination of a homothety and a rotation.
 * If $$ |a| =1 $$ then it is a rotation
 * if $$ a \in \R $$ then it is a homothety
 * $$f(z)= 1/z \quad (a=0, b=1, c = 1 ,d=0 )$$ inversion and reflection with respect to the real axis)

=How to ...? =

eigenvalue and eigenvector
A number $$\lambda$$ and a non-zero vector $$v$$ satisfying

 * $$Mv = \lambda v$$

are called an eigenvalue and an eigenvector of matrix M, respectively.

For dimensions 2 formulas involving radicals exist that can be used to find the eigenvalues. The eigenvalues can be found by using the quadratic formula:

 * $$\lambda_{\pm} = \frac{{\rm tr}(M) \pm \sqrt{{\rm tr}^2 (M) - 4 \det(M)}}{2}.$$

diagonalization
a diagonal matrix is a matrix in which the entries outside the main diagonal are all zero. In other words all off-diagonal elements are zero in a diagonal matrix.

the main diagonal of a matrix $$A$$ is the list of entries $$A_{i,j}$$ where $$i = j$$, here $$ a_{11}, a_{22} $$

the diagonalization of a matrix M gives a pair of matrices: D, P such that:
 * D is diagonal (all elements not on the diagonal are 0)
 * $$M = P D P^{-1}$$

For 2x2 matrices there is a simple closed form solution

Product with a scalar
If $A$ is a matrix and $c$ a scalar, then the matrices $$c\mathbf{A}$$ and $$\mathbf{A}c$$ are obtained by left or right multiplying all entries of $A$ by $c$.

trace
The trace $$\operatorname{tr} $$ of a square 2x2 matrix $$\mathbf{A}$$

 * $$\mathbf{A} =

\begin{pmatrix} a_{11} & a_{12} \\ a_{21} & a_{22} \end{pmatrix} $$

is the sum of its diagonal entries

 * $$\operatorname{tr}(\mathbf{A}) = \sum_{i=1}^{2} a_{ii} = a_{11} + a_{22} $$

So $$\operatorname{tr}(\mathbf{M}) = a+d $$

determinant
determinant $$\operatorname{det}$$ of matrix $$\mathbf{M}$$

 * $$\operatorname{det}\mathbf{M} = \det \begin{pmatrix}a&b\\c&d\end{pmatrix} = ad-bc$$

inverse

Inverse Möbius transformation

 * $$\mathbf{M}^{-1} = \begin{pmatrix}a&b\\c&d\end{pmatrix}^{-1}

= \frac{1}{\operatorname{det}\mathbf{M}}

\begin{pmatrix} d & -b \\ -c & a \end{pmatrix}

= \frac{1}{ad-bc} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix} $$

z = \frac{1}{\operatorname{det}\mathbf{M}} \begin{pmatrix} d & -b \\ -c & a \end{pmatrix}

\begin{pmatrix} w \\ 1 \end{pmatrix}

$$

$$z = f^{-1}(w) $$.

interpolation
How to smootly interpolate between möbius transformations?

If you have two Möbius transformations represented as:

$$f(z) = \frac{az + b}{cz + d}$$

$$g(z) = \frac{pz + q}{rz + s}$$

where coefficients are complex numbers

 * $$a, b, c, d, p, q, r, s, z \in \mathbb{C}$$

Is it possible to derive a third function $$h(z, t)$$, where $$t \in \mathbb{R}$$ and $$0 \leq t \leq 1$$, which "smoothly" interpolates between the transformations represented by $$f(z)$$ and $$g(z)$$?

The solution:

 * $$h(z, t) = f e^{t \log(f^{-1} g)} = f \operatorname{exp}(t \log(f^{-1} g))$$

Specifying a transformation by three points
Given a set of three distinct points z1, z2, z3 on the one Riemann sphere ( let's call it z-sphere) and a second set of distinct points w1, w2, w3 on the second sphere ( w-sphere), there exists precisely one Möbius transformation f(z) with : for i=1,2,3
 * $$ f(z_i) = w_i$$
 * $$f^{-1}(w) = z_i $$

Mapping to 0, 1, infinity
The Möbius transformation with an explicit formula :

 * $$f(z)= \frac {(z-z_1)(z_2-z_3)}{(z-z_3)(z_2-z_1)}$$

maps :
 * z1 to w1= 0
 * z2 to w2= 1
 * z3 to w3= ∞

the unit circle to the real axis - first method
Let's choose 3 z points on a circle :
 * z1= -1
 * z2= i
 * z3= 1

then the Möbius transformation will be :
 * $$f(z)= \frac {(z+1)(i-1)}{(z-1)(i+1)}$$

Knowing that :

$$i+1 = -i (i -1 ) $$

one can simplify this to :

 * $$f(z)= i \frac {z+1}{z-1}$$

In Maxima CAS one can do it :

(%i1) rectform((z+1)*(%i-1)/((z-1)*(%i+1))); (%o1) (%i*(z+1))/(z−1)

where coefficients of the general form are :
 * $$a = i$$

 * $$b = i$$

 * $$c = 1$$

 * $$d = -1$$

so inverse function can be computed using general form :

 * $$f^{-1}(w) = \frac{dw-b}{-cw+a} = \frac{-i - w}{i-w}$$

Lets check it using Maxima CAS :

(%i3) fi(w):=(-%i-w)/(%i-w); (%o3) fi(w):=−%i−w/%i−w (%i4) fi(0); (%o4) −1 (%i5) fi(1); (%o5) −%i−1/%i−1 (%i6) rectform(%); (%o6) %i

Find how to compute it without symbolic computation program (CAS) :

(%i3) fi(w):=(-%i-w)/(%i-w); (%o3) fi(w):=−%i−w/%i−w (%i8) z:x+y*%i; (%o8) %i*y+x (%i9) z1:fi(w); (%o9) (−%i*y−x−%i)/(−%i*y−x+%i) (%i10) realpart(z1); (%o10) ((−y−1)*(1−y))/((1−y)^2+x^2)+x^2/((1−y)^2+x^2) (%i11) imagpart(z1); (%o11) (x*(1−y))/((1−y)^2+x^2)−(x*(−y−1))/((1−y)^2+x^2) (%i13) ratsimp(realpart(z1)); (%o13) (y^2+x^2−1)/(y^2−2*y+x^2+1) (%i14) ratsimp(imagpart(z1)); (%o14) (2*x)/(y^2−2*y+x^2+1)

So using notation :

$$ z = x + yi = f^{-1}(w) $$

one gets :

$$ x = \operatorname{Re}(z) = \operatorname{Re}(f^{-1}(w))  = \frac{y^2+x^2-1}{y^2-2y+x^2+1}$$

$$y = \operatorname{Im}(z) = \operatorname{Im}(f^{-1}(w)) = \frac{2x}{y^2-2y+x^2+1}$$

It can be used for unrolling the Mandelbrot set components

the unit circle to the real axis - second method
Function :

$$f(z) = i\frac{z-1}{z+1}$$

sends the unit circle to the real axis :

 * z=1 to w=0
 * z=i to w=1
 * z=-1 to $$w=\infty$$

Mapping to the imaginary axis
Function $$f(z) = \frac{z-1}{z+1}$$ sends the unit circle to the imaginary axis.

= visualisations=
 * mobius revealed by Mark McClure
 * live demo by Tim Hutton
 * Iterating the Möbius transformation by Tim Hutton

=References=
 * moebius-transformation by Claude Heiland-Allen

title: Fractals/moebius


text: Telecommunications Theory/Printable version


text: Introduction to Philosophical Logic/Printable version


text:
Talk:IB Business Management

dhdjshsjajjajjajusuahahsha

title: Talk:IB Business Management


text:
User talk:2001:448A:2020:64FF:D86B:5841:F4A9:61CF

udieuwiiiaiaisiiaijskajjajjakskaiaaka


text:
Chess Opening Theory/1. h4/1...d5

=Kadas Opening=

1...d5
Black takes the center and opens the diagonal for the light-squared bishop, preventing White's kingside rook from coming out with 2. Rh3??, to which Black will respond with Bxh3. White may try to rectify this with 3. h5?!, but this allows Black to take the full center with 3... e5! not allowing the rook to come to h4 either.

Responses
White may respond to the move d5 with:
 * /2. h5/, allowing Black to take the full center with 2...e5,
 * /2. d4/, which is more principled, and White will always play d4 in this opening so why not?
 * or 2. Nf3, controlling the center with a knight and either going into a King's Indian-like defense, playing classically, or just transposing into the d4 line.

title: Chess Opening Theory/1. h4/1...d5


text:
User:Chessops2/sandbox

3. h6 - Croon's Gambit
The Croon's gambit is an ambitious attempt to ruin Black's kingside at the cost of a pawn. When the pawn is teken, it opens up White's rook file. The main plan of this opening is to open up the rook file or have a thorn pawn on h6 after g6, then strike at the center with d4 and c4 afterwards. Sometimes if Black Takes the pawn, White can take black with Bxh6 after d4. White will always play d4 in every line.

Theory table
.

'''1. h4 d5 2. h5 e5 3. h6'''

title: User:Chessops2/sandbox


text: Malay/Printable version

title: Malay/Printable version


text:
Chess Opening Theory/1. h4/1...d5/2. h5

=Kadas Opening=

2. h5
White continues to march the flank pawn, allowing Black to take the full center with /2...e5/. Another common response is /2...h6/.

title: Chess Opening Theory/1. h4/1...d5/2. h5


text:
Chess Opening Theory/1. h4/1...d5/2. h5/2...e5

=Kadas Opening=

2...e5
Black took the full center, unruffled by White's strange h-pawn advance.

White usually responds with
 * /3. h6/, the Croon's Gambit, or
 * /3. c3/, preparing 4. d4.


text:
Chess Opening Theory/1. h4/1...d5/2. h5/2...e5/3. h6

= Kadas Opening: Croon's Gambit =

3. h6
The Croon's Gambit is an ambitious attempt to ruin Black's kingside at the cost of a pawn. The main plan of this opening is to open up White's rook file or have a thorn pawn on h6, then strike at the center with d4 and c4 afterwards. Sometimes if Black takes the pawn, White can take back with Bxh6 after d4. White will always play d4 in every line.

Theory table
.

'''1. h4 d5 2. h5 e5 3. h6'''

Usage
FM Orest Vovk tried this opening at the European Blitz 2015 tournament with mixed success. As of 2022, he still regularly uses this opening online.


text:
History of video games/Platforms/Intellivision III

History
The Intellivision III was a cancelled successor of the Intellivision.


text:
History of video games/Platforms/Tizen cloud gaming

Development
A cloud gaming service for Samsung smart televisions running the Tizen operating system was announced on October 26th, 2021 during Samsung Developer Conference 2021. The announcement coincided with some other other gaming technology announcements from Samsung. A major effort was made to improve the developer experience for the platform.

In January 2022 during CES 2022 the system was announced more formally as the Samsung Gaming Hub.

Technology
Tizen itself is an operating system based on the Linux kernel.

The system acted as a gateway to other services, such as Utomik, GeForce Now, and Google Stadia.

On June 9, 2022 it was announced that Samsung Smart TVs would also support Xbox Game Pass cloud gaming.


text:
History of video games/Platforms/KW-501

History
The KW-500 and KW-501, were a family of unlicenced Sega Mega Drive clones which achieved some popularity in certain markets.

title: History of video games/Platforms/KW-501


text:
History of video games/Platforms/Light Pong

History
A crowdfunding campaign for Light Pong was launched on Kickstarter in late 2021.

Technology
Light Pong is designed as a 1 dimensional gaming console.

Despite the name suggesting it only plays a version of Pong, the console plays a number of games.


text:
History of video games/Platforms/SNK NeoStar

Development
The SNK NeoStar was an unreleased console.

The console was heavily featured in the November 1993 Official Neo Geo Newsletter.

Legacy
Most of what is known of the console comes from the planning stages and early marketing. As such this console remains highly obscure.

Technology
The console was to use a RISC architecture 32-bit CPU clocked at roughly 14.5 megahertz. The console was said to support polygonal graphics, as well as CD-i format.

The system was to use both cartridges and CD-ROM disks, as well as memory cards. These memory cards were different then prior Neo-Geo memory cards, and were said to be based on hard disk drive technology, enabling a 20 times increase of capacity over older Neo Geo memory cards.

The Neo Star output resolution was supposed to go as high as 640x480. The system would have supported surround sound output.

The system sported 4 joystick ports, as well as support for wireless controllers over infrared communication.

Add-ons planned included a keyboard, "Cable TV/Modem" for online multiplayer and connectivity, and 3D goggles. Online banking was a notable non-game use case for the console's online features.


text:
History of video games/Platforms/ZRRO

Development
Zrro Technologies was a company based in Tel Aviv, Israel.

According to the ZRRO developers, system development began four years prior to announcement (Circa 2011).

Campaign
A website for ZRRO had been operational as early as February 2015.

At least one prototype unit had been sent out for review by February 2015.

The ZRRO met a $200,000 Kickstarter funding goal in 2015. The preorder cost was $199.

Legacy
By August 2016 the ZRRO website was no longer active.

Little more is known about the ZRRO console.

Compute
The system has a quad core processor clocked at 2.0 gigahertz. The system sported 2 gigabytes of DDR3 RAM. The system had 16 gigabytes of onboard storage, as well as a microSD card slot. The system also had an "8 core GPU".

Software
The ZRRO ran Android 4.4 as an operating system.

ZRRO Pad Controller
The distinctive feature of the console was it's controller, which allowed hovering fingers to be registered. Finger detection worked to a range of 1.2 in away from the controller pad. Multiple fingers could be registered simultaneously.

The ZRRO Pad controller supports vibration feedback.

The ZRRO Pad also contained 3 physical buttons below the touch pad.

The ZRRO Pad is wireless.

2015

 * Clash of Clans

title: History of video games/Platforms/ZRRO


text:
History of video games/Platforms/Monon Color

Development
M&D manufactured the Monon Color. Some firmware versions are dated to July 30th, 2014.

Launch
The Monon Color was released in China on either September 30th, 2014, or sometime in October 2014. The price of the system was 100 RMB.

Legacy
In Feburary 2021 "Team Europe" produced a third party 128 megabit flashcart and dumping tool was released for the system.

Compute
The Monon Color is powered by an AX208 SOC, which contains a 8051 derived CPU with 16-bit opcodes clocked at 96 megahertz with additional facilities such as AV decoders.

The system is said to have 16 kilobytes of RAM.

Hardware
The system has a TFT LCD with a resolution of 320 pixels by 240 pixels.

Cartridges were used as a game media.

The system was capable of wireless communication through the use of an IR port.

The handheld was powered by 3 AA batteries.

The unique design of the D-pad was noted.


text:
History of video games/Platforms/Sony mylo

History
While not primarily intended as a gaming device, the Sony mylo had a unique software ecosystem with it's own gaming library.

mylo 2
Prior to launch Sony downplayed the gaming capabilities of the system, considering serious gaming capabilities to be too out of reach from the target system price.

The mylo 2 was released in 2008. The device supported a full version of Adobe Flash, including Flash games. Ajax games were also supported.

Technology
Like the PlayStation Portable, the mylo used memory stick format cards for expanded storage.

COM-1
The device included Wi-Fi support.


text:
History of video games/Platforms/Minty Pi

History
On July 18th, 2017 the MintyPi build guide was released.

No video build guide was posted for MintyPi v2. On April 10th, 2017 a video update about the mintyPi 2.0 was posted.

On March 8th, 2019 the MintyPi v3 build guide was released.

On October 18th, 2020 the MintyPi v3.5 build guide was released.

Technology
The Minty Pi was designed to fit in a mint tin.


text:
History of video games/Platforms/Roku

History
While gaming is not the main focus of the Roku line, a number of smaller games were developed for the system.

Roku did make some pushes towards the gaming market, such as with the release of the Roku Gaming Remote around 2011.

title: History of video games/Platforms/Roku


text:
History of video games/Platforms/MiSTer

Technology
The MiSTer used an FPGA.

title: History of video games/Platforms/MiSTer


text:
History of video games/Platforms/Apple TV

History
The Apple TV is a series of multimedia boxes, which heavily featured gaming.


text:
History of video games/Platforms/Philips Tele-Game series

Launch
The Pilips Tele-Game consoles were a series of early game consoles first released by Philips in late 1975.

Legacy
The last release occoured in 1978.

Technology
The technology used in the console was similar to the odyssey, except significant game circuitry was contained on cartridge.

Later "Las-Vegas" models would rely more on integrated circuits.


text:
History of video games/Platforms/Video Pinball series

History
The Video Pinball consoles were a series of Atari consoles. The first of the consoles was released in 1977.

Technology
The Video Pinball consoles contained RAM.


text:
History of video games/Platforms/Visulex Kit

Background
Visulex manufactured a game console kit which was meant to teach students about electronics.

Launch
According to a 1975 ad, the schematics could be ordered for $1, with a component cost of $40. By May 1976 Visulex kits were still being advertised. Given it's confirmed existence by January 1977, it is among the oldest such consoles to pursue this concept.

Media continued to feature the system through at least January 1977, and possibly longer.


text:
History of video games/Platforms/Retro-Bit Generations

Development
The console was announced by August 2016.

Launch
The system was released later in 2016 for $59.99 USD or 49.99 British Pounds.

Legacy
Due to emulation issues, the system was generally received poorly by critics at launch. However, some reviewers did consider the system as a fair value for the price.

Later on, three more versions Retro Bit Generations consoles were made for a total of 4 consoles in the series by 2018.

Hardware
The system has an HDMI output port. The system also had three RCA jacks for composite video and stereo audio.

The system was shipped with two controllers.

Software
Licenced games were played on the system via emulation.

Games
The system shipped with a non-expandable library of commercial games.

The system also shipped with some system specific games, which were primarily clones of other games.


text:
History of video games/Platforms/ODROID-GO Series

History
The Hardkernel ODROID-Go Advance was released in 2020.

The ODROID-Go Super was released in 2021.


text:
History of video games/Platforms/Kitronik Arcade

Technology
Audio is created with a simple piezoelectric speaker.


text:
History of video games/Platforms/Fire TV

History
The Fire TV is a series of consumer media consumption devices that include some gaming functionality. While most focused on non-interactive media, a special Amazon Fire TV Gaming Edition placed greater emphesis on gaming.


text:
History of video games/Platforms/Nexus Player

History
When it was revealed in late 2014, the media saw it as a micro console due to it's gaming capabilities.

Technology
The device was powered by a smartphone class x86 Intel Atom Z3560 CPU, which was clocked at 1.83 gigahertz, with this chip also containing a Imagination Technologies 6430 GPU.


text:
History of video games/Platforms/AYN Odin

History
From August 2021 to October 4th, 2021 a crowdfunding campaign was held, raising $670,000 to develop the console.

Technology
The console is powered by an 8 core MediaTek Dimensity D1000G CPU clocked at 2 gigahertz. Some models instead used a Snapdragon 845 system on a chip.


text:
History of video games/Platforms/Atari Flashback series

Technology
The first revision of the Flashback suffered from a number of technical problems.


text:
History of video games/Platforms/Let's! TV Play Classic

History
This series of consoles was only released in Japan.


text:
History of video games/Platforms/Lenovo Legion Play

History
Evidence suggested the device was planned for demonstration at MWC (Mobile World Congress) 2021, but was pulled.

The Lenovo Legion Play came to light in October of 2021 as the result of a leak. There was widespread doubt over the value of the handheld based around game streaming following the leak.

The console was often seen as a potential rival to the Steam Deck and the Nintendo Switch.

Controls
The system would have twin analog sticks, one on the upper left and one on the bottom right.

Four face buttons would be housed on the upper right. Clockwise a yellow Y button would be at the top of the diamond pattern, a red B button would be at the right of the diamond, a green A would be at the bottom of the diamond, and finally a blue X button would be housed at the left of the diamond.

The bottom left side of the device would have housed the D-Pad.

Dual shoulder buttons would have been available.

There are potentially 2-4 other auxiliary buttons visible on the face of the device, though it is unclear if they are really buttons or ornamentation.

Hardware
The system would sport a full HD, 16:9 aspect ratio, HDR 10, 7 inch display. There is conflicting information regarding the bezels on the device.

The console would have been powered a 7,000 mAh capacity battery. A USB type C port would have been used.

Either twin speakers or a headphone jack would provide for audio.

The console would support haptic feedback from two motors.

Software
The console would have ran a customized version of Android.

Nvidia GeForce Now would have been supported.

A Google Play icon was visible on the launcher.


text: History of Brazil/Printable version

title: History of Brazil/Printable version


text: Apples/Printable version

title: Apples/Printable version


text: Raising Cattle/Printable version

title: Raising Cattle/Printable version


text: Category:Book:Quantum Chemistry

title: Category:Book:Quantum Chemistry


text: Quantum Chemistry/Printable version

title: Quantum Chemistry/Printable version


text: Category:Book:Learn Shavian

title: Category:Book:Learn Shavian


text:
Learning Clojure/Multimethods and polymorphism

Multimethods and polymorphism
Most languages treat encapsulation and implementation inheritance as the primary features of object-oriented programming, but Clojure thinks these things are overrated. The real virtue of OOP, Clojure says, is polymorphism---encapsulation and inheritance are simply straight-jackets holding back polymorphism's potential.

When doing object-oriented programming in Clojure, we simply use structmaps in place of objects while, in place of traditional encapsulated methods, we use what Clojure calls multimethods, functions which pass on their arguments to other functions based on some criteria of the arguments, such as the number and/or type of the arguments.

A multimethod is made up of three things: a dispatch function, a set of methods, and a set of values associated with those methods. Calling a multimethod calls the dispatch function, and the value returned determines which method to call. A multimethod is created with clojure/defmulti and methods added to it by the macro clojure/defmethod. Here's a reductively simple multimethod with just two methods:

(defmulti victor (fn [a] a)) (defmethod victor 3 [a] "hello")  ; attach a method to call when the dispatch returns 3; the function takes 1 argument, ; which it ignores, returning "hello" (defmethod victor 5 [a] "goodbye") (victor 3)                        ; returns "hello" (victor 5)                        ; returns "goodbye" (victor 4)                        ; exception: No method for dispatch value: 4

Note that the methods' arities must match the multimethod arity because the dispatch function calls the methods by passing on its arguments. (Also note the stylistic inconsistency: defmulti expects a function argument whereas defmethod imitates the defn form.)

Multimethods can be used to imitate traditional single- and multiple-inheritance polymorphism as well as more flexible kinds of polymorphism.


text:
Learning Clojure/Collection functions

Collection functions
The clojure namespace contains many functions and macros for handling collections. Rather than repeat reference information from the API documentation, I'll give just a few example operations:

 * (count collection)

Returns the number of items in the collection.

(count [a b c]) ; return 3 (count nil)     ; return 0

 * (conj collection item)

conjoin. Returns a new copy of the collection with the item added. How the item is added depends upon the collection type, e.g. an item conjoined to a list is added to the beginning while an item conjoined to a vector is added to the end.

(conj [5 7 3] 9)       ; returns [5 7 3 9] (conj (list 5 7 3) 9)) ; returns list (9 5 7 3) (conj nil item)         ; returns list (item)

 * (list item*)
 * (vector item*)
 * (hash-map keyval*) where keyval => key value

Produce a list, vector, or hashmap, respectively. You can generally always just use literal syntax in place of these functions, but having functions gives us something to pass to other functions expecting function arguments.

 * (nth collection n)

Return the nth item from collection, where collection is any collection but not a map. (The collection can be a sequence over a map, but not an actual map.)

(nth [31 73 -11] 2)       ; returns -11 (nth (list 31 73 -11) 0)  ; returns 31 (nth [8 4 4 1] 9)         ; exception: out of bounds

 * keywords as functions

A keyword can be used as a function to look up a key's value in the various kinds of maps (hashmaps, sets, structmaps, etc.):

(:velcro {:velcro 5 :zipper 7})  ; returns 5, the value mapped to :velcro in the hashmap

 * maps as functions

The map types themselves can be used as functions to look up their key's values:

({:velcro 5 :zipper 7} :velcro)  ; returns 5, the value mapped to :velcro in the hashmap ({3 "cat" :tim "moose"} :tim)    ; returns "moose", the value mapped to :tim in the hashmap (["hi" "bye"] 1)                 ; returns "bye", the value of the second index in the vector

Sequence functions
Most of the sequence functions can be passed objects which are not sequences but from which a sequence can be derived, e.g. you can pass a list in place of a sequence.

Where there are redundancies between sequence operations and more operations specialized for specific collection types, the redundancies are mostly for performance considerations. For instance, to produce a reversed-order sequence of a vector, you can use the sequence operation reverse or the vector specific rseq: while rseq is less general, it is more efficient.

 * (seq collection)

Return a sequence representing the collection. seq also works on native Java arrays, Strings, and any object that implements Iterable, Iterator, or Enumeration.

title: Learning Clojure/Collection functions


text:
Learning Clojure/Destructuring

The special forms let, loop, and fn are actually macros: the real special forms are named let*, loop*, and fn*. The macros are most commonly used in place of the actual special forms because the macros add a convenience feature called destructuring.

Often a function expects to receive a collection argument out of which it means to use particular items:

; return the sum of the 1st and 2nd items of the sequence argument (defn foo [s]   (+ (first s) (frest s))) ; sum the first item and the "frest" (first of the rest) item

Having to extract out the values we want can get quite verbose, but using destructuring can help in many cases:

; return the sum of the 1st and 2nd items of the sequence argument (defn foo [s]  (let [[a b] s]     (+ a b)))

Above, where a parameter name is normally specified in the argument list, we put a vector followed by a parameter name: the items in the collection passed to the parameter s are bound to the names a and b in the vector according to position. Similarly, we can destructure using a map:

(def m {:apple 3 :banana 5}) (let [{x :apple} m]           ; assign the value of :apple in m to x    x)                          ; return x

''[I have to say this feels backwards to me: shouldn't it be (let [{:apple x} m] x)? I like to think of the destructuring expression as mirroring the collection being destructured.]''

Destructuring can also be used to pull out the value of collections within collections. Hickey gives more complete coverage here.

title: Learning Clojure/Destructuring


text:
Study Skills/Introduction

Learning involves many activities: managing your time, taking notes, reading books, listening to lectures, memorizing, having discussions, and writing tests. We'll cover each of these activities individually, and teach you to do them more effectively. Feel free to learn the sections in any order that makes sense to you; however given that this is a text, we suggest that you start with the Reading Textbooks section.

Before you begin studying anything, there are some basic ground rules to follow: These instructions are distilled from the studying tips offered by Dale Carnegie in the introduction of each of his books.
 * 1) Desire to learn the material. If you are not motivated, you won't learn. Respicius Rwehumbiza in 2013 asserted that, Desire to learn enables you to sacrifice for study and manage time for study. It enables you to study anywhere and at any time. It creates a sense of responsibility in you about study, a sign of success. It puts you in sense of competition to learn more and more. It makes you generate new ideas and techniques for study, how to study effectively, how to concentrate and how to manage time for study
 * 2) Review the material regularly to reinforce your knowledge of the subject.
 * 3) Apply the knowledge. If you don't use it, you'll forget it sooner.
 * 4) Introspect regularly. Set aside a specific time each week where you examine your actions for that week. Take the time to learn from your mistakes and your successes.

title: Study Skills/Introduction


text:
Study Skills/Managing Your Time

Managing your time effectively is an important part of studying. One of the important things in time management is to do whatever works for you. One common mistake is to try to create an overly restrictive schedule which doesn't work, and then feel very guilty that it doesn't work. Telling yourself that scheduling just doesn't work for you is another common mistake.

The following list will guide you through time management.
 * 1) Schedule - Have a regular study time and place each day - This helps put you in study mode. It's what Pavlov did with his dogs. ("Good doggy. Now study! Study...").
 * 2) Prioritize - Make a list of what you have to do and list it in order of importance. Schedule the important stuff first.
 * 3) Plan your sessions - Do the difficult stuff first. That way, by the time you can barely add 1 to 1, that's all you have left to do.
 * 4) Prepare - Get everything you'll need together BEFORE you start studying.
 * 5) Take breaks - Don't study longer than 50 minutes at a stretch. Use the other ten for a run around the block, or eat a snack. Hmm... Maybe run around the block AFTER the snack. Taking a 5-minute hot shower is another excellent solution.
 * 6) Avoid getting stuck - If you can't figure something out, skip it, and get help later. Skipping everything is not allowed.
 * 7) Divide and conquer - Break your projects up into smaller bits, and complete those bits one by one.
 * 8) Set Milestones - Set yourself some milestones. You can also set rewards for reaching those milestones.
 * 9) Reward yourself - The reward can be small, like treating yourself to some ice cream, or larger, like buying that new outfit you've had your eye on. Rewards also don't have to cost money, like going to play some basketball with some friends at the park. Enjoy yourself when you pass a milestone, stick to your reward plans to make them more worth reaching.
 * 10) Use your time wisely - Use the days for tough activities like studying, and evenings for easier stuff like reviewing. On second thought, better schedule the latter during the day as well.
 * 11) Review regularly - We have said this before. It's important. Better read it again.
 * 12) Say "No!" to distractions - No matter how attractive they are unless, of course, it's on the schedule. ("Proclaiming my everlasting love: Tuesday 16:25 to 16:30")

title: Study Skills/Managing Your Time


text:
Study Skills/Taking Notes

Note taking is vital when Reading Textbooks and Listening To Lectures. Note taking serves a number of purposes. The least important reason is to have material for review. The real reason for note taking is to get the material to stick in your brain. By taking notes, you are actively engaging your brain in the process. And it helps keep you awake. These instructions are derived from the Cornell study method. You can find more information about the Cornell Notes format here.
 * 1) Get the keys - Make notes of key words, phrases and concepts.
 * 2) Summarize - Make summaries of the keys.
 * 3) Restate - Use your own words when writing down the keys. This causes you to think about them.
 * 4) Review - Always review. Review always. Always. Review. Get it? Now read that again.

Tips

 * Don't try to substitute a tape recorder or prepared lecture notes for note taking. Remember that making a record of the lecture is the least important reason for taking notes.
 * Don't try to copy the lecture word for word. Instead try to summarize the major points. This causes you to listen actively.
 * Talk to yourself in your notes. Note what is interesting, what is boring, what makes sense, and what doesn't.
 * Summarize what you have learned. Some people highlight the most important sentence on each page. (Highlighting nearly every sentence on a page is a clear sign that you don't understand it.) Others keep scratch paper, and jot down a summary of every chapter - a few sentences noting the topic of that chapter and the three most important things about that topic.
 * Draw diagrams in your notes, label them, and color them, if you want. Diagrams related to the lecture are what is useful. Unrelated diagrams are merely doodles.
 * Visually organize points into groups. Use outlines, brackets, lists, arrows, stars, boxes, circles, and others.
 * Use color pens or highlighters to mark the different parts of concepts, such as key term, definition, examples, person, place or time, etc.

Annotation system
If you are annotating a text, for example, a scientific article, try creating an annotating scheme. One system is to: Play around with this. Let the system evolve to suit your needs. See if colors are of any use; I personally prefer not to switch pens so I stick to blue (to contrast against the black text)
 * circle words or ideas I do not understand or have never seen
 * put a bracket around things I wish to highlight
 * underline things I especially wish to highlight
 * put an angle bracket next to things I disagree with
 * put an arrow next to things I find remarkable or interesting (scientific articles)

Read more

 * There is a separate Wikibook on Note taking.

title: Study Skills/Taking Notes


text:
Study Skills/Reading

There are several techniques that universities advocate for studying textbooks. Most of them have the same basic structure though. The above is an amalgamation of the SQ5R,the Parcer study techniques, and Plan, Do, Review. The concept at the heart of these techniques is active reading. The idea is that instead of passively reading a textbook and not really paying attention, you have to actively engage your mind in the act of reading, thereby improving comprehension and retaining efficiency. The more you involve your mind in the reading, the better you'll remember.
 * 1) Preview - Quickly skim over the chapter you are studying to get an overview of the material. Read headings, sub-headings, bold words, and other words that are emphasized.
 * 2) Ask - Constantly ask yourself questions about the headings and keywords. Changing headings and keywords into questions, using who, what, where, when, and why.
 * 3) Read - Read the first section, answering the questions you asked earlier. Note any unexpected information as well. (Think about if your questions were on target and what you need to know. Compare what you are reading with what is discussed in class.)
 * 4) Record - Take notes of your answers, of important keywords, and of important concepts. More about this in Taking Notes
 * 5) Relate - Relate each section to the preceding and following sections. Relate information to your previous knowledge and experience.
 * 6) Recite - Cover your answers and notes, and recite them from heart.
 * 7) Repeat - Repeat the Ask-Recite sequence for each section in the chapter.
 * 8) Practice - Do any practice questions and exercises in the material.
 * 9) Review - Review all your notes, and try to recite the important concepts from heart.

General Tips

 * If there are words you don't understand, look them up in a dictionary or textbook related to the concept.

Math/Science Tips

 * Instead of merely "reading" sample problems, look for errors in the author's work. As you read each sentence or step, verify for yourself it is completely correct, and is a logical next step or conclusion.
 * Copy a sample problem to another sheet of paper, then see if you can solve it yourself without looking at the textbook's solution (unless you get stuck). This makes the best use of sample problems, as students who "understood the lecture" or "read the chapter" often have difficulty doing their first problems using this new-found knowledge.
 * Reading a page of a Math/Science textbook this way may take anywhere from 20 minutes to several hours, but will probably reduce your eventual study time for a quiz or test by an even greater amount.
 * Understanding the main ideas of a topic does not mean you will be able to solve problems involving the topic. Spend more time solving problems than you do reading or listening.

title: Study Skills/Reading


text:
Study Skills/Listening To Lectures

 * 1) Prepare - Before you go to a lecture, be sure you've read any assigned reading particularly the concerning text in your study book. Go to class a little early and review the key points of the reading.
 * 2) Be on time. Instructors often dislike having students walk in mid-way through a lecture, and you will have missed material.  Some instructors intentionally base their lecture on statements made in the first few minutes to force students to be on time. Some faculty also give key information (such as test dates) at the beginning of class.
 * 3) Take notes - Always take copious notes. See Taking Notes for tips.
 * 4) Ask questions - If you don't get something, ask. When you ask, state what you understood the teacher to be saying, then ask whether you got it right or not.   In this way, the teacher will be able to detect what exactly you don't understand and clarify it for you.
 * 5) Think ahead of the teacher - What are the implications of the things they are telling you?  Teachers like to steer their lecture on a subject towards the next topic in order to make a smooth transition, and thinking about the implications may give you a head start on understanding that next topic.

title: Study Skills/Listening To Lectures